@dcl/shop 0.1.0-28747573214.commit-462a45d → 0.1.0-28749698227.commit-0c859e2
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/{Assets-DfOXKOnR.js → Assets-FMrABFH_.js} +1 -1
- package/assets/{Cart-DbbHo7Lp.js → Cart-COyAPJn1.js} +1 -1
- package/assets/{CircularProgress-D-iaLmF3.js → CircularProgress-ePyo1lbd.js} +1 -1
- package/assets/{Collection-BBAHD9v7.js → Collection-DJjtkyI0.js} +1 -1
- package/assets/{ConstantsUtil-CkFCQ14z.js → ConstantsUtil-D9t4gp4-.js} +1 -1
- package/assets/{Creator-Cf3awWfr.js → Creator-Cd6xMnQk.js} +1 -1
- package/assets/{ExchangeController-C636pVri.js → ExchangeController-AR7AXGzp.js} +1 -1
- package/assets/{GetCredits-BbICBHrS.js → GetCredits-BC7Z51_v.js} +2 -2
- package/assets/{HelpersUtil-D13uBBzL.js → HelpersUtil-PrvulZLQ.js} +1 -1
- package/assets/{ImportListings-BBkMIFrL.js → ImportListings-CXvHkADP.js} +1 -1
- package/assets/{ItemDetail-Dn0l_owe.js → ItemDetail-Sn2B-MA3.js} +1 -1
- package/assets/{Market-CMksg97B.js → Market-Cr-J1I9u.js} +1 -1
- package/assets/{MyAssets-Ly529Qzy.js → MyAssets-CpoF2iAy.js} +1 -1
- package/assets/{MyFavorites-BM98-wNr.js → MyFavorites-b3vHnYMr.js} +1 -1
- package/assets/{MyPurchases-DDXg_7hF.js → MyPurchases-DVXmppAu.js} +1 -1
- package/assets/{NetworkUtil-DRBYr7tG.js → NetworkUtil-CSluj-ND.js} +1 -1
- package/assets/{RealCheckout-CZ81fyEJ.js → RealCheckout-DO6nD-rf.js} +1 -1
- package/assets/{Success-De5n3cBh.js → Success-CNdczbFT.js} +1 -1
- package/assets/{SvgIcon-DMAonb7f.js → SvgIcon-D2AubmSV.js} +1 -1
- package/assets/{SwapController-DPv5gEgC.js → SwapController-DTKDtDuh.js} +1 -1
- package/assets/{TradeService-BuOZVMe-.js → TradeService-BK-xq9ht.js} +1 -1
- package/assets/{W3MFrameProviderSingleton-C53Q9nWr.js → W3MFrameProviderSingleton-DxZDURuu.js} +3 -3
- package/assets/{WebCryptoP256-DpIFc-YF.js → WebCryptoP256-DslKERu3.js} +1 -1
- package/assets/{basic-9TVVZq54.js → basic-ClTZjNQz.js} +1 -1
- package/assets/{biconomy-BqDW4_Fp.js → biconomy-BVk_afT2.js} +1 -1
- package/assets/{buy-WskP4uLn.js → buy-_5Wro-EH.js} +1 -1
- package/assets/{buy-gasless-BGYfXddW.js → buy-gasless-Da6cXp5w.js} +1 -1
- package/assets/{ccip-Bj2uK6oU.js → ccip-99AVWMCb.js} +1 -1
- package/assets/{ccip-D_jnTLJz.js → ccip-JE6ul9xT.js} +1 -1
- package/assets/{chains-BvaNJh8k.js → chains-L33YnVne.js} +1 -1
- package/assets/{collection-BxPtwR5Z.js → collection-Dj1PGTaS.js} +1 -1
- package/assets/{common-nfYPFMcM.js → common-CKF0Kl8D.js} +1 -1
- package/assets/{controller-B8DfbcQK.js → controller-C8G19uhk.js} +2 -2
- package/assets/{core-CwPOZw31.js → core-CyJXDVbu.js} +4 -4
- package/assets/{custom-CGIKAcy_.js → custom-Cjf2UWeN.js} +1 -1
- package/assets/{data-capture-DxwcCoJo.js → data-capture-Byx93Q11.js} +1 -1
- package/assets/{decimals-DxJOLJvr.js → decimals-CTfzGzBe.js} +1 -1
- package/assets/decimals-nJOPAX3f.js +1 -0
- package/assets/{detectExtension-C1tdnZ3w.js → detectExtension-D3zYez7t.js} +1 -1
- package/assets/{email-D72jCMmT.js → email-DPOB-SWJ.js} +1 -1
- package/assets/{embedded-wallet-Bog9n_tH.js → embedded-wallet-CHJsBta2.js} +1 -1
- package/assets/{engine-Bog4mCpH.js → engine-Bnqy1EVE.js} +1 -1
- package/assets/{estimate-l1-fee-CuQIe1md.js → estimate-l1-fee-Bl4TKlfd.js} +1 -1
- package/assets/eth_estimateGas-C6gJZO0T.js +1 -0
- package/assets/{eth_getStorageAt-9X28hhH4.js → eth_getStorageAt-3NgDSjye.js} +1 -1
- package/assets/eth_getTransactionCount-DTwTbWKm.js +1 -0
- package/assets/{ethereum-DymVJL-H.js → ethereum-BT-rALS5.js} +1 -1
- package/assets/{ethers-BxoDGoYp.js → ethers-DbXGgxrh.js} +4 -4
- package/assets/{extractIPFS-CzVhnm6X.js → extractIPFS-CHWW_nBy.js} +1 -1
- package/assets/{features-Ds8qi8e0.js → features-HqCYMdFT.js} +1 -1
- package/assets/{fetchTokenMetadata-DyKFRjaS.js → fetchTokenMetadata-CSZ3XllS.js} +2 -2
- package/assets/generateUtilityClasses-68H80U2m.js +9 -0
- package/assets/get-ecosystem-wallet-info-CVCd4sza.js +1 -0
- package/assets/{getBalance-CPtlpRd8.js → getBalance-yfGcZGGj.js} +2 -2
- package/assets/{getInstalledModules-jCIwW2OV.js → getInstalledModules-DnAA6-I4.js} +1 -1
- package/assets/{getNFT-17KjVI3E.js → getNFT-BXj9XpaA.js} +1 -1
- package/assets/{getNFT-D71TQwqJ.js → getNFT-vDogDybV.js} +2 -2
- package/assets/{hashTypedData-22Nm0csw.js → hashTypedData-2doJmUR6.js} +1 -1
- package/assets/{hashTypedData-BsHEgjBY.js → hashTypedData-DaDegzDr.js} +1 -1
- package/assets/{import-CcQ3dh0l.js → import-BEVHrqgg.js} +1 -1
- package/assets/{in-app-wallet-calls-t-sxRkB2.js → in-app-wallet-calls-C42NJm8M.js} +1 -1
- package/assets/{index-1QyqBynD.js → index-0AAKBJxH.js} +2 -2
- package/assets/{index-B6FpnCqN.js → index-57ur9orY.js} +1 -1
- package/assets/{index-BW0vL61p.js → index-9ge8OUDw.js} +1 -1
- package/assets/{index-CBg9-0F-.js → index-B4P5FnkC.js} +1 -1
- package/assets/{index-CwQ4WZHg.js → index-B4bWwh_Y.js} +1 -1
- package/assets/{index-BU0oqH1v.js → index-B9SF-7gB.js} +1 -1
- package/assets/{index-DvOTdACV.js → index-BG6CN-s7.js} +1 -1
- package/assets/{index-DLUxEVXI.js → index-BREuBgY2.js} +1 -1
- package/assets/{index-DLXCkPW8.js → index-BVLuv2om.js} +1 -1
- package/assets/{index-BW4u89-l.js → index-BYlyICGz.js} +1 -1
- package/assets/{index-Cx5vMrtt.js → index-BaKOKooW.js} +1 -1
- package/assets/{index-CwbrgNKr.js → index-BeD0ry83.js} +1 -1
- package/assets/{index-BSHqxnWX.js → index-BhzLlo1O.js} +1 -1
- package/assets/{index-Cm04cZlI.js → index-BlH2P_nz.js} +1 -1
- package/assets/{index-VI4KjHoC.js → index-Blv3Wwvz.js} +1 -1
- package/assets/{index-COCOMkF6.js → index-Bme3obuL.js} +1 -1
- package/assets/{index-heQt9VsF.js → index-BqkfR3e1.js} +3 -3
- package/assets/{index-BitTsk-8.js → index-BuPAm941.js} +1 -1
- package/assets/{index-DEh0LiFK.js → index-Bx92bjWv.js} +1 -1
- package/assets/{index-sHr-hGKY.js → index-C0zr56Qh.js} +1 -1
- package/assets/{index-BHoDUeMz.js → index-C9WCBveU.js} +1 -1
- package/assets/index-CB1SUuBM.js +74 -0
- package/assets/{index-DuzIppyc.js → index-CDrsSYcA.js} +1 -1
- package/assets/{index-C9iIs3VH.js → index-CORb4fda.js} +1 -1
- package/assets/{index-jHxTGJdg.js → index-COwpweqw.js} +1 -1
- package/assets/{index-iwu8tO4Z.js → index-CRHmObgS.js} +1 -1
- package/assets/{index-DXqcXSOs.js → index-CRiIcVpU.js} +1 -1
- package/assets/{index-D1Hm6q3z.js → index-CX7ndFAa.js} +1 -1
- package/assets/{index-Bvp-iyve.js → index-CbVF1v4U.js} +1 -1
- package/assets/{index-Bw9N_kF_.js → index-CeSnh-cF.js} +1 -1
- package/assets/{index-CfzTflc3.js → index-Chh2iu1U.js} +1 -1
- package/assets/{index-DYPF9UsI.js → index-CnBS8kzN.js} +1 -1
- package/assets/{index-DHKMIodB.js → index-CtFbxl_y.js} +2 -2
- package/assets/{index--aCrl8ym.js → index-Cuo0mhpq.js} +1 -1
- package/assets/{index-wg2QrcW5.js → index-D7XhLBQ-.js} +1 -1
- package/assets/{index-Cf02sP_a.js → index-D8ALyBMQ.js} +1 -1
- package/assets/{index-CNbUbmHm.js → index-DFAtvbN5.js} +1 -1
- package/assets/{index-BopweyiH.js → index-DFB_iIuz.js} +1 -1
- package/assets/{index-BwNwknii.js → index-DKewLOZ7.js} +1 -1
- package/assets/{index-RrpD-c5G.js → index-DXbLCZL4.js} +1 -1
- package/assets/{index-BRXlFZYr.js → index-DiHK-ypD.js} +1 -1
- package/assets/{index-BuiY2b5V.js → index-DiX8jfOz.js} +1 -1
- package/assets/{index-CtdBxwRn.js → index-Dn9Pxudm.js} +1 -1
- package/assets/{index-Ck94hhTo.js → index-DprMjbvv.js} +1 -1
- package/assets/{index-o5cecGpl.js → index-Dw8xiBHu.js} +1 -1
- package/assets/{index-DpzUBtKq.js → index-DyGFvyMP.js} +3 -3
- package/assets/{index-xXtPh54p.js → index-POoM1fB4.js} +2 -2
- package/assets/{index-C4O-XKSm.js → index-RnHbMsps.js} +1 -1
- package/assets/{index-VE0M5Mr2.js → index-SBOBxQlc.js} +1 -1
- package/assets/{index-D2i3ctoC.js → index-VT1wNEWr.js} +1 -1
- package/assets/{index-D-XWUY--.js → index-ZNqzZwnz.js} +1 -1
- package/assets/{index-BwWuCRvy.js → index-aTH_VwVx.js} +1 -1
- package/assets/{index-BwKjjXxD.js → index-e_7-B1ow.js} +1 -1
- package/assets/{index-DT36RcnA.js → index-j3O81hit.js} +2 -2
- package/assets/{index-DxHbUIT4.js → index-jaAvXNFF.js} +1 -1
- package/assets/{index.es-2PzIAt_1.js → index.es-BCgpKnhB.js} +1 -1
- package/assets/{index.es-DdKll-wt.js → index.es-DLOLLwhc.js} +1 -1
- package/assets/{index.es-DEttXaJp.js → index.es-uQUz0uPi.js} +4 -4
- package/assets/{localBatchGatewayRequest-C-g14orC.js → localBatchGatewayRequest-DCKNeCfz.js} +1 -1
- package/assets/{mana-rate-DeQxAZWf.js → mana-rate-Boaa1HMt.js} +1 -1
- package/assets/{native-Df5jPT-i.js → native-BJmDxbqB.js} +1 -1
- package/assets/network-C9miAzGt.js +1 -0
- package/assets/{networks-DQ_uJOW0.js → networks-D0pJRUuY.js} +1 -1
- package/assets/{onramp-Fj0QTWoK.js → onramp-pQdY_9aS.js} +1 -1
- package/assets/{openzeppelin-C05m57x-.js → openzeppelin-diCOMn_P.js} +1 -1
- package/assets/{ownerOf-iDx9Bfmb.js → ownerOf-CFYID7oD.js} +1 -1
- package/assets/{parseNft-BbqeSraZ.js → parseNft-CmySAMrV.js} +2 -2
- package/assets/{parseSignature-DecPFzAG.js → parseSignature-bCWekXGm.js} +1 -1
- package/assets/{parseSignature-BpHf1ckR.js → parseSignature-t4gfdMWw.js} +3 -3
- package/assets/{pay-with-exchange-DcOvi8il.js → pay-with-exchange-DbEbHfpX.js} +1 -1
- package/assets/{qr-overlay-C42zumtd.js → qr-overlay-rU0bVDln.js} +1 -1
- package/assets/{receive-CBWc5sHm.js → receive-C22Daqnd.js} +1 -1
- package/assets/{resolveImplementation-Dfnpuqfy.js → resolveImplementation-DynwR0lM.js} +1 -1
- package/assets/{rpc-CpwULMGN.js → rpc-C7dS7ng8.js} +1 -1
- package/assets/{secp256k1-yeQJ89oh.js → secp256k1-DcKiXZY-.js} +1 -1
- package/assets/{secp256k1-BnqRXIY8.js → secp256k1-DoZorCJw.js} +1 -1
- package/assets/{secp256k1-C6oufD3A.js → secp256k1-DznyzAlp.js} +1 -1
- package/assets/{send-BkoLHxtn.js → send-DYQ25bRQ.js} +1 -1
- package/assets/{send-batch-transaction-BSK7bmqA.js → send-batch-transaction-EluRyTwS.js} +1 -1
- package/assets/{send-eip712-transaction-Dn-wh_B2.js → send-eip712-transaction-DTR4eE0C.js} +2 -2
- package/assets/{send-gasless-transaction-Ca3gem0_.js → send-gasless-transaction-oXMw6C-s.js} +2 -2
- package/assets/{sendRawTransaction-Cs49dy2x.js → sendRawTransaction-BU7jVR59.js} +3 -3
- package/assets/{serializeTransaction-KiaMgBPL.js → serializeTransaction-yZGwGRzm.js} +1 -1
- package/assets/{session-proposal-vzIJwf7D.js → session-proposal-BwNkG3_v.js} +1 -1
- package/assets/{session-request-BEIJZaAK.js → session-request-CBPwxxaY.js} +2 -2
- package/assets/{sha256-BiN04lIc.js → sha256-Dh2CN2ka.js} +1 -1
- package/assets/{signing-BwGscoGI.js → signing-GS-zzaze.js} +5 -5
- package/assets/{socials-CkBpzoYO.js → socials-D941TnMp.js} +1 -1
- package/assets/{swaps-DQ5hCG4G.js → swaps-5Z0exdjC.js} +1 -1
- package/assets/{thirdweb-DGSIWchy.js → thirdweb-BhSo-VaG.js} +3 -3
- package/assets/{totalSupply--7Gy53iL.js → totalSupply-Dn2mGU3K.js} +1 -1
- package/assets/{transactionReceipt-BqWcSLOT.js → transactionReceipt-DXzK83SA.js} +1 -1
- package/assets/{transactions-BLMRTJRj.js → transactions-BB8fY56R.js} +1 -1
- package/assets/{useInfiniteGrid-DPeVNTF0.js → useInfiniteGrid-BdBxLsy8.js} +1 -1
- package/assets/{utils-CtSpY5KY.js → utils-BZTXwsyT.js} +1 -1
- package/assets/{verifyHash-BbyYMDj2.js → verifyHash-DcUfBKkE.js} +1 -1
- package/assets/{w3m-modal-BO7VJd_F.js → w3m-modal-B_8aqWPZ.js} +1 -1
- package/assets/{w3m-modal-CU9GrhG1.js → w3m-modal-C2IuKDb_.js} +1 -1
- package/assets/{wait-for-tx-receipt-B7zpFNTs.js → wait-for-tx-receipt-DYUfif7J.js} +1 -1
- package/assets/{wallet-kind-I50FvVNZ.js → wallet-kind-I4wsazAy.js} +1 -1
- package/assets/{wallets-3KLAORfj.js → wallets-BCm8dv3V.js} +6 -6
- package/assets/{web-connector-n3P_8fE1.js → web-connector-PEOwt9A9.js} +3 -3
- package/assets/{writeContract-CuPR4V-g.js → writeContract-KYMfI9ra.js} +1 -1
- package/assets/{zora-sepolia-9dBUmZVP.js → zora-sepolia-BF9oR096.js} +1 -1
- package/assets/{zoraTestnet-lp6nJymD.js → zoraTestnet-DOA24Pam.js} +1 -1
- package/index.html +8 -8
- package/package.json +2 -2
- package/assets/decimals-B0WxCOWV.js +0 -1
- package/assets/eth_estimateGas-BeOmUDSu.js +0 -1
- package/assets/eth_getTransactionCount-CHvlH_2Q.js +0 -1
- package/assets/generateUtilityClasses-sji8XAMf.js +0 -16
- package/assets/get-ecosystem-wallet-info-DVtQmxfc.js +0 -1
- package/assets/index-BHOQ04tl.js +0 -42
- package/assets/network-Cc_j76mj.js +0 -1
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/index-D8ALyBMQ.js","assets/react-E8ng6RF2.js","assets/network-C9miAzGt.js","assets/SvgIcon-D2AubmSV.js","assets/generateUtilityClasses-68H80U2m.js","assets/ethers-DbXGgxrh.js","assets/index-POoM1fB4.js","assets/index-CeSnh-cF.js","assets/index-B5lBgsVo.js","assets/CircularProgress-ePyo1lbd.js","assets/TradeService-BK-xq9ht.js","assets/index-DKewLOZ7.js","assets/Assets-FMrABFH_.js","assets/SkeletonCards-yV2mi4oc.js","assets/LoadMore-DB6TwvRe.js","assets/useInfiniteGrid-BdBxLsy8.js","assets/Market-Cr-J1I9u.js","assets/mana-rate-Boaa1HMt.js","assets/buy-_5Wro-EH.js","assets/buy-gasless-Da6cXp5w.js","assets/ItemDetail-Sn2B-MA3.js","assets/ItemDetail-yNwYjl_l.css","assets/Collection-DJjtkyI0.js","assets/collection-Dj1PGTaS.js","assets/collection-Ds5shVfK.css","assets/Creator-Cd6xMnQk.js","assets/MyAssets-CpoF2iAy.js","assets/import-BEVHrqgg.js","assets/wallet-kind-I4wsazAy.js","assets/MyAssets-BjiqkBzd.css","assets/MyFavorites-b3vHnYMr.js","assets/MyPurchases-DVXmppAu.js","assets/ImportListings-CXvHkADP.js","assets/ImportListings-Cdx3om4x.css","assets/Cart-COyAPJn1.js","assets/GetCredits-BC7Z51_v.js","assets/Success-CNdczbFT.js","assets/NotFound-BK3mhtdy.js"])))=>i.map(i=>d[i]);
|
|
2
|
+
var dM=Object.defineProperty;var M_=e=>{throw TypeError(e)};var fM=(e,t,r)=>t in e?dM(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Cn=(e,t,r)=>fM(e,typeof t!="symbol"?t+"":t,r),kl=(e,t,r)=>t.has(e)||M_("Cannot "+r);var oe=(e,t,r)=>(kl(e,t,"read from private field"),r?r.call(e):t.get(e)),Ge=(e,t,r)=>t.has(e)?M_("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),De=(e,t,r,n)=>(kl(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),tt=(e,t,r)=>(kl(e,t,"access private method"),r);var Eu=(e,t,r,n)=>({set _(i){De(e,t,i,r)},get _(){return oe(e,t,n)}});import{r as Ye,j as fe,l as pw,g as mw,R as hw,c as vy,L as Gc,b as ug,m as Dn,d as pM,n as mM,o as sr,N as hM,p as yM,B as gM}from"./react-E8ng6RF2.js";import{g as zc,p as Uc,W as _M,m as EM,h as C_,f as yw}from"./ethers-DbXGgxrh.js";(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const a of i)if(a.type==="childList")for(const s of a.addedNodes)s.tagName==="LINK"&&s.rel==="modulepreload"&&n(s)}).observe(document,{childList:!0,subtree:!0});function r(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(i){if(i.ep)return;i.ep=!0;const a=r(i);fetch(i.href,a)}})();var yo=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},ji,Bn,Aa,nw,vM=(nw=class extends yo{constructor(){super();Ge(this,ji);Ge(this,Bn);Ge(this,Aa);De(this,Aa,t=>{if(typeof window<"u"&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){oe(this,Bn)||this.setEventListener(oe(this,Aa))}onUnsubscribe(){var t;this.hasListeners()||((t=oe(this,Bn))==null||t.call(this),De(this,Bn,void 0))}setEventListener(t){var r;De(this,Aa,t),(r=oe(this,Bn))==null||r.call(this),De(this,Bn,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){oe(this,ji)!==t&&(De(this,ji,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof oe(this,ji)=="boolean"?oe(this,ji):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ji=new WeakMap,Bn=new WeakMap,Aa=new WeakMap,nw),cg=new vM,bM={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},Un,og,iw,TM=(iw=class{constructor(){Ge(this,Un,bM);Ge(this,og,!1)}setTimeoutProvider(e){De(this,Un,e)}setTimeout(e,t){return oe(this,Un).setTimeout(e,t)}clearTimeout(e){oe(this,Un).clearTimeout(e)}setInterval(e,t){return oe(this,Un).setInterval(e,t)}clearInterval(e){oe(this,Un).clearInterval(e)}},Un=new WeakMap,og=new WeakMap,iw),Di=new TM;function SM(e){setTimeout(e,0)}var IM=typeof window>"u"||"Deno"in globalThis;function hr(){}function RM(e,t){return typeof e=="function"?e(t):e}function by(e){return typeof e=="number"&&e>=0&&e!==1/0}function gw(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Yn(e,t){return typeof e=="function"?e(t):e}function Sr(e,t){return typeof e=="function"?e(t):e}function D_(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:s,stale:o}=e;if(s){if(n){if(t.queryHash!==lg(s,t.options))return!1}else if(!eo(t.queryKey,s))return!1}if(r!=="all"){const u=t.isActive();if(r==="active"&&!u||r==="inactive"&&u)return!1}return!(typeof o=="boolean"&&t.isStale()!==o||i&&i!==t.state.fetchStatus||a&&!a(t))}function j_(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(xs(t.options.mutationKey)!==xs(a))return!1}else if(!eo(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function lg(e,t){return((t==null?void 0:t.queryKeyHashFn)||xs)(e)}function xs(e){return JSON.stringify(e,(t,r)=>Sy(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function eo(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>eo(e[r],t[r])):!1}var AM=Object.prototype.hasOwnProperty;function _w(e,t,r=0){if(e===t)return e;if(r>500)return t;const n=$_(e)&&$_(t);if(!n&&!(Sy(e)&&Sy(t)))return t;const a=(n?e:Object.keys(e)).length,s=n?t:Object.keys(t),o=s.length,u=n?new Array(o):{};let l=0;for(let c=0;c<o;c++){const d=n?c:s[c],m=e[d],p=t[d];if(m===p){u[d]=m,(n?c<a:AM.call(e,d))&&l++;continue}if(m===null||p===null||typeof m!="object"||typeof p!="object"){u[d]=p;continue}const E=_w(m,p,r+1);u[d]=E,E===m&&l++}return a===o&&l===a?e:u}function Ty(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const r in e)if(e[r]!==t[r])return!1;return!0}function $_(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Sy(e){if(!L_(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!L_(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function L_(e){return Object.prototype.toString.call(e)==="[object Object]"}function wM(e){return new Promise(t=>{Di.setTimeout(t,e)})}function Iy(e,t,r){return typeof r.structuralSharing=="function"?r.structuralSharing(e,t):r.structuralSharing!==!1?_w(e,t):t}function C3(e){return e}function OM(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function NM(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var dg=Symbol();function Ew(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===dg?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function vw(e,t){return typeof e=="function"?e(...t):!!e}function PM(e,t,r){let n=!1,i;return Object.defineProperty(e,"signal",{enumerable:!0,get:()=>(i??(i=t()),n||(n=!0,i.aborted?r():i.addEventListener("abort",r,{once:!0})),i)}),e}var to=(()=>{let e=()=>IM;return{isServer(){return e()},setIsServer(t){e=t}}})();function Ry(){let e,t;const r=new Promise((i,a)=>{e=i,t=a});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),e(i)},r.reject=i=>{n({status:"rejected",reason:i}),t(i)},r}var MM=SM;function CM(){let e=[],t=0,r=o=>{o()},n=o=>{o()},i=MM;const a=o=>{t?e.push(o):i(()=>{r(o)})},s=()=>{const o=e;e=[],o.length&&i(()=>{n(()=>{o.forEach(u=>{r(u)})})})};return{batch:o=>{let u;t++;try{u=o()}finally{t--,t||s()}return u},batchCalls:o=>(...u)=>{a(()=>{o(...u)})},schedule:a,setNotifyFunction:o=>{r=o},setBatchNotifyFunction:o=>{n=o},setScheduler:o=>{i=o}}}var Kt=CM(),wa,Fn,Oa,aw,DM=(aw=class extends yo{constructor(){super();Ge(this,wa,!0);Ge(this,Fn);Ge(this,Oa);De(this,Oa,t=>{if(typeof window<"u"&&window.addEventListener){const r=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){oe(this,Fn)||this.setEventListener(oe(this,Oa))}onUnsubscribe(){var t;this.hasListeners()||((t=oe(this,Fn))==null||t.call(this),De(this,Fn,void 0))}setEventListener(t){var r;De(this,Oa,t),(r=oe(this,Fn))==null||r.call(this),De(this,Fn,t(this.setOnline.bind(this)))}setOnline(t){oe(this,wa)!==t&&(De(this,wa,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return oe(this,wa)}},wa=new WeakMap,Fn=new WeakMap,Oa=new WeakMap,aw),Wc=new DM;function jM(e){return Math.min(1e3*2**e,3e4)}function bw(e){return(e??"online")==="online"?Wc.isOnline():!0}var Ay=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Tw(e){let t=!1,r=0,n;const i=Ry(),a=()=>i.status!=="pending",s=A=>{var R;if(!a()){const O=new Ay(A);m(O),(R=e.onCancel)==null||R.call(e,O)}},o=()=>{t=!0},u=()=>{t=!1},l=()=>cg.isFocused()&&(e.networkMode==="always"||Wc.isOnline())&&e.canRun(),c=()=>bw(e.networkMode)&&e.canRun(),d=A=>{a()||(n==null||n(),i.resolve(A))},m=A=>{a()||(n==null||n(),i.reject(A))},p=()=>new Promise(A=>{var R;n=O=>{(a()||l())&&A(O)},(R=e.onPause)==null||R.call(e)}).then(()=>{var A;n=void 0,a()||(A=e.onContinue)==null||A.call(e)}),E=()=>{if(a())return;let A;const R=r===0?e.initialPromise:void 0;try{A=R??e.fn()}catch(O){A=Promise.reject(O)}Promise.resolve(A).then(d).catch(O=>{var T;if(a())return;const f=e.retry??(to.isServer()?0:3),v=e.retryDelay??jM,b=typeof v=="function"?v(r,O):v,h=f===!0||typeof f=="number"&&r<f||typeof f=="function"&&f(r,O);if(t||!h){m(O);return}r++,(T=e.onFail)==null||T.call(e,r,O),wM(b).then(()=>l()?void 0:p()).then(()=>{t?m(O):E()})})};return{promise:i,status:()=>i.status,cancel:s,continue:()=>(n==null||n(),i),cancelRetry:o,continueRetry:u,canStart:c,start:()=>(c()?E():p().then(E),i)}}var $i,sw,Sw=(sw=class{constructor(){Ge(this,$i)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),by(this.gcTime)&&De(this,$i,Di.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(to.isServer()?1/0:300*1e3))}clearGcTimeout(){oe(this,$i)!==void 0&&(Di.clearTimeout(oe(this,$i)),De(this,$i,void 0))}},$i=new WeakMap,sw);function $M(e){return{onFetch:(t,r)=>{var c,d,m,p,E;const n=t.options,i=(m=(d=(c=t.fetchOptions)==null?void 0:c.meta)==null?void 0:d.fetchMore)==null?void 0:m.direction,a=((p=t.state.data)==null?void 0:p.pages)||[],s=((E=t.state.data)==null?void 0:E.pageParams)||[];let o={pages:[],pageParams:[]},u=0;const l=async()=>{let A=!1;const R=v=>{PM(v,()=>t.signal,()=>A=!0)},O=Ew(t.options,t.fetchOptions),f=async(v,b,h)=>{if(A)return Promise.reject(t.signal.reason);if(b==null&&v.pages.length)return Promise.resolve(v);const w=(()=>{const K={client:t.client,queryKey:t.queryKey,pageParam:b,direction:h?"backward":"forward",meta:t.options.meta};return R(K),K})(),P=await O(w),{maxPages:B}=t.options,J=h?NM:OM;return{pages:J(v.pages,P,B),pageParams:J(v.pageParams,b,B)}};if(i&&a.length){const v=i==="backward",b=v?Iw:wy,h={pages:a,pageParams:s},T=b(n,h);o=await f(h,T,v)}else{const v=e??a.length;do{const b=u===0?s[0]??n.initialPageParam:wy(n,o);if(u>0&&b==null)break;o=await f(o,b),u++}while(u<v)}return o};t.options.persister?t.fetchFn=()=>{var A,R;return(R=(A=t.options).persister)==null?void 0:R.call(A,l,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=l}}}function wy(e,{pages:t,pageParams:r}){const n=t.length-1;return t.length>0?e.getNextPageParam(t[n],t,r[n],r):void 0}function Iw(e,{pages:t,pageParams:r}){var n;return t.length>0?(n=e.getPreviousPageParam)==null?void 0:n.call(e,t[0],t,r[0],r):void 0}function D3(e,t){return t?wy(e,t)!=null:!1}function j3(e,t){return!t||!e.getPreviousPageParam?!1:Iw(e,t)!=null}var Na,Li,Pa,Rr,qi,Ht,lo,ki,Tr,Rw,bn,ow,LM=(ow=class extends Sw{constructor(t){super();Ge(this,Tr);Ge(this,Na);Ge(this,Li);Ge(this,Pa);Ge(this,Rr);Ge(this,qi);Ge(this,Ht);Ge(this,lo);Ge(this,ki);De(this,ki,!1),De(this,lo,t.defaultOptions),this.setOptions(t.options),this.observers=[],De(this,qi,t.client),De(this,Rr,oe(this,qi).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,De(this,Li,k_(this.options)),this.state=t.state??oe(this,Li),this.scheduleGc()}get meta(){return this.options.meta}get queryType(){return oe(this,Na)}get promise(){var t;return(t=oe(this,Ht))==null?void 0:t.promise}setOptions(t){if(this.options={...oe(this,lo),...t},t!=null&&t._type&&De(this,Na,t._type),this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const r=k_(this.options);r.data!==void 0&&(this.setState(q_(r.data,r.dataUpdatedAt)),De(this,Li,r))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&oe(this,Rr).remove(this)}setData(t,r){const n=Iy(this.state.data,t,this.options);return tt(this,Tr,bn).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t){tt(this,Tr,bn).call(this,{type:"setState",state:t})}cancel(t){var n,i;const r=(n=oe(this,Ht))==null?void 0:n.promise;return(i=oe(this,Ht))==null||i.cancel(t),r?r.then(hr).catch(hr):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}get resetState(){return oe(this,Li)}reset(){this.destroy(),this.setState(this.resetState)}isActive(){return this.observers.some(t=>Sr(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===dg||!this.isFetched()}isFetched(){return this.state.dataUpdateCount+this.state.errorUpdateCount>0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Yn(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!gw(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=oe(this,Ht))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=oe(this,Ht))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),oe(this,Rr).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(oe(this,Ht)&&(oe(this,ki)||tt(this,Tr,Rw).call(this)?oe(this,Ht).cancel({revert:!0}):oe(this,Ht).cancelRetry()),this.scheduleGc()),oe(this,Rr).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||tt(this,Tr,bn).call(this,{type:"invalidate"})}async fetch(t,r){var l,c,d,m,p,E,A,R,O,f,v;if(this.state.fetchStatus!=="idle"&&((l=oe(this,Ht))==null?void 0:l.status())!=="rejected"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(oe(this,Ht))return oe(this,Ht).continueRetry(),oe(this,Ht).promise}if(t&&this.setOptions(t),!this.options.queryFn){const b=this.observers.find(h=>h.options.queryFn);b&&this.setOptions(b.options)}const n=new AbortController,i=b=>{Object.defineProperty(b,"signal",{enumerable:!0,get:()=>(De(this,ki,!0),n.signal)})},a=()=>{const b=Ew(this.options,r),T=(()=>{const w={client:oe(this,qi),queryKey:this.queryKey,meta:this.meta};return i(w),w})();return De(this,ki,!1),this.options.persister?this.options.persister(b,T,this):b(T)},o=(()=>{const b={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:oe(this,qi),state:this.state,fetchFn:a};return i(b),b})(),u=oe(this,Na)==="infinite"?$M(this.options.pages):this.options.behavior;u==null||u.onFetch(o,this),De(this,Pa,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=o.fetchOptions)==null?void 0:c.meta))&&tt(this,Tr,bn).call(this,{type:"fetch",meta:(d=o.fetchOptions)==null?void 0:d.meta}),De(this,Ht,Tw({initialPromise:r==null?void 0:r.initialPromise,fn:o.fetchFn,onCancel:b=>{b instanceof Ay&&b.revert&&this.setState({...oe(this,Pa),fetchStatus:"idle"}),n.abort()},onFail:(b,h)=>{tt(this,Tr,bn).call(this,{type:"failed",failureCount:b,error:h})},onPause:()=>{tt(this,Tr,bn).call(this,{type:"pause"})},onContinue:()=>{tt(this,Tr,bn).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0}));try{const b=await oe(this,Ht).start();if(b===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(b),(p=(m=oe(this,Rr).config).onSuccess)==null||p.call(m,b,this),(A=(E=oe(this,Rr).config).onSettled)==null||A.call(E,b,this.state.error,this),b}catch(b){if(b instanceof Ay){if(b.silent)return oe(this,Ht).promise;if(b.revert){if(this.state.data===void 0)throw b;return this.state.data}}throw tt(this,Tr,bn).call(this,{type:"error",error:b}),(O=(R=oe(this,Rr).config).onError)==null||O.call(R,b,this),(v=(f=oe(this,Rr).config).onSettled)==null||v.call(f,this.state.data,b,this),b}finally{this.scheduleGc()}}},Na=new WeakMap,Li=new WeakMap,Pa=new WeakMap,Rr=new WeakMap,qi=new WeakMap,Ht=new WeakMap,lo=new WeakMap,ki=new WeakMap,Tr=new WeakSet,Rw=function(){return this.state.fetchStatus==="paused"&&this.state.status==="pending"},bn=function(t){const r=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...Aw(n.data,this.options),fetchMeta:t.meta??null};case"success":const i={...n,...q_(t.data,t.dataUpdatedAt),dataUpdateCount:n.dataUpdateCount+1,...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return De(this,Pa,t.manual?i:void 0),i;case"error":const a=t.error;return{...n,error:a,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:a,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...t.state}}};this.state=r(this.state),Kt.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),oe(this,Rr).notify({query:this,type:"updated",action:t})})},ow);function Aw(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:bw(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function q_(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:"success"}}function k_(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var mr,it,fo,ur,Bi,Ma,In,Vn,po,Ca,Da,Ui,Fi,Hn,ja,ht,Rs,Oy,Ny,Py,My,Cy,Dy,jy,ww,uw,qM=(uw=class extends yo{constructor(t,r){super();Ge(this,ht);Ge(this,mr);Ge(this,it);Ge(this,fo);Ge(this,ur);Ge(this,Bi);Ge(this,Ma);Ge(this,In);Ge(this,Vn);Ge(this,po);Ge(this,Ca);Ge(this,Da);Ge(this,Ui);Ge(this,Fi);Ge(this,Hn);Ge(this,ja,new Set);this.options=r,De(this,mr,t),De(this,Vn,null),De(this,In,Ry()),this.bindMethods(),this.setOptions(r)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(oe(this,it).addObserver(this),B_(oe(this,it),this.options)?tt(this,ht,Rs).call(this):this.updateResult(),tt(this,ht,My).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return $y(oe(this,it),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return $y(oe(this,it),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,tt(this,ht,Cy).call(this),tt(this,ht,Dy).call(this),oe(this,it).removeObserver(this)}setOptions(t){const r=this.options,n=oe(this,it);if(this.options=oe(this,mr).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Sr(this.options.enabled,oe(this,it))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");tt(this,ht,jy).call(this),oe(this,it).setOptions(this.options),r._defaulted&&!Ty(this.options,r)&&oe(this,mr).getQueryCache().notify({type:"observerOptionsUpdated",query:oe(this,it),observer:this});const i=this.hasListeners();i&&U_(oe(this,it),n,this.options,r)&&tt(this,ht,Rs).call(this),this.updateResult(),i&&(oe(this,it)!==n||Sr(this.options.enabled,oe(this,it))!==Sr(r.enabled,oe(this,it))||Yn(this.options.staleTime,oe(this,it))!==Yn(r.staleTime,oe(this,it)))&&tt(this,ht,Oy).call(this);const a=tt(this,ht,Ny).call(this);i&&(oe(this,it)!==n||Sr(this.options.enabled,oe(this,it))!==Sr(r.enabled,oe(this,it))||a!==oe(this,Hn))&&tt(this,ht,Py).call(this,a)}getOptimisticResult(t){const r=oe(this,mr).getQueryCache().build(oe(this,mr),t),n=this.createResult(r,t);return BM(this,n)&&(De(this,ur,n),De(this,Ma,this.options),De(this,Bi,oe(this,it).state)),n}getCurrentResult(){return oe(this,ur)}trackResult(t,r){return new Proxy(t,{get:(n,i)=>(this.trackProp(i),r==null||r(i),i==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&oe(this,In).status==="pending"&&oe(this,In).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(n,i))})}trackProp(t){oe(this,ja).add(t)}getCurrentQuery(){return oe(this,it)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const r=oe(this,mr).defaultQueryOptions(t),n=oe(this,mr).getQueryCache().build(oe(this,mr),r);return n.fetch().then(()=>this.createResult(n,r))}fetch(t){return tt(this,ht,Rs).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),oe(this,ur)))}createResult(t,r){var B;const n=oe(this,it),i=this.options,a=oe(this,ur),s=oe(this,Bi),o=oe(this,Ma),l=t!==n?t.state:oe(this,fo),{state:c}=t;let d={...c},m=!1,p;if(r._optimisticResults){const J=this.hasListeners(),K=!J&&B_(t,r),z=J&&U_(t,n,r,i);(K||z)&&(d={...d,...Aw(c.data,t.options)}),r._optimisticResults==="isRestoring"&&(d.fetchStatus="idle")}let{error:E,errorUpdatedAt:A,status:R}=d;p=d.data;let O=!1;if(r.placeholderData!==void 0&&p===void 0&&R==="pending"){let J;a!=null&&a.isPlaceholderData&&r.placeholderData===(o==null?void 0:o.placeholderData)?(J=a.data,O=!0):J=typeof r.placeholderData=="function"?r.placeholderData((B=oe(this,Da))==null?void 0:B.state.data,oe(this,Da)):r.placeholderData,J!==void 0&&(R="success",p=Iy(a==null?void 0:a.data,J,r),m=!0)}if(r.select&&p!==void 0&&!O)if(a&&p===(s==null?void 0:s.data)&&r.select===oe(this,po))p=oe(this,Ca);else try{De(this,po,r.select),p=r.select(p),p=Iy(a==null?void 0:a.data,p,r),De(this,Ca,p),De(this,Vn,null)}catch(J){De(this,Vn,J)}oe(this,Vn)&&(E=oe(this,Vn),p=oe(this,Ca),A=Date.now(),R="error");const f=d.fetchStatus==="fetching",v=R==="pending",b=R==="error",h=v&&f,T=p!==void 0,P={status:R,fetchStatus:d.fetchStatus,isPending:v,isSuccess:R==="success",isError:b,isInitialLoading:h,isLoading:h,data:p,dataUpdatedAt:d.dataUpdatedAt,error:E,errorUpdatedAt:A,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:t.isFetched(),isFetchedAfterMount:d.dataUpdateCount>l.dataUpdateCount||d.errorUpdateCount>l.errorUpdateCount,isFetching:f,isRefetching:f&&!v,isLoadingError:b&&!T,isPaused:d.fetchStatus==="paused",isPlaceholderData:m,isRefetchError:b&&T,isStale:fg(t,r),refetch:this.refetch,promise:oe(this,In),isEnabled:Sr(r.enabled,t)!==!1};if(this.options.experimental_prefetchInRender){const J=P.data!==void 0,K=P.status==="error"&&!J,z=ue=>{K?ue.reject(P.error):J&&ue.resolve(P.data)},U=()=>{const ue=De(this,In,P.promise=Ry());z(ue)},F=oe(this,In);switch(F.status){case"pending":t.queryHash===n.queryHash&&z(F);break;case"fulfilled":(K||P.data!==F.value)&&U();break;case"rejected":(!K||P.error!==F.reason)&&U();break}}return P}updateResult(){const t=oe(this,ur),r=this.createResult(oe(this,it),this.options);if(De(this,Bi,oe(this,it).state),De(this,Ma,this.options),oe(this,Bi).data!==void 0&&De(this,Da,oe(this,it)),Ty(r,t))return;De(this,ur,r);const n=()=>{if(!t)return!0;const{notifyOnChangeProps:i}=this.options,a=typeof i=="function"?i():i;if(a==="all"||!a&&!oe(this,ja).size)return!0;const s=new Set(a??oe(this,ja));return this.options.throwOnError&&s.add("error"),Object.keys(oe(this,ur)).some(o=>{const u=o;return oe(this,ur)[u]!==t[u]&&s.has(u)})};tt(this,ht,ww).call(this,{listeners:n()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&tt(this,ht,My).call(this)}},mr=new WeakMap,it=new WeakMap,fo=new WeakMap,ur=new WeakMap,Bi=new WeakMap,Ma=new WeakMap,In=new WeakMap,Vn=new WeakMap,po=new WeakMap,Ca=new WeakMap,Da=new WeakMap,Ui=new WeakMap,Fi=new WeakMap,Hn=new WeakMap,ja=new WeakMap,ht=new WeakSet,Rs=function(t){tt(this,ht,jy).call(this);let r=oe(this,it).fetch(this.options,t);return t!=null&&t.throwOnError||(r=r.catch(hr)),r},Oy=function(){tt(this,ht,Cy).call(this);const t=Yn(this.options.staleTime,oe(this,it));if(to.isServer()||oe(this,ur).isStale||!by(t))return;const n=gw(oe(this,ur).dataUpdatedAt,t)+1;De(this,Ui,Di.setTimeout(()=>{oe(this,ur).isStale||this.updateResult()},n))},Ny=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(oe(this,it)):this.options.refetchInterval)??!1},Py=function(t){tt(this,ht,Dy).call(this),De(this,Hn,t),!(to.isServer()||Sr(this.options.enabled,oe(this,it))===!1||!by(oe(this,Hn))||oe(this,Hn)===0)&&De(this,Fi,Di.setInterval(()=>{(this.options.refetchIntervalInBackground||cg.isFocused())&&tt(this,ht,Rs).call(this)},oe(this,Hn)))},My=function(){tt(this,ht,Oy).call(this),tt(this,ht,Py).call(this,tt(this,ht,Ny).call(this))},Cy=function(){oe(this,Ui)!==void 0&&(Di.clearTimeout(oe(this,Ui)),De(this,Ui,void 0))},Dy=function(){oe(this,Fi)!==void 0&&(Di.clearInterval(oe(this,Fi)),De(this,Fi,void 0))},jy=function(){const t=oe(this,mr).getQueryCache().build(oe(this,mr),this.options);if(t===oe(this,it))return;const r=oe(this,it);De(this,it,t),De(this,fo,t.state),this.hasListeners()&&(r==null||r.removeObserver(this),t.addObserver(this))},ww=function(t){Kt.batch(()=>{t.listeners&&this.listeners.forEach(r=>{r(oe(this,ur))}),oe(this,mr).getQueryCache().notify({query:oe(this,it),type:"observerResultsUpdated"})})},uw);function kM(e,t){return Sr(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&Sr(t.retryOnMount,e)===!1)}function B_(e,t){return kM(e,t)||e.state.data!==void 0&&$y(e,t,t.refetchOnMount)}function $y(e,t,r){if(Sr(t.enabled,e)!==!1&&Yn(t.staleTime,e)!=="static"){const n=typeof r=="function"?r(e):r;return n==="always"||n!==!1&&fg(e,t)}return!1}function U_(e,t,r,n){return(e!==t||Sr(n.enabled,e)===!1)&&(!r.suspense||e.state.status!=="error")&&fg(e,r)}function fg(e,t){return Sr(t.enabled,e)!==!1&&e.isStaleByTime(Yn(t.staleTime,e))}function BM(e,t){return!Ty(e.getCurrentResult(),t)}var mo,tn,nr,Vi,rn,Ln,cw,UM=(cw=class extends Sw{constructor(t){super();Ge(this,rn);Ge(this,mo);Ge(this,tn);Ge(this,nr);Ge(this,Vi);De(this,mo,t.client),this.mutationId=t.mutationId,De(this,nr,t.mutationCache),De(this,tn,[]),this.state=t.state||FM(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){oe(this,tn).includes(t)||(oe(this,tn).push(t),this.clearGcTimeout(),oe(this,nr).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){De(this,tn,oe(this,tn).filter(r=>r!==t)),this.scheduleGc(),oe(this,nr).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){oe(this,tn).length||(this.state.status==="pending"?this.scheduleGc():oe(this,nr).remove(this))}continue(){var t;return((t=oe(this,Vi))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var s,o,u,l,c,d,m,p,E,A,R,O,f,v,b,h,T,w;const r=()=>{tt(this,rn,Ln).call(this,{type:"continue"})},n={client:oe(this,mo),meta:this.options.meta,mutationKey:this.options.mutationKey};De(this,Vi,Tw({fn:()=>this.options.mutationFn?this.options.mutationFn(t,n):Promise.reject(new Error("No mutationFn found")),onFail:(P,B)=>{tt(this,rn,Ln).call(this,{type:"failed",failureCount:P,error:B})},onPause:()=>{tt(this,rn,Ln).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>oe(this,nr).canRun(this)}));const i=this.state.status==="pending",a=!oe(this,Vi).canStart();try{if(i)r();else{tt(this,rn,Ln).call(this,{type:"pending",variables:t,isPaused:a}),oe(this,nr).config.onMutate&&await oe(this,nr).config.onMutate(t,this,n);const B=await((o=(s=this.options).onMutate)==null?void 0:o.call(s,t,n));B!==this.state.context&&tt(this,rn,Ln).call(this,{type:"pending",context:B,variables:t,isPaused:a})}const P=await oe(this,Vi).start();return await((l=(u=oe(this,nr).config).onSuccess)==null?void 0:l.call(u,P,t,this.state.context,this,n)),await((d=(c=this.options).onSuccess)==null?void 0:d.call(c,P,t,this.state.context,n)),await((p=(m=oe(this,nr).config).onSettled)==null?void 0:p.call(m,P,null,this.state.variables,this.state.context,this,n)),await((A=(E=this.options).onSettled)==null?void 0:A.call(E,P,null,t,this.state.context,n)),tt(this,rn,Ln).call(this,{type:"success",data:P}),P}catch(P){try{await((O=(R=oe(this,nr).config).onError)==null?void 0:O.call(R,P,t,this.state.context,this,n))}catch(B){Promise.reject(B)}try{await((v=(f=this.options).onError)==null?void 0:v.call(f,P,t,this.state.context,n))}catch(B){Promise.reject(B)}try{await((h=(b=oe(this,nr).config).onSettled)==null?void 0:h.call(b,void 0,P,this.state.variables,this.state.context,this,n))}catch(B){Promise.reject(B)}try{await((w=(T=this.options).onSettled)==null?void 0:w.call(T,void 0,P,t,this.state.context,n))}catch(B){Promise.reject(B)}throw tt(this,rn,Ln).call(this,{type:"error",error:P}),P}finally{oe(this,nr).runNext(this)}}},mo=new WeakMap,tn=new WeakMap,nr=new WeakMap,Vi=new WeakMap,rn=new WeakSet,Ln=function(t){const r=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Kt.batch(()=>{oe(this,tn).forEach(n=>{n.onMutationUpdate(t)}),oe(this,nr).notify({mutation:this,type:"updated",action:t})})},cw);function FM(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Rn,qr,ho,lw,VM=(lw=class extends yo{constructor(t={}){super();Ge(this,Rn);Ge(this,qr);Ge(this,ho);this.config=t,De(this,Rn,new Set),De(this,qr,new Map),De(this,ho,0)}build(t,r,n){const i=new UM({client:t,mutationCache:this,mutationId:++Eu(this,ho)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){oe(this,Rn).add(t);const r=vu(t);if(typeof r=="string"){const n=oe(this,qr).get(r);n?n.push(t):oe(this,qr).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(oe(this,Rn).delete(t)){const r=vu(t);if(typeof r=="string"){const n=oe(this,qr).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&oe(this,qr).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=vu(t);if(typeof r=="string"){const n=oe(this,qr).get(r),i=n==null?void 0:n.find(a=>a.state.status==="pending");return!i||i===t}else return!0}runNext(t){var n;const r=vu(t);if(typeof r=="string"){const i=(n=oe(this,qr).get(r))==null?void 0:n.find(a=>a!==t&&a.state.isPaused);return(i==null?void 0:i.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Kt.batch(()=>{oe(this,Rn).forEach(t=>{this.notify({type:"removed",mutation:t})}),oe(this,Rn).clear(),oe(this,qr).clear()})}getAll(){return Array.from(oe(this,Rn))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>j_(r,n))}findAll(t={}){return this.getAll().filter(r=>j_(t,r))}notify(t){Kt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>r.state.isPaused);return Kt.batch(()=>Promise.all(t.map(r=>r.continue().catch(hr))))}},Rn=new WeakMap,qr=new WeakMap,ho=new WeakMap,lw);function vu(e){var t;return(t=e.options.scope)==null?void 0:t.id}var nn,dw,HM=(dw=class extends yo{constructor(t={}){super();Ge(this,nn);this.config=t,De(this,nn,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??lg(i,r);let s=this.get(a);return s||(s=new LM({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(s)),s}add(t){oe(this,nn).has(t.queryHash)||(oe(this,nn).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=oe(this,nn).get(t.queryHash);r&&(t.destroy(),r===t&&oe(this,nn).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Kt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return oe(this,nn).get(t)}getAll(){return[...oe(this,nn).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>D_(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>D_(t,n)):r}notify(t){Kt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Kt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Kt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},nn=new WeakMap,dw),jt,Gn,zn,$a,La,Wn,qa,ka,fw,GM=(fw=class{constructor(e={}){Ge(this,jt);Ge(this,Gn);Ge(this,zn);Ge(this,$a);Ge(this,La);Ge(this,Wn);Ge(this,qa);Ge(this,ka);De(this,jt,e.queryCache||new HM),De(this,Gn,e.mutationCache||new VM),De(this,zn,e.defaultOptions||{}),De(this,$a,new Map),De(this,La,new Map),De(this,Wn,0)}mount(){Eu(this,Wn)._++,oe(this,Wn)===1&&(De(this,qa,cg.subscribe(async e=>{e&&(await this.resumePausedMutations(),oe(this,jt).onFocus())})),De(this,ka,Wc.subscribe(async e=>{e&&(await this.resumePausedMutations(),oe(this,jt).onOnline())})))}unmount(){var e,t;Eu(this,Wn)._--,oe(this,Wn)===0&&((e=oe(this,qa))==null||e.call(this),De(this,qa,void 0),(t=oe(this,ka))==null||t.call(this),De(this,ka,void 0))}isFetching(e){return oe(this,jt).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return oe(this,Gn).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=oe(this,jt).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=oe(this,jt).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(Yn(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return oe(this,jt).findAll(e).map(({queryKey:t,state:r})=>{const n=r.data;return[t,n]})}setQueryData(e,t,r){const n=this.defaultQueryOptions({queryKey:e}),i=oe(this,jt).get(n.queryHash),a=i==null?void 0:i.state.data,s=RM(t,a);if(s!==void 0)return oe(this,jt).build(this,n).setData(s,{...r,manual:!0})}setQueriesData(e,t,r){return Kt.batch(()=>oe(this,jt).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=oe(this,jt).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=oe(this,jt);Kt.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=oe(this,jt);return Kt.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Kt.batch(()=>oe(this,jt).findAll(e).map(i=>i.cancel(r)));return Promise.all(n).then(hr).catch(hr)}invalidateQueries(e,t={}){return Kt.batch(()=>(oe(this,jt).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const r={...t,cancelRefetch:t.cancelRefetch??!0},n=Kt.batch(()=>oe(this,jt).findAll(e).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let a=i.fetch(void 0,r);return r.throwOnError||(a=a.catch(hr)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(hr)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=oe(this,jt).build(this,t);return r.isStaleByTime(Yn(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(hr).catch(hr)}fetchInfiniteQuery(e){return e._type="infinite",this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(hr).catch(hr)}ensureInfiniteQueryData(e){return e._type="infinite",this.ensureQueryData(e)}resumePausedMutations(){return Wc.isOnline()?oe(this,Gn).resumePausedMutations():Promise.resolve()}getQueryCache(){return oe(this,jt)}getMutationCache(){return oe(this,Gn)}getDefaultOptions(){return oe(this,zn)}setDefaultOptions(e){De(this,zn,e)}setQueryDefaults(e,t){oe(this,$a).set(xs(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...oe(this,$a).values()],r={};return t.forEach(n=>{eo(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){oe(this,La).set(xs(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...oe(this,La).values()],r={};return t.forEach(n=>{eo(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...oe(this,zn).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=lg(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===dg&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...oe(this,zn).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){oe(this,jt).clear(),oe(this,Gn).clear()}},jt=new WeakMap,Gn=new WeakMap,zn=new WeakMap,$a=new WeakMap,La=new WeakMap,Wn=new WeakMap,qa=new WeakMap,ka=new WeakMap,fw),Ow=Ye.createContext(void 0),zM=e=>{const t=Ye.useContext(Ow);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},WM=({client:e,children:t})=>(Ye.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),fe.jsx(Ow.Provider,{value:e,children:t})),Nw=Ye.createContext(!1),YM=()=>Ye.useContext(Nw);Nw.Provider;function KM(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var JM=Ye.createContext(KM()),XM=()=>Ye.useContext(JM),QM=(e,t,r)=>{const n=r!=null&&r.state.error&&typeof e.throwOnError=="function"?vw(e.throwOnError,[r.state.error,r]):e.throwOnError;(e.suspense||e.experimental_prefetchInRender||n)&&(t.isReset()||(e.retryOnMount=!1))},ZM=e=>{Ye.useEffect(()=>{e.clearReset()},[e])},xM=({result:e,errorResetBoundary:t,throwOnError:r,query:n,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&n&&(i&&e.data===void 0||vw(r,[e.error,n])),eC=e=>{if(e.suspense){const r=i=>i==="static"?i:Math.max(i??1e3,1e3),n=e.staleTime;e.staleTime=typeof n=="function"?(...i)=>r(n(...i)):r(n),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},tC=(e,t)=>e.isLoading&&e.isFetching&&!t,rC=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,F_=(e,t,r)=>t.fetchOptimistic(e).catch(()=>{r.clearReset()});function nC(e,t,r){var p,E,A,R;const n=YM(),i=XM(),a=zM(),s=a.defaultQueryOptions(e);(E=(p=a.getDefaultOptions().queries)==null?void 0:p._experimental_beforeQuery)==null||E.call(p,s);const o=a.getQueryCache().get(s.queryHash),u=e.subscribed!==!1;s._optimisticResults=n?"isRestoring":u?"optimistic":void 0,eC(s),QM(s,i,o),ZM(i);const l=!a.getQueryCache().get(s.queryHash),[c]=Ye.useState(()=>new t(a,s)),d=c.getOptimisticResult(s),m=!n&&u;if(Ye.useSyncExternalStore(Ye.useCallback(O=>{const f=m?c.subscribe(Kt.batchCalls(O)):hr;return c.updateResult(),f},[c,m]),()=>c.getCurrentResult(),()=>c.getCurrentResult()),Ye.useEffect(()=>{c.setOptions(s)},[s,c]),rC(s,d))throw F_(s,c,i);if(xM({result:d,errorResetBoundary:i,throwOnError:s.throwOnError,query:o,suspense:s.suspense}))throw d.error;if((R=(A=a.getDefaultOptions().queries)==null?void 0:A._experimental_afterQuery)==null||R.call(A,s,d),s.experimental_prefetchInRender&&!to.isServer()&&tC(d,n)){const O=l?F_(s,c,i):o==null?void 0:o.promise;O==null||O.catch(hr).finally(()=>{c.updateResult()})}return s.notifyOnChangeProps?d:c.trackResult(d)}function tl(e,t){return nC(e,qM)}const iC="modulepreload",aC=function(e){return"https://cdn.decentraland.org/@dcl/shop/0.1.0-28749698227.commit-0c859e2/"+e},V_={},Xt=function(t,r,n){let i=Promise.resolve();if(r&&r.length>0){let s=function(l){return Promise.all(l.map(c=>Promise.resolve(c).then(d=>({status:"fulfilled",value:d}),d=>({status:"rejected",reason:d}))))};document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),u=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));i=s(r.map(l=>{if(l=aC(l),l in V_)return;V_[l]=!0;const c=l.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${l}"]${d}`))return;const m=document.createElement("link");if(m.rel=c?"stylesheet":iC,c||(m.as="script"),m.crossOrigin="",m.href=l,u&&m.setAttribute("nonce",u),document.head.appendChild(m),c)return new Promise((p,E)=>{m.addEventListener("load",p),m.addEventListener("error",()=>E(new Error(`Unable to preload CSS for ${l}`)))})}))}function a(s){const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s}return i.then(s=>{for(const o of s||[])o.status==="rejected"&&a(o.reason);return t().catch(a)})},Pw=Object.prototype.toString;function pg(e){switch(Pw.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return An(e,Error)}}function za(e,t){return Pw.call(e)===`[object ${t}]`}function mg(e){return za(e,"ErrorEvent")}function H_(e){return za(e,"DOMError")}function sC(e){return za(e,"DOMException")}function on(e){return za(e,"String")}function hg(e){return typeof e=="object"&&e!==null&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function yg(e){return e===null||hg(e)||typeof e!="object"&&typeof e!="function"}function Gi(e){return za(e,"Object")}function rl(e){return typeof Event<"u"&&An(e,Event)}function oC(e){return typeof Element<"u"&&An(e,Element)}function uC(e){return za(e,"RegExp")}function Wa(e){return!!(e&&e.then&&typeof e.then=="function")}function cC(e){return Gi(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function Mw(e){return typeof e=="number"&&e!==e}function An(e,t){try{return e instanceof t}catch{return!1}}function Cw(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue))}function ba(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function G_(e,t){if(!Array.isArray(e))return"";const r=[];for(let n=0;n<e.length;n++){const i=e[n];try{Cw(i)?r.push("[VueViewModel]"):r.push(String(i))}catch{r.push("[value cannot be serialized]")}}return r.join(t)}function lC(e,t,r=!1){return on(e)?uC(t)?t.test(e):on(t)?r?e===t:e.includes(t):!1:!1}function go(e,t=[],r=!1){return t.some(n=>lC(e,n,r))}function dC(e,t,r=250,n,i,a,s){if(!a.exception||!a.exception.values||!s||!An(s.originalException,Error))return;const o=a.exception.values.length>0?a.exception.values[a.exception.values.length-1]:void 0;o&&(a.exception.values=fC(Ly(e,t,i,s.originalException,n,a.exception.values,o,0),r))}function Ly(e,t,r,n,i,a,s,o){if(a.length>=r+1)return a;let u=[...a];if(An(n[i],Error)){z_(s,o);const l=e(t,n[i]),c=u.length;W_(l,i,c,o),u=Ly(e,t,r,n[i],i,[l,...u],l,c)}return Array.isArray(n.errors)&&n.errors.forEach((l,c)=>{if(An(l,Error)){z_(s,o);const d=e(t,l),m=u.length;W_(d,`errors[${c}]`,m,o),u=Ly(e,t,r,l,i,[d,...u],d,m)}}),u}function z_(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function W_(e,t,r,n){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:r,parent_id:n}}function fC(e,t){return e.map(r=>(r.value&&(r.value=ba(r.value,t)),r))}function bu(e){return e&&e.Math==Math?e:void 0}const at=typeof globalThis=="object"&&bu(globalThis)||typeof window=="object"&&bu(window)||typeof self=="object"&&bu(self)||typeof zc=="object"&&bu(zc)||(function(){return this})()||{};function gg(){return at}function nl(e,t,r){const n=r||at,i=n.__SENTRY__=n.__SENTRY__||{};return i[e]||(i[e]=t())}const Ta=gg(),pC=80;function Ba(e,t={}){if(!e)return"<unknown>";try{let r=e;const n=5,i=[];let a=0,s=0;const o=" > ",u=o.length;let l;const c=Array.isArray(t)?t:t.keyAttrs,d=!Array.isArray(t)&&t.maxStringLength||pC;for(;r&&a++<n&&(l=mC(r,c),!(l==="html"||a>1&&s+i.length*u+l.length>=d));)i.push(l),s+=l.length,r=r.parentNode;return i.reverse().join(o)}catch{return"<unknown>"}}function mC(e,t){const r=e,n=[];let i,a,s,o,u;if(!r||!r.tagName)return"";if(Ta.HTMLElement&&r instanceof HTMLElement&&r.dataset&&r.dataset.sentryComponent)return r.dataset.sentryComponent;n.push(r.tagName.toLowerCase());const l=t&&t.length?t.filter(d=>r.getAttribute(d)).map(d=>[d,r.getAttribute(d)]):null;if(l&&l.length)l.forEach(d=>{n.push(`[${d[0]}="${d[1]}"]`)});else if(r.id&&n.push(`#${r.id}`),i=r.className,i&&on(i))for(a=i.split(/\s+/),u=0;u<a.length;u++)n.push(`.${a[u]}`);const c=["aria-label","type","name","title","alt"];for(u=0;u<c.length;u++)s=c[u],o=r.getAttribute(s),o&&n.push(`[${s}="${o}"]`);return n.join("")}function hC(){try{return Ta.document.location.href}catch{return""}}function yC(e){return Ta.document&&Ta.document.querySelector?Ta.document.querySelector(e):null}function Dw(e){if(!Ta.HTMLElement)return null;let t=e;const r=5;for(let n=0;n<r;n++){if(!t)return null;if(t instanceof HTMLElement&&t.dataset.sentryComponent)return t.dataset.sentryComponent;t=t.parentNode}return null}const Ya=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,gC="Sentry Logger ",qy=["debug","info","warn","error","log","assert","trace"],Yc={};function _o(e){if(!("console"in at))return e();const t=at.console,r={},n=Object.keys(Yc);n.forEach(i=>{const a=Yc[i];r[i]=t[i],t[i]=a});try{return e()}finally{n.forEach(i=>{t[i]=r[i]})}}function _C(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return Ya?qy.forEach(r=>{t[r]=(...n)=>{e&&_o(()=>{at.console[r](`${gC}[${r}]:`,...n)})}}):qy.forEach(r=>{t[r]=()=>{}}),t}const Re=_C(),EC=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function vC(e){return e==="http"||e==="https"}function Qi(e,t=!1){const{host:r,path:n,pass:i,port:a,projectId:s,protocol:o,publicKey:u}=e;return`${o}://${u}${t&&i?`:${i}`:""}@${r}${a?`:${a}`:""}/${n&&`${n}/`}${s}`}function bC(e){const t=EC.exec(e);if(!t){_o(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}const[r,n,i="",a,s="",o]=t.slice(1);let u="",l=o;const c=l.split("/");if(c.length>1&&(u=c.slice(0,-1).join("/"),l=c.pop()),l){const d=l.match(/^\d+/);d&&(l=d[0])}return jw({host:a,pass:i,path:u,projectId:l,port:s,protocol:r,publicKey:n})}function jw(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function TC(e){if(!Ya)return!0;const{port:t,projectId:r,protocol:n}=e;return["protocol","publicKey","host","projectId"].find(s=>e[s]?!1:(Re.error(`Invalid Sentry Dsn: ${s} missing`),!0))?!1:r.match(/^\d+$/)?vC(n)?t&&isNaN(parseInt(t,10))?(Re.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(Re.error(`Invalid Sentry Dsn: Invalid protocol ${n}`),!1):(Re.error(`Invalid Sentry Dsn: Invalid projectId ${r}`),!1)}function $w(e){const t=typeof e=="string"?bC(e):jw(e);if(!(!t||!TC(t)))return t}class an extends Error{constructor(t,r="warn"){super(t),this.message=t,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=r}}function Jt(e,t,r){if(!(t in e))return;const n=e[t],i=r(n);typeof i=="function"&&Lw(i,n),e[t]=i}function zi(e,t,r){try{Object.defineProperty(e,t,{value:r,writable:!0,configurable:!0})}catch{Ya&&Re.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function Lw(e,t){try{const r=t.prototype||{};e.prototype=t.prototype=r,zi(e,"__sentry_original__",t)}catch{}}function _g(e){return e.__sentry_original__}function SC(e){return Object.keys(e).map(t=>`${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`).join("&")}function qw(e){if(pg(e))return{message:e.message,name:e.name,stack:e.stack,...K_(e)};if(rl(e)){const t={type:e.type,target:Y_(e.target),currentTarget:Y_(e.currentTarget),...K_(e)};return typeof CustomEvent<"u"&&An(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function Y_(e){try{return oC(e)?Ba(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function K_(e){if(typeof e=="object"&&e!==null){const t={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}else return{}}function IC(e,t=40){const r=Object.keys(qw(e));if(r.sort(),!r.length)return"[object has no keys]";if(r[0].length>=t)return ba(r[0],t);for(let n=r.length;n>0;n--){const i=r.slice(0,n).join(", ");if(!(i.length>t))return n===r.length?i:ba(i,t)}return""}function kt(e){return ky(e,new Map)}function ky(e,t){if(RC(e)){const r=t.get(e);if(r!==void 0)return r;const n={};t.set(e,n);for(const i of Object.keys(e))typeof e[i]<"u"&&(n[i]=ky(e[i],t));return n}if(Array.isArray(e)){const r=t.get(e);if(r!==void 0)return r;const n=[];return t.set(e,n),e.forEach(i=>{n.push(ky(i,t))}),n}return e}function RC(e){if(!Gi(e))return!1;try{const t=Object.getPrototypeOf(e).constructor.name;return!t||t==="Object"}catch{return!0}}const kw=50,J_=/\(error: (.*)\)/,X_=/captureMessage|captureException/;function Bw(...e){const t=e.sort((r,n)=>r[0]-n[0]).map(r=>r[1]);return(r,n=0)=>{const i=[],a=r.split(`
|
|
3
|
+
`);for(let s=n;s<a.length;s++){const o=a[s];if(o.length>1024)continue;const u=J_.test(o)?o.replace(J_,"$1"):o;if(!u.match(/\S*Error: /)){for(const l of t){const c=l(u);if(c){i.push(c);break}}if(i.length>=kw)break}}return wC(i)}}function AC(e){return Array.isArray(e)?Bw(...e):e}function wC(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(t[t.length-1].function||"")&&t.pop(),t.reverse(),X_.test(t[t.length-1].function||"")&&(t.pop(),X_.test(t[t.length-1].function||"")&&t.pop()),t.slice(0,kw).map(r=>({...r,filename:r.filename||t[t.length-1].filename,function:r.function||"?"}))}const Bl="<anonymous>";function wn(e){try{return!e||typeof e!="function"?Bl:e.name||Bl}catch{return Bl}}const Fc={},Q_={};function Zi(e,t){Fc[e]=Fc[e]||[],Fc[e].push(t)}function xi(e,t){Q_[e]||(t(),Q_[e]=!0)}function kr(e,t){const r=e&&Fc[e];if(r)for(const n of r)try{n(t)}catch(i){Ya&&Re.error(`Error while triggering instrumentation handler.
|
|
4
|
+
Type: ${e}
|
|
5
|
+
Name: ${wn(n)}
|
|
6
|
+
Error:`,i)}}function OC(e){const t="console";Zi(t,e),xi(t,NC)}function NC(){"console"in at&&qy.forEach(function(e){e in at.console&&Jt(at.console,e,function(t){return Yc[e]=t,function(...r){kr("console",{args:r,level:e});const i=Yc[e];i&&i.apply(at.console,r)}})})}function pt(){const e=at,t=e.crypto||e.msCrypto;let r=()=>Math.random()*16;try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(r=()=>{const n=new Uint8Array(1);return t.getRandomValues(n),n[0]})}catch{}return("10000000100040008000"+1e11).replace(/[018]/g,n=>(n^(r()&15)>>n/4).toString(16))}function Uw(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function kn(e){const{message:t,event_id:r}=e;if(t)return t;const n=Uw(e);return n?n.type&&n.value?`${n.type}: ${n.value}`:n.type||n.value||r||"<unknown>":r||"<unknown>"}function By(e,t,r){const n=e.exception=e.exception||{},i=n.values=n.values||[],a=i[0]=i[0]||{};a.value||(a.value=t||""),a.type||(a.type="Error")}function ro(e,t){const r=Uw(e);if(!r)return;const n={type:"generic",handled:!0},i=r.mechanism;if(r.mechanism={...n,...i,...t},t&&"data"in t){const a={...i&&i.data,...t.data};r.mechanism.data=a}}function Z_(e){if(e&&e.__sentry_captured__)return!0;try{zi(e,"__sentry_captured__",!0)}catch{}return!1}function Eg(e){return Array.isArray(e)?e:[e]}const ga=at,PC=1e3;let x_,Uy,Fy;function MC(e){Zi("dom",e),xi("dom",CC)}function CC(){if(!ga.document)return;const e=kr.bind(null,"dom"),t=eE(e,!0);ga.document.addEventListener("click",t,!1),ga.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(r=>{const n=ga[r]&&ga[r].prototype;!n||!n.hasOwnProperty||!n.hasOwnProperty("addEventListener")||(Jt(n,"addEventListener",function(i){return function(a,s,o){if(a==="click"||a=="keypress")try{const u=this,l=u.__sentry_instrumentation_handlers__=u.__sentry_instrumentation_handlers__||{},c=l[a]=l[a]||{refCount:0};if(!c.handler){const d=eE(e);c.handler=d,i.call(this,a,d,o)}c.refCount++}catch{}return i.call(this,a,s,o)}}),Jt(n,"removeEventListener",function(i){return function(a,s,o){if(a==="click"||a=="keypress")try{const u=this,l=u.__sentry_instrumentation_handlers__||{},c=l[a];c&&(c.refCount--,c.refCount<=0&&(i.call(this,a,c.handler,o),c.handler=void 0,delete l[a]),Object.keys(l).length===0&&delete u.__sentry_instrumentation_handlers__)}catch{}return i.call(this,a,s,o)}}))})}function DC(e){if(e.type!==Uy)return!1;try{if(!e.target||e.target._sentryId!==Fy)return!1}catch{}return!0}function jC(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function eE(e,t=!1){return r=>{if(!r||r._sentryCaptured)return;const n=$C(r);if(jC(r.type,n))return;zi(r,"_sentryCaptured",!0),n&&!n._sentryId&&zi(n,"_sentryId",pt());const i=r.type==="keypress"?"input":r.type;DC(r)||(e({event:r,name:i,global:t}),Uy=r.type,Fy=n?n._sentryId:void 0),clearTimeout(x_),x_=ga.setTimeout(()=>{Fy=void 0,Uy=void 0},PC)}}function $C(e){try{return e.target}catch{return null}}const Vy=gg();function Fw(){if(!("fetch"in Vy))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function Hy(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function LC(){if(typeof EdgeRuntime=="string")return!0;if(!Fw())return!1;if(Hy(Vy.fetch))return!0;let e=!1;const t=Vy.document;if(t&&typeof t.createElement=="function")try{const r=t.createElement("iframe");r.hidden=!0,t.head.appendChild(r),r.contentWindow&&r.contentWindow.fetch&&(e=Hy(r.contentWindow.fetch)),t.head.removeChild(r)}catch(r){Ya&&Re.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return e}function Vw(e){const t="fetch";Zi(t,e),xi(t,qC)}function qC(){LC()&&Jt(at,"fetch",function(e){return function(...t){const{method:r,url:n}=kC(t),i={args:t,fetchData:{method:r,url:n},startTimestamp:Date.now()};return kr("fetch",{...i}),e.apply(at,t).then(a=>{const s={...i,endTimestamp:Date.now(),response:a};return kr("fetch",s),a},a=>{const s={...i,endTimestamp:Date.now(),error:a};throw kr("fetch",s),a})}})}function Gy(e,t){return!!e&&typeof e=="object"&&!!e[t]}function tE(e){return typeof e=="string"?e:e?Gy(e,"url")?e.url:e.toString?e.toString():"":""}function kC(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[r,n]=e;return{url:tE(r),method:Gy(n,"method")?String(n.method).toUpperCase():"GET"}}const t=e[0];return{url:tE(t),method:Gy(t,"method")?String(t.method).toUpperCase():"GET"}}let Tu=null;function Hw(e){const t="error";Zi(t,e),xi(t,BC)}function BC(){Tu=at.onerror,at.onerror=function(e,t,r,n,i){return kr("error",{column:n,error:i,line:r,msg:e,url:t}),Tu&&!Tu.__SENTRY_LOADER__?Tu.apply(this,arguments):!1},at.onerror.__SENTRY_INSTRUMENTED__=!0}let Su=null;function Gw(e){const t="unhandledrejection";Zi(t,e),xi(t,UC)}function UC(){Su=at.onunhandledrejection,at.onunhandledrejection=function(e){return kr("unhandledrejection",e),Su&&!Su.__SENTRY_LOADER__?Su.apply(this,arguments):!0},at.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const Iu=gg();function FC(){const e=Iu.chrome,t=e&&e.app&&e.app.runtime,r="history"in Iu&&!!Iu.history.pushState&&!!Iu.history.replaceState;return!t&&r}const as=at;let Ru;function vg(e){const t="history";Zi(t,e),xi(t,VC)}function VC(){if(!FC())return;const e=as.onpopstate;as.onpopstate=function(...r){const n=as.location.href,i=Ru;if(Ru=n,kr("history",{from:i,to:n}),e)try{return e.apply(this,r)}catch{}};function t(r){return function(...n){const i=n.length>2?n[2]:void 0;if(i){const a=Ru,s=String(i);Ru=s,kr("history",{from:a,to:s})}return r.apply(this,n)}}Jt(as.history,"pushState",t),Jt(as.history,"replaceState",t)}const HC=at,_a="__sentry_xhr_v3__";function zw(e){Zi("xhr",e),xi("xhr",GC)}function GC(){if(!HC.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;Jt(e,"open",function(t){return function(...r){const n=Date.now(),i=on(r[0])?r[0].toUpperCase():void 0,a=zC(r[1]);if(!i||!a)return t.apply(this,r);this[_a]={method:i,url:a,request_headers:{}},i==="POST"&&a.match(/sentry_key/)&&(this.__sentry_own_request__=!0);const s=()=>{const o=this[_a];if(o&&this.readyState===4){try{o.status_code=this.status}catch{}const u={args:[i,a],endTimestamp:Date.now(),startTimestamp:n,xhr:this};kr("xhr",u)}};return"onreadystatechange"in this&&typeof this.onreadystatechange=="function"?Jt(this,"onreadystatechange",function(o){return function(...u){return s(),o.apply(this,u)}}):this.addEventListener("readystatechange",s),Jt(this,"setRequestHeader",function(o){return function(...u){const[l,c]=u,d=this[_a];return d&&on(l)&&on(c)&&(d.request_headers[l.toLowerCase()]=c),o.apply(this,u)}}),t.apply(this,r)}}),Jt(e,"send",function(t){return function(...r){const n=this[_a];if(!n)return t.apply(this,r);r[0]!==void 0&&(n.body=r[0]);const i={args:[n.method,n.url],startTimestamp:Date.now(),xhr:this};return kr("xhr",i),t.apply(this,r)}})}function zC(e){if(on(e))return e;try{return e.toString()}catch{}}function WC(){return"npm"}function YC(){const e=typeof WeakSet=="function",t=e?new WeakSet:[];function r(i){if(e)return t.has(i)?!0:(t.add(i),!1);for(let a=0;a<t.length;a++)if(t[a]===i)return!0;return t.push(i),!1}function n(i){if(e)t.delete(i);else for(let a=0;a<t.length;a++)if(t[a]===i){t.splice(a,1);break}}return[r,n]}function qn(e,t=100,r=1/0){try{return zy("",e,t,r)}catch(n){return{ERROR:`**non-serializable** (${n})`}}}function Ww(e,t=3,r=100*1024){const n=qn(e,t);return QC(n)>r?Ww(e,t-1,r):n}function zy(e,t,r=1/0,n=1/0,i=YC()){const[a,s]=i;if(t==null||["number","boolean","string"].includes(typeof t)&&!Mw(t))return t;const o=KC(e,t);if(!o.startsWith("[object "))return o;if(t.__sentry_skip_normalization__)return t;const u=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:r;if(u===0)return o.replace("object ","");if(a(t))return"[Circular ~]";const l=t;if(l&&typeof l.toJSON=="function")try{const p=l.toJSON();return zy("",p,u-1,n,i)}catch{}const c=Array.isArray(t)?[]:{};let d=0;const m=qw(t);for(const p in m){if(!Object.prototype.hasOwnProperty.call(m,p))continue;if(d>=n){c[p]="[MaxProperties ~]";break}const E=m[p];c[p]=zy(p,E,u-1,n,i),d++}return s(t),c}function KC(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof zc<"u"&&t===zc)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(Cw(t))return"[VueViewModel]";if(cC(t))return"[SyntheticEvent]";if(typeof t=="number"&&t!==t)return"[NaN]";if(typeof t=="function")return`[Function: ${wn(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const r=JC(t);return/^HTML(\w*)Element$/.test(r)?`[HTMLElement: ${r}]`:`[object ${r}]`}catch(r){return`**non-serializable** (${r})`}}function JC(e){const t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function XC(e){return~-encodeURI(e).split(/%..|./).length}function QC(e){return XC(JSON.stringify(e))}var Tn;(function(e){e[e.PENDING=0]="PENDING";const r=1;e[e.RESOLVED=r]="RESOLVED";const n=2;e[e.REJECTED=n]="REJECTED"})(Tn||(Tn={}));function Ua(e){return new yr(t=>{t(e)})}function bg(e){return new yr((t,r)=>{r(e)})}class yr{constructor(t){yr.prototype.__init.call(this),yr.prototype.__init2.call(this),yr.prototype.__init3.call(this),yr.prototype.__init4.call(this),this._state=Tn.PENDING,this._handlers=[];try{t(this._resolve,this._reject)}catch(r){this._reject(r)}}then(t,r){return new yr((n,i)=>{this._handlers.push([!1,a=>{if(!t)n(a);else try{n(t(a))}catch(s){i(s)}},a=>{if(!r)i(a);else try{n(r(a))}catch(s){i(s)}}]),this._executeHandlers()})}catch(t){return this.then(r=>r,t)}finally(t){return new yr((r,n)=>{let i,a;return this.then(s=>{a=!1,i=s,t&&t()},s=>{a=!0,i=s,t&&t()}).then(()=>{if(a){n(i);return}r(i)})})}__init(){this._resolve=t=>{this._setResult(Tn.RESOLVED,t)}}__init2(){this._reject=t=>{this._setResult(Tn.REJECTED,t)}}__init3(){this._setResult=(t,r)=>{if(this._state===Tn.PENDING){if(Wa(r)){r.then(this._resolve,this._reject);return}this._state=t,this._value=r,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===Tn.PENDING)return;const t=this._handlers.slice();this._handlers=[],t.forEach(r=>{r[0]||(this._state===Tn.RESOLVED&&r[1](this._value),this._state===Tn.REJECTED&&r[2](this._value),r[0]=!0)})}}}function ZC(e){const t=[];function r(){return e===void 0||t.length<e}function n(s){return t.splice(t.indexOf(s),1)[0]}function i(s){if(!r())return bg(new an("Not adding Promise because buffer limit was reached."));const o=s();return t.indexOf(o)===-1&&t.push(o),o.then(()=>n(o)).then(null,()=>n(o).then(null,()=>{})),o}function a(s){return new yr((o,u)=>{let l=t.length;if(!l)return o(!0);const c=setTimeout(()=>{s&&s>0&&o(!1)},s);t.forEach(d=>{Ua(d).then(()=>{--l||(clearTimeout(c),o(!0))},u)})})}return{$:t,add:i,drain:a}}function Hi(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const r=t[6]||"",n=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:r,hash:n,relative:t[5]+r+n}}const xC=["fatal","error","warning","log","info","debug"];function eD(e){return e==="warn"?"warning":xC.includes(e)?e:"log"}const Yw=1e3;function ea(){return Date.now()/Yw}function tD(){const{performance:e}=at;if(!e||!e.now)return ea;const t=Date.now()-e.now(),r=e.timeOrigin==null?t:e.timeOrigin;return()=>(r+e.now())/Yw}const ta=tD(),wr=(()=>{const{performance:e}=at;if(!e||!e.now)return;const t=3600*1e3,r=e.now(),n=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+r-n):t,a=i<t,s=e.timing&&e.timing.navigationStart,u=typeof s=="number"?Math.abs(s+r-n):t,l=u<t;return a||l?i<=u?e.timeOrigin:s:n})(),Wy="baggage",Kw="sentry-",rD=/^sentry-/,nD=8192;function iD(e){if(!on(e)&&!Array.isArray(e))return;let t={};if(Array.isArray(e))t=e.reduce((n,i)=>{const a=rE(i);for(const s of Object.keys(a))n[s]=a[s];return n},{});else{if(!e)return;t=rE(e)}const r=Object.entries(t).reduce((n,[i,a])=>{if(i.match(rD)){const s=i.slice(Kw.length);n[s]=a}return n},{});if(Object.keys(r).length>0)return r}function Jw(e){if(!e)return;const t=Object.entries(e).reduce((r,[n,i])=>(i&&(r[`${Kw}${n}`]=i),r),{});return aD(t)}function rE(e){return e.split(",").map(t=>t.split("=").map(r=>decodeURIComponent(r.trim()))).reduce((t,[r,n])=>(t[r]=n,t),{})}function aD(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[r,n],i)=>{const a=`${encodeURIComponent(r)}=${encodeURIComponent(n)}`,s=i===0?a:`${t},${a}`;return s.length>nD?(Ya&&Re.warn(`Not adding key: ${r} with val: ${n} to baggage header due to exceeding baggage size limits.`),t):s},"")}const sD=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function oD(e){if(!e)return;const t=e.match(sD);if(!t)return;let r;return t[3]==="1"?r=!0:t[3]==="0"&&(r=!1),{traceId:t[1],parentSampled:r,parentSpanId:t[2]}}function uD(e,t){const r=oD(e),n=iD(t),{traceId:i,parentSpanId:a,parentSampled:s}=r||{};return r?{traceId:i||pt(),parentSpanId:a||pt().substring(16),spanId:pt().substring(16),sampled:s,dsc:n||{}}:{traceId:i||pt(),spanId:pt().substring(16)}}function Tg(e=pt(),t=pt().substring(16),r){let n="";return r!==void 0&&(n=r?"-1":"-0"),`${e}-${t}${n}`}function ra(e,t=[]){return[e,t]}function cD(e,t){const[r,n]=e;return[r,[...n,t]]}function nE(e,t){const r=e[1];for(const n of r){const i=n[0].type;if(t(n,i))return!0}return!1}function Yy(e,t){return(t||new TextEncoder).encode(e)}function lD(e,t){const[r,n]=e;let i=JSON.stringify(r);function a(s){typeof i=="string"?i=typeof s=="string"?i+s:[Yy(i,t),s]:i.push(typeof s=="string"?Yy(s,t):s)}for(const s of n){const[o,u]=s;if(a(`
|
|
7
|
+
${JSON.stringify(o)}
|
|
8
|
+
`),typeof u=="string"||u instanceof Uint8Array)a(u);else{let l;try{l=JSON.stringify(u)}catch{l=JSON.stringify(qn(u))}a(l)}}return typeof i=="string"?i:dD(i)}function dD(e){const t=e.reduce((i,a)=>i+a.length,0),r=new Uint8Array(t);let n=0;for(const i of e)r.set(i,n),n+=i.length;return r}function fD(e,t){const r=typeof e.data=="string"?Yy(e.data,t):e.data;return[kt({type:"attachment",length:r.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),r]}const pD={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket"};function iE(e){return pD[e]}function Xw(e){if(!e||!e.sdk)return;const{name:t,version:r}=e.sdk;return{name:t,version:r}}function mD(e,t,r,n){const i=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!r&&n&&{dsn:Qi(n)},...i&&{trace:kt({...i})}}}function hD(e,t,r){const n=[{type:"client_report"},{timestamp:ea(),discarded_events:e}];return ra(t?{dsn:t}:{},[n])}const yD=60*1e3;function gD(e,t=Date.now()){const r=parseInt(`${e}`,10);if(!isNaN(r))return r*1e3;const n=Date.parse(`${e}`);return isNaN(n)?yD:n-t}function _D(e,t){return e[t]||e.all||0}function ED(e,t,r=Date.now()){return _D(e,t)>r}function vD(e,{statusCode:t,headers:r},n=Date.now()){const i={...e},a=r&&r["x-sentry-rate-limits"],s=r&&r["retry-after"];if(a)for(const o of a.trim().split(",")){const[u,l,,,c]=o.split(":",5),d=parseInt(u,10),m=(isNaN(d)?60:d)*1e3;if(!l)i.all=n+m;else for(const p of l.split(";"))p==="metric_bucket"?(!c||c.split(";").includes("custom"))&&(i[p]=n+m):i[p]=n+m}else s?i.all=n+gD(s,n):t===429&&(i.all=n+60*1e3);return i}const It=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,il="production";function Sg(){return nl("globalEventProcessors",()=>[])}function bD(e){Sg().push(e)}function Kc(e,t,r,n=0){return new yr((i,a)=>{const s=e[n];if(t===null||typeof s!="function")i(t);else{const o=s({...t},r);It&&s.id&&o===null&&Re.log(`Event processor "${s.id}" dropped event`),Wa(o)?o.then(u=>Kc(e,u,r,n+1).then(i)).then(null,a):Kc(e,o,r,n+1).then(i).then(null,a)}})}function Qw(e){const t=ta(),r={sid:pt(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>TD(r)};return e&&Wi(r,e),r}function Wi(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||ta(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:pt()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const r=e.timestamp-e.started;e.duration=r>=0?r:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function Zw(e,t){let r={};e.status==="ok"&&(r={status:"exited"}),Wi(e,r)}function TD(e){return kt({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}const SD=1;function ID(e){const{spanId:t,traceId:r}=e.spanContext(),{data:n,op:i,parent_span_id:a,status:s,tags:o,origin:u}=no(e);return kt({data:n,op:i,parent_span_id:a,span_id:t,status:s,tags:o,trace_id:r,origin:u})}function no(e){return RD(e)?e.getSpanJSON():typeof e.toJSON=="function"?e.toJSON():{}}function RD(e){return typeof e.getSpanJSON=="function"}function AD(e){const{traceFlags:t}=e.spanContext();return!!(t&SD)}function wD(e,t,r,n,i,a){const{normalizeDepth:s=3,normalizeMaxBreadth:o=1e3}=e,u={...t,event_id:t.event_id||r.event_id||pt(),timestamp:t.timestamp||ea()},l=r.integrations||e.integrations.map(R=>R.name);OD(u,e),MD(u,l),t.type===void 0&&ND(u,e.stackParser);const c=DD(n,r.captureContext);r.mechanism&&ro(u,r.mechanism);const d=i&&i.getEventProcessors?i.getEventProcessors():[],m=WD().getScopeData();if(a){const R=a.getScopeData();uE(m,R)}if(c){const R=c.getScopeData();uE(m,R)}const p=[...r.attachments||[],...m.attachments];p.length&&(r.attachments=p),aO(u,m);const E=[...d,...Sg(),...m.eventProcessors];return Kc(E,u,r).then(R=>(R&&PD(R),typeof s=="number"&&s>0?CD(R,s,o):R))}function OD(e,t){const{environment:r,release:n,dist:i,maxValueLength:a=250}=t;"environment"in e||(e.environment="environment"in t?r:il),e.release===void 0&&n!==void 0&&(e.release=n),e.dist===void 0&&i!==void 0&&(e.dist=i),e.message&&(e.message=ba(e.message,a));const s=e.exception&&e.exception.values&&e.exception.values[0];s&&s.value&&(s.value=ba(s.value,a));const o=e.request;o&&o.url&&(o.url=ba(o.url,a))}const aE=new WeakMap;function ND(e,t){const r=at._sentryDebugIds;if(!r)return;let n;const i=aE.get(t);i?n=i:(n=new Map,aE.set(t,n));const a=Object.keys(r).reduce((s,o)=>{let u;const l=n.get(o);l?u=l:(u=t(o),n.set(o,u));for(let c=u.length-1;c>=0;c--){const d=u[c];if(d.filename){s[d.filename]=r[o];break}}return s},{});try{e.exception.values.forEach(s=>{s.stacktrace.frames.forEach(o=>{o.filename&&(o.debug_id=a[o.filename])})})}catch{}}function PD(e){const t={};try{e.exception.values.forEach(n=>{n.stacktrace.frames.forEach(i=>{i.debug_id&&(i.abs_path?t[i.abs_path]=i.debug_id:i.filename&&(t[i.filename]=i.debug_id),delete i.debug_id)})})}catch{}if(Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const r=e.debug_meta.images;Object.keys(t).forEach(n=>{r.push({type:"sourcemap",code_file:n,debug_id:t[n]})})}function MD(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function CD(e,t,r){if(!e)return null;const n={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(i=>({...i,...i.data&&{data:qn(i.data,t,r)}}))},...e.user&&{user:qn(e.user,t,r)},...e.contexts&&{contexts:qn(e.contexts,t,r)},...e.extra&&{extra:qn(e.extra,t,r)}};return e.contexts&&e.contexts.trace&&n.contexts&&(n.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(n.contexts.trace.data=qn(e.contexts.trace.data,t,r))),e.spans&&(n.spans=e.spans.map(i=>{const a=no(i).data;return a&&(i.data=qn(a,t,r)),i})),n}function DD(e,t){if(!t)return e;const r=e?e.clone():new io;return r.update(t),r}function jD(e){if(e)return $D(e)?{captureContext:e}:qD(e)?{captureContext:e}:e}function $D(e){return e instanceof io||typeof e=="function"}const LD=["user","level","extra","contexts","tags","fingerprint","requestSession","propagationContext"];function qD(e){return Object.keys(e).some(t=>LD.includes(t))}function Ig(e,t){return Br().captureException(e,jD(t))}function xw(e,t){return Br().captureEvent(e,t)}function Yi(e,t){Br().addBreadcrumb(e,t)}function kD(e){Br().setUser(e)}function eO(...e){const t=Br();if(e.length===2){const[r,n]=e;return r?t.withScope(()=>(t.getStackTop().scope=r,n(r))):t.withScope(n)}return t.withScope(e[0])}function cr(){return Br().getClient()}function Eo(){return Br().getScope()}function sE(e){const t=cr(),r=sl(),n=Eo(),{release:i,environment:a=il}=t&&t.getOptions()||{},{userAgent:s}=at.navigator||{},o=Qw({release:i,environment:a,user:n.getUser()||r.getUser(),...s&&{userAgent:s},...e}),u=r.getSession();return u&&u.status==="ok"&&Wi(u,{status:"exited"}),tO(),r.setSession(o),n.setSession(o),o}function tO(){const e=sl(),t=Eo(),r=t.getSession()||e.getSession();r&&Zw(r),rO(),e.setSession(),t.setSession()}function rO(){const e=sl(),t=Eo(),r=cr(),n=t.getSession()||e.getSession();n&&r&&r.captureSession&&r.captureSession(n)}function oE(e=!1){if(e){tO();return}rO()}function nO(e){return e.transaction}function iO(e,t,r){const n=t.getOptions(),{publicKey:i}=t.getDsn()||{},{segment:a}=r&&r.getUser()||{},s=kt({environment:n.environment||il,release:n.release,user_segment:a,public_key:i,trace_id:e});return t.emit&&t.emit("createDsc",s),s}function BD(e){const t=cr();if(!t)return{};const r=iO(no(e).trace_id||"",t,Eo()),n=nO(e);if(!n)return r;const i=n&&n._frozenDynamicSamplingContext;if(i)return i;const{sampleRate:a,source:s}=n.metadata;a!=null&&(r.sample_rate=`${a}`);const o=no(n);return s&&s!=="url"&&(r.transaction=o.description),r.sampled=String(AD(n)),t.emit&&t.emit("createDsc",r),r}function aO(e,t){const{fingerprint:r,span:n,breadcrumbs:i,sdkProcessingMetadata:a}=t;UD(e,t),n&&HD(e,n),GD(e,r),FD(e,i),VD(e,a)}function uE(e,t){const{extra:r,tags:n,user:i,contexts:a,level:s,sdkProcessingMetadata:o,breadcrumbs:u,fingerprint:l,eventProcessors:c,attachments:d,propagationContext:m,transactionName:p,span:E}=t;ss(e,"extra",r),ss(e,"tags",n),ss(e,"user",i),ss(e,"contexts",a),ss(e,"sdkProcessingMetadata",o),s&&(e.level=s),p&&(e.transactionName=p),E&&(e.span=E),u.length&&(e.breadcrumbs=[...e.breadcrumbs,...u]),l.length&&(e.fingerprint=[...e.fingerprint,...l]),c.length&&(e.eventProcessors=[...e.eventProcessors,...c]),d.length&&(e.attachments=[...e.attachments,...d]),e.propagationContext={...e.propagationContext,...m}}function ss(e,t,r){if(r&&Object.keys(r).length){e[t]={...e[t]};for(const n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[t][n]=r[n])}}function UD(e,t){const{extra:r,tags:n,user:i,contexts:a,level:s,transactionName:o}=t,u=kt(r);u&&Object.keys(u).length&&(e.extra={...u,...e.extra});const l=kt(n);l&&Object.keys(l).length&&(e.tags={...l,...e.tags});const c=kt(i);c&&Object.keys(c).length&&(e.user={...c,...e.user});const d=kt(a);d&&Object.keys(d).length&&(e.contexts={...d,...e.contexts}),s&&(e.level=s),o&&(e.transaction=o)}function FD(e,t){const r=[...e.breadcrumbs||[],...t];e.breadcrumbs=r.length?r:void 0}function VD(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function HD(e,t){e.contexts={trace:ID(t),...e.contexts};const r=nO(t);if(r){e.sdkProcessingMetadata={dynamicSamplingContext:BD(t),...e.sdkProcessingMetadata};const n=no(r).description;n&&(e.tags={transaction:n,...e.tags})}}function GD(e,t){e.fingerprint=e.fingerprint?Eg(e.fingerprint):[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}const zD=100;let Ul,io=class Vc{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=cE()}static clone(t){return t?t.clone():new Vc}clone(){const t=new Vc;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},t._user=this._user,t._level=this._level,t._span=this._span,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._requestSession=this._requestSession,t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t}setClient(t){this._client=t}getClient(){return this._client}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,segment:void 0,username:void 0},this._session&&Wi(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,r){return this._tags={...this._tags,[t]:r},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,r){return this._extra={...this._extra,[t]:r},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,r){return r===null?delete this._contexts[t]:this._contexts[t]=r,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const t=this._span;return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const r=typeof t=="function"?t(this):t;if(r instanceof Vc){const n=r.getScopeData();this._tags={...this._tags,...n.tags},this._extra={...this._extra,...n.extra},this._contexts={...this._contexts,...n.contexts},n.user&&Object.keys(n.user).length&&(this._user=n.user),n.level&&(this._level=n.level),n.fingerprint.length&&(this._fingerprint=n.fingerprint),r.getRequestSession()&&(this._requestSession=r.getRequestSession()),n.propagationContext&&(this._propagationContext=n.propagationContext)}else if(Gi(r)){const n=t;this._tags={...this._tags,...n.tags},this._extra={...this._extra,...n.extra},this._contexts={...this._contexts,...n.contexts},n.user&&(this._user=n.user),n.level&&(this._level=n.level),n.fingerprint&&(this._fingerprint=n.fingerprint),n.requestSession&&(this._requestSession=n.requestSession),n.propagationContext&&(this._propagationContext=n.propagationContext)}return this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=cE(),this}addBreadcrumb(t,r){const n=typeof r=="number"?r:zD;if(n<=0)return this;const i={timestamp:ea(),...t},a=this._breadcrumbs;return a.push(i),this._breadcrumbs=a.length>n?a.slice(-n):a,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this.getScopeData().attachments}clearAttachments(){return this._attachments=[],this}getScopeData(){const{_breadcrumbs:t,_attachments:r,_contexts:n,_tags:i,_extra:a,_user:s,_level:o,_fingerprint:u,_eventProcessors:l,_propagationContext:c,_sdkProcessingMetadata:d,_transactionName:m,_span:p}=this;return{breadcrumbs:t,attachments:r,contexts:n,tags:i,extra:a,user:s,level:o,fingerprint:u||[],eventProcessors:l,propagationContext:c,sdkProcessingMetadata:d,transactionName:m,span:p}}applyToEvent(t,r={},n=[]){aO(t,this.getScopeData());const i=[...n,...Sg(),...this._eventProcessors];return Kc(i,t,r)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,r){const n=r&&r.event_id?r.event_id:pt();if(!this._client)return Re.warn("No client configured on scope - will not capture exception!"),n;const i=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:i,...r,event_id:n},this),n}captureMessage(t,r,n){const i=n&&n.event_id?n.event_id:pt();if(!this._client)return Re.warn("No client configured on scope - will not capture message!"),i;const a=new Error(t);return this._client.captureMessage(t,r,{originalException:t,syntheticException:a,...n,event_id:i},this),i}captureEvent(t,r){const n=r&&r.event_id?r.event_id:pt();return this._client?(this._client.captureEvent(t,{...r,event_id:n},this),n):(Re.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}};function WD(){return Ul||(Ul=new io),Ul}function cE(){return{traceId:pt(),spanId:pt().substring(16)}}const Ky="7.120.3",sO=parseFloat(Ky),YD=100;let oO=class{constructor(t,r,n,i=sO){this._version=i;let a;r?a=r:(a=new io,a.setClient(t));let s;n?s=n:(s=new io,s.setClient(t)),this._stack=[{scope:a}],t&&this.bindClient(t),this._isolationScope=s}isOlderThan(t){return this._version<t}bindClient(t){const r=this.getStackTop();r.client=t,r.scope.setClient(t),t&&t.setupIntegrations&&t.setupIntegrations()}pushScope(){const t=this.getScope().clone();return this.getStack().push({client:this.getClient(),scope:t}),t}popScope(){return this.getStack().length<=1?!1:!!this.getStack().pop()}withScope(t){const r=this.pushScope();let n;try{n=t(r)}catch(i){throw this.popScope(),i}return Wa(n)?n.then(i=>(this.popScope(),i),i=>{throw this.popScope(),i}):(this.popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStack(){return this._stack}getStackTop(){return this._stack[this._stack.length-1]}captureException(t,r){const n=this._lastEventId=r&&r.event_id?r.event_id:pt(),i=new Error("Sentry syntheticException");return this.getScope().captureException(t,{originalException:t,syntheticException:i,...r,event_id:n}),n}captureMessage(t,r,n){const i=this._lastEventId=n&&n.event_id?n.event_id:pt(),a=new Error(t);return this.getScope().captureMessage(t,r,{originalException:t,syntheticException:a,...n,event_id:i}),i}captureEvent(t,r){const n=r&&r.event_id?r.event_id:pt();return t.type||(this._lastEventId=n),this.getScope().captureEvent(t,{...r,event_id:n}),n}lastEventId(){return this._lastEventId}addBreadcrumb(t,r){const{scope:n,client:i}=this.getStackTop();if(!i)return;const{beforeBreadcrumb:a=null,maxBreadcrumbs:s=YD}=i.getOptions&&i.getOptions()||{};if(s<=0)return;const u={timestamp:ea(),...t},l=a?_o(()=>a(u,r)):u;l!==null&&(i.emit&&i.emit("beforeAddBreadcrumb",l,r),n.addBreadcrumb(l,s))}setUser(t){this.getScope().setUser(t),this.getIsolationScope().setUser(t)}setTags(t){this.getScope().setTags(t),this.getIsolationScope().setTags(t)}setExtras(t){this.getScope().setExtras(t),this.getIsolationScope().setExtras(t)}setTag(t,r){this.getScope().setTag(t,r),this.getIsolationScope().setTag(t,r)}setExtra(t,r){this.getScope().setExtra(t,r),this.getIsolationScope().setExtra(t,r)}setContext(t,r){this.getScope().setContext(t,r),this.getIsolationScope().setContext(t,r)}configureScope(t){const{scope:r,client:n}=this.getStackTop();n&&t(r)}run(t){const r=lE(this);try{t(this)}finally{lE(r)}}getIntegration(t){const r=this.getClient();if(!r)return null;try{return r.getIntegration(t)}catch{return It&&Re.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,r){const n=this._callExtensionMethod("startTransaction",t,r);return It&&!n&&(this.getClient()?Re.warn(`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':
|
|
9
|
+
Sentry.addTracingExtensions();
|
|
10
|
+
Sentry.init({...});
|
|
11
|
+
`):Re.warn("Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")),n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this._sendSessionUpdate()}endSession(){const r=this.getStackTop().scope,n=r.getSession();n&&Zw(n),this._sendSessionUpdate(),r.setSession()}startSession(t){const{scope:r,client:n}=this.getStackTop(),{release:i,environment:a=il}=n&&n.getOptions()||{},{userAgent:s}=at.navigator||{},o=Qw({release:i,environment:a,user:r.getUser(),...s&&{userAgent:s},...t}),u=r.getSession&&r.getSession();return u&&u.status==="ok"&&Wi(u,{status:"exited"}),this.endSession(),r.setSession(o),o}shouldSendDefaultPii(){const t=this.getClient(),r=t&&t.getOptions();return!!(r&&r.sendDefaultPii)}_sendSessionUpdate(){const{scope:t,client:r}=this.getStackTop(),n=t.getSession();n&&r&&r.captureSession&&r.captureSession(n)}_callExtensionMethod(t,...r){const i=al().__SENTRY__;if(i&&i.extensions&&typeof i.extensions[t]=="function")return i.extensions[t].apply(this,r);It&&Re.warn(`Extension method ${t} couldn't be found, doing nothing.`)}};function al(){return at.__SENTRY__=at.__SENTRY__||{extensions:{},hub:void 0},at}function lE(e){const t=al(),r=Jy(t);return uO(t,e),r}function Br(){const e=al();if(e.__SENTRY__&&e.__SENTRY__.acs){const t=e.__SENTRY__.acs.getCurrentHub();if(t)return t}return KD(e)}function sl(){return Br().getIsolationScope()}function KD(e=al()){return(!JD(e)||Jy(e).isOlderThan(sO))&&uO(e,new oO),Jy(e)}function JD(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function Jy(e){return nl("hub",()=>new oO,e)}function uO(e,t){if(!e)return!1;const r=e.__SENTRY__=e.__SENTRY__||{};return r.hub=t,!0}function XD(e,t){return t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]]),e}function QD(e,t,r,n){const i=Xw(r),a={sent_at:new Date().toISOString(),...i&&{sdk:i},...!!n&&t&&{dsn:Qi(t)}},s="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return ra(a,[s])}function ZD(e,t,r,n){const i=Xw(r),a=e.type&&e.type!=="replay_event"?e.type:"event";XD(e,r&&r.sdk);const s=mD(e,i,n,t);return delete e.sdkProcessingMetadata,ra(s,[[{type:a},e]])}const xD="7";function cO(e){const t=e.protocol?`${e.protocol}:`:"",r=e.port?`:${e.port}`:"";return`${t}//${e.host}${r}${e.path?`/${e.path}`:""}/api/`}function ej(e){return`${cO(e)}${e.projectId}/envelope/`}function tj(e,t){return SC({sentry_key:e.publicKey,sentry_version:xD,...t&&{sentry_client:`${t.name}/${t.version}`}})}function rj(e,t={}){const r=typeof t=="string"?t:t.tunnel,n=typeof t=="string"||!t._metadata?void 0:t._metadata.sdk;return r||`${ej(e)}?${tj(e,n)}`}function nj(e,t){const r=$w(e);if(!r)return"";const n=`${cO(r)}embed/error-page/`;let i=`dsn=${Qi(r)}`;for(const a in t)if(a!=="dsn"&&a!=="onClose")if(a==="user"){const s=t.user;if(!s)continue;s.name&&(i+=`&name=${encodeURIComponent(s.name)}`),s.email&&(i+=`&email=${encodeURIComponent(s.email)}`)}else i+=`&${encodeURIComponent(a)}=${encodeURIComponent(t[a])}`;return`${n}?${i}`}const dE=[];function ij(e){const t={};return e.forEach(r=>{const{name:n}=r,i=t[n];i&&!i.isDefaultInstance&&r.isDefaultInstance||(t[n]=r)}),Object.keys(t).map(r=>t[r])}function aj(e){const t=e.defaultIntegrations||[],r=e.integrations;t.forEach(s=>{s.isDefaultInstance=!0});let n;Array.isArray(r)?n=[...t,...r]:typeof r=="function"?n=Eg(r(t)):n=t;const i=ij(n),a=oj(i,s=>s.name==="Debug");if(a!==-1){const[s]=i.splice(a,1);i.push(s)}return i}function sj(e,t){const r={};return t.forEach(n=>{n&&lO(e,n,r)}),r}function fE(e,t){for(const r of t)r&&r.afterAllSetup&&r.afterAllSetup(e)}function lO(e,t,r){if(r[t.name]){It&&Re.log(`Integration skipped because it was already installed: ${t.name}`);return}if(r[t.name]=t,dE.indexOf(t.name)===-1&&(t.setupOnce(bD,Br),dE.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(e),e.on&&typeof t.preprocessEvent=="function"){const n=t.preprocessEvent.bind(t);e.on("preprocessEvent",(i,a)=>n(i,a,e))}if(e.addEventProcessor&&typeof t.processEvent=="function"){const n=t.processEvent.bind(t),i=Object.assign((a,s)=>n(a,s,e),{id:t.name});e.addEventProcessor(i)}It&&Re.log(`Integration installed: ${t.name}`)}function oj(e,t){for(let r=0;r<e.length;r++)if(t(e[r])===!0)return r;return-1}function Kn(e,t){return Object.assign(function(...n){return t(...n)},{id:e})}function uj(e){let t="";for(const r of e){const n=Object.entries(r.tags),i=n.length>0?`|#${n.map(([a,s])=>`${a}:${s}`).join(",")}`:"";t+=`${r.name}@${r.unit}:${r.metric}|${r.metricType}${i}|T${r.timestamp}
|
|
12
|
+
`}return t}function cj(e,t,r,n){const i={sent_at:new Date().toISOString()};r&&r.sdk&&(i.sdk={name:r.sdk.name,version:r.sdk.version}),n&&t&&(i.dsn=Qi(t));const a=lj(e);return ra(i,[a])}function lj(e){const t=uj(e);return[{type:"statsd",length:t.length},t]}const pE="Not capturing exception because it's already been captured.";class dj{constructor(t){if(this._options=t,this._integrations={},this._integrationsInitialized=!1,this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],t.dsn?this._dsn=$w(t.dsn):It&&Re.warn("No DSN provided, client will not send events."),this._dsn){const r=rj(this._dsn,t);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:r})}}captureException(t,r,n){if(Z_(t)){It&&Re.log(pE);return}let i=r&&r.event_id;return this._process(this.eventFromException(t,r).then(a=>this._captureEvent(a,r,n)).then(a=>{i=a})),i}captureMessage(t,r,n,i){let a=n&&n.event_id;const s=hg(t)?t:String(t),o=yg(t)?this.eventFromMessage(s,r,n):this.eventFromException(t,n);return this._process(o.then(u=>this._captureEvent(u,n,i)).then(u=>{a=u})),a}captureEvent(t,r,n){if(r&&r.originalException&&Z_(r.originalException)){It&&Re.log(pE);return}let i=r&&r.event_id;const s=(t.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(t,r,s||n).then(o=>{i=o})),i}captureSession(t){typeof t.release!="string"?It&&Re.warn("Discarded session because of missing or non-string release"):(this.sendSession(t),Wi(t,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(t){const r=this._transport;return r?(this.metricsAggregator&&this.metricsAggregator.flush(),this._isClientDoneProcessing(t).then(n=>r.flush(t).then(i=>n&&i))):Ua(!0)}close(t){return this.flush(t).then(r=>(this.getOptions().enabled=!1,this.metricsAggregator&&this.metricsAggregator.close(),r))}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}setupIntegrations(t){(t&&!this._integrationsInitialized||this._isEnabled()&&!this._integrationsInitialized)&&this._setupIntegrations()}init(){this._isEnabled()&&this._setupIntegrations()}getIntegrationById(t){return this.getIntegrationByName(t)}getIntegrationByName(t){return this._integrations[t]}getIntegration(t){try{return this._integrations[t.id]||null}catch{return It&&Re.warn(`Cannot retrieve integration ${t.id} from the current Client`),null}}addIntegration(t){const r=this._integrations[t.name];lO(this,t,this._integrations),r||fE(this,[t])}sendEvent(t,r={}){this.emit("beforeSendEvent",t,r);let n=ZD(t,this._dsn,this._options._metadata,this._options.tunnel);for(const a of r.attachments||[])n=cD(n,fD(a,this._options.transportOptions&&this._options.transportOptions.textEncoder));const i=this._sendEnvelope(n);i&&i.then(a=>this.emit("afterSendEvent",t,a),null)}sendSession(t){const r=QD(t,this._dsn,this._options._metadata,this._options.tunnel);this._sendEnvelope(r)}recordDroppedEvent(t,r,n){if(this._options.sendClientReports){const i=typeof n=="number"?n:1,a=`${t}:${r}`;It&&Re.log(`Recording outcome: "${a}"${i>1?` (${i} times)`:""}`),this._outcomes[a]=(this._outcomes[a]||0)+i}}captureAggregateMetrics(t){It&&Re.log(`Flushing aggregated metrics, number of metrics: ${t.length}`);const r=cj(t,this._dsn,this._options._metadata,this._options.tunnel);this._sendEnvelope(r)}on(t,r){this._hooks[t]||(this._hooks[t]=[]),this._hooks[t].push(r)}emit(t,...r){this._hooks[t]&&this._hooks[t].forEach(n=>n(...r))}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=sj(this,t),fE(this,t),this._integrationsInitialized=!0}_updateSessionFromEvent(t,r){let n=!1,i=!1;const a=r.exception&&r.exception.values;if(a){i=!0;for(const u of a){const l=u.mechanism;if(l&&l.handled===!1){n=!0;break}}}const s=t.status==="ok";(s&&t.errors===0||s&&n)&&(Wi(t,{...n&&{status:"crashed"},errors:t.errors||Number(i||n)}),this.captureSession(t))}_isClientDoneProcessing(t){return new yr(r=>{let n=0;const i=1,a=setInterval(()=>{this._numProcessing==0?(clearInterval(a),r(!0)):(n+=i,t&&n>=t&&(clearInterval(a),r(!1)))},i)})}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,r,n,i=sl()){const a=this.getOptions(),s=Object.keys(this._integrations);return!r.integrations&&s.length>0&&(r.integrations=s),this.emit("preprocessEvent",t,r),wD(a,t,r,n,this,i).then(o=>{if(o===null)return o;const u={...i.getPropagationContext(),...n?n.getPropagationContext():void 0};if(!(o.contexts&&o.contexts.trace)&&u){const{traceId:c,spanId:d,parentSpanId:m,dsc:p}=u;o.contexts={trace:{trace_id:c,span_id:d,parent_span_id:m},...o.contexts};const E=p||iO(c,this,n);o.sdkProcessingMetadata={dynamicSamplingContext:E,...o.sdkProcessingMetadata}}return o})}_captureEvent(t,r={},n){return this._processEvent(t,r,n).then(i=>i.event_id,i=>{if(It){const a=i;a.logLevel==="log"?Re.log(a.message):Re.warn(a)}})}_processEvent(t,r,n){const i=this.getOptions(),{sampleRate:a}=i,s=fO(t),o=dO(t),u=t.type||"error",l=`before send for type \`${u}\``;if(o&&typeof a=="number"&&Math.random()>a)return this.recordDroppedEvent("sample_rate","error",t),bg(new an(`Discarding event because it's not included in the random sample (sampling rate = ${a})`,"log"));const c=u==="replay_event"?"replay":u,m=(t.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(t,r,n,m).then(p=>{if(p===null)throw this.recordDroppedEvent("event_processor",c,t),new an("An event processor returned `null`, will not send event.","log");if(r.data&&r.data.__sentry__===!0)return p;const A=pj(i,p,r);return fj(A,l)}).then(p=>{if(p===null){if(this.recordDroppedEvent("before_send",c,t),s){const O=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",O)}throw new an(`${l} returned \`null\`, will not send event.`,"log")}const E=n&&n.getSession();if(!s&&E&&this._updateSessionFromEvent(E,p),s){const R=p.sdkProcessingMetadata&&p.sdkProcessingMetadata.spanCountBeforeProcessing||0,O=p.spans?p.spans.length:0,f=R-O;f>0&&this.recordDroppedEvent("before_send","span",f)}const A=p.transaction_info;if(s&&A&&p.transaction!==t.transaction){const R="custom";p.transaction_info={...A,source:R}}return this.sendEvent(p,r),p}).then(null,p=>{throw p instanceof an?p:(this.captureException(p,{data:{__sentry__:!0},originalException:p}),new an(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
|
|
13
|
+
Reason: ${p}`))})}_process(t){this._numProcessing++,t.then(r=>(this._numProcessing--,r),r=>(this._numProcessing--,r))}_sendEnvelope(t){if(this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport)return this._transport.send(t).then(null,r=>{It&&Re.error("Error while sending event:",r)});It&&Re.error("Transport disabled")}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.keys(t).map(r=>{const[n,i]=r.split(":");return{reason:n,category:i,quantity:t[r]}})}}function fj(e,t){const r=`${t} must return \`null\` or a valid event.`;if(Wa(e))return e.then(n=>{if(!Gi(n)&&n!==null)throw new an(r);return n},n=>{throw new an(`${t} rejected with ${n}`)});if(!Gi(e)&&e!==null)throw new an(r);return e}function pj(e,t,r){const{beforeSend:n,beforeSendTransaction:i}=e;if(dO(t)&&n)return n(t,r);if(fO(t)&&i){if(t.spans){const a=t.spans.length;t.sdkProcessingMetadata={...t.sdkProcessingMetadata,spanCountBeforeProcessing:a}}return i(t,r)}return t}function dO(e){return e.type===void 0}function fO(e){return e.type==="transaction"}function mj(e,t){t.debug===!0&&(It?Re.enable():_o(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),Eo().update(t.initialScope);const n=new e(t);hj(n),yj(n)}function hj(e){const r=Br().getStackTop();r.client=e,r.scope.setClient(e)}function yj(e){e.init?e.init():e.setupIntegrations&&e.setupIntegrations()}const gj=30;function pO(e,t,r=ZC(e.bufferSize||gj)){let n={};const i=s=>r.drain(s);function a(s){const o=[];if(nE(s,(d,m)=>{const p=iE(m);if(ED(n,p)){const E=mE(d,m);e.recordDroppedEvent("ratelimit_backoff",p,E)}else o.push(d)}),o.length===0)return Ua();const u=ra(s[0],o),l=d=>{nE(u,(m,p)=>{const E=mE(m,p);e.recordDroppedEvent(d,iE(p),E)})},c=()=>t({body:lD(u,e.textEncoder)}).then(d=>(d.statusCode!==void 0&&(d.statusCode<200||d.statusCode>=300)&&It&&Re.warn(`Sentry responded with status code ${d.statusCode} to sent event.`),n=vD(n,d),d),d=>{throw l("network_error"),d});return r.add(c).then(d=>d,d=>{if(d instanceof an)return It&&Re.error("Skipped sending event because buffer is full."),l("queue_overflow"),Ua();throw d})}return a.__sentry__baseTransport__=!0,{send:a,flush:i}}function mE(e,t){if(!(t!=="event"&&t!=="transaction"))return Array.isArray(e)?e[1]:void 0}function mO(e,t,r=[t],n="npm"){const i=e._metadata||{};i.sdk||(i.sdk={name:`sentry.javascript.${t}`,packages:r.map(a=>({name:`${n}:@sentry/${a}`,version:Ky})),version:Ky}),e._metadata=i}const _j=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/],Ej=[/^.*\/healthcheck$/,/^.*\/healthy$/,/^.*\/live$/,/^.*\/ready$/,/^.*\/heartbeat$/,/^.*\/health$/,/^.*\/healthz$/],hO="InboundFilters",vj=((e={})=>({name:hO,setupOnce(){},processEvent(t,r,n){const i=n.getOptions(),a=bj(e,i);return Tj(t,a)?null:t}})),yO=vj;Kn(hO,yO);function bj(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:_j],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[],...e.disableTransactionDefaults?[]:Ej],ignoreInternal:e.ignoreInternal!==void 0?e.ignoreInternal:!0}}function Tj(e,t){return t.ignoreInternal&&Oj(e)?(It&&Re.warn(`Event dropped due to being internal Sentry Error.
|
|
14
|
+
Event: ${kn(e)}`),!0):Sj(e,t.ignoreErrors)?(It&&Re.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
|
|
15
|
+
Event: ${kn(e)}`),!0):Ij(e,t.ignoreTransactions)?(It&&Re.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.
|
|
16
|
+
Event: ${kn(e)}`),!0):Rj(e,t.denyUrls)?(It&&Re.warn(`Event dropped due to being matched by \`denyUrls\` option.
|
|
17
|
+
Event: ${kn(e)}.
|
|
18
|
+
Url: ${Jc(e)}`),!0):Aj(e,t.allowUrls)?!1:(It&&Re.warn(`Event dropped due to not being matched by \`allowUrls\` option.
|
|
19
|
+
Event: ${kn(e)}.
|
|
20
|
+
Url: ${Jc(e)}`),!0)}function Sj(e,t){return e.type||!t||!t.length?!1:wj(e).some(r=>go(r,t))}function Ij(e,t){if(e.type!=="transaction"||!t||!t.length)return!1;const r=e.transaction;return r?go(r,t):!1}function Rj(e,t){if(!t||!t.length)return!1;const r=Jc(e);return r?go(r,t):!1}function Aj(e,t){if(!t||!t.length)return!0;const r=Jc(e);return r?go(r,t):!0}function wj(e){const t=[];e.message&&t.push(e.message);let r;try{r=e.exception.values[e.exception.values.length-1]}catch{}return r&&r.value&&(t.push(r.value),r.type&&t.push(`${r.type}: ${r.value}`)),It&&t.length===0&&Re.error(`Could not extract message for event ${kn(e)}`),t}function Oj(e){try{return e.exception.values[0].type==="SentryError"}catch{}return!1}function Nj(e=[]){for(let t=e.length-1;t>=0;t--){const r=e[t];if(r&&r.filename!=="<anonymous>"&&r.filename!=="[native code]")return r.filename||null}return null}function Jc(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch{}return t?Nj(t):null}catch{return It&&Re.error(`Cannot extract url for event ${kn(e)}`),null}}let hE;const gO="FunctionToString",yE=new WeakMap,Pj=(()=>({name:gO,setupOnce(){hE=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=_g(this),r=yE.has(cr())&&t!==void 0?t:this;return hE.apply(r,e)}}catch{}},setup(e){yE.set(e,!0)}})),_O=Pj;Kn(gO,_O);const dt=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,EO="production";function Mj(){return nl("globalEventProcessors",()=>[])}function Xy(e,t,r,n=0){return new yr((i,a)=>{const s=e[n];if(t===null||typeof s!="function")i(t);else{const o=s({...t},r);dt&&s.id&&o===null&&Re.log(`Event processor "${s.id}" dropped event`),Wa(o)?o.then(u=>Xy(e,u,r,n+1).then(i)).then(null,a):Xy(e,o,r,n+1).then(i).then(null,a)}})}function Cj(e){const t=ta(),r={sid:pt(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>jj(r)};return e&&ol(r,e),r}function ol(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||ta(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:pt()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const r=e.timestamp-e.started;e.duration=r>=0?r:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function Dj(e,t){let r={};e.status==="ok"&&(r={status:"exited"}),ol(e,r)}function jj(e){return kt({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}const $j=0,vO=1;function Rg(e){const{spanId:t,traceId:r}=e.spanContext(),{data:n,op:i,parent_span_id:a,status:s,tags:o,origin:u}=gr(e);return kt({data:n,op:i,parent_span_id:a,span_id:t,status:s,tags:o,trace_id:r,origin:u})}function ul(e){const{traceId:t,spanId:r}=e.spanContext(),n=Ag(e);return Tg(t,r,n)}function cl(e){return typeof e=="number"?gE(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?gE(e.getTime()):ta()}function gE(e){return e>9999999999?e/1e3:e}function gr(e){return Lj(e)?e.getSpanJSON():typeof e.toJSON=="function"?e.toJSON():{}}function Lj(e){return typeof e.getSpanJSON=="function"}function Ag(e){const{traceFlags:t}=e.spanContext();return!!(t&vO)}function Ka(){return Xa().getClient()}function Ja(){return Xa().getScope()}function Xc(e){return e.transaction}function wg(e,t,r){const n=t.getOptions(),{publicKey:i}=t.getDsn()||{},{segment:a}=r&&r.getUser()||{},s=kt({environment:n.environment||EO,release:n.release,user_segment:a,public_key:i,trace_id:e});return t.emit&&t.emit("createDsc",s),s}function Fa(e){const t=Ka();if(!t)return{};const r=wg(gr(e).trace_id||"",t,Ja()),n=Xc(e);if(!n)return r;const i=n&&n._frozenDynamicSamplingContext;if(i)return i;const{sampleRate:a,source:s}=n.metadata;a!=null&&(r.sample_rate=`${a}`);const o=gr(n);return s&&s!=="url"&&(r.transaction=o.description),r.sampled=String(Ag(n)),t.emit&&t.emit("createDsc",r),r}function qj(e,t){const{fingerprint:r,span:n,breadcrumbs:i,sdkProcessingMetadata:a}=t;kj(e,t),n&&Fj(e,n),Vj(e,r),Bj(e,i),Uj(e,a)}function kj(e,t){const{extra:r,tags:n,user:i,contexts:a,level:s,transactionName:o}=t,u=kt(r);u&&Object.keys(u).length&&(e.extra={...u,...e.extra});const l=kt(n);l&&Object.keys(l).length&&(e.tags={...l,...e.tags});const c=kt(i);c&&Object.keys(c).length&&(e.user={...c,...e.user});const d=kt(a);d&&Object.keys(d).length&&(e.contexts={...d,...e.contexts}),s&&(e.level=s),o&&(e.transaction=o)}function Bj(e,t){const r=[...e.breadcrumbs||[],...t];e.breadcrumbs=r.length?r:void 0}function Uj(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function Fj(e,t){e.contexts={trace:Rg(t),...e.contexts};const r=Xc(t);if(r){e.sdkProcessingMetadata={dynamicSamplingContext:Fa(t),...e.sdkProcessingMetadata};const n=gr(r).description;n&&(e.tags={transaction:n,...e.tags})}}function Vj(e,t){e.fingerprint=e.fingerprint?Eg(e.fingerprint):[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint}const Hj=100;class Sa{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=_E()}static clone(t){return t?t.clone():new Sa}clone(){const t=new Sa;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._extra={...this._extra},t._contexts={...this._contexts},t._user=this._user,t._level=this._level,t._span=this._span,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._requestSession=this._requestSession,t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t}setClient(t){this._client=t}getClient(){return this._client}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,segment:void 0,username:void 0},this._session&&ol(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,r){return this._tags={...this._tags,[t]:r},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,r){return this._extra={...this._extra,[t]:r},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,r){return r===null?delete this._contexts[t]:this._contexts[t]=r,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const t=this._span;return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const r=typeof t=="function"?t(this):t;if(r instanceof Sa){const n=r.getScopeData();this._tags={...this._tags,...n.tags},this._extra={...this._extra,...n.extra},this._contexts={...this._contexts,...n.contexts},n.user&&Object.keys(n.user).length&&(this._user=n.user),n.level&&(this._level=n.level),n.fingerprint.length&&(this._fingerprint=n.fingerprint),r.getRequestSession()&&(this._requestSession=r.getRequestSession()),n.propagationContext&&(this._propagationContext=n.propagationContext)}else if(Gi(r)){const n=t;this._tags={...this._tags,...n.tags},this._extra={...this._extra,...n.extra},this._contexts={...this._contexts,...n.contexts},n.user&&(this._user=n.user),n.level&&(this._level=n.level),n.fingerprint&&(this._fingerprint=n.fingerprint),n.requestSession&&(this._requestSession=n.requestSession),n.propagationContext&&(this._propagationContext=n.propagationContext)}return this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=_E(),this}addBreadcrumb(t,r){const n=typeof r=="number"?r:Hj;if(n<=0)return this;const i={timestamp:ea(),...t},a=this._breadcrumbs;return a.push(i),this._breadcrumbs=a.length>n?a.slice(-n):a,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this.getScopeData().attachments}clearAttachments(){return this._attachments=[],this}getScopeData(){const{_breadcrumbs:t,_attachments:r,_contexts:n,_tags:i,_extra:a,_user:s,_level:o,_fingerprint:u,_eventProcessors:l,_propagationContext:c,_sdkProcessingMetadata:d,_transactionName:m,_span:p}=this;return{breadcrumbs:t,attachments:r,contexts:n,tags:i,extra:a,user:s,level:o,fingerprint:u||[],eventProcessors:l,propagationContext:c,sdkProcessingMetadata:d,transactionName:m,span:p}}applyToEvent(t,r={},n=[]){qj(t,this.getScopeData());const i=[...n,...Mj(),...this._eventProcessors];return Xy(i,t,r)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,r){const n=r&&r.event_id?r.event_id:pt();if(!this._client)return Re.warn("No client configured on scope - will not capture exception!"),n;const i=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:i,...r,event_id:n},this),n}captureMessage(t,r,n){const i=n&&n.event_id?n.event_id:pt();if(!this._client)return Re.warn("No client configured on scope - will not capture message!"),i;const a=new Error(t);return this._client.captureMessage(t,r,{originalException:t,syntheticException:a,...n,event_id:i},this),i}captureEvent(t,r){const n=r&&r.event_id?r.event_id:pt();return this._client?(this._client.captureEvent(t,{...r,event_id:n},this),n):(Re.warn("No client configured on scope - will not capture event!"),n)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}function _E(){return{traceId:pt(),spanId:pt().substring(16)}}const Gj="7.120.3",bO=parseFloat(Gj),zj=100;class TO{constructor(t,r,n,i=bO){this._version=i;let a;r?a=r:(a=new Sa,a.setClient(t));let s;n?s=n:(s=new Sa,s.setClient(t)),this._stack=[{scope:a}],t&&this.bindClient(t),this._isolationScope=s}isOlderThan(t){return this._version<t}bindClient(t){const r=this.getStackTop();r.client=t,r.scope.setClient(t),t&&t.setupIntegrations&&t.setupIntegrations()}pushScope(){const t=this.getScope().clone();return this.getStack().push({client:this.getClient(),scope:t}),t}popScope(){return this.getStack().length<=1?!1:!!this.getStack().pop()}withScope(t){const r=this.pushScope();let n;try{n=t(r)}catch(i){throw this.popScope(),i}return Wa(n)?n.then(i=>(this.popScope(),i),i=>{throw this.popScope(),i}):(this.popScope(),n)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStack(){return this._stack}getStackTop(){return this._stack[this._stack.length-1]}captureException(t,r){const n=this._lastEventId=r&&r.event_id?r.event_id:pt(),i=new Error("Sentry syntheticException");return this.getScope().captureException(t,{originalException:t,syntheticException:i,...r,event_id:n}),n}captureMessage(t,r,n){const i=this._lastEventId=n&&n.event_id?n.event_id:pt(),a=new Error(t);return this.getScope().captureMessage(t,r,{originalException:t,syntheticException:a,...n,event_id:i}),i}captureEvent(t,r){const n=r&&r.event_id?r.event_id:pt();return t.type||(this._lastEventId=n),this.getScope().captureEvent(t,{...r,event_id:n}),n}lastEventId(){return this._lastEventId}addBreadcrumb(t,r){const{scope:n,client:i}=this.getStackTop();if(!i)return;const{beforeBreadcrumb:a=null,maxBreadcrumbs:s=zj}=i.getOptions&&i.getOptions()||{};if(s<=0)return;const u={timestamp:ea(),...t},l=a?_o(()=>a(u,r)):u;l!==null&&(i.emit&&i.emit("beforeAddBreadcrumb",l,r),n.addBreadcrumb(l,s))}setUser(t){this.getScope().setUser(t),this.getIsolationScope().setUser(t)}setTags(t){this.getScope().setTags(t),this.getIsolationScope().setTags(t)}setExtras(t){this.getScope().setExtras(t),this.getIsolationScope().setExtras(t)}setTag(t,r){this.getScope().setTag(t,r),this.getIsolationScope().setTag(t,r)}setExtra(t,r){this.getScope().setExtra(t,r),this.getIsolationScope().setExtra(t,r)}setContext(t,r){this.getScope().setContext(t,r),this.getIsolationScope().setContext(t,r)}configureScope(t){const{scope:r,client:n}=this.getStackTop();n&&t(r)}run(t){const r=EE(this);try{t(this)}finally{EE(r)}}getIntegration(t){const r=this.getClient();if(!r)return null;try{return r.getIntegration(t)}catch{return dt&&Re.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,r){const n=this._callExtensionMethod("startTransaction",t,r);return dt&&!n&&(this.getClient()?Re.warn(`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init':
|
|
21
|
+
Sentry.addTracingExtensions();
|
|
22
|
+
Sentry.init({...});
|
|
23
|
+
`):Re.warn("Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")),n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this._sendSessionUpdate()}endSession(){const r=this.getStackTop().scope,n=r.getSession();n&&Dj(n),this._sendSessionUpdate(),r.setSession()}startSession(t){const{scope:r,client:n}=this.getStackTop(),{release:i,environment:a=EO}=n&&n.getOptions()||{},{userAgent:s}=at.navigator||{},o=Cj({release:i,environment:a,user:r.getUser(),...s&&{userAgent:s},...t}),u=r.getSession&&r.getSession();return u&&u.status==="ok"&&ol(u,{status:"exited"}),this.endSession(),r.setSession(o),o}shouldSendDefaultPii(){const t=this.getClient(),r=t&&t.getOptions();return!!(r&&r.sendDefaultPii)}_sendSessionUpdate(){const{scope:t,client:r}=this.getStackTop(),n=t.getSession();n&&r&&r.captureSession&&r.captureSession(n)}_callExtensionMethod(t,...r){const i=vo().__SENTRY__;if(i&&i.extensions&&typeof i.extensions[t]=="function")return i.extensions[t].apply(this,r);dt&&Re.warn(`Extension method ${t} couldn't be found, doing nothing.`)}}function vo(){return at.__SENTRY__=at.__SENTRY__||{extensions:{},hub:void 0},at}function EE(e){const t=vo(),r=Qy(t);return SO(t,e),r}function Xa(){const e=vo();if(e.__SENTRY__&&e.__SENTRY__.acs){const t=e.__SENTRY__.acs.getCurrentHub();if(t)return t}return Wj(e)}function Og(){return Xa().getIsolationScope()}function Wj(e=vo()){return(!Yj(e)||Qy(e).isOlderThan(bO))&&SO(e,new TO),Qy(e)}function Yj(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function Qy(e){return nl("hub",()=>new TO,e)}function SO(e,t){if(!e)return!1;const r=e.__SENTRY__=e.__SENTRY__||{};return r.hub=t,!0}function Ki(e){return Xa().getScope().getTransaction()}let vE=!1;function Kj(){vE||(vE=!0,Hw(Zy),Gw(Zy))}function Zy(){const e=Ki();if(e){const t="internal_error";dt&&Re.log(`[Tracing] Transaction: ${t} -> Global error occured`),e.setStatus(t)}}Zy.tag="sentry_tracingErrorCallback";var bE;(function(e){e.Ok="ok";const r="deadline_exceeded";e.DeadlineExceeded=r;const n="unauthenticated";e.Unauthenticated=n;const i="permission_denied";e.PermissionDenied=i;const a="not_found";e.NotFound=a;const s="resource_exhausted";e.ResourceExhausted=s;const o="invalid_argument";e.InvalidArgument=o;const u="unimplemented";e.Unimplemented=u;const l="unavailable";e.Unavailable=l;const c="internal_error";e.InternalError=c;const d="unknown_error";e.UnknownError=d;const m="cancelled";e.Cancelled=m;const p="already_exists";e.AlreadyExists=p;const E="failed_precondition";e.FailedPrecondition=E;const A="aborted";e.Aborted=A;const R="out_of_range";e.OutOfRange=R;const O="data_loss";e.DataLoss=O})(bE||(bE={}));function Jj(e){if(e<400&&e>=100)return"ok";if(e>=400&&e<500)switch(e){case 401:return"unauthenticated";case 403:return"permission_denied";case 404:return"not_found";case 409:return"already_exists";case 413:return"failed_precondition";case 429:return"resource_exhausted";default:return"invalid_argument"}if(e>=500&&e<600)switch(e){case 501:return"unimplemented";case 503:return"unavailable";case 504:return"deadline_exceeded";default:return"internal_error"}return"unknown_error"}function Ng(e,t){e.setTag("http.status_code",String(t)),e.setData("http.response.status_code",t);const r=Jj(t);r!=="unknown_error"&&e.setStatus(r)}function Qa(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=Ka(),r=e||t&&t.getOptions();return!!r&&(r.enableTracing||"tracesSampleRate"in r||"tracesSampler"in r)}function IO(e){if(!Qa())return;const t=Zj(e),r=Xa(),n=e.scope?e.scope.getSpan():Xj();if(e.onlyIfParent&&!n)return;const s=(e.scope||Ja()).clone();return Qj(r,{parentSpan:n,spanContext:t,forceTransaction:e.forceTransaction,scope:s})}function Xj(){return Ja().getSpan()}function Qj(e,{parentSpan:t,spanContext:r,forceTransaction:n,scope:i}){if(!Qa())return;const a=Og();let s;if(t&&!n)s=t.startChild(r);else if(t){const o=Fa(t),{traceId:u,spanId:l}=t.spanContext(),c=Ag(t);s=e.startTransaction({traceId:u,parentSpanId:l,parentSampled:c,...r,metadata:{dynamicSamplingContext:o,...r.metadata}})}else{const{traceId:o,dsc:u,parentSpanId:l,sampled:c}={...a.getPropagationContext(),...i.getPropagationContext()};s=e.startTransaction({traceId:o,parentSpanId:l,parentSampled:c,...r,metadata:{dynamicSamplingContext:u,...r.metadata}})}return i.setSpan(s),xj(s,i,a),s}function Zj(e){if(e.startTime){const t={...e};return t.startTimestamp=cl(e.startTime),delete t.startTime,t}return e}const RO="_sentryScope",AO="_sentryIsolationScope";function xj(e,t,r){e&&(zi(e,AO,r),zi(e,RO,t))}function e$(e){return{scope:e[RO],isolationScope:e[AO]}}const Ia="sentry.source",Ea="sentry.sample_rate",Au="sentry.op",va="sentry.origin",t$="profile_id";class wO{constructor(t=1e3){this._maxlen=t,this.spans=[]}add(t){this.spans.length>this._maxlen?t.spanRecorder=void 0:this.spans.push(t)}}class ll{constructor(t={}){this._traceId=t.traceId||pt(),this._spanId=t.spanId||pt().substring(16),this._startTime=t.startTimestamp||ta(),this.tags=t.tags?{...t.tags}:{},this.data=t.data?{...t.data}:{},this.instrumenter=t.instrumenter||"sentry",this._attributes={},this.setAttributes({[va]:t.origin||"manual",[Au]:t.op,...t.attributes}),this._name=t.name||t.description,t.parentSpanId&&(this._parentSpanId=t.parentSpanId),"sampled"in t&&(this._sampled=t.sampled),t.status&&(this._status=t.status),t.endTimestamp&&(this._endTime=t.endTimestamp),t.exclusiveTime!==void 0&&(this._exclusiveTime=t.exclusiveTime),this._measurements=t.measurements?{...t.measurements}:{}}get name(){return this._name||""}set name(t){this.updateName(t)}get description(){return this._name}set description(t){this._name=t}get traceId(){return this._traceId}set traceId(t){this._traceId=t}get spanId(){return this._spanId}set spanId(t){this._spanId=t}set parentSpanId(t){this._parentSpanId=t}get parentSpanId(){return this._parentSpanId}get sampled(){return this._sampled}set sampled(t){this._sampled=t}get attributes(){return this._attributes}set attributes(t){this._attributes=t}get startTimestamp(){return this._startTime}set startTimestamp(t){this._startTime=t}get endTimestamp(){return this._endTime}set endTimestamp(t){this._endTime=t}get status(){return this._status}set status(t){this._status=t}get op(){return this._attributes[Au]}set op(t){this.setAttribute(Au,t)}get origin(){return this._attributes[va]}set origin(t){this.setAttribute(va,t)}spanContext(){const{_spanId:t,_traceId:r,_sampled:n}=this;return{spanId:t,traceId:r,traceFlags:n?vO:$j}}startChild(t){const r=new ll({...t,parentSpanId:this._spanId,sampled:this._sampled,traceId:this._traceId});r.spanRecorder=this.spanRecorder,r.spanRecorder&&r.spanRecorder.add(r);const n=Xc(this);if(r.transaction=n,dt&&n){const i=t&&t.op||"< unknown op >",a=gr(r).description||"< unknown name >",s=n.spanContext().spanId,o=`[Tracing] Starting '${i}' span on transaction '${a}' (${s}).`;Re.log(o),this._logMessage=o}return r}setTag(t,r){return this.tags={...this.tags,[t]:r},this}setData(t,r){return this.data={...this.data,[t]:r},this}setAttribute(t,r){r===void 0?delete this._attributes[t]:this._attributes[t]=r}setAttributes(t){Object.keys(t).forEach(r=>this.setAttribute(r,t[r]))}setStatus(t){return this._status=t,this}setHttpStatus(t){return Ng(this,t),this}setName(t){this.updateName(t)}updateName(t){return this._name=t,this}isSuccess(){return this._status==="ok"}finish(t){return this.end(t)}end(t){if(this._endTime)return;const r=Xc(this);if(dt&&r&&r.spanContext().spanId!==this._spanId){const n=this._logMessage;n&&Re.log(n.replace("Starting","Finishing"))}this._endTime=cl(t)}toTraceparent(){return ul(this)}toContext(){return kt({data:this._getData(),description:this._name,endTimestamp:this._endTime,op:this.op,parentSpanId:this._parentSpanId,sampled:this._sampled,spanId:this._spanId,startTimestamp:this._startTime,status:this._status,tags:this.tags,traceId:this._traceId})}updateWithContext(t){return this.data=t.data||{},this._name=t.name||t.description,this._endTime=t.endTimestamp,this.op=t.op,this._parentSpanId=t.parentSpanId,this._sampled=t.sampled,this._spanId=t.spanId||this._spanId,this._startTime=t.startTimestamp||this._startTime,this._status=t.status,this.tags=t.tags||{},this._traceId=t.traceId||this._traceId,this}getTraceContext(){return Rg(this)}getSpanJSON(){return kt({data:this._getData(),description:this._name,op:this._attributes[Au],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:this._status,tags:Object.keys(this.tags).length>0?this.tags:void 0,timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[va],_metrics_summary:void 0,profile_id:this._attributes[t$],exclusive_time:this._exclusiveTime,measurements:Object.keys(this._measurements).length>0?this._measurements:void 0})}isRecording(){return!this._endTime&&!!this._sampled}toJSON(){return this.getSpanJSON()}_getData(){const{data:t,_attributes:r}=this,n=Object.keys(t).length>0,i=Object.keys(r).length>0;if(!(!n&&!i))return n&&i?{...t,...r}:n?t:r}}class OO extends ll{constructor(t,r){super(t),this._contexts={},this._hub=r||Xa(),this._name=t.name||"",this._metadata={...t.metadata},this._trimEnd=t.trimEnd,this.transaction=this;const n=this._metadata.dynamicSamplingContext;n&&(this._frozenDynamicSamplingContext={...n})}get name(){return this._name}set name(t){this.setName(t)}get metadata(){return{source:"custom",spanMetadata:{},...this._metadata,...this._attributes[Ia]&&{source:this._attributes[Ia]},...this._attributes[Ea]&&{sampleRate:this._attributes[Ea]}}}set metadata(t){this._metadata=t}setName(t,r="custom"){this._name=t,this.setAttribute(Ia,r)}updateName(t){return this._name=t,this}initSpanRecorder(t=1e3){this.spanRecorder||(this.spanRecorder=new wO(t)),this.spanRecorder.add(this)}setContext(t,r){r===null?delete this._contexts[t]:this._contexts[t]=r}setMeasurement(t,r,n=""){this._measurements[t]={value:r,unit:n}}setMetadata(t){this._metadata={...this._metadata,...t}}end(t){const r=cl(t),n=this._finishTransaction(r);if(n)return this._hub.captureEvent(n)}toContext(){const t=super.toContext();return kt({...t,name:this._name,trimEnd:this._trimEnd})}updateWithContext(t){return super.updateWithContext(t),this._name=t.name||"",this._trimEnd=t.trimEnd,this}getDynamicSamplingContext(){return Fa(this)}setHub(t){this._hub=t}getProfileId(){if(this._contexts!==void 0&&this._contexts.profile!==void 0)return this._contexts.profile.profile_id}_finishTransaction(t){if(this._endTime!==void 0)return;this._name||(dt&&Re.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>"),super.end(t);const r=this._hub.getClient();if(r&&r.emit&&r.emit("finishTransaction",this),this._sampled!==!0){dt&&Re.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),r&&r.recordDroppedEvent("sample_rate","transaction");return}const n=this.spanRecorder?this.spanRecorder.spans.filter(c=>c!==this&&gr(c).timestamp):[];if(this._trimEnd&&n.length>0){const c=n.map(d=>gr(d).timestamp).filter(Boolean);this._endTime=c.reduce((d,m)=>d>m?d:m)}const{scope:i,isolationScope:a}=e$(this),{metadata:s}=this,{source:o}=s,u={contexts:{...this._contexts,trace:Rg(this)},spans:n,start_timestamp:this._startTime,tags:this.tags,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{...s,capturedSpanScope:i,capturedSpanIsolationScope:a,...kt({dynamicSamplingContext:Fa(this)})},_metrics_summary:void 0,...o&&{transaction_info:{source:o}}};return Object.keys(this._measurements).length>0&&(dt&&Re.log("[Measurements] Adding measurements to transaction",JSON.stringify(this._measurements,void 0,2)),u.measurements=this._measurements),dt&&Re.log(`[Tracing] Finishing ${this.op} transaction: ${this._name}.`),u}}const Hc={idleTimeout:1e3,finalTimeout:3e4,heartbeatInterval:5e3},r$="finishReason",fa=["heartbeatFailed","idleTimeout","documentHidden","finalTimeout","externalFinish","cancelled"];class n$ extends wO{constructor(t,r,n,i){super(i),this._pushActivity=t,this._popActivity=r,this.transactionSpanId=n}add(t){if(t.spanContext().spanId!==this.transactionSpanId){const r=t.end;t.end=(...n)=>(this._popActivity(t.spanContext().spanId),r.apply(t,n)),gr(t).timestamp===void 0&&this._pushActivity(t.spanContext().spanId)}super.add(t)}}class i$ extends OO{constructor(t,r,n=Hc.idleTimeout,i=Hc.finalTimeout,a=Hc.heartbeatInterval,s=!1,o=!1){super(t,r),this._idleHub=r,this._idleTimeout=n,this._finalTimeout=i,this._heartbeatInterval=a,this._onScope=s,this.activities={},this._heartbeatCounter=0,this._finished=!1,this._idleTimeoutCanceledPermanently=!1,this._beforeFinishCallbacks=[],this._finishReason=fa[4],this._autoFinishAllowed=!o,s&&(dt&&Re.log(`Setting idle transaction on scope. Span ID: ${this.spanContext().spanId}`),r.getScope().setSpan(this)),o||this._restartIdleTimeout(),setTimeout(()=>{this._finished||(this.setStatus("deadline_exceeded"),this._finishReason=fa[3],this.end())},this._finalTimeout)}end(t){const r=cl(t);if(this._finished=!0,this.activities={},this.op==="ui.action.click"&&this.setAttribute(r$,this._finishReason),this.spanRecorder){dt&&Re.log("[Tracing] finishing IdleTransaction",new Date(r*1e3).toISOString(),this.op);for(const n of this._beforeFinishCallbacks)n(this,r);this.spanRecorder.spans=this.spanRecorder.spans.filter(n=>{if(n.spanContext().spanId===this.spanContext().spanId)return!0;gr(n).timestamp||(n.setStatus("cancelled"),n.end(r),dt&&Re.log("[Tracing] cancelling span since transaction ended early",JSON.stringify(n,void 0,2)));const{start_timestamp:i,timestamp:a}=gr(n),s=i&&i<r,o=(this._finalTimeout+this._idleTimeout)/1e3,u=a&&i&&a-i<o;if(dt){const l=JSON.stringify(n,void 0,2);s?u||Re.log("[Tracing] discarding Span since it finished after Transaction final timeout",l):Re.log("[Tracing] discarding Span since it happened after Transaction was finished",l)}return s&&u}),dt&&Re.log("[Tracing] flushing IdleTransaction")}else dt&&Re.log("[Tracing] No active IdleTransaction");if(this._onScope){const n=this._idleHub.getScope();n.getTransaction()===this&&n.setSpan(void 0)}return super.end(t)}registerBeforeFinishCallback(t){this._beforeFinishCallbacks.push(t)}initSpanRecorder(t){if(!this.spanRecorder){const r=i=>{this._finished||this._pushActivity(i)},n=i=>{this._finished||this._popActivity(i)};this.spanRecorder=new n$(r,n,this.spanContext().spanId,t),dt&&Re.log("Starting heartbeat"),this._pingHeartbeat()}this.spanRecorder.add(this)}cancelIdleTimeout(t,{restartOnChildSpanChange:r}={restartOnChildSpanChange:!0}){this._idleTimeoutCanceledPermanently=r===!1,this._idleTimeoutID&&(clearTimeout(this._idleTimeoutID),this._idleTimeoutID=void 0,Object.keys(this.activities).length===0&&this._idleTimeoutCanceledPermanently&&(this._finishReason=fa[5],this.end(t)))}setFinishReason(t){this._finishReason=t}sendAutoFinishSignal(){this._autoFinishAllowed||(dt&&Re.log("[Tracing] Received finish signal for idle transaction."),this._restartIdleTimeout(),this._autoFinishAllowed=!0)}_restartIdleTimeout(t){this.cancelIdleTimeout(),this._idleTimeoutID=setTimeout(()=>{!this._finished&&Object.keys(this.activities).length===0&&(this._finishReason=fa[1],this.end(t))},this._idleTimeout)}_pushActivity(t){this.cancelIdleTimeout(void 0,{restartOnChildSpanChange:!this._idleTimeoutCanceledPermanently}),dt&&Re.log(`[Tracing] pushActivity: ${t}`),this.activities[t]=!0,dt&&Re.log("[Tracing] new activities count",Object.keys(this.activities).length)}_popActivity(t){if(this.activities[t]&&(dt&&Re.log(`[Tracing] popActivity ${t}`),delete this.activities[t],dt&&Re.log("[Tracing] new activities count",Object.keys(this.activities).length)),Object.keys(this.activities).length===0){const r=ta();this._idleTimeoutCanceledPermanently?this._autoFinishAllowed&&(this._finishReason=fa[5],this.end(r)):this._restartIdleTimeout(r+this._idleTimeout/1e3)}}_beat(){if(this._finished)return;const t=Object.keys(this.activities).join("");t===this._prevHeartbeatString?this._heartbeatCounter++:this._heartbeatCounter=1,this._prevHeartbeatString=t,this._heartbeatCounter>=3?this._autoFinishAllowed&&(dt&&Re.log("[Tracing] Transaction finished because of no change for 3 heart beats"),this.setStatus("deadline_exceeded"),this._finishReason=fa[0],this.end()):this._pingHeartbeat()}_pingHeartbeat(){dt&&Re.log(`pinging Heartbeat -> current counter: ${this._heartbeatCounter}`),setTimeout(()=>{this._beat()},this._heartbeatInterval)}}function NO(e,t,r){if(!Qa(t))return e.sampled=!1,e;if(e.sampled!==void 0)return e.setAttribute(Ea,Number(e.sampled)),e;let n;return typeof t.tracesSampler=="function"?(n=t.tracesSampler(r),e.setAttribute(Ea,Number(n))):r.parentSampled!==void 0?n=r.parentSampled:typeof t.tracesSampleRate<"u"?(n=t.tracesSampleRate,e.setAttribute(Ea,Number(n))):(n=1,e.setAttribute(Ea,n)),PO(n)?n?(e.sampled=Math.random()<n,e.sampled?(dt&&Re.log(`[Tracing] starting ${e.op} transaction - ${gr(e).description}`),e):(dt&&Re.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(n)})`),e)):(dt&&Re.log(`[Tracing] Discarding transaction because ${typeof t.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),e.sampled=!1,e):(dt&&Re.warn("[Tracing] Discarding transaction because of invalid sample rate."),e.sampled=!1,e)}function PO(e){return Mw(e)||!(typeof e=="number"||typeof e=="boolean")?(dt&&Re.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`),!1):e<0||e>1?(dt&&Re.warn(`[Tracing] Given sample rate is invalid. Sample rate must be between 0 and 1. Got ${e}.`),!1):!0}function a$(){const t=this.getScope().getSpan();return t?{"sentry-trace":ul(t)}:{}}function s$(e,t){const r=this.getClient(),n=r&&r.getOptions()||{},i=n.instrumenter||"sentry",a=e.instrumenter||"sentry";i!==a&&(dt&&Re.error(`A transaction was started with instrumenter=\`${a}\`, but the SDK is configured with the \`${i}\` instrumenter.
|
|
24
|
+
The transaction will not be sampled. Please use the ${i} instrumentation to start transactions.`),e.sampled=!1);let s=new OO(e,this);return s=NO(s,n,{name:e.name,parentSampled:e.parentSampled,transactionContext:e,attributes:{...e.data,...e.attributes},...t}),s.isRecording()&&s.initSpanRecorder(n._experiments&&n._experiments.maxSpans),r&&r.emit&&r.emit("startTransaction",s),s}function TE(e,t,r,n,i,a,s,o=!1){const u=e.getClient(),l=u&&u.getOptions()||{};let c=new i$(t,e,r,n,s,i,o);return c=NO(c,l,{name:t.name,parentSampled:t.parentSampled,transactionContext:t,attributes:{...t.data,...t.attributes},...a}),c.isRecording()&&c.initSpanRecorder(l._experiments&&l._experiments.maxSpans),u&&u.emit&&u.emit("startTransaction",c),c}function o$(){const e=vo();e.__SENTRY__&&(e.__SENTRY__.extensions=e.__SENTRY__.extensions||{},e.__SENTRY__.extensions.startTransaction||(e.__SENTRY__.extensions.startTransaction=s$),e.__SENTRY__.extensions.traceHeaders||(e.__SENTRY__.extensions.traceHeaders=a$),Kj())}function u$(e,t,r){const n=Ki();n&&n.setMeasurement(e,t,r)}function c$(e,t){const r={sent_at:new Date().toISOString()};t&&(r.dsn=Qi(t));const n=e.map(l$);return ra(r,n)}function l$(e){return[{type:"span"},e]}const Rt=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Xe=at;function d$(){Xe.document?Xe.document.addEventListener("visibilitychange",()=>{const e=Ki();if(Xe.document.hidden&&e){const t="cancelled",{op:r,status:n}=gr(e);Rt&&Re.log(`[Tracing] Transaction: ${t} -> since tab moved to the background, op: ${r}`),n||e.setStatus(t),e.setTag("visibilitychange","document.hidden"),e.end()}}):Rt&&Re.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const bo=(e,t,r)=>{let n,i;return a=>{t.value>=0&&(a||r)&&(i=t.value-(n||0),(i||n===void 0)&&(n=t.value,t.delta=i,e(t)))}},f$=()=>`v3-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,p$=()=>{const e=Xe.performance.timing,t=Xe.performance.navigation.type,r={entryType:"navigation",startTime:0,type:t==2?"back_forward":t===1?"reload":"navigate"};for(const n in e)n!=="navigationStart"&&n!=="toJSON"&&(r[n]=Math.max(e[n]-e.navigationStart,0));return r},dl=()=>Xe.__WEB_VITALS_POLYFILL__?Xe.performance&&(performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]||p$()):Xe.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0],Pg=()=>{const e=dl();return e&&e.activationStart||0},To=(e,t)=>{const r=dl();let n="navigate";return r&&(Xe.document&&Xe.document.prerendering||Pg()>0?n="prerender":n=r.type.replace(/_/g,"-")),{name:e,value:typeof t>"u"?-1:t,rating:"good",delta:0,entries:[],id:f$(),navigationType:n}},Za=(e,t,r)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const n=new PerformanceObserver(i=>{t(i.getEntries())});return n.observe(Object.assign({type:e,buffered:!0},r||{})),n}}catch{}},So=(e,t)=>{const r=n=>{(n.type==="pagehide"||Xe.document.visibilityState==="hidden")&&(e(n),t&&(removeEventListener("visibilitychange",r,!0),removeEventListener("pagehide",r,!0)))};Xe.document&&(addEventListener("visibilitychange",r,!0),addEventListener("pagehide",r,!0))},m$=(e,t={})=>{const r=To("CLS",0);let n,i=0,a=[];const s=u=>{u.forEach(l=>{if(!l.hadRecentInput){const c=a[0],d=a[a.length-1];i&&a.length!==0&&l.startTime-d.startTime<1e3&&l.startTime-c.startTime<5e3?(i+=l.value,a.push(l)):(i=l.value,a=[l]),i>r.value&&(r.value=i,r.entries=a,n&&n())}})},o=Za("layout-shift",s);if(o){n=bo(e,r,t.reportAllChanges);const u=()=>{s(o.takeRecords()),n(!0)};return So(u),u}};let Qc=-1;const h$=()=>{Xe.document&&Xe.document.visibilityState&&(Qc=Xe.document.visibilityState==="hidden"&&!Xe.document.prerendering?0:1/0)},y$=()=>{So(({timeStamp:e})=>{Qc=e},!0)},Mg=()=>(Qc<0&&(h$(),y$()),{get firstHiddenTime(){return Qc}}),g$=e=>{const t=Mg(),r=To("FID");let n;const i=o=>{o.startTime<t.firstHiddenTime&&(r.value=o.processingStart-o.startTime,r.entries.push(o),n(!0))},a=o=>{o.forEach(i)},s=Za("first-input",a);n=bo(e,r),s&&So(()=>{a(s.takeRecords()),s.disconnect()},!0)};let MO=0,Fl=1/0,wu=0;const _$=e=>{e.forEach(t=>{t.interactionId&&(Fl=Math.min(Fl,t.interactionId),wu=Math.max(wu,t.interactionId),MO=wu?(wu-Fl)/7+1:0)})};let xy;const E$=()=>xy?MO:performance.interactionCount||0,v$=()=>{"interactionCount"in performance||xy||(xy=Za("event",_$,{type:"event",buffered:!0,durationThreshold:0}))},CO=()=>E$(),SE=10,Sn=[],Vl={},IE=e=>{const t=Sn[Sn.length-1],r=Vl[e.interactionId];if(r||Sn.length<SE||e.duration>t.latency){if(r)r.entries.push(e),r.latency=Math.max(r.latency,e.duration);else{const n={id:e.interactionId,latency:e.duration,entries:[e]};Vl[n.id]=n,Sn.push(n)}Sn.sort((n,i)=>i.latency-n.latency),Sn.splice(SE).forEach(n=>{delete Vl[n.id]})}},b$=()=>{const e=Math.min(Sn.length-1,Math.floor(CO()/50));return Sn[e]},T$=(e,t)=>{t=t||{},v$();const r=To("INP");let n;const i=s=>{s.forEach(u=>{u.interactionId&&IE(u),u.entryType==="first-input"&&!Sn.some(c=>c.entries.some(d=>u.duration===d.duration&&u.startTime===d.startTime))&&IE(u)});const o=b$();o&&o.latency!==r.value&&(r.value=o.latency,r.entries=o.entries,n())},a=Za("event",i,{durationThreshold:t.durationThreshold||40});n=bo(e,r,t.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),So(()=>{i(a.takeRecords()),r.value<0&&CO()>0&&(r.value=0,r.entries=[]),n(!0)}))},RE={},S$=e=>{const t=Mg(),r=To("LCP");let n;const i=s=>{const o=s[s.length-1];if(o){const u=Math.max(o.startTime-Pg(),0);u<t.firstHiddenTime&&(r.value=u,r.entries=[o],n())}},a=Za("largest-contentful-paint",i);if(a){n=bo(e,r);const s=()=>{RE[r.id]||(i(a.takeRecords()),a.disconnect(),RE[r.id]=!0,n(!0))};return["keydown","click"].forEach(o=>{Xe.document&&addEventListener(o,s,{once:!0,capture:!0})}),So(s,!0),s}},eg=e=>{Xe.document&&(Xe.document.prerendering?addEventListener("prerenderingchange",()=>eg(e),!0):Xe.document.readyState!=="complete"?addEventListener("load",()=>eg(e),!0):setTimeout(e,0))},I$=(e,t)=>{t=t||{};const r=To("TTFB"),n=bo(e,r,t.reportAllChanges);eg(()=>{const i=dl();if(i){if(r.value=Math.max(i.responseStart-Pg(),0),r.value<0||r.value>performance.now())return;r.entries=[i],n(!0)}})},Xs={},Zc={};let DO,jO,$O,LO,qO;function R$(e,t=!1){return Io("cls",e,P$,DO,t)}function A$(e,t=!1){return Io("lcp",e,C$,$O,t)}function w$(e){return Io("ttfb",e,D$,LO)}function O$(e){return Io("fid",e,M$,jO)}function N$(e){return Io("inp",e,j$,qO)}function ao(e,t){return kO(e,t),Zc[e]||($$(e),Zc[e]=!0),BO(e,t)}function xa(e,t){const r=Xs[e];if(!(!r||!r.length))for(const n of r)try{n(t)}catch(i){Rt&&Re.error(`Error while triggering instrumentation handler.
|
|
25
|
+
Type: ${e}
|
|
26
|
+
Name: ${wn(n)}
|
|
27
|
+
Error:`,i)}}function P$(){return m$(e=>{xa("cls",{metric:e}),DO=e},{reportAllChanges:!0})}function M$(){return g$(e=>{xa("fid",{metric:e}),jO=e})}function C$(){return S$(e=>{xa("lcp",{metric:e}),$O=e})}function D$(){return I$(e=>{xa("ttfb",{metric:e}),LO=e})}function j$(){return T$(e=>{xa("inp",{metric:e}),qO=e})}function Io(e,t,r,n,i=!1){kO(e,t);let a;return Zc[e]||(a=r(),Zc[e]=!0),n&&t({metric:n}),BO(e,t,i?a:void 0)}function $$(e){const t={};e==="event"&&(t.durationThreshold=0),Za(e,r=>{xa(e,{entries:r})},t)}function kO(e,t){Xs[e]=Xs[e]||[],Xs[e].push(t)}function BO(e,t,r){return()=>{r&&r();const n=Xs[e];if(!n)return;const i=n.indexOf(t);i!==-1&&n.splice(i,1)}}function Hl(e){return typeof e=="number"&&isFinite(e)}function Va(e,{startTimestamp:t,...r}){return t&&e.startTimestamp>t&&(e.startTimestamp=t),e.startChild({startTimestamp:t,...r})}const L$=2147483647;function Bt(e){return e/1e3}function Cg(){return Xe&&Xe.addEventListener&&Xe.performance}let AE=0,$t={},en,Qs;function q$(){const e=Cg();if(e&&wr){e.mark&&Xe.performance.mark("sentry-tracing-init");const t=H$(),r=F$(),n=V$(),i=G$();return()=>{t(),r(),n(),i()}}return()=>{}}function k$(){ao("longtask",({entries:e})=>{for(const t of e){const r=Ki();if(!r)return;const n=Bt(wr+t.startTime),i=Bt(t.duration);r.startChild({description:"Main UI thread blocked",op:"ui.long-task",origin:"auto.ui.browser.metrics",startTimestamp:n,endTimestamp:n+i})}})}function B$(){ao("event",({entries:e})=>{for(const t of e){const r=Ki();if(!r)return;if(t.name==="click"){const n=Bt(wr+t.startTime),i=Bt(t.duration),a={description:Ba(t.target),op:`ui.interaction.${t.name}`,origin:"auto.ui.browser.metrics",startTimestamp:n,endTimestamp:n+i},s=Dw(t.target);s&&(a.attributes={"ui.component_name":s}),r.startChild(a)}}})}function U$(e,t){if(Cg()&&wr){const n=z$(e,t);return()=>{n()}}return()=>{}}function F$(){return R$(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(Rt&&Re.log("[Measurements] Adding CLS"),$t.cls={value:e.value,unit:""},Qs=t)},!0)}function V$(){return A$(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(Rt&&Re.log("[Measurements] Adding LCP"),$t.lcp={value:e.value,unit:"millisecond"},en=t)},!0)}function H$(){return O$(({metric:e})=>{const t=e.entries[e.entries.length-1];if(!t)return;const r=Bt(wr),n=Bt(t.startTime);Rt&&Re.log("[Measurements] Adding FID"),$t.fid={value:e.value,unit:"millisecond"},$t["mark.fid"]={value:r+n,unit:"second"}})}function G$(){return w$(({metric:e})=>{e.entries[e.entries.length-1]&&(Rt&&Re.log("[Measurements] Adding TTFB"),$t.ttfb={value:e.value,unit:"millisecond"})})}const wE={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function z$(e,t){return N$(({metric:r})=>{if(r.value===void 0)return;const n=r.entries.find(v=>v.duration===r.value&&wE[v.name]!==void 0),i=Ka();if(!n||!i)return;const a=wE[n.name],s=i.getOptions(),o=Bt(wr+n.startTime),u=Bt(r.value),l=n.interactionId!==void 0?e[n.interactionId]:void 0;if(l===void 0)return;const{routeName:c,parentContext:d,activeTransaction:m,user:p,replayId:E}=l,A=p!==void 0?p.email||p.id||p.ip_address:void 0,R=m!==void 0?m.getProfileId():void 0,O=new ll({startTimestamp:o,endTimestamp:o+u,op:`ui.interaction.${a}`,name:Ba(n.target),attributes:{release:s.release,environment:s.environment,transaction:c,...A!==void 0&&A!==""?{user:A}:{},...R!==void 0?{profile_id:R}:{},...E!==void 0?{replay_id:E}:{}},exclusiveTime:r.value,measurements:{inp:{value:r.value,unit:"millisecond"}}}),f=eL(d,s,t);if(f&&Math.random()<f){const v=O?c$([O],i.getDsn()):void 0,b=i&&i.getTransport();b&&v&&b.send(v).then(null,h=>{Rt&&Re.error("Error while sending interaction:",h)});return}})}function W$(e){const t=Cg();if(!t||!Xe.performance.getEntries||!wr)return;Rt&&Re.log("[Tracing] Adding & adjusting spans using Performance API");const r=Bt(wr),n=t.getEntries(),{op:i,start_timestamp:a}=gr(e);if(n.slice(AE).forEach(s=>{const o=Bt(s.startTime),u=Bt(s.duration);if(!(e.op==="navigation"&&a&&r+o<a))switch(s.entryType){case"navigation":{K$(e,s,r);break}case"mark":case"paint":case"measure":{Y$(e,s,o,u,r);const l=Mg(),c=s.startTime<l.firstHiddenTime;s.name==="first-paint"&&c&&(Rt&&Re.log("[Measurements] Adding FP"),$t.fp={value:s.startTime,unit:"millisecond"}),s.name==="first-contentful-paint"&&c&&(Rt&&Re.log("[Measurements] Adding FCP"),$t.fcp={value:s.startTime,unit:"millisecond"});break}case"resource":{X$(e,s,s.name,o,u,r);break}}}),AE=Math.max(n.length-1,0),Q$(e),i==="pageload"){x$($t),["fcp","fp","lcp"].forEach(o=>{if(!$t[o]||!a||r>=a)return;const u=$t[o].value,l=r+Bt(u),c=Math.abs((l-a)*1e3),d=c-u;Rt&&Re.log(`[Measurements] Normalized ${o} from ${u} to ${c} (${d})`),$t[o].value=c});const s=$t["mark.fid"];s&&$t.fid&&(Va(e,{description:"first input delay",endTimestamp:s.value+Bt($t.fid.value),op:"ui.action",origin:"auto.ui.browser.metrics",startTimestamp:s.value}),delete $t["mark.fid"]),"fcp"in $t||delete $t.cls,Object.keys($t).forEach(o=>{u$(o,$t[o].value,$t[o].unit)}),Z$(e)}en=void 0,Qs=void 0,$t={}}function Y$(e,t,r,n,i){const a=i+r,s=a+n;return Va(e,{description:t.name,endTimestamp:s,op:t.entryType,origin:"auto.resource.browser.metrics",startTimestamp:a}),a}function K$(e,t,r){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(n=>{Ou(e,t,n,r)}),Ou(e,t,"secureConnection",r,"TLS/SSL","connectEnd"),Ou(e,t,"fetch",r,"cache","domainLookupStart"),Ou(e,t,"domainLookup",r,"DNS"),J$(e,t,r)}function Ou(e,t,r,n,i,a){const s=a?t[a]:t[`${r}End`],o=t[`${r}Start`];!o||!s||Va(e,{op:"browser",origin:"auto.browser.browser.metrics",description:i||r,startTimestamp:n+Bt(o),endTimestamp:n+Bt(s)})}function J$(e,t,r){t.responseEnd&&(Va(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"request",startTimestamp:r+Bt(t.requestStart),endTimestamp:r+Bt(t.responseEnd)}),Va(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"response",startTimestamp:r+Bt(t.responseStart),endTimestamp:r+Bt(t.responseEnd)}))}function X$(e,t,r,n,i,a){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const s=Hi(r),o={};Gl(o,t,"transferSize","http.response_transfer_size"),Gl(o,t,"encodedBodySize","http.response_content_length"),Gl(o,t,"decodedBodySize","http.decoded_response_content_length"),"renderBlockingStatus"in t&&(o["resource.render_blocking_status"]=t.renderBlockingStatus),s.protocol&&(o["url.scheme"]=s.protocol.split(":").pop()),s.host&&(o["server.address"]=s.host),o["url.same_origin"]=r.includes(Xe.location.origin);const u=a+n,l=u+i;Va(e,{description:r.replace(Xe.location.origin,""),endTimestamp:l,op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",origin:"auto.resource.browser.metrics",startTimestamp:u,data:o})}function Q$(e){const t=Xe.navigator;if(!t)return;const r=t.connection;r&&(r.effectiveType&&e.setTag("effectiveConnectionType",r.effectiveType),r.type&&e.setTag("connectionType",r.type),Hl(r.rtt)&&($t["connection.rtt"]={value:r.rtt,unit:"millisecond"})),Hl(t.deviceMemory)&&e.setTag("deviceMemory",`${t.deviceMemory} GB`),Hl(t.hardwareConcurrency)&&e.setTag("hardwareConcurrency",String(t.hardwareConcurrency))}function Z$(e){en&&(Rt&&Re.log("[Measurements] Adding LCP Data"),en.element&&e.setTag("lcp.element",Ba(en.element)),en.id&&e.setTag("lcp.id",en.id),en.url&&e.setTag("lcp.url",en.url.trim().slice(0,200)),e.setTag("lcp.size",en.size)),Qs&&Qs.sources&&(Rt&&Re.log("[Measurements] Adding CLS Data"),Qs.sources.forEach((t,r)=>e.setTag(`cls.source.${r+1}`,Ba(t.node))))}function Gl(e,t,r,n){const i=t[r];i!=null&&i<L$&&(e[n]=i)}function x$(e){const t=dl();if(!t)return;const{responseStart:r,requestStart:n}=t;n<=r&&(Rt&&Re.log("[Measurements] Adding TTFB Request Time"),e["ttfb.requestTime"]={value:r-n,unit:"millisecond"})}function eL(e,t,r){if(!Qa(t))return!1;let n;return e!==void 0&&typeof t.tracesSampler=="function"?n=t.tracesSampler({transactionContext:e,name:e.name,parentSampled:e.parentSampled,attributes:{...e.data,...e.attributes},location:Xe.location}):e!==void 0&&e.sampled!==void 0?n=e.sampled:typeof t.tracesSampleRate<"u"?n=t.tracesSampleRate:n=1,PO(n)?n===!0?r:n===!1?0:n*r:(Rt&&Re.warn("[Tracing] Discarding interaction span because of invalid sample rate."),!1)}function tL(e,t,r,n,i="auto.http.browser"){if(!Qa()||!e.fetchData)return;const a=t(e.fetchData.url);if(e.endTimestamp&&a){const p=e.fetchData.__span;if(!p)return;const E=n[p];E&&(iL(E,e),delete n[p]);return}const s=Ja(),o=Ka(),{method:u,url:l}=e.fetchData,c=nL(l),d=c?Hi(c).host:void 0,m=a?IO({name:`${u} ${l}`,onlyIfParent:!0,attributes:{url:l,type:"fetch","http.method":u,"http.url":c,"server.address":d,[va]:i},op:"http.client"}):void 0;if(m&&(e.fetchData.__span=m.spanContext().spanId,n[m.spanContext().spanId]=m),r(e.fetchData.url)&&o){const p=e.args[0];e.args[1]=e.args[1]||{};const E=e.args[1];E.headers=rL(p,o,s,E,m)}return m}function rL(e,t,r,n,i){const a=i||r.getSpan(),s=Og(),{traceId:o,spanId:u,sampled:l,dsc:c}={...s.getPropagationContext(),...r.getPropagationContext()},d=a?ul(a):Tg(o,u,l),m=Jw(c||(a?Fa(a):wg(o,t,r))),p=n.headers||(typeof Request<"u"&&An(e,Request)?e.headers:void 0);if(p)if(typeof Headers<"u"&&An(p,Headers)){const E=new Headers(p);return E.append("sentry-trace",d),m&&E.append(Wy,m),E}else if(Array.isArray(p)){const E=[...p,["sentry-trace",d]];return m&&E.push([Wy,m]),E}else{const E="baggage"in p?p.baggage:void 0,A=[];return Array.isArray(E)?A.push(...E):E&&A.push(E),m&&A.push(m),{...p,"sentry-trace":d,baggage:A.length>0?A.join(","):void 0}}else return{"sentry-trace":d,baggage:m}}function nL(e){try{return new URL(e).href}catch{return}}function iL(e,t){if(t.response){Ng(e,t.response.status);const r=t.response&&t.response.headers&&t.response.headers.get("content-length");if(r){const n=parseInt(r);n>0&&e.setAttribute("http.response_content_length",n)}}else t.error&&e.setStatus("internal_error");e.end()}const tg=["localhost",/^\/(?!\/)/],rg={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,tracingOrigins:tg,tracePropagationTargets:tg};function aL(e){const{traceFetch:t,traceXHR:r,tracePropagationTargets:n,tracingOrigins:i,shouldCreateSpanForRequest:a,enableHTTPTimings:s}={traceFetch:rg.traceFetch,traceXHR:rg.traceXHR,...e},o=typeof a=="function"?a:c=>!0,u=c=>cL(c,n||i),l={};t&&Vw(c=>{const d=tL(c,o,u,l);if(d){const m=UO(c.fetchData.url),p=m?Hi(m).host:void 0;d.setAttributes({"http.url":m,"server.address":p})}s&&d&&OE(d)}),r&&zw(c=>{const d=lL(c,o,u,l);s&&d&&OE(d)})}function sL(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.initiatorType==="xmlhttprequest")}function OE(e){const{url:t}=gr(e).data||{};if(!t||typeof t!="string")return;const r=ao("resource",({entries:n})=>{n.forEach(i=>{sL(i)&&i.name.endsWith(t)&&(uL(i).forEach(s=>e.setAttribute(...s)),setTimeout(r))})})}function oL(e){let t="unknown",r="unknown",n="";for(const i of e){if(i==="/"){[t,r]=e.split("/");break}if(!isNaN(Number(i))){t=n==="h"?"http":n,r=e.split(n)[1];break}n+=i}return n===e&&(t=n),{name:t,version:r}}function Qr(e=0){return((wr||performance.timeOrigin)+e)/1e3}function uL(e){const{name:t,version:r}=oL(e.nextHopProtocol),n=[];return n.push(["network.protocol.version",r],["network.protocol.name",t]),wr?[...n,["http.request.redirect_start",Qr(e.redirectStart)],["http.request.fetch_start",Qr(e.fetchStart)],["http.request.domain_lookup_start",Qr(e.domainLookupStart)],["http.request.domain_lookup_end",Qr(e.domainLookupEnd)],["http.request.connect_start",Qr(e.connectStart)],["http.request.secure_connection_start",Qr(e.secureConnectionStart)],["http.request.connection_end",Qr(e.connectEnd)],["http.request.request_start",Qr(e.requestStart)],["http.request.response_start",Qr(e.responseStart)],["http.request.response_end",Qr(e.responseEnd)]]:n}function cL(e,t){return go(e,t||tg)}function lL(e,t,r,n){const i=e.xhr,a=i&&i[_a];if(!Qa()||!i||i.__sentry_own_request__||!a)return;const s=t(a.url);if(e.endTimestamp&&s){const p=i.__sentry_xhr_span_id__;if(!p)return;const E=n[p];E&&a.status_code!==void 0&&(Ng(E,a.status_code),E.end(),delete n[p]);return}const o=Ja(),u=Og(),l=UO(a.url),c=l?Hi(l).host:void 0,d=s?IO({name:`${a.method} ${a.url}`,onlyIfParent:!0,attributes:{type:"xhr","http.method":a.method,"http.url":l,url:a.url,"server.address":c,[va]:"auto.http.browser"},op:"http.client"}):void 0;d&&(i.__sentry_xhr_span_id__=d.spanContext().spanId,n[i.__sentry_xhr_span_id__]=d);const m=Ka();if(i.setRequestHeader&&r(a.url)&&m){const{traceId:p,spanId:E,sampled:A,dsc:R}={...u.getPropagationContext(),...o.getPropagationContext()},O=d?ul(d):Tg(p,E,A),f=Jw(R||(d?Fa(d):wg(p,m,o)));dL(i,O,f)}return d}function dL(e,t,r){try{e.setRequestHeader("sentry-trace",t),r&&e.setRequestHeader(Wy,r)}catch{}}function UO(e){try{return new URL(e,Xe.location.origin).href}catch{return}}function fL(e,t=!0,r=!0){if(!Xe||!Xe.location){Rt&&Re.warn("Could not initialize routing instrumentation due to invalid location");return}let n=Xe.location.href,i;t&&(i=e({name:Xe.location.pathname,startTimestamp:wr?wr/1e3:void 0,op:"pageload",origin:"auto.pageload.browser",metadata:{source:"url"}})),r&&vg(({to:a,from:s})=>{if(s===void 0&&n&&n.indexOf(a)!==-1){n=void 0;return}s!==a&&(n=void 0,i&&(Rt&&Re.log(`[Tracing] Finishing current transaction with op: ${i.op}`),i.end()),i=e({name:Xe.location.pathname,op:"navigation",origin:"auto.navigation.browser",metadata:{source:"url"}}))})}const pL="BrowserTracing",mL={...Hc,markBackgroundTransactions:!0,routingInstrumentation:fL,startTransactionOnLocationChange:!0,startTransactionOnPageLoad:!0,enableLongTask:!0,enableInp:!1,interactionsSampleRate:1,_experiments:{},...rg},NE=10;class hL{constructor(t){this.name=pL,this._hasSetTracePropagationTargets=!1,o$(),Rt&&(this._hasSetTracePropagationTargets=!!(t&&(t.tracePropagationTargets||t.tracingOrigins))),this.options={...mL,...t},this.options._experiments.enableLongTask!==void 0&&(this.options.enableLongTask=this.options._experiments.enableLongTask),t&&!t.tracePropagationTargets&&t.tracingOrigins&&(this.options.tracePropagationTargets=t.tracingOrigins),this._collectWebVitals=q$(),this._interactionIdToRouteNameMapping={},this.options.enableInp&&U$(this._interactionIdToRouteNameMapping,this.options.interactionsSampleRate),this.options.enableLongTask&&k$(),this.options._experiments.enableInteractions&&B$(),this._latestRoute={name:void 0,context:void 0}}setupOnce(t,r){this._getCurrentHub=r;const i=r().getClient(),a=i&&i.getOptions(),{routingInstrumentation:s,startTransactionOnLocationChange:o,startTransactionOnPageLoad:u,markBackgroundTransactions:l,traceFetch:c,traceXHR:d,shouldCreateSpanForRequest:m,enableHTTPTimings:p,_experiments:E}=this.options,A=a&&a.tracePropagationTargets,R=A||this.options.tracePropagationTargets;Rt&&this._hasSetTracePropagationTargets&&A&&Re.warn("[Tracing] The `tracePropagationTargets` option was set in the BrowserTracing integration and top level `Sentry.init`. The top level `Sentry.init` value is being used."),s(O=>{const f=this._createRouteTransaction(O);return this.options._experiments.onStartRouteTransaction&&this.options._experiments.onStartRouteTransaction(f,O,r),f},u,o),l&&d$(),E.enableInteractions&&this._registerInteractionListener(),this.options.enableInp&&this._registerInpInteractionListener(),aL({traceFetch:c,traceXHR:d,tracePropagationTargets:R,shouldCreateSpanForRequest:m,enableHTTPTimings:p})}_createRouteTransaction(t){if(!this._getCurrentHub){Rt&&Re.warn(`[Tracing] Did not create ${t.op} transaction because _getCurrentHub is invalid.`);return}const r=this._getCurrentHub(),{beforeNavigate:n,idleTimeout:i,finalTimeout:a,heartbeatInterval:s}=this.options,o=t.op==="pageload";let u;if(o){const p=o?PE("sentry-trace"):"",E=o?PE("baggage"):void 0,{traceId:A,dsc:R,parentSpanId:O,sampled:f}=uD(p,E);u={traceId:A,parentSpanId:O,parentSampled:f,...t,metadata:{...t.metadata,dynamicSamplingContext:R},trimEnd:!0}}else u={trimEnd:!0,...t};const l=typeof n=="function"?n(u):u,c=l===void 0?{...u,sampled:!1}:l;c.metadata=c.name!==u.name?{...c.metadata,source:"custom"}:c.metadata,this._latestRoute.name=c.name,this._latestRoute.context=c,c.sampled===!1&&Rt&&Re.log(`[Tracing] Will not send ${c.op} transaction because of beforeNavigate.`),Rt&&Re.log(`[Tracing] Starting ${c.op} transaction on scope`);const{location:d}=Xe,m=TE(r,c,i,a,!0,{location:d},s,o);return o&&Xe.document&&(Xe.document.addEventListener("readystatechange",()=>{["interactive","complete"].includes(Xe.document.readyState)&&m.sendAutoFinishSignal()}),["interactive","complete"].includes(Xe.document.readyState)&&m.sendAutoFinishSignal()),m.registerBeforeFinishCallback(p=>{this._collectWebVitals(),W$(p)}),m}_registerInteractionListener(){let t;const r=()=>{const{idleTimeout:n,finalTimeout:i,heartbeatInterval:a}=this.options,s="ui.action.click",o=Ki();if(o&&o.op&&["navigation","pageload"].includes(o.op)){Rt&&Re.warn(`[Tracing] Did not create ${s} transaction because a pageload or navigation transaction is in progress.`);return}if(t&&(t.setFinishReason("interactionInterrupted"),t.end(),t=void 0),!this._getCurrentHub){Rt&&Re.warn(`[Tracing] Did not create ${s} transaction because _getCurrentHub is invalid.`);return}if(!this._latestRoute.name){Rt&&Re.warn(`[Tracing] Did not create ${s} transaction because _latestRouteName is missing.`);return}const u=this._getCurrentHub(),{location:l}=Xe,c={name:this._latestRoute.name,op:s,trimEnd:!0,data:{[Ia]:this._latestRoute.context?yL(this._latestRoute.context):"url"}};t=TE(u,c,n,i,!0,{location:l},a)};["click"].forEach(n=>{Xe.document&&addEventListener(n,r,{once:!1,capture:!0})})}_registerInpInteractionListener(){const t=({entries:r})=>{const n=Ka(),i=n!==void 0&&n.getIntegrationByName!==void 0?n.getIntegrationByName("Replay"):void 0,a=i!==void 0?i.getReplayId():void 0,s=Ki(),o=Ja(),u=o!==void 0?o.getUser():void 0;r.forEach(l=>{if(gL(l)){const c=l.interactionId;if(c===void 0)return;const d=this._interactionIdToRouteNameMapping[c],m=l.duration,p=l.startTime,E=Object.keys(this._interactionIdToRouteNameMapping),A=E.length>0?E.reduce((R,O)=>this._interactionIdToRouteNameMapping[R].duration<this._interactionIdToRouteNameMapping[O].duration?R:O):void 0;if(l.entryType==="first-input"&&E.map(O=>this._interactionIdToRouteNameMapping[O]).some(O=>O.duration===m&&O.startTime===p)||!c)return;if(d)d.duration=Math.max(d.duration,m);else if(E.length<NE||A===void 0||m>this._interactionIdToRouteNameMapping[A].duration){const R=this._latestRoute.name,O=this._latestRoute.context;R&&O&&(A&&Object.keys(this._interactionIdToRouteNameMapping).length>=NE&&delete this._interactionIdToRouteNameMapping[A],this._interactionIdToRouteNameMapping[c]={routeName:R,duration:m,parentContext:O,user:u,activeTransaction:s,replayId:a,startTime:p})}}})};ao("event",t),ao("first-input",t)}}function PE(e){const t=yC(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}function yL(e){const t=e.attributes&&e.attributes[Ia],r=e.data&&e.data[Ia],n=e.metadata&&e.metadata.source;return t||r||n}function gL(e){return"duration"in e}const ct=at;let ng=0;function FO(){return ng>0}function _L(){ng++,setTimeout(()=>{ng--})}function Ha(e,t={},r){if(typeof e!="function")return e;try{const i=e.__sentry_wrapped__;if(i)return typeof i=="function"?i:e;if(_g(e))return e}catch{return e}const n=function(){const i=Array.prototype.slice.call(arguments);try{const a=i.map(s=>Ha(s,t));return e.apply(this,a)}catch(a){throw _L(),eO(s=>{s.addEventProcessor(o=>(t.mechanism&&(By(o,void 0),ro(o,t.mechanism)),o.extra={...o.extra,arguments:i},o)),Ig(a)}),a}};try{for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i])}catch{}Lw(n,e),zi(e,"__sentry_wrapped__",n);try{Object.getOwnPropertyDescriptor(n,"name").configurable&&Object.defineProperty(n,"name",{get(){return e.name}})}catch{}return n}const Ar=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function VO(e,t){const r=Dg(e,t),n={type:t&&t.name,value:TL(t)};return r.length&&(n.stacktrace={frames:r}),n.type===void 0&&n.value===""&&(n.value="Unrecoverable error caught"),n}function EL(e,t,r,n){const i=cr(),a=i&&i.getOptions().normalizeDepth,s={exception:{values:[{type:rl(t)?t.constructor.name:n?"UnhandledRejection":"Error",value:RL(t,{isUnhandledRejection:n})}]},extra:{__serialized__:Ww(t,a)}};if(r){const o=Dg(e,r);o.length&&(s.exception.values[0].stacktrace={frames:o})}return s}function zl(e,t){return{exception:{values:[VO(e,t)]}}}function Dg(e,t){const r=t.stacktrace||t.stack||"",n=bL(t);try{return e(r,n)}catch{}return[]}const vL=/Minified React error #\d+;/i;function bL(e){if(e){if(typeof e.framesToPop=="number")return e.framesToPop;if(vL.test(e.message))return 1}return 0}function TL(e){const t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:t:"No error message"}function SL(e,t,r,n){const i=r&&r.syntheticException||void 0,a=jg(e,t,i,n);return ro(a),a.level="error",r&&r.event_id&&(a.event_id=r.event_id),Ua(a)}function IL(e,t,r="info",n,i){const a=n&&n.syntheticException||void 0,s=ig(e,t,a,i);return s.level=r,n&&n.event_id&&(s.event_id=n.event_id),Ua(s)}function jg(e,t,r,n,i){let a;if(mg(t)&&t.error)return zl(e,t.error);if(H_(t)||sC(t)){const s=t;if("stack"in t)a=zl(e,t);else{const o=s.name||(H_(s)?"DOMError":"DOMException"),u=s.message?`${o}: ${s.message}`:o;a=ig(e,u,r,n),By(a,u)}return"code"in s&&(a.tags={...a.tags,"DOMException.code":`${s.code}`}),a}return pg(t)?zl(e,t):Gi(t)||rl(t)?(a=EL(e,t,r,i),ro(a,{synthetic:!0}),a):(a=ig(e,t,r,n),By(a,`${t}`),ro(a,{synthetic:!0}),a)}function ig(e,t,r,n){const i={};if(n&&r){const a=Dg(e,r);a.length&&(i.exception={values:[{value:t,stacktrace:{frames:a}}]})}if(hg(t)){const{__sentry_template_string__:a,__sentry_template_values__:s}=t;return i.logentry={message:a,params:s},i}return i.message=t,i}function RL(e,{isUnhandledRejection:t}){const r=IC(e),n=t?"promise rejection":"exception";return mg(e)?`Event \`ErrorEvent\` captured as ${n} with message \`${e.message}\``:rl(e)?`Event \`${AL(e)}\` (type=${e.type}) captured as ${n}`:`Object captured as ${n} with keys: ${r}`}function AL(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function wL(e,{metadata:t,tunnel:r,dsn:n}){const i={event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!r&&!!n&&{dsn:Qi(n)}},a=OL(e);return ra(i,[a])}function OL(e){return[{type:"user_report"},e]}class NL extends dj{constructor(t){const r=ct.SENTRY_SDK_SOURCE||WC();mO(t,"browser",["browser"],r),super(t),t.sendClientReports&&ct.document&&ct.document.addEventListener("visibilitychange",()=>{ct.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,r){return SL(this._options.stackParser,t,r,this._options.attachStacktrace)}eventFromMessage(t,r="info",n){return IL(this._options.stackParser,t,r,n,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){Ar&&Re.warn("SDK not enabled, will not capture user feedback.");return}const r=wL(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this._sendEnvelope(r)}_prepareEvent(t,r,n){return t.platform=t.platform||"javascript",super._prepareEvent(t,r,n)}_flushOutcomes(){const t=this._clearOutcomes();if(t.length===0){Ar&&Re.log("No outcomes to send");return}if(!this._dsn){Ar&&Re.log("No dsn provided, will not send outcomes");return}Ar&&Re.log("Sending outcomes:",t);const r=hD(t,this._options.tunnel&&Qi(this._dsn));this._sendEnvelope(r)}}let As;function PL(){if(As)return As;if(Hy(ct.fetch))return As=ct.fetch.bind(ct);const e=ct.document;let t=ct.fetch;if(e&&typeof e.createElement=="function")try{const r=e.createElement("iframe");r.hidden=!0,e.head.appendChild(r);const n=r.contentWindow;n&&n.fetch&&(t=n.fetch),e.head.removeChild(r)}catch(r){Ar&&Re.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return As=t.bind(ct)}function ML(){As=void 0}function CL(e,t=PL()){let r=0,n=0;function i(a){const s=a.body.length;r+=s,n++;const o={body:a.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:r<=6e4&&n<15,...e.fetchOptions};try{return t(e.url,o).then(u=>(r-=s,n--,{statusCode:u.status,headers:{"x-sentry-rate-limits":u.headers.get("X-Sentry-Rate-Limits"),"retry-after":u.headers.get("Retry-After")}}))}catch(u){return ML(),r-=s,n--,bg(u)}}return pO(e,i)}const DL=4;function jL(e){function t(r){return new yr((n,i)=>{const a=new XMLHttpRequest;a.onerror=i,a.onreadystatechange=()=>{a.readyState===DL&&n({statusCode:a.status,headers:{"x-sentry-rate-limits":a.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":a.getResponseHeader("Retry-After")}})},a.open("POST",e.url);for(const s in e.headers)Object.prototype.hasOwnProperty.call(e.headers,s)&&a.setRequestHeader(s,e.headers[s]);a.send(r.body)})}return pO(e,t)}const fl="?",$L=30,LL=40,qL=50;function $g(e,t,r,n){const i={filename:e,function:t,in_app:!0};return r!==void 0&&(i.lineno=r),n!==void 0&&(i.colno=n),i}const kL=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,BL=/\((\S*)(?::(\d+))(?::(\d+))\)/,UL=e=>{const t=kL.exec(e);if(t){if(t[2]&&t[2].indexOf("eval")===0){const a=BL.exec(t[2]);a&&(t[2]=a[1],t[3]=a[2],t[4]=a[3])}const[n,i]=HO(t[1]||fl,t[2]);return $g(i,n,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}},FL=[$L,UL],VL=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,HL=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,GL=e=>{const t=VL.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const a=HL.exec(t[3]);a&&(t[1]=t[1]||"eval",t[3]=a[1],t[4]=a[2],t[5]="")}let n=t[3],i=t[1]||fl;return[i,n]=HO(i,n),$g(n,i,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},zL=[qL,GL],WL=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,YL=e=>{const t=WL.exec(e);return t?$g(t[2],t[1]||fl,+t[3],t[4]?+t[4]:void 0):void 0},KL=[LL,YL],JL=[FL,zL,KL],XL=Bw(...JL),HO=(e,t)=>{const r=e.indexOf("safari-extension")!==-1,n=e.indexOf("safari-web-extension")!==-1;return r||n?[e.indexOf("@")!==-1?e.split("@")[0]:fl,r?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},Nu=1024,GO="Breadcrumbs",QL=((e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:GO,setupOnce(){},setup(r){t.console&&OC(eq(r)),t.dom&&MC(xL(r,t.dom)),t.xhr&&zw(tq(r)),t.fetch&&Vw(rq(r)),t.history&&vg(nq(r)),t.sentry&&r.on&&r.on("beforeSendEvent",ZL(r))}}}),zO=QL;Kn(GO,zO);function ZL(e){return function(r){cr()===e&&Yi({category:`sentry.${r.type==="transaction"?"transaction":"event"}`,event_id:r.event_id,level:r.level,message:kn(r)},{event:r})}}function xL(e,t){return function(n){if(cr()!==e)return;let i,a,s=typeof t=="object"?t.serializeAttribute:void 0,o=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;o&&o>Nu&&(Ar&&Re.warn(`\`dom.maxStringLength\` cannot exceed ${Nu}, but a value of ${o} was configured. Sentry will use ${Nu} instead.`),o=Nu),typeof s=="string"&&(s=[s]);try{const l=n.event,c=iq(l)?l.target:l;i=Ba(c,{keyAttrs:s,maxStringLength:o}),a=Dw(c)}catch{i="<unknown>"}if(i.length===0)return;const u={category:`ui.${n.name}`,message:i};a&&(u.data={"ui.component_name":a}),Yi(u,{event:n.event,name:n.name,global:n.global})}}function eq(e){return function(r){if(cr()!==e)return;const n={category:"console",data:{arguments:r.args,logger:"console"},level:eD(r.level),message:G_(r.args," ")};if(r.level==="assert")if(r.args[0]===!1)n.message=`Assertion failed: ${G_(r.args.slice(1)," ")||"console.assert"}`,n.data.arguments=r.args.slice(1);else return;Yi(n,{input:r.args,level:r.level})}}function tq(e){return function(r){if(cr()!==e)return;const{startTimestamp:n,endTimestamp:i}=r,a=r.xhr[_a];if(!n||!i||!a)return;const{method:s,url:o,status_code:u,body:l}=a,c={method:s,url:o,status_code:u},d={xhr:r.xhr,input:l,startTimestamp:n,endTimestamp:i};Yi({category:"xhr",data:c,type:"http"},d)}}function rq(e){return function(r){if(cr()!==e)return;const{startTimestamp:n,endTimestamp:i}=r;if(i&&!(r.fetchData.url.match(/sentry_key/)&&r.fetchData.method==="POST"))if(r.error){const a=r.fetchData,s={data:r.error,input:r.args,startTimestamp:n,endTimestamp:i};Yi({category:"fetch",data:a,level:"error",type:"http"},s)}else{const a=r.response,s={...r.fetchData,status_code:a&&a.status},o={input:r.args,response:a,startTimestamp:n,endTimestamp:i};Yi({category:"fetch",data:s,type:"http"},o)}}}function nq(e){return function(r){if(cr()!==e)return;let n=r.from,i=r.to;const a=Hi(ct.location.href);let s=n?Hi(n):void 0;const o=Hi(i);(!s||!s.path)&&(s=a),a.protocol===o.protocol&&a.host===o.host&&(i=o.relative),a.protocol===s.protocol&&a.host===s.host&&(n=s.relative),Yi({category:"navigation",data:{from:n,to:i}})}}function iq(e){return!!e&&!!e.target}const WO="Dedupe",aq=(()=>{let e;return{name:WO,setupOnce(){},processEvent(t){if(t.type)return t;try{if(sq(t,e))return Ar&&Re.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}}),YO=aq;Kn(WO,YO);function sq(e,t){return t?!!(oq(e,t)||uq(e,t)):!1}function oq(e,t){const r=e.message,n=t.message;return!(!r&&!n||r&&!n||!r&&n||r!==n||!JO(e,t)||!KO(e,t))}function uq(e,t){const r=ME(t),n=ME(e);return!(!r||!n||r.type!==n.type||r.value!==n.value||!JO(e,t)||!KO(e,t))}function KO(e,t){let r=CE(e),n=CE(t);if(!r&&!n)return!0;if(r&&!n||!r&&n||(r=r,n=n,n.length!==r.length))return!1;for(let i=0;i<n.length;i++){const a=n[i],s=r[i];if(a.filename!==s.filename||a.lineno!==s.lineno||a.colno!==s.colno||a.function!==s.function)return!1}return!0}function JO(e,t){let r=e.fingerprint,n=t.fingerprint;if(!r&&!n)return!0;if(r&&!n||!r&&n)return!1;r=r,n=n;try{return r.join("")===n.join("")}catch{return!1}}function ME(e){return e.exception&&e.exception.values&&e.exception.values[0]}function CE(e){const t=e.exception;if(t)try{return t.values[0].stacktrace.frames}catch{return}}const XO="GlobalHandlers",cq=((e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:XO,setupOnce(){Error.stackTraceLimit=50},setup(r){t.onerror&&(lq(r),DE("onerror")),t.onunhandledrejection&&(dq(r),DE("onunhandledrejection"))}}}),QO=cq;Kn(XO,QO);function lq(e){Hw(t=>{const{stackParser:r,attachStacktrace:n}=xO();if(cr()!==e||FO())return;const{msg:i,url:a,line:s,column:o,error:u}=t,l=u===void 0&&on(i)?mq(i,a,s,o):ZO(jg(r,u||i,void 0,n,!1),a,s,o);l.level="error",xw(l,{originalException:u,mechanism:{handled:!1,type:"onerror"}})})}function dq(e){Gw(t=>{const{stackParser:r,attachStacktrace:n}=xO();if(cr()!==e||FO())return;const i=fq(t),a=yg(i)?pq(i):jg(r,i,void 0,n,!0);a.level="error",xw(a,{originalException:i,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function fq(e){if(yg(e))return e;const t=e;try{if("reason"in t)return t.reason;if("detail"in t&&"reason"in t.detail)return t.detail.reason}catch{}return e}function pq(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function mq(e,t,r,n){const i=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;let a=mg(e)?e.message:e,s="Error";const o=a.match(i);return o&&(s=o[1],a=o[2]),ZO({exception:{values:[{type:s,value:a}]}},t,r,n)}function ZO(e,t,r,n){const i=e.exception=e.exception||{},a=i.values=i.values||[],s=a[0]=a[0]||{},o=s.stacktrace=s.stacktrace||{},u=o.frames=o.frames||[],l=isNaN(parseInt(n,10))?void 0:n,c=isNaN(parseInt(r,10))?void 0:r,d=on(t)&&t.length>0?t:hC();return u.length===0&&u.push({colno:l,filename:d,function:"?",in_app:!0,lineno:c}),e}function DE(e){Ar&&Re.log(`Global Handler attached: ${e}`)}function xO(){const e=cr();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const eN="HttpContext",hq=(()=>({name:eN,setupOnce(){},preprocessEvent(e){if(!ct.navigator&&!ct.location&&!ct.document)return;const t=e.request&&e.request.url||ct.location&&ct.location.href,{referrer:r}=ct.document||{},{userAgent:n}=ct.navigator||{},i={...e.request&&e.request.headers,...r&&{Referer:r},...n&&{"User-Agent":n}},a={...e.request,...t&&{url:t},headers:i};e.request=a}})),tN=hq;Kn(eN,tN);const yq="cause",gq=5,rN="LinkedErrors",_q=((e={})=>{const t=e.limit||gq,r=e.key||yq;return{name:rN,setupOnce(){},preprocessEvent(n,i,a){const s=a.getOptions();dC(VO,s.stackParser,s.maxValueLength,r,t,n,i)}}}),nN=_q;Kn(rN,nN);const Eq=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],iN="TryCatch",vq=((e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:iN,setupOnce(){t.setTimeout&&Jt(ct,"setTimeout",jE),t.setInterval&&Jt(ct,"setInterval",jE),t.requestAnimationFrame&&Jt(ct,"requestAnimationFrame",bq),t.XMLHttpRequest&&"XMLHttpRequest"in ct&&Jt(XMLHttpRequest.prototype,"send",Tq);const r=t.eventTarget;r&&(Array.isArray(r)?r:Eq).forEach(Sq)}}}),aN=vq;Kn(iN,aN);function jE(e){return function(...t){const r=t[0];return t[0]=Ha(r,{mechanism:{data:{function:wn(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function bq(e){return function(t){return e.apply(this,[Ha(t,{mechanism:{data:{function:"requestAnimationFrame",handler:wn(e)},handled:!1,type:"instrument"}})])}}function Tq(e){return function(...t){const r=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(i=>{i in r&&typeof r[i]=="function"&&Jt(r,i,function(a){const s={mechanism:{data:{function:i,handler:wn(a)},handled:!1,type:"instrument"}},o=_g(a);return o&&(s.mechanism.data.handler=wn(o)),Ha(a,s)})}),e.apply(this,t)}}function Sq(e){const t=ct,r=t[e]&&t[e].prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(Jt(r,"addEventListener",function(n){return function(i,a,s){try{typeof a.handleEvent=="function"&&(a.handleEvent=Ha(a.handleEvent,{mechanism:{data:{function:"handleEvent",handler:wn(a),target:e},handled:!1,type:"instrument"}}))}catch{}return n.apply(this,[i,Ha(a,{mechanism:{data:{function:"addEventListener",handler:wn(a),target:e},handled:!1,type:"instrument"}}),s])}}),Jt(r,"removeEventListener",function(n){return function(i,a,s){const o=a;try{const u=o&&o.__sentry_wrapped__;u&&n.call(this,i,u,s)}catch{}return n.call(this,i,o,s)}}))}const Iq=[yO(),_O(),aN(),zO(),QO(),nN(),YO(),tN()];function Rq(e){return[...Iq]}function Aq(e={}){e.defaultIntegrations===void 0&&(e.defaultIntegrations=Rq()),e.release===void 0&&(typeof __SENTRY_RELEASE__=="string"&&(e.release=__SENTRY_RELEASE__),ct.SENTRY_RELEASE&&ct.SENTRY_RELEASE.id&&(e.release=ct.SENTRY_RELEASE.id)),e.autoSessionTracking===void 0&&(e.autoSessionTracking=!0),e.sendClientReports===void 0&&(e.sendClientReports=!0);const t={...e,stackParser:AC(e.stackParser||XL),integrations:aj(e),transport:e.transport||(Fw()?CL:jL)};mj(NL,t),e.autoSessionTracking&&wq()}const $E=(e={},t=Br())=>{if(!ct.document){Ar&&Re.error("Global document not defined in showReportDialog call");return}const{client:r,scope:n}=t.getStackTop(),i=e.dsn||r&&r.getDsn();if(!i){Ar&&Re.error("DSN not configured for showReportDialog call");return}n&&(e.user={...n.getUser(),...e.user}),e.eventId||(e.eventId=t.lastEventId());const a=ct.document.createElement("script");a.async=!0,a.crossOrigin="anonymous",a.src=nj(i,e),e.onLoad&&(a.onload=e.onLoad);const{onClose:s}=e;if(s){const u=l=>{if(l.data==="__sentry_reportdialog_closed__")try{s()}finally{ct.removeEventListener("message",u)}};ct.addEventListener("message",u)}const o=ct.document.head||ct.document.body;o?o.appendChild(a):Ar&&Re.error("Not injecting report dialog. No injection point found in HTML")};function wq(){if(typeof ct.document>"u"){Ar&&Re.warn("Session tracking in non-browser environment with @sentry/browser is not supported.");return}sE({ignoreDuration:!0}),oE(),vg(({from:e,to:t})=>{e!==void 0&&e!==t&&(sE({ignoreDuration:!0}),oE())})}function Oq(e){const t={...e};mO(t,"react"),Aq(t)}var Wl={exports:{}},mt={};/** @license React v16.13.1
|
|
28
|
+
* react-is.production.min.js
|
|
29
|
+
*
|
|
30
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
31
|
+
*
|
|
32
|
+
* This source code is licensed under the MIT license found in the
|
|
33
|
+
* LICENSE file in the root directory of this source tree.
|
|
34
|
+
*/var LE;function Nq(){if(LE)return mt;LE=1;var e=typeof Symbol=="function"&&Symbol.for,t=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,n=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,s=e?Symbol.for("react.provider"):60109,o=e?Symbol.for("react.context"):60110,u=e?Symbol.for("react.async_mode"):60111,l=e?Symbol.for("react.concurrent_mode"):60111,c=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,p=e?Symbol.for("react.memo"):60115,E=e?Symbol.for("react.lazy"):60116,A=e?Symbol.for("react.block"):60121,R=e?Symbol.for("react.fundamental"):60117,O=e?Symbol.for("react.responder"):60118,f=e?Symbol.for("react.scope"):60119;function v(h){if(typeof h=="object"&&h!==null){var T=h.$$typeof;switch(T){case t:switch(h=h.type,h){case u:case l:case n:case a:case i:case d:return h;default:switch(h=h&&h.$$typeof,h){case o:case c:case E:case p:case s:return h;default:return T}}case r:return T}}}function b(h){return v(h)===l}return mt.AsyncMode=u,mt.ConcurrentMode=l,mt.ContextConsumer=o,mt.ContextProvider=s,mt.Element=t,mt.ForwardRef=c,mt.Fragment=n,mt.Lazy=E,mt.Memo=p,mt.Portal=r,mt.Profiler=a,mt.StrictMode=i,mt.Suspense=d,mt.isAsyncMode=function(h){return b(h)||v(h)===u},mt.isConcurrentMode=b,mt.isContextConsumer=function(h){return v(h)===o},mt.isContextProvider=function(h){return v(h)===s},mt.isElement=function(h){return typeof h=="object"&&h!==null&&h.$$typeof===t},mt.isForwardRef=function(h){return v(h)===c},mt.isFragment=function(h){return v(h)===n},mt.isLazy=function(h){return v(h)===E},mt.isMemo=function(h){return v(h)===p},mt.isPortal=function(h){return v(h)===r},mt.isProfiler=function(h){return v(h)===a},mt.isStrictMode=function(h){return v(h)===i},mt.isSuspense=function(h){return v(h)===d},mt.isValidElementType=function(h){return typeof h=="string"||typeof h=="function"||h===n||h===l||h===a||h===i||h===d||h===m||typeof h=="object"&&h!==null&&(h.$$typeof===E||h.$$typeof===p||h.$$typeof===s||h.$$typeof===o||h.$$typeof===c||h.$$typeof===R||h.$$typeof===O||h.$$typeof===f||h.$$typeof===A)},mt.typeOf=v,mt}var qE;function Pq(){return qE||(qE=1,Wl.exports=Nq()),Wl.exports}var Yl,kE;function Mq(){if(kE)return Yl;kE=1;var e=Pq(),t={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},r={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},n={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},a={};a[e.ForwardRef]=n,a[e.Memo]=i;function s(E){return e.isMemo(E)?i:a[E.$$typeof]||t}var o=Object.defineProperty,u=Object.getOwnPropertyNames,l=Object.getOwnPropertySymbols,c=Object.getOwnPropertyDescriptor,d=Object.getPrototypeOf,m=Object.prototype;function p(E,A,R){if(typeof A!="string"){if(m){var O=d(A);O&&O!==m&&p(E,O,R)}var f=u(A);l&&(f=f.concat(l(A)));for(var v=s(E),b=s(A),h=0;h<f.length;++h){var T=f[h];if(!r[T]&&!(R&&R[T])&&!(b&&b[T])&&!(v&&v[T])){var w=c(A,T);try{o(E,T,w)}catch{}}}}return E}return Yl=p,Yl}Mq();const Cq=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function Dq(e){const t=e.match(/^([^.]+)/);return t!==null&&parseInt(t[0])>=17}const BE={componentStack:null,error:null,eventId:null};function jq(e,t){const r=new WeakMap;function n(i,a){if(!r.has(i)){if(i.cause)return r.set(i,!0),n(i.cause,a);i.cause=a}}n(e,t)}class Lg extends Ye.Component{constructor(t){super(t),Lg.prototype.__init.call(this),this.state=BE,this._openFallbackReportDialog=!0;const r=cr();r&&r.on&&t.showDialog&&(this._openFallbackReportDialog=!1,r.on("afterSendEvent",n=>{!n.type&&n.event_id===this._lastEventId&&$E({...t.dialogOptions,eventId:this._lastEventId})}))}componentDidCatch(t,{componentStack:r}){const{beforeCapture:n,onError:i,showDialog:a,dialogOptions:s}=this.props;eO(o=>{if(Dq(Ye.version)&&pg(t)){const l=new Error(t.message);l.name=`React ErrorBoundary ${t.name}`,l.stack=r,jq(t,l)}n&&n(o,t,r);const u=Ig(t,{captureContext:{contexts:{react:{componentStack:r}}},mechanism:{handled:!!this.props.fallback}});i&&i(t,r,u),a&&(this._lastEventId=u,this._openFallbackReportDialog&&$E({...s,eventId:u})),this.setState({error:t,componentStack:r,eventId:u})})}componentDidMount(){const{onMount:t}=this.props;t&&t()}componentWillUnmount(){const{error:t,componentStack:r,eventId:n}=this.state,{onUnmount:i}=this.props;i&&i(t,r,n)}__init(){this.resetErrorBoundary=()=>{const{onReset:t}=this.props,{error:r,componentStack:n,eventId:i}=this.state;t&&t(r,n,i),this.setState(BE)}}render(){const{fallback:t,children:r}=this.props,n=this.state;if(n.error){let i;return typeof t=="function"?i=t({error:n.error,componentStack:n.componentStack,resetError:this.resetErrorBoundary,eventId:n.eventId}):i=t,Ye.isValidElement(i)?i:(t&&Cq&&Re.warn("fallback did not produce a valid ReactElement"),null)}return typeof r=="function"?r():r}}const $q=Ye.lazy(()=>Xt(()=>import("./index-D8ALyBMQ.js"),__vite__mapDeps([0,1,2,3,4,5])).then(e=>({default:e.Navbar})));function Lq(e){return fe.jsx(Ye.Suspense,{fallback:fe.jsx("div",{className:"topnav-skeleton","aria-hidden":!0}),children:fe.jsx($q,{...e})})}const qq={},UE=e=>{let t;const r=new Set,n=(c,d)=>{const m=typeof c=="function"?c(t):c;if(!Object.is(m,t)){const p=t;t=d??(typeof m!="object"||m===null)?m:Object.assign({},t,m),r.forEach(E=>E(t,p))}},i=()=>t,u={setState:n,getState:i,getInitialState:()=>l,subscribe:c=>(r.add(c),()=>r.delete(c)),destroy:()=>{(qq?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),r.clear()}},l=t=e(n,i,u);return u},kq=e=>e?UE(e):UE;var Kl={exports:{}},Jl={},Xl={exports:{}},Ql={};/**
|
|
35
|
+
* @license React
|
|
36
|
+
* use-sync-external-store-shim.production.js
|
|
37
|
+
*
|
|
38
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
39
|
+
*
|
|
40
|
+
* This source code is licensed under the MIT license found in the
|
|
41
|
+
* LICENSE file in the root directory of this source tree.
|
|
42
|
+
*/var FE;function Bq(){if(FE)return Ql;FE=1;var e=pw();function t(d,m){return d===m&&(d!==0||1/d===1/m)||d!==d&&m!==m}var r=typeof Object.is=="function"?Object.is:t,n=e.useState,i=e.useEffect,a=e.useLayoutEffect,s=e.useDebugValue;function o(d,m){var p=m(),E=n({inst:{value:p,getSnapshot:m}}),A=E[0].inst,R=E[1];return a(function(){A.value=p,A.getSnapshot=m,u(A)&&R({inst:A})},[d,p,m]),i(function(){return u(A)&&R({inst:A}),d(function(){u(A)&&R({inst:A})})},[d]),s(p),p}function u(d){var m=d.getSnapshot;d=d.value;try{var p=m();return!r(d,p)}catch{return!0}}function l(d,m){return m()}var c=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?l:o;return Ql.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:c,Ql}var VE;function Uq(){return VE||(VE=1,Xl.exports=Bq()),Xl.exports}/**
|
|
43
|
+
* @license React
|
|
44
|
+
* use-sync-external-store-shim/with-selector.production.js
|
|
45
|
+
*
|
|
46
|
+
* Copyright (c) Meta Platforms, Inc. and affiliates.
|
|
47
|
+
*
|
|
48
|
+
* This source code is licensed under the MIT license found in the
|
|
49
|
+
* LICENSE file in the root directory of this source tree.
|
|
50
|
+
*/var HE;function Fq(){if(HE)return Jl;HE=1;var e=pw(),t=Uq();function r(l,c){return l===c&&(l!==0||1/l===1/c)||l!==l&&c!==c}var n=typeof Object.is=="function"?Object.is:r,i=t.useSyncExternalStore,a=e.useRef,s=e.useEffect,o=e.useMemo,u=e.useDebugValue;return Jl.useSyncExternalStoreWithSelector=function(l,c,d,m,p){var E=a(null);if(E.current===null){var A={hasValue:!1,value:null};E.current=A}else A=E.current;E=o(function(){function O(T){if(!f){if(f=!0,v=T,T=m(T),p!==void 0&&A.hasValue){var w=A.value;if(p(w,T))return b=w}return b=T}if(w=b,n(v,T))return w;var P=m(T);return p!==void 0&&p(w,P)?(v=T,w):(v=T,b=P)}var f=!1,v,b,h=d===void 0?null:d;return[function(){return O(c())},h===null?void 0:function(){return O(h())}]},[c,d,m,p]);var R=i(l,E[0],E[1]);return s(function(){A.hasValue=!0,A.value=R},[R]),u(R),R},Jl}var GE;function Vq(){return GE||(GE=1,Kl.exports=Fq()),Kl.exports}var Hq=Vq();const Gq=mw(Hq),sN={},{useDebugValue:zq}=hw,{useSyncExternalStoreWithSelector:Wq}=Gq;let zE=!1;const Yq=e=>e;function Kq(e,t=Yq,r){(sN?"production":void 0)!=="production"&&r&&!zE&&(console.warn("[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"),zE=!0);const n=Wq(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,r);return zq(n),n}const WE=e=>{(sN?"production":void 0)!=="production"&&typeof e!="function"&&console.warn("[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`.");const t=typeof e=="function"?kq(e):e,r=(n,i)=>Kq(t,n,i);return Object.assign(r,t),r},Ro=e=>e?WE(e):WE;var Or={},Jn={},Xn={},Zl={},Nr={},Pu={exports:{}},xl={},mn={},Qn={},ed={},td={},rd={},YE;function so(){return YE||(YE=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.regexpCode=e.getEsmExportName=e.getProperty=e.safeStringify=e.stringify=e.strConcat=e.addCodeArg=e.str=e._=e.nil=e._Code=e.Name=e.IDENTIFIER=e._CodeOrName=void 0;class t{}e._CodeOrName=t,e.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;class r extends t{constructor(f){if(super(),!e.IDENTIFIER.test(f))throw new Error("CodeGen: name must be a valid identifier");this.str=f}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}}e.Name=r;class n extends t{constructor(f){super(),this._items=typeof f=="string"?[f]:f}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;const f=this._items[0];return f===""||f==='""'}get str(){var f;return(f=this._str)!==null&&f!==void 0?f:this._str=this._items.reduce((v,b)=>`${v}${b}`,"")}get names(){var f;return(f=this._names)!==null&&f!==void 0?f:this._names=this._items.reduce((v,b)=>(b instanceof r&&(v[b.str]=(v[b.str]||0)+1),v),{})}}e._Code=n,e.nil=new n("");function i(O,...f){const v=[O[0]];let b=0;for(;b<f.length;)o(v,f[b]),v.push(O[++b]);return new n(v)}e._=i;const a=new n("+");function s(O,...f){const v=[p(O[0])];let b=0;for(;b<f.length;)v.push(a),o(v,f[b]),v.push(a,p(O[++b]));return u(v),new n(v)}e.str=s;function o(O,f){f instanceof n?O.push(...f._items):f instanceof r?O.push(f):O.push(d(f))}e.addCodeArg=o;function u(O){let f=1;for(;f<O.length-1;){if(O[f]===a){const v=l(O[f-1],O[f+1]);if(v!==void 0){O.splice(f-1,3,v);continue}O[f++]="+"}f++}}function l(O,f){if(f==='""')return O;if(O==='""')return f;if(typeof O=="string")return f instanceof r||O[O.length-1]!=='"'?void 0:typeof f!="string"?`${O.slice(0,-1)}${f}"`:f[0]==='"'?O.slice(0,-1)+f.slice(1):void 0;if(typeof f=="string"&&f[0]==='"'&&!(O instanceof r))return`"${O}${f.slice(1)}`}function c(O,f){return f.emptyStr()?O:O.emptyStr()?f:s`${O}${f}`}e.strConcat=c;function d(O){return typeof O=="number"||typeof O=="boolean"||O===null?O:p(Array.isArray(O)?O.join(","):O)}function m(O){return new n(p(O))}e.stringify=m;function p(O){return JSON.stringify(O).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}e.safeStringify=p;function E(O){return typeof O=="string"&&e.IDENTIFIER.test(O)?new n(`.${O}`):i`[${O}]`}e.getProperty=E;function A(O){if(typeof O=="string"&&e.IDENTIFIER.test(O))return new n(`${O}`);throw new Error(`CodeGen: invalid export name: ${O}, use explicit $id name mapping`)}e.getEsmExportName=A;function R(O){return new n(O.toString())}e.regexpCode=R})(rd)),rd}var nd={},KE;function JE(){return KE||(KE=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ValueScope=e.ValueScopeName=e.Scope=e.varKinds=e.UsedValueState=void 0;const t=so();class r extends Error{constructor(l){super(`CodeGen: "code" for ${l} not defined`),this.value=l.value}}var n;(function(u){u[u.Started=0]="Started",u[u.Completed=1]="Completed"})(n||(e.UsedValueState=n={})),e.varKinds={const:new t.Name("const"),let:new t.Name("let"),var:new t.Name("var")};class i{constructor({prefixes:l,parent:c}={}){this._names={},this._prefixes=l,this._parent=c}toName(l){return l instanceof t.Name?l:this.name(l)}name(l){return new t.Name(this._newName(l))}_newName(l){const c=this._names[l]||this._nameGroup(l);return`${l}${c.index++}`}_nameGroup(l){var c,d;if(!((d=(c=this._parent)===null||c===void 0?void 0:c._prefixes)===null||d===void 0)&&d.has(l)||this._prefixes&&!this._prefixes.has(l))throw new Error(`CodeGen: prefix "${l}" is not allowed in this scope`);return this._names[l]={prefix:l,index:0}}}e.Scope=i;class a extends t.Name{constructor(l,c){super(c),this.prefix=l}setValue(l,{property:c,itemIndex:d}){this.value=l,this.scopePath=(0,t._)`.${new t.Name(c)}[${d}]`}}e.ValueScopeName=a;const s=(0,t._)`\n`;class o extends i{constructor(l){super(l),this._values={},this._scope=l.scope,this.opts={...l,_n:l.lines?s:t.nil}}get(){return this._scope}name(l){return new a(l,this._newName(l))}value(l,c){var d;if(c.ref===void 0)throw new Error("CodeGen: ref must be passed in value");const m=this.toName(l),{prefix:p}=m,E=(d=c.key)!==null&&d!==void 0?d:c.ref;let A=this._values[p];if(A){const f=A.get(E);if(f)return f}else A=this._values[p]=new Map;A.set(E,m);const R=this._scope[p]||(this._scope[p]=[]),O=R.length;return R[O]=c.ref,m.setValue(c,{property:p,itemIndex:O}),m}getValue(l,c){const d=this._values[l];if(d)return d.get(c)}scopeRefs(l,c=this._values){return this._reduceValues(c,d=>{if(d.scopePath===void 0)throw new Error(`CodeGen: name "${d}" has no value`);return(0,t._)`${l}${d.scopePath}`})}scopeCode(l=this._values,c,d){return this._reduceValues(l,m=>{if(m.value===void 0)throw new Error(`CodeGen: name "${m}" has no value`);return m.value.code},c,d)}_reduceValues(l,c,d={},m){let p=t.nil;for(const E in l){const A=l[E];if(!A)continue;const R=d[E]=d[E]||new Map;A.forEach(O=>{if(R.has(O))return;R.set(O,n.Started);let f=c(O);if(f){const v=this.opts.es5?e.varKinds.var:e.varKinds.const;p=(0,t._)`${p}${v} ${O} = ${f};${this.opts._n}`}else if(f=m==null?void 0:m(O))p=(0,t._)`${p}${f}${this.opts._n}`;else throw new r(O);R.set(O,n.Completed)})}return p}}e.ValueScope=o})(nd)),nd}var XE;function Ke(){return XE||(XE=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.or=e.and=e.not=e.CodeGen=e.operators=e.varKinds=e.ValueScopeName=e.ValueScope=e.Scope=e.Name=e.regexpCode=e.stringify=e.getProperty=e.nil=e.strConcat=e.str=e._=void 0;const t=so(),r=JE();var n=so();Object.defineProperty(e,"_",{enumerable:!0,get:function(){return n._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return n.str}}),Object.defineProperty(e,"strConcat",{enumerable:!0,get:function(){return n.strConcat}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return n.nil}}),Object.defineProperty(e,"getProperty",{enumerable:!0,get:function(){return n.getProperty}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return n.stringify}}),Object.defineProperty(e,"regexpCode",{enumerable:!0,get:function(){return n.regexpCode}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return n.Name}});var i=JE();Object.defineProperty(e,"Scope",{enumerable:!0,get:function(){return i.Scope}}),Object.defineProperty(e,"ValueScope",{enumerable:!0,get:function(){return i.ValueScope}}),Object.defineProperty(e,"ValueScopeName",{enumerable:!0,get:function(){return i.ValueScopeName}}),Object.defineProperty(e,"varKinds",{enumerable:!0,get:function(){return i.varKinds}}),e.operators={GT:new t._Code(">"),GTE:new t._Code(">="),LT:new t._Code("<"),LTE:new t._Code("<="),EQ:new t._Code("==="),NEQ:new t._Code("!=="),NOT:new t._Code("!"),OR:new t._Code("||"),AND:new t._Code("&&"),ADD:new t._Code("+")};class a{optimizeNodes(){return this}optimizeNames(N,j){return this}}class s extends a{constructor(N,j,Z){super(),this.varKind=N,this.name=j,this.rhs=Z}render({es5:N,_n:j}){const Z=N?r.varKinds.var:this.varKind,Ee=this.rhs===void 0?"":` = ${this.rhs}`;return`${Z} ${this.name}${Ee};`+j}optimizeNames(N,j){if(N[this.name.str])return this.rhs&&(this.rhs=F(this.rhs,N,j)),this}get names(){return this.rhs instanceof t._CodeOrName?this.rhs.names:{}}}class o extends a{constructor(N,j,Z){super(),this.lhs=N,this.rhs=j,this.sideEffects=Z}render({_n:N}){return`${this.lhs} = ${this.rhs};`+N}optimizeNames(N,j){if(!(this.lhs instanceof t.Name&&!N[this.lhs.str]&&!this.sideEffects))return this.rhs=F(this.rhs,N,j),this}get names(){const N=this.lhs instanceof t.Name?{}:{...this.lhs.names};return U(N,this.rhs)}}class u extends o{constructor(N,j,Z,Ee){super(N,Z,Ee),this.op=j}render({_n:N}){return`${this.lhs} ${this.op}= ${this.rhs};`+N}}class l extends a{constructor(N){super(),this.label=N,this.names={}}render({_n:N}){return`${this.label}:`+N}}class c extends a{constructor(N){super(),this.label=N,this.names={}}render({_n:N}){return`break${this.label?` ${this.label}`:""};`+N}}class d extends a{constructor(N){super(),this.error=N}render({_n:N}){return`throw ${this.error};`+N}get names(){return this.error.names}}class m extends a{constructor(N){super(),this.code=N}render({_n:N}){return`${this.code};`+N}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(N,j){return this.code=F(this.code,N,j),this}get names(){return this.code instanceof t._CodeOrName?this.code.names:{}}}class p extends a{constructor(N=[]){super(),this.nodes=N}render(N){return this.nodes.reduce((j,Z)=>j+Z.render(N),"")}optimizeNodes(){const{nodes:N}=this;let j=N.length;for(;j--;){const Z=N[j].optimizeNodes();Array.isArray(Z)?N.splice(j,1,...Z):Z?N[j]=Z:N.splice(j,1)}return N.length>0?this:void 0}optimizeNames(N,j){const{nodes:Z}=this;let Ee=Z.length;for(;Ee--;){const _e=Z[Ee];_e.optimizeNames(N,j)||(ue(N,_e.names),Z.splice(Ee,1))}return Z.length>0?this:void 0}get names(){return this.nodes.reduce((N,j)=>z(N,j.names),{})}}class E extends p{render(N){return"{"+N._n+super.render(N)+"}"+N._n}}class A extends p{}class R extends E{}R.kind="else";class O extends E{constructor(N,j){super(j),this.condition=N}render(N){let j=`if(${this.condition})`+super.render(N);return this.else&&(j+="else "+this.else.render(N)),j}optimizeNodes(){super.optimizeNodes();const N=this.condition;if(N===!0)return this.nodes;let j=this.else;if(j){const Z=j.optimizeNodes();j=this.else=Array.isArray(Z)?new R(Z):Z}if(j)return N===!1?j instanceof O?j:j.nodes:this.nodes.length?this:new O(ae(N),j instanceof O?[j]:j.nodes);if(!(N===!1||!this.nodes.length))return this}optimizeNames(N,j){var Z;if(this.else=(Z=this.else)===null||Z===void 0?void 0:Z.optimizeNames(N,j),!!(super.optimizeNames(N,j)||this.else))return this.condition=F(this.condition,N,j),this}get names(){const N=super.names;return U(N,this.condition),this.else&&z(N,this.else.names),N}}O.kind="if";class f extends E{}f.kind="for";class v extends f{constructor(N){super(),this.iteration=N}render(N){return`for(${this.iteration})`+super.render(N)}optimizeNames(N,j){if(super.optimizeNames(N,j))return this.iteration=F(this.iteration,N,j),this}get names(){return z(super.names,this.iteration.names)}}class b extends f{constructor(N,j,Z,Ee){super(),this.varKind=N,this.name=j,this.from=Z,this.to=Ee}render(N){const j=N.es5?r.varKinds.var:this.varKind,{name:Z,from:Ee,to:_e}=this;return`for(${j} ${Z}=${Ee}; ${Z}<${_e}; ${Z}++)`+super.render(N)}get names(){const N=U(super.names,this.from);return U(N,this.to)}}class h extends f{constructor(N,j,Z,Ee){super(),this.loop=N,this.varKind=j,this.name=Z,this.iterable=Ee}render(N){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(N)}optimizeNames(N,j){if(super.optimizeNames(N,j))return this.iterable=F(this.iterable,N,j),this}get names(){return z(super.names,this.iterable.names)}}class T extends E{constructor(N,j,Z){super(),this.name=N,this.args=j,this.async=Z}render(N){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(N)}}T.kind="func";class w extends p{render(N){return"return "+super.render(N)}}w.kind="return";class P extends E{render(N){let j="try"+super.render(N);return this.catch&&(j+=this.catch.render(N)),this.finally&&(j+=this.finally.render(N)),j}optimizeNodes(){var N,j;return super.optimizeNodes(),(N=this.catch)===null||N===void 0||N.optimizeNodes(),(j=this.finally)===null||j===void 0||j.optimizeNodes(),this}optimizeNames(N,j){var Z,Ee;return super.optimizeNames(N,j),(Z=this.catch)===null||Z===void 0||Z.optimizeNames(N,j),(Ee=this.finally)===null||Ee===void 0||Ee.optimizeNames(N,j),this}get names(){const N=super.names;return this.catch&&z(N,this.catch.names),this.finally&&z(N,this.finally.names),N}}class B extends E{constructor(N){super(),this.error=N}render(N){return`catch(${this.error})`+super.render(N)}}B.kind="catch";class J extends E{render(N){return"finally"+super.render(N)}}J.kind="finally";class K{constructor(N,j={}){this._values={},this._blockStarts=[],this._constants={},this.opts={...j,_n:j.lines?`
|
|
51
|
+
`:""},this._extScope=N,this._scope=new r.Scope({parent:N}),this._nodes=[new A]}toString(){return this._root.render(this.opts)}name(N){return this._scope.name(N)}scopeName(N){return this._extScope.name(N)}scopeValue(N,j){const Z=this._extScope.value(N,j);return(this._values[Z.prefix]||(this._values[Z.prefix]=new Set)).add(Z),Z}getScopeValue(N,j){return this._extScope.getValue(N,j)}scopeRefs(N){return this._extScope.scopeRefs(N,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(N,j,Z,Ee){const _e=this._scope.toName(j);return Z!==void 0&&Ee&&(this._constants[_e.str]=Z),this._leafNode(new s(N,_e,Z)),_e}const(N,j,Z){return this._def(r.varKinds.const,N,j,Z)}let(N,j,Z){return this._def(r.varKinds.let,N,j,Z)}var(N,j,Z){return this._def(r.varKinds.var,N,j,Z)}assign(N,j,Z){return this._leafNode(new o(N,j,Z))}add(N,j){return this._leafNode(new u(N,e.operators.ADD,j))}code(N){return typeof N=="function"?N():N!==t.nil&&this._leafNode(new m(N)),this}object(...N){const j=["{"];for(const[Z,Ee]of N)j.length>1&&j.push(","),j.push(Z),(Z!==Ee||this.opts.es5)&&(j.push(":"),(0,t.addCodeArg)(j,Ee));return j.push("}"),new t._Code(j)}if(N,j,Z){if(this._blockNode(new O(N)),j&&Z)this.code(j).else().code(Z).endIf();else if(j)this.code(j).endIf();else if(Z)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(N){return this._elseNode(new O(N))}else(){return this._elseNode(new R)}endIf(){return this._endBlockNode(O,R)}_for(N,j){return this._blockNode(N),j&&this.code(j).endFor(),this}for(N,j){return this._for(new v(N),j)}forRange(N,j,Z,Ee,_e=this.opts.es5?r.varKinds.var:r.varKinds.let){const Se=this._scope.toName(N);return this._for(new b(_e,Se,j,Z),()=>Ee(Se))}forOf(N,j,Z,Ee=r.varKinds.const){const _e=this._scope.toName(N);if(this.opts.es5){const Se=j instanceof t.Name?j:this.var("_arr",j);return this.forRange("_i",0,(0,t._)`${Se}.length`,Ie=>{this.var(_e,(0,t._)`${Se}[${Ie}]`),Z(_e)})}return this._for(new h("of",Ee,_e,j),()=>Z(_e))}forIn(N,j,Z,Ee=this.opts.es5?r.varKinds.var:r.varKinds.const){if(this.opts.ownProperties)return this.forOf(N,(0,t._)`Object.keys(${j})`,Z);const _e=this._scope.toName(N);return this._for(new h("in",Ee,_e,j),()=>Z(_e))}endFor(){return this._endBlockNode(f)}label(N){return this._leafNode(new l(N))}break(N){return this._leafNode(new c(N))}return(N){const j=new w;if(this._blockNode(j),this.code(N),j.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(w)}try(N,j,Z){if(!j&&!Z)throw new Error('CodeGen: "try" without "catch" and "finally"');const Ee=new P;if(this._blockNode(Ee),this.code(N),j){const _e=this.name("e");this._currNode=Ee.catch=new B(_e),j(_e)}return Z&&(this._currNode=Ee.finally=new J,this.code(Z)),this._endBlockNode(B,J)}throw(N){return this._leafNode(new d(N))}block(N,j){return this._blockStarts.push(this._nodes.length),N&&this.code(N).endBlock(j),this}endBlock(N){const j=this._blockStarts.pop();if(j===void 0)throw new Error("CodeGen: not in self-balancing block");const Z=this._nodes.length-j;if(Z<0||N!==void 0&&Z!==N)throw new Error(`CodeGen: wrong number of nodes: ${Z} vs ${N} expected`);return this._nodes.length=j,this}func(N,j=t.nil,Z,Ee){return this._blockNode(new T(N,j,Z)),Ee&&this.code(Ee).endFunc(),this}endFunc(){return this._endBlockNode(T)}optimize(N=1){for(;N-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(N){return this._currNode.nodes.push(N),this}_blockNode(N){this._currNode.nodes.push(N),this._nodes.push(N)}_endBlockNode(N,j){const Z=this._currNode;if(Z instanceof N||j&&Z instanceof j)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${j?`${N.kind}/${j.kind}`:N.kind}"`)}_elseNode(N){const j=this._currNode;if(!(j instanceof O))throw new Error('CodeGen: "else" without "if"');return this._currNode=j.else=N,this}get _root(){return this._nodes[0]}get _currNode(){const N=this._nodes;return N[N.length-1]}set _currNode(N){const j=this._nodes;j[j.length-1]=N}}e.CodeGen=K;function z(H,N){for(const j in N)H[j]=(H[j]||0)+(N[j]||0);return H}function U(H,N){return N instanceof t._CodeOrName?z(H,N.names):H}function F(H,N,j){if(H instanceof t.Name)return Z(H);if(!Ee(H))return H;return new t._Code(H._items.reduce((_e,Se)=>(Se instanceof t.Name&&(Se=Z(Se)),Se instanceof t._Code?_e.push(...Se._items):_e.push(Se),_e),[]));function Z(_e){const Se=j[_e.str];return Se===void 0||N[_e.str]!==1?_e:(delete N[_e.str],Se)}function Ee(_e){return _e instanceof t._Code&&_e._items.some(Se=>Se instanceof t.Name&&N[Se.str]===1&&j[Se.str]!==void 0)}}function ue(H,N){for(const j in N)H[j]=(H[j]||0)-(N[j]||0)}function ae(H){return typeof H=="boolean"||typeof H=="number"||H===null?!H:(0,t._)`!${L(H)}`}e.not=ae;const re=D(e.operators.AND);function X(...H){return H.reduce(re)}e.and=X;const W=D(e.operators.OR);function $(...H){return H.reduce(W)}e.or=$;function D(H){return(N,j)=>N===t.nil?j:j===t.nil?N:(0,t._)`${L(N)} ${H} ${L(j)}`}function L(H){return H instanceof t.Name?H:(0,t._)`(${H})`}})(td)),td}var Ze={},QE;function lt(){if(QE)return Ze;QE=1,Object.defineProperty(Ze,"__esModule",{value:!0}),Ze.checkStrictMode=Ze.getErrorPath=Ze.Type=Ze.useFunc=Ze.setEvaluated=Ze.evaluatedPropsToName=Ze.mergeEvaluated=Ze.eachItem=Ze.unescapeJsonPointer=Ze.escapeJsonPointer=Ze.escapeFragment=Ze.unescapeFragment=Ze.schemaRefOrVal=Ze.schemaHasRulesButRef=Ze.schemaHasRules=Ze.checkUnknownRules=Ze.alwaysValidSchema=Ze.toHash=void 0;const e=Ke(),t=so();function r(h){const T={};for(const w of h)T[w]=!0;return T}Ze.toHash=r;function n(h,T){return typeof T=="boolean"?T:Object.keys(T).length===0?!0:(i(h,T),!a(T,h.self.RULES.all))}Ze.alwaysValidSchema=n;function i(h,T=h.schema){const{opts:w,self:P}=h;if(!w.strictSchema||typeof T=="boolean")return;const B=P.RULES.keywords;for(const J in T)B[J]||b(h,`unknown keyword: "${J}"`)}Ze.checkUnknownRules=i;function a(h,T){if(typeof h=="boolean")return!h;for(const w in h)if(T[w])return!0;return!1}Ze.schemaHasRules=a;function s(h,T){if(typeof h=="boolean")return!h;for(const w in h)if(w!=="$ref"&&T.all[w])return!0;return!1}Ze.schemaHasRulesButRef=s;function o({topSchemaRef:h,schemaPath:T},w,P,B){if(!B){if(typeof w=="number"||typeof w=="boolean")return w;if(typeof w=="string")return(0,e._)`${w}`}return(0,e._)`${h}${T}${(0,e.getProperty)(P)}`}Ze.schemaRefOrVal=o;function u(h){return d(decodeURIComponent(h))}Ze.unescapeFragment=u;function l(h){return encodeURIComponent(c(h))}Ze.escapeFragment=l;function c(h){return typeof h=="number"?`${h}`:h.replace(/~/g,"~0").replace(/\//g,"~1")}Ze.escapeJsonPointer=c;function d(h){return h.replace(/~1/g,"/").replace(/~0/g,"~")}Ze.unescapeJsonPointer=d;function m(h,T){if(Array.isArray(h))for(const w of h)T(w);else T(h)}Ze.eachItem=m;function p({mergeNames:h,mergeToName:T,mergeValues:w,resultToName:P}){return(B,J,K,z)=>{const U=K===void 0?J:K instanceof e.Name?(J instanceof e.Name?h(B,J,K):T(B,J,K),K):J instanceof e.Name?(T(B,K,J),J):w(J,K);return z===e.Name&&!(U instanceof e.Name)?P(B,U):U}}Ze.mergeEvaluated={props:p({mergeNames:(h,T,w)=>h.if((0,e._)`${w} !== true && ${T} !== undefined`,()=>{h.if((0,e._)`${T} === true`,()=>h.assign(w,!0),()=>h.assign(w,(0,e._)`${w} || {}`).code((0,e._)`Object.assign(${w}, ${T})`))}),mergeToName:(h,T,w)=>h.if((0,e._)`${w} !== true`,()=>{T===!0?h.assign(w,!0):(h.assign(w,(0,e._)`${w} || {}`),A(h,w,T))}),mergeValues:(h,T)=>h===!0?!0:{...h,...T},resultToName:E}),items:p({mergeNames:(h,T,w)=>h.if((0,e._)`${w} !== true && ${T} !== undefined`,()=>h.assign(w,(0,e._)`${T} === true ? true : ${w} > ${T} ? ${w} : ${T}`)),mergeToName:(h,T,w)=>h.if((0,e._)`${w} !== true`,()=>h.assign(w,T===!0?!0:(0,e._)`${w} > ${T} ? ${w} : ${T}`)),mergeValues:(h,T)=>h===!0?!0:Math.max(h,T),resultToName:(h,T)=>h.var("items",T)})};function E(h,T){if(T===!0)return h.var("props",!0);const w=h.var("props",(0,e._)`{}`);return T!==void 0&&A(h,w,T),w}Ze.evaluatedPropsToName=E;function A(h,T,w){Object.keys(w).forEach(P=>h.assign((0,e._)`${T}${(0,e.getProperty)(P)}`,!0))}Ze.setEvaluated=A;const R={};function O(h,T){return h.scopeValue("func",{ref:T,code:R[T.code]||(R[T.code]=new t._Code(T.code))})}Ze.useFunc=O;var f;(function(h){h[h.Num=0]="Num",h[h.Str=1]="Str"})(f||(Ze.Type=f={}));function v(h,T,w){if(h instanceof e.Name){const P=T===f.Num;return w?P?(0,e._)`"[" + ${h} + "]"`:(0,e._)`"['" + ${h} + "']"`:P?(0,e._)`"/" + ${h}`:(0,e._)`"/" + ${h}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return w?(0,e.getProperty)(h).toString():"/"+c(h)}Ze.getErrorPath=v;function b(h,T,w=h.opts.strictSchema){if(w){if(T=`strict mode: ${T}`,w===!0)throw new Error(T);h.self.logger.warn(T)}}return Ze.checkStrictMode=b,Ze}var Mu={},ZE;function On(){if(ZE)return Mu;ZE=1,Object.defineProperty(Mu,"__esModule",{value:!0});const e=Ke(),t={data:new e.Name("data"),valCxt:new e.Name("valCxt"),instancePath:new e.Name("instancePath"),parentData:new e.Name("parentData"),parentDataProperty:new e.Name("parentDataProperty"),rootData:new e.Name("rootData"),dynamicAnchors:new e.Name("dynamicAnchors"),vErrors:new e.Name("vErrors"),errors:new e.Name("errors"),this:new e.Name("this"),self:new e.Name("self"),scope:new e.Name("scope"),json:new e.Name("json"),jsonPos:new e.Name("jsonPos"),jsonLen:new e.Name("jsonLen"),jsonPart:new e.Name("jsonPart")};return Mu.default=t,Mu}var xE;function Ao(){return xE||(xE=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.extendErrors=e.resetErrorsCount=e.reportExtraError=e.reportError=e.keyword$DataError=e.keywordError=void 0;const t=Ke(),r=lt(),n=On();e.keywordError={message:({keyword:R})=>(0,t.str)`must pass "${R}" keyword validation`},e.keyword$DataError={message:({keyword:R,schemaType:O})=>O?(0,t.str)`"${R}" keyword must be ${O} ($data)`:(0,t.str)`"${R}" keyword is invalid ($data)`};function i(R,O=e.keywordError,f,v){const{it:b}=R,{gen:h,compositeRule:T,allErrors:w}=b,P=d(R,O,f);v??(T||w)?u(h,P):l(b,(0,t._)`[${P}]`)}e.reportError=i;function a(R,O=e.keywordError,f){const{it:v}=R,{gen:b,compositeRule:h,allErrors:T}=v,w=d(R,O,f);u(b,w),h||T||l(v,n.default.vErrors)}e.reportExtraError=a;function s(R,O){R.assign(n.default.errors,O),R.if((0,t._)`${n.default.vErrors} !== null`,()=>R.if(O,()=>R.assign((0,t._)`${n.default.vErrors}.length`,O),()=>R.assign(n.default.vErrors,null)))}e.resetErrorsCount=s;function o({gen:R,keyword:O,schemaValue:f,data:v,errsCount:b,it:h}){if(b===void 0)throw new Error("ajv implementation error");const T=R.name("err");R.forRange("i",b,n.default.errors,w=>{R.const(T,(0,t._)`${n.default.vErrors}[${w}]`),R.if((0,t._)`${T}.instancePath === undefined`,()=>R.assign((0,t._)`${T}.instancePath`,(0,t.strConcat)(n.default.instancePath,h.errorPath))),R.assign((0,t._)`${T}.schemaPath`,(0,t.str)`${h.errSchemaPath}/${O}`),h.opts.verbose&&(R.assign((0,t._)`${T}.schema`,f),R.assign((0,t._)`${T}.data`,v))})}e.extendErrors=o;function u(R,O){const f=R.const("err",O);R.if((0,t._)`${n.default.vErrors} === null`,()=>R.assign(n.default.vErrors,(0,t._)`[${f}]`),(0,t._)`${n.default.vErrors}.push(${f})`),R.code((0,t._)`${n.default.errors}++`)}function l(R,O){const{gen:f,validateName:v,schemaEnv:b}=R;b.$async?f.throw((0,t._)`new ${R.ValidationError}(${O})`):(f.assign((0,t._)`${v}.errors`,O),f.return(!1))}const c={keyword:new t.Name("keyword"),schemaPath:new t.Name("schemaPath"),params:new t.Name("params"),propertyName:new t.Name("propertyName"),message:new t.Name("message"),schema:new t.Name("schema"),parentSchema:new t.Name("parentSchema")};function d(R,O,f){const{createErrors:v}=R.it;return v===!1?(0,t._)`{}`:m(R,O,f)}function m(R,O,f={}){const{gen:v,it:b}=R,h=[p(b,f),E(R,f)];return A(R,O,h),v.object(...h)}function p({errorPath:R},{instancePath:O}){const f=O?(0,t.str)`${R}${(0,r.getErrorPath)(O,r.Type.Str)}`:R;return[n.default.instancePath,(0,t.strConcat)(n.default.instancePath,f)]}function E({keyword:R,it:{errSchemaPath:O}},{schemaPath:f,parentSchema:v}){let b=v?O:(0,t.str)`${O}/${R}`;return f&&(b=(0,t.str)`${b}${(0,r.getErrorPath)(f,r.Type.Str)}`),[c.schemaPath,b]}function A(R,{params:O,message:f},v){const{keyword:b,data:h,schemaValue:T,it:w}=R,{opts:P,propertyName:B,topSchemaRef:J,schemaPath:K}=w;v.push([c.keyword,b],[c.params,typeof O=="function"?O(R):O||(0,t._)`{}`]),P.messages&&v.push([c.message,typeof f=="function"?f(R):f]),P.verbose&&v.push([c.schema,T],[c.parentSchema,(0,t._)`${J}${K}`],[n.default.data,h]),B&&v.push([c.propertyName,B])}})(ed)),ed}var ev;function Jq(){if(ev)return Qn;ev=1,Object.defineProperty(Qn,"__esModule",{value:!0}),Qn.boolOrEmptySchema=Qn.topBoolOrEmptySchema=void 0;const e=Ao(),t=Ke(),r=On(),n={message:"boolean schema is false"};function i(o){const{gen:u,schema:l,validateName:c}=o;l===!1?s(o,!1):typeof l=="object"&&l.$async===!0?u.return(r.default.data):(u.assign((0,t._)`${c}.errors`,null),u.return(!0))}Qn.topBoolOrEmptySchema=i;function a(o,u){const{gen:l,schema:c}=o;c===!1?(l.var(u,!1),s(o)):l.var(u,!0)}Qn.boolOrEmptySchema=a;function s(o,u){const{gen:l,data:c}=o,d={gen:l,keyword:"false schema",data:c,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:o};(0,e.reportError)(d,n,void 0,u)}return Qn}var Yt={},Zn={},tv;function oN(){if(tv)return Zn;tv=1,Object.defineProperty(Zn,"__esModule",{value:!0}),Zn.getRules=Zn.isJSONType=void 0;const e=["string","number","integer","boolean","null","object","array"],t=new Set(e);function r(i){return typeof i=="string"&&t.has(i)}Zn.isJSONType=r;function n(){const i={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:{...i,integer:!0,boolean:!0,null:!0},rules:[{rules:[]},i.number,i.string,i.array,i.object],post:{rules:[]},all:{},keywords:{}}}return Zn.getRules=n,Zn}var hn={},rv;function uN(){if(rv)return hn;rv=1,Object.defineProperty(hn,"__esModule",{value:!0}),hn.shouldUseRule=hn.shouldUseGroup=hn.schemaHasRulesForType=void 0;function e({schema:n,self:i},a){const s=i.RULES.types[a];return s&&s!==!0&&t(n,s)}hn.schemaHasRulesForType=e;function t(n,i){return i.rules.some(a=>r(n,a))}hn.shouldUseGroup=t;function r(n,i){var a;return n[i.keyword]!==void 0||((a=i.definition.implements)===null||a===void 0?void 0:a.some(s=>n[s]!==void 0))}return hn.shouldUseRule=r,hn}var nv;function xc(){if(nv)return Yt;nv=1,Object.defineProperty(Yt,"__esModule",{value:!0}),Yt.reportTypeError=Yt.checkDataTypes=Yt.checkDataType=Yt.coerceAndCheckDataType=Yt.getJSONTypes=Yt.getSchemaTypes=Yt.DataType=void 0;const e=oN(),t=uN(),r=Ao(),n=Ke(),i=lt();var a;(function(f){f[f.Correct=0]="Correct",f[f.Wrong=1]="Wrong"})(a||(Yt.DataType=a={}));function s(f){const v=o(f.type);if(v.includes("null")){if(f.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!v.length&&f.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');f.nullable===!0&&v.push("null")}return v}Yt.getSchemaTypes=s;function o(f){const v=Array.isArray(f)?f:f?[f]:[];if(v.every(e.isJSONType))return v;throw new Error("type must be JSONType or JSONType[]: "+v.join(","))}Yt.getJSONTypes=o;function u(f,v){const{gen:b,data:h,opts:T}=f,w=c(v,T.coerceTypes),P=v.length>0&&!(w.length===0&&v.length===1&&(0,t.schemaHasRulesForType)(f,v[0]));if(P){const B=E(v,h,T.strictNumbers,a.Wrong);b.if(B,()=>{w.length?d(f,v,w):R(f)})}return P}Yt.coerceAndCheckDataType=u;const l=new Set(["string","number","integer","boolean","null"]);function c(f,v){return v?f.filter(b=>l.has(b)||v==="array"&&b==="array"):[]}function d(f,v,b){const{gen:h,data:T,opts:w}=f,P=h.let("dataType",(0,n._)`typeof ${T}`),B=h.let("coerced",(0,n._)`undefined`);w.coerceTypes==="array"&&h.if((0,n._)`${P} == 'object' && Array.isArray(${T}) && ${T}.length == 1`,()=>h.assign(T,(0,n._)`${T}[0]`).assign(P,(0,n._)`typeof ${T}`).if(E(v,T,w.strictNumbers),()=>h.assign(B,T))),h.if((0,n._)`${B} !== undefined`);for(const K of b)(l.has(K)||K==="array"&&w.coerceTypes==="array")&&J(K);h.else(),R(f),h.endIf(),h.if((0,n._)`${B} !== undefined`,()=>{h.assign(T,B),m(f,B)});function J(K){switch(K){case"string":h.elseIf((0,n._)`${P} == "number" || ${P} == "boolean"`).assign(B,(0,n._)`"" + ${T}`).elseIf((0,n._)`${T} === null`).assign(B,(0,n._)`""`);return;case"number":h.elseIf((0,n._)`${P} == "boolean" || ${T} === null
|
|
52
|
+
|| (${P} == "string" && ${T} && ${T} == +${T})`).assign(B,(0,n._)`+${T}`);return;case"integer":h.elseIf((0,n._)`${P} === "boolean" || ${T} === null
|
|
53
|
+
|| (${P} === "string" && ${T} && ${T} == +${T} && !(${T} % 1))`).assign(B,(0,n._)`+${T}`);return;case"boolean":h.elseIf((0,n._)`${T} === "false" || ${T} === 0 || ${T} === null`).assign(B,!1).elseIf((0,n._)`${T} === "true" || ${T} === 1`).assign(B,!0);return;case"null":h.elseIf((0,n._)`${T} === "" || ${T} === 0 || ${T} === false`),h.assign(B,null);return;case"array":h.elseIf((0,n._)`${P} === "string" || ${P} === "number"
|
|
54
|
+
|| ${P} === "boolean" || ${T} === null`).assign(B,(0,n._)`[${T}]`)}}}function m({gen:f,parentData:v,parentDataProperty:b},h){f.if((0,n._)`${v} !== undefined`,()=>f.assign((0,n._)`${v}[${b}]`,h))}function p(f,v,b,h=a.Correct){const T=h===a.Correct?n.operators.EQ:n.operators.NEQ;let w;switch(f){case"null":return(0,n._)`${v} ${T} null`;case"array":w=(0,n._)`Array.isArray(${v})`;break;case"object":w=(0,n._)`${v} && typeof ${v} == "object" && !Array.isArray(${v})`;break;case"integer":w=P((0,n._)`!(${v} % 1) && !isNaN(${v})`);break;case"number":w=P();break;default:return(0,n._)`typeof ${v} ${T} ${f}`}return h===a.Correct?w:(0,n.not)(w);function P(B=n.nil){return(0,n.and)((0,n._)`typeof ${v} == "number"`,B,b?(0,n._)`isFinite(${v})`:n.nil)}}Yt.checkDataType=p;function E(f,v,b,h){if(f.length===1)return p(f[0],v,b,h);let T;const w=(0,i.toHash)(f);if(w.array&&w.object){const P=(0,n._)`typeof ${v} != "object"`;T=w.null?P:(0,n._)`!${v} || ${P}`,delete w.null,delete w.array,delete w.object}else T=n.nil;w.number&&delete w.integer;for(const P in w)T=(0,n.and)(T,p(P,v,b,h));return T}Yt.checkDataTypes=E;const A={message:({schema:f})=>`must be ${f}`,params:({schema:f,schemaValue:v})=>typeof f=="string"?(0,n._)`{type: ${f}}`:(0,n._)`{type: ${v}}`};function R(f){const v=O(f);(0,r.reportError)(v,A)}Yt.reportTypeError=R;function O(f){const{gen:v,data:b,schema:h}=f,T=(0,i.schemaRefOrVal)(f,h,"type");return{gen:v,keyword:"type",data:b,schema:h.type,schemaCode:T,schemaValue:T,parentSchema:h,params:{},it:f}}return Yt}var os={},iv;function Xq(){if(iv)return os;iv=1,Object.defineProperty(os,"__esModule",{value:!0}),os.assignDefaults=void 0;const e=Ke(),t=lt();function r(i,a){const{properties:s,items:o}=i.schema;if(a==="object"&&s)for(const u in s)n(i,u,s[u].default);else a==="array"&&Array.isArray(o)&&o.forEach((u,l)=>n(i,l,u.default))}os.assignDefaults=r;function n(i,a,s){const{gen:o,compositeRule:u,data:l,opts:c}=i;if(s===void 0)return;const d=(0,e._)`${l}${(0,e.getProperty)(a)}`;if(u){(0,t.checkStrictMode)(i,`default is ignored for: ${d}`);return}let m=(0,e._)`${d} === undefined`;c.useDefaults==="empty"&&(m=(0,e._)`${m} || ${d} === null || ${d} === ""`),o.if(m,(0,e._)`${d} = ${(0,e.stringify)(s)}`)}return os}var Pr={},yt={},av;function Ur(){if(av)return yt;av=1,Object.defineProperty(yt,"__esModule",{value:!0}),yt.validateUnion=yt.validateArray=yt.usePattern=yt.callValidateCode=yt.schemaProperties=yt.allSchemaProperties=yt.noPropertyInData=yt.propertyInData=yt.isOwnProperty=yt.hasPropFunc=yt.reportMissingProp=yt.checkMissingProp=yt.checkReportMissingProp=void 0;const e=Ke(),t=lt(),r=On(),n=lt();function i(f,v){const{gen:b,data:h,it:T}=f;b.if(c(b,h,v,T.opts.ownProperties),()=>{f.setParams({missingProperty:(0,e._)`${v}`},!0),f.error()})}yt.checkReportMissingProp=i;function a({gen:f,data:v,it:{opts:b}},h,T){return(0,e.or)(...h.map(w=>(0,e.and)(c(f,v,w,b.ownProperties),(0,e._)`${T} = ${w}`)))}yt.checkMissingProp=a;function s(f,v){f.setParams({missingProperty:v},!0),f.error()}yt.reportMissingProp=s;function o(f){return f.scopeValue("func",{ref:Object.prototype.hasOwnProperty,code:(0,e._)`Object.prototype.hasOwnProperty`})}yt.hasPropFunc=o;function u(f,v,b){return(0,e._)`${o(f)}.call(${v}, ${b})`}yt.isOwnProperty=u;function l(f,v,b,h){const T=(0,e._)`${v}${(0,e.getProperty)(b)} !== undefined`;return h?(0,e._)`${T} && ${u(f,v,b)}`:T}yt.propertyInData=l;function c(f,v,b,h){const T=(0,e._)`${v}${(0,e.getProperty)(b)} === undefined`;return h?(0,e.or)(T,(0,e.not)(u(f,v,b))):T}yt.noPropertyInData=c;function d(f){return f?Object.keys(f).filter(v=>v!=="__proto__"):[]}yt.allSchemaProperties=d;function m(f,v){return d(v).filter(b=>!(0,t.alwaysValidSchema)(f,v[b]))}yt.schemaProperties=m;function p({schemaCode:f,data:v,it:{gen:b,topSchemaRef:h,schemaPath:T,errorPath:w},it:P},B,J,K){const z=K?(0,e._)`${f}, ${v}, ${h}${T}`:v,U=[[r.default.instancePath,(0,e.strConcat)(r.default.instancePath,w)],[r.default.parentData,P.parentData],[r.default.parentDataProperty,P.parentDataProperty],[r.default.rootData,r.default.rootData]];P.opts.dynamicRef&&U.push([r.default.dynamicAnchors,r.default.dynamicAnchors]);const F=(0,e._)`${z}, ${b.object(...U)}`;return J!==e.nil?(0,e._)`${B}.call(${J}, ${F})`:(0,e._)`${B}(${F})`}yt.callValidateCode=p;const E=(0,e._)`new RegExp`;function A({gen:f,it:{opts:v}},b){const h=v.unicodeRegExp?"u":"",{regExp:T}=v.code,w=T(b,h);return f.scopeValue("pattern",{key:w.toString(),ref:w,code:(0,e._)`${T.code==="new RegExp"?E:(0,n.useFunc)(f,T)}(${b}, ${h})`})}yt.usePattern=A;function R(f){const{gen:v,data:b,keyword:h,it:T}=f,w=v.name("valid");if(T.allErrors){const B=v.let("valid",!0);return P(()=>v.assign(B,!1)),B}return v.var(w,!0),P(()=>v.break()),w;function P(B){const J=v.const("len",(0,e._)`${b}.length`);v.forRange("i",0,J,K=>{f.subschema({keyword:h,dataProp:K,dataPropType:t.Type.Num},w),v.if((0,e.not)(w),B)})}}yt.validateArray=R;function O(f){const{gen:v,schema:b,keyword:h,it:T}=f;if(!Array.isArray(b))throw new Error("ajv implementation error");if(b.some(J=>(0,t.alwaysValidSchema)(T,J))&&!T.opts.unevaluated)return;const P=v.let("valid",!1),B=v.name("_valid");v.block(()=>b.forEach((J,K)=>{const z=f.subschema({keyword:h,schemaProp:K,compositeRule:!0},B);v.assign(P,(0,e._)`${P} || ${B}`),f.mergeValidEvaluated(z,B)||v.if((0,e.not)(P))})),f.result(P,()=>f.reset(),()=>f.error(!0))}return yt.validateUnion=O,yt}var sv;function Qq(){if(sv)return Pr;sv=1,Object.defineProperty(Pr,"__esModule",{value:!0}),Pr.validateKeywordUsage=Pr.validSchemaType=Pr.funcKeywordCode=Pr.macroKeywordCode=void 0;const e=Ke(),t=On(),r=Ur(),n=Ao();function i(m,p){const{gen:E,keyword:A,schema:R,parentSchema:O,it:f}=m,v=p.macro.call(f.self,R,O,f),b=l(E,A,v);f.opts.validateSchema!==!1&&f.self.validateSchema(v,!0);const h=E.name("valid");m.subschema({schema:v,schemaPath:e.nil,errSchemaPath:`${f.errSchemaPath}/${A}`,topSchemaRef:b,compositeRule:!0},h),m.pass(h,()=>m.error(!0))}Pr.macroKeywordCode=i;function a(m,p){var E;const{gen:A,keyword:R,schema:O,parentSchema:f,$data:v,it:b}=m;u(b,p);const h=!v&&p.compile?p.compile.call(b.self,O,f,b):p.validate,T=l(A,R,h),w=A.let("valid");m.block$data(w,P),m.ok((E=p.valid)!==null&&E!==void 0?E:w);function P(){if(p.errors===!1)K(),p.modifying&&s(m),z(()=>m.error());else{const U=p.async?B():J();p.modifying&&s(m),z(()=>o(m,U))}}function B(){const U=A.let("ruleErrs",null);return A.try(()=>K((0,e._)`await `),F=>A.assign(w,!1).if((0,e._)`${F} instanceof ${b.ValidationError}`,()=>A.assign(U,(0,e._)`${F}.errors`),()=>A.throw(F))),U}function J(){const U=(0,e._)`${T}.errors`;return A.assign(U,null),K(e.nil),U}function K(U=p.async?(0,e._)`await `:e.nil){const F=b.opts.passContext?t.default.this:t.default.self,ue=!("compile"in p&&!v||p.schema===!1);A.assign(w,(0,e._)`${U}${(0,r.callValidateCode)(m,T,F,ue)}`,p.modifying)}function z(U){var F;A.if((0,e.not)((F=p.valid)!==null&&F!==void 0?F:w),U)}}Pr.funcKeywordCode=a;function s(m){const{gen:p,data:E,it:A}=m;p.if(A.parentData,()=>p.assign(E,(0,e._)`${A.parentData}[${A.parentDataProperty}]`))}function o(m,p){const{gen:E}=m;E.if((0,e._)`Array.isArray(${p})`,()=>{E.assign(t.default.vErrors,(0,e._)`${t.default.vErrors} === null ? ${p} : ${t.default.vErrors}.concat(${p})`).assign(t.default.errors,(0,e._)`${t.default.vErrors}.length`),(0,n.extendErrors)(m)},()=>m.error())}function u({schemaEnv:m},p){if(p.async&&!m.$async)throw new Error("async keyword in sync schema")}function l(m,p,E){if(E===void 0)throw new Error(`keyword "${p}" failed to compile`);return m.scopeValue("keyword",typeof E=="function"?{ref:E}:{ref:E,code:(0,e.stringify)(E)})}function c(m,p,E=!1){return!p.length||p.some(A=>A==="array"?Array.isArray(m):A==="object"?m&&typeof m=="object"&&!Array.isArray(m):typeof m==A||E&&typeof m>"u")}Pr.validSchemaType=c;function d({schema:m,opts:p,self:E,errSchemaPath:A},R,O){if(Array.isArray(R.keyword)?!R.keyword.includes(O):R.keyword!==O)throw new Error("ajv implementation error");const f=R.dependencies;if(f!=null&&f.some(v=>!Object.prototype.hasOwnProperty.call(m,v)))throw new Error(`parent schema must have dependencies of ${O}: ${f.join(",")}`);if(R.validateSchema&&!R.validateSchema(m[O])){const b=`keyword "${O}" value is invalid at path "${A}": `+E.errorsText(R.validateSchema.errors);if(p.validateSchema==="log")E.logger.error(b);else throw new Error(b)}}return Pr.validateKeywordUsage=d,Pr}var yn={},ov;function Zq(){if(ov)return yn;ov=1,Object.defineProperty(yn,"__esModule",{value:!0}),yn.extendSubschemaMode=yn.extendSubschemaData=yn.getSubschema=void 0;const e=Ke(),t=lt();function r(a,{keyword:s,schemaProp:o,schema:u,schemaPath:l,errSchemaPath:c,topSchemaRef:d}){if(s!==void 0&&u!==void 0)throw new Error('both "keyword" and "schema" passed, only one allowed');if(s!==void 0){const m=a.schema[s];return o===void 0?{schema:m,schemaPath:(0,e._)`${a.schemaPath}${(0,e.getProperty)(s)}`,errSchemaPath:`${a.errSchemaPath}/${s}`}:{schema:m[o],schemaPath:(0,e._)`${a.schemaPath}${(0,e.getProperty)(s)}${(0,e.getProperty)(o)}`,errSchemaPath:`${a.errSchemaPath}/${s}/${(0,t.escapeFragment)(o)}`}}if(u!==void 0){if(l===void 0||c===void 0||d===void 0)throw new Error('"schemaPath", "errSchemaPath" and "topSchemaRef" are required with "schema"');return{schema:u,schemaPath:l,topSchemaRef:d,errSchemaPath:c}}throw new Error('either "keyword" or "schema" must be passed')}yn.getSubschema=r;function n(a,s,{dataProp:o,dataPropType:u,data:l,dataTypes:c,propertyName:d}){if(l!==void 0&&o!==void 0)throw new Error('both "data" and "dataProp" passed, only one allowed');const{gen:m}=s;if(o!==void 0){const{errorPath:E,dataPathArr:A,opts:R}=s,O=m.let("data",(0,e._)`${s.data}${(0,e.getProperty)(o)}`,!0);p(O),a.errorPath=(0,e.str)`${E}${(0,t.getErrorPath)(o,u,R.jsPropertySyntax)}`,a.parentDataProperty=(0,e._)`${o}`,a.dataPathArr=[...A,a.parentDataProperty]}if(l!==void 0){const E=l instanceof e.Name?l:m.let("data",l,!0);p(E),d!==void 0&&(a.propertyName=d)}c&&(a.dataTypes=c);function p(E){a.data=E,a.dataLevel=s.dataLevel+1,a.dataTypes=[],s.definedProperties=new Set,a.parentData=s.data,a.dataNames=[...s.dataNames,E]}}yn.extendSubschemaData=n;function i(a,{jtdDiscriminator:s,jtdMetadata:o,compositeRule:u,createErrors:l,allErrors:c}){u!==void 0&&(a.compositeRule=u),l!==void 0&&(a.createErrors=l),c!==void 0&&(a.allErrors=c),a.jtdDiscriminator=s,a.jtdMetadata=o}return yn.extendSubschemaMode=i,yn}var or={},id,uv;function qg(){return uv||(uv=1,id=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var n,i,a;if(Array.isArray(t)){if(n=t.length,n!=r.length)return!1;for(i=n;i--!==0;)if(!e(t[i],r[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(a=Object.keys(t),n=a.length,n!==Object.keys(r).length)return!1;for(i=n;i--!==0;)if(!Object.prototype.hasOwnProperty.call(r,a[i]))return!1;for(i=n;i--!==0;){var s=a[i];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}),id}var ad={exports:{}},cv;function xq(){if(cv)return ad.exports;cv=1;var e=ad.exports=function(n,i,a){typeof i=="function"&&(a=i,i={}),a=i.cb||a;var s=typeof a=="function"?a:a.pre||function(){},o=a.post||function(){};t(i,s,o,n,"",n)};e.keywords={additionalItems:!0,items:!0,contains:!0,additionalProperties:!0,propertyNames:!0,not:!0,if:!0,then:!0,else:!0},e.arrayKeywords={items:!0,allOf:!0,anyOf:!0,oneOf:!0},e.propsKeywords={$defs:!0,definitions:!0,properties:!0,patternProperties:!0,dependencies:!0},e.skipKeywords={default:!0,enum:!0,const:!0,required:!0,maximum:!0,minimum:!0,exclusiveMaximum:!0,exclusiveMinimum:!0,multipleOf:!0,maxLength:!0,minLength:!0,pattern:!0,format:!0,maxItems:!0,minItems:!0,uniqueItems:!0,maxProperties:!0,minProperties:!0};function t(n,i,a,s,o,u,l,c,d,m){if(s&&typeof s=="object"&&!Array.isArray(s)){i(s,o,u,l,c,d,m);for(var p in s){var E=s[p];if(Array.isArray(E)){if(p in e.arrayKeywords)for(var A=0;A<E.length;A++)t(n,i,a,E[A],o+"/"+p+"/"+A,u,o,p,s,A)}else if(p in e.propsKeywords){if(E&&typeof E=="object")for(var R in E)t(n,i,a,E[R],o+"/"+p+"/"+r(R),u,o,p,s,R)}else(p in e.keywords||n.allKeys&&!(p in e.skipKeywords))&&t(n,i,a,E,o+"/"+p,u,o,p,s)}a(s,o,u,l,c,d,m)}}function r(n){return n.replace(/~/g,"~0").replace(/\//g,"~1")}return ad.exports}var lv;function pl(){if(lv)return or;lv=1,Object.defineProperty(or,"__esModule",{value:!0}),or.getSchemaRefs=or.resolveUrl=or.normalizeId=or._getFullPath=or.getFullPath=or.inlineRef=void 0;const e=lt(),t=qg(),r=xq(),n=new Set(["type","format","pattern","maxLength","minLength","maxProperties","minProperties","maxItems","minItems","maximum","minimum","uniqueItems","multipleOf","required","enum","const"]);function i(A,R=!0){return typeof A=="boolean"?!0:R===!0?!s(A):R?o(A)<=R:!1}or.inlineRef=i;const a=new Set(["$ref","$recursiveRef","$recursiveAnchor","$dynamicRef","$dynamicAnchor"]);function s(A){for(const R in A){if(a.has(R))return!0;const O=A[R];if(Array.isArray(O)&&O.some(s)||typeof O=="object"&&s(O))return!0}return!1}function o(A){let R=0;for(const O in A){if(O==="$ref")return 1/0;if(R++,!n.has(O)&&(typeof A[O]=="object"&&(0,e.eachItem)(A[O],f=>R+=o(f)),R===1/0))return 1/0}return R}function u(A,R="",O){O!==!1&&(R=d(R));const f=A.parse(R);return l(A,f)}or.getFullPath=u;function l(A,R){return A.serialize(R).split("#")[0]+"#"}or._getFullPath=l;const c=/#\/?$/;function d(A){return A?A.replace(c,""):""}or.normalizeId=d;function m(A,R,O){return O=d(O),A.resolve(R,O)}or.resolveUrl=m;const p=/^[a-z_][-a-z0-9._]*$/i;function E(A,R){if(typeof A=="boolean")return{};const{schemaId:O,uriResolver:f}=this.opts,v=d(A[O]||R),b={"":v},h=u(f,v,!1),T={},w=new Set;return r(A,{allKeys:!0},(J,K,z,U)=>{if(U===void 0)return;const F=h+K;let ue=b[U];typeof J[O]=="string"&&(ue=ae.call(this,J[O])),re.call(this,J.$anchor),re.call(this,J.$dynamicAnchor),b[K]=ue;function ae(X){const W=this.opts.uriResolver.resolve;if(X=d(ue?W(ue,X):X),w.has(X))throw B(X);w.add(X);let $=this.refs[X];return typeof $=="string"&&($=this.refs[$]),typeof $=="object"?P(J,$.schema,X):X!==d(F)&&(X[0]==="#"?(P(J,T[X],X),T[X]=J):this.refs[X]=F),X}function re(X){if(typeof X=="string"){if(!p.test(X))throw new Error(`invalid anchor "${X}"`);ae.call(this,`#${X}`)}}}),T;function P(J,K,z){if(K!==void 0&&!t(J,K))throw B(z)}function B(J){return new Error(`reference "${J}" resolves to more than one schema`)}}return or.getSchemaRefs=E,or}var dv;function wo(){if(dv)return mn;dv=1,Object.defineProperty(mn,"__esModule",{value:!0}),mn.getData=mn.KeywordCxt=mn.validateFunctionCode=void 0;const e=Jq(),t=xc(),r=uN(),n=xc(),i=Xq(),a=Qq(),s=Zq(),o=Ke(),u=On(),l=pl(),c=lt(),d=Ao();function m(ne){if(h(ne)&&(w(ne),b(ne))){R(ne);return}p(ne,()=>(0,e.topBoolOrEmptySchema)(ne))}mn.validateFunctionCode=m;function p({gen:ne,validateName:ce,schema:de,schemaEnv:me,opts:Te},Ae){Te.code.es5?ne.func(ce,(0,o._)`${u.default.data}, ${u.default.valCxt}`,me.$async,()=>{ne.code((0,o._)`"use strict"; ${f(de,Te)}`),A(ne,Te),ne.code(Ae)}):ne.func(ce,(0,o._)`${u.default.data}, ${E(Te)}`,me.$async,()=>ne.code(f(de,Te)).code(Ae))}function E(ne){return(0,o._)`{${u.default.instancePath}="", ${u.default.parentData}, ${u.default.parentDataProperty}, ${u.default.rootData}=${u.default.data}${ne.dynamicRef?(0,o._)`, ${u.default.dynamicAnchors}={}`:o.nil}}={}`}function A(ne,ce){ne.if(u.default.valCxt,()=>{ne.var(u.default.instancePath,(0,o._)`${u.default.valCxt}.${u.default.instancePath}`),ne.var(u.default.parentData,(0,o._)`${u.default.valCxt}.${u.default.parentData}`),ne.var(u.default.parentDataProperty,(0,o._)`${u.default.valCxt}.${u.default.parentDataProperty}`),ne.var(u.default.rootData,(0,o._)`${u.default.valCxt}.${u.default.rootData}`),ce.dynamicRef&&ne.var(u.default.dynamicAnchors,(0,o._)`${u.default.valCxt}.${u.default.dynamicAnchors}`)},()=>{ne.var(u.default.instancePath,(0,o._)`""`),ne.var(u.default.parentData,(0,o._)`undefined`),ne.var(u.default.parentDataProperty,(0,o._)`undefined`),ne.var(u.default.rootData,u.default.data),ce.dynamicRef&&ne.var(u.default.dynamicAnchors,(0,o._)`{}`)})}function R(ne){const{schema:ce,opts:de,gen:me}=ne;p(ne,()=>{de.$comment&&ce.$comment&&U(ne),J(ne),me.let(u.default.vErrors,null),me.let(u.default.errors,0),de.unevaluated&&O(ne),P(ne),F(ne)})}function O(ne){const{gen:ce,validateName:de}=ne;ne.evaluated=ce.const("evaluated",(0,o._)`${de}.evaluated`),ce.if((0,o._)`${ne.evaluated}.dynamicProps`,()=>ce.assign((0,o._)`${ne.evaluated}.props`,(0,o._)`undefined`)),ce.if((0,o._)`${ne.evaluated}.dynamicItems`,()=>ce.assign((0,o._)`${ne.evaluated}.items`,(0,o._)`undefined`))}function f(ne,ce){const de=typeof ne=="object"&&ne[ce.schemaId];return de&&(ce.code.source||ce.code.process)?(0,o._)`/*# sourceURL=${de} */`:o.nil}function v(ne,ce){if(h(ne)&&(w(ne),b(ne))){T(ne,ce);return}(0,e.boolOrEmptySchema)(ne,ce)}function b({schema:ne,self:ce}){if(typeof ne=="boolean")return!ne;for(const de in ne)if(ce.RULES.all[de])return!0;return!1}function h(ne){return typeof ne.schema!="boolean"}function T(ne,ce){const{schema:de,gen:me,opts:Te}=ne;Te.$comment&&de.$comment&&U(ne),K(ne),z(ne);const Ae=me.const("_errs",u.default.errors);P(ne,Ae),me.var(ce,(0,o._)`${Ae} === ${u.default.errors}`)}function w(ne){(0,c.checkUnknownRules)(ne),B(ne)}function P(ne,ce){if(ne.opts.jtd)return ae(ne,[],!1,ce);const de=(0,t.getSchemaTypes)(ne.schema),me=(0,t.coerceAndCheckDataType)(ne,de);ae(ne,de,!me,ce)}function B(ne){const{schema:ce,errSchemaPath:de,opts:me,self:Te}=ne;ce.$ref&&me.ignoreKeywordsWithRef&&(0,c.schemaHasRulesButRef)(ce,Te.RULES)&&Te.logger.warn(`$ref: keywords ignored in schema at path "${de}"`)}function J(ne){const{schema:ce,opts:de}=ne;ce.default!==void 0&&de.useDefaults&&de.strictSchema&&(0,c.checkStrictMode)(ne,"default is ignored in the schema root")}function K(ne){const ce=ne.schema[ne.opts.schemaId];ce&&(ne.baseId=(0,l.resolveUrl)(ne.opts.uriResolver,ne.baseId,ce))}function z(ne){if(ne.schema.$async&&!ne.schemaEnv.$async)throw new Error("async schema in sync schema")}function U({gen:ne,schemaEnv:ce,schema:de,errSchemaPath:me,opts:Te}){const Ae=de.$comment;if(Te.$comment===!0)ne.code((0,o._)`${u.default.self}.logger.log(${Ae})`);else if(typeof Te.$comment=="function"){const Be=(0,o.str)`${me}/$comment`,We=ne.scopeValue("root",{ref:ce.root});ne.code((0,o._)`${u.default.self}.opts.$comment(${Ae}, ${Be}, ${We}.schema)`)}}function F(ne){const{gen:ce,schemaEnv:de,validateName:me,ValidationError:Te,opts:Ae}=ne;de.$async?ce.if((0,o._)`${u.default.errors} === 0`,()=>ce.return(u.default.data),()=>ce.throw((0,o._)`new ${Te}(${u.default.vErrors})`)):(ce.assign((0,o._)`${me}.errors`,u.default.vErrors),Ae.unevaluated&&ue(ne),ce.return((0,o._)`${u.default.errors} === 0`))}function ue({gen:ne,evaluated:ce,props:de,items:me}){de instanceof o.Name&&ne.assign((0,o._)`${ce}.props`,de),me instanceof o.Name&&ne.assign((0,o._)`${ce}.items`,me)}function ae(ne,ce,de,me){const{gen:Te,schema:Ae,data:Be,allErrors:We,opts:et,self:Je}=ne,{RULES:st}=Je;if(Ae.$ref&&(et.ignoreKeywordsWithRef||!(0,c.schemaHasRulesButRef)(Ae,st))){Te.block(()=>Ee(ne,"$ref",st.all.$ref.definition));return}et.jtd||X(ne,ce),Te.block(()=>{for(const gt of st.rules)Mt(gt);Mt(st.post)});function Mt(gt){(0,r.shouldUseGroup)(Ae,gt)&&(gt.type?(Te.if((0,n.checkDataType)(gt.type,Be,et.strictNumbers)),re(ne,gt),ce.length===1&&ce[0]===gt.type&&de&&(Te.else(),(0,n.reportTypeError)(ne)),Te.endIf()):re(ne,gt),We||Te.if((0,o._)`${u.default.errors} === ${me||0}`))}}function re(ne,ce){const{gen:de,schema:me,opts:{useDefaults:Te}}=ne;Te&&(0,i.assignDefaults)(ne,ce.type),de.block(()=>{for(const Ae of ce.rules)(0,r.shouldUseRule)(me,Ae)&&Ee(ne,Ae.keyword,Ae.definition,ce.type)})}function X(ne,ce){ne.schemaEnv.meta||!ne.opts.strictTypes||(W(ne,ce),ne.opts.allowUnionTypes||$(ne,ce),D(ne,ne.dataTypes))}function W(ne,ce){if(ce.length){if(!ne.dataTypes.length){ne.dataTypes=ce;return}ce.forEach(de=>{H(ne.dataTypes,de)||j(ne,`type "${de}" not allowed by context "${ne.dataTypes.join(",")}"`)}),N(ne,ce)}}function $(ne,ce){ce.length>1&&!(ce.length===2&&ce.includes("null"))&&j(ne,"use allowUnionTypes to allow union type keyword")}function D(ne,ce){const de=ne.self.RULES.all;for(const me in de){const Te=de[me];if(typeof Te=="object"&&(0,r.shouldUseRule)(ne.schema,Te)){const{type:Ae}=Te.definition;Ae.length&&!Ae.some(Be=>L(ce,Be))&&j(ne,`missing type "${Ae.join(",")}" for keyword "${me}"`)}}}function L(ne,ce){return ne.includes(ce)||ce==="number"&&ne.includes("integer")}function H(ne,ce){return ne.includes(ce)||ce==="integer"&&ne.includes("number")}function N(ne,ce){const de=[];for(const me of ne.dataTypes)H(ce,me)?de.push(me):ce.includes("integer")&&me==="number"&&de.push("integer");ne.dataTypes=de}function j(ne,ce){const de=ne.schemaEnv.baseId+ne.errSchemaPath;ce+=` at "${de}" (strictTypes)`,(0,c.checkStrictMode)(ne,ce,ne.opts.strictTypes)}class Z{constructor(ce,de,me){if((0,a.validateKeywordUsage)(ce,de,me),this.gen=ce.gen,this.allErrors=ce.allErrors,this.keyword=me,this.data=ce.data,this.schema=ce.schema[me],this.$data=de.$data&&ce.opts.$data&&this.schema&&this.schema.$data,this.schemaValue=(0,c.schemaRefOrVal)(ce,this.schema,me,this.$data),this.schemaType=de.schemaType,this.parentSchema=ce.schema,this.params={},this.it=ce,this.def=de,this.$data)this.schemaCode=ce.gen.const("vSchema",Ie(this.$data,ce));else if(this.schemaCode=this.schemaValue,!(0,a.validSchemaType)(this.schema,de.schemaType,de.allowUndefined))throw new Error(`${me} value must be ${JSON.stringify(de.schemaType)}`);("code"in de?de.trackErrors:de.errors!==!1)&&(this.errsCount=ce.gen.const("_errs",u.default.errors))}result(ce,de,me){this.failResult((0,o.not)(ce),de,me)}failResult(ce,de,me){this.gen.if(ce),me?me():this.error(),de?(this.gen.else(),de(),this.allErrors&&this.gen.endIf()):this.allErrors?this.gen.endIf():this.gen.else()}pass(ce,de){this.failResult((0,o.not)(ce),void 0,de)}fail(ce){if(ce===void 0){this.error(),this.allErrors||this.gen.if(!1);return}this.gen.if(ce),this.error(),this.allErrors?this.gen.endIf():this.gen.else()}fail$data(ce){if(!this.$data)return this.fail(ce);const{schemaCode:de}=this;this.fail((0,o._)`${de} !== undefined && (${(0,o.or)(this.invalid$data(),ce)})`)}error(ce,de,me){if(de){this.setParams(de),this._error(ce,me),this.setParams({});return}this._error(ce,me)}_error(ce,de){(ce?d.reportExtraError:d.reportError)(this,this.def.error,de)}$dataError(){(0,d.reportError)(this,this.def.$dataError||d.keyword$DataError)}reset(){if(this.errsCount===void 0)throw new Error('add "trackErrors" to keyword definition');(0,d.resetErrorsCount)(this.gen,this.errsCount)}ok(ce){this.allErrors||this.gen.if(ce)}setParams(ce,de){de?Object.assign(this.params,ce):this.params=ce}block$data(ce,de,me=o.nil){this.gen.block(()=>{this.check$data(ce,me),de()})}check$data(ce=o.nil,de=o.nil){if(!this.$data)return;const{gen:me,schemaCode:Te,schemaType:Ae,def:Be}=this;me.if((0,o.or)((0,o._)`${Te} === undefined`,de)),ce!==o.nil&&me.assign(ce,!0),(Ae.length||Be.validateSchema)&&(me.elseIf(this.invalid$data()),this.$dataError(),ce!==o.nil&&me.assign(ce,!1)),me.else()}invalid$data(){const{gen:ce,schemaCode:de,schemaType:me,def:Te,it:Ae}=this;return(0,o.or)(Be(),We());function Be(){if(me.length){if(!(de instanceof o.Name))throw new Error("ajv implementation error");const et=Array.isArray(me)?me:[me];return(0,o._)`${(0,n.checkDataTypes)(et,de,Ae.opts.strictNumbers,n.DataType.Wrong)}`}return o.nil}function We(){if(Te.validateSchema){const et=ce.scopeValue("validate$data",{ref:Te.validateSchema});return(0,o._)`!${et}(${de})`}return o.nil}}subschema(ce,de){const me=(0,s.getSubschema)(this.it,ce);(0,s.extendSubschemaData)(me,this.it,ce),(0,s.extendSubschemaMode)(me,ce);const Te={...this.it,...me,items:void 0,props:void 0};return v(Te,de),Te}mergeEvaluated(ce,de){const{it:me,gen:Te}=this;me.opts.unevaluated&&(me.props!==!0&&ce.props!==void 0&&(me.props=c.mergeEvaluated.props(Te,ce.props,me.props,de)),me.items!==!0&&ce.items!==void 0&&(me.items=c.mergeEvaluated.items(Te,ce.items,me.items,de)))}mergeValidEvaluated(ce,de){const{it:me,gen:Te}=this;if(me.opts.unevaluated&&(me.props!==!0||me.items!==!0))return Te.if(de,()=>this.mergeEvaluated(ce,o.Name)),!0}}mn.KeywordCxt=Z;function Ee(ne,ce,de,me){const Te=new Z(ne,de,ce);"code"in de?de.code(Te,me):Te.$data&&de.validate?(0,a.funcKeywordCode)(Te,de):"macro"in de?(0,a.macroKeywordCode)(Te,de):(de.compile||de.validate)&&(0,a.funcKeywordCode)(Te,de)}const _e=/^\/(?:[^~]|~0|~1)*$/,Se=/^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;function Ie(ne,{dataLevel:ce,dataNames:de,dataPathArr:me}){let Te,Ae;if(ne==="")return u.default.rootData;if(ne[0]==="/"){if(!_e.test(ne))throw new Error(`Invalid JSON-pointer: ${ne}`);Te=ne,Ae=u.default.rootData}else{const Je=Se.exec(ne);if(!Je)throw new Error(`Invalid JSON-pointer: ${ne}`);const st=+Je[1];if(Te=Je[2],Te==="#"){if(st>=ce)throw new Error(et("property/index",st));return me[ce-st]}if(st>ce)throw new Error(et("data",st));if(Ae=de[ce-st],!Te)return Ae}let Be=Ae;const We=Te.split("/");for(const Je of We)Je&&(Ae=(0,o._)`${Ae}${(0,o.getProperty)((0,c.unescapeJsonPointer)(Je))}`,Be=(0,o._)`${Be} && ${Ae}`);return Be;function et(Je,st){return`Cannot access ${Je} ${st} levels up, current level is ${ce}`}}return mn.getData=Ie,mn}var Cu={},fv;function kg(){if(fv)return Cu;fv=1,Object.defineProperty(Cu,"__esModule",{value:!0});class e extends Error{constructor(r){super("validation failed"),this.errors=r,this.ajv=this.validation=!0}}return Cu.default=e,Cu}var Du={},pv;function ml(){if(pv)return Du;pv=1,Object.defineProperty(Du,"__esModule",{value:!0});const e=pl();class t extends Error{constructor(n,i,a,s){super(s||`can't resolve reference ${a} from id ${i}`),this.missingRef=(0,e.resolveUrl)(n,i,a),this.missingSchema=(0,e.normalizeId)((0,e.getFullPath)(n,this.missingRef))}}return Du.default=t,Du}var vr={},mv;function Bg(){if(mv)return vr;mv=1,Object.defineProperty(vr,"__esModule",{value:!0}),vr.resolveSchema=vr.getCompilingSchema=vr.resolveRef=vr.compileSchema=vr.SchemaEnv=void 0;const e=Ke(),t=kg(),r=On(),n=pl(),i=lt(),a=wo();class s{constructor(O){var f;this.refs={},this.dynamicAnchors={};let v;typeof O.schema=="object"&&(v=O.schema),this.schema=O.schema,this.schemaId=O.schemaId,this.root=O.root||this,this.baseId=(f=O.baseId)!==null&&f!==void 0?f:(0,n.normalizeId)(v==null?void 0:v[O.schemaId||"$id"]),this.schemaPath=O.schemaPath,this.localRefs=O.localRefs,this.meta=O.meta,this.$async=v==null?void 0:v.$async,this.refs={}}}vr.SchemaEnv=s;function o(R){const O=c.call(this,R);if(O)return O;const f=(0,n.getFullPath)(this.opts.uriResolver,R.root.baseId),{es5:v,lines:b}=this.opts.code,{ownProperties:h}=this.opts,T=new e.CodeGen(this.scope,{es5:v,lines:b,ownProperties:h});let w;R.$async&&(w=T.scopeValue("Error",{ref:t.default,code:(0,e._)`require("ajv/dist/runtime/validation_error").default`}));const P=T.scopeName("validate");R.validateName=P;const B={gen:T,allErrors:this.opts.allErrors,data:r.default.data,parentData:r.default.parentData,parentDataProperty:r.default.parentDataProperty,dataNames:[r.default.data],dataPathArr:[e.nil],dataLevel:0,dataTypes:[],definedProperties:new Set,topSchemaRef:T.scopeValue("schema",this.opts.code.source===!0?{ref:R.schema,code:(0,e.stringify)(R.schema)}:{ref:R.schema}),validateName:P,ValidationError:w,schema:R.schema,schemaEnv:R,rootId:f,baseId:R.baseId||f,schemaPath:e.nil,errSchemaPath:R.schemaPath||(this.opts.jtd?"":"#"),errorPath:(0,e._)`""`,opts:this.opts,self:this};let J;try{this._compilations.add(R),(0,a.validateFunctionCode)(B),T.optimize(this.opts.code.optimize);const K=T.toString();J=`${T.scopeRefs(r.default.scope)}return ${K}`,this.opts.code.process&&(J=this.opts.code.process(J,R));const U=new Function(`${r.default.self}`,`${r.default.scope}`,J)(this,this.scope.get());if(this.scope.value(P,{ref:U}),U.errors=null,U.schema=R.schema,U.schemaEnv=R,R.$async&&(U.$async=!0),this.opts.code.source===!0&&(U.source={validateName:P,validateCode:K,scopeValues:T._values}),this.opts.unevaluated){const{props:F,items:ue}=B;U.evaluated={props:F instanceof e.Name?void 0:F,items:ue instanceof e.Name?void 0:ue,dynamicProps:F instanceof e.Name,dynamicItems:ue instanceof e.Name},U.source&&(U.source.evaluated=(0,e.stringify)(U.evaluated))}return R.validate=U,R}catch(K){throw delete R.validate,delete R.validateName,J&&this.logger.error("Error compiling schema, function code:",J),K}finally{this._compilations.delete(R)}}vr.compileSchema=o;function u(R,O,f){var v;f=(0,n.resolveUrl)(this.opts.uriResolver,O,f);const b=R.refs[f];if(b)return b;let h=m.call(this,R,f);if(h===void 0){const T=(v=R.localRefs)===null||v===void 0?void 0:v[f],{schemaId:w}=this.opts;T&&(h=new s({schema:T,schemaId:w,root:R,baseId:O}))}if(h!==void 0)return R.refs[f]=l.call(this,h)}vr.resolveRef=u;function l(R){return(0,n.inlineRef)(R.schema,this.opts.inlineRefs)?R.schema:R.validate?R:o.call(this,R)}function c(R){for(const O of this._compilations)if(d(O,R))return O}vr.getCompilingSchema=c;function d(R,O){return R.schema===O.schema&&R.root===O.root&&R.baseId===O.baseId}function m(R,O){let f;for(;typeof(f=this.refs[O])=="string";)O=f;return f||this.schemas[O]||p.call(this,R,O)}function p(R,O){const f=this.opts.uriResolver.parse(O),v=(0,n._getFullPath)(this.opts.uriResolver,f);let b=(0,n.getFullPath)(this.opts.uriResolver,R.baseId,void 0);if(Object.keys(R.schema).length>0&&v===b)return A.call(this,f,R);const h=(0,n.normalizeId)(v),T=this.refs[h]||this.schemas[h];if(typeof T=="string"){const w=p.call(this,R,T);return typeof(w==null?void 0:w.schema)!="object"?void 0:A.call(this,f,w)}if(typeof(T==null?void 0:T.schema)=="object"){if(T.validate||o.call(this,T),h===(0,n.normalizeId)(O)){const{schema:w}=T,{schemaId:P}=this.opts,B=w[P];return B&&(b=(0,n.resolveUrl)(this.opts.uriResolver,b,B)),new s({schema:w,schemaId:P,root:R,baseId:b})}return A.call(this,f,T)}}vr.resolveSchema=p;const E=new Set(["properties","patternProperties","enum","dependencies","definitions"]);function A(R,{baseId:O,schema:f,root:v}){var b;if(((b=R.fragment)===null||b===void 0?void 0:b[0])!=="/")return;for(const w of R.fragment.slice(1).split("/")){if(typeof f=="boolean")return;const P=f[(0,i.unescapeFragment)(w)];if(P===void 0)return;f=P;const B=typeof f=="object"&&f[this.opts.schemaId];!E.has(w)&&B&&(O=(0,n.resolveUrl)(this.opts.uriResolver,O,B))}let h;if(typeof f!="boolean"&&f.$ref&&!(0,i.schemaHasRulesButRef)(f,this.RULES)){const w=(0,n.resolveUrl)(this.opts.uriResolver,O,f.$ref);h=p.call(this,v,w)}const{schemaId:T}=this.opts;if(h=h||new s({schema:f,schemaId:T,root:v,baseId:O}),h.schema!==h.root.schema)return h}return vr}const ek="https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#",tk="Meta-schema for $data reference (JSON AnySchema extension proposal)",rk="object",nk=["$data"],ik={$data:{type:"string",anyOf:[{format:"relative-json-pointer"},{format:"json-pointer"}]}},ak=!1,sk={$id:ek,description:tk,type:rk,required:nk,properties:ik,additionalProperties:ak};var ju={},us={exports:{}},sd,hv;function cN(){if(hv)return sd;hv=1;const e=RegExp.prototype.test.bind(/^[\da-f]{8}-[\da-f]{4}-[\da-f]{4}-[\da-f]{4}-[\da-f]{12}$/iu),t=RegExp.prototype.test.bind(/^(?:(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)\.){3}(?:25[0-5]|2[0-4]\d|1\d{2}|[1-9]\d|\d)$/u),r=RegExp.prototype.test.bind(/^[\da-f]{2}$/iu),n=RegExp.prototype.test.bind(/^[\da-z\-._~]$/iu),i=RegExp.prototype.test.bind(/^[\da-z\-._~!$&'()*+,;=:@/]$/iu);function a(h){let T="",w=0,P=0;for(P=0;P<h.length;P++)if(w=h[P].charCodeAt(0),w!==48){if(!(w>=48&&w<=57||w>=65&&w<=70||w>=97&&w<=102))return"";T+=h[P];break}for(P+=1;P<h.length;P++){if(w=h[P].charCodeAt(0),!(w>=48&&w<=57||w>=65&&w<=70||w>=97&&w<=102))return"";T+=h[P]}return T}const s=RegExp.prototype.test.bind(/[^!"$&'()*+,\-.;=_`a-z{}~]/u);function o(h){return h.length=0,!0}function u(h,T,w){if(h.length){const P=a(h);if(P!=="")T.push(P);else return w.error=!0,!1;h.length=0}return!0}function l(h){let T=0;const w={error:!1,address:"",zone:""},P=[],B=[];let J=!1,K=!1,z=u;for(let U=0;U<h.length;U++){const F=h[U];if(!(F==="["||F==="]"))if(F===":"){if(J===!0&&(K=!0),!z(B,P,w))break;if(++T>7){w.error=!0;break}U>0&&h[U-1]===":"&&(J=!0),P.push(":");continue}else if(F==="%"){if(!z(B,P,w))break;z=o}else{B.push(F);continue}}return B.length&&(z===o?w.zone=B.join(""):K?P.push(B.join("")):P.push(a(B))),w.address=P.join(""),w}function c(h){if(d(h,":")<2)return{host:h,isIPV6:!1};const T=l(h);if(T.error)return{host:h,isIPV6:!1};{let w=T.address,P=T.address;return T.zone&&(w+="%"+T.zone,P+="%25"+T.zone),{host:w,isIPV6:!0,escapedHost:P}}}function d(h,T){let w=0;for(let P=0;P<h.length;P++)h[P]===T&&w++;return w}function m(h){let T=h;const w=[];let P=-1,B=0;for(;B=T.length;){if(B===1){if(T===".")break;if(T==="/"){w.push("/");break}else{w.push(T);break}}else if(B===2){if(T[0]==="."){if(T[1]===".")break;if(T[1]==="/"){T=T.slice(2);continue}}else if(T[0]==="/"&&(T[1]==="."||T[1]==="/")){w.push("/");break}}else if(B===3&&T==="/.."){w.length!==0&&w.pop(),w.push("/");break}if(T[0]==="."){if(T[1]==="."){if(T[2]==="/"){T=T.slice(3);continue}}else if(T[1]==="/"){T=T.slice(2);continue}}else if(T[0]==="/"&&T[1]==="."){if(T[2]==="/"){T=T.slice(2);continue}else if(T[2]==="."&&T[3]==="/"){T=T.slice(3),w.length!==0&&w.pop();continue}}if((P=T.indexOf("/",1))===-1){w.push(T);break}else w.push(T.slice(0,P)),T=T.slice(P)}return w.join("")}const p={"@":"%40","/":"%2F","?":"%3F","#":"%23",":":"%3A"},E=/[@/?#:]/g,A=/[@/?#]/g;function R(h,T){const w=T?A:E;return w.lastIndex=0,h.replace(w,P=>p[P])}function O(h,T=!1){if(h.indexOf("%")===-1)return h;let w="";for(let P=0;P<h.length;P++){if(h[P]==="%"&&P+2<h.length){const B=h.slice(P+1,P+3);if(r(B)){const J=B.toUpperCase(),K=String.fromCharCode(parseInt(J,16));T&&n(K)?w+=K:w+="%"+J,P+=2;continue}}w+=h[P]}return w}function f(h){let T="";for(let w=0;w<h.length;w++){if(h[w]==="%"&&w+2<h.length){const P=h.slice(w+1,w+3);if(r(P)){const B=P.toUpperCase(),J=String.fromCharCode(parseInt(B,16));J!=="."&&n(J)?T+=J:T+="%"+B,w+=2;continue}}i(h[w])?T+=h[w]:T+=escape(h[w])}return T}function v(h){let T="";for(let w=0;w<h.length;w++){if(h[w]==="%"&&w+2<h.length){const P=h.slice(w+1,w+3);if(r(P)){T+="%"+P.toUpperCase(),w+=2;continue}}T+=escape(h[w])}return T}function b(h){const T=[];if(h.userinfo!==void 0&&(T.push(h.userinfo),T.push("@")),h.host!==void 0){let w=unescape(h.host);if(!t(w)){const P=c(w);P.isIPV6===!0?w=`[${P.escapedHost}]`:w=R(w,!1)}T.push(w)}return(typeof h.port=="number"||typeof h.port=="string")&&(T.push(":"),T.push(String(h.port))),T.length?T.join(""):void 0}return sd={nonSimpleDomain:s,recomposeAuthority:b,reescapeHostDelimiters:R,normalizePercentEncoding:O,normalizePathEncoding:f,escapePreservingEscapes:v,removeDotSegments:m,isIPv4:t,isUUID:e,normalizeIPv6:c,stringArrayToHexStripped:a},sd}var od,yv;function ok(){if(yv)return od;yv=1;const{isUUID:e}=cN(),t=/([\da-z][\d\-a-z]{0,31}):((?:[\w!$'()*+,\-.:;=@]|%[\da-f]{2})+)/iu,r=["http","https","ws","wss","urn","urn:uuid"];function n(h){return r.indexOf(h)!==-1}function i(h){return h.secure===!0?!0:h.secure===!1?!1:h.scheme?h.scheme.length===3&&(h.scheme[0]==="w"||h.scheme[0]==="W")&&(h.scheme[1]==="s"||h.scheme[1]==="S")&&(h.scheme[2]==="s"||h.scheme[2]==="S"):!1}function a(h){return h.host||(h.error=h.error||"HTTP URIs must have a host."),h}function s(h){const T=String(h.scheme).toLowerCase()==="https";return(h.port===(T?443:80)||h.port==="")&&(h.port=void 0),h.path||(h.path="/"),h}function o(h){return h.secure=i(h),h.resourceName=(h.path||"/")+(h.query?"?"+h.query:""),h.path=void 0,h.query=void 0,h}function u(h){if((h.port===(i(h)?443:80)||h.port==="")&&(h.port=void 0),typeof h.secure=="boolean"&&(h.scheme=h.secure?"wss":"ws",h.secure=void 0),h.resourceName){const[T,w]=h.resourceName.split("?");h.path=T&&T!=="/"?T:void 0,h.query=w,h.resourceName=void 0}return h.fragment=void 0,h}function l(h,T){if(!h.path)return h.error="URN can not be parsed",h;const w=h.path.match(t);if(w){const P=T.scheme||h.scheme||"urn";h.nid=w[1].toLowerCase(),h.nss=w[2];const B=`${P}:${T.nid||h.nid}`,J=b(B);h.path=void 0,J&&(h=J.parse(h,T))}else h.error=h.error||"URN can not be parsed.";return h}function c(h,T){if(h.nid===void 0)throw new Error("URN without nid cannot be serialized");const w=T.scheme||h.scheme||"urn",P=h.nid.toLowerCase(),B=`${w}:${T.nid||P}`,J=b(B);J&&(h=J.serialize(h,T));const K=h,z=h.nss;return K.path=`${P||T.nid}:${z}`,T.skipEscape=!0,K}function d(h,T){const w=h;return w.uuid=w.nss,w.nss=void 0,!T.tolerant&&(!w.uuid||!e(w.uuid))&&(w.error=w.error||"UUID is not valid."),w}function m(h){const T=h;return T.nss=(h.uuid||"").toLowerCase(),T}const p={scheme:"http",domainHost:!0,parse:a,serialize:s},E={scheme:"https",domainHost:p.domainHost,parse:a,serialize:s},A={scheme:"ws",domainHost:!0,parse:o,serialize:u},R={scheme:"wss",domainHost:A.domainHost,parse:A.parse,serialize:A.serialize},v={http:p,https:E,ws:A,wss:R,urn:{scheme:"urn",parse:l,serialize:c,skipNormalize:!0},"urn:uuid":{scheme:"urn:uuid",parse:d,serialize:m,skipNormalize:!0}};Object.setPrototypeOf(v,null);function b(h){return h&&(v[h]||v[h.toLowerCase()])||void 0}return od={wsIsSecure:i,SCHEMES:v,isValidSchemeName:n,getSchemeHandler:b},od}var gv;function uk(){if(gv)return us.exports;gv=1;const{normalizeIPv6:e,removeDotSegments:t,recomposeAuthority:r,normalizePercentEncoding:n,normalizePathEncoding:i,escapePreservingEscapes:a,reescapeHostDelimiters:s,isIPv4:o,nonSimpleDomain:u}=cN(),{SCHEMES:l,getSchemeHandler:c}=ok();function d(P,B){return typeof P=="string"?P=b(P,B):typeof P=="object"&&(P=v(A(P,B),B)),P}function m(P,B,J){const K=J?Object.assign({scheme:"null"},J):{scheme:"null"},z=p(v(P,K),v(B,K),K,!0);return K.skipEscape=!0,A(z,K)}function p(P,B,J,K){const z={};return K||(P=v(A(P,J),J),B=v(A(B,J),J)),J=J||{},!J.tolerant&&B.scheme?(z.scheme=B.scheme,z.userinfo=B.userinfo,z.host=B.host,z.port=B.port,z.path=t(B.path||""),z.query=B.query):(B.userinfo!==void 0||B.host!==void 0||B.port!==void 0?(z.userinfo=B.userinfo,z.host=B.host,z.port=B.port,z.path=t(B.path||""),z.query=B.query):(B.path?(B.path[0]==="/"?z.path=t(B.path):((P.userinfo!==void 0||P.host!==void 0||P.port!==void 0)&&!P.path?z.path="/"+B.path:P.path?z.path=P.path.slice(0,P.path.lastIndexOf("/")+1)+B.path:z.path=B.path,z.path=t(z.path)),z.query=B.query):(z.path=P.path,B.query!==void 0?z.query=B.query:z.query=P.query),z.userinfo=P.userinfo,z.host=P.host,z.port=P.port),z.scheme=P.scheme),z.fragment=B.fragment,z}function E(P,B,J){const K=T(P,J),z=T(B,J);return K!==void 0&&z!==void 0&&K.toLowerCase()===z.toLowerCase()}function A(P,B){const J={host:P.host,scheme:P.scheme,userinfo:P.userinfo,port:P.port,path:P.path,query:P.query,nid:P.nid,nss:P.nss,uuid:P.uuid,fragment:P.fragment,reference:P.reference,resourceName:P.resourceName,secure:P.secure,error:""},K=Object.assign({},B),z=[],U=c(K.scheme||J.scheme);U&&U.serialize&&U.serialize(J,K),J.path!==void 0&&(K.skipEscape?J.path=n(J.path):(J.path=a(J.path),J.scheme!==void 0&&(J.path=J.path.split("%3A").join(":")))),K.reference!=="suffix"&&J.scheme&&z.push(J.scheme,":");const F=r(J);if(F!==void 0&&(K.reference!=="suffix"&&z.push("//"),z.push(F),J.path&&J.path[0]!=="/"&&z.push("/")),J.path!==void 0){let ue=J.path;!K.absolutePath&&(!U||!U.absolutePath)&&(ue=t(ue)),F===void 0&&ue[0]==="/"&&ue[1]==="/"&&(ue="/%2F"+ue.slice(2)),z.push(ue)}return J.query!==void 0&&z.push("?",J.query),J.fragment!==void 0&&z.push("#",J.fragment),z.join("")}const R=/^(?:([^#/:?]+):)?(?:\/\/((?:([^#/?@]*)@)?(\[[^#/?\]]+\]|[^#/:?]*)(?::(\d*))?))?([^#?]*)(?:\?([^#]*))?(?:#((?:.|[\n\r])*))?/u;function O(P,B){if(B[2]!==void 0&&P.path&&P.path[0]!=="/")return'URI path must start with "/" when authority is present.';if(typeof P.port=="number"&&(P.port<0||P.port>65535))return"URI port is malformed."}function f(P,B){const J=Object.assign({},B),K={scheme:void 0,userinfo:void 0,host:"",port:void 0,path:"",query:void 0,fragment:void 0};let z=!1,U=!1;J.reference==="suffix"&&(J.scheme?P=J.scheme+":"+P:P="//"+P);const F=P.match(R);if(F){K.scheme=F[1],K.userinfo=F[3],K.host=F[4],K.port=parseInt(F[5],10),K.path=F[6]||"",K.query=F[7],K.fragment=F[8],isNaN(K.port)&&(K.port=F[5]);const ue=O(K,F);if(ue!==void 0&&(K.error=K.error||ue,z=!0),K.host)if(o(K.host)===!1){const X=e(K.host);K.host=X.host.toLowerCase(),U=X.isIPV6}else U=!0;K.scheme===void 0&&K.userinfo===void 0&&K.host===void 0&&K.port===void 0&&K.query===void 0&&!K.path?K.reference="same-document":K.scheme===void 0?K.reference="relative":K.fragment===void 0?K.reference="absolute":K.reference="uri",J.reference&&J.reference!=="suffix"&&J.reference!==K.reference&&(K.error=K.error||"URI is not a "+J.reference+" reference.");const ae=c(J.scheme||K.scheme);if(!J.unicodeSupport&&(!ae||!ae.unicodeSupport)&&K.host&&(J.domainHost||ae&&ae.domainHost)&&U===!1&&u(K.host))try{K.host=new URL("http://"+K.host).hostname}catch(re){K.error=K.error||"Host's domain name can not be converted to ASCII: "+re}if((!ae||ae&&!ae.skipNormalize)&&(P.indexOf("%")!==-1&&(K.scheme!==void 0&&(K.scheme=unescape(K.scheme)),K.host!==void 0&&(K.host=s(unescape(K.host),U))),K.path&&(K.path=i(K.path)),K.fragment))try{K.fragment=encodeURI(decodeURIComponent(K.fragment))}catch{K.error=K.error||"URI malformed"}ae&&ae.parse&&ae.parse(K,J)}else K.error=K.error||"URI can not be parsed.";return{parsed:K,malformedAuthorityOrPort:z}}function v(P,B){return f(P,B).parsed}function b(P,B){return h(P,B).normalized}function h(P,B){const{parsed:J,malformedAuthorityOrPort:K}=f(P,B);return{normalized:K?P:A(J,B),malformedAuthorityOrPort:K}}function T(P,B){if(typeof P=="string"){const{normalized:J,malformedAuthorityOrPort:K}=h(P,B);return K?void 0:J}if(typeof P=="object")return A(P,B)}const w={SCHEMES:l,normalize:d,resolve:m,resolveComponent:p,equal:E,serialize:A,parse:v};return us.exports=w,us.exports.default=w,us.exports.fastUri=w,us.exports}var _v;function ck(){if(_v)return ju;_v=1,Object.defineProperty(ju,"__esModule",{value:!0});const e=uk();return e.code='require("ajv/dist/runtime/uri").default',ju.default=e,ju}var Ev;function lk(){return Ev||(Ev=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CodeGen=e.Name=e.nil=e.stringify=e.str=e._=e.KeywordCxt=void 0;var t=wo();Object.defineProperty(e,"KeywordCxt",{enumerable:!0,get:function(){return t.KeywordCxt}});var r=Ke();Object.defineProperty(e,"_",{enumerable:!0,get:function(){return r._}}),Object.defineProperty(e,"str",{enumerable:!0,get:function(){return r.str}}),Object.defineProperty(e,"stringify",{enumerable:!0,get:function(){return r.stringify}}),Object.defineProperty(e,"nil",{enumerable:!0,get:function(){return r.nil}}),Object.defineProperty(e,"Name",{enumerable:!0,get:function(){return r.Name}}),Object.defineProperty(e,"CodeGen",{enumerable:!0,get:function(){return r.CodeGen}});const n=kg(),i=ml(),a=oN(),s=Bg(),o=Ke(),u=pl(),l=xc(),c=lt(),d=sk,m=ck(),p=($,D)=>new RegExp($,D);p.code="new RegExp";const E=["removeAdditional","useDefaults","coerceTypes"],A=new Set(["validate","serialize","parse","wrapper","root","schema","keyword","pattern","formats","validate$data","func","obj","Error"]),R={errorDataPath:"",format:"`validateFormats: false` can be used instead.",nullable:'"nullable" keyword is supported by default.',jsonPointers:"Deprecated jsPropertySyntax can be used instead.",extendRefs:"Deprecated ignoreKeywordsWithRef can be used instead.",missingRefs:"Pass empty schema with $id that should be ignored to ajv.addSchema.",processCode:"Use option `code: {process: (code, schemaEnv: object) => string}`",sourceCode:"Use option `code: {source: true}`",strictDefaults:"It is default now, see option `strict`.",strictKeywords:"It is default now, see option `strict`.",uniqueItems:'"uniqueItems" keyword is always validated.',unknownFormats:"Disable strict mode or pass `true` to `ajv.addFormat` (or `formats` option).",cache:"Map is used as cache, schema object as key.",serialize:"Map is used as cache, schema object as key.",ajvErrors:"It is default now."},O={ignoreKeywordsWithRef:"",jsPropertySyntax:"",unicode:'"minLength"/"maxLength" account for unicode characters by default.'},f=200;function v($){var D,L,H,N,j,Z,Ee,_e,Se,Ie,ne,ce,de,me,Te,Ae,Be,We,et,Je,st,Mt,gt,Ut,_t;const Qt=$.strict,Zt=(D=$.code)===null||D===void 0?void 0:D.optimize,ft=Zt===!0||Zt===void 0?1:Zt||0,_r=(H=(L=$.code)===null||L===void 0?void 0:L.regExp)!==null&&H!==void 0?H:p,C=(N=$.uriResolver)!==null&&N!==void 0?N:m.default;return{strictSchema:(Z=(j=$.strictSchema)!==null&&j!==void 0?j:Qt)!==null&&Z!==void 0?Z:!0,strictNumbers:(_e=(Ee=$.strictNumbers)!==null&&Ee!==void 0?Ee:Qt)!==null&&_e!==void 0?_e:!0,strictTypes:(Ie=(Se=$.strictTypes)!==null&&Se!==void 0?Se:Qt)!==null&&Ie!==void 0?Ie:"log",strictTuples:(ce=(ne=$.strictTuples)!==null&&ne!==void 0?ne:Qt)!==null&&ce!==void 0?ce:"log",strictRequired:(me=(de=$.strictRequired)!==null&&de!==void 0?de:Qt)!==null&&me!==void 0?me:!1,code:$.code?{...$.code,optimize:ft,regExp:_r}:{optimize:ft,regExp:_r},loopRequired:(Te=$.loopRequired)!==null&&Te!==void 0?Te:f,loopEnum:(Ae=$.loopEnum)!==null&&Ae!==void 0?Ae:f,meta:(Be=$.meta)!==null&&Be!==void 0?Be:!0,messages:(We=$.messages)!==null&&We!==void 0?We:!0,inlineRefs:(et=$.inlineRefs)!==null&&et!==void 0?et:!0,schemaId:(Je=$.schemaId)!==null&&Je!==void 0?Je:"$id",addUsedSchema:(st=$.addUsedSchema)!==null&&st!==void 0?st:!0,validateSchema:(Mt=$.validateSchema)!==null&&Mt!==void 0?Mt:!0,validateFormats:(gt=$.validateFormats)!==null&>!==void 0?gt:!0,unicodeRegExp:(Ut=$.unicodeRegExp)!==null&&Ut!==void 0?Ut:!0,int32range:(_t=$.int32range)!==null&&_t!==void 0?_t:!0,uriResolver:C}}class b{constructor(D={}){this.schemas={},this.refs={},this.formats=Object.create(null),this._compilations=new Set,this._loading={},this._cache=new Map,D=this.opts={...D,...v(D)};const{es5:L,lines:H}=this.opts.code;this.scope=new o.ValueScope({scope:{},prefixes:A,es5:L,lines:H}),this.logger=z(D.logger);const N=D.validateFormats;D.validateFormats=!1,this.RULES=(0,a.getRules)(),h.call(this,R,D,"NOT SUPPORTED"),h.call(this,O,D,"DEPRECATED","warn"),this._metaOpts=J.call(this),D.formats&&P.call(this),this._addVocabularies(),this._addDefaultMetaSchema(),D.keywords&&B.call(this,D.keywords),typeof D.meta=="object"&&this.addMetaSchema(D.meta),w.call(this),D.validateFormats=N}_addVocabularies(){this.addKeyword("$async")}_addDefaultMetaSchema(){const{$data:D,meta:L,schemaId:H}=this.opts;let N=d;H==="id"&&(N={...d},N.id=N.$id,delete N.$id),L&&D&&this.addMetaSchema(N,N[H],!1)}defaultMeta(){const{meta:D,schemaId:L}=this.opts;return this.opts.defaultMeta=typeof D=="object"?D[L]||D:void 0}validate(D,L){let H;if(typeof D=="string"){if(H=this.getSchema(D),!H)throw new Error(`no schema with key or ref "${D}"`)}else H=this.compile(D);const N=H(L);return"$async"in H||(this.errors=H.errors),N}compile(D,L){const H=this._addSchema(D,L);return H.validate||this._compileSchemaEnv(H)}compileAsync(D,L){if(typeof this.opts.loadSchema!="function")throw new Error("options.loadSchema should be a function");const{loadSchema:H}=this.opts;return N.call(this,D,L);async function N(Ie,ne){await j.call(this,Ie.$schema);const ce=this._addSchema(Ie,ne);return ce.validate||Z.call(this,ce)}async function j(Ie){Ie&&!this.getSchema(Ie)&&await N.call(this,{$ref:Ie},!0)}async function Z(Ie){try{return this._compileSchemaEnv(Ie)}catch(ne){if(!(ne instanceof i.default))throw ne;return Ee.call(this,ne),await _e.call(this,ne.missingSchema),Z.call(this,Ie)}}function Ee({missingSchema:Ie,missingRef:ne}){if(this.refs[Ie])throw new Error(`AnySchema ${Ie} is loaded but ${ne} cannot be resolved`)}async function _e(Ie){const ne=await Se.call(this,Ie);this.refs[Ie]||await j.call(this,ne.$schema),this.refs[Ie]||this.addSchema(ne,Ie,L)}async function Se(Ie){const ne=this._loading[Ie];if(ne)return ne;try{return await(this._loading[Ie]=H(Ie))}finally{delete this._loading[Ie]}}}addSchema(D,L,H,N=this.opts.validateSchema){if(Array.isArray(D)){for(const Z of D)this.addSchema(Z,void 0,H,N);return this}let j;if(typeof D=="object"){const{schemaId:Z}=this.opts;if(j=D[Z],j!==void 0&&typeof j!="string")throw new Error(`schema ${Z} must be string`)}return L=(0,u.normalizeId)(L||j),this._checkUnique(L),this.schemas[L]=this._addSchema(D,H,L,N,!0),this}addMetaSchema(D,L,H=this.opts.validateSchema){return this.addSchema(D,L,!0,H),this}validateSchema(D,L){if(typeof D=="boolean")return!0;let H;if(H=D.$schema,H!==void 0&&typeof H!="string")throw new Error("$schema must be a string");if(H=H||this.opts.defaultMeta||this.defaultMeta(),!H)return this.logger.warn("meta-schema not available"),this.errors=null,!0;const N=this.validate(H,D);if(!N&&L){const j="schema is invalid: "+this.errorsText();if(this.opts.validateSchema==="log")this.logger.error(j);else throw new Error(j)}return N}getSchema(D){let L;for(;typeof(L=T.call(this,D))=="string";)D=L;if(L===void 0){const{schemaId:H}=this.opts,N=new s.SchemaEnv({schema:{},schemaId:H});if(L=s.resolveSchema.call(this,N,D),!L)return;this.refs[D]=L}return L.validate||this._compileSchemaEnv(L)}removeSchema(D){if(D instanceof RegExp)return this._removeAllSchemas(this.schemas,D),this._removeAllSchemas(this.refs,D),this;switch(typeof D){case"undefined":return this._removeAllSchemas(this.schemas),this._removeAllSchemas(this.refs),this._cache.clear(),this;case"string":{const L=T.call(this,D);return typeof L=="object"&&this._cache.delete(L.schema),delete this.schemas[D],delete this.refs[D],this}case"object":{const L=D;this._cache.delete(L);let H=D[this.opts.schemaId];return H&&(H=(0,u.normalizeId)(H),delete this.schemas[H],delete this.refs[H]),this}default:throw new Error("ajv.removeSchema: invalid parameter")}}addVocabulary(D){for(const L of D)this.addKeyword(L);return this}addKeyword(D,L){let H;if(typeof D=="string")H=D,typeof L=="object"&&(this.logger.warn("these parameters are deprecated, see docs for addKeyword"),L.keyword=H);else if(typeof D=="object"&&L===void 0){if(L=D,H=L.keyword,Array.isArray(H)&&!H.length)throw new Error("addKeywords: keyword must be string or non-empty array")}else throw new Error("invalid addKeywords parameters");if(F.call(this,H,L),!L)return(0,c.eachItem)(H,j=>ue.call(this,j)),this;re.call(this,L);const N={...L,type:(0,l.getJSONTypes)(L.type),schemaType:(0,l.getJSONTypes)(L.schemaType)};return(0,c.eachItem)(H,N.type.length===0?j=>ue.call(this,j,N):j=>N.type.forEach(Z=>ue.call(this,j,N,Z))),this}getKeyword(D){const L=this.RULES.all[D];return typeof L=="object"?L.definition:!!L}removeKeyword(D){const{RULES:L}=this;delete L.keywords[D],delete L.all[D];for(const H of L.rules){const N=H.rules.findIndex(j=>j.keyword===D);N>=0&&H.rules.splice(N,1)}return this}addFormat(D,L){return typeof L=="string"&&(L=new RegExp(L)),this.formats[D]=L,this}errorsText(D=this.errors,{separator:L=", ",dataVar:H="data"}={}){return!D||D.length===0?"No errors":D.map(N=>`${H}${N.instancePath} ${N.message}`).reduce((N,j)=>N+L+j)}$dataMetaSchema(D,L){const H=this.RULES.all;D=JSON.parse(JSON.stringify(D));for(const N of L){const j=N.split("/").slice(1);let Z=D;for(const Ee of j)Z=Z[Ee];for(const Ee in H){const _e=H[Ee];if(typeof _e!="object")continue;const{$data:Se}=_e.definition,Ie=Z[Ee];Se&&Ie&&(Z[Ee]=W(Ie))}}return D}_removeAllSchemas(D,L){for(const H in D){const N=D[H];(!L||L.test(H))&&(typeof N=="string"?delete D[H]:N&&!N.meta&&(this._cache.delete(N.schema),delete D[H]))}}_addSchema(D,L,H,N=this.opts.validateSchema,j=this.opts.addUsedSchema){let Z;const{schemaId:Ee}=this.opts;if(typeof D=="object")Z=D[Ee];else{if(this.opts.jtd)throw new Error("schema must be object");if(typeof D!="boolean")throw new Error("schema must be object or boolean")}let _e=this._cache.get(D);if(_e!==void 0)return _e;H=(0,u.normalizeId)(Z||H);const Se=u.getSchemaRefs.call(this,D,H);return _e=new s.SchemaEnv({schema:D,schemaId:Ee,meta:L,baseId:H,localRefs:Se}),this._cache.set(_e.schema,_e),j&&!H.startsWith("#")&&(H&&this._checkUnique(H),this.refs[H]=_e),N&&this.validateSchema(D,!0),_e}_checkUnique(D){if(this.schemas[D]||this.refs[D])throw new Error(`schema with key or id "${D}" already exists`)}_compileSchemaEnv(D){if(D.meta?this._compileMetaSchema(D):s.compileSchema.call(this,D),!D.validate)throw new Error("ajv implementation error");return D.validate}_compileMetaSchema(D){const L=this.opts;this.opts=this._metaOpts;try{s.compileSchema.call(this,D)}finally{this.opts=L}}}b.ValidationError=n.default,b.MissingRefError=i.default,e.default=b;function h($,D,L,H="error"){for(const N in $){const j=N;j in D&&this.logger[H](`${L}: option ${N}. ${$[j]}`)}}function T($){return $=(0,u.normalizeId)($),this.schemas[$]||this.refs[$]}function w(){const $=this.opts.schemas;if($)if(Array.isArray($))this.addSchema($);else for(const D in $)this.addSchema($[D],D)}function P(){for(const $ in this.opts.formats){const D=this.opts.formats[$];D&&this.addFormat($,D)}}function B($){if(Array.isArray($)){this.addVocabulary($);return}this.logger.warn("keywords option as map is deprecated, pass array");for(const D in $){const L=$[D];L.keyword||(L.keyword=D),this.addKeyword(L)}}function J(){const $={...this.opts};for(const D of E)delete $[D];return $}const K={log(){},warn(){},error(){}};function z($){if($===!1)return K;if($===void 0)return console;if($.log&&$.warn&&$.error)return $;throw new Error("logger must implement log, warn and error methods")}const U=/^[a-z_$][a-z0-9_$:-]*$/i;function F($,D){const{RULES:L}=this;if((0,c.eachItem)($,H=>{if(L.keywords[H])throw new Error(`Keyword ${H} is already defined`);if(!U.test(H))throw new Error(`Keyword ${H} has invalid name`)}),!!D&&D.$data&&!("code"in D||"validate"in D))throw new Error('$data keyword must have "code" or "validate" function')}function ue($,D,L){var H;const N=D==null?void 0:D.post;if(L&&N)throw new Error('keyword with "post" flag cannot have "type"');const{RULES:j}=this;let Z=N?j.post:j.rules.find(({type:_e})=>_e===L);if(Z||(Z={type:L,rules:[]},j.rules.push(Z)),j.keywords[$]=!0,!D)return;const Ee={keyword:$,definition:{...D,type:(0,l.getJSONTypes)(D.type),schemaType:(0,l.getJSONTypes)(D.schemaType)}};D.before?ae.call(this,Z,Ee,D.before):Z.rules.push(Ee),j.all[$]=Ee,(H=D.implements)===null||H===void 0||H.forEach(_e=>this.addKeyword(_e))}function ae($,D,L){const H=$.rules.findIndex(N=>N.keyword===L);H>=0?$.rules.splice(H,0,D):($.rules.push(D),this.logger.warn(`rule ${L} is not defined`))}function re($){let{metaSchema:D}=$;D!==void 0&&($.$data&&this.opts.$data&&(D=W(D)),$.validateSchema=this.compile(D,!0))}const X={$ref:"https://raw.githubusercontent.com/ajv-validator/ajv/master/lib/refs/data.json#"};function W($){return{anyOf:[$,X]}}})(xl)),xl}var $u={},Lu={},qu={},vv;function dk(){if(vv)return qu;vv=1,Object.defineProperty(qu,"__esModule",{value:!0});const e={keyword:"id",code(){throw new Error('NOT SUPPORTED: keyword "id", use "$id" for schema ID')}};return qu.default=e,qu}var jn={},bv;function fk(){if(bv)return jn;bv=1,Object.defineProperty(jn,"__esModule",{value:!0}),jn.callRef=jn.getValidate=void 0;const e=ml(),t=Ur(),r=Ke(),n=On(),i=Bg(),a=lt(),s={keyword:"$ref",schemaType:"string",code(l){const{gen:c,schema:d,it:m}=l,{baseId:p,schemaEnv:E,validateName:A,opts:R,self:O}=m,{root:f}=E;if((d==="#"||d==="#/")&&p===f.baseId)return b();const v=i.resolveRef.call(O,f,p,d);if(v===void 0)throw new e.default(m.opts.uriResolver,p,d);if(v instanceof i.SchemaEnv)return h(v);return T(v);function b(){if(E===f)return u(l,A,E,E.$async);const w=c.scopeValue("root",{ref:f});return u(l,(0,r._)`${w}.validate`,f,f.$async)}function h(w){const P=o(l,w);u(l,P,w,w.$async)}function T(w){const P=c.scopeValue("schema",R.code.source===!0?{ref:w,code:(0,r.stringify)(w)}:{ref:w}),B=c.name("valid"),J=l.subschema({schema:w,dataTypes:[],schemaPath:r.nil,topSchemaRef:P,errSchemaPath:d},B);l.mergeEvaluated(J),l.ok(B)}}};function o(l,c){const{gen:d}=l;return c.validate?d.scopeValue("validate",{ref:c.validate}):(0,r._)`${d.scopeValue("wrapper",{ref:c})}.validate`}jn.getValidate=o;function u(l,c,d,m){const{gen:p,it:E}=l,{allErrors:A,schemaEnv:R,opts:O}=E,f=O.passContext?n.default.this:r.nil;m?v():b();function v(){if(!R.$async)throw new Error("async schema referenced by sync schema");const w=p.let("valid");p.try(()=>{p.code((0,r._)`await ${(0,t.callValidateCode)(l,c,f)}`),T(c),A||p.assign(w,!0)},P=>{p.if((0,r._)`!(${P} instanceof ${E.ValidationError})`,()=>p.throw(P)),h(P),A||p.assign(w,!1)}),l.ok(w)}function b(){l.result((0,t.callValidateCode)(l,c,f),()=>T(c),()=>h(c))}function h(w){const P=(0,r._)`${w}.errors`;p.assign(n.default.vErrors,(0,r._)`${n.default.vErrors} === null ? ${P} : ${n.default.vErrors}.concat(${P})`),p.assign(n.default.errors,(0,r._)`${n.default.vErrors}.length`)}function T(w){var P;if(!E.opts.unevaluated)return;const B=(P=d==null?void 0:d.validate)===null||P===void 0?void 0:P.evaluated;if(E.props!==!0)if(B&&!B.dynamicProps)B.props!==void 0&&(E.props=a.mergeEvaluated.props(p,B.props,E.props));else{const J=p.var("props",(0,r._)`${w}.evaluated.props`);E.props=a.mergeEvaluated.props(p,J,E.props,r.Name)}if(E.items!==!0)if(B&&!B.dynamicItems)B.items!==void 0&&(E.items=a.mergeEvaluated.items(p,B.items,E.items));else{const J=p.var("items",(0,r._)`${w}.evaluated.items`);E.items=a.mergeEvaluated.items(p,J,E.items,r.Name)}}}return jn.callRef=u,jn.default=s,jn}var Tv;function pk(){if(Tv)return Lu;Tv=1,Object.defineProperty(Lu,"__esModule",{value:!0});const e=dk(),t=fk(),r=["$schema","$id","$defs","$vocabulary",{keyword:"$comment"},"definitions",e.default,t.default];return Lu.default=r,Lu}var ku={},Bu={},Sv;function mk(){if(Sv)return Bu;Sv=1,Object.defineProperty(Bu,"__esModule",{value:!0});const e=Ke(),t=e.operators,r={maximum:{okStr:"<=",ok:t.LTE,fail:t.GT},minimum:{okStr:">=",ok:t.GTE,fail:t.LT},exclusiveMaximum:{okStr:"<",ok:t.LT,fail:t.GTE},exclusiveMinimum:{okStr:">",ok:t.GT,fail:t.LTE}},n={message:({keyword:a,schemaCode:s})=>(0,e.str)`must be ${r[a].okStr} ${s}`,params:({keyword:a,schemaCode:s})=>(0,e._)`{comparison: ${r[a].okStr}, limit: ${s}}`},i={keyword:Object.keys(r),type:"number",schemaType:"number",$data:!0,error:n,code(a){const{keyword:s,data:o,schemaCode:u}=a;a.fail$data((0,e._)`${o} ${r[s].fail} ${u} || isNaN(${o})`)}};return Bu.default=i,Bu}var Uu={},Iv;function hk(){if(Iv)return Uu;Iv=1,Object.defineProperty(Uu,"__esModule",{value:!0});const e=Ke(),r={keyword:"multipleOf",type:"number",schemaType:"number",$data:!0,error:{message:({schemaCode:n})=>(0,e.str)`must be multiple of ${n}`,params:({schemaCode:n})=>(0,e._)`{multipleOf: ${n}}`},code(n){const{gen:i,data:a,schemaCode:s,it:o}=n,u=o.opts.multipleOfPrecision,l=i.let("res"),c=u?(0,e._)`Math.abs(Math.round(${l}) - ${l}) > 1e-${u}`:(0,e._)`${l} !== parseInt(${l})`;n.fail$data((0,e._)`(${s} === 0 || (${l} = ${a}/${s}, ${c}))`)}};return Uu.default=r,Uu}var Fu={},Vu={},Rv;function yk(){if(Rv)return Vu;Rv=1,Object.defineProperty(Vu,"__esModule",{value:!0});function e(t){const r=t.length;let n=0,i=0,a;for(;i<r;)n++,a=t.charCodeAt(i++),a>=55296&&a<=56319&&i<r&&(a=t.charCodeAt(i),(a&64512)===56320&&i++);return n}return Vu.default=e,e.code='require("ajv/dist/runtime/ucs2length").default',Vu}var Av;function gk(){if(Av)return Fu;Av=1,Object.defineProperty(Fu,"__esModule",{value:!0});const e=Ke(),t=lt(),r=yk(),i={keyword:["maxLength","minLength"],type:"string",schemaType:"number",$data:!0,error:{message({keyword:a,schemaCode:s}){const o=a==="maxLength"?"more":"fewer";return(0,e.str)`must NOT have ${o} than ${s} characters`},params:({schemaCode:a})=>(0,e._)`{limit: ${a}}`},code(a){const{keyword:s,data:o,schemaCode:u,it:l}=a,c=s==="maxLength"?e.operators.GT:e.operators.LT,d=l.opts.unicode===!1?(0,e._)`${o}.length`:(0,e._)`${(0,t.useFunc)(a.gen,r.default)}(${o})`;a.fail$data((0,e._)`${d} ${c} ${u}`)}};return Fu.default=i,Fu}var Hu={},wv;function _k(){if(wv)return Hu;wv=1,Object.defineProperty(Hu,"__esModule",{value:!0});const e=Ur(),t=lt(),r=Ke(),i={keyword:"pattern",type:"string",schemaType:"string",$data:!0,error:{message:({schemaCode:a})=>(0,r.str)`must match pattern "${a}"`,params:({schemaCode:a})=>(0,r._)`{pattern: ${a}}`},code(a){const{gen:s,data:o,$data:u,schema:l,schemaCode:c,it:d}=a,m=d.opts.unicodeRegExp?"u":"";if(u){const{regExp:p}=d.opts.code,E=p.code==="new RegExp"?(0,r._)`new RegExp`:(0,t.useFunc)(s,p),A=s.let("valid");s.try(()=>s.assign(A,(0,r._)`${E}(${c}, ${m}).test(${o})`),()=>s.assign(A,!1)),a.fail$data((0,r._)`!${A}`)}else{const p=(0,e.usePattern)(a,l);a.fail$data((0,r._)`!${p}.test(${o})`)}}};return Hu.default=i,Hu}var Gu={},Ov;function Ek(){if(Ov)return Gu;Ov=1,Object.defineProperty(Gu,"__esModule",{value:!0});const e=Ke(),r={keyword:["maxProperties","minProperties"],type:"object",schemaType:"number",$data:!0,error:{message({keyword:n,schemaCode:i}){const a=n==="maxProperties"?"more":"fewer";return(0,e.str)`must NOT have ${a} than ${i} properties`},params:({schemaCode:n})=>(0,e._)`{limit: ${n}}`},code(n){const{keyword:i,data:a,schemaCode:s}=n,o=i==="maxProperties"?e.operators.GT:e.operators.LT;n.fail$data((0,e._)`Object.keys(${a}).length ${o} ${s}`)}};return Gu.default=r,Gu}var zu={},Nv;function vk(){if(Nv)return zu;Nv=1,Object.defineProperty(zu,"__esModule",{value:!0});const e=Ur(),t=Ke(),r=lt(),i={keyword:"required",type:"object",schemaType:"array",$data:!0,error:{message:({params:{missingProperty:a}})=>(0,t.str)`must have required property '${a}'`,params:({params:{missingProperty:a}})=>(0,t._)`{missingProperty: ${a}}`},code(a){const{gen:s,schema:o,schemaCode:u,data:l,$data:c,it:d}=a,{opts:m}=d;if(!c&&o.length===0)return;const p=o.length>=m.loopRequired;if(d.allErrors?E():A(),m.strictRequired){const f=a.parentSchema.properties,{definedProperties:v}=a.it;for(const b of o)if((f==null?void 0:f[b])===void 0&&!v.has(b)){const h=d.schemaEnv.baseId+d.errSchemaPath,T=`required property "${b}" is not defined at "${h}" (strictRequired)`;(0,r.checkStrictMode)(d,T,d.opts.strictRequired)}}function E(){if(p||c)a.block$data(t.nil,R);else for(const f of o)(0,e.checkReportMissingProp)(a,f)}function A(){const f=s.let("missing");if(p||c){const v=s.let("valid",!0);a.block$data(v,()=>O(f,v)),a.ok(v)}else s.if((0,e.checkMissingProp)(a,o,f)),(0,e.reportMissingProp)(a,f),s.else()}function R(){s.forOf("prop",u,f=>{a.setParams({missingProperty:f}),s.if((0,e.noPropertyInData)(s,l,f,m.ownProperties),()=>a.error())})}function O(f,v){a.setParams({missingProperty:f}),s.forOf(f,u,()=>{s.assign(v,(0,e.propertyInData)(s,l,f,m.ownProperties)),s.if((0,t.not)(v),()=>{a.error(),s.break()})},t.nil)}}};return zu.default=i,zu}var Wu={},Pv;function bk(){if(Pv)return Wu;Pv=1,Object.defineProperty(Wu,"__esModule",{value:!0});const e=Ke(),r={keyword:["maxItems","minItems"],type:"array",schemaType:"number",$data:!0,error:{message({keyword:n,schemaCode:i}){const a=n==="maxItems"?"more":"fewer";return(0,e.str)`must NOT have ${a} than ${i} items`},params:({schemaCode:n})=>(0,e._)`{limit: ${n}}`},code(n){const{keyword:i,data:a,schemaCode:s}=n,o=i==="maxItems"?e.operators.GT:e.operators.LT;n.fail$data((0,e._)`${a}.length ${o} ${s}`)}};return Wu.default=r,Wu}var Yu={},Ku={},Mv;function Ug(){if(Mv)return Ku;Mv=1,Object.defineProperty(Ku,"__esModule",{value:!0});const e=qg();return e.code='require("ajv/dist/runtime/equal").default',Ku.default=e,Ku}var Cv;function Tk(){if(Cv)return Yu;Cv=1,Object.defineProperty(Yu,"__esModule",{value:!0});const e=xc(),t=Ke(),r=lt(),n=Ug(),a={keyword:"uniqueItems",type:"array",schemaType:"boolean",$data:!0,error:{message:({params:{i:s,j:o}})=>(0,t.str)`must NOT have duplicate items (items ## ${o} and ${s} are identical)`,params:({params:{i:s,j:o}})=>(0,t._)`{i: ${s}, j: ${o}}`},code(s){const{gen:o,data:u,$data:l,schema:c,parentSchema:d,schemaCode:m,it:p}=s;if(!l&&!c)return;const E=o.let("valid"),A=d.items?(0,e.getSchemaTypes)(d.items):[];s.block$data(E,R,(0,t._)`${m} === false`),s.ok(E);function R(){const b=o.let("i",(0,t._)`${u}.length`),h=o.let("j");s.setParams({i:b,j:h}),o.assign(E,!0),o.if((0,t._)`${b} > 1`,()=>(O()?f:v)(b,h))}function O(){return A.length>0&&!A.some(b=>b==="object"||b==="array")}function f(b,h){const T=o.name("item"),w=(0,e.checkDataTypes)(A,T,p.opts.strictNumbers,e.DataType.Wrong),P=o.const("indices",(0,t._)`{}`);o.for((0,t._)`;${b}--;`,()=>{o.let(T,(0,t._)`${u}[${b}]`),o.if(w,(0,t._)`continue`),A.length>1&&o.if((0,t._)`typeof ${T} == "string"`,(0,t._)`${T} += "_"`),o.if((0,t._)`typeof ${P}[${T}] == "number"`,()=>{o.assign(h,(0,t._)`${P}[${T}]`),s.error(),o.assign(E,!1).break()}).code((0,t._)`${P}[${T}] = ${b}`)})}function v(b,h){const T=(0,r.useFunc)(o,n.default),w=o.name("outer");o.label(w).for((0,t._)`;${b}--;`,()=>o.for((0,t._)`${h} = ${b}; ${h}--;`,()=>o.if((0,t._)`${T}(${u}[${b}], ${u}[${h}])`,()=>{s.error(),o.assign(E,!1).break(w)})))}}};return Yu.default=a,Yu}var Ju={},Dv;function Sk(){if(Dv)return Ju;Dv=1,Object.defineProperty(Ju,"__esModule",{value:!0});const e=Ke(),t=lt(),r=Ug(),i={keyword:"const",$data:!0,error:{message:"must be equal to constant",params:({schemaCode:a})=>(0,e._)`{allowedValue: ${a}}`},code(a){const{gen:s,data:o,$data:u,schemaCode:l,schema:c}=a;u||c&&typeof c=="object"?a.fail$data((0,e._)`!${(0,t.useFunc)(s,r.default)}(${o}, ${l})`):a.fail((0,e._)`${c} !== ${o}`)}};return Ju.default=i,Ju}var Xu={},jv;function Ik(){if(jv)return Xu;jv=1,Object.defineProperty(Xu,"__esModule",{value:!0});const e=Ke(),t=lt(),r=Ug(),i={keyword:"enum",schemaType:"array",$data:!0,error:{message:"must be equal to one of the allowed values",params:({schemaCode:a})=>(0,e._)`{allowedValues: ${a}}`},code(a){const{gen:s,data:o,$data:u,schema:l,schemaCode:c,it:d}=a;if(!u&&l.length===0)throw new Error("enum must have non-empty array");const m=l.length>=d.opts.loopEnum;let p;const E=()=>p??(p=(0,t.useFunc)(s,r.default));let A;if(m||u)A=s.let("valid"),a.block$data(A,R);else{if(!Array.isArray(l))throw new Error("ajv implementation error");const f=s.const("vSchema",c);A=(0,e.or)(...l.map((v,b)=>O(f,b)))}a.pass(A);function R(){s.assign(A,!1),s.forOf("v",c,f=>s.if((0,e._)`${E()}(${o}, ${f})`,()=>s.assign(A,!0).break()))}function O(f,v){const b=l[v];return typeof b=="object"&&b!==null?(0,e._)`${E()}(${o}, ${f}[${v}])`:(0,e._)`${o} === ${b}`}}};return Xu.default=i,Xu}var $v;function Rk(){if($v)return ku;$v=1,Object.defineProperty(ku,"__esModule",{value:!0});const e=mk(),t=hk(),r=gk(),n=_k(),i=Ek(),a=vk(),s=bk(),o=Tk(),u=Sk(),l=Ik(),c=[e.default,t.default,r.default,n.default,i.default,a.default,s.default,o.default,{keyword:"type",schemaType:["string","array"]},{keyword:"nullable",schemaType:"boolean"},u.default,l.default];return ku.default=c,ku}var Qu={},pa={},Lv;function lN(){if(Lv)return pa;Lv=1,Object.defineProperty(pa,"__esModule",{value:!0}),pa.validateAdditionalItems=void 0;const e=Ke(),t=lt(),n={keyword:"additionalItems",type:"array",schemaType:["boolean","object"],before:"uniqueItems",error:{message:({params:{len:a}})=>(0,e.str)`must NOT have more than ${a} items`,params:({params:{len:a}})=>(0,e._)`{limit: ${a}}`},code(a){const{parentSchema:s,it:o}=a,{items:u}=s;if(!Array.isArray(u)){(0,t.checkStrictMode)(o,'"additionalItems" is ignored when "items" is not an array of schemas');return}i(a,u)}};function i(a,s){const{gen:o,schema:u,data:l,keyword:c,it:d}=a;d.items=!0;const m=o.const("len",(0,e._)`${l}.length`);if(u===!1)a.setParams({len:s.length}),a.pass((0,e._)`${m} <= ${s.length}`);else if(typeof u=="object"&&!(0,t.alwaysValidSchema)(d,u)){const E=o.var("valid",(0,e._)`${m} <= ${s.length}`);o.if((0,e.not)(E),()=>p(E)),a.ok(E)}function p(E){o.forRange("i",s.length,m,A=>{a.subschema({keyword:c,dataProp:A,dataPropType:t.Type.Num},E),d.allErrors||o.if((0,e.not)(E),()=>o.break())})}}return pa.validateAdditionalItems=i,pa.default=n,pa}var Zu={},ma={},qv;function dN(){if(qv)return ma;qv=1,Object.defineProperty(ma,"__esModule",{value:!0}),ma.validateTuple=void 0;const e=Ke(),t=lt(),r=Ur(),n={keyword:"items",type:"array",schemaType:["object","array","boolean"],before:"uniqueItems",code(a){const{schema:s,it:o}=a;if(Array.isArray(s))return i(a,"additionalItems",s);o.items=!0,!(0,t.alwaysValidSchema)(o,s)&&a.ok((0,r.validateArray)(a))}};function i(a,s,o=a.schema){const{gen:u,parentSchema:l,data:c,keyword:d,it:m}=a;A(l),m.opts.unevaluated&&o.length&&m.items!==!0&&(m.items=t.mergeEvaluated.items(u,o.length,m.items));const p=u.name("valid"),E=u.const("len",(0,e._)`${c}.length`);o.forEach((R,O)=>{(0,t.alwaysValidSchema)(m,R)||(u.if((0,e._)`${E} > ${O}`,()=>a.subschema({keyword:d,schemaProp:O,dataProp:O},p)),a.ok(p))});function A(R){const{opts:O,errSchemaPath:f}=m,v=o.length,b=v===R.minItems&&(v===R.maxItems||R[s]===!1);if(O.strictTuples&&!b){const h=`"${d}" is ${v}-tuple, but minItems or maxItems/${s} are not specified or different at path "${f}"`;(0,t.checkStrictMode)(m,h,O.strictTuples)}}}return ma.validateTuple=i,ma.default=n,ma}var kv;function Ak(){if(kv)return Zu;kv=1,Object.defineProperty(Zu,"__esModule",{value:!0});const e=dN(),t={keyword:"prefixItems",type:"array",schemaType:["array"],before:"uniqueItems",code:r=>(0,e.validateTuple)(r,"items")};return Zu.default=t,Zu}var xu={},Bv;function wk(){if(Bv)return xu;Bv=1,Object.defineProperty(xu,"__esModule",{value:!0});const e=Ke(),t=lt(),r=Ur(),n=lN(),a={keyword:"items",type:"array",schemaType:["object","boolean"],before:"uniqueItems",error:{message:({params:{len:s}})=>(0,e.str)`must NOT have more than ${s} items`,params:({params:{len:s}})=>(0,e._)`{limit: ${s}}`},code(s){const{schema:o,parentSchema:u,it:l}=s,{prefixItems:c}=u;l.items=!0,!(0,t.alwaysValidSchema)(l,o)&&(c?(0,n.validateAdditionalItems)(s,c):s.ok((0,r.validateArray)(s)))}};return xu.default=a,xu}var ec={},Uv;function Ok(){if(Uv)return ec;Uv=1,Object.defineProperty(ec,"__esModule",{value:!0});const e=Ke(),t=lt(),n={keyword:"contains",type:"array",schemaType:["object","boolean"],before:"uniqueItems",trackErrors:!0,error:{message:({params:{min:i,max:a}})=>a===void 0?(0,e.str)`must contain at least ${i} valid item(s)`:(0,e.str)`must contain at least ${i} and no more than ${a} valid item(s)`,params:({params:{min:i,max:a}})=>a===void 0?(0,e._)`{minContains: ${i}}`:(0,e._)`{minContains: ${i}, maxContains: ${a}}`},code(i){const{gen:a,schema:s,parentSchema:o,data:u,it:l}=i;let c,d;const{minContains:m,maxContains:p}=o;l.opts.next?(c=m===void 0?1:m,d=p):c=1;const E=a.const("len",(0,e._)`${u}.length`);if(i.setParams({min:c,max:d}),d===void 0&&c===0){(0,t.checkStrictMode)(l,'"minContains" == 0 without "maxContains": "contains" keyword ignored');return}if(d!==void 0&&c>d){(0,t.checkStrictMode)(l,'"minContains" > "maxContains" is always invalid'),i.fail();return}if((0,t.alwaysValidSchema)(l,s)){let v=(0,e._)`${E} >= ${c}`;d!==void 0&&(v=(0,e._)`${v} && ${E} <= ${d}`),i.pass(v);return}l.items=!0;const A=a.name("valid");d===void 0&&c===1?O(A,()=>a.if(A,()=>a.break())):c===0?(a.let(A,!0),d!==void 0&&a.if((0,e._)`${u}.length > 0`,R)):(a.let(A,!1),R()),i.result(A,()=>i.reset());function R(){const v=a.name("_valid"),b=a.let("count",0);O(v,()=>a.if(v,()=>f(b)))}function O(v,b){a.forRange("i",0,E,h=>{i.subschema({keyword:"contains",dataProp:h,dataPropType:t.Type.Num,compositeRule:!0},v),b()})}function f(v){a.code((0,e._)`${v}++`),d===void 0?a.if((0,e._)`${v} >= ${c}`,()=>a.assign(A,!0).break()):(a.if((0,e._)`${v} > ${d}`,()=>a.assign(A,!1).break()),c===1?a.assign(A,!0):a.if((0,e._)`${v} >= ${c}`,()=>a.assign(A,!0)))}}};return ec.default=n,ec}var ud={},Fv;function Nk(){return Fv||(Fv=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.validateSchemaDeps=e.validatePropertyDeps=e.error=void 0;const t=Ke(),r=lt(),n=Ur();e.error={message:({params:{property:u,depsCount:l,deps:c}})=>{const d=l===1?"property":"properties";return(0,t.str)`must have ${d} ${c} when property ${u} is present`},params:({params:{property:u,depsCount:l,deps:c,missingProperty:d}})=>(0,t._)`{property: ${u},
|
|
55
|
+
missingProperty: ${d},
|
|
56
|
+
depsCount: ${l},
|
|
57
|
+
deps: ${c}}`};const i={keyword:"dependencies",type:"object",schemaType:"object",error:e.error,code(u){const[l,c]=a(u);s(u,l),o(u,c)}};function a({schema:u}){const l={},c={};for(const d in u){if(d==="__proto__")continue;const m=Array.isArray(u[d])?l:c;m[d]=u[d]}return[l,c]}function s(u,l=u.schema){const{gen:c,data:d,it:m}=u;if(Object.keys(l).length===0)return;const p=c.let("missing");for(const E in l){const A=l[E];if(A.length===0)continue;const R=(0,n.propertyInData)(c,d,E,m.opts.ownProperties);u.setParams({property:E,depsCount:A.length,deps:A.join(", ")}),m.allErrors?c.if(R,()=>{for(const O of A)(0,n.checkReportMissingProp)(u,O)}):(c.if((0,t._)`${R} && (${(0,n.checkMissingProp)(u,A,p)})`),(0,n.reportMissingProp)(u,p),c.else())}}e.validatePropertyDeps=s;function o(u,l=u.schema){const{gen:c,data:d,keyword:m,it:p}=u,E=c.name("valid");for(const A in l)(0,r.alwaysValidSchema)(p,l[A])||(c.if((0,n.propertyInData)(c,d,A,p.opts.ownProperties),()=>{const R=u.subschema({keyword:m,schemaProp:A},E);u.mergeValidEvaluated(R,E)},()=>c.var(E,!0)),u.ok(E))}e.validateSchemaDeps=o,e.default=i})(ud)),ud}var tc={},Vv;function Pk(){if(Vv)return tc;Vv=1,Object.defineProperty(tc,"__esModule",{value:!0});const e=Ke(),t=lt(),n={keyword:"propertyNames",type:"object",schemaType:["object","boolean"],error:{message:"property name must be valid",params:({params:i})=>(0,e._)`{propertyName: ${i.propertyName}}`},code(i){const{gen:a,schema:s,data:o,it:u}=i;if((0,t.alwaysValidSchema)(u,s))return;const l=a.name("valid");a.forIn("key",o,c=>{i.setParams({propertyName:c}),i.subschema({keyword:"propertyNames",data:c,dataTypes:["string"],propertyName:c,compositeRule:!0},l),a.if((0,e.not)(l),()=>{i.error(!0),u.allErrors||a.break()})}),i.ok(l)}};return tc.default=n,tc}var rc={},Hv;function fN(){if(Hv)return rc;Hv=1,Object.defineProperty(rc,"__esModule",{value:!0});const e=Ur(),t=Ke(),r=On(),n=lt(),a={keyword:"additionalProperties",type:["object"],schemaType:["boolean","object"],allowUndefined:!0,trackErrors:!0,error:{message:"must NOT have additional properties",params:({params:s})=>(0,t._)`{additionalProperty: ${s.additionalProperty}}`},code(s){const{gen:o,schema:u,parentSchema:l,data:c,errsCount:d,it:m}=s;if(!d)throw new Error("ajv implementation error");const{allErrors:p,opts:E}=m;if(m.props=!0,E.removeAdditional!=="all"&&(0,n.alwaysValidSchema)(m,u))return;const A=(0,e.allSchemaProperties)(l.properties),R=(0,e.allSchemaProperties)(l.patternProperties);O(),s.ok((0,t._)`${d} === ${r.default.errors}`);function O(){o.forIn("key",c,T=>{!A.length&&!R.length?b(T):o.if(f(T),()=>b(T))})}function f(T){let w;if(A.length>8){const P=(0,n.schemaRefOrVal)(m,l.properties,"properties");w=(0,e.isOwnProperty)(o,P,T)}else A.length?w=(0,t.or)(...A.map(P=>(0,t._)`${T} === ${P}`)):w=t.nil;return R.length&&(w=(0,t.or)(w,...R.map(P=>(0,t._)`${(0,e.usePattern)(s,P)}.test(${T})`))),(0,t.not)(w)}function v(T){o.code((0,t._)`delete ${c}[${T}]`)}function b(T){if(E.removeAdditional==="all"||E.removeAdditional&&u===!1){v(T);return}if(u===!1){s.setParams({additionalProperty:T}),s.error(),p||o.break();return}if(typeof u=="object"&&!(0,n.alwaysValidSchema)(m,u)){const w=o.name("valid");E.removeAdditional==="failing"?(h(T,w,!1),o.if((0,t.not)(w),()=>{s.reset(),v(T)})):(h(T,w),p||o.if((0,t.not)(w),()=>o.break()))}}function h(T,w,P){const B={keyword:"additionalProperties",dataProp:T,dataPropType:n.Type.Str};P===!1&&Object.assign(B,{compositeRule:!0,createErrors:!1,allErrors:!1}),s.subschema(B,w)}}};return rc.default=a,rc}var nc={},Gv;function Mk(){if(Gv)return nc;Gv=1,Object.defineProperty(nc,"__esModule",{value:!0});const e=wo(),t=Ur(),r=lt(),n=fN(),i={keyword:"properties",type:"object",schemaType:"object",code(a){const{gen:s,schema:o,parentSchema:u,data:l,it:c}=a;c.opts.removeAdditional==="all"&&u.additionalProperties===void 0&&n.default.code(new e.KeywordCxt(c,n.default,"additionalProperties"));const d=(0,t.allSchemaProperties)(o);for(const R of d)c.definedProperties.add(R);c.opts.unevaluated&&d.length&&c.props!==!0&&(c.props=r.mergeEvaluated.props(s,(0,r.toHash)(d),c.props));const m=d.filter(R=>!(0,r.alwaysValidSchema)(c,o[R]));if(m.length===0)return;const p=s.name("valid");for(const R of m)E(R)?A(R):(s.if((0,t.propertyInData)(s,l,R,c.opts.ownProperties)),A(R),c.allErrors||s.else().var(p,!0),s.endIf()),a.it.definedProperties.add(R),a.ok(p);function E(R){return c.opts.useDefaults&&!c.compositeRule&&o[R].default!==void 0}function A(R){a.subschema({keyword:"properties",schemaProp:R,dataProp:R},p)}}};return nc.default=i,nc}var ic={},zv;function Ck(){if(zv)return ic;zv=1,Object.defineProperty(ic,"__esModule",{value:!0});const e=Ur(),t=Ke(),r=lt(),n=lt(),i={keyword:"patternProperties",type:"object",schemaType:"object",code(a){const{gen:s,schema:o,data:u,parentSchema:l,it:c}=a,{opts:d}=c,m=(0,e.allSchemaProperties)(o),p=m.filter(b=>(0,r.alwaysValidSchema)(c,o[b]));if(m.length===0||p.length===m.length&&(!c.opts.unevaluated||c.props===!0))return;const E=d.strictSchema&&!d.allowMatchingProperties&&l.properties,A=s.name("valid");c.props!==!0&&!(c.props instanceof t.Name)&&(c.props=(0,n.evaluatedPropsToName)(s,c.props));const{props:R}=c;O();function O(){for(const b of m)E&&f(b),c.allErrors?v(b):(s.var(A,!0),v(b),s.if(A))}function f(b){for(const h in E)new RegExp(b).test(h)&&(0,r.checkStrictMode)(c,`property ${h} matches pattern ${b} (use allowMatchingProperties)`)}function v(b){s.forIn("key",u,h=>{s.if((0,t._)`${(0,e.usePattern)(a,b)}.test(${h})`,()=>{const T=p.includes(b);T||a.subschema({keyword:"patternProperties",schemaProp:b,dataProp:h,dataPropType:n.Type.Str},A),c.opts.unevaluated&&R!==!0?s.assign((0,t._)`${R}[${h}]`,!0):!T&&!c.allErrors&&s.if((0,t.not)(A),()=>s.break())})})}}};return ic.default=i,ic}var ac={},Wv;function Dk(){if(Wv)return ac;Wv=1,Object.defineProperty(ac,"__esModule",{value:!0});const e=lt(),t={keyword:"not",schemaType:["object","boolean"],trackErrors:!0,code(r){const{gen:n,schema:i,it:a}=r;if((0,e.alwaysValidSchema)(a,i)){r.fail();return}const s=n.name("valid");r.subschema({keyword:"not",compositeRule:!0,createErrors:!1,allErrors:!1},s),r.failResult(s,()=>r.reset(),()=>r.error())},error:{message:"must NOT be valid"}};return ac.default=t,ac}var sc={},Yv;function jk(){if(Yv)return sc;Yv=1,Object.defineProperty(sc,"__esModule",{value:!0});const t={keyword:"anyOf",schemaType:"array",trackErrors:!0,code:Ur().validateUnion,error:{message:"must match a schema in anyOf"}};return sc.default=t,sc}var oc={},Kv;function $k(){if(Kv)return oc;Kv=1,Object.defineProperty(oc,"__esModule",{value:!0});const e=Ke(),t=lt(),n={keyword:"oneOf",schemaType:"array",trackErrors:!0,error:{message:"must match exactly one schema in oneOf",params:({params:i})=>(0,e._)`{passingSchemas: ${i.passing}}`},code(i){const{gen:a,schema:s,parentSchema:o,it:u}=i;if(!Array.isArray(s))throw new Error("ajv implementation error");if(u.opts.discriminator&&o.discriminator)return;const l=s,c=a.let("valid",!1),d=a.let("passing",null),m=a.name("_valid");i.setParams({passing:d}),a.block(p),i.result(c,()=>i.reset(),()=>i.error(!0));function p(){l.forEach((E,A)=>{let R;(0,t.alwaysValidSchema)(u,E)?a.var(m,!0):R=i.subschema({keyword:"oneOf",schemaProp:A,compositeRule:!0},m),A>0&&a.if((0,e._)`${m} && ${c}`).assign(c,!1).assign(d,(0,e._)`[${d}, ${A}]`).else(),a.if(m,()=>{a.assign(c,!0),a.assign(d,A),R&&i.mergeEvaluated(R,e.Name)})})}}};return oc.default=n,oc}var uc={},Jv;function Lk(){if(Jv)return uc;Jv=1,Object.defineProperty(uc,"__esModule",{value:!0});const e=lt(),t={keyword:"allOf",schemaType:"array",code(r){const{gen:n,schema:i,it:a}=r;if(!Array.isArray(i))throw new Error("ajv implementation error");const s=n.name("valid");i.forEach((o,u)=>{if((0,e.alwaysValidSchema)(a,o))return;const l=r.subschema({keyword:"allOf",schemaProp:u},s);r.ok(s),r.mergeEvaluated(l)})}};return uc.default=t,uc}var cc={},Xv;function qk(){if(Xv)return cc;Xv=1,Object.defineProperty(cc,"__esModule",{value:!0});const e=Ke(),t=lt(),n={keyword:"if",schemaType:["object","boolean"],trackErrors:!0,error:{message:({params:a})=>(0,e.str)`must match "${a.ifClause}" schema`,params:({params:a})=>(0,e._)`{failingKeyword: ${a.ifClause}}`},code(a){const{gen:s,parentSchema:o,it:u}=a;o.then===void 0&&o.else===void 0&&(0,t.checkStrictMode)(u,'"if" without "then" and "else" is ignored');const l=i(u,"then"),c=i(u,"else");if(!l&&!c)return;const d=s.let("valid",!0),m=s.name("_valid");if(p(),a.reset(),l&&c){const A=s.let("ifClause");a.setParams({ifClause:A}),s.if(m,E("then",A),E("else",A))}else l?s.if(m,E("then")):s.if((0,e.not)(m),E("else"));a.pass(d,()=>a.error(!0));function p(){const A=a.subschema({keyword:"if",compositeRule:!0,createErrors:!1,allErrors:!1},m);a.mergeEvaluated(A)}function E(A,R){return()=>{const O=a.subschema({keyword:A},m);s.assign(d,m),a.mergeValidEvaluated(O,d),R?s.assign(R,(0,e._)`${A}`):a.setParams({ifClause:A})}}}};function i(a,s){const o=a.schema[s];return o!==void 0&&!(0,t.alwaysValidSchema)(a,o)}return cc.default=n,cc}var lc={},Qv;function kk(){if(Qv)return lc;Qv=1,Object.defineProperty(lc,"__esModule",{value:!0});const e=lt(),t={keyword:["then","else"],schemaType:["object","boolean"],code({keyword:r,parentSchema:n,it:i}){n.if===void 0&&(0,e.checkStrictMode)(i,`"${r}" without "if" is ignored`)}};return lc.default=t,lc}var Zv;function Bk(){if(Zv)return Qu;Zv=1,Object.defineProperty(Qu,"__esModule",{value:!0});const e=lN(),t=Ak(),r=dN(),n=wk(),i=Ok(),a=Nk(),s=Pk(),o=fN(),u=Mk(),l=Ck(),c=Dk(),d=jk(),m=$k(),p=Lk(),E=qk(),A=kk();function R(O=!1){const f=[c.default,d.default,m.default,p.default,E.default,A.default,s.default,o.default,a.default,u.default,l.default];return O?f.push(t.default,n.default):f.push(e.default,r.default),f.push(i.default),f}return Qu.default=R,Qu}var dc={},fc={},xv;function Uk(){if(xv)return fc;xv=1,Object.defineProperty(fc,"__esModule",{value:!0});const e=Ke(),r={keyword:"format",type:["number","string"],schemaType:"string",$data:!0,error:{message:({schemaCode:n})=>(0,e.str)`must match format "${n}"`,params:({schemaCode:n})=>(0,e._)`{format: ${n}}`},code(n,i){const{gen:a,data:s,$data:o,schema:u,schemaCode:l,it:c}=n,{opts:d,errSchemaPath:m,schemaEnv:p,self:E}=c;if(!d.validateFormats)return;o?A():R();function A(){const O=a.scopeValue("formats",{ref:E.formats,code:d.code.formats}),f=a.const("fDef",(0,e._)`${O}[${l}]`),v=a.let("fType"),b=a.let("format");a.if((0,e._)`typeof ${f} == "object" && !(${f} instanceof RegExp)`,()=>a.assign(v,(0,e._)`${f}.type || "string"`).assign(b,(0,e._)`${f}.validate`),()=>a.assign(v,(0,e._)`"string"`).assign(b,f)),n.fail$data((0,e.or)(h(),T()));function h(){return d.strictSchema===!1?e.nil:(0,e._)`${l} && !${b}`}function T(){const w=p.$async?(0,e._)`(${f}.async ? await ${b}(${s}) : ${b}(${s}))`:(0,e._)`${b}(${s})`,P=(0,e._)`(typeof ${b} == "function" ? ${w} : ${b}.test(${s}))`;return(0,e._)`${b} && ${b} !== true && ${v} === ${i} && !${P}`}}function R(){const O=E.formats[u];if(!O){h();return}if(O===!0)return;const[f,v,b]=T(O);f===i&&n.pass(w());function h(){if(d.strictSchema===!1){E.logger.warn(P());return}throw new Error(P());function P(){return`unknown format "${u}" ignored in schema at path "${m}"`}}function T(P){const B=P instanceof RegExp?(0,e.regexpCode)(P):d.code.formats?(0,e._)`${d.code.formats}${(0,e.getProperty)(u)}`:void 0,J=a.scopeValue("formats",{key:u,ref:P,code:B});return typeof P=="object"&&!(P instanceof RegExp)?[P.type||"string",P.validate,(0,e._)`${J}.validate`]:["string",P,J]}function w(){if(typeof O=="object"&&!(O instanceof RegExp)&&O.async){if(!p.$async)throw new Error("async format in sync schema");return(0,e._)`await ${b}(${s})`}return typeof v=="function"?(0,e._)`${b}(${s})`:(0,e._)`${b}.test(${s})`}}}};return fc.default=r,fc}var eb;function Fk(){if(eb)return dc;eb=1,Object.defineProperty(dc,"__esModule",{value:!0});const t=[Uk().default];return dc.default=t,dc}var xn={},tb;function Vk(){return tb||(tb=1,Object.defineProperty(xn,"__esModule",{value:!0}),xn.contentVocabulary=xn.metadataVocabulary=void 0,xn.metadataVocabulary=["title","description","default","deprecated","readOnly","writeOnly","examples"],xn.contentVocabulary=["contentMediaType","contentEncoding","contentSchema"]),xn}var rb;function Hk(){if(rb)return $u;rb=1,Object.defineProperty($u,"__esModule",{value:!0});const e=pk(),t=Rk(),r=Bk(),n=Fk(),i=Vk(),a=[e.default,t.default,(0,r.default)(),n.default,i.metadataVocabulary,i.contentVocabulary];return $u.default=a,$u}var pc={},cs={},nb;function Gk(){if(nb)return cs;nb=1,Object.defineProperty(cs,"__esModule",{value:!0}),cs.DiscrError=void 0;var e;return(function(t){t.Tag="tag",t.Mapping="mapping"})(e||(cs.DiscrError=e={})),cs}var ib;function zk(){if(ib)return pc;ib=1,Object.defineProperty(pc,"__esModule",{value:!0});const e=Ke(),t=Gk(),r=Bg(),n=ml(),i=lt(),s={keyword:"discriminator",type:"object",schemaType:"object",error:{message:({params:{discrError:o,tagName:u}})=>o===t.DiscrError.Tag?`tag "${u}" must be string`:`value of tag "${u}" must be in oneOf`,params:({params:{discrError:o,tag:u,tagName:l}})=>(0,e._)`{error: ${o}, tag: ${l}, tagValue: ${u}}`},code(o){const{gen:u,data:l,schema:c,parentSchema:d,it:m}=o,{oneOf:p}=d;if(!m.opts.discriminator)throw new Error("discriminator: requires discriminator option");const E=c.propertyName;if(typeof E!="string")throw new Error("discriminator: requires propertyName");if(c.mapping)throw new Error("discriminator: mapping is not supported");if(!p)throw new Error("discriminator: requires oneOf keyword");const A=u.let("valid",!1),R=u.const("tag",(0,e._)`${l}${(0,e.getProperty)(E)}`);u.if((0,e._)`typeof ${R} == "string"`,()=>O(),()=>o.error(!1,{discrError:t.DiscrError.Tag,tag:R,tagName:E})),o.ok(A);function O(){const b=v();u.if(!1);for(const h in b)u.elseIf((0,e._)`${R} === ${h}`),u.assign(A,f(b[h]));u.else(),o.error(!1,{discrError:t.DiscrError.Mapping,tag:R,tagName:E}),u.endIf()}function f(b){const h=u.name("valid"),T=o.subschema({keyword:"oneOf",schemaProp:b},h);return o.mergeEvaluated(T,e.Name),h}function v(){var b;const h={},T=P(d);let w=!0;for(let K=0;K<p.length;K++){let z=p[K];if(z!=null&&z.$ref&&!(0,i.schemaHasRulesButRef)(z,m.self.RULES)){const F=z.$ref;if(z=r.resolveRef.call(m.self,m.schemaEnv.root,m.baseId,F),z instanceof r.SchemaEnv&&(z=z.schema),z===void 0)throw new n.default(m.opts.uriResolver,m.baseId,F)}const U=(b=z==null?void 0:z.properties)===null||b===void 0?void 0:b[E];if(typeof U!="object")throw new Error(`discriminator: oneOf subschemas (or referenced schemas) must have "properties/${E}"`);w=w&&(T||P(z)),B(U,K)}if(!w)throw new Error(`discriminator: "${E}" must be required`);return h;function P({required:K}){return Array.isArray(K)&&K.includes(E)}function B(K,z){if(K.const)J(K.const,z);else if(K.enum)for(const U of K.enum)J(U,z);else throw new Error(`discriminator: "properties/${E}" must have "const" or "enum"`)}function J(K,z){if(typeof K!="string"||K in h)throw new Error(`discriminator: "${E}" values must be unique strings`);h[K]=z}}}};return pc.default=s,pc}const Wk="http://json-schema.org/draft-07/schema#",Yk="http://json-schema.org/draft-07/schema#",Kk="Core schema meta-schema",Jk={schemaArray:{type:"array",minItems:1,items:{$ref:"#"}},nonNegativeInteger:{type:"integer",minimum:0},nonNegativeIntegerDefault0:{allOf:[{$ref:"#/definitions/nonNegativeInteger"},{default:0}]},simpleTypes:{enum:["array","boolean","integer","null","number","object","string"]},stringArray:{type:"array",items:{type:"string"},uniqueItems:!0,default:[]}},Xk=["object","boolean"],Qk={$id:{type:"string",format:"uri-reference"},$schema:{type:"string",format:"uri"},$ref:{type:"string",format:"uri-reference"},$comment:{type:"string"},title:{type:"string"},description:{type:"string"},default:!0,readOnly:{type:"boolean",default:!1},examples:{type:"array",items:!0},multipleOf:{type:"number",exclusiveMinimum:0},maximum:{type:"number"},exclusiveMaximum:{type:"number"},minimum:{type:"number"},exclusiveMinimum:{type:"number"},maxLength:{$ref:"#/definitions/nonNegativeInteger"},minLength:{$ref:"#/definitions/nonNegativeIntegerDefault0"},pattern:{type:"string",format:"regex"},additionalItems:{$ref:"#"},items:{anyOf:[{$ref:"#"},{$ref:"#/definitions/schemaArray"}],default:!0},maxItems:{$ref:"#/definitions/nonNegativeInteger"},minItems:{$ref:"#/definitions/nonNegativeIntegerDefault0"},uniqueItems:{type:"boolean",default:!1},contains:{$ref:"#"},maxProperties:{$ref:"#/definitions/nonNegativeInteger"},minProperties:{$ref:"#/definitions/nonNegativeIntegerDefault0"},required:{$ref:"#/definitions/stringArray"},additionalProperties:{$ref:"#"},definitions:{type:"object",additionalProperties:{$ref:"#"},default:{}},properties:{type:"object",additionalProperties:{$ref:"#"},default:{}},patternProperties:{type:"object",additionalProperties:{$ref:"#"},propertyNames:{format:"regex"},default:{}},dependencies:{type:"object",additionalProperties:{anyOf:[{$ref:"#"},{$ref:"#/definitions/stringArray"}]}},propertyNames:{$ref:"#"},const:!0,enum:{type:"array",items:!0,minItems:1,uniqueItems:!0},type:{anyOf:[{$ref:"#/definitions/simpleTypes"},{type:"array",items:{$ref:"#/definitions/simpleTypes"},minItems:1,uniqueItems:!0}]},format:{type:"string"},contentMediaType:{type:"string"},contentEncoding:{type:"string"},if:{$ref:"#"},then:{$ref:"#"},else:{$ref:"#"},allOf:{$ref:"#/definitions/schemaArray"},anyOf:{$ref:"#/definitions/schemaArray"},oneOf:{$ref:"#/definitions/schemaArray"},not:{$ref:"#"}},Zk={$schema:Wk,$id:Yk,title:Kk,definitions:Jk,type:Xk,properties:Qk,default:!0};var ab;function Fg(){return ab||(ab=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.MissingRefError=t.ValidationError=t.CodeGen=t.Name=t.nil=t.stringify=t.str=t._=t.KeywordCxt=t.Ajv=void 0;const r=lk(),n=Hk(),i=zk(),a=Zk,s=["/properties"],o="http://json-schema.org/draft-07/schema";class u extends r.default{_addVocabularies(){super._addVocabularies(),n.default.forEach(E=>this.addVocabulary(E)),this.opts.discriminator&&this.addKeyword(i.default)}_addDefaultMetaSchema(){if(super._addDefaultMetaSchema(),!this.opts.meta)return;const E=this.opts.$data?this.$dataMetaSchema(a,s):a;this.addMetaSchema(E,o,!1),this.refs["http://json-schema.org/schema"]=o}defaultMeta(){return this.opts.defaultMeta=super.defaultMeta()||(this.getSchema(o)?o:void 0)}}t.Ajv=u,e.exports=t=u,e.exports.Ajv=u,Object.defineProperty(t,"__esModule",{value:!0}),t.default=u;var l=wo();Object.defineProperty(t,"KeywordCxt",{enumerable:!0,get:function(){return l.KeywordCxt}});var c=Ke();Object.defineProperty(t,"_",{enumerable:!0,get:function(){return c._}}),Object.defineProperty(t,"str",{enumerable:!0,get:function(){return c.str}}),Object.defineProperty(t,"stringify",{enumerable:!0,get:function(){return c.stringify}}),Object.defineProperty(t,"nil",{enumerable:!0,get:function(){return c.nil}}),Object.defineProperty(t,"Name",{enumerable:!0,get:function(){return c.Name}}),Object.defineProperty(t,"CodeGen",{enumerable:!0,get:function(){return c.CodeGen}});var d=kg();Object.defineProperty(t,"ValidationError",{enumerable:!0,get:function(){return d.default}});var m=ml();Object.defineProperty(t,"MissingRefError",{enumerable:!0,get:function(){return m.default}})})(Pu,Pu.exports)),Pu.exports}var ws={exports:{}},Os={exports:{}},Ns={exports:{}},mc={exports:{}},sb;function xk(){return sb||(sb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=Ke(),n=["undefined","string","number","object","function","boolean","symbol"];function i(){return{keyword:"typeof",schemaType:["string","array"],code(a){const{data:s,schema:o,schemaValue:u}=a;a.fail(typeof o=="string"?(0,r._)`typeof ${s} != ${o}`:(0,r._)`${u}.indexOf(typeof ${s}) < 0`)},metaSchema:{anyOf:[{type:"string",enum:n},{type:"array",items:{type:"string",enum:n}}]}}}t.default=i,e.exports=i})(mc,mc.exports)),mc.exports}var ob=Ns.exports,ub;function eB(){return ub||(ub=1,(function(e,t){var r=ob&&ob.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(xk()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Ns,Ns.exports)),Ns.exports}var Ps={exports:{}},pN={},hl={};hl.byteLength=nB;hl.toByteArray=aB;hl.fromByteArray=uB;var sn=[],Ir=[],tB=typeof Uint8Array<"u"?Uint8Array:Array,cd="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";for(var ha=0,rB=cd.length;ha<rB;++ha)sn[ha]=cd[ha],Ir[cd.charCodeAt(ha)]=ha;Ir[45]=62;Ir[95]=63;function mN(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var r=e.indexOf("=");r===-1&&(r=t);var n=r===t?0:4-r%4;return[r,n]}function nB(e){var t=mN(e),r=t[0],n=t[1];return(r+n)*3/4-n}function iB(e,t,r){return(t+r)*3/4-r}function aB(e){var t,r=mN(e),n=r[0],i=r[1],a=new tB(iB(e,n,i)),s=0,o=i>0?n-4:n,u;for(u=0;u<o;u+=4)t=Ir[e.charCodeAt(u)]<<18|Ir[e.charCodeAt(u+1)]<<12|Ir[e.charCodeAt(u+2)]<<6|Ir[e.charCodeAt(u+3)],a[s++]=t>>16&255,a[s++]=t>>8&255,a[s++]=t&255;return i===2&&(t=Ir[e.charCodeAt(u)]<<2|Ir[e.charCodeAt(u+1)]>>4,a[s++]=t&255),i===1&&(t=Ir[e.charCodeAt(u)]<<10|Ir[e.charCodeAt(u+1)]<<4|Ir[e.charCodeAt(u+2)]>>2,a[s++]=t>>8&255,a[s++]=t&255),a}function sB(e){return sn[e>>18&63]+sn[e>>12&63]+sn[e>>6&63]+sn[e&63]}function oB(e,t,r){for(var n,i=[],a=t;a<r;a+=3)n=(e[a]<<16&16711680)+(e[a+1]<<8&65280)+(e[a+2]&255),i.push(sB(n));return i.join("")}function uB(e){for(var t,r=e.length,n=r%3,i=[],a=16383,s=0,o=r-n;s<o;s+=a)i.push(oB(e,s,s+a>o?o:s+a));return n===1?(t=e[r-1],i.push(sn[t>>2]+sn[t<<4&63]+"==")):n===2&&(t=(e[r-2]<<8)+e[r-1],i.push(sn[t>>10]+sn[t>>4&63]+sn[t<<2&63]+"=")),i.join("")}var Vg={};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */Vg.read=function(e,t,r,n,i){var a,s,o=i*8-n-1,u=(1<<o)-1,l=u>>1,c=-7,d=r?i-1:0,m=r?-1:1,p=e[t+d];for(d+=m,a=p&(1<<-c)-1,p>>=-c,c+=o;c>0;a=a*256+e[t+d],d+=m,c-=8);for(s=a&(1<<-c)-1,a>>=-c,c+=n;c>0;s=s*256+e[t+d],d+=m,c-=8);if(a===0)a=1-l;else{if(a===u)return s?NaN:(p?-1:1)*(1/0);s=s+Math.pow(2,n),a=a-l}return(p?-1:1)*s*Math.pow(2,a-n)};Vg.write=function(e,t,r,n,i,a){var s,o,u,l=a*8-i-1,c=(1<<l)-1,d=c>>1,m=i===23?Math.pow(2,-24)-Math.pow(2,-77):0,p=n?0:a-1,E=n?1:-1,A=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(o=isNaN(t)?1:0,s=c):(s=Math.floor(Math.log(t)/Math.LN2),t*(u=Math.pow(2,-s))<1&&(s--,u*=2),s+d>=1?t+=m/u:t+=m*Math.pow(2,1-d),t*u>=2&&(s++,u/=2),s+d>=c?(o=0,s=c):s+d>=1?(o=(t*u-1)*Math.pow(2,i),s=s+d):(o=t*Math.pow(2,d-1)*Math.pow(2,i),s=0));i>=8;e[r+p]=o&255,p+=E,o/=256,i-=8);for(s=s<<i|o,l+=i;l>0;e[r+p]=s&255,p+=E,s/=256,l-=8);e[r+p-E]|=A*128};/*!
|
|
58
|
+
* The buffer module from node.js, for the browser.
|
|
59
|
+
*
|
|
60
|
+
* @author Feross Aboukhadijeh <https://feross.org>
|
|
61
|
+
* @license MIT
|
|
62
|
+
*/(function(e){const t=hl,r=Vg,n=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=c,e.SlowBuffer=h,e.INSPECT_MAX_BYTES=50;const i=2147483647;e.kMaxLength=i;const{Uint8Array:a,ArrayBuffer:s,SharedArrayBuffer:o}=globalThis;c.TYPED_ARRAY_SUPPORT=u(),!c.TYPED_ARRAY_SUPPORT&&typeof console<"u"&&typeof console.error=="function"&&console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support.");function u(){try{const C=new a(1),_={foo:function(){return 42}};return Object.setPrototypeOf(_,a.prototype),Object.setPrototypeOf(C,_),C.foo()===42}catch{return!1}}Object.defineProperty(c.prototype,"parent",{enumerable:!0,get:function(){if(c.isBuffer(this))return this.buffer}}),Object.defineProperty(c.prototype,"offset",{enumerable:!0,get:function(){if(c.isBuffer(this))return this.byteOffset}});function l(C){if(C>i)throw new RangeError('The value "'+C+'" is invalid for option "size"');const _=new a(C);return Object.setPrototypeOf(_,c.prototype),_}function c(C,_,I){if(typeof C=="number"){if(typeof _=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return E(C)}return d(C,_,I)}c.poolSize=8192;function d(C,_,I){if(typeof C=="string")return A(C,_);if(s.isView(C))return O(C);if(C==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof C);if(_t(C,s)||C&&_t(C.buffer,s)||typeof o<"u"&&(_t(C,o)||C&&_t(C.buffer,o)))return f(C,_,I);if(typeof C=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const G=C.valueOf&&C.valueOf();if(G!=null&&G!==C)return c.from(G,_,I);const le=v(C);if(le)return le;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof C[Symbol.toPrimitive]=="function")return c.from(C[Symbol.toPrimitive]("string"),_,I);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof C)}c.from=function(C,_,I){return d(C,_,I)},Object.setPrototypeOf(c.prototype,a.prototype),Object.setPrototypeOf(c,a);function m(C){if(typeof C!="number")throw new TypeError('"size" argument must be of type number');if(C<0)throw new RangeError('The value "'+C+'" is invalid for option "size"')}function p(C,_,I){return m(C),C<=0?l(C):_!==void 0?typeof I=="string"?l(C).fill(_,I):l(C).fill(_):l(C)}c.alloc=function(C,_,I){return p(C,_,I)};function E(C){return m(C),l(C<0?0:b(C)|0)}c.allocUnsafe=function(C){return E(C)},c.allocUnsafeSlow=function(C){return E(C)};function A(C,_){if((typeof _!="string"||_==="")&&(_="utf8"),!c.isEncoding(_))throw new TypeError("Unknown encoding: "+_);const I=T(C,_)|0;let G=l(I);const le=G.write(C,_);return le!==I&&(G=G.slice(0,le)),G}function R(C){const _=C.length<0?0:b(C.length)|0,I=l(_);for(let G=0;G<_;G+=1)I[G]=C[G]&255;return I}function O(C){if(_t(C,a)){const _=new a(C);return f(_.buffer,_.byteOffset,_.byteLength)}return R(C)}function f(C,_,I){if(_<0||C.byteLength<_)throw new RangeError('"offset" is outside of buffer bounds');if(C.byteLength<_+(I||0))throw new RangeError('"length" is outside of buffer bounds');let G;return _===void 0&&I===void 0?G=new a(C):I===void 0?G=new a(C,_):G=new a(C,_,I),Object.setPrototypeOf(G,c.prototype),G}function v(C){if(c.isBuffer(C)){const _=b(C.length)|0,I=l(_);return I.length===0||C.copy(I,0,0,_),I}if(C.length!==void 0)return typeof C.length!="number"||Qt(C.length)?l(0):R(C);if(C.type==="Buffer"&&Array.isArray(C.data))return R(C.data)}function b(C){if(C>=i)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+i.toString(16)+" bytes");return C|0}function h(C){return+C!=C&&(C=0),c.alloc(+C)}c.isBuffer=function(_){return _!=null&&_._isBuffer===!0&&_!==c.prototype},c.compare=function(_,I){if(_t(_,a)&&(_=c.from(_,_.offset,_.byteLength)),_t(I,a)&&(I=c.from(I,I.offset,I.byteLength)),!c.isBuffer(_)||!c.isBuffer(I))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(_===I)return 0;let G=_.length,le=I.length;for(let ge=0,be=Math.min(G,le);ge<be;++ge)if(_[ge]!==I[ge]){G=_[ge],le=I[ge];break}return G<le?-1:le<G?1:0},c.isEncoding=function(_){switch(String(_).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},c.concat=function(_,I){if(!Array.isArray(_))throw new TypeError('"list" argument must be an Array of Buffers');if(_.length===0)return c.alloc(0);let G;if(I===void 0)for(I=0,G=0;G<_.length;++G)I+=_[G].length;const le=c.allocUnsafe(I);let ge=0;for(G=0;G<_.length;++G){let be=_[G];if(_t(be,a))ge+be.length>le.length?(c.isBuffer(be)||(be=c.from(be)),be.copy(le,ge)):a.prototype.set.call(le,be,ge);else if(c.isBuffer(be))be.copy(le,ge);else throw new TypeError('"list" argument must be an Array of Buffers');ge+=be.length}return le};function T(C,_){if(c.isBuffer(C))return C.length;if(s.isView(C)||_t(C,s))return C.byteLength;if(typeof C!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof C);const I=C.length,G=arguments.length>2&&arguments[2]===!0;if(!G&&I===0)return 0;let le=!1;for(;;)switch(_){case"ascii":case"latin1":case"binary":return I;case"utf8":case"utf-8":return Je(C).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return I*2;case"hex":return I>>>1;case"base64":return gt(C).length;default:if(le)return G?-1:Je(C).length;_=(""+_).toLowerCase(),le=!0}}c.byteLength=T;function w(C,_,I){let G=!1;if((_===void 0||_<0)&&(_=0),_>this.length||((I===void 0||I>this.length)&&(I=this.length),I<=0)||(I>>>=0,_>>>=0,I<=_))return"";for(C||(C="utf8");;)switch(C){case"hex":return L(this,_,I);case"utf8":case"utf-8":return re(this,_,I);case"ascii":return $(this,_,I);case"latin1":case"binary":return D(this,_,I);case"base64":return ae(this,_,I);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return H(this,_,I);default:if(G)throw new TypeError("Unknown encoding: "+C);C=(C+"").toLowerCase(),G=!0}}c.prototype._isBuffer=!0;function P(C,_,I){const G=C[_];C[_]=C[I],C[I]=G}c.prototype.swap16=function(){const _=this.length;if(_%2!==0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let I=0;I<_;I+=2)P(this,I,I+1);return this},c.prototype.swap32=function(){const _=this.length;if(_%4!==0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let I=0;I<_;I+=4)P(this,I,I+3),P(this,I+1,I+2);return this},c.prototype.swap64=function(){const _=this.length;if(_%8!==0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let I=0;I<_;I+=8)P(this,I,I+7),P(this,I+1,I+6),P(this,I+2,I+5),P(this,I+3,I+4);return this},c.prototype.toString=function(){const _=this.length;return _===0?"":arguments.length===0?re(this,0,_):w.apply(this,arguments)},c.prototype.toLocaleString=c.prototype.toString,c.prototype.equals=function(_){if(!c.isBuffer(_))throw new TypeError("Argument must be a Buffer");return this===_?!0:c.compare(this,_)===0},c.prototype.inspect=function(){let _="";const I=e.INSPECT_MAX_BYTES;return _=this.toString("hex",0,I).replace(/(.{2})/g,"$1 ").trim(),this.length>I&&(_+=" ... "),"<Buffer "+_+">"},n&&(c.prototype[n]=c.prototype.inspect),c.prototype.compare=function(_,I,G,le,ge){if(_t(_,a)&&(_=c.from(_,_.offset,_.byteLength)),!c.isBuffer(_))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof _);if(I===void 0&&(I=0),G===void 0&&(G=_?_.length:0),le===void 0&&(le=0),ge===void 0&&(ge=this.length),I<0||G>_.length||le<0||ge>this.length)throw new RangeError("out of range index");if(le>=ge&&I>=G)return 0;if(le>=ge)return-1;if(I>=G)return 1;if(I>>>=0,G>>>=0,le>>>=0,ge>>>=0,this===_)return 0;let be=ge-le,Qe=G-I;const At=Math.min(be,Qe),Et=this.slice(le,ge),wt=_.slice(I,G);for(let rt=0;rt<At;++rt)if(Et[rt]!==wt[rt]){be=Et[rt],Qe=wt[rt];break}return be<Qe?-1:Qe<be?1:0};function B(C,_,I,G,le){if(C.length===0)return-1;if(typeof I=="string"?(G=I,I=0):I>2147483647?I=2147483647:I<-2147483648&&(I=-2147483648),I=+I,Qt(I)&&(I=le?0:C.length-1),I<0&&(I=C.length+I),I>=C.length){if(le)return-1;I=C.length-1}else if(I<0)if(le)I=0;else return-1;if(typeof _=="string"&&(_=c.from(_,G)),c.isBuffer(_))return _.length===0?-1:J(C,_,I,G,le);if(typeof _=="number")return _=_&255,typeof a.prototype.indexOf=="function"?le?a.prototype.indexOf.call(C,_,I):a.prototype.lastIndexOf.call(C,_,I):J(C,[_],I,G,le);throw new TypeError("val must be string, number or Buffer")}function J(C,_,I,G,le){let ge=1,be=C.length,Qe=_.length;if(G!==void 0&&(G=String(G).toLowerCase(),G==="ucs2"||G==="ucs-2"||G==="utf16le"||G==="utf-16le")){if(C.length<2||_.length<2)return-1;ge=2,be/=2,Qe/=2,I/=2}function At(wt,rt){return ge===1?wt[rt]:wt.readUInt16BE(rt*ge)}let Et;if(le){let wt=-1;for(Et=I;Et<be;Et++)if(At(C,Et)===At(_,wt===-1?0:Et-wt)){if(wt===-1&&(wt=Et),Et-wt+1===Qe)return wt*ge}else wt!==-1&&(Et-=Et-wt),wt=-1}else for(I+Qe>be&&(I=be-Qe),Et=I;Et>=0;Et--){let wt=!0;for(let rt=0;rt<Qe;rt++)if(At(C,Et+rt)!==At(_,rt)){wt=!1;break}if(wt)return Et}return-1}c.prototype.includes=function(_,I,G){return this.indexOf(_,I,G)!==-1},c.prototype.indexOf=function(_,I,G){return B(this,_,I,G,!0)},c.prototype.lastIndexOf=function(_,I,G){return B(this,_,I,G,!1)};function K(C,_,I,G){I=Number(I)||0;const le=C.length-I;G?(G=Number(G),G>le&&(G=le)):G=le;const ge=_.length;G>ge/2&&(G=ge/2);let be;for(be=0;be<G;++be){const Qe=parseInt(_.substr(be*2,2),16);if(Qt(Qe))return be;C[I+be]=Qe}return be}function z(C,_,I,G){return Ut(Je(_,C.length-I),C,I,G)}function U(C,_,I,G){return Ut(st(_),C,I,G)}function F(C,_,I,G){return Ut(gt(_),C,I,G)}function ue(C,_,I,G){return Ut(Mt(_,C.length-I),C,I,G)}c.prototype.write=function(_,I,G,le){if(I===void 0)le="utf8",G=this.length,I=0;else if(G===void 0&&typeof I=="string")le=I,G=this.length,I=0;else if(isFinite(I))I=I>>>0,isFinite(G)?(G=G>>>0,le===void 0&&(le="utf8")):(le=G,G=void 0);else throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");const ge=this.length-I;if((G===void 0||G>ge)&&(G=ge),_.length>0&&(G<0||I<0)||I>this.length)throw new RangeError("Attempt to write outside buffer bounds");le||(le="utf8");let be=!1;for(;;)switch(le){case"hex":return K(this,_,I,G);case"utf8":case"utf-8":return z(this,_,I,G);case"ascii":case"latin1":case"binary":return U(this,_,I,G);case"base64":return F(this,_,I,G);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ue(this,_,I,G);default:if(be)throw new TypeError("Unknown encoding: "+le);le=(""+le).toLowerCase(),be=!0}},c.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};function ae(C,_,I){return _===0&&I===C.length?t.fromByteArray(C):t.fromByteArray(C.slice(_,I))}function re(C,_,I){I=Math.min(C.length,I);const G=[];let le=_;for(;le<I;){const ge=C[le];let be=null,Qe=ge>239?4:ge>223?3:ge>191?2:1;if(le+Qe<=I){let At,Et,wt,rt;switch(Qe){case 1:ge<128&&(be=ge);break;case 2:At=C[le+1],(At&192)===128&&(rt=(ge&31)<<6|At&63,rt>127&&(be=rt));break;case 3:At=C[le+1],Et=C[le+2],(At&192)===128&&(Et&192)===128&&(rt=(ge&15)<<12|(At&63)<<6|Et&63,rt>2047&&(rt<55296||rt>57343)&&(be=rt));break;case 4:At=C[le+1],Et=C[le+2],wt=C[le+3],(At&192)===128&&(Et&192)===128&&(wt&192)===128&&(rt=(ge&15)<<18|(At&63)<<12|(Et&63)<<6|wt&63,rt>65535&&rt<1114112&&(be=rt))}}be===null?(be=65533,Qe=1):be>65535&&(be-=65536,G.push(be>>>10&1023|55296),be=56320|be&1023),G.push(be),le+=Qe}return W(G)}const X=4096;function W(C){const _=C.length;if(_<=X)return String.fromCharCode.apply(String,C);let I="",G=0;for(;G<_;)I+=String.fromCharCode.apply(String,C.slice(G,G+=X));return I}function $(C,_,I){let G="";I=Math.min(C.length,I);for(let le=_;le<I;++le)G+=String.fromCharCode(C[le]&127);return G}function D(C,_,I){let G="";I=Math.min(C.length,I);for(let le=_;le<I;++le)G+=String.fromCharCode(C[le]);return G}function L(C,_,I){const G=C.length;(!_||_<0)&&(_=0),(!I||I<0||I>G)&&(I=G);let le="";for(let ge=_;ge<I;++ge)le+=Zt[C[ge]];return le}function H(C,_,I){const G=C.slice(_,I);let le="";for(let ge=0;ge<G.length-1;ge+=2)le+=String.fromCharCode(G[ge]+G[ge+1]*256);return le}c.prototype.slice=function(_,I){const G=this.length;_=~~_,I=I===void 0?G:~~I,_<0?(_+=G,_<0&&(_=0)):_>G&&(_=G),I<0?(I+=G,I<0&&(I=0)):I>G&&(I=G),I<_&&(I=_);const le=this.subarray(_,I);return Object.setPrototypeOf(le,c.prototype),le};function N(C,_,I){if(C%1!==0||C<0)throw new RangeError("offset is not uint");if(C+_>I)throw new RangeError("Trying to access beyond buffer length")}c.prototype.readUintLE=c.prototype.readUIntLE=function(_,I,G){_=_>>>0,I=I>>>0,G||N(_,I,this.length);let le=this[_],ge=1,be=0;for(;++be<I&&(ge*=256);)le+=this[_+be]*ge;return le},c.prototype.readUintBE=c.prototype.readUIntBE=function(_,I,G){_=_>>>0,I=I>>>0,G||N(_,I,this.length);let le=this[_+--I],ge=1;for(;I>0&&(ge*=256);)le+=this[_+--I]*ge;return le},c.prototype.readUint8=c.prototype.readUInt8=function(_,I){return _=_>>>0,I||N(_,1,this.length),this[_]},c.prototype.readUint16LE=c.prototype.readUInt16LE=function(_,I){return _=_>>>0,I||N(_,2,this.length),this[_]|this[_+1]<<8},c.prototype.readUint16BE=c.prototype.readUInt16BE=function(_,I){return _=_>>>0,I||N(_,2,this.length),this[_]<<8|this[_+1]},c.prototype.readUint32LE=c.prototype.readUInt32LE=function(_,I){return _=_>>>0,I||N(_,4,this.length),(this[_]|this[_+1]<<8|this[_+2]<<16)+this[_+3]*16777216},c.prototype.readUint32BE=c.prototype.readUInt32BE=function(_,I){return _=_>>>0,I||N(_,4,this.length),this[_]*16777216+(this[_+1]<<16|this[_+2]<<8|this[_+3])},c.prototype.readBigUInt64LE=ft(function(_){_=_>>>0,Ae(_,"offset");const I=this[_],G=this[_+7];(I===void 0||G===void 0)&&Be(_,this.length-8);const le=I+this[++_]*2**8+this[++_]*2**16+this[++_]*2**24,ge=this[++_]+this[++_]*2**8+this[++_]*2**16+G*2**24;return BigInt(le)+(BigInt(ge)<<BigInt(32))}),c.prototype.readBigUInt64BE=ft(function(_){_=_>>>0,Ae(_,"offset");const I=this[_],G=this[_+7];(I===void 0||G===void 0)&&Be(_,this.length-8);const le=I*2**24+this[++_]*2**16+this[++_]*2**8+this[++_],ge=this[++_]*2**24+this[++_]*2**16+this[++_]*2**8+G;return(BigInt(le)<<BigInt(32))+BigInt(ge)}),c.prototype.readIntLE=function(_,I,G){_=_>>>0,I=I>>>0,G||N(_,I,this.length);let le=this[_],ge=1,be=0;for(;++be<I&&(ge*=256);)le+=this[_+be]*ge;return ge*=128,le>=ge&&(le-=Math.pow(2,8*I)),le},c.prototype.readIntBE=function(_,I,G){_=_>>>0,I=I>>>0,G||N(_,I,this.length);let le=I,ge=1,be=this[_+--le];for(;le>0&&(ge*=256);)be+=this[_+--le]*ge;return ge*=128,be>=ge&&(be-=Math.pow(2,8*I)),be},c.prototype.readInt8=function(_,I){return _=_>>>0,I||N(_,1,this.length),this[_]&128?(255-this[_]+1)*-1:this[_]},c.prototype.readInt16LE=function(_,I){_=_>>>0,I||N(_,2,this.length);const G=this[_]|this[_+1]<<8;return G&32768?G|4294901760:G},c.prototype.readInt16BE=function(_,I){_=_>>>0,I||N(_,2,this.length);const G=this[_+1]|this[_]<<8;return G&32768?G|4294901760:G},c.prototype.readInt32LE=function(_,I){return _=_>>>0,I||N(_,4,this.length),this[_]|this[_+1]<<8|this[_+2]<<16|this[_+3]<<24},c.prototype.readInt32BE=function(_,I){return _=_>>>0,I||N(_,4,this.length),this[_]<<24|this[_+1]<<16|this[_+2]<<8|this[_+3]},c.prototype.readBigInt64LE=ft(function(_){_=_>>>0,Ae(_,"offset");const I=this[_],G=this[_+7];(I===void 0||G===void 0)&&Be(_,this.length-8);const le=this[_+4]+this[_+5]*2**8+this[_+6]*2**16+(G<<24);return(BigInt(le)<<BigInt(32))+BigInt(I+this[++_]*2**8+this[++_]*2**16+this[++_]*2**24)}),c.prototype.readBigInt64BE=ft(function(_){_=_>>>0,Ae(_,"offset");const I=this[_],G=this[_+7];(I===void 0||G===void 0)&&Be(_,this.length-8);const le=(I<<24)+this[++_]*2**16+this[++_]*2**8+this[++_];return(BigInt(le)<<BigInt(32))+BigInt(this[++_]*2**24+this[++_]*2**16+this[++_]*2**8+G)}),c.prototype.readFloatLE=function(_,I){return _=_>>>0,I||N(_,4,this.length),r.read(this,_,!0,23,4)},c.prototype.readFloatBE=function(_,I){return _=_>>>0,I||N(_,4,this.length),r.read(this,_,!1,23,4)},c.prototype.readDoubleLE=function(_,I){return _=_>>>0,I||N(_,8,this.length),r.read(this,_,!0,52,8)},c.prototype.readDoubleBE=function(_,I){return _=_>>>0,I||N(_,8,this.length),r.read(this,_,!1,52,8)};function j(C,_,I,G,le,ge){if(!c.isBuffer(C))throw new TypeError('"buffer" argument must be a Buffer instance');if(_>le||_<ge)throw new RangeError('"value" argument is out of bounds');if(I+G>C.length)throw new RangeError("Index out of range")}c.prototype.writeUintLE=c.prototype.writeUIntLE=function(_,I,G,le){if(_=+_,I=I>>>0,G=G>>>0,!le){const Qe=Math.pow(2,8*G)-1;j(this,_,I,G,Qe,0)}let ge=1,be=0;for(this[I]=_&255;++be<G&&(ge*=256);)this[I+be]=_/ge&255;return I+G},c.prototype.writeUintBE=c.prototype.writeUIntBE=function(_,I,G,le){if(_=+_,I=I>>>0,G=G>>>0,!le){const Qe=Math.pow(2,8*G)-1;j(this,_,I,G,Qe,0)}let ge=G-1,be=1;for(this[I+ge]=_&255;--ge>=0&&(be*=256);)this[I+ge]=_/be&255;return I+G},c.prototype.writeUint8=c.prototype.writeUInt8=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,1,255,0),this[I]=_&255,I+1},c.prototype.writeUint16LE=c.prototype.writeUInt16LE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,2,65535,0),this[I]=_&255,this[I+1]=_>>>8,I+2},c.prototype.writeUint16BE=c.prototype.writeUInt16BE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,2,65535,0),this[I]=_>>>8,this[I+1]=_&255,I+2},c.prototype.writeUint32LE=c.prototype.writeUInt32LE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,4,4294967295,0),this[I+3]=_>>>24,this[I+2]=_>>>16,this[I+1]=_>>>8,this[I]=_&255,I+4},c.prototype.writeUint32BE=c.prototype.writeUInt32BE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,4,4294967295,0),this[I]=_>>>24,this[I+1]=_>>>16,this[I+2]=_>>>8,this[I+3]=_&255,I+4};function Z(C,_,I,G,le){Te(_,G,le,C,I,7);let ge=Number(_&BigInt(4294967295));C[I++]=ge,ge=ge>>8,C[I++]=ge,ge=ge>>8,C[I++]=ge,ge=ge>>8,C[I++]=ge;let be=Number(_>>BigInt(32)&BigInt(4294967295));return C[I++]=be,be=be>>8,C[I++]=be,be=be>>8,C[I++]=be,be=be>>8,C[I++]=be,I}function Ee(C,_,I,G,le){Te(_,G,le,C,I,7);let ge=Number(_&BigInt(4294967295));C[I+7]=ge,ge=ge>>8,C[I+6]=ge,ge=ge>>8,C[I+5]=ge,ge=ge>>8,C[I+4]=ge;let be=Number(_>>BigInt(32)&BigInt(4294967295));return C[I+3]=be,be=be>>8,C[I+2]=be,be=be>>8,C[I+1]=be,be=be>>8,C[I]=be,I+8}c.prototype.writeBigUInt64LE=ft(function(_,I=0){return Z(this,_,I,BigInt(0),BigInt("0xffffffffffffffff"))}),c.prototype.writeBigUInt64BE=ft(function(_,I=0){return Ee(this,_,I,BigInt(0),BigInt("0xffffffffffffffff"))}),c.prototype.writeIntLE=function(_,I,G,le){if(_=+_,I=I>>>0,!le){const At=Math.pow(2,8*G-1);j(this,_,I,G,At-1,-At)}let ge=0,be=1,Qe=0;for(this[I]=_&255;++ge<G&&(be*=256);)_<0&&Qe===0&&this[I+ge-1]!==0&&(Qe=1),this[I+ge]=(_/be>>0)-Qe&255;return I+G},c.prototype.writeIntBE=function(_,I,G,le){if(_=+_,I=I>>>0,!le){const At=Math.pow(2,8*G-1);j(this,_,I,G,At-1,-At)}let ge=G-1,be=1,Qe=0;for(this[I+ge]=_&255;--ge>=0&&(be*=256);)_<0&&Qe===0&&this[I+ge+1]!==0&&(Qe=1),this[I+ge]=(_/be>>0)-Qe&255;return I+G},c.prototype.writeInt8=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,1,127,-128),_<0&&(_=255+_+1),this[I]=_&255,I+1},c.prototype.writeInt16LE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,2,32767,-32768),this[I]=_&255,this[I+1]=_>>>8,I+2},c.prototype.writeInt16BE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,2,32767,-32768),this[I]=_>>>8,this[I+1]=_&255,I+2},c.prototype.writeInt32LE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,4,2147483647,-2147483648),this[I]=_&255,this[I+1]=_>>>8,this[I+2]=_>>>16,this[I+3]=_>>>24,I+4},c.prototype.writeInt32BE=function(_,I,G){return _=+_,I=I>>>0,G||j(this,_,I,4,2147483647,-2147483648),_<0&&(_=4294967295+_+1),this[I]=_>>>24,this[I+1]=_>>>16,this[I+2]=_>>>8,this[I+3]=_&255,I+4},c.prototype.writeBigInt64LE=ft(function(_,I=0){return Z(this,_,I,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),c.prototype.writeBigInt64BE=ft(function(_,I=0){return Ee(this,_,I,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))});function _e(C,_,I,G,le,ge){if(I+G>C.length)throw new RangeError("Index out of range");if(I<0)throw new RangeError("Index out of range")}function Se(C,_,I,G,le){return _=+_,I=I>>>0,le||_e(C,_,I,4),r.write(C,_,I,G,23,4),I+4}c.prototype.writeFloatLE=function(_,I,G){return Se(this,_,I,!0,G)},c.prototype.writeFloatBE=function(_,I,G){return Se(this,_,I,!1,G)};function Ie(C,_,I,G,le){return _=+_,I=I>>>0,le||_e(C,_,I,8),r.write(C,_,I,G,52,8),I+8}c.prototype.writeDoubleLE=function(_,I,G){return Ie(this,_,I,!0,G)},c.prototype.writeDoubleBE=function(_,I,G){return Ie(this,_,I,!1,G)},c.prototype.copy=function(_,I,G,le){if(!c.isBuffer(_))throw new TypeError("argument should be a Buffer");if(G||(G=0),!le&&le!==0&&(le=this.length),I>=_.length&&(I=_.length),I||(I=0),le>0&&le<G&&(le=G),le===G||_.length===0||this.length===0)return 0;if(I<0)throw new RangeError("targetStart out of bounds");if(G<0||G>=this.length)throw new RangeError("Index out of range");if(le<0)throw new RangeError("sourceEnd out of bounds");le>this.length&&(le=this.length),_.length-I<le-G&&(le=_.length-I+G);const ge=le-G;return this===_&&typeof a.prototype.copyWithin=="function"?this.copyWithin(I,G,le):a.prototype.set.call(_,this.subarray(G,le),I),ge},c.prototype.fill=function(_,I,G,le){if(typeof _=="string"){if(typeof I=="string"?(le=I,I=0,G=this.length):typeof G=="string"&&(le=G,G=this.length),le!==void 0&&typeof le!="string")throw new TypeError("encoding must be a string");if(typeof le=="string"&&!c.isEncoding(le))throw new TypeError("Unknown encoding: "+le);if(_.length===1){const be=_.charCodeAt(0);(le==="utf8"&&be<128||le==="latin1")&&(_=be)}}else typeof _=="number"?_=_&255:typeof _=="boolean"&&(_=Number(_));if(I<0||this.length<I||this.length<G)throw new RangeError("Out of range index");if(G<=I)return this;I=I>>>0,G=G===void 0?this.length:G>>>0,_||(_=0);let ge;if(typeof _=="number")for(ge=I;ge<G;++ge)this[ge]=_;else{const be=c.isBuffer(_)?_:c.from(_,le),Qe=be.length;if(Qe===0)throw new TypeError('The value "'+_+'" is invalid for argument "value"');for(ge=0;ge<G-I;++ge)this[ge+I]=be[ge%Qe]}return this};const ne={};function ce(C,_,I){ne[C]=class extends I{constructor(){super(),Object.defineProperty(this,"message",{value:_.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${C}]`,this.stack,delete this.name}get code(){return C}set code(le){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:le,writable:!0})}toString(){return`${this.name} [${C}]: ${this.message}`}}}ce("ERR_BUFFER_OUT_OF_BOUNDS",function(C){return C?`${C} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),ce("ERR_INVALID_ARG_TYPE",function(C,_){return`The "${C}" argument must be of type number. Received type ${typeof _}`},TypeError),ce("ERR_OUT_OF_RANGE",function(C,_,I){let G=`The value of "${C}" is out of range.`,le=I;return Number.isInteger(I)&&Math.abs(I)>2**32?le=de(String(I)):typeof I=="bigint"&&(le=String(I),(I>BigInt(2)**BigInt(32)||I<-(BigInt(2)**BigInt(32)))&&(le=de(le)),le+="n"),G+=` It must be ${_}. Received ${le}`,G},RangeError);function de(C){let _="",I=C.length;const G=C[0]==="-"?1:0;for(;I>=G+4;I-=3)_=`_${C.slice(I-3,I)}${_}`;return`${C.slice(0,I)}${_}`}function me(C,_,I){Ae(_,"offset"),(C[_]===void 0||C[_+I]===void 0)&&Be(_,C.length-(I+1))}function Te(C,_,I,G,le,ge){if(C>I||C<_){const be=typeof _=="bigint"?"n":"";let Qe;throw _===0||_===BigInt(0)?Qe=`>= 0${be} and < 2${be} ** ${(ge+1)*8}${be}`:Qe=`>= -(2${be} ** ${(ge+1)*8-1}${be}) and < 2 ** ${(ge+1)*8-1}${be}`,new ne.ERR_OUT_OF_RANGE("value",Qe,C)}me(G,le,ge)}function Ae(C,_){if(typeof C!="number")throw new ne.ERR_INVALID_ARG_TYPE(_,"number",C)}function Be(C,_,I){throw Math.floor(C)!==C?(Ae(C,I),new ne.ERR_OUT_OF_RANGE("offset","an integer",C)):_<0?new ne.ERR_BUFFER_OUT_OF_BOUNDS:new ne.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${_}`,C)}const We=/[^+/0-9A-Za-z-_]/g;function et(C){if(C=C.split("=")[0],C=C.trim().replace(We,""),C.length<2)return"";for(;C.length%4!==0;)C=C+"=";return C}function Je(C,_){_=_||1/0;let I;const G=C.length;let le=null;const ge=[];for(let be=0;be<G;++be){if(I=C.charCodeAt(be),I>55295&&I<57344){if(!le){if(I>56319){(_-=3)>-1&&ge.push(239,191,189);continue}else if(be+1===G){(_-=3)>-1&&ge.push(239,191,189);continue}le=I;continue}if(I<56320){(_-=3)>-1&&ge.push(239,191,189),le=I;continue}I=(le-55296<<10|I-56320)+65536}else le&&(_-=3)>-1&&ge.push(239,191,189);if(le=null,I<128){if((_-=1)<0)break;ge.push(I)}else if(I<2048){if((_-=2)<0)break;ge.push(I>>6|192,I&63|128)}else if(I<65536){if((_-=3)<0)break;ge.push(I>>12|224,I>>6&63|128,I&63|128)}else if(I<1114112){if((_-=4)<0)break;ge.push(I>>18|240,I>>12&63|128,I>>6&63|128,I&63|128)}else throw new Error("Invalid code point")}return ge}function st(C){const _=[];for(let I=0;I<C.length;++I)_.push(C.charCodeAt(I)&255);return _}function Mt(C,_){let I,G,le;const ge=[];for(let be=0;be<C.length&&!((_-=2)<0);++be)I=C.charCodeAt(be),G=I>>8,le=I%256,ge.push(le),ge.push(G);return ge}function gt(C){return t.toByteArray(et(C))}function Ut(C,_,I,G){let le;for(le=0;le<G&&!(le+I>=_.length||le>=C.length);++le)_[le+I]=C[le];return le}function _t(C,_){return C instanceof _||C!=null&&C.constructor!=null&&C.constructor.name!=null&&C.constructor.name===_.name}function Qt(C){return C!==C}const Zt=(function(){const C="0123456789abcdef",_=new Array(256);for(let I=0;I<16;++I){const G=I*16;for(let le=0;le<16;++le)_[G+le]=C[I]+C[le]}return _})();function ft(C){return typeof BigInt>"u"?_r:C}function _r(){throw new Error("BigInt not supported")}})(pN);const cb=pN.Buffer;var hc={exports:{}},lb;function cB(){return lb||(lb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r={Object,Array,Function,Number,String,Date,RegExp};typeof cb<"u"&&(r.Buffer=cb),typeof Promise<"u"&&(r.Promise=Promise);const n=Object.assign(i,{CONSTRUCTORS:r});function i(){return{keyword:"instanceof",schemaType:["string","array"],compile(s){if(typeof s=="string"){const o=a(s);return u=>u instanceof o}if(Array.isArray(s)){const o=s.map(a);return u=>{for(const l of o)if(u instanceof l)return!0;return!1}}throw new Error("ajv implementation error")},metaSchema:{anyOf:[{type:"string"},{type:"array",items:{type:"string"}}]}}}function a(s){const o=r[s];if(o)return o;throw new Error(`invalid "instanceof" keyword value ${s}`)}t.default=n,e.exports=n})(hc,hc.exports)),hc.exports}var db=Ps.exports,fb;function lB(){return fb||(fb=1,(function(e,t){var r=db&&db.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(cB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Ps,Ps.exports)),Ps.exports}var Ms={exports:{}},Cs={exports:{}},yc={},pb;function hN(){if(pb)return yc;pb=1,Object.defineProperty(yc,"__esModule",{value:!0});function e(t){return()=>({keyword:t,type:"number",schemaType:"array",macro:function([n,i]){return r(n,i),t==="range"?{minimum:n,maximum:i}:{exclusiveMinimum:n,exclusiveMaximum:i}},metaSchema:{type:"array",minItems:2,maxItems:2,items:{type:"number"}}});function r(n,i){if(n>i||t==="exclusiveRange"&&n===i)throw new Error("There are no numbers in range")}}return yc.default=e,yc}var mb=Cs.exports,hb;function dB(){return hb||(hb=1,(function(e,t){var r=mb&&mb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const i=(0,r(hN()).default)("range");t.default=i,e.exports=i})(Cs,Cs.exports)),Cs.exports}var yb=Ms.exports,gb;function fB(){return gb||(gb=1,(function(e,t){var r=yb&&yb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(dB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Ms,Ms.exports)),Ms.exports}var Ds={exports:{}},js={exports:{}},_b=js.exports,Eb;function pB(){return Eb||(Eb=1,(function(e,t){var r=_b&&_b.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const i=(0,r(hN()).default)("exclusiveRange");t.default=i,e.exports=i})(js,js.exports)),js.exports}var vb=Ds.exports,bb;function mB(){return bb||(bb=1,(function(e,t){var r=vb&&vb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(pB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Ds,Ds.exports)),Ds.exports}var $s={exports:{}},gc={exports:{}},ei={},Tb;function yl(){if(Tb)return ei;Tb=1,Object.defineProperty(ei,"__esModule",{value:!0}),ei.usePattern=ei.metaSchemaRef=void 0;const e=Ke(),t="http://json-schema.org/schema";function r({defaultMeta:i}={}){return i===!1?{}:{$ref:i||t}}ei.metaSchemaRef=r;function n({gen:i,it:{opts:a}},s,o=a.unicodeRegExp?"u":""){const u=new RegExp(s,o);return i.scopeValue("pattern",{key:u.toString(),ref:u,code:(0,e._)`new RegExp(${s}, ${o})`})}return ei.usePattern=n,ei}var Sb;function hB(){return Sb||(Sb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=Ke(),n=yl(),i={type:"object",properties:{pattern:{type:"string"},flags:{type:"string",nullable:!0}},required:["pattern"],additionalProperties:!1},a=/^\/(.*)\/([gimuy]*)$/;function s(){return{keyword:"regexp",type:"string",schemaType:["string","object"],code(o){const{data:u,schema:l}=o,c=d(l);o.pass((0,r._)`${c}.test(${u})`);function d(m){if(typeof m=="object")return(0,n.usePattern)(o,m.pattern,m.flags);const p=a.exec(m);if(p)return(0,n.usePattern)(o,p[1],p[2]);throw new Error("cannot parse string into RegExp")}},metaSchema:{anyOf:[{type:"string"},i]}}}t.default=s,e.exports=s})(gc,gc.exports)),gc.exports}var Ib=$s.exports,Rb;function yB(){return Rb||(Rb=1,(function(e,t){var r=Ib&&Ib.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(hB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})($s,$s.exports)),$s.exports}var Ls={exports:{}},_c={exports:{}},Ab;function gB(){return Ab||(Ab=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=Ke(),n={trimStart:u=>u.trimStart(),trimEnd:u=>u.trimEnd(),trimLeft:u=>u.trimStart(),trimRight:u=>u.trimEnd(),trim:u=>u.trim(),toLowerCase:u=>u.toLowerCase(),toUpperCase:u=>u.toUpperCase(),toEnumCase:(u,l)=>(l==null?void 0:l.hash[o(u)])||u},i=Object.assign(a,{transform:n});function a(){return{keyword:"transform",schemaType:"array",before:"enum",code(u){const{gen:l,data:c,schema:d,parentSchema:m,it:p}=u,{parentData:E,parentDataProperty:A}=p,R=d;if(!R.length)return;let O;if(R.includes("toEnumCase")){const v=s(m);O=l.scopeValue("obj",{ref:v,code:(0,r.stringify)(v)})}l.if((0,r._)`typeof ${c} == "string" && ${E} !== undefined`,()=>{l.assign(c,f(R.slice())),l.assign((0,r._)`${E}[${A}]`,c)});function f(v){if(!v.length)return c;const b=v.pop();if(!(b in n))throw new Error(`transform: unknown transformation ${b}`);const h=l.scopeValue("func",{ref:n[b],code:(0,r._)`require("ajv-keywords/dist/definitions/transform").transform${(0,r.getProperty)(b)}`}),T=f(v);return O&&b==="toEnumCase"?(0,r._)`${h}(${T}, ${O})`:(0,r._)`${h}(${T})`}},metaSchema:{type:"array",items:{type:"string",enum:Object.keys(n)}}}}function s(u){const l={hash:{}};if(!u.enum)throw new Error('transform: "toEnumCase" requires "enum"');for(const c of u.enum){if(typeof c!="string")continue;const d=o(c);if(l.hash[d])throw new Error('transform: "toEnumCase" requires all lowercased "enum" values to be unique');l.hash[d]=c}return l}function o(u){return u.toLowerCase()}t.default=i,e.exports=i})(_c,_c.exports)),_c.exports}var wb=Ls.exports,Ob;function _B(){return Ob||(Ob=1,(function(e,t){var r=wb&&wb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(gB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Ls,Ls.exports)),Ls.exports}var qs={exports:{}},Ec={exports:{}},Nb;function EB(){return Nb||(Nb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=qg(),n=["number","integer","string","boolean","null"];function i(){return{keyword:"uniqueItemProperties",type:"array",schemaType:"array",compile(s,o){const u=a(s,o);return l=>{if(l.length<=1)return!0;for(let c=0;c<s.length;c++){const d=s[c];if(u[c]){const m={};for(const p of l){if(!p||typeof p!="object")continue;let E=p[d];if(!(E&&typeof E=="object")){if(typeof E=="string"&&(E='"'+E),m[E])return!1;m[E]=!0}}}else for(let m=l.length;m--;){const p=l[m];if(!(!p||typeof p!="object"))for(let E=m;E--;){const A=l[E];if(A&&typeof A=="object"&&r(p[d],A[d]))return!1}}}return!0}},metaSchema:{type:"array",items:{type:"string"}}}}t.default=i;function a(s,o){return s.map(u=>{var l,c,d;const m=(d=(c=(l=o.items)===null||l===void 0?void 0:l.properties)===null||c===void 0?void 0:c[u])===null||d===void 0?void 0:d.type;return Array.isArray(m)?!m.includes("object")&&!m.includes("array"):n.includes(m)})}e.exports=i})(Ec,Ec.exports)),Ec.exports}var Pb=qs.exports,Mb;function vB(){return Mb||(Mb=1,(function(e,t){var r=Pb&&Pb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(EB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(qs,qs.exports)),qs.exports}var ks={exports:{}},vc={exports:{}},Cb;function bB(){return Cb||(Cb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});function r(){return{keyword:"allRequired",type:"object",schemaType:"boolean",macro(n,i){if(!n)return!0;const a=Object.keys(i.properties);return a.length===0?!0:{required:a}},dependencies:["properties"]}}t.default=r,e.exports=r})(vc,vc.exports)),vc.exports}var Db=ks.exports,jb;function TB(){return jb||(jb=1,(function(e,t){var r=Db&&Db.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(bB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(ks,ks.exports)),ks.exports}var Bs={exports:{}},Us={exports:{}},bc={},$b;function yN(){if($b)return bc;$b=1,Object.defineProperty(bc,"__esModule",{value:!0});function e(t){return()=>({keyword:t,type:"object",schemaType:"array",macro(r){return r.length===0?!0:r.length===1?{required:r}:{[t==="anyRequired"?"anyOf":"oneOf"]:r.map(i=>({required:[i]}))}},metaSchema:{type:"array",items:{type:"string"}}})}return bc.default=e,bc}var Lb=Us.exports,qb;function SB(){return qb||(qb=1,(function(e,t){var r=Lb&&Lb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const i=(0,r(yN()).default)("anyRequired");t.default=i,e.exports=i})(Us,Us.exports)),Us.exports}var kb=Bs.exports,Bb;function IB(){return Bb||(Bb=1,(function(e,t){var r=kb&&kb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(SB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Bs,Bs.exports)),Bs.exports}var Fs={exports:{}},Vs={exports:{}},Ub=Vs.exports,Fb;function RB(){return Fb||(Fb=1,(function(e,t){var r=Ub&&Ub.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const i=(0,r(yN()).default)("oneRequired");t.default=i,e.exports=i})(Vs,Vs.exports)),Vs.exports}var Vb=Fs.exports,Hb;function AB(){return Hb||(Hb=1,(function(e,t){var r=Vb&&Vb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(RB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Fs,Fs.exports)),Fs.exports}var Hs={exports:{}},Tc={exports:{}},Gb;function wB(){return Gb||(Gb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=Ke(),n=yl(),i={message:({params:{missingPattern:s}})=>(0,r.str)`should have property matching pattern '${s}'`,params:({params:{missingPattern:s}})=>(0,r._)`{missingPattern: ${s}}`};function a(){return{keyword:"patternRequired",type:"object",schemaType:"array",error:i,code(s){const{gen:o,schema:u,data:l}=s;if(u.length===0)return;const c=o.let("valid",!0);for(const m of u)d(m);function d(m){const p=o.let("matched",!1);o.forIn("key",l,E=>{o.assign(p,(0,r._)`${(0,n.usePattern)(s,m)}.test(${E})`),o.if(p,()=>o.break())}),s.setParams({missingPattern:m}),o.assign(c,(0,r.and)(c,p)),s.pass(c)}},metaSchema:{type:"array",items:{type:"string",format:"regex"},uniqueItems:!0}}}t.default=a,e.exports=a})(Tc,Tc.exports)),Tc.exports}var zb=Hs.exports,Wb;function OB(){return Wb||(Wb=1,(function(e,t){var r=zb&&zb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(wB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Hs,Hs.exports)),Hs.exports}var Gs={exports:{}},Sc={exports:{}},Yb;function NB(){return Yb||(Yb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});function r(){return{keyword:"prohibited",type:"object",schemaType:"array",macro:function(n){return n.length===0?!0:n.length===1?{not:{required:n}}:{not:{anyOf:n.map(i=>({required:[i]}))}}},metaSchema:{type:"array",items:{type:"string"}}}}t.default=r,e.exports=r})(Sc,Sc.exports)),Sc.exports}var Kb=Gs.exports,Jb;function PB(){return Jb||(Jb=1,(function(e,t){var r=Kb&&Kb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(NB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Gs,Gs.exports)),Gs.exports}var zs={exports:{}},Ic={exports:{}},Xb;function MB(){return Xb||(Xb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=yl();function n(s){return{keyword:"deepProperties",type:"object",schemaType:"object",macro:function(o){const u=[];for(const l in o)u.push(i(l,o[l]));return{allOf:u}},metaSchema:{type:"object",propertyNames:{type:"string",format:"json-pointer"},additionalProperties:(0,r.metaSchemaRef)(s)}}}t.default=n;function i(s,o){const u=s.split("/"),l={};let c=l;for(let d=1;d<u.length;d++){let m=u[d];const p=d===u.length-1;m=a(m);const E=c.properties={};let A;if(/[0-9]+/.test(m)){let R=+m;for(A=c.items=[],c.type=["object","array"];R--;)A.push({})}else c.type="object";c=p?o:{},E[m]=c,A&&A.push(c)}return l}function a(s){return s.replace(/~1/g,"/").replace(/~0/g,"~")}e.exports=n})(Ic,Ic.exports)),Ic.exports}var Qb=zs.exports,Zb;function CB(){return Zb||(Zb=1,(function(e,t){var r=Qb&&Qb.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(MB()),i=(a,s)=>a.addKeyword((0,n.default)(s));t.default=i,e.exports=i})(zs,zs.exports)),zs.exports}var Ws={exports:{}},Rc={exports:{}},xb;function DB(){return xb||(xb=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=Ke();function n(){return{keyword:"deepRequired",type:"object",schemaType:"array",code(a){const{schema:s,data:o}=a,u=s.map(c=>(0,r._)`(${l(c)}) === undefined`);a.fail((0,r.or)(...u));function l(c){if(c==="")throw new Error("empty JSON pointer not allowed");const d=c.split("/");let m=o;const p=d.map((E,A)=>A?m=(0,r._)`${m}${(0,r.getProperty)(i(E))}`:m);return(0,r.and)(...p)}},metaSchema:{type:"array",items:{type:"string",format:"json-pointer"}}}}t.default=n;function i(a){return a.replace(/~1/g,"/").replace(/~0/g,"~")}e.exports=n})(Rc,Rc.exports)),Rc.exports}var e0=Ws.exports,t0;function jB(){return t0||(t0=1,(function(e,t){var r=e0&&e0.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(DB()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Ws,Ws.exports)),Ws.exports}var Ys={exports:{}},Ac={exports:{}},r0;function $B(){return r0||(r0=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r={},n={timestamp:()=>()=>Date.now(),datetime:()=>()=>new Date().toISOString(),date:()=>()=>new Date().toISOString().slice(0,10),time:()=>()=>new Date().toISOString().slice(11),random:()=>()=>Math.random(),randomint:c=>{var d;const m=(d=c==null?void 0:c.max)!==null&&d!==void 0?d:2;return()=>Math.floor(Math.random()*m)},seq:c=>{var d;const m=(d=c==null?void 0:c.name)!==null&&d!==void 0?d:"";return r[m]||(r[m]=0),()=>r[m]++}},i=Object.assign(a,{DEFAULTS:n});function a(){return{keyword:"dynamicDefaults",type:"object",schemaType:["string","object"],modifying:!0,valid:!0,compile(c,d,m){if(!m.opts.useDefaults||m.compositeRule)return()=>!0;const p={};for(const A in c)p[A]=s(c[A]);const E=m.opts.useDefaults==="empty";return A=>{for(const R in c)(A[R]===void 0||E&&(A[R]===null||A[R]===""))&&(A[R]=p[R]());return!0}},metaSchema:{type:"object",additionalProperties:{anyOf:[{type:"string"},{type:"object",additionalProperties:!1,required:["func","args"],properties:{func:{type:"string"},args:{type:"object"}}}]}}}}function s(c){return typeof c=="object"?o(c):u(c)}function o({func:c,args:d}){const m=n[c];return l(c,m),m(d)}function u(c=""){const d=n[c];return l(c,d),d()}function l(c,d){if(!d)throw new Error(`invalid "dynamicDefaults" keyword property value: ${c}`)}t.default=i,e.exports=i})(Ac,Ac.exports)),Ac.exports}var n0=Ys.exports,i0;function LB(){return i0||(i0=1,(function(e,t){var r=n0&&n0.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r($B()),i=a=>a.addKeyword((0,n.default)());t.default=i,e.exports=i})(Ys,Ys.exports)),Ys.exports}var Ks={exports:{}},wc={exports:{}},a0;function qB(){return a0||(a0=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=Ke(),n=yl(),i={message:({params:{schemaProp:s}})=>s?(0,r.str)`should match case "${s}" schema`:(0,r.str)`should match default case schema`,params:({params:{schemaProp:s}})=>s?(0,r._)`{failingCase: ${s}}`:(0,r._)`{failingDefault: true}`};function a(s){const o=(0,n.metaSchemaRef)(s);return[{keyword:"select",schemaType:["string","number","boolean","null"],$data:!0,error:i,dependencies:["selectCases"],code(u){const{gen:l,schemaCode:c,parentSchema:d}=u;u.block$data(r.nil,()=>{const m=l.let("valid",!0),p=l.name("_valid"),E=l.const("value",(0,r._)`${c} === null ? "null" : ${c}`);l.if(!1);for(const A in d.selectCases){u.setParams({schemaProp:A}),l.elseIf((0,r._)`"" + ${E} == ${A}`);const R=u.subschema({keyword:"selectCases",schemaProp:A},p);u.mergeEvaluated(R,r.Name),l.assign(m,p)}if(l.else(),d.selectDefault!==void 0){u.setParams({schemaProp:void 0});const A=u.subschema({keyword:"selectDefault"},p);u.mergeEvaluated(A,r.Name),l.assign(m,p)}l.endIf(),u.pass(m)})}},{keyword:"selectCases",dependencies:["select"],metaSchema:{type:"object",additionalProperties:o}},{keyword:"selectDefault",dependencies:["select","selectCases"],metaSchema:o}]}t.default=a,e.exports=a})(wc,wc.exports)),wc.exports}var s0=Ks.exports,o0;function kB(){return o0||(o0=1,(function(e,t){var r=s0&&s0.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(qB()),i=(a,s)=>((0,n.default)(s).forEach(o=>a.addKeyword(o)),a);t.default=i,e.exports=i})(Ks,Ks.exports)),Ks.exports}var u0=Os.exports,c0;function BB(){return c0||(c0=1,(function(e,t){var r=u0&&u0.__importDefault||function(b){return b&&b.__esModule?b:{default:b}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(eB()),i=r(lB()),a=r(fB()),s=r(mB()),o=r(yB()),u=r(_B()),l=r(vB()),c=r(TB()),d=r(IB()),m=r(AB()),p=r(OB()),E=r(PB()),A=r(CB()),R=r(jB()),O=r(LB()),f=r(kB()),v={typeof:n.default,instanceof:i.default,range:a.default,exclusiveRange:s.default,regexp:o.default,transform:u.default,uniqueItemProperties:l.default,allRequired:c.default,anyRequired:d.default,oneRequired:m.default,patternRequired:p.default,prohibited:E.default,deepProperties:A.default,deepRequired:R.default,dynamicDefaults:O.default,select:f.default};t.default=v,e.exports=v})(Os,Os.exports)),Os.exports}var l0=ws.exports,d0;function gN(){return d0||(d0=1,(function(e,t){var r=l0&&l0.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};Object.defineProperty(t,"__esModule",{value:!0});const n=r(BB()),i=(s,o)=>{if(Array.isArray(o)){for(const u of o)a(u)(s);return s}if(o)return a(o)(s),s;for(o in n.default)a(o)(s);return s};i.get=a;function a(s){const o=n.default[s];if(!o)throw new Error("Unknown keyword "+s);return o}t.default=i,e.exports=i,e.exports.default=i})(ws,ws.exports)),ws.exports}var Oc={exports:{}},f0;function _N(){return f0||(f0=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0});const r=Fg(),n=Ke(),i=so(),a=wo(),s=Ao(),o=On(),u="errorMessage",l=new r.Name("emUsed"),c={required:"missingProperty",dependencies:"property",dependentRequired:"property"},d=/\$\{[^}]+\}/,m=/\$\{([^}]+)\}/g,p=/^""\s*\+\s*|\s*\+\s*""$/g;function E(R){return{keyword:u,schemaType:["string","object"],post:!0,code(O){const{gen:f,data:v,schema:b,schemaValue:h,it:T}=O;if(T.createErrors===!1)return;const w=b,P=n.strConcat(o.default.instancePath,T.errorPath);f.if(r._`${o.default.errors} > 0`,()=>{if(typeof w=="object"){const[H,N]=J(w);N&&K(N),H&&z(H),U(B(w))}const L=typeof w=="string"?w:w._;L&&F(L),R.keepErrors||ue()});function B({properties:L,items:H}){const N={};if(L){N.props={};for(const j in L)N.props[j]=[]}if(H){N.items={};for(let j=0;j<H.length;j++)N.items[j]=[]}return N}function J(L){let H,N;for(const j in L){if(j==="properties"||j==="items")continue;const Z=L[j];if(typeof Z=="object"){H||(H={});const Ee=H[j]={};for(const _e in Z)Ee[_e]=[]}else N||(N={}),N[j]=[]}return[H,N]}function K(L){const H=f.const("emErrors",r.stringify(L)),N=f.const("templates",W(L,b));f.forOf("err",o.default.vErrors,_e=>f.if(ae(_e,H),()=>f.code(r._`${H}[${_e}.keyword].push(${_e})`).assign(r._`${_e}.${l}`,!0)));const{singleError:j}=R;if(j){const _e=f.let("message",r._`""`),Se=f.let("paramsErrors",r._`[]`);Z(Ie=>{f.if(_e,()=>f.code(r._`${_e} += ${typeof j=="string"?j:";"}`)),f.code(r._`${_e} += ${Ee(Ie)}`),f.assign(Se,r._`${Se}.concat(${H}[${Ie}])`)}),s.reportError(O,{message:_e,params:r._`{errors: ${Se}}`})}else Z(_e=>s.reportError(O,{message:Ee(_e),params:r._`{errors: ${H}[${_e}]}`}));function Z(_e){f.forIn("key",H,Se=>f.if(r._`${H}[${Se}].length`,()=>_e(Se)))}function Ee(_e){return r._`${_e} in ${N} ? ${N}[${_e}]() : ${h}[${_e}]`}}function z(L){const H=f.const("emErrors",r.stringify(L)),N=[];for(const Se in L)N.push([Se,W(L[Se],b[Se])]);const j=f.const("templates",f.object(...N)),Z=f.scopeValue("obj",{ref:c,code:r.stringify(c)}),Ee=f.let("emPropParams"),_e=f.let("emParamsErrors");f.forOf("err",o.default.vErrors,Se=>f.if(ae(Se,H),()=>{f.assign(Ee,r._`${Z}[${Se}.keyword]`),f.assign(_e,r._`${H}[${Se}.keyword][${Se}.params[${Ee}]]`),f.if(_e,()=>f.code(r._`${_e}.push(${Se})`).assign(r._`${Se}.${l}`,!0))})),f.forIn("key",H,Se=>f.forIn("keyProp",r._`${H}[${Se}]`,Ie=>{f.assign(_e,r._`${H}[${Se}][${Ie}]`),f.if(r._`${_e}.length`,()=>{const ne=f.const("tmpl",r._`${j}[${Se}] && ${j}[${Se}][${Ie}]`);s.reportError(O,{message:r._`${ne} ? ${ne}() : ${h}[${Se}][${Ie}]`,params:r._`{errors: ${_e}}`})})}))}function U(L){const{props:H,items:N}=L;if(!H&&!N)return;const j=r._`typeof ${v} == "object"`,Z=r._`Array.isArray(${v})`,Ee=f.let("emErrors");let _e,Se;const Ie=f.let("templates");H&&N?(_e=f.let("emChildKwd"),f.if(j),f.if(Z,()=>{ne(N,b.items),f.assign(_e,r.str`items`)},()=>{ne(H,b.properties),f.assign(_e,r.str`properties`)}),Se=r._`[${_e}]`):N?(f.if(Z),ne(N,b.items),Se=r._`.items`):H&&(f.if(n.and(j,n.not(Z))),ne(H,b.properties),Se=r._`.properties`),f.forOf("err",o.default.vErrors,ce=>re(ce,Ee,de=>f.code(r._`${Ee}[${de}].push(${ce})`).assign(r._`${ce}.${l}`,!0))),f.forIn("key",Ee,ce=>f.if(r._`${Ee}[${ce}].length`,()=>{s.reportError(O,{message:r._`${ce} in ${Ie} ? ${Ie}[${ce}]() : ${h}${Se}[${ce}]`,params:r._`{errors: ${Ee}[${ce}]}`}),f.assign(r._`${o.default.vErrors}[${o.default.errors}-1].instancePath`,r._`${P} + "/" + ${ce}.replace(/~/g, "~0").replace(/\\//g, "~1")`)})),f.endIf();function ne(ce,de){f.assign(Ee,r.stringify(ce)),f.assign(Ie,W(ce,de))}}function F(L){const H=f.const("emErrs",r._`[]`);f.forOf("err",o.default.vErrors,N=>f.if(X(N),()=>f.code(r._`${H}.push(${N})`).assign(r._`${N}.${l}`,!0))),f.if(r._`${H}.length`,()=>s.reportError(O,{message:$(L),params:r._`{errors: ${H}}`}))}function ue(){const L=f.const("emErrs",r._`[]`);f.forOf("err",o.default.vErrors,H=>f.if(r._`!${H}.${l}`,()=>f.code(r._`${L}.push(${H})`))),f.assign(o.default.vErrors,L).assign(o.default.errors,r._`${L}.length`)}function ae(L,H){return n.and(r._`${L}.keyword !== ${u}`,r._`!${L}.${l}`,r._`${L}.instancePath === ${P}`,r._`${L}.keyword in ${H}`,r._`${L}.schemaPath.indexOf(${T.errSchemaPath}) === 0`,r._`/^\\/[^\\/]*$/.test(${L}.schemaPath.slice(${T.errSchemaPath.length}))`)}function re(L,H,N){f.if(n.and(r._`${L}.keyword !== ${u}`,r._`!${L}.${l}`,r._`${L}.instancePath.indexOf(${P}) === 0`),()=>{const j=f.scopeValue("pattern",{ref:/^\/([^/]*)(?:\/|$)/,code:r._`new RegExp("^\\\/([^/]*)(?:\\\/|$)")`}),Z=f.const("emMatches",r._`${j}.exec(${L}.instancePath.slice(${P}.length))`),Ee=f.const("emChild",r._`${Z} && ${Z}[1].replace(/~1/g, "/").replace(/~0/g, "~")`);f.if(r._`${Ee} !== undefined && ${Ee} in ${H}`,()=>N(Ee))})}function X(L){return n.and(r._`${L}.keyword !== ${u}`,r._`!${L}.${l}`,n.or(r._`${L}.instancePath === ${P}`,n.and(r._`${L}.instancePath.indexOf(${P}) === 0`,r._`${L}.instancePath[${P}.length] === "/"`)),r._`${L}.schemaPath.indexOf(${T.errSchemaPath}) === 0`,r._`${L}.schemaPath[${T.errSchemaPath}.length] === "/"`)}function W(L,H){const N=[];for(const j in L){const Z=H[j];d.test(Z)&&N.push([j,D(Z)])}return f.object(...N)}function $(L){return d.test(L)?new i._Code(i.safeStringify(L).replace(m,(H,N)=>`" + JSON.stringify(${a.getData(N,T)}) + "`).replace(p,"")):r.stringify(L)}function D(L){return r._`function(){return ${$(L)}}`}},metaSchema:{anyOf:[{type:"string"},{type:"object",properties:{properties:{$ref:"#/$defs/stringMap"},items:{$ref:"#/$defs/stringList"},required:{$ref:"#/$defs/stringOrMap"},dependencies:{$ref:"#/$defs/stringOrMap"}},additionalProperties:{type:"string"}}],$defs:{stringMap:{type:"object",additionalProperties:{type:"string"}},stringOrMap:{anyOf:[{type:"string"},{$ref:"#/$defs/stringMap"}]},stringList:{type:"array",items:{type:"string"}}}}}}const A=(R,O={})=>{if(!R.opts.allErrors)throw new Error("ajv-errors: Ajv option allErrors must be true");if(R.opts.jsPropertySyntax)throw new Error("ajv-errors: ajv option jsPropertySyntax is not supported");return R.addKeyword(E(O))};t.default=A,e.exports=A,e.exports.default=A})(Oc,Oc.exports)),Oc.exports}var p0;function Oe(){if(p0)return Nr;p0=1;var e=Nr&&Nr.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};Object.defineProperty(Nr,"__esModule",{value:!0}),Nr.validateType=Nr.generateLazyValidator=Nr.Ajv=void 0;const t=e(Fg());Nr.Ajv=t.default;const r=e(gN()),n=e(_N());function i(s,o){let u=null;const l=(c,d)=>{if(!u){const m=new t.default({$data:!0,allErrors:!0});(0,r.default)(m),(0,n.default)(m,{singleError:!0}),o==null||o.forEach(p=>m.addKeyword(p)),u=m.compile(s),Object.defineProperty(l,"errors",{get(){return u==null?void 0:u.errors}})}return u(c,d)};return l}Nr.generateLazyValidator=i;function a(s,o){return s.validate(o)}return Nr.validateType=a,Nr}var m0;function UB(){return m0||(m0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SceneUpdate=e.SCENE_UPDATE=void 0;const t=Oe();e.SCENE_UPDATE="SCENE_UPDATE",(function(r){r.schema={type:"object",properties:{type:{type:"string",enum:[e.SCENE_UPDATE]},payload:{type:"object",properties:{sceneId:{type:"string"},sceneType:{type:"string"}},additionalProperties:!1,required:["sceneId","sceneType"]}},required:["payload","type"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.SceneUpdate||(e.SceneUpdate={}))})(Zl)),Zl}var ld={},h0;function FB(){return h0||(h0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Update=e.UPDATE=void 0;const t=Oe();e.UPDATE="update",(function(r){r.schema={type:"object",properties:{type:{type:"string",enum:[e.UPDATE]}},required:["type"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Update||(e.Update={}))})(ld)),ld}var y0;function VB(){return y0||(y0=1,(function(e){var t=Xn&&Xn.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Xn&&Xn.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(UB(),e),r(FB(),e)})(Xn)),Xn}var ti={},dd={},g0;function HB(){return g0||(g0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProjectType=void 0;const t=Oe();(function(r){r.SCENE="scene",r.SMART_ITEM="smart-item",r.PORTABLE_EXPERIENCE="portable-experience",r.LIBRARY="library"})(e.ProjectType||(e.ProjectType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.ProjectType||(e.ProjectType={}))})(dd)),dd}var fd={},pd={},_0;function gl(){return _0||(_0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Rarity=void 0;const t=Oe();(function(r){r.UNIQUE="unique",r.MYTHIC="mythic",r.EXOTIC="exotic",r.LEGENDARY="legendary",r.EPIC="epic",r.RARE="rare",r.UNCOMMON="uncommon",r.COMMON="common"})(e.Rarity||(e.Rarity={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema);const n={[r.UNIQUE]:1,[r.MYTHIC]:10,[r.EXOTIC]:50,[r.LEGENDARY]:100,[r.EPIC]:1e3,[r.RARE]:5e3,[r.UNCOMMON]:1e4,[r.COMMON]:1e5},i={[r.UNIQUE]:"#FFE617",[r.MYTHIC]:"#FB7DE3",[r.EXOTIC]:"#E4FFB8",[r.LEGENDARY]:"#A657ED",[r.EPIC]:"#6397F2",[r.RARE]:"#3AD682",[r.UNCOMMON]:"#FF8563",[r.COMMON]:"#D4E0E0"},a={[r.UNIQUE]:"#FFB626",[r.MYTHIC]:"#FF63E1",[r.EXOTIC]:"#CAFF73",[r.LEGENDARY]:"#842DDA",[r.EPIC]:"#3D85E6",[r.RARE]:"#36CF75",[r.UNCOMMON]:"#ED6D4F",[r.COMMON]:"#ABC1C1"};function s(c){return n[c]}r.getMaxSupply=s;function o(c){return a[c]}r.getColor=o;function u(){return[r.UNIQUE,r.MYTHIC,r.EXOTIC,r.LEGENDARY,r.EPIC,r.RARE,r.UNCOMMON,r.COMMON]}r.getRarities=u;function l(c){return[i[c],a[c]]}r.getGradient=l})(e.Rarity||(e.Rarity={}))})(pd)),pd}var md={},E0;function na(){return E0||(E0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WearableCategory=void 0;const t=Oe();(function(r){r.EYEBROWS="eyebrows",r.EYES="eyes",r.FACIAL_HAIR="facial_hair",r.HAIR="hair",r.BODY_SHAPE="body_shape",r.MOUTH="mouth",r.UPPER_BODY="upper_body",r.LOWER_BODY="lower_body",r.FEET="feet",r.EARRING="earring",r.EYEWEAR="eyewear",r.HAT="hat",r.HELMET="helmet",r.MASK="mask",r.TIARA="tiara",r.TOP_HEAD="top_head",r.SKIN="skin",r.HANDS_WEAR="hands_wear"})(e.WearableCategory||(e.WearableCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.WearableCategory||(e.WearableCategory={}))})(md)),md}var hd={},v0;function _l(){return v0||(v0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpringBonesData=e.SpringBoneParams=void 0;const t=Oe();var r;(function(n){n.schema={type:"object",properties:{stiffness:{type:"number",minimum:0,maximum:4},gravityPower:{type:"number",minimum:0,maximum:2},gravityDir:{type:"array",items:[{type:"number",minimum:-10,maximum:10},{type:"number",minimum:-10,maximum:10},{type:"number",minimum:-10,maximum:10}],minItems:3,maxItems:3},drag:{type:"number",minimum:0,maximum:1},center:{type:"string",nullable:!0},isRoot:{type:"boolean",nullable:!0}},required:["stiffness","gravityPower","gravityDir","drag"]},n.validate=(0,t.generateLazyValidator)(n.schema)})(r=e.SpringBoneParams||(e.SpringBoneParams={})),(function(n){n.schema={type:"object",properties:{version:{type:"integer",enum:[1]},models:{type:"object",additionalProperties:{type:"object",additionalProperties:r.schema,required:[]},required:[]}},required:["version","models"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.SpringBonesData||(e.SpringBonesData={}))})(hd)),hd}var yd={},gd={},b0;function Hg(){return b0||(b0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.BodyShape=void 0;const t=Oe();(function(r){r.MALE="urn:decentraland:off-chain:base-avatars:BaseMale",r.FEMALE="urn:decentraland:off-chain:base-avatars:BaseFemale"})(e.BodyShape||(e.BodyShape={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.BodyShape||(e.BodyShape={}))})(gd)),gd}var _d={},Ed={},T0;function EN(){return T0||(T0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.BodyPartCategory=void 0;const t=Oe();(function(r){r.HEAD="head",r.HANDS="hands"})(e.BodyPartCategory||(e.BodyPartCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.BodyPartCategory||(e.BodyPartCategory={}))})(Ed)),Ed}var S0;function Gg(){return S0||(S0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.HideableWearableCategory=void 0;const t=na(),r=Oe(),n=EN();(function(i){i.schema={oneOf:[Object.assign({},t.WearableCategory.schema),Object.assign({},n.BodyPartCategory.schema)]},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.HideableWearableCategory||(e.HideableWearableCategory={}))})(_d)),_d}var I0;function zg(){return I0||(I0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WearableRepresentation=void 0;const t=Oe(),r=Hg(),n=Gg();(function(i){i.schema={type:"object",properties:{bodyShapes:{type:"array",items:r.BodyShape.schema,minItems:1,uniqueItems:!0},mainFile:{type:"string",minLength:1},contents:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,contains:{const:{$data:"2/mainFile"}}},overrideHides:{type:"array",items:n.HideableWearableCategory.schema},overrideReplaces:{type:"array",items:n.HideableWearableCategory.schema}},required:["bodyShapes","mainFile","contents","overrideHides","overrideReplaces"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.WearableRepresentation||(e.WearableRepresentation={}))})(yd)),yd}var ri={},ni={},vd={},bd={},R0;function ia(){return R0||(R0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.IPFSv1=e.IPFSv2=e.EthAddress=e.Color3=void 0;const t=Oe();(function(r){r.schema={type:"object",required:["r","g","b"],properties:{r:{type:"number",minimum:0,maximum:1},g:{type:"number",minimum:0,maximum:1},b:{type:"number",minimum:0,maximum:1}}};const n=(0,t.generateLazyValidator)(r.schema);r.validate=i=>n(i)})(e.Color3||(e.Color3={})),(function(r){r.schema={type:"string",pattern:"^0x[a-fA-F0-9]{40}$"};const n=new RegExp(r.schema.pattern);r.validate=i=>n.test(i)})(e.EthAddress||(e.EthAddress={})),(function(r){r.schema={type:"string",pattern:"^(ba)[a-zA-Z0-9]{57}$"};const n=new RegExp(r.schema.pattern);r.validate=i=>n.test(i)})(e.IPFSv2||(e.IPFSv2={})),(function(r){r.schema={type:"string",pattern:"^(Qm)[a-zA-Z0-9]{44}$"};const n=new RegExp(r.schema.pattern);r.validate=i=>n.test(i)})(e.IPFSv1||(e.IPFSv1={}))})(bd)),bd}var A0;function vN(){return A0||(A0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Avatar=e.Link=e.LinkUrl=e.AvatarInfo=e.Snapshots=void 0;const t=na(),r=ia(),n=Oe();var i;(function(u){u.schema={type:"object",required:["face256","body"],properties:{face256:r.IPFSv2.schema,body:r.IPFSv2.schema}},u.validate=(0,n.generateLazyValidator)(u.schema)})(i=e.Snapshots||(e.Snapshots={}));var a;(function(u){u.schema={type:"object",required:["bodyShape","eyes","hair","skin"],properties:{bodyShape:{type:"string"},eyes:{type:"object",required:["color"],properties:{color:r.Color3.schema}},hair:{type:"object",required:["color"],properties:{color:r.Color3.schema}},skin:{type:"object",required:["color"],properties:{color:r.Color3.schema}},wearables:{type:"array",items:{type:"string"}},forceRender:{type:"array",nullable:!0,items:t.WearableCategory.schema},emotes:{type:"array",items:{type:"object",properties:{slot:{type:"number"},urn:{type:"string"}},required:["slot","urn"]},nullable:!0},snapshots:Object.assign(Object.assign({},i.schema),{nullable:!0})},additionalProperties:!0},u.validate=(0,n.generateLazyValidator)(u.schema)})(a=e.AvatarInfo||(e.AvatarInfo={}));var s;(function(u){u.schema={type:"string",maxLength:2083,pattern:"^(?:https?):\\/\\/[^\\s/$.?#].[^\\s]*$"};const l=new RegExp(u.schema.pattern,"i");u.validate=c=>l.test(c)})(s=e.LinkUrl||(e.LinkUrl={}));var o;(function(u){u.schema={type:"object",required:["title","url"],properties:{title:{type:"string"},url:s.schema}}})(o=e.Link||(e.Link={})),(function(u){u.schema={type:"object",required:["name","description","ethAddress","version","tutorialStep","avatar","hasClaimedName"],properties:{userId:{type:"string"},name:{type:"string"},nameColor:Object.assign(Object.assign({},r.Color3.schema),{nullable:!0}),description:{type:"string"},links:{type:"array",maxItems:5,items:o.schema,nullable:!0},country:{nullable:!0,type:"string"},employmentStatus:{nullable:!0,type:"string"},gender:{nullable:!0,type:"string"},pronouns:{nullable:!0,type:"string"},relationshipStatus:{nullable:!0,type:"string"},sexualOrientation:{nullable:!0,type:"string"},language:{nullable:!0,type:"string"},profession:{nullable:!0,type:"string"},birthdate:{nullable:!0,type:"number"},realName:{nullable:!0,type:"string"},hobbies:{nullable:!0,type:"string"},ethAddress:r.EthAddress.schema,version:{type:"number"},tutorialStep:{type:"number"},email:{type:"string",nullable:!0},blocked:{type:"array",items:{type:"string"},nullable:!0},muted:{type:"array",items:{type:"string"},nullable:!0},interests:{type:"array",items:{type:"string"},nullable:!0},hasClaimedName:{type:"boolean"},hasConnectedWeb3:{type:"boolean",nullable:!0},avatar:a.schema},additionalProperties:!0},u.validate=(0,n.generateLazyValidator)(u.schema)})(e.Avatar||(e.Avatar={}))})(vd)),vd}var Td={},w0;function GB(){return w0||(w0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Profile=void 0;const t=Oe(),r=vN();(function(n){n.schema={type:"object",required:["avatars"],properties:{avatars:{type:"array",items:r.Avatar.schema}},additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.Profile||(e.Profile={}))})(Td)),Td}var O0;function zB(){return O0||(O0=1,(function(e){var t=ni&&ni.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=ni&&ni.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(vN(),e),r(GB(),e)})(ni)),ni}var Sd={},Id={},N0;function bN(){return N0||(N0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.FeatureToggles=e.portableExperiencesToggles=e.toggles=void 0;const t=Oe();e.toggles=["enabled","disabled"],e.portableExperiencesToggles=[...e.toggles,"hideUi"],(function(r){r.schema={type:"object",properties:{voiceChat:{type:"string",enum:e.toggles,nullable:!0},portableExperiences:{type:"string",enum:e.portableExperiencesToggles,nullable:!0,errorMessage:`valid options are ${e.portableExperiencesToggles.join(", ")}`},nearbyVoiceChat:{type:"string",enum:e.toggles,nullable:!0,errorMessage:`valid options are ${e.toggles.join(", ")}`}},errorMessage:`valid options are ${e.toggles.join(", ")}`,required:[]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.FeatureToggles||(e.FeatureToggles={}))})(Id)),Id}var Rd={},P0;function TN(){return P0||(P0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WorldConfiguration=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{name:{type:"string",nullable:!0},skybox:{type:"number",nullable:!0},minimapVisible:{type:"boolean",nullable:!0},miniMapConfig:{type:"object",nullable:!0,properties:{visible:{type:"boolean",nullable:!0},dataImage:{type:"string",nullable:!0},estateImage:{type:"string",nullable:!0}}},skyboxConfig:{type:"object",nullable:!0,properties:{fixedTime:{type:"number",nullable:!0},textures:{type:"array",nullable:!0,items:{type:"string"},oneOf:[{minItems:0,maxItems:0},{minItems:1,maxItems:1},{minItems:6,maxItems:6}],errorMessage:"customSkybox must be an array of 0, 1 or 6 strings"}}},fixedAdapter:{type:"string",nullable:!0},placesConfig:{type:"object",nullable:!0,properties:{optOut:{type:"boolean",nullable:!0}}}},required:[]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.WorldConfiguration||(e.WorldConfiguration={}))})(Rd)),Rd}var Ad={},M0;function SN(){return M0||(M0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SceneParcels=void 0;const t=Oe();(function(r){r.schema={description:'Describes a scene, a set of parcels whose content is treated as the same entity. A list of parcels is listed, for which one of them is considered the "base" for positioning purposes.',type:"object",properties:{base:{type:"string",pattern:"^-?[0-9]+,-?[0-9]+$"},parcels:{type:"array",items:{type:"string",pattern:"^-?[0-9]+,-?[0-9]+$"},minItems:1}},additionalProperties:!0,required:["base","parcels"]},r.schemaValidator=(0,t.generateLazyValidator)(r.schema),r.validate=n=>r.schemaValidator(n)&&n.parcels.includes(n.base)})(e.SceneParcels||(e.SceneParcels={}))})(Ad)),Ad}var wd={},ls={},C0;function Wg(){return C0||(C0=1,Object.defineProperty(ls,"__esModule",{value:!0}),ls.displayableProperties=void 0,ls.displayableProperties={menuBarIcon:{description:"Name of the file used as icon for the MenuBar",type:"string",nullable:!0}}),ls}var Od={},D0;function IN(){return D0||(D0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Source=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{version:{type:"number",nullable:!0},origin:{type:"string"},projectId:{type:"string"},point:{type:"object",properties:{x:{type:"integer"},y:{type:"integer"}},nullable:!0,required:["x","y"]},rotation:{type:"string",enum:["north","east","south","west"],nullable:!0},layout:{type:"object",properties:{rows:{type:"integer"},cols:{type:"integer"}},nullable:!0,required:["rows","cols"]},isEmpty:{type:"boolean",nullable:!0}},additionalProperties:!0,required:["origin","projectId"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Source||(e.Source={}))})(Od)),Od}var Nd={},j0;function RN(){return j0||(j0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpawnPoint=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{name:{type:"string",nullable:!0},position:{type:"object",oneOf:[{$ref:"#single-position"},{$ref:"#multi-position"}],required:["x","y","z"]},default:{type:"boolean",nullable:!0},cameraTarget:{type:"object",properties:{x:{type:"number"},y:{type:"number"},z:{type:"number"}},required:["x","y","z"],nullable:!0}},required:["position"],definitions:{"single-position":{$id:"#single-position",type:"object",properties:{x:{type:"number"},y:{type:"number"},z:{type:"number"}},required:["x","y","z"]},"multi-position":{$id:"#multi-position",type:"object",properties:{x:{type:"array",items:{type:"number"},minItems:1},y:{type:"array",items:{type:"number"},minItems:1},z:{type:"array",items:{type:"number"},minItems:1}},required:["x","y","z"]}}},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.SpawnPoint||(e.SpawnPoint={}))})(Nd)),Nd}var $0;function WB(){return $0||($0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Scene=e.RequiredPermission=void 0;const t=Oe(),r=Wg(),n=bN(),i=SN(),a=IN(),s=RN(),o=TN();var u;(function(l){l.ALLOW_TO_MOVE_PLAYER_INSIDE_SCENE="ALLOW_TO_MOVE_PLAYER_INSIDE_SCENE",l.ALLOW_TO_TRIGGER_AVATAR_EMOTE="ALLOW_TO_TRIGGER_AVATAR_EMOTE",l.ALLOW_MEDIA_HOSTNAMES="ALLOW_MEDIA_HOSTNAMES",l.USE_WEB3_API="USE_WEB3_API",l.USE_FETCH="USE_FETCH",l.USE_WEBSOCKET="USE_WEBSOCKET",l.OPEN_EXTERNAL_LINK="OPEN_EXTERNAL_LINK"})(u=e.RequiredPermission||(e.RequiredPermission={})),(function(l){l.schema={type:"object",properties:Object.assign(Object.assign({isPortableExperience:{description:"Define the current scene as a Portable Experience",type:"boolean",nullable:!0},main:{description:"File that contains the entry point of the scene's code",type:"string",minLength:1},scene:i.SceneParcels.schema},r.displayableProperties),{display:{description:"Information related to how should this land be displayed apart from the normal rendering of the scene",type:"object",properties:{title:{description:"A name so other users can identify what the contents of this land should be",type:"string",nullable:!0},favicon:{description:"DEPRECATED. Allow the land owner to set up a favicon to this land",type:"string",nullable:!0},description:{description:"A description that will be shown on client's nav map when the scene is selected",type:"string",nullable:!0},navmapThumbnail:{type:"string",nullable:!0}},nullable:!0,required:[]},owner:{type:"string",nullable:!0},creator:{type:"string",nullable:!0,description:"Wallet address of the creator of the scene",pattern:"^(0x[a-fA-F0-9]{40})?$",errorMessage:"Creator must be a valid wallet address"},contact:{description:"Describe different ways of contacting the land owner",type:"object",properties:{name:{type:"string",nullable:!0},email:{type:"string",nullable:!0},im:{type:"string",nullable:!0},url:{type:"string",nullable:!0}},nullable:!0,required:[]},tags:{type:"array",items:{type:"string",minLength:1},nullable:!0},source:Object.assign(Object.assign({},a.Source.schema),{nullable:!0}),spawnPoints:{type:"array",items:s.SpawnPoint.schema,nullable:!0},requiredPermissions:{type:"array",items:{type:"string",enum:Object.values(u)},uniqueItems:!0,nullable:!0},featureToggles:Object.assign(Object.assign({},n.FeatureToggles.schema),{nullable:!0}),worldConfiguration:Object.assign(Object.assign({},o.WorldConfiguration.schema),{nullable:!0}),allowedMediaHostnames:{type:"array",items:{type:"string"},nullable:!0}}),additionalProperties:!0,required:["main","scene"],dependencies:{requiredPermissions:{if:{properties:{requiredPermissions:{type:"array",contains:{const:u.ALLOW_MEDIA_HOSTNAMES}}}},then:{properties:{allowedMediaHostnames:{type:"array",items:{type:"string"},nullable:!1,minItems:1}},required:["allowedMediaHostnames"]},else:{properties:{allowedMediaHostnames:{type:["null","array"],nullable:!0,maxItems:0}}}}}},l.validate=(0,t.generateLazyValidator)(l.schema)})(e.Scene||(e.Scene={}))})(wd)),wd}var L0;function YB(){return L0||(L0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpawnPoint=e.Source=e.RequiredPermission=e.Scene=e.SceneParcels=e.WorldConfiguration=e.FeatureToggles=void 0;var t=bN();Object.defineProperty(e,"FeatureToggles",{enumerable:!0,get:function(){return t.FeatureToggles}});var r=TN();Object.defineProperty(e,"WorldConfiguration",{enumerable:!0,get:function(){return r.WorldConfiguration}});var n=SN();Object.defineProperty(e,"SceneParcels",{enumerable:!0,get:function(){return n.SceneParcels}});var i=WB();Object.defineProperty(e,"Scene",{enumerable:!0,get:function(){return i.Scene}}),Object.defineProperty(e,"RequiredPermission",{enumerable:!0,get:function(){return i.RequiredPermission}});var a=IN();Object.defineProperty(e,"Source",{enumerable:!0,get:function(){return a.Source}});var s=RN();Object.defineProperty(e,"SpawnPoint",{enumerable:!0,get:function(){return s.SpawnPoint}})})(Sd)),Sd}var ii={},Pd={},Md={},q0;function AN(){return q0||(q0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Locale=void 0;const t=Oe();(function(r){r.EN="en",r.ES="es"})(e.Locale||(e.Locale={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Locale||(e.Locale={}))})(Md)),Md}var k0;function wN(){return k0||(k0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.I18N=void 0;const t=Oe(),r=AN();(function(n){n.schema={type:"object",properties:{code:r.Locale.schema,text:{type:"string"}},additionalProperties:!0,required:["code","text"]},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.I18N||(e.I18N={}))})(Pd)),Pd}var Cd={},B0;function ON(){return B0||(B0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Metrics=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{triangles:{type:"number"},materials:{type:"number"},textures:{type:"number"},meshes:{type:"number"},bodies:{type:"number"},entities:{type:"number"}},required:["triangles","materials","textures","meshes","bodies","entities"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Metrics||(e.Metrics={}))})(Cd)),Cd}var Dd={},U0;function Yg(){return U0||(U0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.isStandard=e.standardProperties=void 0;const t=gl(),r=Oe();e.standardProperties={collectionAddress:{type:"string",nullable:!1},rarity:t.Rarity.schema};const n={type:"object",properties:Object.assign({},e.standardProperties),required:["collectionAddress","rarity"]},i=(0,r.generateLazyValidator)(n);function a(s){return i(s)}e.isStandard=a})(Dd)),Dd}var jd={},ai={},$d={},F0;function KB(){return F0||(F0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.MerkleProof=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{proof:{type:"array",items:{type:"string"}},index:{type:"number"},hashingKeys:{type:"array",items:{type:"string"}},entityHash:{type:"string"}},required:["entityHash","hashingKeys","index","proof"],additionalProperties:!0},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.MerkleProof||(e.MerkleProof={}))})($d)),$d}var V0;function NN(){return V0||(V0=1,(function(e){var t=ai&&ai.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=ai&&ai.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(KB(),e)})(ai)),ai}var Ld={},H0;function Kg(){return H0||(H0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createMappingsHelper=e.AddMappingError=e.Mappings=e.Mapping=e.MultipleMapping=e.RangeMapping=e.AnyMapping=e.SingleMapping=e.ContractNetwork=e.MappingType=void 0;const t=Oe();var r;(function(d){d.SINGLE="single",d.ANY="any",d.MULTIPLE="multiple",d.RANGE="range"})(r=e.MappingType||(e.MappingType={}));var n;(function(d){d.MAINNET="mainnet",d.BASE_MAINNET="base_mainnet",d.BASE_SEPOLIA="base_sepolia",d.MONAD_MAINNET="monad_mainnet",d.MONAD_TESTNET="monad_testnet",d.APE_MAINNET="ape_mainnet",d.APE_CALDERA="ape_caldera",d.MATIC="matic",d.SEPOLIA="sepolia",d.AMOY="amoy"})(n=e.ContractNetwork||(e.ContractNetwork={}));var i;(function(d){d.schema={type:"object",properties:{type:{type:"string",const:r.SINGLE},id:{type:"string",pattern:"^[0-9]+$"}},required:["type","id"],additionalProperties:!1},d.validate=(0,t.generateLazyValidator)(d.schema)})(i=e.SingleMapping||(e.SingleMapping={}));var a;(function(d){d.schema={type:"object",properties:{type:{type:"string",const:r.ANY}},required:["type"],additionalProperties:!1},d.validate=(0,t.generateLazyValidator)(d.schema)})(a=e.AnyMapping||(e.AnyMapping={}));var s;(function(d){d._fromLessThanOrEqualTo={keyword:"_fromLessThanOrEqualTo",validate:function(p,E){if(!E||!E.from||!E.to)return!1;let{to:A,from:R}=E;return(typeof R!="bigint"||typeof A!="bigint")&&(R=BigInt(R),A=BigInt(A)),R<=A},errors:!1},d.schema={type:"object",properties:{type:{type:"string",const:r.RANGE},from:{type:"string",pattern:"^[0-9]+$"},to:{type:"string",pattern:"^[0-9]+$"}},required:["type","from","to"],additionalProperties:!1,_fromLessThanOrEqualTo:!0},d.validate=(0,t.generateLazyValidator)(d.schema,[d._fromLessThanOrEqualTo])})(s=e.RangeMapping||(e.RangeMapping={}));var o;(function(d){d.schema={type:"object",properties:{type:{type:"string",const:r.MULTIPLE},ids:{type:"array",items:{type:"string",pattern:"^[0-9]+$"},minItems:1,uniqueItems:!0}},required:["type","ids"],additionalProperties:!1},d.validate=(0,t.generateLazyValidator)(d.schema)})(o=e.MultipleMapping||(e.MultipleMapping={}));var u;(function(d){d.schema={type:"object",properties:{type:{type:"string",enum:Object.values(r)}},required:["type"],oneOf:[i.schema,a.schema,s.schema,o.schema]},d.validate=(0,t.generateLazyValidator)(d.schema,[s._fromLessThanOrEqualTo])})(u=e.Mapping||(e.Mapping={})),(function(d){d._isMappingsValid={keyword:"_isMappingsValid",validate:function(p,E){try{c(E)}catch{return!1}return!0},errors:!1},d.innerSchema={type:"object",patternProperties:{"^0x[0-9a-fA-F]{40}$":{type:"array",items:u.schema}},minProperties:1,required:[],additionalProperties:!1};const m=Object.values(n).reduce((p,E)=>(p[E]=d.innerSchema,p),{});d.schema={type:"object",properties:m,minProperties:1,additionalProperties:!1,_isMappingsValid:!0},d.validate=(0,t.generateLazyValidator)(d.schema,[s._fromLessThanOrEqualTo,d._isMappingsValid])})(e.Mappings||(e.Mappings={}));class l extends Error{constructor(m,p,E){super(m),this.existingMapping=p,this.conflictingMapping=E}}e.AddMappingError=l;function c(d={}){const m={};for(const[h,T]of Object.entries(d)){m[h]={};for(const[w,P]of Object.entries(T))for(const B of P)v(h,w,B)}function p(){return JSON.parse(JSON.stringify(m))}function E(h,T,w){const P=BigInt(h);return P>=BigInt(T)&&P<=BigInt(w)}function A(h,T){switch(T.type){case r.SINGLE:return h.id===T.id;case r.MULTIPLE:return T.ids.includes(h.id);case r.RANGE:return E(h.id,T.from,T.to);default:return!1}}function R(h,T){switch(T.type){case r.SINGLE:return h.ids.includes(T.id);case r.MULTIPLE:return h.ids.some(w=>T.ids.includes(w));case r.RANGE:return h.ids.some(w=>E(w,T.from,T.to));default:return!1}}function O(h,T){switch(T.type){case r.SINGLE:return E(T.id,h.from,h.to);case r.MULTIPLE:return T.ids.some(w=>E(w,h.from,h.to));case r.RANGE:return BigInt(h.from)<=BigInt(T.to)&&BigInt(h.to)>=BigInt(T.from)}}function f(h,T){if(h.type===r.ANY||T.type===r.ANY)return!0;switch(h.type){case r.SINGLE:return A(h,T);case r.MULTIPLE:return R(h,T);case r.RANGE:return O(h,T)}}function v(h,T,w){var P,B;const J=T.toLowerCase();m[h]=(P=m[h])!==null&&P!==void 0?P:{},m[h][J]=(B=m[h][J])!==null&&B!==void 0?B:[];for(const K of m[h][J])if(f(K,w))throw new l(`Cannot add mapping to contract ${J} on network ${h} because it overlaps with existing mapping`,K,w);m[h][J].push(w)}function b(h,T,w){var P;return!((P=m[h])===null||P===void 0)&&P[T]?m[h][T].some(B=>{switch(B.type){case r.SINGLE:return B.id===w;case r.ANY:return!0;case r.MULTIPLE:return B.ids.includes(w);case r.RANGE:return BigInt(w)>=BigInt(B.from)&&BigInt(w)<=BigInt(B.to)}}):!1}return{addMapping:v,getMappings:p,includesNft:b}}e.createMappingsHelper=c})(Ld)),Ld}var G0;function Jg(){return G0||(G0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.isThirdParty=e.schema=void 0;const t=Oe(),r=NN(),n=Kg();e.schema={type:"object",properties:{merkleProof:r.MerkleProof.schema,content:{type:"object",nullable:!1,additionalProperties:{type:"string"},required:[]},mappings:Object.assign({nullable:!0},n.Mappings.schema)},required:["merkleProof","content"],_containsHashingKeys:!0};const i={keyword:"_containsHashingKeys",validate:function(o,u){var l;const c=u;return!((l=c==null?void 0:c.merkleProof)===null||l===void 0)&&l.hashingKeys?c.merkleProof.hashingKeys.every(d=>c.hasOwnProperty(d)):!1},errors:!1},a=(0,t.generateLazyValidator)(e.schema,[i,n.RangeMapping._fromLessThanOrEqualTo,n.Mappings._isMappingsValid]);function s(o){return a(o)}e.isThirdParty=s})(jd)),jd}var qd={},kd={},Mr={},z0;function PN(){if(z0)return Mr;z0=1,Object.defineProperty(Mr,"__esModule",{value:!0}),Mr.isBaseEmote=Mr.isBaseAvatar=Mr.requiredBaseItemProps=Mr.baseItemProperties=void 0;const e=wN(),t=ON(),r=Wg();Mr.baseItemProperties=Object.assign(Object.assign({},r.displayableProperties),{id:{type:"string"},name:{type:"string"},description:{type:"string"},i18n:{type:"array",items:e.I18N.schema,minItems:1,uniqueItemProperties:["code"],errorMessage:'${0#} array should not have duplicates for "code"'},thumbnail:{type:"string"},image:{type:"string"},metrics:Object.assign(Object.assign({},t.Metrics.schema),{nullable:!0})}),Mr.requiredBaseItemProps=["id","name","description","i18n","thumbnail","image"];function n(a){if(!a||!a.id)return!1;const s=a.id.split(":"),o=s[1]==="decentraland",u=s[3]==="base-avatars";return s.length===5&&o&&u}Mr.isBaseAvatar=n;function i(a){if(!a||!a.id)return!1;const s=a.id.split(":");return s.length===5&&s[1]==="decentraland"&&s[3]==="base-emotes"}return Mr.isBaseEmote=i,Mr}var W0;function JB(){return W0||(W0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Wearable=void 0;const t=Oe(),r=na(),n=zg(),i=PN(),a=Yg(),s=Jg(),o=Gg(),u=Kg(),l=_l();(function(c){c.schema={type:"object",properties:Object.assign(Object.assign(Object.assign(Object.assign({},i.baseItemProperties),a.standardProperties),s.schema.properties.thirdPartyProps),{data:{type:"object",properties:{replaces:{type:"array",items:o.HideableWearableCategory.schema},hides:{type:"array",items:o.HideableWearableCategory.schema},tags:{type:"array",items:{type:"string",minLength:1}},representations:{type:"array",items:n.WearableRepresentation.schema,minItems:1},category:r.WearableCategory.schema,removesDefaultHiding:{type:"array",nullable:!0,items:o.HideableWearableCategory.schema},blockVrmExport:{type:"boolean",nullable:!0},outlineCompatible:{type:"boolean",nullable:!0},springBones:Object.assign(Object.assign({},l.SpringBonesData.schema),{nullable:!0})},required:["replaces","hides","tags","representations","category"]}}),additionalProperties:!0,required:[],oneOf:[{required:["id","i18n"],prohibited:["merkleProof","content","collectionAddress","rarity","mappings"],_isBaseAvatar:!0},{required:[...i.requiredBaseItemProps,"data","collectionAddress","rarity"],prohibited:["merkleProof","content","mappings"]},{required:[...i.requiredBaseItemProps,"data","merkleProof","content"],prohibited:["collectionAddress","rarity"],_isThirdParty:!0}],errorMessage:{oneOf:"either standard XOR thirdparty properties conditions must be met"}};const d={keyword:"_isThirdParty",validate:(p,E)=>!p||(0,s.isThirdParty)(E),errors:!1},m={keyword:"_isBaseAvatar",validate:(p,E)=>!p||(0,i.isBaseAvatar)(E),errors:!1};c.validate=(0,t.generateLazyValidator)(c.schema,[d,m,u.RangeMapping._fromLessThanOrEqualTo,u.Mappings._isMappingsValid])})(e.Wearable||(e.Wearable={}))})(kd)),kd}var Y0;function XB(){return Y0||(Y0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpringBonesData=e.SpringBoneParams=e.HideableWearableCategory=e.BodyPartCategory=e.WearableCategory=e.Wearable=e.WearableRepresentation=void 0;var t=zg();Object.defineProperty(e,"WearableRepresentation",{enumerable:!0,get:function(){return t.WearableRepresentation}});var r=JB();Object.defineProperty(e,"Wearable",{enumerable:!0,get:function(){return r.Wearable}});var n=na();Object.defineProperty(e,"WearableCategory",{enumerable:!0,get:function(){return n.WearableCategory}});var i=EN();Object.defineProperty(e,"BodyPartCategory",{enumerable:!0,get:function(){return i.BodyPartCategory}});var a=Gg();Object.defineProperty(e,"HideableWearableCategory",{enumerable:!0,get:function(){return a.HideableWearableCategory}});var s=_l();Object.defineProperty(e,"SpringBoneParams",{enumerable:!0,get:function(){return s.SpringBoneParams}}),Object.defineProperty(e,"SpringBonesData",{enumerable:!0,get:function(){return s.SpringBonesData}})})(qd)),qd}var Bd={},Ud={},Fd={},Vd={},K0;function MN(){return K0||(K0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteCategory=void 0;const t=Oe();(function(r){r.DANCE="dance",r.STUNT="stunt",r.GREETINGS="greetings",r.FUN="fun",r.POSES="poses",r.REACTIONS="reactions",r.HORROR="horror",r.MISCELLANEOUS="miscellaneous"})(e.EmoteCategory||(e.EmoteCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.EmoteCategory||(e.EmoteCategory={}))})(Vd)),Vd}var Hd={},J0;function CN(){return J0||(J0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteRepresentationADR74=void 0;const t=Oe(),r=Hg();(function(n){n.schema={type:"object",properties:{bodyShapes:{type:"array",items:r.BodyShape.schema,minItems:1,uniqueItems:!0},mainFile:{type:"string",minLength:1},contents:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,contains:{const:{$data:"2/mainFile"}},errorMessage:{contains:"contents should contain mainFile: ${1/mainFile}"}}},required:["bodyShapes","mainFile","contents"]},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EmoteRepresentationADR74||(e.EmoteRepresentationADR74={}))})(Hd)),Hd}var Gd={},X0;function DN(){return X0||(X0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.OutcomeGroup=e.StartAnimation=e.EmoteClip=e.ArmatureId=void 0;const t=Oe();var r;(function(i){i.Armature="Armature",i.Armature_Prop="Armature_Prop",i.Armature_Other="Armature_Other"})(r=e.ArmatureId||(e.ArmatureId={})),(function(i){i.schema={type:"string",enum:Object.values(i)},i.validate=(0,t.generateLazyValidator)(i.schema)})(r=e.ArmatureId||(e.ArmatureId={}));var n;(function(i){i.schema={type:"object",properties:{animation:{type:"string",minLength:1,errorMessage:"animation must be a non-empty string (GLB clip name)"}},required:["animation"],additionalProperties:!1,errorMessage:{required:{animation:"animation is required (GLB clip name)"}}},i.validate=(0,t.generateLazyValidator)(i.schema)})(n=e.EmoteClip||(e.EmoteClip={})),(function(i){i.schema={type:"object",properties:{loop:{type:"boolean",errorMessage:"startAnimation.loop must be a boolean"},[r.Armature]:Object.assign(Object.assign({},n.schema),{errorMessage:"startAnimation.Armature is required and must contain valid animation data"}),[r.Armature_Prop]:Object.assign(Object.assign({},n.schema),{nullable:!0,errorMessage:"startAnimation.Armature_Prop must contain valid animation data when provided"}),audio:{type:"string",nullable:!0,errorMessage:"audio must be a string (audio clip filename) when provided"}},required:["loop",r.Armature],additionalProperties:!1,errorMessage:{required:{loop:"startAnimation.loop is required",[r.Armature]:"startAnimation.Armature is required"}}},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.StartAnimation||(e.StartAnimation={})),(function(i){i.schema={type:"object",properties:{title:{type:"string",minLength:1,errorMessage:"outcome.title must be a non-empty string"},loop:{type:"boolean",errorMessage:"outcome.loop must be a boolean"},clips:{type:"object",properties:Object.values(r).reduce((a,s)=>(a[s]=Object.assign(Object.assign({},n.schema),{nullable:!0,errorMessage:`outcome.clips.${s} must contain valid animation data when provided`}),a),{}),additionalProperties:!0,minProperties:1,errorMessage:"outcome.clips must contain at least one armature animation"},audio:{type:"string",nullable:!0,errorMessage:"audio must be a string (audio clip filename) when provided"}},required:["title","loop","clips"],additionalProperties:!1,errorMessage:{required:{title:"outcome.title is required",loop:"outcome.loop is required",clips:"outcome.clips is required"}}},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.OutcomeGroup||(e.OutcomeGroup={}))})(Gd)),Gd}var Q0;function jN(){return Q0||(Q0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteDataADR74=void 0;const t=MN(),r=Oe(),n=CN(),i=DN();(function(a){a.schema={type:"object",properties:{tags:{type:"array",items:{type:"string",minLength:1}},representations:{type:"array",items:n.EmoteRepresentationADR74.schema,minItems:1},category:t.EmoteCategory.schema,loop:{type:"boolean"},startAnimation:Object.assign(Object.assign({},i.StartAnimation.schema),{nullable:!0}),randomizeOutcomes:{type:"boolean",nullable:!0},outcomes:{type:"array",items:i.OutcomeGroup.schema,minItems:1,maxItems:3,nullable:!0}},required:["category","tags","representations","loop"],dependencies:{startAnimation:["randomizeOutcomes","outcomes"],randomizeOutcomes:["startAnimation","outcomes"],outcomes:["startAnimation","randomizeOutcomes"]},additionalProperties:!0},a.validate=(0,r.generateLazyValidator)(a.schema)})(e.EmoteDataADR74||(e.EmoteDataADR74={}))})(Fd)),Fd}var Z0;function QB(){return Z0||(Z0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Emote=void 0;const t=$N(),r=Oe(),n=PN(),i=Yg(),a=Jg(),s=jN();(function(o){o.schema={type:"object",properties:Object.assign(Object.assign(Object.assign(Object.assign({},n.baseItemProperties),i.standardProperties),a.schema.properties),{emoteDataADR74:s.EmoteDataADR74.schema}),additionalProperties:!0,required:[...n.requiredBaseItemProps],oneOf:[{required:["emoteDataADR74"],oneOf:[{required:["id","i18n"],prohibited:["merkleProof","content","collectionAddress","rarity"],_isBaseEmote:!0},{required:["collectionAddress","rarity"],prohibited:["merkleProof","content"],errorMessage:"standard properties conditions are not met"},{required:["merkleProof","content","id","name","description","i18n","image","thumbnail","emoteDataADR74"],_isThirdParty:!0,prohibited:["collectionAddress","rarity"],errorMessage:"thirdparty properties conditions are not met"}],errorMessage:{oneOf:"emote should have either standard or thirdparty properties"}}],errorMessage:{oneOf:'emote should have "emoteDataADR74" and match its schema'}};const u={keyword:"_isThirdParty",validate:(c,d)=>!c||(0,t.isThirdParty)(d),errors:!1},l={keyword:"_isBaseEmote",validate:(c,d)=>!c||(0,n.isBaseEmote)(d),errors:!1};o.validate=(0,r.generateLazyValidator)(o.schema,[u,l,t.RangeMapping._fromLessThanOrEqualTo,t.Mappings._isMappingsValid])})(e.Emote||(e.Emote={}))})(Ud)),Ud}var zd={},x0;function ZB(){return x0||(x0=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmotePlayMode=void 0;const t=Oe();(function(r){r.SIMPLE="simple",r.LOOP="loop"})(e.EmotePlayMode||(e.EmotePlayMode={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.EmotePlayMode||(e.EmotePlayMode={}))})(zd)),zd}var Wd={},eT;function xB(){return eT||(eT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteOutcomeType=void 0;const t=Oe();(function(r){r.SIMPLE_OUTCOME="so",r.MULTIPLE_OUTCOME="mo",r.RANDOM_OUTCOME="ro"})(e.EmoteOutcomeType||(e.EmoteOutcomeType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.EmoteOutcomeType||(e.EmoteOutcomeType={}))})(Wd)),Wd}var tT;function eU(){return tT||(tT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteOutcomeType=e.EmotePlayMode=e.EmoteCategory=e.StartAnimation=e.OutcomeGroup=e.EmoteClip=e.ArmatureId=e.EmoteDataADR74=e.EmoteRepresentationADR74=e.Emote=void 0;var t=QB();Object.defineProperty(e,"Emote",{enumerable:!0,get:function(){return t.Emote}});var r=CN();Object.defineProperty(e,"EmoteRepresentationADR74",{enumerable:!0,get:function(){return r.EmoteRepresentationADR74}});var n=jN();Object.defineProperty(e,"EmoteDataADR74",{enumerable:!0,get:function(){return n.EmoteDataADR74}});var i=DN();Object.defineProperty(e,"ArmatureId",{enumerable:!0,get:function(){return i.ArmatureId}}),Object.defineProperty(e,"EmoteClip",{enumerable:!0,get:function(){return i.EmoteClip}}),Object.defineProperty(e,"OutcomeGroup",{enumerable:!0,get:function(){return i.OutcomeGroup}}),Object.defineProperty(e,"StartAnimation",{enumerable:!0,get:function(){return i.StartAnimation}});var a=MN();Object.defineProperty(e,"EmoteCategory",{enumerable:!0,get:function(){return a.EmoteCategory}});var s=ZB();Object.defineProperty(e,"EmotePlayMode",{enumerable:!0,get:function(){return s.EmotePlayMode}});var o=xB();Object.defineProperty(e,"EmoteOutcomeType",{enumerable:!0,get:function(){return o.EmoteOutcomeType}})})(Bd)),Bd}var rT;function $N(){return rT||(rT=1,(function(e){var t=ii&&ii.__createBinding||(Object.create?(function(l,c,d,m){m===void 0&&(m=d);var p=Object.getOwnPropertyDescriptor(c,d);(!p||("get"in p?!c.__esModule:p.writable||p.configurable))&&(p={enumerable:!0,get:function(){return c[d]}}),Object.defineProperty(l,m,p)}):(function(l,c,d,m){m===void 0&&(m=d),l[m]=c[d]})),r=ii&&ii.__exportStar||function(l,c){for(var d in l)d!=="default"&&!Object.prototype.hasOwnProperty.call(c,d)&&t(c,l,d)};Object.defineProperty(e,"__esModule",{value:!0}),e.isThirdParty=e.isStandard=e.BodyShape=e.Metrics=e.Locale=e.I18N=void 0;var n=wN();Object.defineProperty(e,"I18N",{enumerable:!0,get:function(){return n.I18N}});var i=AN();Object.defineProperty(e,"Locale",{enumerable:!0,get:function(){return i.Locale}});var a=ON();Object.defineProperty(e,"Metrics",{enumerable:!0,get:function(){return a.Metrics}});var s=Hg();Object.defineProperty(e,"BodyShape",{enumerable:!0,get:function(){return s.BodyShape}});var o=Yg();Object.defineProperty(e,"isStandard",{enumerable:!0,get:function(){return o.isStandard}});var u=Jg();Object.defineProperty(e,"isThirdParty",{enumerable:!0,get:function(){return u.isThirdParty}}),r(Kg(),e),r(XB(),e),r(eU(),e)})(ii)),ii}var Yd={},Kd={},nT;function Oo(){return nT||(nT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.AuthChain=e.AuthLink=e.AuthLinkType=void 0;const t=Oe();var r;(function(i){i.SIGNER="SIGNER",i.ECDSA_PERSONAL_EPHEMERAL="ECDSA_EPHEMERAL",i.ECDSA_PERSONAL_SIGNED_ENTITY="ECDSA_SIGNED_ENTITY",i.ECDSA_EIP_1654_EPHEMERAL="ECDSA_EIP_1654_EPHEMERAL",i.ECDSA_EIP_1654_SIGNED_ENTITY="ECDSA_EIP_1654_SIGNED_ENTITY"})(r=e.AuthLinkType||(e.AuthLinkType={}));var n;(function(i){i.schema={type:"object",properties:{type:{type:"string",enum:Object.values(r)},payload:{type:"string"},signature:{type:"string",nullable:!0}},required:["payload","type"],if:{properties:{type:{not:{const:r.SIGNER}}}},then:{required:["signature"]},else:{oneOf:[{properties:{signature:{type:"string",const:""}},required:["signature"]},{properties:{signature:{type:"null"}}}]}},i.validate=(0,t.generateLazyValidator)(i.schema)})(n=e.AuthLink||(e.AuthLink={})),(function(i){i.schema={type:"array",items:n.schema,minItems:1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.AuthChain||(e.AuthChain={}))})(Kd)),Kd}var iT;function tU(){return iT||(iT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PointerChangesSyncDeployment=e.SnapshotSyncDeployment=void 0;const t=ia(),r=Oo(),n=Oe();(function(i){i.schema={type:"object",properties:{entityId:{type:"string"},entityType:{type:"string"},pointers:{type:"array",items:{type:"string"},minItems:1},authChain:r.AuthChain.schema,entityTimestamp:{type:"number",minimum:0}},oneOf:[{properties:{entityId:t.IPFSv1.schema}},{properties:{entityId:t.IPFSv2.schema}}],required:["entityId","entityType","pointers","entityTimestamp","authChain"]},i.validate=(0,n.generateLazyValidator)(i.schema)})(e.SnapshotSyncDeployment||(e.SnapshotSyncDeployment={})),(function(i){i.schema={type:"object",properties:{entityId:{type:"string"},entityType:{type:"string"},pointers:{type:"array",items:{type:"string"},minItems:1},authChain:r.AuthChain.schema,entityTimestamp:{type:"number",minimum:0},localTimestamp:{type:"number",minimum:0}},oneOf:[{properties:{entityId:t.IPFSv1.schema}},{properties:{entityId:t.IPFSv2.schema}}],required:["entityId","entityType","pointers","localTimestamp","entityTimestamp","authChain"]},i.validate=(0,n.generateLazyValidator)(i.schema)})(e.PointerChangesSyncDeployment||(e.PointerChangesSyncDeployment={}))})(Yd)),Yd}var Jd={},Xd={},aT;function LN(){return aT||(aT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ContentMapping=void 0;const t=ia(),r=Oe();(function(n){n.schema={type:"object",properties:{file:{type:"string",minLength:1},hash:{type:"string",oneOf:[t.IPFSv1.schema,t.IPFSv2.schema]}},required:["file","hash"]},n.validate=(0,r.generateLazyValidator)(n.schema)})(e.ContentMapping||(e.ContentMapping={}))})(Xd)),Xd}var sT;function qN(){return sT||(sT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Entity=e.EntityType=void 0;const t=ia(),r=LN(),n=Oe();(function(i){i.SCENE="scene",i.PROFILE="profile",i.WEARABLE="wearable",i.STORE="store",i.EMOTE="emote",i.OUTFITS="outfits"})(e.EntityType||(e.EntityType={})),(function(i){i.schema={type:"object",properties:{version:{type:"string",enum:["v3"]},id:{type:"string",oneOf:[t.IPFSv1.schema,t.IPFSv2.schema]},type:{type:"string"},pointers:{type:"array",items:{type:"string",minLength:1}},timestamp:{type:"number",minimum:0},content:{type:"array",items:r.ContentMapping.schema},metadata:{type:"object",nullable:!0}},required:["version","id","type","pointers","timestamp","content"]},i.validate=(0,n.generateLazyValidator)(i.schema)})(e.Entity||(e.Entity={}))})(Jd)),Jd}var Qd={},oT;function rU(){return oT||(oT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DeploymentWithAuthChain=void 0;const t=Oo(),r=Oe();(function(n){n.schema={type:"object",properties:{entityId:{type:"string"},entityType:{type:"string"},pointers:{type:"array",items:{type:"string"},minItems:1},localTimestamp:{type:"number",minimum:0},authChain:t.AuthChain.schema},required:["entityId","entityType","pointers","localTimestamp","authChain"]},n.validate=(0,r.generateLazyValidator)(n.schema)})(e.DeploymentWithAuthChain||(e.DeploymentWithAuthChain={}))})(Qd)),Qd}var si={},Zd={},uT;function nU(){return uT||(uT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Outfits=e.Outfit=void 0;const t=na(),r=ia(),n=Oe();var i;(function(a){a.schema={type:"object",required:["bodyShape","eyes","hair","skin","wearables"],properties:{bodyShape:{type:"string"},eyes:{type:"object",required:["color"],properties:{color:r.Color3.schema}},hair:{type:"object",required:["color"],properties:{color:r.Color3.schema}},skin:{type:"object",required:["color"],properties:{color:r.Color3.schema}},wearables:{type:"array",items:{type:"string"}},forceRender:{type:"array",nullable:!0,items:t.WearableCategory.schema}},additionalProperties:!0},a.validate=(0,n.generateLazyValidator)(a.schema)})(i=e.Outfit||(e.Outfit={})),(function(a){a.schema={type:"object",required:["outfits","namesForExtraSlots"],properties:{outfits:{type:"array",items:{type:"object",required:["slot","outfit"],properties:{slot:{type:"number"},outfit:i.schema}}},namesForExtraSlots:{type:"array",uniqueItems:!0,items:{type:"string"}}},additionalProperties:!0},a.validate=(0,n.generateLazyValidator)(a.schema)})(e.Outfits||(e.Outfits={}))})(Zd)),Zd}var cT;function iU(){return cT||(cT=1,(function(e){var t=si&&si.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=si&&si.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(nU(),e)})(si)),si}var oi={},xd={},lT;function kN(){return lT||(lT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.NotificationOptOutScope=e.NotificationType=void 0,(function(t){t.BADGE_GRANTED="badge_granted",t.BID_ACCEPTED="bid_accepted",t.BID_RECEIVED="bid_received",t.EVENTS_STARTED="events_started",t.EVENTS_STARTS_SOON="events_starts_soon",t.EVENT_CREATED="event_created",t.EVENT_APPROVED="event_approved",t.EVENT_REJECTED="event_rejected",t.EVENT_DELETED="event_deleted",t.GOVERNANCE_ANNOUNCEMENT="governance_announcement",t.GOVERNANCE_AUTHORED_PROPOSAL_FINISHED="governance_authored_proposal_finished",t.GOVERNANCE_COAUTHOR_REQUESTED="governance_coauthor_requested",t.GOVERNANCE_CLIFF_ENDED="governance_cliff_ended",t.GOVERNANCE_NEW_COMMENT_ON_PROJECT_UPDATE="governance_new_comment_on_project_update",t.GOVERNANCE_NEW_COMMENT_ON_PROPOSAL="governance_new_comment_on_proposal",t.GOVERNANCE_PROPOSAL_ENACTED="governance_proposal_enacted",t.GOVERNANCE_VOTING_ENDED_VOTER="governance_voting_ended_voter",t.GOVERNANCE_PITCH_PASSED="governance_pitch_passed",t.GOVERNANCE_TENDER_PASSED="governance_tender_passed",t.GOVERNANCE_WHALE_VOTE="governance_whale_vote",t.GOVERNANCE_VOTED_ON_BEHALF="governance_voted_on_behalf",t.ITEM_SOLD="item_sold",t.ITEM_PUBLISHED="item_published",t.LAND_RENTAL_ENDED="rental_ended",t.LAND_RENTED="rental_started",t.REWARD_ASSIGNED="reward_assignment",t.REWARD_CAMPAIGN_OUT_OF_FUNDS="reward_campaign_out_of_funds",t.REWARD_CAMPAIGN_GAS_PRICE_HIGHER_THAN_EXPECTED="reward_campaign_gas_price_higher_than_expected",t.REWARD_CAMPAIGN_OUT_OF_STOCK="reward_campaign_out_of_stock",t.REWARD_DELAYED="reward_delayed",t.REWARD_IN_PROGRESS="reward_in_progress",t.ROYALTIES_EARNED="royalties_earned",t.SOCIAL_SERVICE_FRIENDSHIP_REQUEST="social_service_friendship_request",t.SOCIAL_SERVICE_FRIENDSHIP_ACCEPTED="social_service_friendship_accepted",t.WORLDS_ACCESS_RESTORED="worlds_access_restored",t.WORLDS_ACCESS_RESTRICTED="worlds_access_restricted",t.WORLDS_MISSING_RESOURCES="worlds_missing_resources",t.WORLDS_PERMISSION_GRANTED="worlds_permission_granted",t.WORLDS_PERMISSION_REVOKED="worlds_permission_revoked",t.CREDITS_GOAL_COMPLETED="credits_goal_completed",t.CREDITS_ON_DEMAND_GRANTED="credits_on_demand_granted",t.STREAMING_KEY_RESET="streaming_key_reset",t.STREAMING_KEY_REVOKE="streaming_key_revoke",t.STREAMING_KEY_EXPIRED="streaming_key_expired",t.STREAMING_TIME_EXCEEDED="streaming_time_exceeded",t.STREAMING_PLACE_UPDATED="streaming_place_updated",t.CREDITS_REMINDER_COMPLETE_GOALS="credits_reminder_complete_goals",t.CREDITS_REMINDER_CLAIM_CREDITS="credits_reminder_claim_credits",t.CREDITS_REMINDER_USAGE="credits_reminder_usage",t.CREDITS_REMINDER_USAGE_24_HOURS="credits_reminder_usage_24_hours",t.CREDITS_REMINDER_DO_NOT_MISS_OUT="credits_reminder_do_not_miss_out",t.CREDITS_NEW_SEASON_REMINDER="credits_new_season_reminder",t.REFERRAL_INVITED_USERS_ACCEPTED="referral_invited_users_accepted",t.REFERRAL_NEW_TIER_REACHED="referral_new_tier_reached",t.COMMUNITY_DELETED="community_deleted",t.COMMUNITY_DELETED_CONTENT_VIOLATION="community_deleted_content_violation",t.COMMUNITY_RENAMED="community_renamed",t.COMMUNITY_MEMBER_BANNED="community_member_banned",t.COMMUNITY_MEMBER_REMOVED="community_member_removed",t.COMMUNITY_REQUEST_TO_JOIN_RECEIVED="community_request_to_join_received",t.COMMUNITY_REQUEST_TO_JOIN_ACCEPTED="community_request_to_join_accepted",t.COMMUNITY_INVITE_RECEIVED="community_invite_received",t.COMMUNITY_OWNERSHIP_TRANSFERRED="community_ownership_transferred",t.COMMUNITY_POST_ADDED="community_post_added",t.COMMUNITY_VOICE_CHAT_STARTED="community_voice_chat_started",t.USER_BANNED_FROM_SCENE="user_banned_from_scene",t.USER_UNBANNED_FROM_SCENE="user_unbanned_from_scene",t.TRANSFER_RECEIVED="transfer_received",t.TIP_RECEIVED="tip_received",t.BANNED="banned",t.BAN_WARNING="ban_warning",t.BAN_LIFTED="ban_lifted"})(e.NotificationType||(e.NotificationType={})),(function(t){t.COMMUNITY="community"})(e.NotificationOptOutScope||(e.NotificationOptOutScope={}))})(xd)),xd}var ef={},tf={},dT;function BN(){return dT||(dT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SubscriptionDetails=void 0;const t=Oe(),r=kN(),n={type:"object",required:["email","in_app"],properties:{email:{type:"boolean"},in_app:{type:"boolean"}}},i=Object.values(r.NotificationType).reduce((a,s)=>(a[s]=n,a),{});(function(a){a.schema={type:"object",required:["ignore_all_email","ignore_all_in_app","message_type"],properties:{ignore_all_email:{type:"boolean"},ignore_all_in_app:{type:"boolean"},message_type:{type:"object",required:Object.values(r.NotificationType),additionalProperties:!1,properties:i}}},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.SubscriptionDetails||(e.SubscriptionDetails={}))})(tf)),tf}var rf={},fT;function UN(){return fT||(fT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Email=void 0,(function(t){t.schema={type:"string",pattern:"^[\\w\\-\\.]+@([\\w-]+\\.)+[\\w-]{2,}$"};const r=new RegExp(t.schema.pattern);t.validate=n=>r.test(n)})(e.Email||(e.Email={}))})(rf)),rf}var pT;function aU(){return pT||(pT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Subscription=void 0;const t=Oe(),r=BN(),n=ia(),i=UN();(function(a){a.schema={type:"object",required:["address","details"],properties:{address:n.EthAddress.schema,email:Object.assign(Object.assign({},i.Email.schema),{nullable:!0}),details:r.SubscriptionDetails.schema}},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Subscription||(e.Subscription={}))})(ef)),ef}var mT;function sU(){return mT||(mT=1,(function(e){var t=oi&&oi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=oi&&oi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(kN(),e),r(aU(),e),r(BN(),e)})(oi)),oi}var ui={},nf={},hT;function lr(){return hT||(hT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Events=void 0,(function(t){(function(r){r.BLOCKCHAIN="blockchain",r.CATALYST_DEPLOYMENT="catalyst-deployment",r.WORLD="world",r.CLIENT="client",r.WEB="web",r.MARKETPLACE="marketplace",r.REWARDS="rewards",r.BADGE="badge",r.ASSET_BUNDLE="asset-bundle",r.SOCIAL_SERVICE="social-service",r.CREDITS_SERVICE="credits-service",r.STREAMING="streaming",r.COMMS="comms",r.REFERRAL="referral",r.COMMUNITY="community",r.CAMERA="camera",r.EVENT="event",r.GOVERNANCE="governance",r.MODERATION="moderation"})(t.Type||(t.Type={})),(function(r){(function(n){n.BID_ACCEPTED="bid-accepted",n.ITEM_SOLD="item-sold",n.RENTAL_ENDED="land-rental-ended",n.RENTAL_STARTED="land-rental-started",n.ROYALTIES_EARNED="royalties-earned",n.COLLECTION_CREATED="collection-created",n.ITEM_PUBLISHED="item-published",n.TRANSFER_RECEIVED="transfer-received",n.TIP_RECEIVED="tip-received"})(r.Blockchain||(r.Blockchain={})),(function(n){n.BID_RECEIVED="bid-received"})(r.Marketplace||(r.Marketplace={})),(function(n){n.SCENE="scene",n.PROFILE="profile",n.WEARABLE="wearable",n.STORE="store",n.EMOTE="emote",n.OUTFITS="outfits"})(r.CatalystDeployment||(r.CatalystDeployment={})),(function(n){n.DEPLOYMENT="deployment",n.WORLD_SETTINGS_CHANGED="world_settings_changed",n.WORLD_SCENES_UNDEPLOYMENT="world_scenes_undeployment",n.WORLD_UNDEPLOYMENT="world_undeployment",n.WORLD_SPAWN_COORDINATE_SET="world_spawn_coordinate_set",n.WORLDS_PERMISSION_GRANTED="worlds_permission_granted",n.WORLDS_PERMISSION_REVOKED="worlds_permission_revoked",n.WORLDS_ACCESS_RESTORED="worlds_access_restored",n.WORLDS_ACCESS_RESTRICTED="worlds_access_restricted",n.WORLDS_MISSING_RESOURCES="worlds_missing_resources"})(r.Worlds||(r.Worlds={})),(function(n){n.LOGGED_IN="logged-in",n.LOGGED_IN_CACHED="logged-in-cached",n.MOVE_TO_PARCEL="move-to-parcel",n.USED_EMOTE="used-emote",n.PASSPORT_OPENED="passport-opened",n.WALKED_DISTANCE="walked-distance",n.VERTICAL_HEIGHT_REACHED="vertical-height-reached"})(r.Client||(r.Client={})),(function(n){n.AUTH_IDENTIFY="auth-identify"})(r.Web||(r.Web={})),(function(n){n.REWARD_IN_PROGRESS="reward-in-progress",n.REWARD_ASSIGNED="reward-assigned",n.CAMPAIGN_OUT_OF_FUNDS="campaign-out-of-funds",n.CAMPAIGN_GAS_PRICE_HIGHER_THAN_EXPECTED="campaign-gas-price-higher-than-expected",n.CAMPAIGN_OUT_OF_STOCK="campaign-out-of-stock",n.REWARD_DELAYED="reward-delayed"})(r.Rewards||(r.Rewards={})),(function(n){n.GRANTED="badge-granted"})(r.Badge||(r.Badge={})),(function(n){n.CONVERTED="converted",n.MANUALLY_QUEUED="manually-queued"})(r.AssetBundle||(r.AssetBundle={})),(function(n){n.FRIENDSHIP_REQUEST="friendship-request",n.FRIENDSHIP_ACCEPTED="friendship-accepted"})(r.SocialService||(r.SocialService={})),(function(n){n.CREDITS_GOAL_COMPLETED="credits-goal-completed",n.COMPLETE_GOALS_REMINDER="complete-goals-reminder",n.CLAIM_CREDITS_REMINDER="claim-credits-reminder",n.DO_NOT_MISS_OUT_REMINDER="do-not-miss-out-reminder",n.USAGE_REMINDER="usage-reminder",n.USAGE_24_HOURS_REMINDER="usage-24-hours-reminder",n.ON_DEMAND_CREDITS_GRANTED="on-demand-credits-granted",n.NEW_SEASON_REMINDER="new-season-reminder"})(r.CreditsService||(r.CreditsService={})),(function(n){n.STREAMING_KEY_RESET="streaming-key-reset",n.STREAMING_KEY_REVOKE="streaming-key-revoke",n.STREAMING_KEY_EXPIRED="streaming-key-expired",n.STREAMING_TIME_EXCEEDED="streaming-time-exceeded",n.STREAMING_PLACE_UPDATED="streaming-place-updated",n.COMMUNITY_STREAMING_ENDED="community-streaming-ended"})(r.Streaming||(r.Streaming={})),(function(n){n.USER_JOINED_ROOM="user-joined-room",n.USER_LEFT_ROOM="user-left-room",n.USER_BANNED_FROM_SCENE="user-banned-from-scene",n.USER_UNBANNED_FROM_SCENE="user-unbanned-from-scene"})(r.Comms||(r.Comms={})),(function(n){n.REFERRAL_INVITED_USERS_ACCEPTED="referral-invited-users-accepted",n.REFERRAL_NEW_TIER_REACHED="referral-new-tier-reached"})(r.Referral||(r.Referral={})),(function(n){n.DELETED="community-deleted",n.DELETED_CONTENT_VIOLATION="community-deleted-content-violation",n.RENAMED="community-renamed",n.MEMBER_BANNED="community-member-banned",n.MEMBER_LEFT="community-member-left",n.MEMBER_REMOVED="community-member-removed",n.REQUEST_TO_JOIN_RECEIVED="community-request-to-join-received",n.REQUEST_TO_JOIN_ACCEPTED="community-request-to-join-accepted",n.INVITE_RECEIVED="community-invite-received",n.OWNERSHIP_TRANSFERRED="community-ownership-transferred",n.POST_ADDED="community-post-added",n.VOICE_CHAT_STARTED="community-voice-chat-started"})(r.Community||(r.Community={})),(function(n){n.PHOTO_TAKEN="photo-taken",n.PHOTO_PRIVACY_CHANGED="photo-privacy-changed"})(r.Camera||(r.Camera={})),(function(n){n.EVENT_CREATED="event-created",n.EVENT_STARTS_SOON="event-starts-soon",n.EVENT_STARTED="event-started",n.EVENT_ENDED="event-ended",n.EVENT_APPROVED="event-approved",n.EVENT_REJECTED="event-rejected",n.EVENT_DELETED="event-deleted"})(r.Event||(r.Event={})),(function(n){n.PROPOSAL_ENACTED="governance_proposal_enacted",n.COAUTHOR_REQUESTED="governance_coauthor_requested",n.PITCH_PASSED="governance_pitch_passed",n.TENDER_PASSED="governance_tender_passed",n.AUTHORED_PROPOSAL_FINISHED="governance_authored_proposal_finished",n.VOTING_ENDED_VOTER="governance_voting_ended_voter",n.NEW_COMMENT_ON_PROPOSAL="governance_new_comment_on_proposal",n.NEW_COMMENT_ON_PROJECT_UPDATED="governance_new_comment_on_project_update",n.WHALE_VOTE="governance_whale_vote",n.VOTED_ON_BEHALF="governance_voted_on_behalf",n.CLIFF_ENDED="governance_cliff_ended"})(r.Governance||(r.Governance={})),(function(n){n.USER_BAN_CREATED="user-ban-created",n.USER_BAN_LIFTED="user-ban-lifted",n.USER_WARNING_CREATED="user-warning-created"})(r.Moderation||(r.Moderation={}))})(t.SubType||(t.SubType={}))})(e.Events||(e.Events={}))})(nf)),nf}var af={},yT;function oU(){return yT||(yT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TipReceivedEvent=e.TransferReceivedEvent=e.CollectionCreatedEvent=e.RoyaltiesEarnedEvent=e.RentalStartedEvent=e.RentalEndedEvent=e.ItemPublishedEvent=e.ItemSoldEvent=e.BidAcceptedEvent=void 0;const t=Oe(),r=lr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.BID_ACCEPTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},seller:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},price:{type:"string"},title:{type:"string"},description:{type:"string"},network:{type:"string"}},required:["address","image","seller","category","link","price","title","network"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.BidAcceptedEvent||(e.BidAcceptedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.ITEM_SOLD},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},buyer:{type:"string"},seller:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},tokenId:{type:"string"},network:{type:"string"},title:{type:"string"},description:{type:"string"}},required:["address","image","seller","category","link","network","title","description"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.ItemSoldEvent||(e.ItemSoldEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.ITEM_PUBLISHED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{creator:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},itemId:{type:"string"},network:{type:"string"},urn:{type:"string"}},required:["creator","category","itemId","network","urn"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.ItemPublishedEvent||(e.ItemPublishedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.RENTAL_ENDED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},contract:{type:"string"},land:{type:"string",nullable:!0},lessor:{type:"string"},tenant:{type:"string"},operator:{type:"string"},startedAt:{type:"string"},endedAt:{type:"string"},tokenId:{type:"string"},link:{type:"string"},title:{type:"string"},description:{type:"string",nullable:!0}},required:["address","contract","lessor","tenant","operator","startedAt","endedAt","tokenId","link","title"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.RentalEndedEvent||(e.RentalEndedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.RENTAL_STARTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},contract:{type:"string"},land:{type:"string",nullable:!0},lessor:{type:"string"},tenant:{type:"string"},operator:{type:"string"},startedAt:{type:"string"},endedAt:{type:"string"},tokenId:{type:"string"},link:{type:"string"},title:{type:"string"},description:{type:"string",nullable:!0}},required:["address","contract","lessor","tenant","operator","startedAt","endedAt","tokenId","link","title"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.RentalStartedEvent||(e.RentalStartedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.ROYALTIES_EARNED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},royaltiesCut:{type:"string"},royaltiesCollector:{type:"string"},network:{type:"string"},title:{type:"string"},description:{type:"string",nullable:!0}},required:["address","image","category","link","royaltiesCut","royaltiesCollector","network","title"]}},required:["type","subType","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.RoyaltiesEarnedEvent||(e.RoyaltiesEarnedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.COLLECTION_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{creator:{type:"string"},name:{type:"string"}},required:["creator","name"]}},required:["type","subType","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CollectionCreatedEvent||(e.CollectionCreatedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.TRANSFER_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{senderAddress:{type:"string"},receiverAddress:{type:"string"},tokenUri:{type:"string",nullable:!0}},required:["senderAddress","receiverAddress"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.TransferReceivedEvent||(e.TransferReceivedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.TIP_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{senderAddress:{type:"string"},receiverAddress:{type:"string"},amount:{type:"string"}},required:["senderAddress","receiverAddress","amount"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.TipReceivedEvent||(e.TipReceivedEvent={}))})(af)),af}var sf={},gT;function uU(){return gT||(gT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CatalystDeploymentEvent=void 0;const t=Oo(),r=Oe(),n=qN(),i=lr();(function(a){a.schema={type:"object",properties:{type:{type:"string",const:i.Events.Type.CATALYST_DEPLOYMENT},subType:{type:"string",enum:Object.values(i.Events.SubType.CatalystDeployment)},key:{type:"string"},timestamp:{type:"number",minimum:1},entity:n.Entity.schema,authChain:t.AuthChain.schema},required:["type","subType","entity","authChain","key","timestamp"],additionalProperties:!1},a.validate=(0,r.generateLazyValidator)(a.schema)})(e.CatalystDeploymentEvent||(e.CatalystDeploymentEvent={}))})(sf)),sf}var of={},_T;function cU(){return _T||(_T=1,Object.defineProperty(of,"__esModule",{value:!0})),of}var uf={},ET;function lU(){return ET||(ET=1,Object.defineProperty(uf,"__esModule",{value:!0})),uf}var cf={},vT;function dU(){return vT||(vT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.BidReceivedEvent=void 0;const t=Oe(),r=lr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MARKETPLACE},subType:{type:"string",const:r.Events.SubType.Marketplace.BID_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},seller:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},price:{type:"string"},title:{type:"string"},description:{type:"string"},network:{type:"string"}},required:["address","image","seller","category","link","price","title","network"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.BidReceivedEvent||(e.BidReceivedEvent={}))})(cf)),cf}var lf={},ds={},bT;function El(){if(bT)return ds;bT=1,Object.defineProperty(ds,"__esModule",{value:!0}),ds.createEventSchema=void 0;function e(t,r,n){return{type:"object",properties:{type:{type:"string",const:t},subType:{type:"string",const:r},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:n},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1}}return ds.createEventSchema=e,ds}var TT;function fU(){return TT||(TT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.RewardDelayedEvent=e.CampaignOutOfStockEvent=e.CampaignGasPriceHigherThanExpectedEvent=e.CampaignOutOfFundsEvent=e.RewardAssignedEvent=e.RewardInProgressEvent=void 0;const t=Oe(),r=lr(),n=El(),i={type:"object",properties:{title:{type:"string"},description:{type:"string"},link:{type:"string",nullable:!0},beneficiary:{type:"string"},tokenName:{type:"string"},tokenImage:{type:"string"},tokenRarity:{type:"string",nullable:!0},tokenCategory:{type:"string",nullable:!0}},required:["title","description","beneficiary","tokenName","tokenImage"],additionalProperties:!1},a={type:"object",properties:{title:{type:"string"},description:{type:"string"},link:{type:"string",nullable:!0},owner:{type:"string"},campaignId:{type:"string"},campaignName:{type:"string"}},required:["title","description","owner","campaignId","campaignName"],additionalProperties:!1};(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.REWARD_IN_PROGRESS,i),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.RewardInProgressEvent||(e.RewardInProgressEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.REWARD_ASSIGNED,i),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.RewardAssignedEvent||(e.RewardAssignedEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.CAMPAIGN_OUT_OF_FUNDS,a),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.CampaignOutOfFundsEvent||(e.CampaignOutOfFundsEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.CAMPAIGN_GAS_PRICE_HIGHER_THAN_EXPECTED,a),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.CampaignGasPriceHigherThanExpectedEvent||(e.CampaignGasPriceHigherThanExpectedEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.CAMPAIGN_OUT_OF_STOCK,a),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.CampaignOutOfStockEvent||(e.CampaignOutOfStockEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.REWARD_DELAYED,i),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.RewardDelayedEvent||(e.RewardDelayedEvent={}))})(lf)),lf}var df={},ST;function pU(){return ST||(ST=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CreditsClaimReminderEvent=e.CreditsDoNotMissOutReminderEvent=e.CreditsUsage24HoursReminderEvent=e.CreditsNewSeasonReminderEvent=e.CreditsUsageReminderEvent=e.CreditsCompleteGoalsReminderEvent=e.CreditsGoalCompletedEvent=e.CreditsOnDemandEvent=e.FriendshipAcceptedEvent=e.FriendshipRequestEvent=e.AssetBundleConversionManuallyQueuedEvent=e.AssetBundleConversionFinishedEvent=e.BadgeGrantedEvent=void 0;const t=Oe(),r=lr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BADGE},subType:{type:"string",const:r.Events.SubType.Badge.GRANTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{badgeId:{type:"string"},badgeTierName:{type:"string",nullable:!0},badgeName:{type:"string"},badgeImageUrl:{type:"string"},address:{type:"string"}},required:["badgeId","badgeName","badgeImageUrl","address"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.BadgeGrantedEvent||(e.BadgeGrantedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.ASSET_BUNDLE},subType:{type:"string",const:r.Events.SubType.AssetBundle.CONVERTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{entityId:{type:"string"},platform:{type:"string",enum:["windows","mac","webgl"]},statusCode:{type:"number"},isLods:{type:"boolean"},isWorld:{type:"boolean"},version:{type:"string"}},required:["entityId","platform","statusCode","isLods","isWorld","version"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.AssetBundleConversionFinishedEvent||(e.AssetBundleConversionFinishedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.ASSET_BUNDLE},subType:{type:"string",const:r.Events.SubType.AssetBundle.MANUALLY_QUEUED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{entityId:{type:"string"},platform:{type:"string",enum:["windows","mac","webgl"]},isLods:{type:"boolean"},isPriority:{type:"boolean"},version:{type:"string"}},required:["entityId","platform","isLods"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.AssetBundleConversionManuallyQueuedEvent||(e.AssetBundleConversionManuallyQueuedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.SOCIAL_SERVICE},subType:{type:"string",const:r.Events.SubType.SocialService.FRIENDSHIP_REQUEST},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{requestId:{type:"string"},sender:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]},receiver:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]},message:{type:"string",nullable:!0}},required:["requestId","sender","receiver"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.FriendshipRequestEvent||(e.FriendshipRequestEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.SOCIAL_SERVICE},subType:{type:"string",const:r.Events.SubType.SocialService.FRIENDSHIP_ACCEPTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{requestId:{type:"string"},sender:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]},receiver:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]}},required:["requestId","sender","receiver"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.FriendshipAcceptedEvent||(e.FriendshipAcceptedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.ON_DEMAND_CREDITS_GRANTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{creditsGranted:{type:"number",minimum:1},address:{type:"string"},granterAddress:{type:"string"}},required:["creditsGranted","address","granterAddress"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsOnDemandEvent||(e.CreditsOnDemandEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.CREDITS_GOAL_COMPLETED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{goalId:{type:"string"},creditsObtained:{type:"number",minimum:0},seasonId:{type:"number",minimum:1},weekNumber:{type:"number",minimum:1},address:{type:"string"}},required:["goalId","creditsObtained","seasonId","weekNumber","address"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsGoalCompletedEvent||(e.CreditsGoalCompletedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.COMPLETE_GOALS_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},seasonId:{type:"number",minimum:1},weekNumber:{type:"number",minimum:1},pendingGoalIds:{type:"array",items:{type:"string"},minItems:1}},required:["address","seasonId","weekNumber","pendingGoalIds"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsCompleteGoalsReminderEvent||(e.CreditsCompleteGoalsReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.USAGE_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},creditsAmount:{type:"number",minimum:1},expirationDate:{type:"string"},expirationDay:{type:"string"}},required:["address","creditsAmount","expirationDate","expirationDay"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsUsageReminderEvent||(e.CreditsUsageReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.NEW_SEASON_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{addresses:{type:"array",items:{type:"string"}},seasonName:{type:"string"},startDate:{type:"string"},endDate:{type:"string"}},required:["addresses","seasonName","startDate","endDate"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsNewSeasonReminderEvent||(e.CreditsNewSeasonReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.USAGE_24_HOURS_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},creditsAmount:{type:"number",minimum:1},expirationDate:{type:"string"}},required:["address","creditsAmount","expirationDate"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsUsage24HoursReminderEvent||(e.CreditsUsage24HoursReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.DO_NOT_MISS_OUT_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"}},required:["address"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsDoNotMissOutReminderEvent||(e.CreditsDoNotMissOutReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.CLAIM_CREDITS_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},seasonId:{type:"number",minimum:1},weekNumber:{type:"number",minimum:1}},required:["address","seasonId","weekNumber"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsClaimReminderEvent||(e.CreditsClaimReminderEvent={}))})(df)),df}var ff={},IT;function mU(){return IT||(IT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CommunityStreamingEndedEvent=e.StreamingPlaceUpdatedEvent=e.StreamingTimeExceededEvent=e.StreamingKeyExpiredEvent=e.StreamingKeyRevokeEvent=e.StreamingKeyResetEvent=void 0;const t=Oe(),r=lr(),n=El(),i={type:"object",properties:{title:{type:"string"},description:{type:"string"},position:{type:"string"},worldName:{type:"string",nullable:!0},isWorld:{type:"boolean"},url:{type:"string"},address:{type:"string"},image:{type:"string"}},required:["position","isWorld","url","title","description","address","image"],additionalProperties:!1};(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_KEY_RESET,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingKeyResetEvent||(e.StreamingKeyResetEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_KEY_REVOKE,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingKeyRevokeEvent||(e.StreamingKeyRevokeEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_KEY_EXPIRED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingKeyExpiredEvent||(e.StreamingKeyExpiredEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_TIME_EXCEEDED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingTimeExceededEvent||(e.StreamingTimeExceededEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_PLACE_UPDATED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingPlaceUpdatedEvent||(e.StreamingPlaceUpdatedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.COMMUNITY_STREAMING_ENDED,{type:"object",properties:{communityId:{type:"string"},totalParticipants:{type:"number"}},required:["communityId","totalParticipants"],additionalProperties:!1}),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.CommunityStreamingEndedEvent||(e.CommunityStreamingEndedEvent={}))})(ff)),ff}var pf={},RT;function hU(){return RT||(RT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.UserUnbannedFromSceneEvent=e.UserBannedFromSceneEvent=e.UserLeftRoomEvent=e.UserJoinedRoomEvent=e.RoomType=void 0;const t=Oe(),r=lr();var n;(function(i){i.PRIVATE_MESSAGE="private-message",i.VOICE_CHAT="voice-chat",i.COMMUNITY_VOICE_CHAT="community-voice-chat",i.ISLAND="island",i.SCENE="scene",i.WORLD="world",i.UNKNOWN="unknown"})(n=e.RoomType||(e.RoomType={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_JOINED_ROOM},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{parcel:{type:"string"},sceneId:{type:"string"},userAddress:{type:"string"},realmName:{type:"string"},islandName:{type:"string",nullable:!0},communityId:{type:"string",nullable:!0},voiceChatId:{type:"string",nullable:!0},isWorld:{type:"boolean"},roomType:{type:"string",enum:Object.values(n)}},required:["parcel","sceneId","userAddress","realmName","isWorld","roomType"]}},required:["type","subType","key","timestamp","metadata"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserJoinedRoomEvent||(e.UserJoinedRoomEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_LEFT_ROOM},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{userAddress:{type:"string"},realmName:{type:"string"},isWorld:{type:"boolean"},roomType:{type:"string",enum:Object.values(n)},sceneId:{type:"string",nullable:!0},islandName:{type:"string",nullable:!0},communityId:{type:"string",nullable:!0},voiceChatId:{type:"string",nullable:!0}},required:["isWorld","userAddress","realmName","roomType"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserLeftRoomEvent||(e.UserLeftRoomEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_BANNED_FROM_SCENE},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{placeTitle:{type:"string"},userAddress:{type:"string"}},required:["placeTitle","userAddress"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserBannedFromSceneEvent||(e.UserBannedFromSceneEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_UNBANNED_FROM_SCENE},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{placeTitle:{type:"string"},userAddress:{type:"string"}},required:["placeTitle","userAddress"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserUnbannedFromSceneEvent||(e.UserUnbannedFromSceneEvent={}))})(pf)),pf}var mf={},AT;function yU(){return AT||(AT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ReferralNewTierReachedEvent=e.ReferralInvitedUsersAcceptedEvent=void 0;const t=Oe(),r=lr(),n=El(),i={type:"object",properties:{title:{type:"string"},description:{type:"string"},address:{type:"string"},tier:{type:"number",minimum:1},url:{type:"string"},image:{type:"string"},invitedUserAddress:{type:"string"},invitedUsers:{type:"number",minimum:1},rarity:{type:"string",nullable:!0}},required:["address","tier","url","title","description","image","invitedUserAddress"],additionalProperties:!1};(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.REFERRAL,r.Events.SubType.Referral.REFERRAL_INVITED_USERS_ACCEPTED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.ReferralInvitedUsersAcceptedEvent||(e.ReferralInvitedUsersAcceptedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.REFERRAL,r.Events.SubType.Referral.REFERRAL_NEW_TIER_REACHED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.ReferralNewTierReachedEvent||(e.ReferralNewTierReachedEvent={}))})(mf)),mf}var hf={},wT;function gU(){return wT||(wT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CommunityVoiceChatStartedEvent=e.CommunityOwnershipTransferredEvent=e.CommunityPostAddedEvent=e.CommunityInviteReceivedEvent=e.CommunityRequestToJoinAcceptedEvent=e.CommunityRequestToJoinReceivedEvent=e.CommunityMemberRemovedEvent=e.CommunityMemberLeftEvent=e.CommunityMemberBannedEvent=e.CommunityRenamedEvent=e.CommunityDeletedContentViolationEvent=e.CommunityDeletedEvent=void 0;const t=Oe(),r=lr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.DELETED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},memberAddresses:{type:"array",items:{type:"string"}},thumbnailUrl:{type:"string"}},required:["id","name","memberAddresses","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityDeletedEvent||(e.CommunityDeletedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.DELETED_CONTENT_VIOLATION},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},ownerAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["id","name","ownerAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityDeletedContentViolationEvent||(e.CommunityDeletedContentViolationEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.RENAMED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},oldName:{type:"string"},newName:{type:"string"},memberAddresses:{type:"array",items:{type:"string"}},thumbnailUrl:{type:"string"}},required:["id","oldName","newName","memberAddresses","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityRenamedEvent||(e.CommunityRenamedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.MEMBER_BANNED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["id","name","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityMemberBannedEvent||(e.CommunityMemberBannedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.MEMBER_LEFT},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},memberAddress:{type:"string"}},required:["id","memberAddress"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityMemberLeftEvent||(e.CommunityMemberLeftEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.MEMBER_REMOVED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["id","name","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityMemberRemovedEvent||(e.CommunityMemberRemovedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.REQUEST_TO_JOIN_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},memberAddress:{type:"string"},memberName:{type:"string"},thumbnailUrl:{type:"string"},addressesToNotify:{type:"array",items:{type:"string"}}},required:["communityId","communityName","memberAddress","memberName","thumbnailUrl","addressesToNotify"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityRequestToJoinReceivedEvent||(e.CommunityRequestToJoinReceivedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.REQUEST_TO_JOIN_ACCEPTED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["communityId","communityName","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityRequestToJoinAcceptedEvent||(e.CommunityRequestToJoinAcceptedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.INVITE_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["communityId","communityName","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityInviteReceivedEvent||(e.CommunityInviteReceivedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.POST_ADDED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},thumbnailUrl:{type:"string"},postId:{type:"string"},authorAddress:{type:"string"},addressesToNotify:{type:"array",items:{type:"string"}}},required:["addressesToNotify","communityId","communityName","thumbnailUrl","postId","authorAddress"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityPostAddedEvent||(e.CommunityPostAddedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.OWNERSHIP_TRANSFERRED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},oldOwnerAddress:{type:"string"},newOwnerAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["communityId","communityName","oldOwnerAddress","newOwnerAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityOwnershipTransferredEvent||(e.CommunityOwnershipTransferredEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.VOICE_CHAT_STARTED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},thumbnailUrl:{type:"string"},addressesToNotify:{type:"array",items:{type:"string"}}},required:["communityId","communityName","thumbnailUrl","addressesToNotify"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityVoiceChatStartedEvent||(e.CommunityVoiceChatStartedEvent={}))})(hf)),hf}var yf={},OT;function _U(){return OT||(OT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PhotoTakenEvent=e.PhotoPrivacyChangedEvent=void 0;const t=Oe(),r=lr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CAMERA},subType:{type:"string",const:r.Events.SubType.Camera.PHOTO_PRIVACY_CHANGED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{userAddress:{type:"string"},photoId:{type:"string"},isPublic:{type:"boolean"}},required:["userAddress","photoId","isPublic"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.PhotoPrivacyChangedEvent||(e.PhotoPrivacyChangedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CAMERA},subType:{type:"string",const:r.Events.SubType.Camera.PHOTO_TAKEN},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{sceneId:{type:"string"},userAddress:{type:"string"},realm:{type:"string"},photoId:{type:"string"},isPublic:{type:"boolean"},users:{type:"array",items:{type:"object",properties:{address:{type:"string"},isEmoting:{type:"boolean"}},required:["address","isEmoting"],additionalProperties:!1}},placeId:{type:"string",nullable:!0}},required:["userAddress","realm","photoId","isPublic","users"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.PhotoTakenEvent||(e.PhotoTakenEvent={}))})(yf)),yf}var gf={},NT;function EU(){return NT||(NT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EventDeletedEvent=e.EventRejectedEvent=e.EventApprovedEvent=e.EventEndedEvent=e.EventCreatedEvent=e.EventStartsSoonEvent=e.EventStartedEvent=void 0;const t=Oe(),r=lr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_STARTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string"},image:{type:"string"},link:{type:"string"},communityId:{type:"string"},communityThumbnail:{type:"string",nullable:!0},title:{type:"string"},description:{type:"string"},attendee:{type:"string"}},required:["name","image","link"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventStartedEvent||(e.EventStartedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_STARTS_SOON},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string"},image:{type:"string"},link:{type:"string"},startsAt:{type:"string"},endsAt:{type:"string"},title:{type:"string"},description:{type:"string"},attendee:{type:"string"}},required:["name","image","link","startsAt","endsAt"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventStartsSoonEvent||(e.EventStartsSoonEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string"},image:{type:"string"},communityId:{type:"string"},communityName:{type:"string"},communityThumbnail:{type:"string",nullable:!0},title:{type:"string"},description:{type:"string"},attendee:{type:"string"}},required:["name","image"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventCreatedEvent||(e.EventCreatedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_ENDED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{communityId:{type:"string",nullable:!0},totalAttendees:{type:"number"}},required:["totalAttendees"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventEndedEvent||(e.EventEndedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_APPROVED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{host:{type:"string"},title:{type:"string"},description:{type:"string"},image:{type:"string"},link:{type:"string"}},required:["host","title","image","link"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventApprovedEvent||(e.EventApprovedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_REJECTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{host:{type:"string"},title:{type:"string"},description:{type:"string"},image:{type:"string"},reason:{type:"string"}},required:["host","title","image","reason"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventRejectedEvent||(e.EventRejectedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_DELETED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{host:{type:"string"},title:{type:"string"},description:{type:"string"},image:{type:"string"},reason:{type:"string",nullable:!0}},required:["host","title","image"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventDeletedEvent||(e.EventDeletedEvent={}))})(gf)),gf}var _f={},PT;function vU(){return PT||(PT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.GovernanceCliffEndedEvent=e.GovernanceVotedOnBehalfEvent=e.GovernanceWhaleVoteEvent=e.GovernanceNewCommentOnProjectUpdatedEvent=e.GovernanceNewCommentOnProposalEvent=e.GovernanceVotingEndedVoterEvent=e.GovernanceAuthoredProposalFinishedEvent=e.GovernanceTenderPassedEvent=e.GovernancePitchPassedEvent=e.GovernanceCoauthorRequestedEvent=e.GovernanceProposalEnactedEvent=void 0;const t=Oe(),r=lr(),n=El(),i={type:"object",properties:{proposalId:{type:"string"},proposalTitle:{type:"string"},title:{type:"string"},description:{type:"string"},link:{type:"string"},address:{type:"string"}},required:["proposalId","proposalTitle","title","description","link","address"],additionalProperties:!1};(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.PROPOSAL_ENACTED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceProposalEnactedEvent||(e.GovernanceProposalEnactedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.COAUTHOR_REQUESTED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceCoauthorRequestedEvent||(e.GovernanceCoauthorRequestedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.PITCH_PASSED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernancePitchPassedEvent||(e.GovernancePitchPassedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.TENDER_PASSED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceTenderPassedEvent||(e.GovernanceTenderPassedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.AUTHORED_PROPOSAL_FINISHED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceAuthoredProposalFinishedEvent||(e.GovernanceAuthoredProposalFinishedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.VOTING_ENDED_VOTER,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceVotingEndedVoterEvent||(e.GovernanceVotingEndedVoterEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.NEW_COMMENT_ON_PROPOSAL,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceNewCommentOnProposalEvent||(e.GovernanceNewCommentOnProposalEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.NEW_COMMENT_ON_PROJECT_UPDATED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceNewCommentOnProjectUpdatedEvent||(e.GovernanceNewCommentOnProjectUpdatedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.WHALE_VOTE,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceWhaleVoteEvent||(e.GovernanceWhaleVoteEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.VOTED_ON_BEHALF,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceVotedOnBehalfEvent||(e.GovernanceVotedOnBehalfEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.CLIFF_ENDED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceCliffEndedEvent||(e.GovernanceCliffEndedEvent={}))})(_f)),_f}var Ef={},MT;function bU(){return MT||(MT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WorldsMissingResourcesEvent=e.WorldsAccessRestrictedEvent=e.WorldsPermissionGrantedEvent=e.WorldsPermissionRevokedEvent=e.WorldsAccessRestoredEvent=e.WorldDeploymentEvent=e.WorldUndeploymentEvent=e.WorldScenesUndeploymentEvent=e.WorldSpawnCoordinateSetEvent=e.WorldSettingsChangedEvent=void 0;const t=Oo(),r=Oe(),n=lr();(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_SETTINGS_CHANGED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{worldName:{type:"string"},title:{type:"string",nullable:!0},description:{type:"string",nullable:!0},contentRating:{type:"string",nullable:!0},skyboxTime:{type:"number",nullable:!0},categories:{type:"array",items:{type:"string"},nullable:!0},singlePlayer:{type:"boolean",nullable:!0},showInPlaces:{type:"boolean",nullable:!0},thumbnailUrl:{type:"string",nullable:!0},accessType:{type:"string",nullable:!0}},required:["worldName"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1}})(e.WorldSettingsChangedEvent||(e.WorldSettingsChangedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_SPAWN_COORDINATE_SET},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string",pattern:"^[a-zA-Z0-9_-]+\\.dcl\\.eth|[a-zA-Z0-9_-]+\\.eth$"},oldCoordinate:{type:"object",properties:{x:{type:"number"},y:{type:"number"}},required:["x","y"],additionalProperties:!1,nullable:!0},newCoordinate:{type:"object",properties:{x:{type:"number"},y:{type:"number"}},required:["x","y"],additionalProperties:!1}},required:["name","oldCoordinate","newCoordinate"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldSpawnCoordinateSetEvent||(e.WorldSpawnCoordinateSetEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_SCENES_UNDEPLOYMENT},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{worldName:{type:"string"},scenes:{type:"array",items:{type:"object",properties:{entityId:{type:"string"},baseParcel:{type:"string"}},required:["entityId","baseParcel"],additionalProperties:!1},minItems:1}},required:["worldName","scenes"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldScenesUndeploymentEvent||(e.WorldScenesUndeploymentEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_UNDEPLOYMENT},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{worldName:{type:"string"}},required:["worldName"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldUndeploymentEvent||(e.WorldUndeploymentEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.DEPLOYMENT},key:{type:"string"},timestamp:{type:"number",minimum:0},entity:{type:"object",properties:{entityId:{type:"string"},authChain:t.AuthChain.schema},additionalProperties:!0,required:["entityId","authChain"]},contentServerUrls:{type:"array",items:{type:"string"},nullable:!0},force:{type:"boolean",nullable:!0},animation:{type:"string",nullable:!0},lods:{type:"array",items:{type:"string"},nullable:!0}},required:["type","subType","key","timestamp","entity"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldDeploymentEvent||(e.WorldDeploymentEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_ACCESS_RESTORED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},url:{type:"string"},attendee:{type:"string"}},required:["title","description","url","attendee"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsAccessRestoredEvent||(e.WorldsAccessRestoredEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_PERMISSION_REVOKED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},world:{type:"string"},permissions:{type:"array",items:{type:"string"}},url:{type:"string"},address:{type:"string"}},required:["title","description","world","permissions","url","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsPermissionRevokedEvent||(e.WorldsPermissionRevokedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_PERMISSION_GRANTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},world:{type:"string"},permissions:{type:"array",items:{type:"string"}},url:{type:"string"},address:{type:"string"}},required:["title","description","world","permissions","url","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsPermissionGrantedEvent||(e.WorldsPermissionGrantedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_ACCESS_RESTRICTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},when:{type:"number"},address:{type:"string"}},required:["title","description","when","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsAccessRestrictedEvent||(e.WorldsAccessRestrictedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_MISSING_RESOURCES},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},url:{type:"string"},when:{type:"number"},address:{type:"string"}},required:["title","description","url","when","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsMissingResourcesEvent||(e.WorldsMissingResourcesEvent={}))})(Ef)),Ef}var vf={},CT;function TU(){return CT||(CT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.UserWarningCreatedEvent=e.UserBanLiftedEvent=e.UserBanCreatedEvent=void 0;const t=Oe(),r=lr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MODERATION},subType:{type:"string",const:r.Events.SubType.Moderation.USER_BAN_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{id:{type:"string"},bannedAddress:{type:"string"},bannedBy:{type:"string"},reason:{type:"string"},bannedAt:{type:"number",minimum:0},expiresAt:{type:"number",nullable:!0,minimum:0},customMessage:{type:"string",nullable:!0}},required:["id","bannedAddress","bannedBy","reason","bannedAt","expiresAt"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.UserBanCreatedEvent||(e.UserBanCreatedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MODERATION},subType:{type:"string",const:r.Events.SubType.Moderation.USER_BAN_LIFTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{id:{type:"string"},bannedAddress:{type:"string"},liftedBy:{type:"string"},liftedAt:{type:"number",minimum:0}},required:["id","bannedAddress","liftedBy","liftedAt"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.UserBanLiftedEvent||(e.UserBanLiftedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MODERATION},subType:{type:"string",const:r.Events.SubType.Moderation.USER_WARNING_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{id:{type:"string"},warnedAddress:{type:"string"},warnedBy:{type:"string"},reason:{type:"string"},warnedAt:{type:"number",minimum:0}},required:["id","warnedAddress","warnedBy","reason","warnedAt"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.UserWarningCreatedEvent||(e.UserWarningCreatedEvent={}))})(vf)),vf}var DT;function SU(){return DT||(DT=1,(function(e){var t=ui&&ui.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=ui&&ui.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(lr(),e),r(oU(),e),r(uU(),e),r(cU(),e),r(lU(),e),r(dU(),e),r(fU(),e),r(pU(),e),r(mU(),e),r(hU(),e),r(yU(),e),r(gU(),e),r(_U(),e),r(EU(),e),r(vU(),e),r(bU(),e),r(TU(),e)})(ui)),ui}var jT;function Xg(){return jT||(jT=1,(function(e){var t=ri&&ri.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=ri&&ri.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(zB(),e),r(YB(),e),r($N(),e),r(Wg(),e),r(NN(),e),r(tU(),e),r(qN(),e),r(rU(),e),r(iU(),e),r(sU(),e),r(SU(),e)})(ri)),ri}var $T;function IU(){return $T||($T=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WearableJson=void 0;const t=gl(),r=na(),n=_l(),i=zg(),a=Oe(),s=Xg();(function(o){o.schema={type:"object",properties:{description:{type:"string"},rarity:Object.assign(Object.assign({},t.Rarity.schema),{nullable:!0}),name:{type:"string"},data:{type:"object",properties:{replaces:{type:"array",items:r.WearableCategory.schema},hides:{type:"array",items:r.WearableCategory.schema},tags:{type:"array",items:{type:"string",minLength:1}},representations:{type:"array",items:i.WearableRepresentation.schema,minItems:1},category:r.WearableCategory.schema,removesDefaultHiding:{type:"array",nullable:!0,items:s.HideableWearableCategory.schema},blockVrmExport:{type:"boolean",nullable:!0},outlineCompatible:{type:"boolean",nullable:!0},springBones:Object.assign(Object.assign({},n.SpringBonesData.schema),{nullable:!0})},required:["replaces","hides","tags","representations","category"]}},additionalProperties:!0,required:["description","name","data"]},o.validate=(0,a.generateLazyValidator)(o.schema)})(e.WearableJson||(e.WearableJson={}))})(fd)),fd}var LT;function RU(){return LT||(LT=1,(function(e){var t=ti&&ti.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=ti&&ti.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(HB(),e),r(IU(),e)})(ti)),ti}var qT;function AU(){return qT||(qT=1,(function(e){var t=Jn&&Jn.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Jn&&Jn.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(VB(),e),r(RU(),e)})(Jn)),Jn}var ci={},bf={},kT;function wU(){return kT||(kT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Account=e.AccountSortBy=void 0;const t=Oe();(function(r){r.MOST_SALES="most_sales",r.MOST_PURCHASES="most_purchases",r.MOST_SPENT="most_spent",r.MOST_EARNED="most_earned",r.MOST_ROYALTIES="most_royalties",r.MOST_COLLECTIONS="most_collections"})(e.AccountSortBy||(e.AccountSortBy={})),(function(r){r.schema={type:"object",properties:{id:{type:"string"},address:{type:"string"},sales:{type:"integer"},purchases:{type:"integer"},spent:{type:"string"},earned:{type:"string"},royalties:{type:"string"},collections:{type:"number"}},required:["id","address","sales","purchases","spent","earned","royalties","collections"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Account||(e.Account={}))})(bf)),bf}var Tf={},Sf={},BT;function FN(){return BT||(BT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getChainId=e.ChainName=void 0;const t=Oe(),r=Vr();var n;(function(a){a.ETHEREUM_MAINNET="Ethereum Mainnet",a.ETHEREUM_ROPSTEN="Ropsten",a.ETHEREUM_RINKEBY="Rinkeby",a.ETHEREUM_GOERLI="Goerli",a.ETHEREUM_KOVAN="Kovan",a.ETHEREUM_SEPOLIA="Sepolia",a.MATIC_MAINNET="Polygon",a.MATIC_MUMBAI="Mumbai",a.MATIC_AMOY="Amoy",a.AVALANCHE_MAINNET="Avalanche",a.BINANCE_MAINNET="Binance Smart Chain",a.ARBITRUM_MAINNET="Arbitrum",a.OPTIMISM_MAINNET="Optimism",a.FANTOM_MAINNET="Fantom"})(n=e.ChainName||(e.ChainName={}));function i(a){switch(a){case n.ETHEREUM_MAINNET:return r.ChainId.ETHEREUM_MAINNET;case n.ETHEREUM_ROPSTEN:return r.ChainId.ETHEREUM_ROPSTEN;case n.ETHEREUM_RINKEBY:return r.ChainId.ETHEREUM_RINKEBY;case n.ETHEREUM_GOERLI:return r.ChainId.ETHEREUM_GOERLI;case n.ETHEREUM_KOVAN:return r.ChainId.ETHEREUM_KOVAN;case n.ETHEREUM_SEPOLIA:return r.ChainId.ETHEREUM_SEPOLIA;case n.MATIC_MAINNET:return r.ChainId.MATIC_MAINNET;case n.MATIC_MUMBAI:return r.ChainId.MATIC_MUMBAI;case n.MATIC_AMOY:return r.ChainId.MATIC_AMOY;case n.AVALANCHE_MAINNET:return r.ChainId.AVALANCHE_MAINNET;case n.BINANCE_MAINNET:return r.ChainId.BSC_MAINNET;case n.ARBITRUM_MAINNET:return r.ChainId.ARBITRUM_MAINNET;case n.OPTIMISM_MAINNET:return r.ChainId.OPTIMISM_MAINNET;case n.FANTOM_MAINNET:return r.ChainId.FANTOM_MAINNET;default:return null}}e.getChainId=i,(function(a){a.schema={type:"string",enum:Object.values(a)},a.validate=(0,t.generateLazyValidator)(a.schema)})(n=e.ChainName||(e.ChainName={}))})(Sf)),Sf}var If={},UT;function Fr(){return UT||(UT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Network=void 0;const t=Oe();(function(r){r.ETHEREUM="ETHEREUM",r.MATIC="MATIC",r.AVALANCHE="AVALANCHE",r.BSC="BINANCE SMART CHAIN",r.OPTIMISM="OPTIMISM",r.ARBITRUM="ARBITRUM",r.FANTOM="FANTOM"})(e.Network||(e.Network={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Network||(e.Network={}))})(If)),If}var FT;function Vr(){return FT||(FT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getNetwork=e.getNetworkMapping=e.getURNProtocol=e.getChainName=e.ChainId=void 0;const t=Oe(),r=FN(),n=Fr();var i;(function(l){l[l.ETHEREUM_MAINNET=1]="ETHEREUM_MAINNET",l[l.ETHEREUM_ROPSTEN=3]="ETHEREUM_ROPSTEN",l[l.ETHEREUM_RINKEBY=4]="ETHEREUM_RINKEBY",l[l.ETHEREUM_GOERLI=5]="ETHEREUM_GOERLI",l[l.ETHEREUM_KOVAN=42]="ETHEREUM_KOVAN",l[l.ETHEREUM_SEPOLIA=11155111]="ETHEREUM_SEPOLIA",l[l.MATIC_MAINNET=137]="MATIC_MAINNET",l[l.MATIC_MUMBAI=80001]="MATIC_MUMBAI",l[l.MATIC_AMOY=80002]="MATIC_AMOY",l[l.BSC_MAINNET=56]="BSC_MAINNET",l[l.OPTIMISM_MAINNET=10]="OPTIMISM_MAINNET",l[l.ARBITRUM_MAINNET=42161]="ARBITRUM_MAINNET",l[l.FANTOM_MAINNET=250]="FANTOM_MAINNET",l[l.AVALANCHE_MAINNET=43114]="AVALANCHE_MAINNET"})(i=e.ChainId||(e.ChainId={}));function a(l){switch(l){case i.ETHEREUM_MAINNET:return r.ChainName.ETHEREUM_MAINNET;case i.ETHEREUM_ROPSTEN:return r.ChainName.ETHEREUM_ROPSTEN;case i.ETHEREUM_RINKEBY:return r.ChainName.ETHEREUM_RINKEBY;case i.ETHEREUM_GOERLI:return r.ChainName.ETHEREUM_GOERLI;case i.ETHEREUM_KOVAN:return r.ChainName.ETHEREUM_KOVAN;case i.ETHEREUM_SEPOLIA:return r.ChainName.ETHEREUM_SEPOLIA;case i.MATIC_MAINNET:return r.ChainName.MATIC_MAINNET;case i.MATIC_MUMBAI:return r.ChainName.MATIC_MUMBAI;case i.MATIC_AMOY:return r.ChainName.MATIC_AMOY;case i.BSC_MAINNET:return r.ChainName.BINANCE_MAINNET;case i.ARBITRUM_MAINNET:return r.ChainName.ARBITRUM_MAINNET;case i.OPTIMISM_MAINNET:return r.ChainName.OPTIMISM_MAINNET;case i.FANTOM_MAINNET:return r.ChainName.FANTOM_MAINNET;case i.AVALANCHE_MAINNET:return r.ChainName.AVALANCHE_MAINNET;default:return null}}e.getChainName=a;function s(l){switch(l){case i.ETHEREUM_MAINNET:return"ethereum";case i.ETHEREUM_ROPSTEN:return"ropsten";case i.ETHEREUM_RINKEBY:return"rinkeby";case i.ETHEREUM_GOERLI:return"goerli";case i.ETHEREUM_KOVAN:return"kovan";case i.ETHEREUM_SEPOLIA:return"sepolia";case i.MATIC_MAINNET:return"matic";case i.MATIC_MUMBAI:return"mumbai";case i.MATIC_AMOY:return"amoy";default:return""}}e.getURNProtocol=s;function o(l){const c={[n.Network.BSC]:i.BSC_MAINNET,[n.Network.OPTIMISM]:i.OPTIMISM_MAINNET,[n.Network.ARBITRUM]:i.ARBITRUM_MAINNET,[n.Network.FANTOM]:i.FANTOM_MAINNET,[n.Network.AVALANCHE]:i.AVALANCHE_MAINNET};switch(l){case i.ETHEREUM_MAINNET:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_MAINNET,[n.Network.MATIC]:i.MATIC_MAINNET},c);case i.ETHEREUM_ROPSTEN:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_ROPSTEN,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_RINKEBY:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_RINKEBY,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_GOERLI:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_GOERLI,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_KOVAN:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_KOVAN,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_SEPOLIA:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_SEPOLIA,[n.Network.MATIC]:i.MATIC_AMOY},c);case i.MATIC_MAINNET:return Object.assign({[n.Network.ETHEREUM]:i.MATIC_MAINNET,[n.Network.MATIC]:i.MATIC_MAINNET},c);case i.MATIC_MUMBAI:return Object.assign({[n.Network.ETHEREUM]:i.MATIC_MUMBAI,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.MATIC_AMOY:return Object.assign({[n.Network.ETHEREUM]:i.MATIC_AMOY,[n.Network.MATIC]:i.MATIC_AMOY},c);default:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_MAINNET,[n.Network.MATIC]:i.MATIC_MAINNET},c)}}e.getNetworkMapping=o;function u(l){switch(l){case i.ETHEREUM_MAINNET:case i.ETHEREUM_ROPSTEN:case i.ETHEREUM_GOERLI:case i.ETHEREUM_KOVAN:case i.ETHEREUM_RINKEBY:case i.ETHEREUM_SEPOLIA:return n.Network.ETHEREUM;case i.MATIC_MAINNET:case i.MATIC_MUMBAI:case i.MATIC_AMOY:return n.Network.MATIC;case i.BSC_MAINNET:return n.Network.BSC;case i.OPTIMISM_MAINNET:return n.Network.OPTIMISM;case i.ARBITRUM_MAINNET:return n.Network.ARBITRUM;case i.FANTOM_MAINNET:return n.Network.FANTOM;case i.AVALANCHE_MAINNET:return n.Network.AVALANCHE}}e.getNetwork=u,(function(l){l.schema={type:"number",enum:Object.values(l)},l.validate=(0,t.generateLazyValidator)(l.schema)})(i=e.ChainId||(e.ChainId={}))})(Tf)),Tf}var Rf={},VT;function OU(){return VT||(VT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Collection=e.CollectionSortBy=void 0;const t=Oe(),r=Vr(),n=Fr();(function(i){i.NEWEST="newest",i.NAME="name",i.RECENTLY_REVIEWED="recently_reviewed",i.RECENTLY_LISTED="recently_listed",i.SIZE="size"})(e.CollectionSortBy||(e.CollectionSortBy={})),(function(i){i.schema={type:"object",properties:{urn:{type:"string"},creator:{type:"string"},name:{type:"string"},contractAddress:{type:"string"},size:{type:"integer"},isOnSale:{type:"boolean"},createdAt:{type:"integer"},updatedAt:{type:"integer"},reviewedAt:{type:"integer"},network:n.Network.schema,chainId:r.ChainId.schema,firstListedAt:{type:"integer",nullable:!0}},required:["urn","creator","name","contractAddress","isOnSale","size","createdAt","updatedAt","reviewedAt","network","chainId"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.Collection||(e.Collection={}))})(Rf)),Rf}var Af={},wf={},HT;function vl(){return HT||(HT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.NFTCategory=void 0;const t=Oe();(function(r){r.PARCEL="parcel",r.ESTATE="estate",r.WEARABLE="wearable",r.ENS="ens",r.EMOTE="emote"})(e.NFTCategory||(e.NFTCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.NFTCategory||(e.NFTCategory={}))})(wf)),wf}var GT;function NU(){return GT||(GT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Contract=e.ContractSortBy=void 0;const t=Oe(),r=Vr(),n=Fr(),i=vl();(function(a){a.NAME="name"})(e.ContractSortBy||(e.ContractSortBy={})),(function(a){a.schema={type:"object",properties:{name:{type:"string"},address:{type:"string"},category:i.NFTCategory.schema,network:n.Network.schema,chainId:r.ChainId.schema},required:["name","address","category","network","chainId"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Contract||(e.Contract={}))})(Af)),Af}var Of={},Nf={},zT;function VN(){return zT||(zT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.NFT=e.NFTSortBy=void 0;const t=Oe(),r=Vr(),n=Xg(),i=Fr(),a=vl(),s=gl(),o=na();(function(u){u.NAME="name",u.NEWEST="newest",u.RECENTLY_LISTED="recently_listed",u.RECENTLY_SOLD="recently_sold",u.CHEAPEST="cheapest",u.RENTAL_LISTING_DATE="rental_listing_date",u.RENTAL_DATE="rented_date",u.MAX_RENTAL_PRICE="max_rental_price",u.MIN_RENTAL_PRICE="min_rental_price"})(e.NFTSortBy||(e.NFTSortBy={})),(function(u){u.schema={type:"object",properties:{id:{type:"string"},tokenId:{type:"string"},contractAddress:{type:"string"},activeOrderId:{type:"string",nullable:!0},utility:{type:"string",nullable:!0},openRentalId:{type:"string",nullable:!0},owner:{type:"string"},name:{type:"string"},image:{type:"string"},url:{type:"string"},data:{type:"object",nullable:!1,properties:{parcel:{type:"object",properties:{description:{type:["string"],nullable:!0},x:{type:"string"},y:{type:"string"},estate:{type:"object",properties:{tokenId:{type:"string"},name:{type:"string"}},required:["tokenId","name"],nullable:!0}},required:["description","x","y","estate"],nullable:!0},estate:{type:"object",properties:{description:{type:["string"],nullable:!0},size:{type:"integer"},parcels:{type:"array",items:{type:"object",properties:{x:{type:"number"},y:{type:"number"}},required:["x","y"]}}},required:["description","size","parcels"],nullable:!0},wearable:{type:"object",properties:{bodyShapes:{type:"array",items:n.BodyShape.schema},category:o.WearableCategory.schema,description:{type:"string"},rarity:s.Rarity.schema,isSmart:{type:"boolean"}},required:["bodyShapes","category","description","rarity","isSmart"],nullable:!0},ens:{type:"object",properties:{subdomain:{type:"string"}},required:["subdomain"],nullable:!0},emote:{type:"object",properties:{bodyShapes:{type:"array",items:n.BodyShape.schema},category:n.EmoteCategory.schema,description:{type:"string"},rarity:s.Rarity.schema,loop:{type:"boolean"},hasSound:{type:"boolean"},hasGeometry:{type:"boolean"},outcomeType:{type:"string",nullable:!0}},required:["bodyShapes","category","description","rarity","loop"],nullable:!0}},required:[]},issuedId:{type:"string",nullable:!0},itemId:{type:"string",nullable:!0},category:a.NFTCategory.schema,network:i.Network.schema,chainId:r.ChainId.schema,createdAt:{type:"integer"},updatedAt:{type:"integer"},soldAt:{type:"integer"},urn:{type:"string",nullable:!0}},required:["id","tokenId","contractAddress","activeOrderId","openRentalId","owner","name","image","url","data","issuedId","itemId","category","network","chainId","createdAt","updatedAt","soldAt"]},u.validate=(0,t.generateLazyValidator)(u.schema)})(e.NFT||(e.NFT={}))})(Nf)),Nf}var WT;function PU(){return WT||(WT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Item=e.ItemSortBy=void 0;const t=Oe(),r=Vr(),n=Fr(),i=VN(),a=vl();(function(s){s.NAME="name",s.NEWEST="newest",s.RECENTLY_REVIEWED="recently_reviewed",s.RECENTLY_SOLD="recently_sold",s.RECENTLY_LISTED="recently_listed",s.CHEAPEST="cheapest"})(e.ItemSortBy||(e.ItemSortBy={})),(function(s){s.schema={type:"object",properties:{id:{type:"string"},name:{type:"string"},thumbnail:{type:"string"},url:{type:"string"},category:a.NFTCategory.schema,contractAddress:{type:"string"},itemId:{type:"string"},rarity:{type:"string"},price:{type:"string"},available:{type:"integer"},isOnSale:{type:"boolean"},creator:{type:"string"},beneficiary:{type:"string",nullable:!0},tradeId:{type:"string",nullable:!0},tradeContractAddress:{type:"string",nullable:!0},data:i.NFT.schema.properties.data,network:n.Network.schema,chainId:r.ChainId.schema,urn:{type:"string"},createdAt:{type:"integer"},updatedAt:{type:"integer"},reviewedAt:{type:"integer"},soldAt:{type:"integer"},firstListedAt:{type:"integer",nullable:!0},picks:{type:"object",properties:{pickedByUser:{type:"boolean",nullable:!0},count:{type:"integer"}},required:["count"],nullable:!0},minPrice:{type:"string",nullable:!0},utility:{type:"string",nullable:!0},minListingPrice:{type:"string",nullable:!0},maxListingPrice:{type:"string",nullable:!0},listings:{type:"integer",nullable:!0},owners:{type:"integer",nullable:!0},tradeExpiresAt:{type:"integer",nullable:!0}},required:["id","name","thumbnail","url","category","contractAddress","itemId","rarity","price","available","isOnSale","creator","data","network","chainId","createdAt","updatedAt","soldAt"]},s.validate=(0,t.generateLazyValidator)(s.schema)})(e.Item||(e.Item={}))})(Of)),Of}var Pf={},YT;function Qg(){return YT||(YT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ListingStatus=void 0;const t=Oe();(function(r){r.OPEN="open",r.SOLD="sold",r.CANCELLED="cancelled"})(e.ListingStatus||(e.ListingStatus={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.ListingStatus||(e.ListingStatus={}))})(Pf)),Pf}var Mf={},KT;function MU(){return KT||(KT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.MetaTransaction=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{from:{type:"string"},params:{type:"array",items:[{type:"string"},{type:"string"}],additionalItems:!1,minItems:2}},additionalProperties:!1,required:["from","params"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.MetaTransaction||(e.MetaTransaction={}))})(Mf)),Mf}var Cf={},JT;function CU(){return JT||(JT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Mint=e.MintSortBy=void 0;const t=Oe(),r=Vr(),n=Fr();(function(i){i.RECENTLY_MINTED="recently_minted",i.MOST_EXPENSIVE="most_expensive"})(e.MintSortBy||(e.MintSortBy={})),(function(i){i.schema={type:"object",properties:{id:{type:"string"},creator:{type:"string"},beneficiary:{type:"string"},minter:{type:"string"},price:{type:"string",nullable:!0},contractAddress:{type:"string"},tokenId:{type:"string"},itemId:{type:"string"},issuedId:{type:"string"},timestamp:{type:"integer"},network:n.Network.schema,chainId:r.ChainId.schema},required:["id","creator","beneficiary","minter","itemId","tokenId","issuedId","contractAddress","price","timestamp","network","chainId"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.Mint||(e.Mint={}))})(Cf)),Cf}var Df={},XT;function DU(){return XT||(XT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CatalogSortDirection=e.CatalogSortBy=void 0,(function(t){t.NEWEST="newest",t.RECENTLY_SOLD="recently_sold",t.CHEAPEST="cheapest",t.MOST_EXPENSIVE="most_expensive",t.RECENTLY_LISTED="recently_listed"})(e.CatalogSortBy||(e.CatalogSortBy={})),(function(t){t.ASC="asc",t.DESC="desc"})(e.CatalogSortDirection||(e.CatalogSortDirection={}))})(Df)),Df}var jf={},QT;function jU(){return QT||(QT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Order=e.OrderSortBy=void 0;const t=Oe(),r=Vr(),n=Qg(),i=Fr();(function(a){a.RECENTLY_LISTED="recently_listed",a.RECENTLY_UPDATED="recently_updated",a.CHEAPEST="cheapest",a.ISSUED_ID_ASC="issued_id_asc",a.ISSUED_ID_DESC="issued_id_desc",a.OLDEST="oldest"})(e.OrderSortBy||(e.OrderSortBy={})),(function(a){a.schema={type:"object",properties:{id:{type:"string"},marketplaceAddress:{type:"string"},contractAddress:{type:"string"},tokenId:{type:"string"},owner:{type:"string"},buyer:{type:["string"],nullable:!0},price:{type:"string"},status:n.ListingStatus.schema,network:i.Network.schema,chainId:r.ChainId.schema,expiresAt:{type:"integer"},createdAt:{type:"integer"},updatedAt:{type:"integer"},issuedId:{type:"string"},tradeId:{type:"string",nullable:!0}},required:["id","marketplaceAddress","contractAddress","tokenId","owner","buyer","price","status","network","chainId","expiresAt","createdAt","updatedAt"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Order||(e.Order={}))})(jf)),jf}var $f={},ZT;function $U(){return ZT||(ZT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProviderType=void 0;const t=Oe();(function(r){r.INJECTED="injected",r.MAGIC="magic",r.MAGIC_TEST="magic_test",r.FORTMATIC="formatic",r.NETWORK="network",r.WALLET_CONNECT="wallet_connect",r.WALLET_CONNECT_V2="wallet_connect_v2",r.WALLET_LINK="wallet_link",r.METAMASK_MOBILE="metamask_mobile",r.AUTH_SERVER="auth_server",r.THIRDWEB="thirdweb"})(e.ProviderType||(e.ProviderType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.ProviderType||(e.ProviderType={}))})($f)),$f}var Lf={},xT;function HN(){return xT||(xT=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SaleType=void 0;const t=Oe();(function(r){r.ORDER="order",r.BID="bid",r.MINT="mint"})(e.SaleType||(e.SaleType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.SaleType||(e.SaleType={}))})(Lf)),Lf}var qf={},eS;function LU(){return eS||(eS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Sale=e.SaleSortBy=void 0;const t=Oe(),r=Vr(),n=HN(),i=Fr();(function(a){a.RECENTLY_SOLD="recently_sold",a.MOST_EXPENSIVE="most_expensive"})(e.SaleSortBy||(e.SaleSortBy={})),(function(a){a.schema={type:"object",properties:{id:{type:"string"},type:n.SaleType.schema,buyer:{type:"string"},seller:{type:"string"},price:{type:"string"},contractAddress:{type:"string"},tokenId:{type:"string"},itemId:{type:"string"},txHash:{type:"string"},timestamp:{type:"integer"},network:i.Network.schema,chainId:r.ChainId.schema},required:["id","buyer","seller","itemId","tokenId","price","contractAddress","timestamp","txHash","network","chainId"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Sale||(e.Sale={}))})(qf)),qf}var kf={},tS;function qU(){return tS||(tS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.RentalListingCreation=e.PeriodCreation=e.RentalsListingsSortBy=e.RentalsListingsFilterByCategory=e.RentalsListingSortDirection=e.RentalStatus=void 0;const t=Oe(),r=Vr(),n=Fr();(function(a){a.OPEN="open",a.CANCELLED="cancelled",a.EXECUTED="executed",a.CLAIMED="claimed"})(e.RentalStatus||(e.RentalStatus={})),(function(a){a.ASC="asc",a.DESC="desc"})(e.RentalsListingSortDirection||(e.RentalsListingSortDirection={})),(function(a){a.PARCEL="parcel",a.ESTATE="estate"})(e.RentalsListingsFilterByCategory||(e.RentalsListingsFilterByCategory={})),(function(a){a.LAND_CREATION_DATE="land_creation_date",a.RENTAL_LISTING_DATE="rental_listing_date",a.RENTAL_DATE="rented_date",a.NAME="name",a.MAX_RENTAL_PRICE="max_rental_price",a.MIN_RENTAL_PRICE="min_rental_price"})(e.RentalsListingsSortBy||(e.RentalsListingsSortBy={}));var i;(function(a){a.schema={type:"object",properties:{minDays:{type:"integer",minimum:0,maximum:2147483647},maxDays:{type:"integer",minimum:0,maximum:2147483647},pricePerDay:{type:"string",pattern:"^[0-9]+$"}},additionalProperties:!1,required:["minDays","maxDays","pricePerDay"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(i=e.PeriodCreation||(e.PeriodCreation={})),(function(a){a.schema={type:"object",properties:{network:n.Network.schema,chainId:r.ChainId.schema,expiration:{type:"number",minimum:0},signature:{type:"string",minLength:1},tokenId:{type:"string",minLength:1},nonces:{type:"array",minItems:3,maxItems:3,items:{minLength:1,type:"string",pattern:"^[0-9]+$"}},contractAddress:{type:"string",pattern:"^0x[a-fA-F0-9]{40}$"},rentalContractAddress:{type:"string",pattern:"^0x[a-fA-F0-9]{40}$"},periods:{type:"array",minItems:1,maxItems:100,uniqueItems:!0,items:i.schema},target:{type:"string",pattern:"^0x[a-fA-F0-9]{40}$"}},additionalProperties:!1,required:["network","chainId","expiration","signature","nonces","tokenId","contractAddress","rentalContractAddress","periods","target"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.RentalListingCreation||(e.RentalListingCreation={}))})(kf)),kf}var Bf={},rS;function kU(){return rS||(rS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.AnalyticsDayDataSortBy=void 0,(function(t){t.DATE="date",t.MOST_SALES="most_sales"})(e.AnalyticsDayDataSortBy||(e.AnalyticsDayDataSortBy={}))})(Bf)),Bf}var Uf={},nS;function BU(){return nS||(nS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Store=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{id:{type:"string"},version:{type:"number"},owner:{type:"string"},description:{type:"string"},links:{type:"array",items:{type:"object",properties:{name:{type:"string"},url:{type:"string"}},required:["name","url"]}},images:{type:"array",items:{type:"object",properties:{name:{type:"string"},file:{type:"string"}},required:["name","file"]}}},required:["id","version","owner","description","links","images"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Store||(e.Store={}))})(Uf)),Uf}var Ff={},iS;function UU(){return iS||(iS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.GenderFilterOption=e.WearableGender=void 0;const t=Oe();(function(r){r.MALE="male",r.FEMALE="female"})(e.WearableGender||(e.WearableGender={})),(function(r){r.MALE="male",r.FEMALE="female",r.UNISEX="unisex"})(e.GenderFilterOption||(e.GenderFilterOption={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.WearableGender||(e.WearableGender={}))})(Ff)),Ff}var Vf={},aS;function FU(){return aS||(aS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.World=e.isInsideWorldLimits=e.getWorld=void 0;const t=Oe();function r(){return{validWorldRanges:[{xMin:-150,yMin:-150,xMax:150,yMax:150},{xMin:62,yMin:151,xMax:162,yMax:158},{xMin:151,yMin:144,xMax:162,yMax:150},{xMin:151,yMin:59,xMax:163,yMax:143}]}}e.getWorld=r;function n(i,a){const s=r().validWorldRanges;for(const o of s)if(i>=o.xMin&&i<=o.xMax&&a>=o.yMin&&a<=o.yMax)return!0;return!1}e.isInsideWorldLimits=n,(function(i){i.schema={type:"object",required:["validWorldRanges"],properties:{validWorldRanges:{type:"array",default:[{xMin:-150,yMin:-150,xMax:150,yMax:150}],items:{type:"object",required:["xMin","yMin","xMax","yMax"],properties:{xMin:{type:"integer"},yMin:{type:"integer"},xMax:{type:"integer"},yMax:{type:"integer"}}}}},additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.World||(e.World={}))})(Vf)),Vf}var Hf={},sS;function VU(){return sS||(sS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Bid=e.BidSortBy=void 0;const t=Oe(),r=Vr(),n=Qg(),i=Fr();(function(a){a.RECENTLY_OFFERED="recently_offered",a.RECENTLY_UPDATED="recently_updated",a.MOST_EXPENSIVE="most_expensive"})(e.BidSortBy||(e.BidSortBy={})),(function(a){const s={properties:{id:{type:"string"},bidder:{type:"string"},seller:{type:"string"},price:{type:"string"},fingerprint:{type:"string"},status:n.ListingStatus.schema,contractAddress:{type:"string"},network:i.Network.schema,chainId:r.ChainId.schema,expiresAt:{type:"integer"},createdAt:{type:"integer"},updatedAt:{type:"integer"}},required:["id","bidder","seller","price","fingerprint","status","contractAddress","network","chainId","expiresAt","createdAt","updatedAt"]};a.schema={type:"object",required:[],oneOf:[{properties:Object.assign(Object.assign({},s.properties),{tradeId:{type:"string"},tokenId:{type:"string"}}),required:[...s.required,"tradeId","tokenId"]},{type:"object",properties:Object.assign(Object.assign({},s.properties),{tradeId:{type:"string"},itemId:{type:"string"}}),required:[...s.required,"tradeId","itemId"]},{type:"object",properties:Object.assign(Object.assign({},s.properties),{bidAddress:{type:"string"},blockchainId:{type:"string"},blockNumber:{type:"string"},tokenId:{type:"string"}}),required:[...s.required,"bidAddress","blockchainId","blockNumber","tokenId"]}]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Bid||(e.Bid={}))})(Hf)),Hf}var Gf={},oS;function HU(){return oS||(oS=1,Object.defineProperty(Gf,"__esModule",{value:!0})),Gf}var zf={},uS;function GU(){return uS||(uS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TradeAssetDirection=e.TradeAssetType=e.TradeType=void 0,(function(t){t.BID="bid",t.PUBLIC_NFT_ORDER="public_nft_order",t.PUBLIC_ITEM_ORDER="public_item_order"})(e.TradeType||(e.TradeType={})),(function(t){t[t.ERC20=1]="ERC20",t[t.USD_PEGGED_MANA=2]="USD_PEGGED_MANA",t[t.ERC721=3]="ERC721",t[t.COLLECTION_ITEM=4]="COLLECTION_ITEM"})(e.TradeAssetType||(e.TradeAssetType={})),(function(t){t.SENT="sent",t.RECEIVED="received"})(e.TradeAssetDirection||(e.TradeAssetDirection={}))})(zf)),zf}var li={},Wf={},cS;function zU(){return cS||(cS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewCamera=void 0;const t=Oe();(function(r){r.STATIC="static",r.INTERACTIVE="interactive"})(e.PreviewCamera||(e.PreviewCamera={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewCamera||(e.PreviewCamera={}))})(Wf)),Wf}var Yf={},lS;function WU(){return lS||(lS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewUnityMode=void 0,(function(t){t.AUTH="authentication",t.BUILDER="builder",t.MARKETPLACE="marketplace",t.PROFILE="profile",t.CONFIG="configurator",t.JESUS="jesus"})(e.PreviewUnityMode||(e.PreviewUnityMode={}))})(Yf)),Yf}var Kf={},dS;function YU(){return dS||(dS=1,Object.defineProperty(Kf,"__esModule",{value:!0})),Kf}var Jf={},fS;function KU(){return fS||(fS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewEmoteEventType=void 0;const t=Oe();(function(r){r.ANIMATION_PLAY="animation_play",r.ANIMATION_PAUSE="animation_pause",r.ANIMATION_LOOP="animation_loop",r.ANIMATION_END="animation_end",r.ANIMATION_PLAYING="animation_playing"})(e.PreviewEmoteEventType||(e.PreviewEmoteEventType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewEmoteEventType||(e.PreviewEmoteEventType={}))})(Jf)),Jf}var Xf={},pS;function JU(){return pS||(pS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewEmote=void 0;const t=Oe();(function(r){r.IDLE="idle",r.WALK="walk",r.RUN="run",r.JUMP="jump",r.CLAP="clap",r.DAB="dab",r.DANCE="dance",r.FASHION="fashion",r.FASHION_2="fashion-2",r.FASHION_3="fashion-3",r.FASHION_4="fashion-4",r.LOVE="love",r.MONEY="money",r.FIST_PUMP="fist-pump",r.HEAD_EXPLODE="head-explode",r.WAVE="wave"})(e.PreviewEmote||(e.PreviewEmote={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewEmote||(e.PreviewEmote={}))})(Xf)),Xf}var Qf={},mS;function XU(){return mS||(mS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.sendMessage=e.PreviewRenderer=e.PreviewMessageType=void 0;const t=Oe();(function(n){n.READY="ready",n.LOAD="load",n.ERROR="error",n.UPDATE="update",n.CONTROLLER_REQUEST="controller_request",n.CONTROLLER_RESPONSE="controller_response",n.EMOTE_EVENT="emote_event"})(e.PreviewMessageType||(e.PreviewMessageType={})),(function(n){n.BABYLON="babylon",n.UNITY="unity"})(e.PreviewRenderer||(e.PreviewRenderer={})),(function(n){n.schema={type:"string",enum:Object.values(n)},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.PreviewMessageType||(e.PreviewMessageType={}));const r=(n,i,a,s="*")=>{const o={type:i,payload:a};n.postMessage(o,s)};e.sendMessage=r})(Qf)),Qf}var Zf={},hS;function QU(){return hS||(hS=1,Object.defineProperty(Zf,"__esModule",{value:!0})),Zf}var xf={},yS;function ZU(){return yS||(yS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewProjection=void 0;const t=Oe();(function(r){r.ORTHOGRAPHIC="orthographic",r.PERSPECTIVE="perspective"})(e.PreviewProjection||(e.PreviewProjection={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewProjection||(e.PreviewProjection={}))})(xf)),xf}var ep={},gS;function xU(){return gS||(gS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewType=void 0;const t=Oe();(function(r){r.TEXTURE="texture",r.WEARABLE="wearable",r.AVATAR="avatar"})(e.PreviewType||(e.PreviewType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewType||(e.PreviewType={}))})(ep)),ep}var tp={},_S;function eF(){return _S||(_S=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpringBoneParams=void 0;var t=_l();Object.defineProperty(e,"SpringBoneParams",{enumerable:!0,get:function(){return t.SpringBoneParams}})})(tp)),tp}var rp={},ES;function tF(){return ES||(ES=1,Object.defineProperty(rp,"__esModule",{value:!0})),rp}var np={},vS;function rF(){return vS||(vS=1,Object.defineProperty(np,"__esModule",{value:!0})),np}var ip={},bS;function nF(){return bS||(bS=1,Object.defineProperty(ip,"__esModule",{value:!0})),ip}var ap={},TS;function iF(){return TS||(TS=1,Object.defineProperty(ap,"__esModule",{value:!0})),ap}var sp={},SS;function aF(){return SS||(SS=1,Object.defineProperty(sp,"__esModule",{value:!0})),sp}var op={},IS;function sF(){return IS||(IS=1,Object.defineProperty(op,"__esModule",{value:!0})),op}var up={},RS;function oF(){return RS||(RS=1,Object.defineProperty(up,"__esModule",{value:!0})),up}var cp={},AS;function uF(){return AS||(AS=1,Object.defineProperty(cp,"__esModule",{value:!0})),cp}var wS;function cF(){return wS||(wS=1,(function(e){var t=li&&li.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=li&&li.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(zU(),e),r(WU(),e),r(YU(),e),r(KU(),e),r(JU(),e),r(XU(),e),r(QU(),e),r(ZU(),e),r(xU(),e),r(eF(),e),r(tF(),e),r(rF(),e),r(nF(),e),r(iF(),e),r(aF(),e),r(sF(),e),r(oF(),e),r(uF(),e)})(li)),li}var di={},fs={},OS;function lF(){if(OS)return fs;OS=1,Object.defineProperty(fs,"__esModule",{value:!0}),fs.isSysLink=void 0;const e=t=>t!==null&&typeof t=="object"&&"sys"in t&&"id"in t.sys;return fs.isSysLink=e,fs}var ps={},NS;function dF(){if(NS)return ps;NS=1,Object.defineProperty(ps,"__esModule",{value:!0}),ps.ContentfulLocale=void 0;var e;return(function(t){t.enUS="en-US",t.es="es",t.zh="zh"})(e||(e={})),ps.ContentfulLocale=e,ps}var lp={},PS;function fF(){return PS||(PS=1,Object.defineProperty(lp,"__esModule",{value:!0})),lp}var MS;function pF(){return MS||(MS=1,(function(e){var t=di&&di.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=di&&di.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(lF(),e),r(dF(),e),r(fF(),e)})(di)),di}var CS;function mF(){return CS||(CS=1,(function(e){var t=ci&&ci.__createBinding||(Object.create?(function(J,K,z,U){U===void 0&&(U=z);var F=Object.getOwnPropertyDescriptor(K,z);(!F||("get"in F?!K.__esModule:F.writable||F.configurable))&&(F={enumerable:!0,get:function(){return K[z]}}),Object.defineProperty(J,U,F)}):(function(J,K,z,U){U===void 0&&(U=z),J[U]=K[z]})),r=ci&&ci.__exportStar||function(J,K){for(var z in J)z!=="default"&&!Object.prototype.hasOwnProperty.call(K,z)&&t(K,J,z)};Object.defineProperty(e,"__esModule",{value:!0}),e.isInsideWorldLimits=e.getWorld=e.World=e.GenderFilterOption=e.WearableGender=e.Store=e.AnalyticsDayDataSortBy=e.PeriodCreation=e.RentalListingCreation=e.RentalsListingsSortBy=e.RentalsListingsFilterByCategory=e.RentalsListingSortDirection=e.RentalStatus=e.SaleSortBy=e.Sale=e.SaleType=e.Rarity=e.ProviderType=e.OrderSortBy=e.Order=e.CatalogSortDirection=e.CatalogSortBy=e.NFTSortBy=e.NFT=e.NFTCategory=e.Network=e.MintSortBy=e.Mint=e.MetaTransaction=e.ListingStatus=e.ItemSortBy=e.Item=e.ContractSortBy=e.Contract=e.CollectionSortBy=e.Collection=e.getChainId=e.ChainName=e.getURNProtocol=e.getChainName=e.ChainId=e.AccountSortBy=e.Account=void 0;var n=wU();Object.defineProperty(e,"Account",{enumerable:!0,get:function(){return n.Account}}),Object.defineProperty(e,"AccountSortBy",{enumerable:!0,get:function(){return n.AccountSortBy}});var i=Vr();Object.defineProperty(e,"ChainId",{enumerable:!0,get:function(){return i.ChainId}}),Object.defineProperty(e,"getChainName",{enumerable:!0,get:function(){return i.getChainName}}),Object.defineProperty(e,"getURNProtocol",{enumerable:!0,get:function(){return i.getURNProtocol}});var a=FN();Object.defineProperty(e,"ChainName",{enumerable:!0,get:function(){return a.ChainName}}),Object.defineProperty(e,"getChainId",{enumerable:!0,get:function(){return a.getChainId}});var s=OU();Object.defineProperty(e,"Collection",{enumerable:!0,get:function(){return s.Collection}}),Object.defineProperty(e,"CollectionSortBy",{enumerable:!0,get:function(){return s.CollectionSortBy}});var o=NU();Object.defineProperty(e,"Contract",{enumerable:!0,get:function(){return o.Contract}}),Object.defineProperty(e,"ContractSortBy",{enumerable:!0,get:function(){return o.ContractSortBy}});var u=PU();Object.defineProperty(e,"Item",{enumerable:!0,get:function(){return u.Item}}),Object.defineProperty(e,"ItemSortBy",{enumerable:!0,get:function(){return u.ItemSortBy}});var l=Qg();Object.defineProperty(e,"ListingStatus",{enumerable:!0,get:function(){return l.ListingStatus}});var c=MU();Object.defineProperty(e,"MetaTransaction",{enumerable:!0,get:function(){return c.MetaTransaction}});var d=CU();Object.defineProperty(e,"Mint",{enumerable:!0,get:function(){return d.Mint}}),Object.defineProperty(e,"MintSortBy",{enumerable:!0,get:function(){return d.MintSortBy}});var m=Fr();Object.defineProperty(e,"Network",{enumerable:!0,get:function(){return m.Network}});var p=vl();Object.defineProperty(e,"NFTCategory",{enumerable:!0,get:function(){return p.NFTCategory}});var E=VN();Object.defineProperty(e,"NFT",{enumerable:!0,get:function(){return E.NFT}}),Object.defineProperty(e,"NFTSortBy",{enumerable:!0,get:function(){return E.NFTSortBy}});var A=DU();Object.defineProperty(e,"CatalogSortBy",{enumerable:!0,get:function(){return A.CatalogSortBy}}),Object.defineProperty(e,"CatalogSortDirection",{enumerable:!0,get:function(){return A.CatalogSortDirection}});var R=jU();Object.defineProperty(e,"Order",{enumerable:!0,get:function(){return R.Order}}),Object.defineProperty(e,"OrderSortBy",{enumerable:!0,get:function(){return R.OrderSortBy}});var O=$U();Object.defineProperty(e,"ProviderType",{enumerable:!0,get:function(){return O.ProviderType}});var f=gl();Object.defineProperty(e,"Rarity",{enumerable:!0,get:function(){return f.Rarity}});var v=HN();Object.defineProperty(e,"SaleType",{enumerable:!0,get:function(){return v.SaleType}});var b=LU();Object.defineProperty(e,"Sale",{enumerable:!0,get:function(){return b.Sale}}),Object.defineProperty(e,"SaleSortBy",{enumerable:!0,get:function(){return b.SaleSortBy}});var h=qU();Object.defineProperty(e,"RentalStatus",{enumerable:!0,get:function(){return h.RentalStatus}}),Object.defineProperty(e,"RentalsListingSortDirection",{enumerable:!0,get:function(){return h.RentalsListingSortDirection}}),Object.defineProperty(e,"RentalsListingsFilterByCategory",{enumerable:!0,get:function(){return h.RentalsListingsFilterByCategory}}),Object.defineProperty(e,"RentalsListingsSortBy",{enumerable:!0,get:function(){return h.RentalsListingsSortBy}}),Object.defineProperty(e,"RentalListingCreation",{enumerable:!0,get:function(){return h.RentalListingCreation}}),Object.defineProperty(e,"PeriodCreation",{enumerable:!0,get:function(){return h.PeriodCreation}});var T=kU();Object.defineProperty(e,"AnalyticsDayDataSortBy",{enumerable:!0,get:function(){return T.AnalyticsDayDataSortBy}});var w=BU();Object.defineProperty(e,"Store",{enumerable:!0,get:function(){return w.Store}});var P=UU();Object.defineProperty(e,"WearableGender",{enumerable:!0,get:function(){return P.WearableGender}}),Object.defineProperty(e,"GenderFilterOption",{enumerable:!0,get:function(){return P.GenderFilterOption}});var B=FU();Object.defineProperty(e,"World",{enumerable:!0,get:function(){return B.World}}),Object.defineProperty(e,"getWorld",{enumerable:!0,get:function(){return B.getWorld}}),Object.defineProperty(e,"isInsideWorldLimits",{enumerable:!0,get:function(){return B.isInsideWorldLimits}}),r(VU(),e),r(HU(),e),r(GU(),e),r(cF(),e),r(pF(),e)})(ci)),ci}var dp={},DS;function hF(){return DS||(DS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.LinkerAuthorization=void 0;const t=Oe();(function(r){r.schema={type:"object",properties:{name:{type:"string"},desc:{type:"string"},startDate:{type:"string",nullable:!0},endDate:{type:"string",nullable:!0},contactInfo:{type:"object",properties:{name:{type:"string"}},required:["name"]},onlyDev:{type:"boolean",nullable:!0},addresses:{type:"array",items:{type:"string"},minItems:1},plots:{type:"array",items:{type:"string"},minItems:1}},required:["name","desc","contactInfo","addresses","plots"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.LinkerAuthorization||(e.LinkerAuthorization={}))})(dp)),dp}var fi={},fp={},ms={},jS;function GN(){if(jS)return ms;jS=1,Object.defineProperty(ms,"__esModule",{value:!0}),ms.isInExceptionBlock=void 0;function e(i,a){return i>=62&&i<=150&&a>=151&&a<=158}function t(i,a){return i>=151&&i<=162&&a>=144&&a<=158}function r(i,a){return i>=151&&i<=163&&a>=59&&a<=143}function n(i,a){return e(i,a)||t(i,a)||r(i,a)}return ms.isInExceptionBlock=n,ms}var $S;function yF(){return $S||($S=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Parcel=e.PARCEL_LIMITS=void 0;const t=Oe(),r=GN();e.PARCEL_LIMITS={minX:-150,maxX:150,minY:-150,maxY:150},(function(n){n._isInLimits={keyword:"_isInLimits",validate:function(p,E){return!E||typeof E.x!="number"||typeof E.y!="number"?!1:o(E)||(0,r.isInExceptionBlock)(E.x,E.y)},errors:!1},n.schema={type:"object",required:["x","y"],properties:{x:{type:"number"},y:{type:"number"}},_isInLimits:!0,additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema,[n._isInLimits]);function i({x:m,y:p}){return`${m},${p}`}n.parcelToString=i;function a(m){const p=m.match(/^(-?\d+),(-?\d+)$/);if(!p)return null;const[,E,A]=p,R=parseInt(E,10),O=parseInt(A,10);return{x:R,y:O}}n.stringToParcel=a;function s(m){const p=a(m);return p?n.validate(p):!1}n.isParcelStringValid=s;function o(m){const{x:p,y:E}=m;return p>=e.PARCEL_LIMITS.minX&&p<=e.PARCEL_LIMITS.maxX&&E>=e.PARCEL_LIMITS.minY&&E<=e.PARCEL_LIMITS.maxY}n.isInStandardBounds=o;function u(m){return(0,r.isInExceptionBlock)(m.x,m.y)}n.isExceptionParcel=u;function l(m){return o(m)||u(m)}n.isInBounds=l;function c(m){return n.validate(m)}n.isValid=c;function d(m){const p=a(m);return p?n.validate(p):!1}n.isValidString=d})(e.Parcel||(e.Parcel={}))})(fp)),fp}var pi={},LS;function gF(){if(LS)return pi;LS=1,Object.defineProperty(pi,"__esModule",{value:!0}),pi.validateUrlInstance=pi.validateUrl=void 0;const e={allowLocalhost:!1,allowedPorts:[]};function t(p,E=2){let A=p;for(let R=0;R<E;R++)try{A=decodeURIComponent(A)}catch{break}return A.normalize("NFKC")}function r(p){return/[\u0000-\u001F\u007F-\u009F\u202A-\u202E\u2066-\u2069]/.test(p)}function n(p){return!!(p.username||p.password)}function i(p){return/\\/.test(p)}const a=["80","443"];function s(p,E){return!!p.port&&!E.includes(p.port)}function o(p){const E=p.toLowerCase();return!!(E==="localhost"||E.endsWith(".local")||/^(127\.|10\.|172\.(1[6-9]|2[0-9]|3[0-1])\.|192\.168\.|169\.254\.)/.test(E)||E==="::1"||E==="[::1]"||E.startsWith("fe80:")||E.startsWith("fc00:"))}function u(p){if(p.startsWith("//"))return null;try{return{url:new URL(p),wasRelative:!1}}catch{try{return{url:new URL(p,"https://example.com"),wasRelative:!0}}catch{return null}}}function l(p){const E=t(String(p).toLowerCase());return!(r(E)||i(E))}function c(p){return!(!p||p.includes("..")||p.includes("//")||r(p)||i(p))}function d(p,E={}){const A=Object.assign(Object.assign({},e),E),R=[...a,...A.allowedPorts];if(!p||p.length===0||p.length>4096||r(p)||i(p))return!1;const O=t(p);if(r(O)||i(O)||p.startsWith("//"))return!1;const f=u(p);if(!f)return!1;const{url:v,wasRelative:b}=f;if(v.protocol!=="http:"&&v.protocol!=="https:"&&v.protocol!==""||n(v)||i(p)||i(v.href)||!b&&(s(v,R)||!A.allowLocalhost&&v.hostname&&o(v.hostname))||!c(v.pathname)||v.pathname.length>2048)return!1;const h=Array.from(v.searchParams.entries());if(h.length>50||(v.search?v.search.startsWith("?")?v.search.length-1:v.search.length:0)>2048)return!1;for(const[w,P]of h)if(w.length===0||!l(w)||!l(P)||w.length>128||P.length>1024)return!1;return!(v.hash&&r(v.hash))}pi.validateUrl=d;function m(p,E={}){return d(p.toString(),E)}return pi.validateUrlInstance=m,pi}var qS;function _F(){return qS||(qS=1,(function(e){var t=fi&&fi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=fi&&fi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(yF(),e),r(GN(),e),r(gF(),e)})(fi)),fi}var kS;function EF(){return kS||(kS=1,(function(e){var t=Or&&Or.__createBinding||(Object.create?(function(s,o,u,l){l===void 0&&(l=u);var c=Object.getOwnPropertyDescriptor(o,u);(!c||("get"in c?!o.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:function(){return o[u]}}),Object.defineProperty(s,l,c)}):(function(s,o,u,l){l===void 0&&(l=u),s[l]=o[u]})),r=Or&&Or.__setModuleDefault||(Object.create?(function(s,o){Object.defineProperty(s,"default",{enumerable:!0,value:o})}):function(s,o){s.default=o}),n=Or&&Or.__importStar||function(s){if(s&&s.__esModule)return s;var o={};if(s!=null)for(var u in s)u!=="default"&&Object.prototype.hasOwnProperty.call(s,u)&&t(o,s,u);return r(o,s),o},i=Or&&Or.__exportStar||function(s,o){for(var u in s)u!=="default"&&!Object.prototype.hasOwnProperty.call(o,u)&&t(o,s,u)};Object.defineProperty(e,"__esModule",{value:!0}),e.sdk=void 0;const a=n(AU());e.sdk=a,i(Oe(),e),i(mF(),e),i(Xg(),e),i(ia(),e),i(hF(),e),i(Oo(),e),i(LN(),e),i(UN(),e),i(_F(),e)})(Or)),Or}var oo=EF(),mi={},Cr={},Js={exports:{}},vF=Js.exports,BS;function bl(){return BS||(BS=1,(function(e,t){(function(r,n){n(t)})(vF,(function(r){function n(y){if(y.jsonrpc="2.0",!y.id||typeof y.id!="number"||Math.floor(y.id)!==y.id)throw new Error(`Invalid RPC message(invalid id) message: ${JSON.stringify(y)}`);if(!y.method||typeof y.method!="string"||y.method.trim().length===0)throw new Error(`Invalid RPC message(invalid method) message: ${JSON.stringify(y)}`);if(!y.params||typeof y.params!="object")throw new Error(`Invalid RPC message(invalid params) message: ${JSON.stringify(y)}`);return y}var i={};function a(){let y,S;const M=new Promise(((Y,x)=>{y=se=>{Y(se),M.isPending=!1},S=se=>{x(se),M.isPending=!1}})).catch((Y=>Promise.reject(Y)));return M.resolve=y,M.reject=S,"finally"in M||(M.finally=Y=>{M.then(Y),M.catch(Y)}),M.isPending=!0,M}Object.defineProperty(i,"__esModule",{value:!0});var s=i.future=a;i.default=a;var o={exports:{}};/**
|
|
63
|
+
* [js-sha3]{@link https://github.com/emn178/js-sha3}
|
|
64
|
+
*
|
|
65
|
+
* @version 0.8.0
|
|
66
|
+
* @author Chen, Yi-Cyuan [emn178@gmail.com]
|
|
67
|
+
* @copyright Chen, Yi-Cyuan 2015-2018
|
|
68
|
+
* @license MIT
|
|
69
|
+
*/(function(y){(function(){var S="input is invalid type",M=typeof window=="object",Y=M?window:{};Y.JS_SHA3_NO_WINDOW&&(M=!1);var x=!M&&typeof self=="object";!Y.JS_SHA3_NO_NODE_JS&&typeof Uc=="object"&&Uc.versions&&Uc.versions.node?Y=vy:x&&(Y=self);var se=!Y.JS_SHA3_NO_COMMON_JS&&y.exports,ve=!Y.JS_SHA3_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",Pe="0123456789abcdef".split(""),Ue=[4,1024,262144,67108864],Ve=[0,8,16,24],ir=[1,0,32898,0,32906,2147483648,2147516416,2147483648,32907,0,2147483649,0,2147516545,2147483648,32777,2147483648,138,0,136,0,2147516425,0,2147483658,0,2147516555,0,139,2147483648,32905,2147483648,32771,2147483648,32770,2147483648,128,2147483648,32778,0,2147483658,2147483648,2147516545,2147483648,32896,2147483648,2147483649,0,2147516424,2147483648],Ct=[224,256,384,512],Ce=[128,256],Gt=["hex","buffer","arrayBuffer","array","digest"],bt={128:168,256:136};!Y.JS_SHA3_NO_NODE_JS&&Array.isArray||(Array.isArray=function(g){return Object.prototype.toString.call(g)==="[object Array]"}),!ve||!Y.JS_SHA3_NO_ARRAY_BUFFER_IS_VIEW&&ArrayBuffer.isView||(ArrayBuffer.isView=function(g){return typeof g=="object"&&g.buffer&&g.buffer.constructor===ArrayBuffer});for(var Tt=function(g,q,Q){return function(V){return new ot(g,q,g).update(V)[Q]()}},xt=function(g,q,Q){return function(V,ee){return new ot(g,q,ee).update(V)[Q]()}},ln=function(g,q,Q){return function(V,ee,te,ie){return zt["cshake"+g].update(V,ee,te,ie)[Q]()}},Yr=function(g,q,Q){return function(V,ee,te,ie){return zt["kmac"+g].update(V,ee,te,ie)[Q]()}},er=function(g,q,Q,V){for(var ee=0;ee<Gt.length;++ee){var te=Gt[ee];g[te]=q(Q,V,te)}return g},Kr=function(g,q){var Q=Tt(g,q,"hex");return Q.create=function(){return new ot(g,q,g)},Q.update=function(V){return Q.create().update(V)},er(Q,Tt,g,q)},Nn=[{name:"keccak",padding:[1,256,65536,16777216],bits:Ct,createMethod:Kr},{name:"sha3",padding:[6,1536,393216,100663296],bits:Ct,createMethod:Kr},{name:"shake",padding:[31,7936,2031616,520093696],bits:Ce,createMethod:function(g,q){var Q=xt(g,q,"hex");return Q.create=function(V){return new ot(g,q,V)},Q.update=function(V,ee){return Q.create(ee).update(V)},er(Q,xt,g,q)}},{name:"cshake",padding:Ue,bits:Ce,createMethod:function(g,q){var Q=bt[g],V=ln(g,0,"hex");return V.create=function(ee,te,ie){return te||ie?new ot(g,q,ee).bytepad([te,ie],Q):zt["shake"+g].create(ee)},V.update=function(ee,te,ie,pe){return V.create(te,ie,pe).update(ee)},er(V,ln,g,q)}},{name:"kmac",padding:Ue,bits:Ce,createMethod:function(g,q){var Q=bt[g],V=Yr(g,0,"hex");return V.create=function(ee,te,ie){return new Er(g,q,te).bytepad(["KMAC",ie],Q).bytepad([ee],Q)},V.update=function(ee,te,ie,pe){return V.create(ee,ie,pe).update(te)},er(V,Yr,g,q)}}],zt={},dn=[],tr=0;tr<Nn.length;++tr)for(var Jr=Nn[tr],we=Jr.bits,fn=0;fn<we.length;++fn){var la=Jr.name+"_"+we[fn];if(dn.push(la),zt[la]=Jr.createMethod(we[fn],Jr.padding),Jr.name!=="sha3"){var da=Jr.name+we[fn];dn.push(da),zt[da]=zt[la]}}function ot(g,q,Q){this.blocks=[],this.s=[],this.padding=q,this.outputBits=Q,this.reset=!0,this.finalized=!1,this.block=0,this.start=0,this.blockCount=1600-(g<<1)>>5,this.byteCount=this.blockCount<<2,this.outputBlocks=Q>>5,this.extraBytes=(31&Q)>>3;for(var V=0;V<50;++V)this.s[V]=0}function Er(g,q,Q){ot.call(this,g,q,Q)}ot.prototype.update=function(g){if(this.finalized)throw new Error("finalize already called");var q,Q=typeof g;if(Q!=="string"){if(Q!=="object")throw new Error(S);if(g===null)throw new Error(S);if(ve&&g.constructor===ArrayBuffer)g=new Uint8Array(g);else if(!(Array.isArray(g)||ve&&ArrayBuffer.isView(g)))throw new Error(S);q=!0}for(var V,ee,te=this.blocks,ie=this.byteCount,pe=g.length,ye=this.blockCount,he=0,Me=this.s;he<pe;){if(this.reset)for(this.reset=!1,te[0]=this.block,V=1;V<ye+1;++V)te[V]=0;if(q)for(V=this.start;he<pe&&V<ie;++he)te[V>>2]|=g[he]<<Ve[3&V++];else for(V=this.start;he<pe&&V<ie;++he)(ee=g.charCodeAt(he))<128?te[V>>2]|=ee<<Ve[3&V++]:ee<2048?(te[V>>2]|=(192|ee>>6)<<Ve[3&V++],te[V>>2]|=(128|63&ee)<<Ve[3&V++]):ee<55296||ee>=57344?(te[V>>2]|=(224|ee>>12)<<Ve[3&V++],te[V>>2]|=(128|ee>>6&63)<<Ve[3&V++],te[V>>2]|=(128|63&ee)<<Ve[3&V++]):(ee=65536+((1023&ee)<<10|1023&g.charCodeAt(++he)),te[V>>2]|=(240|ee>>18)<<Ve[3&V++],te[V>>2]|=(128|ee>>12&63)<<Ve[3&V++],te[V>>2]|=(128|ee>>6&63)<<Ve[3&V++],te[V>>2]|=(128|63&ee)<<Ve[3&V++]);if(this.lastByteIndex=V,V>=ie){for(this.start=V-ie,this.block=te[ye],V=0;V<ye;++V)Me[V]^=te[V];k(Me),this.reset=!0}else this.start=V}return this},ot.prototype.encode=function(g,q){var Q=255&g,V=1,ee=[Q];for(Q=255&(g>>=8);Q>0;)ee.unshift(Q),Q=255&(g>>=8),++V;return q?ee.push(V):ee.unshift(V),this.update(ee),ee.length},ot.prototype.encodeString=function(g){var q,Q=typeof g;if(Q!=="string"){if(Q!=="object")throw new Error(S);if(g===null)throw new Error(S);if(ve&&g.constructor===ArrayBuffer)g=new Uint8Array(g);else if(!(Array.isArray(g)||ve&&ArrayBuffer.isView(g)))throw new Error(S);q=!0}var V=0,ee=g.length;if(q)V=ee;else for(var te=0;te<g.length;++te){var ie=g.charCodeAt(te);ie<128?V+=1:ie<2048?V+=2:ie<55296||ie>=57344?V+=3:(ie=65536+((1023&ie)<<10|1023&g.charCodeAt(++te)),V+=4)}return V+=this.encode(8*V),this.update(g),V},ot.prototype.bytepad=function(g,q){for(var Q=this.encode(q),V=0;V<g.length;++V)Q+=this.encodeString(g[V]);var ee=q-Q%q,te=[];return te.length=ee,this.update(te),this},ot.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var g=this.blocks,q=this.lastByteIndex,Q=this.blockCount,V=this.s;if(g[q>>2]|=this.padding[3&q],this.lastByteIndex===this.byteCount)for(g[0]=g[Q],q=1;q<Q+1;++q)g[q]=0;for(g[Q-1]|=2147483648,q=0;q<Q;++q)V[q]^=g[q];k(V)}},ot.prototype.toString=ot.prototype.hex=function(){this.finalize();for(var g,q=this.blockCount,Q=this.s,V=this.outputBlocks,ee=this.extraBytes,te=0,ie=0,pe="";ie<V;){for(te=0;te<q&&ie<V;++te,++ie)g=Q[te],pe+=Pe[g>>4&15]+Pe[15&g]+Pe[g>>12&15]+Pe[g>>8&15]+Pe[g>>20&15]+Pe[g>>16&15]+Pe[g>>28&15]+Pe[g>>24&15];ie%q==0&&(k(Q),te=0)}return ee&&(g=Q[te],pe+=Pe[g>>4&15]+Pe[15&g],ee>1&&(pe+=Pe[g>>12&15]+Pe[g>>8&15]),ee>2&&(pe+=Pe[g>>20&15]+Pe[g>>16&15])),pe},ot.prototype.arrayBuffer=function(){this.finalize();var g,q=this.blockCount,Q=this.s,V=this.outputBlocks,ee=this.extraBytes,te=0,ie=0,pe=this.outputBits>>3;g=ee?new ArrayBuffer(V+1<<2):new ArrayBuffer(pe);for(var ye=new Uint32Array(g);ie<V;){for(te=0;te<q&&ie<V;++te,++ie)ye[ie]=Q[te];ie%q==0&&k(Q)}return ee&&(ye[te]=Q[te],g=g.slice(0,pe)),g},ot.prototype.buffer=ot.prototype.arrayBuffer,ot.prototype.digest=ot.prototype.array=function(){this.finalize();for(var g,q,Q=this.blockCount,V=this.s,ee=this.outputBlocks,te=this.extraBytes,ie=0,pe=0,ye=[];pe<ee;){for(ie=0;ie<Q&&pe<ee;++ie,++pe)g=pe<<2,q=V[ie],ye[g]=255&q,ye[g+1]=q>>8&255,ye[g+2]=q>>16&255,ye[g+3]=q>>24&255;pe%Q==0&&k(V)}return te&&(g=pe<<2,q=V[ie],ye[g]=255&q,te>1&&(ye[g+1]=q>>8&255),te>2&&(ye[g+2]=q>>16&255)),ye},Er.prototype=new ot,Er.prototype.finalize=function(){return this.encode(this.outputBits,!0),ot.prototype.finalize.call(this)};var k=function(g){var q,Q,V,ee,te,ie,pe,ye,he,Me,Fe,ze,nt,St,Nt,xe,ut,Lt,pn,Pn,Mn,ar,Xr,Wt,qt,vt,Lo,qo,ko,Bo,Uo,Fo,Vo,Ho,Go,zo,Wo,Yo,Ko,Jo,Xo,Qo,Zo,xo,eu,tu,ru,nu,iu,au,su,ou,uu,cu,lu,du,fu,pu,mu,hu,yu,gu,_u;for(V=0;V<48;V+=2)ee=g[0]^g[10]^g[20]^g[30]^g[40],te=g[1]^g[11]^g[21]^g[31]^g[41],ie=g[2]^g[12]^g[22]^g[32]^g[42],pe=g[3]^g[13]^g[23]^g[33]^g[43],ye=g[4]^g[14]^g[24]^g[34]^g[44],he=g[5]^g[15]^g[25]^g[35]^g[45],Me=g[6]^g[16]^g[26]^g[36]^g[46],Fe=g[7]^g[17]^g[27]^g[37]^g[47],q=(ze=g[8]^g[18]^g[28]^g[38]^g[48])^(ie<<1|pe>>>31),Q=(nt=g[9]^g[19]^g[29]^g[39]^g[49])^(pe<<1|ie>>>31),g[0]^=q,g[1]^=Q,g[10]^=q,g[11]^=Q,g[20]^=q,g[21]^=Q,g[30]^=q,g[31]^=Q,g[40]^=q,g[41]^=Q,q=ee^(ye<<1|he>>>31),Q=te^(he<<1|ye>>>31),g[2]^=q,g[3]^=Q,g[12]^=q,g[13]^=Q,g[22]^=q,g[23]^=Q,g[32]^=q,g[33]^=Q,g[42]^=q,g[43]^=Q,q=ie^(Me<<1|Fe>>>31),Q=pe^(Fe<<1|Me>>>31),g[4]^=q,g[5]^=Q,g[14]^=q,g[15]^=Q,g[24]^=q,g[25]^=Q,g[34]^=q,g[35]^=Q,g[44]^=q,g[45]^=Q,q=ye^(ze<<1|nt>>>31),Q=he^(nt<<1|ze>>>31),g[6]^=q,g[7]^=Q,g[16]^=q,g[17]^=Q,g[26]^=q,g[27]^=Q,g[36]^=q,g[37]^=Q,g[46]^=q,g[47]^=Q,q=Me^(ee<<1|te>>>31),Q=Fe^(te<<1|ee>>>31),g[8]^=q,g[9]^=Q,g[18]^=q,g[19]^=Q,g[28]^=q,g[29]^=Q,g[38]^=q,g[39]^=Q,g[48]^=q,g[49]^=Q,St=g[0],Nt=g[1],tu=g[11]<<4|g[10]>>>28,ru=g[10]<<4|g[11]>>>28,qo=g[20]<<3|g[21]>>>29,ko=g[21]<<3|g[20]>>>29,hu=g[31]<<9|g[30]>>>23,yu=g[30]<<9|g[31]>>>23,Qo=g[40]<<18|g[41]>>>14,Zo=g[41]<<18|g[40]>>>14,Ho=g[2]<<1|g[3]>>>31,Go=g[3]<<1|g[2]>>>31,xe=g[13]<<12|g[12]>>>20,ut=g[12]<<12|g[13]>>>20,nu=g[22]<<10|g[23]>>>22,iu=g[23]<<10|g[22]>>>22,Bo=g[33]<<13|g[32]>>>19,Uo=g[32]<<13|g[33]>>>19,gu=g[42]<<2|g[43]>>>30,_u=g[43]<<2|g[42]>>>30,cu=g[5]<<30|g[4]>>>2,lu=g[4]<<30|g[5]>>>2,zo=g[14]<<6|g[15]>>>26,Wo=g[15]<<6|g[14]>>>26,Lt=g[25]<<11|g[24]>>>21,pn=g[24]<<11|g[25]>>>21,au=g[34]<<15|g[35]>>>17,su=g[35]<<15|g[34]>>>17,Fo=g[45]<<29|g[44]>>>3,Vo=g[44]<<29|g[45]>>>3,Wt=g[6]<<28|g[7]>>>4,qt=g[7]<<28|g[6]>>>4,du=g[17]<<23|g[16]>>>9,fu=g[16]<<23|g[17]>>>9,Yo=g[26]<<25|g[27]>>>7,Ko=g[27]<<25|g[26]>>>7,Pn=g[36]<<21|g[37]>>>11,Mn=g[37]<<21|g[36]>>>11,ou=g[47]<<24|g[46]>>>8,uu=g[46]<<24|g[47]>>>8,xo=g[8]<<27|g[9]>>>5,eu=g[9]<<27|g[8]>>>5,vt=g[18]<<20|g[19]>>>12,Lo=g[19]<<20|g[18]>>>12,pu=g[29]<<7|g[28]>>>25,mu=g[28]<<7|g[29]>>>25,Jo=g[38]<<8|g[39]>>>24,Xo=g[39]<<8|g[38]>>>24,ar=g[48]<<14|g[49]>>>18,Xr=g[49]<<14|g[48]>>>18,g[0]=St^~xe&Lt,g[1]=Nt^~ut&pn,g[10]=Wt^~vt&qo,g[11]=qt^~Lo&ko,g[20]=Ho^~zo&Yo,g[21]=Go^~Wo&Ko,g[30]=xo^~tu&nu,g[31]=eu^~ru&iu,g[40]=cu^~du&pu,g[41]=lu^~fu&mu,g[2]=xe^~Lt&Pn,g[3]=ut^~pn&Mn,g[12]=vt^~qo&Bo,g[13]=Lo^~ko&Uo,g[22]=zo^~Yo&Jo,g[23]=Wo^~Ko&Xo,g[32]=tu^~nu&au,g[33]=ru^~iu&su,g[42]=du^~pu&hu,g[43]=fu^~mu&yu,g[4]=Lt^~Pn&ar,g[5]=pn^~Mn&Xr,g[14]=qo^~Bo&Fo,g[15]=ko^~Uo&Vo,g[24]=Yo^~Jo&Qo,g[25]=Ko^~Xo&Zo,g[34]=nu^~au&ou,g[35]=iu^~su&uu,g[44]=pu^~hu&gu,g[45]=mu^~yu&_u,g[6]=Pn^~ar&St,g[7]=Mn^~Xr&Nt,g[16]=Bo^~Fo&Wt,g[17]=Uo^~Vo&qt,g[26]=Jo^~Qo&Ho,g[27]=Xo^~Zo&Go,g[36]=au^~ou&xo,g[37]=su^~uu&eu,g[46]=hu^~gu&cu,g[47]=yu^~_u&lu,g[8]=ar^~St&xe,g[9]=Xr^~Nt&ut,g[18]=Fo^~Wt&vt,g[19]=Vo^~qt&Lo,g[28]=Qo^~Ho&zo,g[29]=Zo^~Go&Wo,g[38]=ou^~xo&tu,g[39]=uu^~eu&ru,g[48]=gu^~cu&du,g[49]=_u^~lu&fu,g[0]^=ir[V],g[1]^=ir[V+1]};if(se)y.exports=zt;else for(tr=0;tr<dn.length;++tr)Y[dn[tr]]=zt[dn[tr]]})()})(o);var u=o.exports,l=/^-?(?:\d+(?:\.\d*)?|\.\d+)(?:e[+-]?\d+)?$/i,c=Math.ceil,d=Math.floor,m="[BigNumber Error] ",p=m+"Number primitive has more than 15 significant digits: ",E=1e14,A=14,R=9007199254740991,O=[1,10,100,1e3,1e4,1e5,1e6,1e7,1e8,1e9,1e10,1e11,1e12,1e13],f=1e7,v=1e9;function b(y){var S=0|y;return y>0||y===S?S:S-1}function h(y){for(var S,M,Y=1,x=y.length,se=y[0]+"";Y<x;){for(S=y[Y++]+"",M=A-S.length;M--;S="0"+S);se+=S}for(x=se.length;se.charCodeAt(--x)===48;);return se.slice(0,x+1||1)}function T(y,S){var M,Y,x=y.c,se=S.c,ve=y.s,Pe=S.s,Ue=y.e,Ve=S.e;if(!ve||!Pe)return null;if(M=x&&!x[0],Y=se&&!se[0],M||Y)return M?Y?0:-Pe:ve;if(ve!=Pe)return ve;if(M=ve<0,Y=Ue==Ve,!x||!se)return Y?0:!x^M?1:-1;if(!Y)return Ue>Ve^M?1:-1;for(Pe=(Ue=x.length)<(Ve=se.length)?Ue:Ve,ve=0;ve<Pe;ve++)if(x[ve]!=se[ve])return x[ve]>se[ve]^M?1:-1;return Ue==Ve?0:Ue>Ve^M?1:-1}function w(y,S,M,Y){if(y<S||y>M||y!==d(y))throw Error(m+(Y||"Argument")+(typeof y=="number"?y<S||y>M?" out of range: ":" not an integer: ":" not a primitive number: ")+String(y))}function P(y){var S=y.c.length-1;return b(y.e/A)==S&&y.c[S]%2!=0}function B(y,S){return(y.length>1?y.charAt(0)+"."+y.slice(1):y)+(S<0?"e":"e+")+S}function J(y,S,M){var Y,x;if(S<0){for(x=M+".";++S;x+=M);y=x+y}else if(++S>(Y=y.length)){for(x=M,S-=Y;--S;x+=M);y+=x}else S<Y&&(y=y.slice(0,S)+"."+y.slice(S));return y}var K=(function y(S){var M,Y,x,se,ve,Pe,Ue,Ve,ir,Ct,Ce=we.prototype={constructor:we,toString:null,valueOf:null},Gt=new we(1),bt=20,Tt=4,xt=-7,ln=21,Yr=-1e7,er=1e7,Kr=!1,Nn=1,zt=0,dn={prefix:"",groupSize:3,secondaryGroupSize:0,groupSeparator:",",decimalSeparator:".",fractionGroupSize:0,fractionGroupSeparator:" ",suffix:""},tr="0123456789abcdefghijklmnopqrstuvwxyz",Jr=!0;function we(k,g){var q,Q,V,ee,te,ie,pe,ye,he=this;if(!(he instanceof we))return new we(k,g);if(g==null){if(k&&k._isBigNumber===!0)return he.s=k.s,void(!k.c||k.e>er?he.c=he.e=null:k.e<Yr?he.c=[he.e=0]:(he.e=k.e,he.c=k.c.slice()));if((ie=typeof k=="number")&&0*k==0){if(he.s=1/k<0?(k=-k,-1):1,k===~~k){for(ee=0,te=k;te>=10;te/=10,ee++);return void(ee>er?he.c=he.e=null:(he.e=ee,he.c=[k]))}ye=String(k)}else{if(!l.test(ye=String(k)))return x(he,ye,ie);he.s=ye.charCodeAt(0)==45?(ye=ye.slice(1),-1):1}(ee=ye.indexOf("."))>-1&&(ye=ye.replace(".","")),(te=ye.search(/e/i))>0?(ee<0&&(ee=te),ee+=+ye.slice(te+1),ye=ye.substring(0,te)):ee<0&&(ee=ye.length)}else{if(w(g,2,tr.length,"Base"),g==10&&Jr)return ot(he=new we(k),bt+he.e+1,Tt);if(ye=String(k),ie=typeof k=="number"){if(0*k!=0)return x(he,ye,ie,g);if(he.s=1/k<0?(ye=ye.slice(1),-1):1,we.DEBUG&&ye.replace(/^0\.0*|\./,"").length>15)throw Error(p+k)}else he.s=ye.charCodeAt(0)===45?(ye=ye.slice(1),-1):1;for(q=tr.slice(0,g),ee=te=0,pe=ye.length;te<pe;te++)if(q.indexOf(Q=ye.charAt(te))<0){if(Q=="."){if(te>ee){ee=pe;continue}}else if(!V&&(ye==ye.toUpperCase()&&(ye=ye.toLowerCase())||ye==ye.toLowerCase()&&(ye=ye.toUpperCase()))){V=!0,te=-1,ee=0;continue}return x(he,String(k),ie,g)}ie=!1,(ee=(ye=Y(ye,g,10,he.s)).indexOf("."))>-1?ye=ye.replace(".",""):ee=ye.length}for(te=0;ye.charCodeAt(te)===48;te++);for(pe=ye.length;ye.charCodeAt(--pe)===48;);if(ye=ye.slice(te,++pe)){if(pe-=te,ie&&we.DEBUG&&pe>15&&(k>R||k!==d(k)))throw Error(p+he.s*k);if((ee=ee-te-1)>er)he.c=he.e=null;else if(ee<Yr)he.c=[he.e=0];else{if(he.e=ee,he.c=[],te=(ee+1)%A,ee<0&&(te+=A),te<pe){for(te&&he.c.push(+ye.slice(0,te)),pe-=A;te<pe;)he.c.push(+ye.slice(te,te+=A));te=A-(ye=ye.slice(te)).length}else te-=pe;for(;te--;ye+="0");he.c.push(+ye)}}else he.c=[he.e=0]}function fn(k,g,q,Q){var V,ee,te,ie,pe;if(q==null?q=Tt:w(q,0,8),!k.c)return k.toString();if(V=k.c[0],te=k.e,g==null)pe=h(k.c),pe=Q==1||Q==2&&(te<=xt||te>=ln)?B(pe,te):J(pe,te,"0");else if(ee=(k=ot(new we(k),g,q)).e,ie=(pe=h(k.c)).length,Q==1||Q==2&&(g<=ee||ee<=xt)){for(;ie<g;pe+="0",ie++);pe=B(pe,ee)}else if(g-=te,pe=J(pe,ee,"0"),ee+1>ie){if(--g>0)for(pe+=".";g--;pe+="0");}else if((g+=ee-ie)>0)for(ee+1==ie&&(pe+=".");g--;pe+="0");return k.s<0&&V?"-"+pe:pe}function la(k,g){for(var q,Q=1,V=new we(k[0]);Q<k.length;Q++){if(!(q=new we(k[Q])).s){V=q;break}g.call(V,q)&&(V=q)}return V}function da(k,g,q){for(var Q=1,V=g.length;!g[--V];g.pop());for(V=g[0];V>=10;V/=10,Q++);return(q=Q+q*A-1)>er?k.c=k.e=null:q<Yr?k.c=[k.e=0]:(k.e=q,k.c=g),k}function ot(k,g,q,Q){var V,ee,te,ie,pe,ye,he,Me=k.c,Fe=O;if(Me){e:{for(V=1,ie=Me[0];ie>=10;ie/=10,V++);if((ee=g-V)<0)ee+=A,te=g,he=(pe=Me[ye=0])/Fe[V-te-1]%10|0;else if((ye=c((ee+1)/A))>=Me.length){if(!Q)break e;for(;Me.length<=ye;Me.push(0));pe=he=0,V=1,te=(ee%=A)-A+1}else{for(pe=ie=Me[ye],V=1;ie>=10;ie/=10,V++);he=(te=(ee%=A)-A+V)<0?0:pe/Fe[V-te-1]%10|0}if(Q=Q||g<0||Me[ye+1]!=null||(te<0?pe:pe%Fe[V-te-1]),Q=q<4?(he||Q)&&(q==0||q==(k.s<0?3:2)):he>5||he==5&&(q==4||Q||q==6&&(ee>0?te>0?pe/Fe[V-te]:0:Me[ye-1])%10&1||q==(k.s<0?8:7)),g<1||!Me[0])return Me.length=0,Q?(g-=k.e+1,Me[0]=Fe[(A-g%A)%A],k.e=-g||0):Me[0]=k.e=0,k;if(ee==0?(Me.length=ye,ie=1,ye--):(Me.length=ye+1,ie=Fe[A-ee],Me[ye]=te>0?d(pe/Fe[V-te]%Fe[te])*ie:0),Q)for(;;){if(ye==0){for(ee=1,te=Me[0];te>=10;te/=10,ee++);for(te=Me[0]+=ie,ie=1;te>=10;te/=10,ie++);ee!=ie&&(k.e++,Me[0]==E&&(Me[0]=1));break}if(Me[ye]+=ie,Me[ye]!=E)break;Me[ye--]=0,ie=1}for(ee=Me.length;Me[--ee]===0;Me.pop());}k.e>er?k.c=k.e=null:k.e<Yr&&(k.c=[k.e=0])}return k}function Er(k){var g,q=k.e;return q===null?k.toString():(g=h(k.c),g=q<=xt||q>=ln?B(g,q):J(g,q,"0"),k.s<0?"-"+g:g)}return we.clone=y,we.ROUND_UP=0,we.ROUND_DOWN=1,we.ROUND_CEIL=2,we.ROUND_FLOOR=3,we.ROUND_HALF_UP=4,we.ROUND_HALF_DOWN=5,we.ROUND_HALF_EVEN=6,we.ROUND_HALF_CEIL=7,we.ROUND_HALF_FLOOR=8,we.EUCLID=9,we.config=we.set=function(k){var g,q;if(k!=null){if(typeof k!="object")throw Error(m+"Object expected: "+k);if(k.hasOwnProperty(g="DECIMAL_PLACES")&&(w(q=k[g],0,v,g),bt=q),k.hasOwnProperty(g="ROUNDING_MODE")&&(w(q=k[g],0,8,g),Tt=q),k.hasOwnProperty(g="EXPONENTIAL_AT")&&((q=k[g])&&q.pop?(w(q[0],-v,0,g),w(q[1],0,v,g),xt=q[0],ln=q[1]):(w(q,-v,v,g),xt=-(ln=q<0?-q:q))),k.hasOwnProperty(g="RANGE"))if((q=k[g])&&q.pop)w(q[0],-v,-1,g),w(q[1],1,v,g),Yr=q[0],er=q[1];else{if(w(q,-v,v,g),!q)throw Error(m+g+" cannot be zero: "+q);Yr=-(er=q<0?-q:q)}if(k.hasOwnProperty(g="CRYPTO")){if((q=k[g])!==!!q)throw Error(m+g+" not true or false: "+q);if(q){if(typeof crypto>"u"||!crypto||!crypto.getRandomValues&&!crypto.randomBytes)throw Kr=!q,Error(m+"crypto unavailable");Kr=q}else Kr=q}if(k.hasOwnProperty(g="MODULO_MODE")&&(w(q=k[g],0,9,g),Nn=q),k.hasOwnProperty(g="POW_PRECISION")&&(w(q=k[g],0,v,g),zt=q),k.hasOwnProperty(g="FORMAT")){if(typeof(q=k[g])!="object")throw Error(m+g+" not an object: "+q);dn=q}if(k.hasOwnProperty(g="ALPHABET")){if(typeof(q=k[g])!="string"||/^.?$|[+\-.\s]|(.).*\1/.test(q))throw Error(m+g+" invalid: "+q);Jr=q.slice(0,10)=="0123456789",tr=q}}return{DECIMAL_PLACES:bt,ROUNDING_MODE:Tt,EXPONENTIAL_AT:[xt,ln],RANGE:[Yr,er],CRYPTO:Kr,MODULO_MODE:Nn,POW_PRECISION:zt,FORMAT:dn,ALPHABET:tr}},we.isBigNumber=function(k){if(!k||k._isBigNumber!==!0)return!1;if(!we.DEBUG)return!0;var g,q,Q=k.c,V=k.e,ee=k.s;e:if({}.toString.call(Q)=="[object Array]"){if((ee===1||ee===-1)&&V>=-v&&V<=v&&V===d(V)){if(Q[0]===0){if(V===0&&Q.length===1)return!0;break e}if((g=(V+1)%A)<1&&(g+=A),String(Q[0]).length==g){for(g=0;g<Q.length;g++)if((q=Q[g])<0||q>=E||q!==d(q))break e;if(q!==0)return!0}}}else if(Q===null&&V===null&&(ee===null||ee===1||ee===-1))return!0;throw Error(m+"Invalid BigNumber: "+k)},we.maximum=we.max=function(){return la(arguments,Ce.lt)},we.minimum=we.min=function(){return la(arguments,Ce.gt)},we.random=(se=9007199254740992,ve=Math.random()*se&2097151?function(){return d(Math.random()*se)}:function(){return 8388608*(1073741824*Math.random()|0)+(8388608*Math.random()|0)},function(k){var g,q,Q,V,ee,te=0,ie=[],pe=new we(Gt);if(k==null?k=bt:w(k,0,v),V=c(k/A),Kr)if(crypto.getRandomValues){for(g=crypto.getRandomValues(new Uint32Array(V*=2));te<V;)(ee=131072*g[te]+(g[te+1]>>>11))>=9e15?(q=crypto.getRandomValues(new Uint32Array(2)),g[te]=q[0],g[te+1]=q[1]):(ie.push(ee%1e14),te+=2);te=V/2}else{if(!crypto.randomBytes)throw Kr=!1,Error(m+"crypto unavailable");for(g=crypto.randomBytes(V*=7);te<V;)(ee=281474976710656*(31&g[te])+1099511627776*g[te+1]+4294967296*g[te+2]+16777216*g[te+3]+(g[te+4]<<16)+(g[te+5]<<8)+g[te+6])>=9e15?crypto.randomBytes(7).copy(g,te):(ie.push(ee%1e14),te+=7);te=V/7}if(!Kr)for(;te<V;)(ee=ve())<9e15&&(ie[te++]=ee%1e14);for(V=ie[--te],k%=A,V&&k&&(ee=O[A-k],ie[te]=d(V/ee)*ee);ie[te]===0;ie.pop(),te--);if(te<0)ie=[Q=0];else{for(Q=-1;ie[0]===0;ie.splice(0,1),Q-=A);for(te=1,ee=ie[0];ee>=10;ee/=10,te++);te<A&&(Q-=A-te)}return pe.e=Q,pe.c=ie,pe}),we.sum=function(){for(var k=1,g=arguments,q=new we(g[0]);k<g.length;)q=q.plus(g[k++]);return q},Y=(function(){var k="0123456789";function g(q,Q,V,ee){for(var te,ie,pe=[0],ye=0,he=q.length;ye<he;){for(ie=pe.length;ie--;pe[ie]*=Q);for(pe[0]+=ee.indexOf(q.charAt(ye++)),te=0;te<pe.length;te++)pe[te]>V-1&&(pe[te+1]==null&&(pe[te+1]=0),pe[te+1]+=pe[te]/V|0,pe[te]%=V)}return pe.reverse()}return function(q,Q,V,ee,te){var ie,pe,ye,he,Me,Fe,ze,nt,St=q.indexOf("."),Nt=bt,xe=Tt;for(St>=0&&(he=zt,zt=0,q=q.replace(".",""),Fe=(nt=new we(Q)).pow(q.length-St),zt=he,nt.c=g(J(h(Fe.c),Fe.e,"0"),10,V,k),nt.e=nt.c.length),ye=he=(ze=g(q,Q,V,te?(ie=tr,k):(ie=k,tr))).length;ze[--he]==0;ze.pop());if(!ze[0])return ie.charAt(0);if(St<0?--ye:(Fe.c=ze,Fe.e=ye,Fe.s=ee,ze=(Fe=M(Fe,nt,Nt,xe,V)).c,Me=Fe.r,ye=Fe.e),St=ze[pe=ye+Nt+1],he=V/2,Me=Me||pe<0||ze[pe+1]!=null,Me=xe<4?(St!=null||Me)&&(xe==0||xe==(Fe.s<0?3:2)):St>he||St==he&&(xe==4||Me||xe==6&&1&ze[pe-1]||xe==(Fe.s<0?8:7)),pe<1||!ze[0])q=Me?J(ie.charAt(1),-Nt,ie.charAt(0)):ie.charAt(0);else{if(ze.length=pe,Me)for(--V;++ze[--pe]>V;)ze[pe]=0,pe||(++ye,ze=[1].concat(ze));for(he=ze.length;!ze[--he];);for(St=0,q="";St<=he;q+=ie.charAt(ze[St++]));q=J(q,ye,ie.charAt(0))}return q}})(),M=(function(){function k(Q,V,ee){var te,ie,pe,ye,he=0,Me=Q.length,Fe=V%f,ze=V/f|0;for(Q=Q.slice();Me--;)he=((ie=Fe*(pe=Q[Me]%f)+(te=ze*pe+(ye=Q[Me]/f|0)*Fe)%f*f+he)/ee|0)+(te/f|0)+ze*ye,Q[Me]=ie%ee;return he&&(Q=[he].concat(Q)),Q}function g(Q,V,ee,te){var ie,pe;if(ee!=te)pe=ee>te?1:-1;else for(ie=pe=0;ie<ee;ie++)if(Q[ie]!=V[ie]){pe=Q[ie]>V[ie]?1:-1;break}return pe}function q(Q,V,ee,te){for(var ie=0;ee--;)Q[ee]-=ie,ie=Q[ee]<V[ee]?1:0,Q[ee]=ie*te+Q[ee]-V[ee];for(;!Q[0]&&Q.length>1;Q.splice(0,1));}return function(Q,V,ee,te,ie){var pe,ye,he,Me,Fe,ze,nt,St,Nt,xe,ut,Lt,pn,Pn,Mn,ar,Xr,Wt=Q.s==V.s?1:-1,qt=Q.c,vt=V.c;if(!(qt&&qt[0]&&vt&&vt[0]))return new we(Q.s&&V.s&&(qt?!vt||qt[0]!=vt[0]:vt)?qt&&qt[0]==0||!vt?0*Wt:Wt/0:NaN);for(Nt=(St=new we(Wt)).c=[],Wt=ee+(ye=Q.e-V.e)+1,ie||(ie=E,ye=b(Q.e/A)-b(V.e/A),Wt=Wt/A|0),he=0;vt[he]==(qt[he]||0);he++);if(vt[he]>(qt[he]||0)&&ye--,Wt<0)Nt.push(1),Me=!0;else{for(Pn=qt.length,ar=vt.length,he=0,Wt+=2,(Fe=d(ie/(vt[0]+1)))>1&&(vt=k(vt,Fe,ie),qt=k(qt,Fe,ie),ar=vt.length,Pn=qt.length),pn=ar,ut=(xe=qt.slice(0,ar)).length;ut<ar;xe[ut++]=0);Xr=vt.slice(),Xr=[0].concat(Xr),Mn=vt[0],vt[1]>=ie/2&&Mn++;do{if(Fe=0,(pe=g(vt,xe,ar,ut))<0){if(Lt=xe[0],ar!=ut&&(Lt=Lt*ie+(xe[1]||0)),(Fe=d(Lt/Mn))>1)for(Fe>=ie&&(Fe=ie-1),nt=(ze=k(vt,Fe,ie)).length,ut=xe.length;g(ze,xe,nt,ut)==1;)Fe--,q(ze,ar<nt?Xr:vt,nt,ie),nt=ze.length,pe=1;else Fe==0&&(pe=Fe=1),nt=(ze=vt.slice()).length;if(nt<ut&&(ze=[0].concat(ze)),q(xe,ze,ut,ie),ut=xe.length,pe==-1)for(;g(vt,xe,ar,ut)<1;)Fe++,q(xe,ar<ut?Xr:vt,ut,ie),ut=xe.length}else pe===0&&(Fe++,xe=[0]);Nt[he++]=Fe,xe[0]?xe[ut++]=qt[pn]||0:(xe=[qt[pn]],ut=1)}while((pn++<Pn||xe[0]!=null)&&Wt--);Me=xe[0]!=null,Nt[0]||Nt.splice(0,1)}if(ie==E){for(he=1,Wt=Nt[0];Wt>=10;Wt/=10,he++);ot(St,ee+(St.e=he+ye*A-1)+1,te,Me)}else St.e=ye,St.r=+Me;return St}})(),Pe=/^(-?)0([xbo])(?=\w[\w.]*$)/i,Ue=/^([^.]+)\.$/,Ve=/^\.([^.]+)$/,ir=/^-?(Infinity|NaN)$/,Ct=/^\s*\+(?=[\w.])|^\s+|\s+$/g,x=function(k,g,q,Q){var V,ee=q?g:g.replace(Ct,"");if(ir.test(ee))k.s=isNaN(ee)?null:ee<0?-1:1;else{if(!q&&(ee=ee.replace(Pe,(function(te,ie,pe){return V=(pe=pe.toLowerCase())=="x"?16:pe=="b"?2:8,Q&&Q!=V?te:ie})),Q&&(V=Q,ee=ee.replace(Ue,"$1").replace(Ve,"0.$1")),g!=ee))return new we(ee,V);if(we.DEBUG)throw Error(m+"Not a"+(Q?" base "+Q:"")+" number: "+g);k.s=null}k.c=k.e=null},Ce.absoluteValue=Ce.abs=function(){var k=new we(this);return k.s<0&&(k.s=1),k},Ce.comparedTo=function(k,g){return T(this,new we(k,g))},Ce.decimalPlaces=Ce.dp=function(k,g){var q,Q,V,ee=this;if(k!=null)return w(k,0,v),g==null?g=Tt:w(g,0,8),ot(new we(ee),k+ee.e+1,g);if(!(q=ee.c))return null;if(Q=((V=q.length-1)-b(this.e/A))*A,V=q[V])for(;V%10==0;V/=10,Q--);return Q<0&&(Q=0),Q},Ce.dividedBy=Ce.div=function(k,g){return M(this,new we(k,g),bt,Tt)},Ce.dividedToIntegerBy=Ce.idiv=function(k,g){return M(this,new we(k,g),0,1)},Ce.exponentiatedBy=Ce.pow=function(k,g){var q,Q,V,ee,te,ie,pe,ye,he=this;if((k=new we(k)).c&&!k.isInteger())throw Error(m+"Exponent not an integer: "+Er(k));if(g!=null&&(g=new we(g)),te=k.e>14,!he.c||!he.c[0]||he.c[0]==1&&!he.e&&he.c.length==1||!k.c||!k.c[0])return ye=new we(Math.pow(+Er(he),te?k.s*(2-P(k)):+Er(k))),g?ye.mod(g):ye;if(ie=k.s<0,g){if(g.c?!g.c[0]:!g.s)return new we(NaN);(Q=!ie&&he.isInteger()&&g.isInteger())&&(he=he.mod(g))}else{if(k.e>9&&(he.e>0||he.e<-1||(he.e==0?he.c[0]>1||te&&he.c[1]>=24e7:he.c[0]<8e13||te&&he.c[0]<=9999975e7)))return ee=he.s<0&&P(k)?-0:0,he.e>-1&&(ee=1/ee),new we(ie?1/ee:ee);zt&&(ee=c(zt/A+2))}for(te?(q=new we(.5),ie&&(k.s=1),pe=P(k)):pe=(V=Math.abs(+Er(k)))%2,ye=new we(Gt);;){if(pe){if(!(ye=ye.times(he)).c)break;ee?ye.c.length>ee&&(ye.c.length=ee):Q&&(ye=ye.mod(g))}if(V){if((V=d(V/2))===0)break;pe=V%2}else if(ot(k=k.times(q),k.e+1,1),k.e>14)pe=P(k);else{if((V=+Er(k))==0)break;pe=V%2}he=he.times(he),ee?he.c&&he.c.length>ee&&(he.c.length=ee):Q&&(he=he.mod(g))}return Q?ye:(ie&&(ye=Gt.div(ye)),g?ye.mod(g):ee?ot(ye,zt,Tt,void 0):ye)},Ce.integerValue=function(k){var g=new we(this);return k==null?k=Tt:w(k,0,8),ot(g,g.e+1,k)},Ce.isEqualTo=Ce.eq=function(k,g){return T(this,new we(k,g))===0},Ce.isFinite=function(){return!!this.c},Ce.isGreaterThan=Ce.gt=function(k,g){return T(this,new we(k,g))>0},Ce.isGreaterThanOrEqualTo=Ce.gte=function(k,g){return(g=T(this,new we(k,g)))===1||g===0},Ce.isInteger=function(){return!!this.c&&b(this.e/A)>this.c.length-2},Ce.isLessThan=Ce.lt=function(k,g){return T(this,new we(k,g))<0},Ce.isLessThanOrEqualTo=Ce.lte=function(k,g){return(g=T(this,new we(k,g)))===-1||g===0},Ce.isNaN=function(){return!this.s},Ce.isNegative=function(){return this.s<0},Ce.isPositive=function(){return this.s>0},Ce.isZero=function(){return!!this.c&&this.c[0]==0},Ce.minus=function(k,g){var q,Q,V,ee,te=this,ie=te.s;if(g=(k=new we(k,g)).s,!ie||!g)return new we(NaN);if(ie!=g)return k.s=-g,te.plus(k);var pe=te.e/A,ye=k.e/A,he=te.c,Me=k.c;if(!pe||!ye){if(!he||!Me)return he?(k.s=-g,k):new we(Me?te:NaN);if(!he[0]||!Me[0])return Me[0]?(k.s=-g,k):new we(he[0]?te:Tt==3?-0:0)}if(pe=b(pe),ye=b(ye),he=he.slice(),ie=pe-ye){for((ee=ie<0)?(ie=-ie,V=he):(ye=pe,V=Me),V.reverse(),g=ie;g--;V.push(0));V.reverse()}else for(Q=(ee=(ie=he.length)<(g=Me.length))?ie:g,ie=g=0;g<Q;g++)if(he[g]!=Me[g]){ee=he[g]<Me[g];break}if(ee&&(V=he,he=Me,Me=V,k.s=-k.s),(g=(Q=Me.length)-(q=he.length))>0)for(;g--;he[q++]=0);for(g=E-1;Q>ie;){if(he[--Q]<Me[Q]){for(q=Q;q&&!he[--q];he[q]=g);--he[q],he[Q]+=E}he[Q]-=Me[Q]}for(;he[0]==0;he.splice(0,1),--ye);return he[0]?da(k,he,ye):(k.s=Tt==3?-1:1,k.c=[k.e=0],k)},Ce.modulo=Ce.mod=function(k,g){var q,Q,V=this;return k=new we(k,g),!V.c||!k.s||k.c&&!k.c[0]?new we(NaN):!k.c||V.c&&!V.c[0]?new we(V):(Nn==9?(Q=k.s,k.s=1,q=M(V,k,0,3),k.s=Q,q.s*=Q):q=M(V,k,0,Nn),(k=V.minus(q.times(k))).c[0]||Nn!=1||(k.s=V.s),k)},Ce.multipliedBy=Ce.times=function(k,g){var q,Q,V,ee,te,ie,pe,ye,he,Me,Fe,ze,nt,St,Nt,xe=this,ut=xe.c,Lt=(k=new we(k,g)).c;if(!(ut&&Lt&&ut[0]&&Lt[0]))return!xe.s||!k.s||ut&&!ut[0]&&!Lt||Lt&&!Lt[0]&&!ut?k.c=k.e=k.s=null:(k.s*=xe.s,ut&&Lt?(k.c=[0],k.e=0):k.c=k.e=null),k;for(Q=b(xe.e/A)+b(k.e/A),k.s*=xe.s,(pe=ut.length)<(Me=Lt.length)&&(nt=ut,ut=Lt,Lt=nt,V=pe,pe=Me,Me=V),V=pe+Me,nt=[];V--;nt.push(0));for(St=E,Nt=f,V=Me;--V>=0;){for(q=0,Fe=Lt[V]%Nt,ze=Lt[V]/Nt|0,ee=V+(te=pe);ee>V;)q=((ye=Fe*(ye=ut[--te]%Nt)+(ie=ze*ye+(he=ut[te]/Nt|0)*Fe)%Nt*Nt+nt[ee]+q)/St|0)+(ie/Nt|0)+ze*he,nt[ee--]=ye%St;nt[ee]=q}return q?++Q:nt.splice(0,1),da(k,nt,Q)},Ce.negated=function(){var k=new we(this);return k.s=-k.s||null,k},Ce.plus=function(k,g){var q,Q=this,V=Q.s;if(g=(k=new we(k,g)).s,!V||!g)return new we(NaN);if(V!=g)return k.s=-g,Q.minus(k);var ee=Q.e/A,te=k.e/A,ie=Q.c,pe=k.c;if(!ee||!te){if(!ie||!pe)return new we(V/0);if(!ie[0]||!pe[0])return pe[0]?k:new we(ie[0]?Q:0*V)}if(ee=b(ee),te=b(te),ie=ie.slice(),V=ee-te){for(V>0?(te=ee,q=pe):(V=-V,q=ie),q.reverse();V--;q.push(0));q.reverse()}for((V=ie.length)-(g=pe.length)<0&&(q=pe,pe=ie,ie=q,g=V),V=0;g;)V=(ie[--g]=ie[g]+pe[g]+V)/E|0,ie[g]=E===ie[g]?0:ie[g]%E;return V&&(ie=[V].concat(ie),++te),da(k,ie,te)},Ce.precision=Ce.sd=function(k,g){var q,Q,V,ee=this;if(k!=null&&k!==!!k)return w(k,1,v),g==null?g=Tt:w(g,0,8),ot(new we(ee),k,g);if(!(q=ee.c))return null;if(Q=(V=q.length-1)*A+1,V=q[V]){for(;V%10==0;V/=10,Q--);for(V=q[0];V>=10;V/=10,Q++);}return k&&ee.e+1>Q&&(Q=ee.e+1),Q},Ce.shiftedBy=function(k){return w(k,-9007199254740991,R),this.times("1e"+k)},Ce.squareRoot=Ce.sqrt=function(){var k,g,q,Q,V,ee=this,te=ee.c,ie=ee.s,pe=ee.e,ye=bt+4,he=new we("0.5");if(ie!==1||!te||!te[0])return new we(!ie||ie<0&&(!te||te[0])?NaN:te?ee:1/0);if((ie=Math.sqrt(+Er(ee)))==0||ie==1/0?(((g=h(te)).length+pe)%2==0&&(g+="0"),ie=Math.sqrt(+g),pe=b((pe+1)/2)-(pe<0||pe%2),q=new we(g=ie==1/0?"5e"+pe:(g=ie.toExponential()).slice(0,g.indexOf("e")+1)+pe)):q=new we(ie+""),q.c[0]){for((ie=(pe=q.e)+ye)<3&&(ie=0);;)if(V=q,q=he.times(V.plus(M(ee,V,ye,1))),h(V.c).slice(0,ie)===(g=h(q.c)).slice(0,ie)){if(q.e<pe&&--ie,(g=g.slice(ie-3,ie+1))!="9999"&&(Q||g!="4999")){+g&&(+g.slice(1)||g.charAt(0)!="5")||(ot(q,q.e+bt+2,1),k=!q.times(q).eq(ee));break}if(!Q&&(ot(V,V.e+bt+2,0),V.times(V).eq(ee))){q=V;break}ye+=4,ie+=4,Q=1}}return ot(q,q.e+bt+1,Tt,k)},Ce.toExponential=function(k,g){return k!=null&&(w(k,0,v),k++),fn(this,k,g,1)},Ce.toFixed=function(k,g){return k!=null&&(w(k,0,v),k=k+this.e+1),fn(this,k,g)},Ce.toFormat=function(k,g,q){var Q,V=this;if(q==null)k!=null&&g&&typeof g=="object"?(q=g,g=null):k&&typeof k=="object"?(q=k,k=g=null):q=dn;else if(typeof q!="object")throw Error(m+"Argument not an object: "+q);if(Q=V.toFixed(k,g),V.c){var ee,te=Q.split("."),ie=+q.groupSize,pe=+q.secondaryGroupSize,ye=q.groupSeparator||"",he=te[0],Me=te[1],Fe=V.s<0,ze=Fe?he.slice(1):he,nt=ze.length;if(pe&&(ee=ie,ie=pe,pe=ee,nt-=ee),ie>0&&nt>0){for(ee=nt%ie||ie,he=ze.substr(0,ee);ee<nt;ee+=ie)he+=ye+ze.substr(ee,ie);pe>0&&(he+=ye+ze.slice(ee)),Fe&&(he="-"+he)}Q=Me?he+(q.decimalSeparator||"")+((pe=+q.fractionGroupSize)?Me.replace(new RegExp("\\d{"+pe+"}\\B","g"),"$&"+(q.fractionGroupSeparator||"")):Me):he}return(q.prefix||"")+Q+(q.suffix||"")},Ce.toFraction=function(k){var g,q,Q,V,ee,te,ie,pe,ye,he,Me,Fe,ze=this,nt=ze.c;if(k!=null&&(!(ie=new we(k)).isInteger()&&(ie.c||ie.s!==1)||ie.lt(Gt)))throw Error(m+"Argument "+(ie.isInteger()?"out of range: ":"not an integer: ")+Er(ie));if(!nt)return new we(ze);for(g=new we(Gt),ye=q=new we(Gt),Q=pe=new we(Gt),Fe=h(nt),ee=g.e=Fe.length-ze.e-1,g.c[0]=O[(te=ee%A)<0?A+te:te],k=!k||ie.comparedTo(g)>0?ee>0?g:ye:ie,te=er,er=1/0,ie=new we(Fe),pe.c[0]=0;he=M(ie,g,0,1),(V=q.plus(he.times(Q))).comparedTo(k)!=1;)q=Q,Q=V,ye=pe.plus(he.times(V=ye)),pe=V,g=ie.minus(he.times(V=g)),ie=V;return V=M(k.minus(q),Q,0,1),pe=pe.plus(V.times(ye)),q=q.plus(V.times(Q)),pe.s=ye.s=ze.s,Me=M(ye,Q,ee*=2,Tt).minus(ze).abs().comparedTo(M(pe,q,ee,Tt).minus(ze).abs())<1?[ye,Q]:[pe,q],er=te,Me},Ce.toNumber=function(){return+Er(this)},Ce.toPrecision=function(k,g){return k!=null&&w(k,1,v),fn(this,k,g,2)},Ce.toString=function(k){var g,q=this,Q=q.s,V=q.e;return V===null?Q?(g="Infinity",Q<0&&(g="-"+g)):g="NaN":(k==null?g=V<=xt||V>=ln?B(h(q.c),V):J(h(q.c),V,"0"):k===10&&Jr?g=J(h((q=ot(new we(q),bt+V+1,Tt)).c),q.e,"0"):(w(k,2,tr.length,"Base"),g=Y(J(h(q.c),V,"0"),10,k,Q,!0)),Q<0&&q.c[0]&&(g="-"+g)),g},Ce.valueOf=Ce.toJSON=function(){return Er(this)},Ce._isBigNumber=!0,Ce[Symbol.toStringTag]="BigNumber",Ce[Symbol.for("nodejs.util.inspect.custom")]=Ce.valueOf,S!=null&&we.set(S),we})();const z={ROUNDING_MODE:K.ROUND_DOWN};function U(y){return new TextEncoder().encode(y)}function F(y){return typeof y=="string"?F(X(y)):new TextDecoder().decode(y)}K.config(z);const ue="UNKNOWN_ERROR",ae="INVALID_ARGUMENT";function re(y,S=ue,M={}){const Y=[];Object.keys(M).forEach((ve=>{try{Y.push(ve+"="+JSON.stringify(M[ve]))}catch{Y.push(ve+"="+JSON.stringify(M[ve].toString()))}}));const x=y;Y.length&&(y+=" ("+Y.join(", ")+")");const se=new Error(y);return se.reason=x,se.code=S,Object.keys(M).forEach((function(ve){se[ve]=M[ve]})),se}function X(y){if(typeof y!="string")throw new Error("hexToBytes only accept strings, got: "+typeof y);if(y.substr(0,2)==="0x")return X(y.substr(2));const S=new Uint8Array(Math.ceil(y.length/2));let M=0;for(let Y=0;Y<y.length;Y+=2){const x=parseInt(y.substr(Y,2),16);if(isNaN(x))throw new Error("Cannot read hex string:"+JSON.stringify(y));S[M]=x,M++}return S}function W(y){return Array.from(y).map((S=>S.toString(16).padStart(2,"0"))).join("")}function $(y,S){if(typeof y=="string"){if(S&&S.encoding==="hex"&&typeof y=="string"){let M=y;M.length>2&&M.substr(0,2)==="0x"&&(M=M.substr(2));const Y=X(M);return u.keccak256(Y)}return u.keccak256(U(y))}return u.keccak256(y)}const D={noether:"0",wei:"1",kwei:"1000",Kwei:"1000",babbage:"1000",femtoether:"1000",mwei:"1000000",Mwei:"1000000",lovelace:"1000000",picoether:"1000000",gwei:"1000000000",Gwei:"1000000000",shannon:"1000000000",nanoether:"1000000000",nano:"1000000000",szabo:"1000000000000",microether:"1000000000000",micro:"1000000000000",finney:"1000000000000000",milliether:"1000000000000000",milli:"1000000000000000",ether:"1000000000000000000",kether:"1000000000000000000000",grand:"1000000000000000000000",mether:"1000000000000000000000000",gether:"1000000000000000000000000000",tether:"1000000000000000000000000000000"};function L(y,S,M){return new Array(S-y.length+1).join(M||"0")+y}function H(y){let S="",M=0;const Y=y.length;for(y.substring(0,2)==="0x"&&(M=2);M<Y;M+=2){const x=parseInt(y.substr(M,2),16);S+=String.fromCharCode(x)}return S}function N(y){return I(y)&&y.name&&y.name.indexOf("(")!==-1?y.name:y.name+"("+Z(!1,y.inputs||[]).join(",")+")"}function j(...y){const S=y.reduce(((x,se)=>x+se.length),0),M=new Uint8Array(S);let Y=0;for(const x of y)M.set(x,Y),Y+=x.length;return M}function Z(y,S){const M=[];return S.forEach((function(Y){if(typeof Y.components=="object"){if(Y.type.substring(0,5)!=="tuple")throw new Error("components found but type is not tuple; report on GitHub");let x="";const se=Y.type.indexOf("[");se>=0&&(x=Y.type.substring(se));const ve=Z(y,Y.components);M.push("("+ve.join(",")+")"+x)}else M.push(Y.type)})),M}function Ee(y){const S=y.indexOf("("),M=y.indexOf(")");return S!==-1&&M!==-1?y.substr(0,S):y}function _e(y){const S=y.indexOf("("),M=y.indexOf(")");return S!==-1&&M!==-1?y.substr(S+1,M-S-1).replace(" ",""):""}function Se(y){return y==null?y:We(y).toNumber()}function Ie(y){return We(y).toNumber()}function ne(y){return C(y)?y.toString(10):""+y}function ce(y){return typeof y=="string"&&!y.startsWith("0x")&&/^[A-Za-z0-9]+$/.test(y)?"0x"+y:Ae(y)}function de(y){if(typeof y=="string")return y.startsWith("0x")&&/^[A-Za-z0-9]+$/.test(y)?Ae(y):"0x"+W(U(y));if(y instanceof Uint8Array)return"0x"+W(y);throw new Error(`toStringData: Error trying to convert ${y} (${typeof y}) to a hex string.`)}function me(y){return typeof y=="boolean"?y:We(y).toNumber()!==0}function Te(y){const S=We(y),M=S.toString(16);return S.isLessThan(0)?"-0x"+M.substr(1):"0x"+M}function Ae(y){if(G(y))return Te(+y);if(C(y))return Te(y);if(_(y)){const S=y;if(S.indexOf("-0x")===0)return Te(S);if(S.indexOf("0x")===0)return S;if(!isFinite(S))return W(U(S))}if(y instanceof Uint8Array)return"0x"+W(y);if(le(y)||I(y))throw new Error("toHex can only be called with scalar values, not objects or arrays");return Te(y)}function Be(y){const S=y?y.toLowerCase():"ether",M=D[S];if(M===void 0)throw new Error("This unit doesn't exists, please use the one of the following units"+JSON.stringify(D,null,2));return new K(M,10)}function We(y){let S=y||0;return C(S)?S:(typeof S=="string"&&(S=S.trim()),typeof S!="string"||S.indexOf("0x")!==0&&S.indexOf("-0x")!==0?S instanceof Uint8Array?new K(W(S),16):new K(S,10):new K(S.replace("0x","").toLowerCase(),16))}function et(y){return new K(new Array(y).fill("1").join(""),2)}function Je(y,S=256){const M=We(y).integerValue();return M.isLessThan(0)?et(S).plus(M).plus(1):M}function st(y,S){return L(y.toString(2),S,"0")[0]==="1"}function Mt(y){if(typeof y!="string")throw re("invalid address",ae,{arg:"address",value:y});if(y.trim().match(/^(0x)?[0-9a-fA-F]{40}$/))return y.trim().substring(0,2)!=="0x"&&(y="0x"+y),Zt(y);throw re("invalid address",ae,{arg:"address",value:y})}function gt(y,S=256){if(st(y,S)){const M=et(S);return y.minus(M).minus(1)}return y}function Ut(y){return/^0x[0-9a-f]{40}$/i.test(y)}function _t(y){return!!/^(0x)?[0-9a-f]{40}$/i.test(y)&&(!(!/^(0x)?[0-9a-f]{40}$/.test(y)&&!/^(0x)?[0-9A-F]{40}$/.test(y))||Qt(y))}function Qt(y){const S=y.replace("0x",""),M=$(S.toLowerCase());for(let Y=0;Y<40;Y++)if(parseInt(M[Y],16)>7&&S[Y].toUpperCase()!==S[Y]||parseInt(M[Y],16)<=7&&S[Y].toLowerCase()!==S[Y])return!1;return!0}function Zt(y){if(y===void 0)return"";const S=y.toLowerCase().replace("0x",""),M=$(S);let Y="0x";for(let x=0;x<S.length;x++)parseInt(M[x],16)>7?Y+=S[x].toUpperCase():Y+=S[x];return Y}function ft(y){if(!Array.isArray(y))throw new Error(`Value was not an array: ${JSON.stringify(y)}`);return y}function _r(y){return Ut(y)?y:/^[0-9a-f]{40}$/.test(y)?"0x"+y:"0x"+L(Ae(y).substr(2),40)}function C(y){return y instanceof K}function _(y){return typeof y=="string"||y&&y.constructor&&y.constructor.name==="String"}function I(y){return y!==null&&!Array.isArray(y)&&typeof y=="object"}function G(y){return typeof y=="boolean"}function le(y){return Array.isArray(y)}var ge,be;function Qe(y,S){if(!y)throw new Error("jsonrpc method should be specified!");if(typeof y!="string")throw new Error(`jsonrpc must be a string, got ${typeof y}!`);return r.messageId++,{jsonrpc:"2.0",id:r.messageId,method:y,params:S||[]}}function At(y){return Array.isArray(y)?y.every(S):S(y);function S(M){return!!M&&(M.error===void 0||M.error===null)&&M.jsonrpc==="2.0"&&M.id!==null&&"result"in M&&M.result!==void 0}}r.TransactionStatus=void 0,(ge=r.TransactionStatus||(r.TransactionStatus={})).pending="pending",ge.confirmed="confirmed",ge.failed="failed",r.TransactionType=void 0,(be=r.TransactionType||(r.TransactionType={})).queued="queued",be.dropped="dropped",be.replaced="replaced",be.pending="pending",be.reverted="reverted",be.confirmed="confirmed",r.messageId=0;function Et(y){return We(y)}function wt(y){return y==="latest"||y==="pending"||y==="earliest"}function rt(y){return y===void 0?"latest":Ft(y)}function Ft(y){return y==null?null:wt(y)?y:Ae(y)}function Ml(y){return y.from&&(y.from=fr(y.from)),y.to&&(y.to=fr(y.to)),y.gasPrice!==void 0&&(y.gasPrice=Te(y.gasPrice)),y.gas!==void 0&&(y.gas=Te(y.gas)),y.value!==void 0&&(y.value=Te(y.value)),y.nonce!==void 0&&(y.nonce=Te(y.nonce)),y.data&&!y.data.startsWith("0x")&&/^[A-Za-z0-9]+$/.test(y.data)&&(y.data="0x"+y.data),y}function ca(y){if(typeof y!="string")throw new Error("The provided input for transactionId is not a string, got: "+JSON.stringify(y));if(y.indexOf("0x")!==0)throw new Error("TransactionID must start with 0x, got: "+JSON.stringify(y));if(y.length!==66)throw new Error("TransactionID must be a 32 byte hex, got: "+JSON.stringify(y));return y}function Cl(y){if(typeof y!="object")throw new Error("Did not provide transaction options");if(!y.from)throw new Error('Missing "from" in transaction options');return y.from=fr(y.from),y.to&&(y.to=fr(y.to)),y.gasPrice!==void 0&&(y.gasPrice=Te(y.gasPrice)),y.gas!==void 0&&(y.gas=Te(y.gas)),y.value!==void 0&&(y.value=Te(y.value)),y.nonce!==void 0&&(y.nonce=Te(y.nonce)),y.data&&!y.data.startsWith("0x")&&/^[A-Za-z0-9]+$/.test(y.data)&&(y.data="0x"+y.data),y}function ts(y){return y?(y.blockNumber!==null&&(y.blockNumber=Ie(y.blockNumber)),y.transactionIndex!==null&&(y.transactionIndex=Ie(y.transactionIndex)),y.nonce=Ie(y.nonce),y.gas=Ie(y.gas),y.gasPrice=We(y.gasPrice),y.value=We(y.value),y):null}function p_(y){return y?(y.blockNumber!==null&&(y.blockNumber=Ie(y.blockNumber)),y.transactionIndex!==null&&(y.transactionIndex=Ie(y.transactionIndex)),y.cumulativeGasUsed=Ie(y.cumulativeGasUsed),y.gasUsed=Ie(y.gasUsed),y.effectiveGasPrice!==void 0&&y.effectiveGasPrice!==null&&(y.effectiveGasPrice=Ie(y.effectiveGasPrice)),y.logs&&le(y.logs)&&(y.logs=y.logs.map((function(S){return Co(S)}))),y.status=Ie(y.status||""),y):null}function rs(y){return y?(y.gasLimit=Ie(y.gasLimit),y.gasUsed=Ie(y.gasUsed),y.size=Ie(y.size),y.timestamp=Ie(y.timestamp),y.number!==null&&(y.number=Ie(y.number)),y.difficulty=We(y.difficulty),y.totalDifficulty=We(y.totalDifficulty),le(y.transactions)&&y.transactions.forEach((function(S,M){_(S)||(y.transactions[M]=ts(S)||y.transactions[M])})),y):null}function Co(y){return y&&(y.blockNumber&&(y.blockNumber=Ie(y.blockNumber)),y.transactionIndex&&(y.transactionIndex=Ie(y.transactionIndex)),y.logIndex&&(y.logIndex=Ie(y.logIndex)),y)}function fr(y){if(Ut(y))return y;if(_t(y))return"0x"+y;throw new Error(`Invalid address: ${JSON.stringify(y)}`)}function m_(y){return y}function h_(y){return y&&(y.startingBlock=Ie(y.startingBlock),y.currentBlock=Ie(y.currentBlock),y.highestBlock=Ie(y.highestBlock),y.knownStates&&(y.knownStates=Ie(y.knownStates),y.pulledStates=Ie(y.pulledStates)),y)}function Dl(y){if(y===null)throw re("cannot convert null value to array",ae,{arg:"value",value:y});if(y instanceof Uint8Array)return new Uint8Array(y);if(typeof y=="string"){const S=y.match(/^(0x)?[0-9a-fA-F]*$/);if(!S)throw re("invalid hexidecimal string",ae,{arg:"value",value:y});if(S[1]!=="0x")throw re("hex string must have 0x prefix",ae,{arg:"value",value:y});(y=y.substring(2)).length%2&&(y="0"+y);const M=[];for(let Y=0;Y<y.length;Y+=2)M.push(parseInt(y.substr(Y,2),16));return new Uint8Array(M)}if((function(S){if(!S||parseInt(String(S.length))!==S.length||typeof S=="string")return!1;for(let M=0;M<S.length;M++){const Y=S[M];if(Y<0||Y>=256||parseInt(String(Y))!==Y)return!1}return!0})(y))return new Uint8Array(y);throw re("invalid arrayify value",void 0,{arg:"value",value:y,type:typeof y})}function y_(y,S,M){Object.defineProperty(y,S,{enumerable:!0,value:M,writable:!1})}const xP=new K(-1),eM=new K(0),tM=new K(1),g_=new K("0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff");function __(y){return(function(S,M){function Y(ve){return new Error('unexpected character "'+S[ve]+'" at position '+ve+' in "'+S+'"')}const x={type:"",name:"",state:{allowType:!0}};let se=x;for(let ve=0;ve<S.length;ve++){const Pe=S[ve];switch(Pe){case"(":if(!se.state.allowParams)throw Y(ve);se.state.allowType=!1,se.type=ns(se.type),se.components=[{type:"",name:"",parent:se,state:{allowType:!0}}],se=se.components[0];break;case")":delete se.state,se.name==="indexed"&&(se.indexed=!0,se.name=""),se.type=ns(se.type);const Ue=se;if(se=se.parent,!se)throw Y(ve);delete Ue.parent,se.state.allowParams=!1,se.state.allowName=!0,se.state.allowArray=!0;break;case",":delete se.state,se.name==="indexed"&&(se.indexed=!0,se.name=""),se.type=ns(se.type);const Ve={type:"",name:"",parent:se.parent,state:{allowType:!0}};se.parent.components.push(Ve),delete se.parent,se=Ve;break;case" ":se.state.allowType&&se.type!==""&&(se.type=ns(se.type),delete se.state.allowType,se.state.allowName=!0,se.state.allowParams=!0),se.state.allowName&&se.name!==""&&(se.name==="indexed"?(se.indexed=!0,se.name=""):se.state.allowName=!1);break;case"[":if(!se.state.allowArray)throw Y(ve);se.type+=Pe,se.state.allowArray=!1,se.state.allowName=!1,se.state.readArray=!0;break;case"]":if(!se.state.readArray)throw Y(ve);se.type+=Pe,se.state.readArray=!1,se.state.allowArray=!0,se.state.allowName=!0;break;default:if(se.state.allowType)se.type+=Pe,se.state.allowParams=!0,se.state.allowArray=!0;else if(se.state.allowName)se.name+=Pe,delete se.state.allowArray;else{if(!se.state.readArray)throw Y(ve);se.type+=Pe}}}if(se.parent)throw new Error("unexpected eof");return delete x.state,se.name==="indexed"&&(se.indexed=!0,se.name=""),x.type=ns(x.type),x})(y)}function ns(y){return y.match(/^uint($|[^1-9])/)?y="uint256"+y.substring(4):y.match(/^int($|[^1-9])/)&&(y="int256"+y.substring(3)),y}const rM=new RegExp(/^bytes([0-9]*)$/),E_=new RegExp(/^(u?int)([0-9]*)$/),nM=new RegExp(/^(.*)\[([0-9]*)\]$/),iM=function(y,S){const M=y.match(E_);return M&&parseInt(M[2])<=48?S.toNumber():S};class Wr{constructor(S,M,Y,x="",se){this.coerceFunc=S,this.name=M,this.type=Y,this.localName=x,this.dynamic=se}}class aM extends Wr{constructor(S){super(S.coerceFunc,S.name,S.type,void 0,S.dynamic),y_(this,"coder",S)}encode(S){return this.coder.encode(S)}decode(S,M){return this.coder.decode(S,M)}}class sM extends Wr{constructor(S,M){super(S,"null","",M,!1)}encode(S){return Dl([])}decode(S,M){if(M>S.length)throw new Error("invalid null");return{consumed:0,value:this.coerceFunc("null",void 0)}}}function Do(y,S){return new K(y.toString(2).substr(-S),2)}class v_ extends Wr{constructor(S,M,Y,x){const se=(Y?"int":"uint")+8*M;super(S,se,se,x,!1),this.size=M,this.signed=Y}encode(S){try{let M=We(S);if(this.signed){let x=Do(g_,8*this.size-1);if(M.gt(x))throw new Error("out-of-bounds");if(x=x.plus(tM).multipliedBy(xP),M.lt(x))throw new Error("out-of-bounds")}else if(M.lt(eM)||M.gt(Do(g_,8*this.size)))throw new Error("out-of-bounds");M=Do(Je(M,8*this.size),8*this.size),this.signed&&(M=Je(gt(M,8*this.size),256));const Y=L(Je(M).toString(16),64);if(Y.indexOf("NaN")!==-1)throw re("invalid number value, NaN",ae,{arg:this.localName,coderType:this.name,value:S,v:M,twosComplement:Je(M),twosComplement16:Je(M).toString(16),pad:L(Je(M).toString(16),64),size:this.size});return X(Y)}catch(M){throw re("invalid number value",ae,{arg:this.localName,coderType:this.name,value:S,message:M.toString()})}}decode(S,M){if(S.length<M+32)throw re("insufficient data for "+this.name+" type",ae,{arg:this.localName,coderType:this.name,value:Ae(S.slice(M,M+32))});const Y=32-this.size;let x=new K(W(S.slice(M+Y,M+32)),16);return x=this.signed?gt(x,8*this.size):Do(x,8*this.size),{consumed:32,value:this.coerceFunc(this.name,x)}}}const cn=new v_((function(y,S){return S}),32,!1,"none");class b_ extends Wr{constructor(S,M,Y){const x="bytes"+M;super(S,x,x,Y,!1),this.length=M}encode(S){const M=new Uint8Array(32);try{if(typeof S=="string"&&S.length%2!=0)throw new Error("hex string cannot be odd-length");const Y=Dl(S);if(Y.length>this.length)throw new Error("incorrect data length");M.set(Y)}catch(Y){throw re("invalid "+this.name+" value. Use hex strings or Uint8Array",ae,{arg:this.localName,coderType:this.name,value:Y.value||S,details:Y.message})}return M}decode(S,M){if(S.length<M+32)throw re("insufficient data for "+this.name+" type",ae,{arg:this.localName,coderType:this.name,value:Ae(S.slice(M,M+32))});return{consumed:32,value:this.coerceFunc(this.name,S.slice(M,M+this.length))}}}function T_(y){const S=32*Math.ceil(y.length/32),M=new Uint8Array(S-y.length);return j(cn.encode(y.length),y,M)}function S_(y,S,M){if(y.length<S+32)throw re("insufficient data for dynamicBytes length",ae,{arg:M,coderType:"dynamicBytes",value:Ae(y.slice(S,S+32))});let Y=cn.decode(y,S).value;try{Y=Y.toNumber()}catch(x){throw x("dynamic bytes count too large",ae,{arg:M,coderType:"dynamicBytes",value:Y.toString()})}if(y.length<S+32+Y)throw re("insufficient data for dynamicBytes type",ae,{arg:M,coderType:"dynamicBytes",value:Ae(y.slice(S,S+32+Y))});return{consumed:32+32*Math.ceil(Y/32),value:y.slice(S+32,S+32+Y)}}function jo(y){return 32*Math.ceil(y/32)}function I_(y,S){if(!Array.isArray(S)){if(!S||typeof S!="object")throw re("invalid tuple value",ae,{coderType:"tuple",value:S});{const Ue=[];y.forEach((function(Ve){Ue.push(S[Ve.localName])})),S=Ue}}if(y.length!==S.length)throw re("types/value length mismatch",ae,{coderType:"tuple",value:S});const M=[];y.forEach((function(Ue,Ve){M.push({dynamic:Ue.dynamic,value:Ue.encode(S[Ve])})}));let Y=0,x=0;M.forEach((function(Ue){Ue.dynamic?(Y+=32,x+=jo(Ue.value.length)):Y+=jo(Ue.value.length)}));let se=0,ve=Y;const Pe=new Uint8Array(Y+x);return M.forEach((function(Ue){Ue.dynamic?(Pe.set(cn.encode(ve),se),se+=32,Pe.set(Ue.value,ve),ve+=jo(Ue.value.length)):(Pe.set(Ue.value,se),se+=jo(Ue.value.length))})),Pe}class oM extends Array{}class uM extends Wr{constructor(S,M,Y,x){super(S,"array",M.type+"["+(Y>=0?Y:"")+"]",x,Y===-1||M.dynamic),this.coder=M,this.length=Y}encode(S){if(!Array.isArray(S))throw re("expected array value",ae,{arg:this.localName,coderType:"array",value:S});let M=this.length,Y=new Uint8Array(0);M===-1&&(M=S.length,Y=cn.encode(M)),(function(se,ve,Pe){if(Pe||(Pe=""),se<ve)throw re("missing argument"+Pe,"MISSING_ARGUMENT",{count:se,expectedCount:ve});if(se>ve)throw re("too many arguments"+Pe,"UNEXPECTED_ARGUMENT",{count:se,expectedCount:ve})})(M,S.length,"in coder array"+(this.localName?" "+this.localName:""));const x=[];for(let se=0;se<S.length;se++)x.push(this.coder);return j(Y,I_(x,S))}decode(S,M){let Y=0,x=this.length;if(x===-1){let Pe;try{Pe=cn.decode(S,M)}catch(Ue){throw re("insufficient data for dynamic array length",ae,{arg:this.localName,coderType:"array",value:Ue.value})}try{x=Pe.value.toNumber()}catch{throw re("array count too large",ae,{arg:this.localName,coderType:"array",value:Pe.value.toString()})}Y+=Pe.consumed,M+=Pe.consumed}const se=[];for(let Pe=0;Pe<x;Pe++)se.push(new aM(this.coder));const ve=(function(Pe,Ue,Ve){const ir=Ve;let Ct=0;const Ce=[];return Pe.forEach((function(Gt){let bt;if(Gt.dynamic){const Tt=cn.decode(Ue,Ve);bt=Gt.decode(Ue,ir+Tt.value.toNumber()),bt.consumed=Tt.consumed}else bt=Gt.decode(Ue,Ve);bt.value!==void 0&&Ce.push(bt.value),Ve+=bt.consumed,Ct+=bt.consumed})),{value:Ce,consumed:Ct}})(se,S,M);return ve.consumed+=Y,ve.value=this.coerceFunc(this.type,ve.value),ve}}class jl extends Wr{constructor(S,M,Y){let x=!1;const se=[];M.forEach((function(ve){ve.dynamic&&(x=!0),se.push(ve.type)})),super(S,"tuple","tuple("+se.join(",")+")",Y,x),this.coders=M}encode(S){return I_(this.coders,S)}decode(S,M){const Y=(function(x,se,ve){const Pe=ve;let Ue=0;const Ve=new oM;return x.forEach((function(ir){let Ct;if(ir.dynamic){const Ce=cn.decode(se,ve);Ct=ir.decode(se,Pe+Ce.value.toNumber()),Ct.consumed=Ce.consumed}else Ct=ir.decode(se,ve);Ct.value!==void 0&&Ve.push(Ct.value),ve+=Ct.consumed,Ue+=Ct.consumed})),x.forEach((function(ir,Ct){let Ce=ir.localName;Ce&&(Ce==="length"&&(Ce="_length"),Ve[Ce]!==null&&Ve[Ce]!==void 0||(Ve[Ce]=Ve[Ct]))})),{value:Ve,consumed:Ue}})(this.coders,S,M);return Y.value=this.coerceFunc(this.type,Y.value),Y}}const cM={address:class extends Wr{constructor(y,S){super(y,"address","address",S,!1)}encode(y){const S=new Uint8Array(32),M=y.trim();if(!_t(M))throw re("invalid address format",ae,{arg:this.localName,coderType:"address",value:y});try{S.set(X(fr(M)),12)}catch(Y){throw re(`invalid address (${Y.message})`,ae,{arg:this.localName,coderType:"address",value:y})}return S}decode(y,S){if(y.length<S+32)throw re("insufficuent data for address type",ae,{arg:this.localName,coderType:"address",value:Ae(y.slice(S,S+32)),missingBytes:S+32-y.length});return{consumed:32,value:this.coerceFunc("address",Mt(Ae(y.slice(S+12,S+32))))}}},bool:class extends Wr{constructor(y,S){super(y,"bool","bool",S,!1)}encode(y){return cn.encode(y?1:0)}decode(y,S){try{const M=cn.decode(y,S);return{consumed:M.consumed,value:this.coerceFunc("bool",!M.value.isZero())}}catch(M){throw M.reason==="insufficient data for uint256 type"?re("insufficient data for boolean type",ae,{arg:this.localName,coderType:"boolean",value:M.value}):M}}},string:class extends Wr{constructor(y,S){super(y,"string","string",S,!0)}encode(y){if(typeof y!="string")throw re("invalid string value",ae,{arg:this.localName,coderType:"string",value:y});return T_(U(y))}decode(y,S){const M=S_(y,S,this.localName);return M.value=this.coerceFunc("string",F(M.value)),M}},bytes:class extends Wr{constructor(y,S){super(y,"bytes","bytes",S,!0)}encode(y){try{return T_(Dl(y))}catch(S){throw S("invalid bytes value",ae,{arg:this.localName,coderType:"bytes",value:S.value})}}decode(y,S){const M=S_(y,S,this.localName);return M.value=this.coerceFunc("bytes",M.value),M}},function:class extends b_{constructor(y,S){super(y,24,S)}}};function $o(y,S){const M=cM[S.type];if(M)return new M(y,S.name);let Y=S.type.match(E_);if(Y){const x=parseInt(Y[2]||"256");if(x===0||x>256||x%8!=0)throw re("invalid "+Y[1]+" bit length",ae,{arg:"param",value:S});return new v_(y,x/8,Y[1]==="int",S.name)}if(Y=S.type.match(rM),Y){const x=parseInt(Y[1]);if(x===0||x>32)throw re("invalid bytes length",ae,{arg:"param",value:S});return new b_(y,x,S.name)}if(Y=S.type.match(nM),Y){const x=Object.assign({},S),se=parseInt(Y[2]||"-1");return x.type=Y[1],new uM(y,$o(y,x),se,S.name)}if(S.type.substring(0,5)==="tuple")return(function(x,se,ve){se||(se=[]);const Pe=se.map((Ue=>$o(x,Ue)));return new jl(x,Pe,ve)})(y,S.components,S.name);if(S.type==="")return new sM(y,S.name);throw re("invalid type",ae,{arg:"type",value:S.type,fullType:S})}class $l{constructor(S){(function(M,Y){if(!(M instanceof Y))throw re("missing new","MISSING_NEW",{name:Y.name})})(this,$l),S||(S=iM),y_(this,"coerceFunc",S)}encode(S,M){if(S.length!==M.length)throw re("types/values length mismatch",ae,{count:{types:S.length,values:M.length},value:{types:S,values:M}});const Y=S.map((x=>typeof x=="string"?__(x):x)).map((x=>$o(this.coerceFunc,x)));return new jl(this.coerceFunc,Y,"_").encode(M)}decode(S,M){const Y=S.map((x=>typeof x=="string"?__(x):x)).map((x=>$o(this.coerceFunc,x)));return new jl(this.coerceFunc,Y,"_").decode(M,0).value}}const R_=new $l;var A_,$e;function Le(y,S,M,Y){var x,se=arguments.length,ve=se<3?S:Y;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")ve=Reflect.decorate(y,S,M,Y);else for(var Pe=y.length-1;Pe>=0;Pe--)(x=y[Pe])&&(ve=(se<3?x(ve):se>3?x(S,M,ve):x(S,M))||ve);return se>3&&ve&&Object.defineProperty(S,M,ve),ve}function qe(y,S){if(typeof Reflect=="object"&&typeof Reflect.metadata=="function")return Reflect.metadata(y,S)}r.coder=void 0,(A_=r.coder||(r.coder={})).encodeParams=function(y,S){return W(R_.encode(y,S))},A_.decodeParams=function(y,S){if(y.length>0&&(!S||S==="0x"||S==="0X"))throw new Error("Returned values aren't valid, did it run Out of Gas? You might also see this error if you are not using the correct ABI for the contract you are retrieving data from, requesting data from a block number that does not exist, or querying a node which is not fully synced.");return R_.decode(y,X("0x"+S.replace(/0x/i,"")))},typeof SuppressedError=="function"&&SuppressedError;class He{constructor(S){this.callName=S.callName,this.params=S.params||0,this.inputFormatter=S.inputFormatter||null,this.outputFormatter=S.outputFormatter}validateArgs(S){if(S.length!==this.params)throw M=this.callName,Y=S.length,x=this.params,new Error(`Invalid number of input parameters to RPC method "${M}" given: ${Y}, expected: ${x}`);var M,Y,x}formatInput(S){return this.inputFormatter?this.inputFormatter.map((function(M,Y){return M?M(S[Y]):S[Y]})):S}formatOutput(S){return S!==null?this.outputFormatter(S):null}toPayload(S){const M=this.formatInput(S);return this.validateArgs(M),{method:this.callName,params:M}}async execute(S,...M){const Y=this.toPayload(M);if(!S)throw new Error("Missing RequestManager in method#exec");const x=await S.sendAsync(Y);return this.formatOutput(x)}}class pr{constructor(S){this.getter=S.getter,this.outputFormatter=S.outputFormatter}formatOutput(S){return this.outputFormatter(S)}async execute(S,...M){const Y=await S.sendAsync({method:this.getter,params:[]});return this.formatOutput(Y)}}function w_(y){return new Promise((S=>setTimeout(S,y)))}r.eth=void 0,($e=r.eth||(r.eth={})).eth_getBalance=new He({callName:"eth_getBalance",params:2,inputFormatter:[fr,rt],outputFormatter:Et}),$e.eth_getStorageAt=new He({callName:"eth_getStorageAt",params:3,inputFormatter:[fr,Ae,rt],outputFormatter:ce}),$e.eth_getCode=new He({callName:"eth_getCode",params:2,inputFormatter:[fr,rt],outputFormatter:ce}),$e.eth_getBlockByHash=new He({callName:"eth_getBlockByHash",params:2,inputFormatter:[Ft,function(y){return!!y}],outputFormatter:rs}),$e.eth_getBlockByNumber=new He({callName:"eth_getBlockByNumber",params:2,inputFormatter:[Ft,function(y){return!!y}],outputFormatter:rs}),$e.eth_getUncleByBlockHashAndIndex=new He({callName:"eth_getUncleByBlockHashAndIndex",params:2,inputFormatter:[Ft,Ae],outputFormatter:rs}),$e.eth_getUncleByBlockNumberAndIndex=new He({callName:"eth_getUncleByBlockNumberAndIndex",params:2,inputFormatter:[Ft,Ae],outputFormatter:rs}),$e.eth_getBlockTransactionCountByHash=new He({callName:"eth_getBlockTransactionCountByHash",params:1,inputFormatter:[Ft],outputFormatter:Ie}),$e.eth_getBlockTransactionCountByNumber=new He({callName:"eth_getBlockTransactionCountByNumber",params:1,inputFormatter:[Ft],outputFormatter:Ie}),$e.eth_getUncleCountByBlockHash=new He({callName:"eth_getUncleCountByBlockHash",params:1,inputFormatter:[Ft],outputFormatter:Ie}),$e.eth_getUncleCountByBlockNumber=new He({callName:"eth_getUncleCountByBlockNumber",params:1,inputFormatter:[Ft],outputFormatter:Ie}),$e.eth_getTransactionByHash=new He({callName:"eth_getTransactionByHash",params:1,inputFormatter:[ca],outputFormatter:ts}),$e.eth_getTransactionByBlockHashAndIndex=new He({callName:"eth_getTransactionByBlockHashAndIndex",params:2,inputFormatter:[Ft,Ae],outputFormatter:ts}),$e.eth_getTransactionByBlockNumberAndIndex=new He({callName:"eth_getTransactionByBlockNumberAndIndex",params:2,inputFormatter:[Ft,Ae],outputFormatter:ts}),$e.eth_getTransactionReceipt=new He({callName:"eth_getTransactionReceipt",params:1,inputFormatter:[ca],outputFormatter:p_}),$e.eth_getTransactionCount=new He({callName:"eth_getTransactionCount",params:2,inputFormatter:[fr,rt],outputFormatter:Ie}),$e.eth_sendRawTransaction=new He({callName:"eth_sendRawTransaction",params:1,inputFormatter:[null],outputFormatter:ce}),$e.web3_sha3=new He({callName:"web3_sha3",params:1,inputFormatter:[null],outputFormatter:ce}),$e.eth_sendTransaction=new He({callName:"eth_sendTransaction",params:1,inputFormatter:[Cl],outputFormatter:ce}),$e.eth_sign=new He({callName:"eth_sign",params:2,inputFormatter:[fr,null],outputFormatter:ce}),$e.eth_call=new He({callName:"eth_call",params:2,inputFormatter:[Ml,rt],outputFormatter:ce}),$e.eth_estimateGas=new He({callName:"eth_estimateGas",params:1,inputFormatter:[Ml],outputFormatter:Ie}),$e.eth_submitWork=new He({callName:"eth_submitWork",params:3,inputFormatter:[null,null,null],outputFormatter:me}),$e.eth_getWork=new He({callName:"eth_getWork",params:0,inputFormatter:[],outputFormatter:ft}),$e.eth_coinbase=new pr({getter:"eth_coinbase",outputFormatter:_r}),$e.eth_mining=new pr({getter:"eth_mining",outputFormatter:me}),$e.eth_hashrate=new pr({getter:"eth_hashrate",outputFormatter:Ie}),$e.eth_syncing=new pr({getter:"eth_syncing",outputFormatter:h_}),$e.eth_gasPrice=new pr({getter:"eth_gasPrice",outputFormatter:Et}),$e.eth_accounts=new pr({getter:"eth_accounts",outputFormatter:ft}),$e.eth_blockNumber=new pr({getter:"eth_blockNumber",outputFormatter:Ie}),$e.eth_protocolVersion=new pr({getter:"eth_protocolVersion",outputFormatter:Ie}),$e.web3_clientVersion=new pr({getter:"web3_clientVersion",outputFormatter:ne}),$e.net_version=new pr({getter:"net_version",outputFormatter:ne}),$e.shh_version=new He({callName:"shh_version",params:0,inputFormatter:[],outputFormatter:Ie}),$e.shh_post=new He({callName:"shh_post",params:1,inputFormatter:[null],outputFormatter:me}),$e.personal_newAccount=new He({callName:"personal_newAccount",params:1,inputFormatter:[null],outputFormatter:_r}),$e.personal_importRawKey=new He({callName:"personal_importRawKey",params:2,inputFormatter:[null,null],outputFormatter:_r}),$e.personal_sign=new He({callName:"personal_sign",params:3,inputFormatter:[de,fr,null],outputFormatter:ce}),$e.personal_ecRecover=new He({callName:"personal_ecRecover",params:2,inputFormatter:[de,null],outputFormatter:_r}),$e.personal_unlockAccount=new He({callName:"personal_unlockAccount",params:3,inputFormatter:[fr,null,Se],outputFormatter:me}),$e.personal_sendTransaction=new He({callName:"personal_sendTransaction",params:2,inputFormatter:[Cl,null],outputFormatter:ce}),$e.personal_lockAccount=new He({callName:"personal_lockAccount",params:1,inputFormatter:[fr],outputFormatter:me}),$e.personal_listAccounts=new pr({getter:"personal_listAccounts",outputFormatter:ft}),$e.net_listening=new pr({getter:"net_listening",outputFormatter:me}),$e.net_peerCount=new pr({getter:"net_peerCount",outputFormatter:Ie}),$e.eth_newFilter=new He({callName:"eth_newFilter",params:1,inputFormatter:[m_],outputFormatter:Ae}),$e.eth_getLogs=new He({callName:"eth_getLogs",params:1,inputFormatter:[ft],outputFormatter:ft}),$e.eth_newBlockFilter=new He({callName:"eth_newBlockFilter",params:0,inputFormatter:[],outputFormatter:Ae}),$e.eth_newPendingTransactionFilter=new He({callName:"eth_newPendingTransactionFilter",params:0,inputFormatter:[],outputFormatter:Ae}),$e.eth_uninstallFilter=new He({callName:"eth_uninstallFilter",params:1,inputFormatter:[Ae],outputFormatter:me}),$e.eth_getFilterLogs=new He({callName:"eth_getFilterLogs",params:1,inputFormatter:[Ae],outputFormatter:ft}),$e.eth_getFilterChanges=new He({callName:"eth_getFilterChanges",params:1,inputFormatter:[Ae],outputFormatter:ft}),$e.eth_submitHashrate=new He({callName:"eth_submitHashrate",params:2,inputFormatter:[null,null],outputFormatter:me}),$e.shh_newIdentity=new He({callName:"shh_newIdentity",params:0,inputFormatter:[],outputFormatter:ce}),$e.shh_hasIdentity=new He({callName:"shh_hasIdentity",params:1,inputFormatter:[null],outputFormatter:me}),$e.shh_newGroup=new He({callName:"shh_newGroup",params:0,inputFormatter:[],outputFormatter:ce}),$e.shh_addToGroup=new He({callName:"shh_addToGroup",params:1,inputFormatter:[null],outputFormatter:me}),$e.shh_newFilter=new He({callName:"shh_newFilter",params:1,inputFormatter:[null],outputFormatter:Ae}),$e.shh_uninstallFilter=new He({callName:"shh_uninstallFilter",params:1,inputFormatter:[null],outputFormatter:me}),$e.shh_getLogs=new He({callName:"shh_getLogs",params:1,inputFormatter:[null],outputFormatter:ft}),$e.shh_getFilterMessages=new He({callName:"shh_getFilterMessages",params:1,inputFormatter:[null],outputFormatter:ft}),$e.shh_getFilterChanges=new He({callName:"shh_getFilterChanges",params:1,inputFormatter:[null],outputFormatter:ft}),$e.shh_getMessages=new He({callName:"shh_getMessages",params:1,inputFormatter:[null],outputFormatter:ft});function ke(y,S){const M=r.eth[S];if(!M)throw new Error(`Could not find the method/property named ${S.toString()}`);Object.defineProperty(y,S,{value:function(...Y){return M.execute(this,...Y)}})}class je{constructor(S){this.provider=S,this.requests=new Map}async sendAsync(S){const M=await this.provider;if(!M)throw new Error("Provider not set or invalid");const Y=Qe(S.method,S.params),x=s();return this.requests.set(Y.id,x),M.sendAsync(Y,((se,ve)=>{this.requests.delete(Y.id),se?x.reject(se):At(ve)?x.resolve(ve.result):x.reject((function(Pe){const Ue=Pe&&Pe.error&&Pe.error.message?Pe.error.message:"Invalid JSON RPC response: "+JSON.stringify(Pe);return new Error(Ue)})(ve))})),x}setProvider(S){this.provider=S}async getConfirmedTransaction(S){const M=await this.waitForCompletion(S);if(this.isFailure(M))throw new Error(`Transaction "${S}" failed`);return M}async waitForCompletion(S,M){const Y=ca(S);if(await this.isTxDropped(Y,M)){const x=await this.getTransactionAndReceipt(Y);return Object.assign(Object.assign({},x),{status:r.TransactionStatus.failed})}for(;;){const x=await this.getTransactionAndReceipt(Y);if(!this.isPending(x)&&x.receipt)return Object.assign(Object.assign({},x),{status:this.isFailure(x)?r.TransactionStatus.failed:r.TransactionStatus.confirmed});await w_(2e3)}}async getTransaction(S){let M,Y=null;const x=ca(S);try{const ve=(await this.eth_accounts())[0];ve&&(Y=await this.eth_getTransactionCount(ve,"latest"))}catch{Y=null}try{if(M=await this.eth_getTransactionByHash(x),M===null)return null}catch{return null}if(M.blockNumber===null){if(Y!==null){if(M.nonce<Y)return{hash:x,type:r.TransactionType.replaced,nonce:M.nonce};if(M.nonce>Y)return{hash:x,type:r.TransactionType.queued,nonce:M.nonce}}return Object.assign({type:r.TransactionType.pending},M)}let se;try{if(se=await this.eth_getTransactionReceipt(x),se===null||se.status===0)return Object.assign({type:r.TransactionType.reverted},M)}catch{return null}return Object.assign(Object.assign({type:r.TransactionType.confirmed},M),{receipt:se})}async isTxDropped(S,M=15){let Y=M;for(;Y>0;){if(await this.getTransactionAndReceipt(S)!==null)return!1;Y-=1,await w_(2e3)}return!0}async getTransactionAndReceipt(S){S=ca(S);const[M,Y]=await Promise.all([this.eth_getTransactionByHash(S),this.eth_getTransactionReceipt(S)]);return Object.assign(Object.assign({},M),{receipt:Y})}isPending(S){return S&&S.blockNumber===null}isFailure(S){return S&&(!S.receipt||S.receipt.status===0)}}Le([ke,qe("design:type",Function)],je.prototype,"web3_clientVersion",void 0),Le([ke,qe("design:type",Function)],je.prototype,"web3_sha3",void 0),Le([ke,qe("design:type",Function)],je.prototype,"net_version",void 0),Le([ke,qe("design:type",Function)],je.prototype,"net_peerCount",void 0),Le([ke,qe("design:type",Function)],je.prototype,"net_listening",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_protocolVersion",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_syncing",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_coinbase",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_mining",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_hashrate",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_gasPrice",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_accounts",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_blockNumber",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getBalance",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getStorageAt",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getTransactionCount",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getBlockTransactionCountByHash",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getBlockTransactionCountByNumber",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getUncleCountByBlockHash",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getUncleCountByBlockNumber",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getCode",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_sign",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_sendTransaction",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_sendRawTransaction",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_call",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_estimateGas",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getBlockByHash",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getBlockByNumber",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getTransactionByHash",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getTransactionByBlockHashAndIndex",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getTransactionByBlockNumberAndIndex",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getTransactionReceipt",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getUncleByBlockHashAndIndex",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getUncleByBlockNumberAndIndex",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_newFilter",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_newBlockFilter",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_newPendingTransactionFilter",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_uninstallFilter",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getFilterChanges",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getFilterLogs",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getLogs",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_getWork",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_submitWork",void 0),Le([ke,qe("design:type",Function)],je.prototype,"eth_submitHashrate",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_post",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_version",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_newIdentity",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_hasIdentity",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_newGroup",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_addToGroup",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_newFilter",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_uninstallFilter",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_getFilterChanges",void 0),Le([ke,qe("design:type",Function)],je.prototype,"shh_getMessages",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_unlockAccount",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_newAccount",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_listAccounts",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_lockAccount",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_importRawKey",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_sendTransaction",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_sign",void 0),Le([ke,qe("design:type",Function)],je.prototype,"personal_ecRecover",void 0);class O_{constructor(S){this.json=S,this._inputTypes=S.inputs||[],this._outputTypes=S.outputs||[],this._constant=!!S.constant,this._payable=!!S.payable||S.stateMutability==="payable",this.needsToBeTransaction=this._payable||"constant"in S&&!S.constant||S.stateMutability==="nonpayable",this._name=N(S)}extractDefaultBlock(S){return S.length>this._inputTypes.length&&!I(S[S.length-1])&&rt(S.pop())||"latest"}validateArgs(S){if(S.some((se=>se===void 0)))throw new Error("Invalid call, some arguments are undefined");const M=S.filter((function(se){return!(I(se)===!0&&le(se)===!1&&C(se)===!1&&!(se instanceof Uint8Array))}));if(M.length!==this._inputTypes.length)throw Y=M.length,x=this._inputTypes.length,new Error(`Invalid number of arguments to Solidity function. given: ${Y}, expected: ${x}`);var Y,x}toPayload(S){let M={to:void 0,data:void 0,value:void 0,from:void 0};S.length>this._inputTypes.length&&I(S[S.length-1])&&(M=S.pop()),this.validateArgs(S);const Y=this.signature();let x=r.coder.encodeParams(this._inputTypes,S);return x.indexOf("0x")===0&&(x=x.substr(2)),M.data="0x"+Y+x,M}signature(){return $(this._name).slice(0,8)}unpackOutput(S){if(!S)return;const M=S.length>=2?S.slice(2):S,Y=r.coder.decodeParams(this._outputTypes,M);return Y.length===1?Y[0]:Y}async execute(S,M,...Y){if(!S)throw new Error(`Cannot call function ${this.displayName()} because there is no requestManager`);if(this.needsToBeTransaction){const x=this.toPayload(Y);if(x.to=M,x.value>0&&!this._payable)throw new Error("Cannot send value to non-payable function");if(!x.from)throw new Error('Missing "from" in transaction options');return await S.eth_sendTransaction(x)}{const x=this.extractDefaultBlock(Y),se=this.toPayload(Y);se.to=M;const ve=await S.eth_call(se,x);return this.unpackOutput(ve)}}estimateGas(S,M,...Y){if(!(S instanceof je))throw new Error("estimateGas needs to receive a RequestManager as first argument");const x=this.toPayload(Y);return x.to=M,S.eth_estimateGas(x)}displayName(){return Ee(this._name)}typeName(){return _e(this._name)||"void"}attachToContract(S){const M=this.displayName(),Y=Object.assign(((...x)=>this.execute(S.requestManager,S.address,...x)),{estimateGas:this.estimateGas.bind(this,S.requestManager,S.address),toPayload:(...x)=>this.toPayload(x),toRPCMessage:(...x)=>{const se=this.extractDefaultBlock(x),ve=this.toPayload(x);return ve.to=S.address,{method:"eth_call",params:[ve,se]}},unpackOutput:x=>this.unpackOutput(x)});S[M]||(S[M]=Y),S[M][this.typeName()]=Y}}function N_(y){if(y==null)return null;const S=String(y).toString();return S.indexOf("0x")===0?S:W(U(S))}class Ll{constructor(S){this.requestManager=S,this.isStarted=!1,this.isDisposed=!1,this.formatter=M=>M,this.filterId=s(),this.callbacks=[],this.stopSemaphore=s()}async watch(S){if(this.isDisposed)throw new Error("The filter was disposed");S&&(this.callbacks.push(S),this.isStarted||await this.start())}async start(){if(this.isDisposed)throw new Error("The filter was disposed");if(!this.isStarted){this.isStarted=!0;try{const S=await this.getNewFilter();if(!S)throw new Error("Could not create a filter, response: "+JSON.stringify(S));this.filterId.resolve(S)}catch(S){throw S}this.stopSemaphore=s(),await this.poll()}}async stop(){if(!this.isStarted||this.isDisposed)return;this.isDisposed=!0;const S=await this.filterId;if(this.isStarted=!1,this.stopSemaphore&&await this.stopSemaphore,await this.uninstall()!==!0)throw new Error(`Couldn't stop the eth filter: ${S}`)}async poll(){if(this.isStarted){if(this.callbacks.length){const M=await this.getChanges();M&&this.callbacks.forEach((Y=>{this.formatter?M.forEach((x=>{Y(this.formatter(x))})):M.forEach((x=>Y(x)))}))}this.stopSemaphore.resolve(1),this.isStarted&&(this.stopSemaphore=s(),setTimeout((S=()=>this.poll(),function(){S().catch((M=>console.error(M)))}),500))}else this.stopSemaphore.resolve(1);var S}}class is extends Ll{constructor(S,M,Y=(x=>x)){super(S),this.requestManager=S,this.options=M,this.formatter=Y,this.options=this.options||{},this.options.topics=this.options.topics||[],this.options.topics=this.options.topics.map((function(x){return N_(x)})),this.options={topics:this.options.topics,address:this.options.address?this.options.address:void 0,fromBlock:typeof this.options.fromBlock=="number"||typeof this.options.fromBlock=="string"?Ft(this.options.fromBlock)||void 0:"latest",toBlock:typeof this.options.toBlock=="number"||typeof this.options.toBlock=="string"?Ft(this.options.toBlock)||void 0:"latest"}}async getLogs(){this.isStarted||await this.start();const S=await this.filterId;return this.requestManager.eth_getFilterLogs(S)}async getNewFilter(){return this.requestManager.eth_newFilter(this.options)}async getChanges(){const S=await this.filterId;return this.requestManager.eth_getFilterChanges(S)}async uninstall(){const S=await this.filterId;return this.requestManager.eth_uninstallFilter(S)}}class ql{constructor(S,M,Y){this.requestManager=S,this.address=Y,this._anonymous=!1,this._params=M.inputs||[],this._name=N(M),this._anonymous=M.anonymous||!1}types(S){return this._params.filter((function(M){return M.indexed===S}))}displayName(){return Ee(this._name)}typeName(){return _e(this._name)||"void"}signature(){return $(this._name)}encode(S={},M={}){const Y={topics:[],address:this.address};M.fromBlock!==void 0&&(Y.fromBlock=Ft(M.fromBlock)||void 0),M.toBlock!==void 0&&(Y.toBlock=Ft(M.toBlock)||void 0),Y.topics=Y.topics||[],this._anonymous||Y.topics.push("0x"+this.signature());const x=this._params.filter((function(se){return se.indexed===!0})).map((function(se){const ve=S[se.name];return ve==null?null:le(ve)?ve.map((function(Pe){return"0x"+r.coder.encodeParams([se],[Pe])})):"0x"+r.coder.encodeParams([se],[ve])}));return Y.topics=Y.topics.concat(x),Y}decode(S){S.data=S.data||"",S.topics=S.topics||[];const M=(this._anonymous?S.topics:S.topics.slice(1)).map((function(Pe){return Pe.slice(2)})).join(""),Y=r.coder.decodeParams(this.types(!0),M),x=S.data.slice(2),se=r.coder.decodeParams(this.types(!1),x),ve=this._params.reduce((function(Pe,Ue){return Pe[Ue.name]=Ue.indexed?Y.shift():se.shift(),Pe}),{});return Object.assign(Object.assign({},Co(S)),{event:this.displayName(),address:S.address,args:ve})}async execute(S,M){const Y=this.encode(S,M),x=this.decode.bind(this);return new is(this.requestManager,Y,x)}attachToContract(S){const M=this.execute.bind(this),Y=this.displayName();S.events[Y]||(S.events[Y]=M),S.events[Y][this.typeName()]=this.execute.bind(this,S)}}class lM{constructor(S,M,Y){this._requestManager=S,this._json=M,this._address=Y}encode(S={}){const M={address:this._address};return S.fromBlock!==void 0&&(M.fromBlock=Ft(S.fromBlock)||void 0),S.toBlock!==void 0&&(M.toBlock=Ft(S.toBlock)||void 0),M}decode(S){S.data=S.data||"";const M=le(S.topics)&&_(S.topics[0])?S.topics[0].slice(2):"",Y=this._json.filter((function(x){return M===$(N(x))}))[0];return Y?new ql(this._requestManager,Y,this._address).decode(S):Co(S)}async execute(S){const M=this.encode(S),Y=this.decode.bind(this);return new is(this._requestManager,M,Y)}getAllEventsFunction(){return this.execute.bind(this)}}class P_{constructor(S,M,Y){var x;this.requestManager=S,this.abi=M,this.address=Y,this.events={},this.transactionHash=null,this.address=Y,this.abi=M,(x=this).abi.filter((function(se){return se.type==="function"})).map((function(se){return new O_(se)})).forEach((function(se){se.attachToContract(x)})),this.allEvents=(function(se){const ve=se.abi.filter((function(Ue){return Ue.type==="event"})),Pe=new lM(se.requestManager,ve,se.address);return ve.map((function(Ue){return new ql(se.requestManager,Ue,se.address)})).forEach((function(Ue){Ue.attachToContract(se)})),Pe.getAllEventsFunction()})(this)}}r.AbstractFilter=Ll,r.BigNumber=K,r.Contract=P_,r.ContractFactory=class{constructor(y,S){this.requestManager=y,this.abi=S}async deploy(...y){let S;const M=y[y.length-1];if(I(M)&&!le(M)&&(S=y.pop()),!S)throw new Error("Missing options object");if(!S.data||typeof S.data!="string")throw new Error("Invalid options.data");if(Ie(S.value)>0&&!(this.abi.filter((function(Ve){return Ve.type==="constructor"&&Ve.inputs.length===y.length}))[0]||{}).payable)throw new Error("Cannot send value to non-payable constructor");const Y=(x=this.abi,se=y,x.filter((function(Ve){return Ve.type==="constructor"&&Ve.inputs&&Ve.inputs.length===se.length})).map((function(Ve){return Ve.inputs||[]})).map((function(Ve){return r.coder.encodeParams(Ve,se)}))[0]||"");var x,se;S.data+=Y,S.gas||(S.gas=await this.requestManager.eth_estimateGas(S));const ve=await this.requestManager.eth_sendTransaction(S);if(!ve)throw new Error("Error while sending contract creation transaction. A TxHash was not retrieved");const Pe=await(async function(Ve,ir){const Ct=s();let Ce=0;const Gt=()=>{Ce++,Ce>50?Ct.reject(new Error("Contract transaction couldn't be found after 50 blocks")):Ve.eth_getTransactionReceipt(ir).then((xt=>{xt&&xt.blockHash?Ct.resolve(xt):setTimeout(Gt,1e3)}),(xt=>Ct.reject(xt)))};Gt();const bt=await Ct,Tt=await Ve.eth_getCode(bt.contractAddress,"latest");if(Tt&&Tt.length>3)return bt.contractAddress;throw Object.assign(new Error("The contract code couldn't be stored, please check your gas amount."),{response:Tt,receipt:bt})})(this.requestManager,ve),Ue=await this.at(Pe);return Ue.transactionHash=ve,Ue}async at(y){if(!_t(y))throw new TypeError(`Invalid address ${JSON.stringify(y)}`);return new P_(this.requestManager,this.abi,y)}},r.EthBlockFilter=class extends is{constructor(y){super(y,{})}async getNewFilter(){return this.requestManager.eth_newBlockFilter()}},r.EthFilter=is,r.EthPendingTransactionFilter=class extends is{constructor(y){super(y,{})}async getNewFilter(){return this.requestManager.eth_newPendingTransactionFilter()}},r.HTTPProvider=class{constructor(y,S={}){this.host=y,this.options=S,this.debug=!1,this.host=y||"http://localhost:8545"}send(){throw new Error("Sync requests are deprecated")}sendAsync(y,S){try{let M=null;M=y instanceof Array?y.map((se=>n(se))):n(y);const Y=this.options.fetch||globalThis.fetch;if(Y===void 0)throw new Error("There is no global fetch object nor it was provided. Please install and import isomorphic-fetch");const x={body:JSON.stringify(M),method:"POST",headers:Object.assign(Object.assign({},this.options.headers),{"Content-Type":"application/json"})};this.debug&&console.log("SEND >> "+x.body),Y(this.host,x).then((async se=>{if(se.ok){const ve=await se.json();this.debug&&console.log("RECV << "+JSON.stringify(ve)),ve.error?S(Object.assign(new Error(ve.error.json||ve.error),ve.error)):S(null,ve)}else{const ve=(typeof se.text=="function"?await se.text().catch((()=>"")):"").trim().slice(0,512),Pe="External error. response code: "+se.status+(ve?" — "+ve:"");this.debug&&console.log("ERR << "+Pe),S(new Error(Pe))}}),(se=>{this.debug&&console.log("ERR << "+JSON.stringify(se)),S(se)}))}catch(M){this.debug&&console.log("ERR << "+JSON.stringify(M)),S(M)}}},r.Method=He,r.Property=pr,r.RequestManager=je,r.SHHFilter=class extends Ll{constructor(y,S){super(y),this.requestManager=y,this.options=S,this.options=this.options||{topics:[]},this.options.topics=this.options.topics||[],this.options.topics=this.options.topics.map((function(M){return N_(M)})),this.options={topics:this.options.topics,to:this.options.to}}async getMessages(){const y=await this.filterId;return this.requestManager.shh_getMessages(y)}async getNewFilter(){return this.requestManager.shh_newFilter(this.options)}async getChanges(){const y=await this.filterId;return this.requestManager.shh_getFilterChanges(y)}async uninstall(){const y=await this.filterId;return this.requestManager.shh_uninstallFilter(y)}},r.SolidityEvent=ql,r.SolidityFunction=O_,r.WebSocketProvider=class{constructor(y,S={}){this.url=y,this.options=S,this.isDisposed=!1,this.responseCallbacks=new Map,this.notificationCallbacks=new Set,this.debug=!1,this.lastChunk="",this.connect()}dispose(){this.isDisposed=!0;const y=this.connection;this.timeout(new Error("Provider disposed.")),y.then((S=>S.close())).catch((S=>{this.debug&&console.error(S)}))}send(){throw new Error("Sync requests are deprecated")}sendAsync(y,S){const M=[];let Y;if(y instanceof Array)Y=Promise.all(y.map((x=>{const se=s();try{const ve=n(x);M.push(ve),this.responseCallbacks.set(ve.id,se)}catch(ve){se.reject(ve)}return se})));else{const x=s();try{const se=n(y);M.push(se),this.responseCallbacks.set(se.id,x)}catch(se){x.reject(se)}Y=x}Y.then((x=>S(null,x)),(x=>S(x))),this.connection.then((x=>{M.forEach((se=>{const ve=JSON.stringify(se);this.debug&&console.log("SEND >> "+ve),x.send(ve)}))}),(x=>{S(x)}))}parseResponse(y){const S=[];return y.replace(/\}[\n\r]?\{/g,"}|--|{").replace(/\}\][\n\r]?\[\{/g,"}]|--|[{").replace(/\}[\n\r]?\[\{/g,"}|--|[{").replace(/\}\][\n\r]?\{/g,"}]|--|{").split("|--|").forEach((M=>{let Y=M;this.lastChunk&&(Y=this.lastChunk+Y);let x=null;try{x=JSON.parse(Y)}catch{return this.lastChunk=Y,clearTimeout(this.lastChunkTimeout),void(this.lastChunkTimeout=setTimeout((()=>{this.timeout()}),15e3))}clearTimeout(this.lastChunkTimeout),this.lastChunk="",x&&S.push(x)})),S}processMessage(y){if("id"in y){const S=y.id,M=this.responseCallbacks.get(S);if(!M)return void console.error("Error: Received a response for an unknown request",y);this.responseCallbacks.delete(S),y.error!==void 0&&y.error!==null?M.reject(Object.assign(new Error(y.error.message||y.error),y.error)):"result"in y&&M.resolve(y)}else this.notificationCallbacks.forEach((S=>S(null,y)))}timeout(y){this.connection&&this.connection.isPending||(this.connection=s());const S=y||new Error("Connection timeout");this.responseCallbacks.forEach((M=>M.reject(S))),this.responseCallbacks.clear(),this.isDisposed||setTimeout((()=>this.connect()),1e3)}connect(){this.connection&&!this.connection.isPending&&this.connection.then((M=>M.close())).catch((M=>{this.debug&&console.error(M)})),this.connection&&this.connection.isPending||(this.connection=s()),this.lastChunk="";const y=this.options.WebSocketConstructor||(typeof WebSocket<"u"?WebSocket:void 0);if(!y)throw new Error("Please provide a WebSocketConstructor");const S=new y(this.url,this.options.protocol);S.onopen=()=>{this.connection.resolve(S)},S.onerror=M=>{const Y=new Error("Error in web socket");Y.data=M,this.timeout(Y)},S.onclose=M=>{this.timeout(new Error(`Connection closed (${M&&M.reason||"Unknown reason"})`))},S.onmessage=M=>{const Y=typeof M.data=="string"?M.data:"";this.debug&&console.log("RECV << "+M.data),this.parseResponse(Y).forEach((x=>{x instanceof Array?x.forEach((se=>this.processMessage(se))):this.processMessage(x)}))}}},r.bytesToHex=W,r.bytesToUtf8String=F,r.concatBytes=j,r.default=je,r.extractDisplayName=Ee,r.extractTypeName=_e,r.fromAscii=function(y,S=0){let M="";for(let Y=0;Y<y.length;Y++){const x=y.charCodeAt(Y).toString(16);M+=x.length<2?"0"+x:x}return"0x"+M.padEnd(S,"0")},r.fromDecimal=Te,r.fromTwosComplement=gt,r.fromWei=function(y,S){const M=We(y).dividedBy(Be(S));return C(y)?M:M.toString(10)},r.getAddress=Mt,r.getValueOfUnit=Be,r.hexToBytes=X,r.inputAddressFormatter=fr,r.inputBlockNumberFormatter=Ft,r.inputCallFormatter=Ml,r.inputDefaultBlockNumberFormatter=rt,r.inputFilterOptions=m_,r.inputPostFormatter=function(y){return y?(y.ttl=Te(y.ttl),y.workToProve=Te(y.workToProve),y.priority=Te(y.priority),le(y.topics)||(y.topics=y.topics?[y.topics]:[]),y.topics=y.topics.map((function(S){return S.indexOf("0x")===0?S:"0x"+W(U(S))})),y):null},r.inputTransactionFormatter=Cl,r.inputTransactionId=ca,r.isAddress=_t,r.isArray=le,r.isBigNumber=C,r.isBloom=function(y){return!!/^(0x)?[0-9a-f]{512}$/i.test(y)&&!!/^(0x)?[0-9a-f]{512}$/i.test(y)},r.isBoolean=G,r.isChecksumAddress=Qt,r.isFunction=function(y){return typeof y=="function"},r.isHex=function(y){return typeof y=="string"&&/^0x[0-9a-fA-F]+$/.test(y)},r.isJson=function(y){try{return!!JSON.parse(y)}catch{return!1}},r.isObject=I,r.isPredefinedBlockNumber=wt,r.isStrictAddress=Ut,r.isString=_,r.isTopic=function(y){return!!/^(0x)?[0-9a-f]{64}$/i.test(y)&&!!/^(0x)?[0-9a-f]{64}$/i.test(y)},r.isValidResponse=At,r.outputBigNumberFormatter=Et,r.outputBlockFormatter=rs,r.outputLogFormatter=Co,r.outputPostFormatter=function(y){return y?(y.expiry=Ie(y.expiry),y.sent=Ie(y.sent),y.ttl=Ie(y.ttl),y.workProved=Ie(y.workProved),y.topics||(y.topics=[]),y.topics=y.topics.map((function(S){return H(S)})),y):null},r.outputSyncingFormatter=h_,r.outputTransactionFormatter=ts,r.outputTransactionReceiptFormatter=p_,r.padLeft=L,r.padRight=function(y,S,M){return y+new Array(S-y.length+1).join(M||"0")},r.sha3=$,r.signedIsNegative=st,r.stringToUtf8Bytes=U,r.toAddress=_r,r.toArray=ft,r.toAscii=H,r.toBatchPayload=function(y){return y.map((function(S){return Qe(S.method,S.params)}))},r.toBigNumber=We,r.toBoolean=me,r.toChecksumAddress=Zt,r.toData=ce,r.toDecimal=Ie,r.toHex=Ae,r.toJsonRpcRequest=Qe,r.toNullDecimal=Se,r.toString=ne,r.toStringData=de,r.toTwosComplement=Je,r.toWei=function(y,S){const M=We(y).times(Be(S));return C(y)?M:M.toString(10)},r.transformToFullName=N,Object.defineProperty(r,"__esModule",{value:!0})}))})(Js,Js.exports)),Js.exports}var Nc={},US;function bF(){if(US)return Nc;US=1,Object.defineProperty(Nc,"__esModule",{value:!0}),Nc.SignatureValidator=t;const e=bl();async function t(r,n){const i=[{constant:!0,inputs:[{name:"hash",type:"bytes32"},{name:"_signature",type:"bytes"}],name:"isValidSignature",outputs:[{name:"magicValue",type:"bytes4"}],payable:!1,stateMutability:"view",type:"function"}];return await new e.ContractFactory(r,i).at(n)}return Nc}var Zr={},pp={},mp={},hi={},gn={},Vt={},FS;function Zg(){if(FS)return Vt;FS=1,Object.defineProperty(Vt,"__esModule",{value:!0}),Vt.output=Vt.exists=Vt.hash=Vt.bytes=Vt.bool=Vt.number=Vt.isBytes=void 0;function e(u){if(!Number.isSafeInteger(u)||u<0)throw new Error(`positive integer expected, not ${u}`)}Vt.number=e;function t(u){if(typeof u!="boolean")throw new Error(`boolean expected, not ${u}`)}Vt.bool=t;function r(u){return u instanceof Uint8Array||u!=null&&typeof u=="object"&&u.constructor.name==="Uint8Array"}Vt.isBytes=r;function n(u,...l){if(!r(u))throw new Error("Uint8Array expected");if(l.length>0&&!l.includes(u.length))throw new Error(`Uint8Array expected of length ${l}, not of length=${u.length}`)}Vt.bytes=n;function i(u){if(typeof u!="function"||typeof u.create!="function")throw new Error("Hash should be wrapped by utils.wrapConstructor");e(u.outputLen),e(u.blockLen)}Vt.hash=i;function a(u,l=!0){if(u.destroyed)throw new Error("Hash instance has been destroyed");if(l&&u.finished)throw new Error("Hash#digest() has already been called")}Vt.exists=a;function s(u,l){n(u);const c=l.outputLen;if(u.length<c)throw new Error(`digestInto() expects output buffer of length at least ${c}`)}Vt.output=s;const o={number:e,bool:t,bytes:n,hash:i,exists:a,output:s};return Vt.default=o,Vt}var hp={},hs={},VS;function TF(){return VS||(VS=1,Object.defineProperty(hs,"__esModule",{value:!0}),hs.crypto=void 0,hs.crypto=typeof globalThis=="object"&&"crypto"in globalThis?globalThis.crypto:void 0),hs}var HS;function No(){return HS||(HS=1,(function(e){/*! noble-hashes - MIT License (c) 2022 Paul Miller (paulmillr.com) */Object.defineProperty(e,"__esModule",{value:!0}),e.randomBytes=e.wrapXOFConstructorWithOpts=e.wrapConstructorWithOpts=e.wrapConstructor=e.checkOpts=e.Hash=e.concatBytes=e.toBytes=e.utf8ToBytes=e.asyncLoop=e.nextTick=e.hexToBytes=e.bytesToHex=e.byteSwap32=e.byteSwapIfBE=e.byteSwap=e.isLE=e.rotl=e.rotr=e.createView=e.u32=e.u8=e.isBytes=void 0;const t=TF(),r=Zg();function n(z){return z instanceof Uint8Array||z!=null&&typeof z=="object"&&z.constructor.name==="Uint8Array"}e.isBytes=n;const i=z=>new Uint8Array(z.buffer,z.byteOffset,z.byteLength);e.u8=i;const a=z=>new Uint32Array(z.buffer,z.byteOffset,Math.floor(z.byteLength/4));e.u32=a;const s=z=>new DataView(z.buffer,z.byteOffset,z.byteLength);e.createView=s;const o=(z,U)=>z<<32-U|z>>>U;e.rotr=o;const u=(z,U)=>z<<U|z>>>32-U>>>0;e.rotl=u,e.isLE=new Uint8Array(new Uint32Array([287454020]).buffer)[0]===68;const l=z=>z<<24&4278190080|z<<8&16711680|z>>>8&65280|z>>>24&255;e.byteSwap=l,e.byteSwapIfBE=e.isLE?z=>z:z=>(0,e.byteSwap)(z);function c(z){for(let U=0;U<z.length;U++)z[U]=(0,e.byteSwap)(z[U])}e.byteSwap32=c;const d=Array.from({length:256},(z,U)=>U.toString(16).padStart(2,"0"));function m(z){(0,r.bytes)(z);let U="";for(let F=0;F<z.length;F++)U+=d[z[F]];return U}e.bytesToHex=m;const p={_0:48,_9:57,_A:65,_F:70,_a:97,_f:102};function E(z){if(z>=p._0&&z<=p._9)return z-p._0;if(z>=p._A&&z<=p._F)return z-(p._A-10);if(z>=p._a&&z<=p._f)return z-(p._a-10)}function A(z){if(typeof z!="string")throw new Error("hex string expected, got "+typeof z);const U=z.length,F=U/2;if(U%2)throw new Error("padded hex string expected, got unpadded hex of length "+U);const ue=new Uint8Array(F);for(let ae=0,re=0;ae<F;ae++,re+=2){const X=E(z.charCodeAt(re)),W=E(z.charCodeAt(re+1));if(X===void 0||W===void 0){const $=z[re]+z[re+1];throw new Error('hex string expected, got non-hex character "'+$+'" at index '+re)}ue[ae]=X*16+W}return ue}e.hexToBytes=A;const R=async()=>{};e.nextTick=R;async function O(z,U,F){let ue=Date.now();for(let ae=0;ae<z;ae++){F(ae);const re=Date.now()-ue;re>=0&&re<U||(await(0,e.nextTick)(),ue+=re)}}e.asyncLoop=O;function f(z){if(typeof z!="string")throw new Error(`utf8ToBytes expected string, got ${typeof z}`);return new Uint8Array(new TextEncoder().encode(z))}e.utf8ToBytes=f;function v(z){return typeof z=="string"&&(z=f(z)),(0,r.bytes)(z),z}e.toBytes=v;function b(...z){let U=0;for(let ue=0;ue<z.length;ue++){const ae=z[ue];(0,r.bytes)(ae),U+=ae.length}const F=new Uint8Array(U);for(let ue=0,ae=0;ue<z.length;ue++){const re=z[ue];F.set(re,ae),ae+=re.length}return F}e.concatBytes=b;class h{clone(){return this._cloneInto()}}e.Hash=h;const T={}.toString;function w(z,U){if(U!==void 0&&T.call(U)!=="[object Object]")throw new Error("Options should be object or undefined");return Object.assign(z,U)}e.checkOpts=w;function P(z){const U=ue=>z().update(v(ue)).digest(),F=z();return U.outputLen=F.outputLen,U.blockLen=F.blockLen,U.create=()=>z(),U}e.wrapConstructor=P;function B(z){const U=(ue,ae)=>z(ae).update(v(ue)).digest(),F=z({});return U.outputLen=F.outputLen,U.blockLen=F.blockLen,U.create=ue=>z(ue),U}e.wrapConstructorWithOpts=B;function J(z){const U=(ue,ae)=>z(ae).update(v(ue)).digest(),F=z({});return U.outputLen=F.outputLen,U.blockLen=F.blockLen,U.create=ue=>z(ue),U}e.wrapXOFConstructorWithOpts=J;function K(z=32){if(t.crypto&&typeof t.crypto.getRandomValues=="function")return t.crypto.getRandomValues(new Uint8Array(z));throw new Error("crypto.getRandomValues must be defined")}e.randomBytes=K})(hp)),hp}var GS;function SF(){if(GS)return gn;GS=1,Object.defineProperty(gn,"__esModule",{value:!0}),gn.HashMD=gn.Maj=gn.Chi=void 0;const e=Zg(),t=No();function r(s,o,u,l){if(typeof s.setBigUint64=="function")return s.setBigUint64(o,u,l);const c=BigInt(32),d=BigInt(4294967295),m=Number(u>>c&d),p=Number(u&d),E=l?4:0,A=l?0:4;s.setUint32(o+E,m,l),s.setUint32(o+A,p,l)}const n=(s,o,u)=>s&o^~s&u;gn.Chi=n;const i=(s,o,u)=>s&o^s&u^o&u;gn.Maj=i;class a extends t.Hash{constructor(o,u,l,c){super(),this.blockLen=o,this.outputLen=u,this.padOffset=l,this.isLE=c,this.finished=!1,this.length=0,this.pos=0,this.destroyed=!1,this.buffer=new Uint8Array(o),this.view=(0,t.createView)(this.buffer)}update(o){(0,e.exists)(this);const{view:u,buffer:l,blockLen:c}=this;o=(0,t.toBytes)(o);const d=o.length;for(let m=0;m<d;){const p=Math.min(c-this.pos,d-m);if(p===c){const E=(0,t.createView)(o);for(;c<=d-m;m+=c)this.process(E,m);continue}l.set(o.subarray(m,m+p),this.pos),this.pos+=p,m+=p,this.pos===c&&(this.process(u,0),this.pos=0)}return this.length+=o.length,this.roundClean(),this}digestInto(o){(0,e.exists)(this),(0,e.output)(o,this),this.finished=!0;const{buffer:u,view:l,blockLen:c,isLE:d}=this;let{pos:m}=this;u[m++]=128,this.buffer.subarray(m).fill(0),this.padOffset>c-m&&(this.process(l,0),m=0);for(let O=m;O<c;O++)u[O]=0;r(l,c-8,BigInt(this.length*8),d),this.process(l,0);const p=(0,t.createView)(o),E=this.outputLen;if(E%4)throw new Error("_sha2: outputLen should be aligned to 32bit");const A=E/4,R=this.get();if(A>R.length)throw new Error("_sha2: outputLen bigger than state");for(let O=0;O<A;O++)p.setUint32(4*O,R[O],d)}digest(){const{buffer:o,outputLen:u}=this;this.digestInto(o);const l=o.slice(0,u);return this.destroy(),l}_cloneInto(o){o||(o=new this.constructor),o.set(...this.get());const{blockLen:u,buffer:l,length:c,finished:d,destroyed:m,pos:p}=this;return o.length=c,o.pos=p,o.finished=d,o.destroyed=m,c%u&&o.buffer.set(l),o}}return gn.HashMD=a,gn}var zS;function IF(){if(zS)return hi;zS=1,Object.defineProperty(hi,"__esModule",{value:!0}),hi.sha224=hi.sha256=void 0;const e=SF(),t=No(),r=new Uint32Array([1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298]),n=new Uint32Array([1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225]),i=new Uint32Array(64);class a extends e.HashMD{constructor(){super(64,32,8,!1),this.A=n[0]|0,this.B=n[1]|0,this.C=n[2]|0,this.D=n[3]|0,this.E=n[4]|0,this.F=n[5]|0,this.G=n[6]|0,this.H=n[7]|0}get(){const{A:u,B:l,C:c,D:d,E:m,F:p,G:E,H:A}=this;return[u,l,c,d,m,p,E,A]}set(u,l,c,d,m,p,E,A){this.A=u|0,this.B=l|0,this.C=c|0,this.D=d|0,this.E=m|0,this.F=p|0,this.G=E|0,this.H=A|0}process(u,l){for(let f=0;f<16;f++,l+=4)i[f]=u.getUint32(l,!1);for(let f=16;f<64;f++){const v=i[f-15],b=i[f-2],h=(0,t.rotr)(v,7)^(0,t.rotr)(v,18)^v>>>3,T=(0,t.rotr)(b,17)^(0,t.rotr)(b,19)^b>>>10;i[f]=T+i[f-7]+h+i[f-16]|0}let{A:c,B:d,C:m,D:p,E,F:A,G:R,H:O}=this;for(let f=0;f<64;f++){const v=(0,t.rotr)(E,6)^(0,t.rotr)(E,11)^(0,t.rotr)(E,25),b=O+v+(0,e.Chi)(E,A,R)+r[f]+i[f]|0,T=((0,t.rotr)(c,2)^(0,t.rotr)(c,13)^(0,t.rotr)(c,22))+(0,e.Maj)(c,d,m)|0;O=R,R=A,A=E,E=p+b|0,p=m,m=d,d=c,c=b+T|0}c=c+this.A|0,d=d+this.B|0,m=m+this.C|0,p=p+this.D|0,E=E+this.E|0,A=A+this.F|0,R=R+this.G|0,O=O+this.H|0,this.set(c,d,m,p,E,A,R,O)}roundClean(){i.fill(0)}destroy(){this.set(0,0,0,0,0,0,0,0),this.buffer.fill(0)}}class s extends a{constructor(){super(),this.A=-1056596264,this.B=914150663,this.C=812702999,this.D=-150054599,this.E=-4191439,this.F=1750603025,this.G=1694076839,this.H=-1090891868,this.outputLen=28}}return hi.sha256=(0,t.wrapConstructor)(()=>new a),hi.sha224=(0,t.wrapConstructor)(()=>new s),hi}var ys={},yp={},WS;function RF(){return WS||(WS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.hmac=e.HMAC=void 0;const t=Zg(),r=No();class n extends r.Hash{constructor(s,o){super(),this.finished=!1,this.destroyed=!1,(0,t.hash)(s);const u=(0,r.toBytes)(o);if(this.iHash=s.create(),typeof this.iHash.update!="function")throw new Error("Expected instance of class which extends utils.Hash");this.blockLen=this.iHash.blockLen,this.outputLen=this.iHash.outputLen;const l=this.blockLen,c=new Uint8Array(l);c.set(u.length>l?s.create().update(u).digest():u);for(let d=0;d<c.length;d++)c[d]^=54;this.iHash.update(c),this.oHash=s.create();for(let d=0;d<c.length;d++)c[d]^=106;this.oHash.update(c),c.fill(0)}update(s){return(0,t.exists)(this),this.iHash.update(s),this}digestInto(s){(0,t.exists)(this),(0,t.bytes)(s,this.outputLen),this.finished=!0,this.iHash.digestInto(s),this.oHash.update(s),this.oHash.digestInto(s),this.destroy()}digest(){const s=new Uint8Array(this.oHash.outputLen);return this.digestInto(s),s}_cloneInto(s){s||(s=Object.create(Object.getPrototypeOf(this),{}));const{oHash:o,iHash:u,finished:l,destroyed:c,blockLen:d,outputLen:m}=this;return s=s,s.finished=l,s.destroyed=c,s.blockLen=d,s.outputLen=m,s.oHash=o._cloneInto(s.oHash),s.iHash=u._cloneInto(s.iHash),s}destroy(){this.destroyed=!0,this.oHash.destroy(),this.iHash.destroy()}}e.HMAC=n;const i=(a,s,o)=>new n(a,s).update(o).digest();e.hmac=i,e.hmac.create=(a,s)=>new n(a,s)})(yp)),yp}var gp={},gs={},Pt={},Ot={},YS;function Ga(){if(YS)return Ot;YS=1,Object.defineProperty(Ot,"__esModule",{value:!0}),Ot.bitMask=void 0,Ot.isBytes=n,Ot.abytes=i,Ot.bytesToHex=s,Ot.numberToHexUnpadded=o,Ot.hexToNumber=u,Ot.hexToBytes=d,Ot.bytesToNumberBE=m,Ot.bytesToNumberLE=p,Ot.numberToBytesBE=E,Ot.numberToBytesLE=A,Ot.numberToVarBytesBE=R,Ot.ensureBytes=O,Ot.concatBytes=f,Ot.equalBytes=v,Ot.utf8ToBytes=b,Ot.bitLen=h,Ot.bitGet=T,Ot.bitSet=w,Ot.createHmacDrbg=K,Ot.validateObject=U;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const e=BigInt(0),t=BigInt(1),r=BigInt(2);function n(F){return F instanceof Uint8Array||F!=null&&typeof F=="object"&&F.constructor.name==="Uint8Array"}function i(F){if(!n(F))throw new Error("Uint8Array expected")}const a=Array.from({length:256},(F,ue)=>ue.toString(16).padStart(2,"0"));function s(F){i(F);let ue="";for(let ae=0;ae<F.length;ae++)ue+=a[F[ae]];return ue}function o(F){const ue=F.toString(16);return ue.length&1?`0${ue}`:ue}function u(F){if(typeof F!="string")throw new Error("hex string expected, got "+typeof F);return BigInt(F===""?"0":`0x${F}`)}const l={_0:48,_9:57,_A:65,_F:70,_a:97,_f:102};function c(F){if(F>=l._0&&F<=l._9)return F-l._0;if(F>=l._A&&F<=l._F)return F-(l._A-10);if(F>=l._a&&F<=l._f)return F-(l._a-10)}function d(F){if(typeof F!="string")throw new Error("hex string expected, got "+typeof F);const ue=F.length,ae=ue/2;if(ue%2)throw new Error("padded hex string expected, got unpadded hex of length "+ue);const re=new Uint8Array(ae);for(let X=0,W=0;X<ae;X++,W+=2){const $=c(F.charCodeAt(W)),D=c(F.charCodeAt(W+1));if($===void 0||D===void 0){const L=F[W]+F[W+1];throw new Error('hex string expected, got non-hex character "'+L+'" at index '+W)}re[X]=$*16+D}return re}function m(F){return u(s(F))}function p(F){return i(F),u(s(Uint8Array.from(F).reverse()))}function E(F,ue){return d(F.toString(16).padStart(ue*2,"0"))}function A(F,ue){return E(F,ue).reverse()}function R(F){return d(o(F))}function O(F,ue,ae){let re;if(typeof ue=="string")try{re=d(ue)}catch(W){throw new Error(`${F} must be valid hex string, got "${ue}". Cause: ${W}`)}else if(n(ue))re=Uint8Array.from(ue);else throw new Error(`${F} must be hex string or Uint8Array`);const X=re.length;if(typeof ae=="number"&&X!==ae)throw new Error(`${F} expected ${ae} bytes, got ${X}`);return re}function f(...F){let ue=0;for(let re=0;re<F.length;re++){const X=F[re];i(X),ue+=X.length}const ae=new Uint8Array(ue);for(let re=0,X=0;re<F.length;re++){const W=F[re];ae.set(W,X),X+=W.length}return ae}function v(F,ue){if(F.length!==ue.length)return!1;let ae=0;for(let re=0;re<F.length;re++)ae|=F[re]^ue[re];return ae===0}function b(F){if(typeof F!="string")throw new Error(`utf8ToBytes expected string, got ${typeof F}`);return new Uint8Array(new TextEncoder().encode(F))}function h(F){let ue;for(ue=0;F>e;F>>=t,ue+=1);return ue}function T(F,ue){return F>>BigInt(ue)&t}function w(F,ue,ae){return F|(ae?t:e)<<BigInt(ue)}const P=F=>(r<<BigInt(F-1))-t;Ot.bitMask=P;const B=F=>new Uint8Array(F),J=F=>Uint8Array.from(F);function K(F,ue,ae){if(typeof F!="number"||F<2)throw new Error("hashLen must be a number");if(typeof ue!="number"||ue<2)throw new Error("qByteLen must be a number");if(typeof ae!="function")throw new Error("hmacFn must be a function");let re=B(F),X=B(F),W=0;const $=()=>{re.fill(1),X.fill(0),W=0},D=(...j)=>ae(X,re,...j),L=(j=B())=>{X=D(J([0]),j),re=D(),j.length!==0&&(X=D(J([1]),j),re=D())},H=()=>{if(W++>=1e3)throw new Error("drbg: tried 1000 values");let j=0;const Z=[];for(;j<ue;){re=D();const Ee=re.slice();Z.push(Ee),j+=re.length}return f(...Z)};return(j,Z)=>{$(),L(j);let Ee;for(;!(Ee=Z(H()));)L();return $(),Ee}}const z={bigint:F=>typeof F=="bigint",function:F=>typeof F=="function",boolean:F=>typeof F=="boolean",string:F=>typeof F=="string",stringOrUint8Array:F=>typeof F=="string"||n(F),isSafeInteger:F=>Number.isSafeInteger(F),array:F=>Array.isArray(F),field:(F,ue)=>ue.Fp.isValid(F),hash:F=>typeof F=="function"&&Number.isSafeInteger(F.outputLen)};function U(F,ue,ae={}){const re=(X,W,$)=>{const D=z[W];if(typeof D!="function")throw new Error(`Invalid validator "${W}", expected function`);const L=F[X];if(!($&&L===void 0)&&!D(L,F))throw new Error(`Invalid param ${String(X)}=${L} (${typeof L}), expected ${W}`)};for(const[X,W]of Object.entries(ue))re(X,W,!1);for(const[X,W]of Object.entries(ae))re(X,W,!0);return F}return Ot}var KS;function Tl(){if(KS)return Pt;KS=1,Object.defineProperty(Pt,"__esModule",{value:!0}),Pt.isNegativeLE=void 0,Pt.mod=u,Pt.pow=l,Pt.pow2=c,Pt.invert=d,Pt.tonelliShanks=m,Pt.FpSqrt=p,Pt.validateField=R,Pt.FpPow=O,Pt.FpInvertBatch=f,Pt.FpDiv=v,Pt.FpIsSquare=b,Pt.nLength=h,Pt.Field=T,Pt.FpSqrtOdd=w,Pt.FpSqrtEven=P,Pt.hashToPrivateScalar=B,Pt.getFieldBytesLength=J,Pt.getMinHashLength=K,Pt.mapHashToField=z;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const e=Ga(),t=BigInt(0),r=BigInt(1),n=BigInt(2),i=BigInt(3),a=BigInt(4),s=BigInt(5),o=BigInt(8);BigInt(9),BigInt(16);function u(U,F){const ue=U%F;return ue>=t?ue:F+ue}function l(U,F,ue){if(ue<=t||F<t)throw new Error("Expected power/modulo > 0");if(ue===r)return t;let ae=r;for(;F>t;)F&r&&(ae=ae*U%ue),U=U*U%ue,F>>=r;return ae}function c(U,F,ue){let ae=U;for(;F-- >t;)ae*=ae,ae%=ue;return ae}function d(U,F){if(U===t||F<=t)throw new Error(`invert: expected positive integers, got n=${U} mod=${F}`);let ue=u(U,F),ae=F,re=t,X=r;for(;ue!==t;){const $=ae/ue,D=ae%ue,L=re-X*$;ae=ue,ue=D,re=X,X=L}if(ae!==r)throw new Error("invert: does not exist");return u(re,F)}function m(U){const F=(U-r)/n;let ue,ae,re;for(ue=U-r,ae=0;ue%n===t;ue/=n,ae++);for(re=n;re<U&&l(re,F,U)!==U-r;re++);if(ae===1){const W=(U+r)/a;return function(D,L){const H=D.pow(L,W);if(!D.eql(D.sqr(H),L))throw new Error("Cannot find square root");return H}}const X=(ue+r)/n;return function($,D){if($.pow(D,F)===$.neg($.ONE))throw new Error("Cannot find square root");let L=ae,H=$.pow($.mul($.ONE,re),ue),N=$.pow(D,X),j=$.pow(D,ue);for(;!$.eql(j,$.ONE);){if($.eql(j,$.ZERO))return $.ZERO;let Z=1;for(let _e=$.sqr(j);Z<L&&!$.eql(_e,$.ONE);Z++)_e=$.sqr(_e);const Ee=$.pow(H,r<<BigInt(L-Z-1));H=$.sqr(Ee),N=$.mul(N,Ee),j=$.mul(j,H),L=Z}return N}}function p(U){if(U%a===i){const F=(U+r)/a;return function(ae,re){const X=ae.pow(re,F);if(!ae.eql(ae.sqr(X),re))throw new Error("Cannot find square root");return X}}if(U%o===s){const F=(U-s)/o;return function(ae,re){const X=ae.mul(re,n),W=ae.pow(X,F),$=ae.mul(re,W),D=ae.mul(ae.mul($,n),W),L=ae.mul($,ae.sub(D,ae.ONE));if(!ae.eql(ae.sqr(L),re))throw new Error("Cannot find square root");return L}}return m(U)}const E=(U,F)=>(u(U,F)&r)===r;Pt.isNegativeLE=E;const A=["create","isValid","is0","neg","inv","sqrt","sqr","eql","add","sub","mul","pow","div","addN","subN","mulN","sqrN"];function R(U){const F={ORDER:"bigint",MASK:"bigint",BYTES:"isSafeInteger",BITS:"isSafeInteger"},ue=A.reduce((ae,re)=>(ae[re]="function",ae),F);return(0,e.validateObject)(U,ue)}function O(U,F,ue){if(ue<t)throw new Error("Expected power > 0");if(ue===t)return U.ONE;if(ue===r)return F;let ae=U.ONE,re=F;for(;ue>t;)ue&r&&(ae=U.mul(ae,re)),re=U.sqr(re),ue>>=r;return ae}function f(U,F){const ue=new Array(F.length),ae=F.reduce((X,W,$)=>U.is0(W)?X:(ue[$]=X,U.mul(X,W)),U.ONE),re=U.inv(ae);return F.reduceRight((X,W,$)=>U.is0(W)?X:(ue[$]=U.mul(X,ue[$]),U.mul(X,W)),re),ue}function v(U,F,ue){return U.mul(F,typeof ue=="bigint"?d(ue,U.ORDER):U.inv(ue))}function b(U){const F=(U.ORDER-r)/n;return ue=>{const ae=U.pow(ue,F);return U.eql(ae,U.ZERO)||U.eql(ae,U.ONE)}}function h(U,F){const ue=F!==void 0?F:U.toString(2).length,ae=Math.ceil(ue/8);return{nBitLength:ue,nByteLength:ae}}function T(U,F,ue=!1,ae={}){if(U<=t)throw new Error(`Expected Field ORDER > 0, got ${U}`);const{nBitLength:re,nByteLength:X}=h(U,F);if(X>2048)throw new Error("Field lengths over 2048 bytes are not supported");const W=p(U),$=Object.freeze({ORDER:U,BITS:re,BYTES:X,MASK:(0,e.bitMask)(re),ZERO:t,ONE:r,create:D=>u(D,U),isValid:D=>{if(typeof D!="bigint")throw new Error(`Invalid field element: expected bigint, got ${typeof D}`);return t<=D&&D<U},is0:D=>D===t,isOdd:D=>(D&r)===r,neg:D=>u(-D,U),eql:(D,L)=>D===L,sqr:D=>u(D*D,U),add:(D,L)=>u(D+L,U),sub:(D,L)=>u(D-L,U),mul:(D,L)=>u(D*L,U),pow:(D,L)=>O($,D,L),div:(D,L)=>u(D*d(L,U),U),sqrN:D=>D*D,addN:(D,L)=>D+L,subN:(D,L)=>D-L,mulN:(D,L)=>D*L,inv:D=>d(D,U),sqrt:ae.sqrt||(D=>W($,D)),invertBatch:D=>f($,D),cmov:(D,L,H)=>H?L:D,toBytes:D=>ue?(0,e.numberToBytesLE)(D,X):(0,e.numberToBytesBE)(D,X),fromBytes:D=>{if(D.length!==X)throw new Error(`Fp.fromBytes: expected ${X}, got ${D.length}`);return ue?(0,e.bytesToNumberLE)(D):(0,e.bytesToNumberBE)(D)}});return Object.freeze($)}function w(U,F){if(!U.isOdd)throw new Error("Field doesn't have isOdd");const ue=U.sqrt(F);return U.isOdd(ue)?ue:U.neg(ue)}function P(U,F){if(!U.isOdd)throw new Error("Field doesn't have isOdd");const ue=U.sqrt(F);return U.isOdd(ue)?U.neg(ue):ue}function B(U,F,ue=!1){U=(0,e.ensureBytes)("privateHash",U);const ae=U.length,re=h(F).nByteLength+8;if(re<24||ae<re||ae>1024)throw new Error(`hashToPrivateScalar: expected ${re}-1024 bytes of input, got ${ae}`);const X=ue?(0,e.bytesToNumberLE)(U):(0,e.bytesToNumberBE)(U);return u(X,F-r)+r}function J(U){if(typeof U!="bigint")throw new Error("field order must be bigint");const F=U.toString(2).length;return Math.ceil(F/8)}function K(U){const F=J(U);return F+Math.ceil(F/2)}function z(U,F,ue=!1){const ae=U.length,re=J(F),X=K(F);if(ae<16||ae<X||ae>1024)throw new Error(`expected ${X}-1024 bytes of input, got ${ae}`);const W=ue?(0,e.bytesToNumberBE)(U):(0,e.bytesToNumberLE)(U),$=u(W,F-r)+r;return ue?(0,e.numberToBytesLE)($,re):(0,e.numberToBytesBE)($,re)}return Pt}var JS;function AF(){if(JS)return gs;JS=1,Object.defineProperty(gs,"__esModule",{value:!0}),gs.wNAF=i,gs.validateBasic=a;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const e=Tl(),t=Ga(),r=BigInt(0),n=BigInt(1);function i(s,o){const u=(c,d)=>{const m=d.negate();return c?m:d},l=c=>{const d=Math.ceil(o/c)+1,m=2**(c-1);return{windows:d,windowSize:m}};return{constTimeNegate:u,unsafeLadder(c,d){let m=s.ZERO,p=c;for(;d>r;)d&n&&(m=m.add(p)),p=p.double(),d>>=n;return m},precomputeWindow(c,d){const{windows:m,windowSize:p}=l(d),E=[];let A=c,R=A;for(let O=0;O<m;O++){R=A,E.push(R);for(let f=1;f<p;f++)R=R.add(A),E.push(R);A=R.double()}return E},wNAF(c,d,m){const{windows:p,windowSize:E}=l(c);let A=s.ZERO,R=s.BASE;const O=BigInt(2**c-1),f=2**c,v=BigInt(c);for(let b=0;b<p;b++){const h=b*E;let T=Number(m&O);m>>=v,T>E&&(T-=f,m+=n);const w=h,P=h+Math.abs(T)-1,B=b%2!==0,J=T<0;T===0?R=R.add(u(B,d[w])):A=A.add(u(J,d[P]))}return{p:A,f:R}},wNAFCached(c,d,m,p){const E=c._WINDOW_SIZE||1;let A=d.get(c);return A||(A=this.precomputeWindow(c,E),E!==1&&d.set(c,p(A))),this.wNAF(E,A,m)}}}function a(s){return(0,e.validateField)(s.Fp),(0,t.validateObject)(s,{n:"bigint",h:"bigint",Gx:"field",Gy:"field"},{nBitLength:"isSafeInteger",nByteLength:"isSafeInteger"}),Object.freeze({...(0,e.nLength)(s.n,s.nBitLength),...s,p:s.Fp.ORDER})}return gs}var XS;function zN(){return XS||(XS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DER=void 0,e.weierstrassPoints=p,e.weierstrass=A,e.SWUFpSqrtRatio=R,e.mapToCurveSimpleSWU=O;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const t=AF(),r=Tl(),n=Ga(),i=Ga();function a(f){const v=(0,t.validateBasic)(f);n.validateObject(v,{a:"field",b:"field"},{allowedPrivateKeyLengths:"array",wrapPrivateKey:"boolean",isTorsionFree:"function",clearCofactor:"function",allowInfinityPoint:"boolean",fromBytes:"function",toBytes:"function"});const{endo:b,Fp:h,a:T}=v;if(b){if(!h.eql(T,h.ZERO))throw new Error("Endomorphism can only be defined for Koblitz curves that have a=0");if(typeof b!="object"||typeof b.beta!="bigint"||typeof b.splitScalar!="function")throw new Error("Expected endomorphism with beta: bigint and splitScalar: function")}return Object.freeze({...v})}const{bytesToNumberBE:s,hexToBytes:o}=n;e.DER={Err:class extends Error{constructor(v=""){super(v)}},_parseInt(f){const{Err:v}=e.DER;if(f.length<2||f[0]!==2)throw new v("Invalid signature integer tag");const b=f[1],h=f.subarray(2,b+2);if(!b||h.length!==b)throw new v("Invalid signature integer: wrong length");if(h[0]&128)throw new v("Invalid signature integer: negative");if(h[0]===0&&!(h[1]&128))throw new v("Invalid signature integer: unnecessary leading zero");return{d:s(h),l:f.subarray(b+2)}},toSig(f){const{Err:v}=e.DER,b=typeof f=="string"?o(f):f;n.abytes(b);let h=b.length;if(h<2||b[0]!=48)throw new v("Invalid signature tag");if(b[1]!==h-2)throw new v("Invalid signature: incorrect length");const{d:T,l:w}=e.DER._parseInt(b.subarray(2)),{d:P,l:B}=e.DER._parseInt(w);if(B.length)throw new v("Invalid signature: left bytes after parsing");return{r:T,s:P}},hexFromSig(f){const v=K=>Number.parseInt(K[0],16)&8?"00"+K:K,b=K=>{const z=K.toString(16);return z.length&1?`0${z}`:z},h=v(b(f.s)),T=v(b(f.r)),w=h.length/2,P=T.length/2,B=b(w),J=b(P);return`30${b(P+w+4)}02${J}${T}02${B}${h}`}};const u=BigInt(0),l=BigInt(1),c=BigInt(2),d=BigInt(3),m=BigInt(4);function p(f){const v=a(f),{Fp:b}=v,h=v.toBytes||((ae,re,X)=>{const W=re.toAffine();return n.concatBytes(Uint8Array.from([4]),b.toBytes(W.x),b.toBytes(W.y))}),T=v.fromBytes||(ae=>{const re=ae.subarray(1),X=b.fromBytes(re.subarray(0,b.BYTES)),W=b.fromBytes(re.subarray(b.BYTES,2*b.BYTES));return{x:X,y:W}});function w(ae){const{a:re,b:X}=v,W=b.sqr(ae),$=b.mul(W,ae);return b.add(b.add($,b.mul(ae,re)),X)}if(!b.eql(b.sqr(v.Gy),w(v.Gx)))throw new Error("bad generator point: equation left != right");function P(ae){return typeof ae=="bigint"&&u<ae&&ae<v.n}function B(ae){if(!P(ae))throw new Error("Expected valid bigint: 0 < bigint < curve.n")}function J(ae){const{allowedPrivateKeyLengths:re,nByteLength:X,wrapPrivateKey:W,n:$}=v;if(re&&typeof ae!="bigint"){if(n.isBytes(ae)&&(ae=n.bytesToHex(ae)),typeof ae!="string"||!re.includes(ae.length))throw new Error("Invalid key");ae=ae.padStart(X*2,"0")}let D;try{D=typeof ae=="bigint"?ae:n.bytesToNumberBE((0,i.ensureBytes)("private key",ae,X))}catch{throw new Error(`private key must be ${X} bytes, hex or bigint, not ${typeof ae}`)}return W&&(D=r.mod(D,$)),B(D),D}const K=new Map;function z(ae){if(!(ae instanceof U))throw new Error("ProjectivePoint expected")}class U{constructor(re,X,W){if(this.px=re,this.py=X,this.pz=W,re==null||!b.isValid(re))throw new Error("x required");if(X==null||!b.isValid(X))throw new Error("y required");if(W==null||!b.isValid(W))throw new Error("z required")}static fromAffine(re){const{x:X,y:W}=re||{};if(!re||!b.isValid(X)||!b.isValid(W))throw new Error("invalid affine point");if(re instanceof U)throw new Error("projective point not allowed");const $=D=>b.eql(D,b.ZERO);return $(X)&&$(W)?U.ZERO:new U(X,W,b.ONE)}get x(){return this.toAffine().x}get y(){return this.toAffine().y}static normalizeZ(re){const X=b.invertBatch(re.map(W=>W.pz));return re.map((W,$)=>W.toAffine(X[$])).map(U.fromAffine)}static fromHex(re){const X=U.fromAffine(T((0,i.ensureBytes)("pointHex",re)));return X.assertValidity(),X}static fromPrivateKey(re){return U.BASE.multiply(J(re))}_setWindowSize(re){this._WINDOW_SIZE=re,K.delete(this)}assertValidity(){if(this.is0()){if(v.allowInfinityPoint&&!b.is0(this.py))return;throw new Error("bad point: ZERO")}const{x:re,y:X}=this.toAffine();if(!b.isValid(re)||!b.isValid(X))throw new Error("bad point: x or y not FE");const W=b.sqr(X),$=w(re);if(!b.eql(W,$))throw new Error("bad point: equation left != right");if(!this.isTorsionFree())throw new Error("bad point: not in prime-order subgroup")}hasEvenY(){const{y:re}=this.toAffine();if(b.isOdd)return!b.isOdd(re);throw new Error("Field doesn't support isOdd")}equals(re){z(re);const{px:X,py:W,pz:$}=this,{px:D,py:L,pz:H}=re,N=b.eql(b.mul(X,H),b.mul(D,$)),j=b.eql(b.mul(W,H),b.mul(L,$));return N&&j}negate(){return new U(this.px,b.neg(this.py),this.pz)}double(){const{a:re,b:X}=v,W=b.mul(X,d),{px:$,py:D,pz:L}=this;let H=b.ZERO,N=b.ZERO,j=b.ZERO,Z=b.mul($,$),Ee=b.mul(D,D),_e=b.mul(L,L),Se=b.mul($,D);return Se=b.add(Se,Se),j=b.mul($,L),j=b.add(j,j),H=b.mul(re,j),N=b.mul(W,_e),N=b.add(H,N),H=b.sub(Ee,N),N=b.add(Ee,N),N=b.mul(H,N),H=b.mul(Se,H),j=b.mul(W,j),_e=b.mul(re,_e),Se=b.sub(Z,_e),Se=b.mul(re,Se),Se=b.add(Se,j),j=b.add(Z,Z),Z=b.add(j,Z),Z=b.add(Z,_e),Z=b.mul(Z,Se),N=b.add(N,Z),_e=b.mul(D,L),_e=b.add(_e,_e),Z=b.mul(_e,Se),H=b.sub(H,Z),j=b.mul(_e,Ee),j=b.add(j,j),j=b.add(j,j),new U(H,N,j)}add(re){z(re);const{px:X,py:W,pz:$}=this,{px:D,py:L,pz:H}=re;let N=b.ZERO,j=b.ZERO,Z=b.ZERO;const Ee=v.a,_e=b.mul(v.b,d);let Se=b.mul(X,D),Ie=b.mul(W,L),ne=b.mul($,H),ce=b.add(X,W),de=b.add(D,L);ce=b.mul(ce,de),de=b.add(Se,Ie),ce=b.sub(ce,de),de=b.add(X,$);let me=b.add(D,H);return de=b.mul(de,me),me=b.add(Se,ne),de=b.sub(de,me),me=b.add(W,$),N=b.add(L,H),me=b.mul(me,N),N=b.add(Ie,ne),me=b.sub(me,N),Z=b.mul(Ee,de),N=b.mul(_e,ne),Z=b.add(N,Z),N=b.sub(Ie,Z),Z=b.add(Ie,Z),j=b.mul(N,Z),Ie=b.add(Se,Se),Ie=b.add(Ie,Se),ne=b.mul(Ee,ne),de=b.mul(_e,de),Ie=b.add(Ie,ne),ne=b.sub(Se,ne),ne=b.mul(Ee,ne),de=b.add(de,ne),Se=b.mul(Ie,de),j=b.add(j,Se),Se=b.mul(me,de),N=b.mul(ce,N),N=b.sub(N,Se),Se=b.mul(ce,Ie),Z=b.mul(me,Z),Z=b.add(Z,Se),new U(N,j,Z)}subtract(re){return this.add(re.negate())}is0(){return this.equals(U.ZERO)}wNAF(re){return ue.wNAFCached(this,K,re,X=>{const W=b.invertBatch(X.map($=>$.pz));return X.map(($,D)=>$.toAffine(W[D])).map(U.fromAffine)})}multiplyUnsafe(re){const X=U.ZERO;if(re===u)return X;if(B(re),re===l)return this;const{endo:W}=v;if(!W)return ue.unsafeLadder(this,re);let{k1neg:$,k1:D,k2neg:L,k2:H}=W.splitScalar(re),N=X,j=X,Z=this;for(;D>u||H>u;)D&l&&(N=N.add(Z)),H&l&&(j=j.add(Z)),Z=Z.double(),D>>=l,H>>=l;return $&&(N=N.negate()),L&&(j=j.negate()),j=new U(b.mul(j.px,W.beta),j.py,j.pz),N.add(j)}multiply(re){B(re);let X=re,W,$;const{endo:D}=v;if(D){const{k1neg:L,k1:H,k2neg:N,k2:j}=D.splitScalar(X);let{p:Z,f:Ee}=this.wNAF(H),{p:_e,f:Se}=this.wNAF(j);Z=ue.constTimeNegate(L,Z),_e=ue.constTimeNegate(N,_e),_e=new U(b.mul(_e.px,D.beta),_e.py,_e.pz),W=Z.add(_e),$=Ee.add(Se)}else{const{p:L,f:H}=this.wNAF(X);W=L,$=H}return U.normalizeZ([W,$])[0]}multiplyAndAddUnsafe(re,X,W){const $=U.BASE,D=(H,N)=>N===u||N===l||!H.equals($)?H.multiplyUnsafe(N):H.multiply(N),L=D(this,X).add(D(re,W));return L.is0()?void 0:L}toAffine(re){const{px:X,py:W,pz:$}=this,D=this.is0();re==null&&(re=D?b.ONE:b.inv($));const L=b.mul(X,re),H=b.mul(W,re),N=b.mul($,re);if(D)return{x:b.ZERO,y:b.ZERO};if(!b.eql(N,b.ONE))throw new Error("invZ was invalid");return{x:L,y:H}}isTorsionFree(){const{h:re,isTorsionFree:X}=v;if(re===l)return!0;if(X)return X(U,this);throw new Error("isTorsionFree() has not been declared for the elliptic curve")}clearCofactor(){const{h:re,clearCofactor:X}=v;return re===l?this:X?X(U,this):this.multiplyUnsafe(v.h)}toRawBytes(re=!0){return this.assertValidity(),h(U,this,re)}toHex(re=!0){return n.bytesToHex(this.toRawBytes(re))}}U.BASE=new U(v.Gx,v.Gy,b.ONE),U.ZERO=new U(b.ZERO,b.ONE,b.ZERO);const F=v.nBitLength,ue=(0,t.wNAF)(U,v.endo?Math.ceil(F/2):F);return{CURVE:v,ProjectivePoint:U,normPrivateKeyToScalar:J,weierstrassEquation:w,isWithinCurveOrder:P}}function E(f){const v=(0,t.validateBasic)(f);return n.validateObject(v,{hash:"hash",hmac:"function",randomBytes:"function"},{bits2int:"function",bits2int_modN:"function",lowS:"boolean"}),Object.freeze({lowS:!0,...v})}function A(f){const v=E(f),{Fp:b,n:h}=v,T=b.BYTES+1,w=2*b.BYTES+1;function P(de){return u<de&&de<b.ORDER}function B(de){return r.mod(de,h)}function J(de){return r.invert(de,h)}const{ProjectivePoint:K,normPrivateKeyToScalar:z,weierstrassEquation:U,isWithinCurveOrder:F}=p({...v,toBytes(de,me,Te){const Ae=me.toAffine(),Be=b.toBytes(Ae.x),We=n.concatBytes;return Te?We(Uint8Array.from([me.hasEvenY()?2:3]),Be):We(Uint8Array.from([4]),Be,b.toBytes(Ae.y))},fromBytes(de){const me=de.length,Te=de[0],Ae=de.subarray(1);if(me===T&&(Te===2||Te===3)){const Be=n.bytesToNumberBE(Ae);if(!P(Be))throw new Error("Point is not on curve");const We=U(Be);let et;try{et=b.sqrt(We)}catch(Mt){const gt=Mt instanceof Error?": "+Mt.message:"";throw new Error("Point is not on curve"+gt)}const Je=(et&l)===l;return(Te&1)===1!==Je&&(et=b.neg(et)),{x:Be,y:et}}else if(me===w&&Te===4){const Be=b.fromBytes(Ae.subarray(0,b.BYTES)),We=b.fromBytes(Ae.subarray(b.BYTES,2*b.BYTES));return{x:Be,y:We}}else throw new Error(`Point of length ${me} was invalid. Expected ${T} compressed bytes or ${w} uncompressed bytes`)}}),ue=de=>n.bytesToHex(n.numberToBytesBE(de,v.nByteLength));function ae(de){const me=h>>l;return de>me}function re(de){return ae(de)?B(-de):de}const X=(de,me,Te)=>n.bytesToNumberBE(de.slice(me,Te));class W{constructor(me,Te,Ae){this.r=me,this.s=Te,this.recovery=Ae,this.assertValidity()}static fromCompact(me){const Te=v.nByteLength;return me=(0,i.ensureBytes)("compactSignature",me,Te*2),new W(X(me,0,Te),X(me,Te,2*Te))}static fromDER(me){const{r:Te,s:Ae}=e.DER.toSig((0,i.ensureBytes)("DER",me));return new W(Te,Ae)}assertValidity(){if(!F(this.r))throw new Error("r must be 0 < r < CURVE.n");if(!F(this.s))throw new Error("s must be 0 < s < CURVE.n")}addRecoveryBit(me){return new W(this.r,this.s,me)}recoverPublicKey(me){const{r:Te,s:Ae,recovery:Be}=this,We=j((0,i.ensureBytes)("msgHash",me));if(Be==null||![0,1,2,3].includes(Be))throw new Error("recovery id invalid");const et=Be===2||Be===3?Te+v.n:Te;if(et>=b.ORDER)throw new Error("recovery id 2 or 3 invalid");const Je=(Be&1)===0?"02":"03",st=K.fromHex(Je+ue(et)),Mt=J(et),gt=B(-We*Mt),Ut=B(Ae*Mt),_t=K.BASE.multiplyAndAddUnsafe(st,gt,Ut);if(!_t)throw new Error("point at infinify");return _t.assertValidity(),_t}hasHighS(){return ae(this.s)}normalizeS(){return this.hasHighS()?new W(this.r,B(-this.s),this.recovery):this}toDERRawBytes(){return n.hexToBytes(this.toDERHex())}toDERHex(){return e.DER.hexFromSig({r:this.r,s:this.s})}toCompactRawBytes(){return n.hexToBytes(this.toCompactHex())}toCompactHex(){return ue(this.r)+ue(this.s)}}const $={isValidPrivateKey(de){try{return z(de),!0}catch{return!1}},normPrivateKeyToScalar:z,randomPrivateKey:()=>{const de=r.getMinHashLength(v.n);return r.mapHashToField(v.randomBytes(de),v.n)},precompute(de=8,me=K.BASE){return me._setWindowSize(de),me.multiply(BigInt(3)),me}};function D(de,me=!0){return K.fromPrivateKey(de).toRawBytes(me)}function L(de){const me=n.isBytes(de),Te=typeof de=="string",Ae=(me||Te)&&de.length;return me?Ae===T||Ae===w:Te?Ae===2*T||Ae===2*w:de instanceof K}function H(de,me,Te=!0){if(L(de))throw new Error("first arg must be private key");if(!L(me))throw new Error("second arg must be public key");return K.fromHex(me).multiply(z(de)).toRawBytes(Te)}const N=v.bits2int||function(de){const me=n.bytesToNumberBE(de),Te=de.length*8-v.nBitLength;return Te>0?me>>BigInt(Te):me},j=v.bits2int_modN||function(de){return B(N(de))},Z=n.bitMask(v.nBitLength);function Ee(de){if(typeof de!="bigint")throw new Error("bigint expected");if(!(u<=de&&de<Z))throw new Error(`bigint expected < 2^${v.nBitLength}`);return n.numberToBytesBE(de,v.nByteLength)}function _e(de,me,Te=Se){if(["recovered","canonical"].some(Zt=>Zt in Te))throw new Error("sign() legacy options not supported");const{hash:Ae,randomBytes:Be}=v;let{lowS:We,prehash:et,extraEntropy:Je}=Te;We==null&&(We=!0),de=(0,i.ensureBytes)("msgHash",de),et&&(de=(0,i.ensureBytes)("prehashed msgHash",Ae(de)));const st=j(de),Mt=z(me),gt=[Ee(Mt),Ee(st)];if(Je!=null&&Je!==!1){const Zt=Je===!0?Be(b.BYTES):Je;gt.push((0,i.ensureBytes)("extraEntropy",Zt))}const Ut=n.concatBytes(...gt),_t=st;function Qt(Zt){const ft=N(Zt);if(!F(ft))return;const _r=J(ft),C=K.BASE.multiply(ft).toAffine(),_=B(C.x);if(_===u)return;const I=B(_r*B(_t+_*Mt));if(I===u)return;let G=(C.x===_?0:2)|Number(C.y&l),le=I;return We&&ae(I)&&(le=re(I),G^=1),new W(_,le,G)}return{seed:Ut,k2sig:Qt}}const Se={lowS:v.lowS,prehash:!1},Ie={lowS:v.lowS,prehash:!1};function ne(de,me,Te=Se){const{seed:Ae,k2sig:Be}=_e(de,me,Te),We=v;return n.createHmacDrbg(We.hash.outputLen,We.nByteLength,We.hmac)(Ae,Be)}K.BASE._setWindowSize(8);function ce(de,me,Te,Ae=Ie){var C;const Be=de;if(me=(0,i.ensureBytes)("msgHash",me),Te=(0,i.ensureBytes)("publicKey",Te),"strict"in Ae)throw new Error("options.strict was renamed to lowS");const{lowS:We,prehash:et}=Ae;let Je,st;try{if(typeof Be=="string"||n.isBytes(Be))try{Je=W.fromDER(Be)}catch(_){if(!(_ instanceof e.DER.Err))throw _;Je=W.fromCompact(Be)}else if(typeof Be=="object"&&typeof Be.r=="bigint"&&typeof Be.s=="bigint"){const{r:_,s:I}=Be;Je=new W(_,I)}else throw new Error("PARSE");st=K.fromHex(Te)}catch(_){if(_.message==="PARSE")throw new Error("signature must be Signature instance, Uint8Array or hex string");return!1}if(We&&Je.hasHighS())return!1;et&&(me=v.hash(me));const{r:Mt,s:gt}=Je,Ut=j(me),_t=J(gt),Qt=B(Ut*_t),Zt=B(Mt*_t),ft=(C=K.BASE.multiplyAndAddUnsafe(st,Qt,Zt))==null?void 0:C.toAffine();return ft?B(ft.x)===Mt:!1}return{CURVE:v,getPublicKey:D,getSharedSecret:H,sign:ne,verify:ce,ProjectivePoint:K,Signature:W,utils:$}}function R(f,v){const b=f.ORDER;let h=u;for(let ae=b-l;ae%c===u;ae/=c)h+=l;const T=h,w=c<<T-l-l,P=w*c,B=(b-l)/P,J=(B-l)/c,K=P-l,z=w,U=f.pow(v,B),F=f.pow(v,(B+l)/c);let ue=(ae,re)=>{let X=U,W=f.pow(re,K),$=f.sqr(W);$=f.mul($,re);let D=f.mul(ae,$);D=f.pow(D,J),D=f.mul(D,W),W=f.mul(D,re),$=f.mul(D,ae);let L=f.mul($,W);D=f.pow(L,z);let H=f.eql(D,f.ONE);W=f.mul($,F),D=f.mul(L,X),$=f.cmov(W,$,H),L=f.cmov(D,L,H);for(let N=T;N>l;N--){let j=N-c;j=c<<j-l;let Z=f.pow(L,j);const Ee=f.eql(Z,f.ONE);W=f.mul($,X),X=f.mul(X,X),Z=f.mul(L,X),$=f.cmov(W,$,Ee),L=f.cmov(Z,L,Ee)}return{isValid:H,value:$}};if(f.ORDER%m===d){const ae=(f.ORDER-d)/m,re=f.sqrt(f.neg(v));ue=(X,W)=>{let $=f.sqr(W);const D=f.mul(X,W);$=f.mul($,D);let L=f.pow($,ae);L=f.mul(L,D);const H=f.mul(L,re),N=f.mul(f.sqr(L),W),j=f.eql(N,X);let Z=f.cmov(H,L,j);return{isValid:j,value:Z}}}return ue}function O(f,v){if(r.validateField(f),!f.isValid(v.A)||!f.isValid(v.B)||!f.isValid(v.Z))throw new Error("mapToCurveSimpleSWU: invalid opts");const b=R(f,v.Z);if(!f.isOdd)throw new Error("Fp.isOdd is not implemented!");return h=>{let T,w,P,B,J,K,z,U;T=f.sqr(h),T=f.mul(T,v.Z),w=f.sqr(T),w=f.add(w,T),P=f.add(w,f.ONE),P=f.mul(P,v.B),B=f.cmov(v.Z,f.neg(w),!f.eql(w,f.ZERO)),B=f.mul(B,v.A),w=f.sqr(P),K=f.sqr(B),J=f.mul(K,v.A),w=f.add(w,J),w=f.mul(w,P),K=f.mul(K,B),J=f.mul(K,v.B),w=f.add(w,J),z=f.mul(T,P);const{isValid:F,value:ue}=b(w,K);U=f.mul(T,h),U=f.mul(U,ue),z=f.cmov(z,P,F),U=f.cmov(U,ue,F);const ae=f.isOdd(h)===f.isOdd(U);return U=f.cmov(f.neg(U),U,ae),z=f.div(z,B),{x:z,y:U}}}})(gp)),gp}var QS;function wF(){if(QS)return ys;QS=1,Object.defineProperty(ys,"__esModule",{value:!0}),ys.getHash=n,ys.createCurve=i;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const e=RF(),t=No(),r=zN();function n(a){return{hash:a,hmac:(s,...o)=>(0,e.hmac)(a,s,(0,t.concatBytes)(...o)),randomBytes:t.randomBytes}}function i(a,s){const o=u=>(0,r.weierstrass)({...a,...n(u)});return Object.freeze({...o(s),create:o})}return ys}var $n={},ZS;function OF(){if(ZS)return $n;ZS=1,Object.defineProperty($n,"__esModule",{value:!0}),$n.expand_message_xmd=s,$n.expand_message_xof=o,$n.hash_to_field=u,$n.isogenyMap=l,$n.createHasher=c;const e=Tl(),t=Ga(),r=t.bytesToNumberBE;function n(d,m){if(d<0||d>=1<<8*m)throw new Error(`bad I2OSP call: value=${d} length=${m}`);const p=Array.from({length:m}).fill(0);for(let E=m-1;E>=0;E--)p[E]=d&255,d>>>=8;return new Uint8Array(p)}function i(d,m){const p=new Uint8Array(d.length);for(let E=0;E<d.length;E++)p[E]=d[E]^m[E];return p}function a(d){if(!Number.isSafeInteger(d))throw new Error("number expected")}function s(d,m,p,E){(0,t.abytes)(d),(0,t.abytes)(m),a(p),m.length>255&&(m=E((0,t.concatBytes)((0,t.utf8ToBytes)("H2C-OVERSIZE-DST-"),m)));const{outputLen:A,blockLen:R}=E,O=Math.ceil(p/A);if(O>255)throw new Error("Invalid xmd length");const f=(0,t.concatBytes)(m,n(m.length,1)),v=n(0,R),b=n(p,2),h=new Array(O),T=E((0,t.concatBytes)(v,d,b,n(0,1),f));h[0]=E((0,t.concatBytes)(T,n(1,1),f));for(let P=1;P<=O;P++){const B=[i(T,h[P-1]),n(P+1,1),f];h[P]=E((0,t.concatBytes)(...B))}return(0,t.concatBytes)(...h).slice(0,p)}function o(d,m,p,E,A){if((0,t.abytes)(d),(0,t.abytes)(m),a(p),m.length>255){const R=Math.ceil(2*E/8);m=A.create({dkLen:R}).update((0,t.utf8ToBytes)("H2C-OVERSIZE-DST-")).update(m).digest()}if(p>65535||m.length>255)throw new Error("expand_message_xof: invalid lenInBytes");return A.create({dkLen:p}).update(d).update(n(p,2)).update(m).update(n(m.length,1)).digest()}function u(d,m,p){(0,t.validateObject)(p,{DST:"stringOrUint8Array",p:"bigint",m:"isSafeInteger",k:"isSafeInteger",hash:"hash"});const{p:E,k:A,m:R,hash:O,expand:f,DST:v}=p;(0,t.abytes)(d),a(m);const b=typeof v=="string"?(0,t.utf8ToBytes)(v):v,h=E.toString(2).length,T=Math.ceil((h+A)/8),w=m*R*T;let P;if(f==="xmd")P=s(d,b,w,O);else if(f==="xof")P=o(d,b,w,A,O);else if(f==="_internal_pass")P=d;else throw new Error('expand must be "xmd" or "xof"');const B=new Array(m);for(let J=0;J<m;J++){const K=new Array(R);for(let z=0;z<R;z++){const U=T*(z+J*R),F=P.subarray(U,U+T);K[z]=(0,e.mod)(r(F),E)}B[J]=K}return B}function l(d,m){const p=m.map(E=>Array.from(E).reverse());return(E,A)=>{const[R,O,f,v]=p.map(b=>b.reduce((h,T)=>d.add(d.mul(h,E),T)));return E=d.div(R,O),A=d.mul(A,d.div(f,v)),{x:E,y:A}}}function c(d,m,p){if(typeof m!="function")throw new Error("mapToCurve() must be defined");return{hashToCurve(E,A){const R=u(E,2,{...p,DST:p.DST,...A}),O=d.fromAffine(m(R[0])),f=d.fromAffine(m(R[1])),v=O.add(f).clearCofactor();return v.assertValidity(),v},encodeToCurve(E,A){const R=u(E,1,{...p,DST:p.encodeDST,...A}),O=d.fromAffine(m(R[0])).clearCofactor();return O.assertValidity(),O},mapToCurve(E){if(!Array.isArray(E))throw new Error("mapToCurve: expected array of bigints");for(const R of E)if(typeof R!="bigint")throw new Error(`mapToCurve: expected array of bigints, got ${R} in array`);const A=d.fromAffine(m(E)).clearCofactor();return A.assertValidity(),A}}}return $n}var xS;function NF(){return xS||(xS=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.encodeToCurve=e.hashToCurve=e.schnorr=e.secp256k1=void 0;/*! noble-curves - MIT License (c) 2022 Paul Miller (paulmillr.com) */const t=IF(),r=No(),n=wF(),i=OF(),a=Tl(),s=Ga(),o=zN(),u=BigInt("0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffffc2f"),l=BigInt("0xfffffffffffffffffffffffffffffffebaaedce6af48a03bbfd25e8cd0364141"),c=BigInt(1),d=BigInt(2),m=(W,$)=>(W+$/d)/$;function p(W){const $=u,D=BigInt(3),L=BigInt(6),H=BigInt(11),N=BigInt(22),j=BigInt(23),Z=BigInt(44),Ee=BigInt(88),_e=W*W*W%$,Se=_e*_e*W%$,Ie=(0,a.pow2)(Se,D,$)*Se%$,ne=(0,a.pow2)(Ie,D,$)*Se%$,ce=(0,a.pow2)(ne,d,$)*_e%$,de=(0,a.pow2)(ce,H,$)*ce%$,me=(0,a.pow2)(de,N,$)*de%$,Te=(0,a.pow2)(me,Z,$)*me%$,Ae=(0,a.pow2)(Te,Ee,$)*Te%$,Be=(0,a.pow2)(Ae,Z,$)*me%$,We=(0,a.pow2)(Be,D,$)*Se%$,et=(0,a.pow2)(We,j,$)*de%$,Je=(0,a.pow2)(et,L,$)*_e%$,st=(0,a.pow2)(Je,d,$);if(!E.eql(E.sqr(st),W))throw new Error("Cannot find square root");return st}const E=(0,a.Field)(u,void 0,void 0,{sqrt:p});e.secp256k1=(0,n.createCurve)({a:BigInt(0),b:BigInt(7),Fp:E,n:l,Gx:BigInt("55066263022277343669578718895168534326250603453777594175500187360389116729240"),Gy:BigInt("32670510020758816978083085130507043184471273380659243275938904335757337482424"),h:BigInt(1),lowS:!0,endo:{beta:BigInt("0x7ae96a2b657c07106e64479eac3434e99cf0497512f58995c1396c28719501ee"),splitScalar:W=>{const $=l,D=BigInt("0x3086d221a7d46bcde86c90e49284eb15"),L=-c*BigInt("0xe4437ed6010e88286f547fa90abfe4c3"),H=BigInt("0x114ca50f7a8e2f3f657c1108d9d44cfd8"),N=D,j=BigInt("0x100000000000000000000000000000000"),Z=m(N*W,$),Ee=m(-L*W,$);let _e=(0,a.mod)(W-Z*D-Ee*H,$),Se=(0,a.mod)(-Z*L-Ee*N,$);const Ie=_e>j,ne=Se>j;if(Ie&&(_e=$-_e),ne&&(Se=$-Se),_e>j||Se>j)throw new Error("splitScalar: Endomorphism failed, k="+W);return{k1neg:Ie,k1:_e,k2neg:ne,k2:Se}}}},t.sha256);const A=BigInt(0),R=W=>typeof W=="bigint"&&A<W&&W<u,O=W=>typeof W=="bigint"&&A<W&&W<l,f={};function v(W,...$){let D=f[W];if(D===void 0){const L=(0,t.sha256)(Uint8Array.from(W,H=>H.charCodeAt(0)));D=(0,s.concatBytes)(L,L),f[W]=D}return(0,t.sha256)((0,s.concatBytes)(D,...$))}const b=W=>W.toRawBytes(!0).slice(1),h=W=>(0,s.numberToBytesBE)(W,32),T=W=>(0,a.mod)(W,u),w=W=>(0,a.mod)(W,l),P=e.secp256k1.ProjectivePoint,B=(W,$,D)=>P.BASE.multiplyAndAddUnsafe(W,$,D);function J(W){let $=e.secp256k1.utils.normPrivateKeyToScalar(W),D=P.fromPrivateKey($);return{scalar:D.hasEvenY()?$:w(-$),bytes:b(D)}}function K(W){if(!R(W))throw new Error("bad x: need 0 < x < p");const $=T(W*W),D=T($*W+BigInt(7));let L=p(D);L%d!==A&&(L=T(-L));const H=new P(W,L,c);return H.assertValidity(),H}function z(...W){return w((0,s.bytesToNumberBE)(v("BIP0340/challenge",...W)))}function U(W){return J(W).bytes}function F(W,$,D=(0,r.randomBytes)(32)){const L=(0,s.ensureBytes)("message",W),{bytes:H,scalar:N}=J($),j=(0,s.ensureBytes)("auxRand",D,32),Z=h(N^(0,s.bytesToNumberBE)(v("BIP0340/aux",j))),Ee=v("BIP0340/nonce",Z,H,L),_e=w((0,s.bytesToNumberBE)(Ee));if(_e===A)throw new Error("sign failed: k is zero");const{bytes:Se,scalar:Ie}=J(_e),ne=z(Se,H,L),ce=new Uint8Array(64);if(ce.set(Se,0),ce.set(h(w(Ie+ne*N)),32),!ue(ce,L,H))throw new Error("sign: Invalid signature produced");return ce}function ue(W,$,D){const L=(0,s.ensureBytes)("signature",W,64),H=(0,s.ensureBytes)("message",$),N=(0,s.ensureBytes)("publicKey",D,32);try{const j=K((0,s.bytesToNumberBE)(N)),Z=(0,s.bytesToNumberBE)(L.subarray(0,32));if(!R(Z))return!1;const Ee=(0,s.bytesToNumberBE)(L.subarray(32,64));if(!O(Ee))return!1;const _e=z(h(Z),b(j),H),Se=B(j,Ee,w(-_e));return!(!Se||!Se.hasEvenY()||Se.toAffine().x!==Z)}catch{return!1}}e.schnorr={getPublicKey:U,sign:F,verify:ue,utils:{randomPrivateKey:e.secp256k1.utils.randomPrivateKey,lift_x:K,pointToBytes:b,numberToBytesBE:s.numberToBytesBE,bytesToNumberBE:s.bytesToNumberBE,taggedHash:v,mod:a.mod}};const ae=(0,i.isogenyMap)(E,[["0x8e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38daaaaa8c7","0x7d3d4c80bc321d5b9f315cea7fd44c5d595d2fc0bf63b92dfff1044f17c6581","0x534c328d23f234e6e2a413deca25caece4506144037c40314ecbd0b53d9dd262","0x8e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38e38daaaaa88c"],["0xd35771193d94918a9ca34ccbb7b640dd86cd409542f8487d9fe6b745781eb49b","0xedadc6f64383dc1df7c4b2d51b54225406d36b641f5e41bbc52a56612a8c6d14","0x0000000000000000000000000000000000000000000000000000000000000001"],["0x4bda12f684bda12f684bda12f684bda12f684bda12f684bda12f684b8e38e23c","0xc75e0c32d5cb7c0fa9d0a54b12a0a6d5647ab046d686da6fdffc90fc201d71a3","0x29a6194691f91a73715209ef6512e576722830a201be2018a765e85a9ecee931","0x2f684bda12f684bda12f684bda12f684bda12f684bda12f684bda12f38e38d84"],["0xfffffffffffffffffffffffffffffffffffffffffffffffffffffffefffff93b","0x7a06534bb8bdb49fd5e9e6632722c2989467c1bfc8e8d978dfb425d2685c2573","0x6484aa716545ca2cf3a70c3fa8fe337e0a3d21162f0d6299a7bf8192bfd2a76f","0x0000000000000000000000000000000000000000000000000000000000000001"]].map(W=>W.map($=>BigInt($)))),re=(0,o.mapToCurveSimpleSWU)(E,{A:BigInt("0x3f8731abdd661adca08a5558f0f5d272e953d363cb6f0e5d405447c01a444533"),B:BigInt("1771"),Z:E.create(BigInt("-11"))}),X=(0,i.createHasher)(e.secp256k1.ProjectivePoint,W=>{const{x:$,y:D}=re(E.create(W[0]));return ae($,D)},{DST:"secp256k1_XMD:SHA-256_SSWU_RO_",encodeDST:"secp256k1_XMD:SHA-256_SSWU_NU_",p:E.ORDER,m:1,k:128,expand:"xmd",hash:t.sha256});e.hashToCurve=X.hashToCurve,e.encodeToCurve=X.encodeToCurve})(mp)),mp}var eI;function PF(){return eI||(eI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.secp256k1=void 0;var t=NF();Object.defineProperty(e,"secp256k1",{enumerable:!0,get:function(){return t.secp256k1}})})(pp)),pp}var tI;function MF(){if(tI)return Zr;tI=1,Object.defineProperty(Zr,"__esModule",{value:!0}),Zr.recoverPublicKey=r,Zr.recoverAddressFromEthSignature=i,Zr.sign=a,Zr.createEthereumMessageHash=s,Zr.ethSign=o,Zr.computeAddress=u,Zr.createUnsafeIdentity=l;const e=bl(),t=PF();function r(c,d){if(c.length!==65)throw new Error("Invalid signature length "+c.length);const m=c[64];if(m!==27&&m!==28)throw new Error(`Invalid signature recovery value: ${m}. Expected 27 or 28.`);const p=c.slice(0,c.length-1),E=m===28?1:0;return t.secp256k1.Signature.fromCompact(p).addRecoveryBit(E).recoverPublicKey(d).toRawBytes(!1).slice(1)}function n(c){if(c.length!==65)throw new Error("Invalid ethereum signature");const d=c[64];if(d===0||d===1){const m=new Uint8Array(c);return m[64]=d+27,m}return c}function i(c,d){if(typeof c=="string"){if((0,e.isHex)(c))return i((0,e.hexToBytes)(c),d);throw new Error("String signatures must be encoded in hex")}return u(r(n(c),s(d)))}function a(c,d){const m=t.secp256k1.sign(d,c),p=m.recovery===1?"1c":"1b";return"0x"+m.toCompactHex()+p}function s(c){const d=typeof c=="string"?(0,e.stringToUtf8Bytes)(c):c,m=(0,e.concatBytes)((0,e.stringToUtf8Bytes)(`Ethereum Signed Message:
|
|
70
|
+
`),(0,e.stringToUtf8Bytes)(String(d.length)),d);return(0,e.hexToBytes)((0,e.sha3)(m))}function o(c,d){return a(c,s(d))}function u(c){let d;if(c.length===65&&c[0]===4)d=c.slice(1);else if(c.length===64)d=c;else throw new Error(`Invalid public key length: ${c.length}. Expected 64 bytes, or 65 bytes with a leading 0x04 uncompressed prefix.`);return(0,e.getAddress)((0,e.sha3)(d).substring(24))}function l(){const c=t.secp256k1.utils.randomPrivateKey(),d=t.secp256k1.getPublicKey(c,!1).slice(1),m=u(d);return{privateKey:(0,e.bytesToHex)(c),publicKey:(0,e.bytesToHex)(d),address:m}}return Zr}var Pc={},rI;function CF(){if(rI)return Pc;rI=1,Object.defineProperty(Pc,"__esModule",{value:!0});const e=bl();class t{constructor(n,i=!0){Cn(this,"requestManager");Cn(this,"checkedBlocks");Cn(this,"saveBlocks");Cn(this,"savedBlocks");Cn(this,"requests");Cn(this,"blockTime");Cn(this,"firstTimestamp");this.requestManager=n,this.checkedBlocks={},this.saveBlocks=i,this.savedBlocks={},this.requests=0}async fillBlockTime(){const n=await this.getBlockWrapper("latest"),i=await this.getBlockWrapper(1);return this.blockTime=(n.timestamp-i.timestamp)/(Number(n.number)-1),this.firstTimestamp=i.timestamp,{blockTime:this.blockTime,firstTimestamp:this.firstTimestamp}}async getDate(n,i=!0){const a=n/1e3,s=Date.now()/1e3;let o=this.firstTimestamp,u=this.blockTime;if((o===void 0||u===void 0)&&({firstTimestamp:o,blockTime:u}=await this.fillBlockTime()),a<o)return{block:1,timestamp:a};const l=this.savedBlocks.latest;if(a>=s||l&&a>l.timestamp)return{block:(0,e.toBigNumber)(await this.requestManager.eth_blockNumber()).toNumber(),timestamp:a};this.checkedBlocks[a]=[];const c=await this.getBlockWrapper(Math.ceil((a-o)/u));return{block:await this.findBetter(a,c,i,u),timestamp:a}}async findBetter(n,i,a,s){let o=s??this.blockTime??(await this.fillBlockTime()).blockTime;if(await this.isBetterBlock(n,i,a))return i.number;const u=n-i.timestamp;let l=Math.ceil(u/o);l===0&&(l=u<0?-1:1);const c=await this.getBlockWrapper(this.getNextBlock(n,i.number,l));return o=Math.abs((i.timestamp-c.timestamp)/(i.number-c.number)),this.findBetter(n,c,a,o)}async isBetterBlock(n,i,a){const s=i.timestamp;if(a){if(s<n)return!1;const o=await this.getBlockWrapper(i.number-1);if(s>=n&&o.timestamp<n)return!0}else{if(s>=n)return!1;const o=await this.getBlockWrapper(i.number+1);if(s<n&&o.timestamp>=n)return!0}return!1}getNextBlock(n,i,a){const s=i+a;if(this.checkedBlocks[n].includes(s)){const o=a<0?a+1:a-1;if(o===0)throw new Error(`Could not find an unchecked block for timestamp ${n}`);return this.getNextBlock(n,i,o)}return this.checkedBlocks[n].push(s),s}async getBlockWrapper(n){if(!this.saveBlocks){const s=await this.requestManager.eth_getBlockByNumber(n,!1);return{number:(0,e.toBigNumber)(s.number).toNumber(),timestamp:(0,e.toBigNumber)(s.timestamp).toNumber()}}const i=n.toString();if(this.savedBlocks[i])return this.savedBlocks[i];if(typeof n=="number"&&this.savedBlocks.latest&&this.savedBlocks.latest.number<=n)return this.savedBlocks.latest;const{timestamp:a}=await this.requestManager.eth_getBlockByNumber(n,!1);return this.savedBlocks[i]={number:(0,e.toBigNumber)(n==="latest"?await this.requestManager.eth_blockNumber():n).toNumber(),timestamp:(0,e.toBigNumber)(a).toNumber()},this.requests++,this.savedBlocks[i]}}return Pc.default=t,Pc}var Mc={},nI;function DF(){if(nI)return Mc;nI=1,Object.defineProperty(Mc,"__esModule",{value:!0}),Mc.moveMinutes=e;function e(t){const r=new Date;return r.setMinutes(r.getMinutes()+t),r}return Mc}var _p={},Dr={},yi={},gi={},Ep={},jr={},iI;function Ne(){if(iI)return jr;iI=1;var e=jr&&jr.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};Object.defineProperty(jr,"__esModule",{value:!0}),jr.validateType=jr.generateLazyValidator=jr.Ajv=void 0;const t=e(Fg());jr.Ajv=t.default;const r=e(gN()),n=e(_N());function i(s,o){let u=null;const l=(c,d)=>{if(!u){const m=new t.default({$data:!0,allErrors:!0});(0,r.default)(m),(0,n.default)(m,{singleError:!0}),o==null||o.forEach(p=>m.addKeyword(p)),u=m.compile(s),Object.defineProperty(l,"errors",{get(){return u==null?void 0:u.errors}})}return u(c,d)};return l}jr.generateLazyValidator=i;function a(s,o){return s.validate(o)}return jr.validateType=a,jr}var aI;function jF(){return aI||(aI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SceneUpdate=e.SCENE_UPDATE=void 0;const t=Ne();e.SCENE_UPDATE="SCENE_UPDATE",(function(r){r.schema={type:"object",properties:{type:{type:"string",enum:[e.SCENE_UPDATE]},payload:{type:"object",properties:{sceneId:{type:"string"},sceneType:{type:"string"}},additionalProperties:!1,required:["sceneId","sceneType"]}},required:["payload","type"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.SceneUpdate||(e.SceneUpdate={}))})(Ep)),Ep}var vp={},sI;function $F(){return sI||(sI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Update=e.UPDATE=void 0;const t=Ne();e.UPDATE="update",(function(r){r.schema={type:"object",properties:{type:{type:"string",enum:[e.UPDATE]}},required:["type"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Update||(e.Update={}))})(vp)),vp}var oI;function LF(){return oI||(oI=1,(function(e){var t=gi&&gi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=gi&&gi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(jF(),e),r($F(),e)})(gi)),gi}var _i={},bp={},uI;function qF(){return uI||(uI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProjectType=void 0;const t=Ne();(function(r){r.SCENE="scene",r.SMART_ITEM="smart-item",r.PORTABLE_EXPERIENCE="portable-experience",r.LIBRARY="library"})(e.ProjectType||(e.ProjectType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.ProjectType||(e.ProjectType={}))})(bp)),bp}var Tp={},Sp={},cI;function Sl(){return cI||(cI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Rarity=void 0;const t=Ne();(function(r){r.UNIQUE="unique",r.MYTHIC="mythic",r.EXOTIC="exotic",r.LEGENDARY="legendary",r.EPIC="epic",r.RARE="rare",r.UNCOMMON="uncommon",r.COMMON="common"})(e.Rarity||(e.Rarity={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema);const n={[r.UNIQUE]:1,[r.MYTHIC]:10,[r.EXOTIC]:50,[r.LEGENDARY]:100,[r.EPIC]:1e3,[r.RARE]:5e3,[r.UNCOMMON]:1e4,[r.COMMON]:1e5},i={[r.UNIQUE]:"#FFE617",[r.MYTHIC]:"#FB7DE3",[r.EXOTIC]:"#E4FFB8",[r.LEGENDARY]:"#A657ED",[r.EPIC]:"#6397F2",[r.RARE]:"#3AD682",[r.UNCOMMON]:"#FF8563",[r.COMMON]:"#D4E0E0"},a={[r.UNIQUE]:"#FFB626",[r.MYTHIC]:"#FF63E1",[r.EXOTIC]:"#CAFF73",[r.LEGENDARY]:"#842DDA",[r.EPIC]:"#3D85E6",[r.RARE]:"#36CF75",[r.UNCOMMON]:"#ED6D4F",[r.COMMON]:"#ABC1C1"};function s(c){return n[c]}r.getMaxSupply=s;function o(c){return a[c]}r.getColor=o;function u(){return[r.UNIQUE,r.MYTHIC,r.EXOTIC,r.LEGENDARY,r.EPIC,r.RARE,r.UNCOMMON,r.COMMON]}r.getRarities=u;function l(c){return[i[c],a[c]]}r.getGradient=l})(e.Rarity||(e.Rarity={}))})(Sp)),Sp}var Ip={},lI;function aa(){return lI||(lI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WearableCategory=void 0;const t=Ne();(function(r){r.EYEBROWS="eyebrows",r.EYES="eyes",r.FACIAL_HAIR="facial_hair",r.HAIR="hair",r.BODY_SHAPE="body_shape",r.MOUTH="mouth",r.UPPER_BODY="upper_body",r.LOWER_BODY="lower_body",r.FEET="feet",r.EARRING="earring",r.EYEWEAR="eyewear",r.HAT="hat",r.HELMET="helmet",r.MASK="mask",r.TIARA="tiara",r.TOP_HEAD="top_head",r.SKIN="skin",r.HANDS_WEAR="hands_wear"})(e.WearableCategory||(e.WearableCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.WearableCategory||(e.WearableCategory={}))})(Ip)),Ip}var Rp={},Ap={},dI;function xg(){return dI||(dI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.BodyShape=void 0;const t=Ne();(function(r){r.MALE="urn:decentraland:off-chain:base-avatars:BaseMale",r.FEMALE="urn:decentraland:off-chain:base-avatars:BaseFemale"})(e.BodyShape||(e.BodyShape={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.BodyShape||(e.BodyShape={}))})(Ap)),Ap}var wp={},Op={},fI;function WN(){return fI||(fI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.BodyPartCategory=void 0;const t=Ne();(function(r){r.HEAD="head",r.HANDS="hands"})(e.BodyPartCategory||(e.BodyPartCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.BodyPartCategory||(e.BodyPartCategory={}))})(Op)),Op}var pI;function e_(){return pI||(pI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.HideableWearableCategory=void 0;const t=aa(),r=Ne(),n=WN();(function(i){i.schema={oneOf:[Object.assign({},t.WearableCategory.schema),Object.assign({},n.BodyPartCategory.schema)]},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.HideableWearableCategory||(e.HideableWearableCategory={}))})(wp)),wp}var mI;function t_(){return mI||(mI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WearableRepresentation=void 0;const t=Ne(),r=xg(),n=e_();(function(i){i.schema={type:"object",properties:{bodyShapes:{type:"array",items:r.BodyShape.schema,minItems:1,uniqueItems:!0},mainFile:{type:"string",minLength:1},contents:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,contains:{const:{$data:"2/mainFile"}}},overrideHides:{type:"array",items:n.HideableWearableCategory.schema},overrideReplaces:{type:"array",items:n.HideableWearableCategory.schema}},required:["bodyShapes","mainFile","contents","overrideHides","overrideReplaces"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.WearableRepresentation||(e.WearableRepresentation={}))})(Rp)),Rp}var Ei={},vi={},Np={},Pp={},hI;function sa(){return hI||(hI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.IPFSv1=e.IPFSv2=e.EthAddress=e.Color3=void 0;const t=Ne();(function(r){r.schema={type:"object",required:["r","g","b"],properties:{r:{type:"number",minimum:0,maximum:1},g:{type:"number",minimum:0,maximum:1},b:{type:"number",minimum:0,maximum:1}}};const n=(0,t.generateLazyValidator)(r.schema);r.validate=i=>n(i)})(e.Color3||(e.Color3={})),(function(r){r.schema={type:"string",pattern:"^0x[a-fA-F0-9]{40}$"};const n=new RegExp(r.schema.pattern);r.validate=i=>n.test(i)})(e.EthAddress||(e.EthAddress={})),(function(r){r.schema={type:"string",pattern:"^(ba)[a-zA-Z0-9]{57}$"};const n=new RegExp(r.schema.pattern);r.validate=i=>n.test(i)})(e.IPFSv2||(e.IPFSv2={})),(function(r){r.schema={type:"string",pattern:"^(Qm)[a-zA-Z0-9]{44}$"};const n=new RegExp(r.schema.pattern);r.validate=i=>n.test(i)})(e.IPFSv1||(e.IPFSv1={}))})(Pp)),Pp}var yI;function YN(){return yI||(yI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Avatar=e.Link=e.LinkUrl=e.AvatarInfo=e.Snapshots=void 0;const t=aa(),r=sa(),n=Ne();var i;(function(u){u.schema={type:"object",required:["face256","body"],properties:{face256:r.IPFSv2.schema,body:r.IPFSv2.schema}},u.validate=(0,n.generateLazyValidator)(u.schema)})(i=e.Snapshots||(e.Snapshots={}));var a;(function(u){u.schema={type:"object",required:["bodyShape","eyes","hair","skin"],properties:{bodyShape:{type:"string"},eyes:{type:"object",required:["color"],properties:{color:r.Color3.schema}},hair:{type:"object",required:["color"],properties:{color:r.Color3.schema}},skin:{type:"object",required:["color"],properties:{color:r.Color3.schema}},wearables:{type:"array",items:{type:"string"}},forceRender:{type:"array",nullable:!0,items:t.WearableCategory.schema},emotes:{type:"array",items:{type:"object",properties:{slot:{type:"number"},urn:{type:"string"}},required:["slot","urn"]},nullable:!0},snapshots:Object.assign(Object.assign({},i.schema),{nullable:!0})},additionalProperties:!0},u.validate=(0,n.generateLazyValidator)(u.schema)})(a=e.AvatarInfo||(e.AvatarInfo={}));var s;(function(u){u.schema={type:"string",maxLength:2083,pattern:"^(?:https?):\\/\\/[^\\s/$.?#].[^\\s]*$"};const l=new RegExp(u.schema.pattern,"i");u.validate=c=>l.test(c)})(s=e.LinkUrl||(e.LinkUrl={}));var o;(function(u){u.schema={type:"object",required:["title","url"],properties:{title:{type:"string"},url:s.schema}}})(o=e.Link||(e.Link={})),(function(u){u.schema={type:"object",required:["name","description","ethAddress","version","tutorialStep","avatar","hasClaimedName"],properties:{userId:{type:"string"},name:{type:"string"},nameColor:Object.assign(Object.assign({},r.Color3.schema),{nullable:!0}),description:{type:"string"},links:{type:"array",maxItems:5,items:o.schema,nullable:!0},country:{nullable:!0,type:"string"},employmentStatus:{nullable:!0,type:"string"},gender:{nullable:!0,type:"string"},pronouns:{nullable:!0,type:"string"},relationshipStatus:{nullable:!0,type:"string"},sexualOrientation:{nullable:!0,type:"string"},language:{nullable:!0,type:"string"},profession:{nullable:!0,type:"string"},birthdate:{nullable:!0,type:"number"},realName:{nullable:!0,type:"string"},hobbies:{nullable:!0,type:"string"},ethAddress:r.EthAddress.schema,version:{type:"number"},tutorialStep:{type:"number"},email:{type:"string",nullable:!0},blocked:{type:"array",items:{type:"string"},nullable:!0},muted:{type:"array",items:{type:"string"},nullable:!0},interests:{type:"array",items:{type:"string"},nullable:!0},hasClaimedName:{type:"boolean"},hasConnectedWeb3:{type:"boolean",nullable:!0},avatar:a.schema},additionalProperties:!0},u.validate=(0,n.generateLazyValidator)(u.schema)})(e.Avatar||(e.Avatar={}))})(Np)),Np}var Mp={},gI;function kF(){return gI||(gI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Profile=void 0;const t=Ne(),r=YN();(function(n){n.schema={type:"object",required:["avatars"],properties:{avatars:{type:"array",items:r.Avatar.schema}},additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.Profile||(e.Profile={}))})(Mp)),Mp}var _I;function BF(){return _I||(_I=1,(function(e){var t=vi&&vi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=vi&&vi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(YN(),e),r(kF(),e)})(vi)),vi}var Cp={},Dp={},EI;function KN(){return EI||(EI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.FeatureToggles=e.portableExperiencesToggles=e.toggles=void 0;const t=Ne();e.toggles=["enabled","disabled"],e.portableExperiencesToggles=[...e.toggles,"hideUi"],(function(r){r.schema={type:"object",properties:{voiceChat:{type:"string",enum:e.toggles,nullable:!0},portableExperiences:{type:"string",enum:e.portableExperiencesToggles,nullable:!0,errorMessage:`valid options are ${e.portableExperiencesToggles.join(", ")}`}},errorMessage:`valid options are ${e.toggles.join(", ")}`,required:[]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.FeatureToggles||(e.FeatureToggles={}))})(Dp)),Dp}var jp={},vI;function JN(){return vI||(vI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WorldConfiguration=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{name:{type:"string",nullable:!0},skybox:{type:"number",nullable:!0},minimapVisible:{type:"boolean",nullable:!0},miniMapConfig:{type:"object",nullable:!0,properties:{visible:{type:"boolean",nullable:!0},dataImage:{type:"string",nullable:!0},estateImage:{type:"string",nullable:!0}}},skyboxConfig:{type:"object",nullable:!0,properties:{fixedTime:{type:"number",nullable:!0},textures:{type:"array",nullable:!0,items:{type:"string"},oneOf:[{minItems:0,maxItems:0},{minItems:1,maxItems:1},{minItems:6,maxItems:6}],errorMessage:"customSkybox must be an array of 0, 1 or 6 strings"}}},fixedAdapter:{type:"string",nullable:!0},placesConfig:{type:"object",nullable:!0,properties:{optOut:{type:"boolean",nullable:!0}}}},required:[]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.WorldConfiguration||(e.WorldConfiguration={}))})(jp)),jp}var $p={},bI;function XN(){return bI||(bI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SceneParcels=void 0;const t=Ne();(function(r){r.schema={description:'Describes a scene, a set of parcels whose content is treated as the same entity. A list of parcels is listed, for which one of them is considered the "base" for positioning purposes.',type:"object",properties:{base:{type:"string",pattern:"^-?[0-9]+,-?[0-9]+$"},parcels:{type:"array",items:{type:"string",pattern:"^-?[0-9]+,-?[0-9]+$"},minItems:1}},additionalProperties:!0,required:["base","parcels"]},r.schemaValidator=(0,t.generateLazyValidator)(r.schema),r.validate=n=>r.schemaValidator(n)&&n.parcels.includes(n.base)})(e.SceneParcels||(e.SceneParcels={}))})($p)),$p}var Lp={},_s={},TI;function r_(){return TI||(TI=1,Object.defineProperty(_s,"__esModule",{value:!0}),_s.displayableProperties=void 0,_s.displayableProperties={menuBarIcon:{description:"Name of the file used as icon for the MenuBar",type:"string",nullable:!0}}),_s}var qp={},SI;function QN(){return SI||(SI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Source=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{version:{type:"number",nullable:!0},origin:{type:"string"},projectId:{type:"string"},point:{type:"object",properties:{x:{type:"integer"},y:{type:"integer"}},nullable:!0,required:["x","y"]},rotation:{type:"string",enum:["north","east","south","west"],nullable:!0},layout:{type:"object",properties:{rows:{type:"integer"},cols:{type:"integer"}},nullable:!0,required:["rows","cols"]},isEmpty:{type:"boolean",nullable:!0}},additionalProperties:!0,required:["origin","projectId"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Source||(e.Source={}))})(qp)),qp}var kp={},II;function ZN(){return II||(II=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpawnPoint=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{name:{type:"string",nullable:!0},position:{type:"object",oneOf:[{$ref:"#single-position"},{$ref:"#multi-position"}],required:["x","y","z"]},default:{type:"boolean",nullable:!0},cameraTarget:{type:"object",properties:{x:{type:"number"},y:{type:"number"},z:{type:"number"}},required:["x","y","z"],nullable:!0}},required:["position"],definitions:{"single-position":{$id:"#single-position",type:"object",properties:{x:{type:"number"},y:{type:"number"},z:{type:"number"}},required:["x","y","z"]},"multi-position":{$id:"#multi-position",type:"object",properties:{x:{type:"array",items:{type:"number"},minItems:1},y:{type:"array",items:{type:"number"},minItems:1},z:{type:"array",items:{type:"number"},minItems:1}},required:["x","y","z"]}}},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.SpawnPoint||(e.SpawnPoint={}))})(kp)),kp}var RI;function UF(){return RI||(RI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Scene=e.RequiredPermission=void 0;const t=Ne(),r=r_(),n=KN(),i=XN(),a=QN(),s=ZN(),o=JN();var u;(function(l){l.ALLOW_TO_MOVE_PLAYER_INSIDE_SCENE="ALLOW_TO_MOVE_PLAYER_INSIDE_SCENE",l.ALLOW_TO_TRIGGER_AVATAR_EMOTE="ALLOW_TO_TRIGGER_AVATAR_EMOTE",l.ALLOW_MEDIA_HOSTNAMES="ALLOW_MEDIA_HOSTNAMES",l.USE_WEB3_API="USE_WEB3_API",l.USE_FETCH="USE_FETCH",l.USE_WEBSOCKET="USE_WEBSOCKET",l.OPEN_EXTERNAL_LINK="OPEN_EXTERNAL_LINK"})(u=e.RequiredPermission||(e.RequiredPermission={})),(function(l){l.schema={type:"object",properties:Object.assign(Object.assign({isPortableExperience:{description:"Define the current scene as a Portable Experience",type:"boolean",nullable:!0},main:{description:"File that contains the entry point of the scene's code",type:"string",minLength:1},scene:i.SceneParcels.schema},r.displayableProperties),{display:{description:"Information related to how should this land be displayed apart from the normal rendering of the scene",type:"object",properties:{title:{description:"A name so other users can identify what the contents of this land should be",type:"string",nullable:!0},favicon:{description:"DEPRECATED. Allow the land owner to set up a favicon to this land",type:"string",nullable:!0},description:{description:"A description that will be shown on client's nav map when the scene is selected",type:"string",nullable:!0},navmapThumbnail:{type:"string",nullable:!0}},nullable:!0,required:[]},owner:{type:"string",nullable:!0},creator:{type:"string",nullable:!0,description:"Wallet address of the creator of the scene",pattern:"^(0x[a-fA-F0-9]{40})?$",errorMessage:"Creator must be a valid wallet address"},contact:{description:"Describe different ways of contacting the land owner",type:"object",properties:{name:{type:"string",nullable:!0},email:{type:"string",nullable:!0},im:{type:"string",nullable:!0},url:{type:"string",nullable:!0}},nullable:!0,required:[]},tags:{type:"array",items:{type:"string",minLength:1},nullable:!0},source:Object.assign(Object.assign({},a.Source.schema),{nullable:!0}),spawnPoints:{type:"array",items:s.SpawnPoint.schema,nullable:!0},requiredPermissions:{type:"array",items:{type:"string",enum:Object.values(u)},uniqueItems:!0,nullable:!0},featureToggles:Object.assign(Object.assign({},n.FeatureToggles.schema),{nullable:!0}),worldConfiguration:Object.assign(Object.assign({},o.WorldConfiguration.schema),{nullable:!0}),allowedMediaHostnames:{type:"array",items:{type:"string"},nullable:!0}}),additionalProperties:!0,required:["main","scene"],dependencies:{requiredPermissions:{if:{properties:{requiredPermissions:{type:"array",contains:{const:u.ALLOW_MEDIA_HOSTNAMES}}}},then:{properties:{allowedMediaHostnames:{type:"array",items:{type:"string"},nullable:!1,minItems:1}},required:["allowedMediaHostnames"]},else:{properties:{allowedMediaHostnames:{type:["null","array"],nullable:!0,maxItems:0}}}}}},l.validate=(0,t.generateLazyValidator)(l.schema)})(e.Scene||(e.Scene={}))})(Lp)),Lp}var AI;function FF(){return AI||(AI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpawnPoint=e.Source=e.RequiredPermission=e.Scene=e.SceneParcels=e.WorldConfiguration=e.FeatureToggles=void 0;var t=KN();Object.defineProperty(e,"FeatureToggles",{enumerable:!0,get:function(){return t.FeatureToggles}});var r=JN();Object.defineProperty(e,"WorldConfiguration",{enumerable:!0,get:function(){return r.WorldConfiguration}});var n=XN();Object.defineProperty(e,"SceneParcels",{enumerable:!0,get:function(){return n.SceneParcels}});var i=UF();Object.defineProperty(e,"Scene",{enumerable:!0,get:function(){return i.Scene}}),Object.defineProperty(e,"RequiredPermission",{enumerable:!0,get:function(){return i.RequiredPermission}});var a=QN();Object.defineProperty(e,"Source",{enumerable:!0,get:function(){return a.Source}});var s=ZN();Object.defineProperty(e,"SpawnPoint",{enumerable:!0,get:function(){return s.SpawnPoint}})})(Cp)),Cp}var bi={},Bp={},Up={},wI;function xN(){return wI||(wI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Locale=void 0;const t=Ne();(function(r){r.EN="en",r.ES="es"})(e.Locale||(e.Locale={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Locale||(e.Locale={}))})(Up)),Up}var OI;function eP(){return OI||(OI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.I18N=void 0;const t=Ne(),r=xN();(function(n){n.schema={type:"object",properties:{code:r.Locale.schema,text:{type:"string"}},additionalProperties:!0,required:["code","text"]},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.I18N||(e.I18N={}))})(Bp)),Bp}var Fp={},NI;function tP(){return NI||(NI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Metrics=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{triangles:{type:"number"},materials:{type:"number"},textures:{type:"number"},meshes:{type:"number"},bodies:{type:"number"},entities:{type:"number"}},required:["triangles","materials","textures","meshes","bodies","entities"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Metrics||(e.Metrics={}))})(Fp)),Fp}var Vp={},PI;function n_(){return PI||(PI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.isStandard=e.standardProperties=void 0;const t=Sl(),r=Ne();e.standardProperties={collectionAddress:{type:"string",nullable:!1},rarity:t.Rarity.schema};const n={type:"object",properties:Object.assign({},e.standardProperties),required:["collectionAddress","rarity"]},i=(0,r.generateLazyValidator)(n);function a(s){return i(s)}e.isStandard=a})(Vp)),Vp}var Hp={},Ti={},Gp={},MI;function VF(){return MI||(MI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.MerkleProof=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{proof:{type:"array",items:{type:"string"}},index:{type:"number"},hashingKeys:{type:"array",items:{type:"string"}},entityHash:{type:"string"}},required:["entityHash","hashingKeys","index","proof"],additionalProperties:!0},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.MerkleProof||(e.MerkleProof={}))})(Gp)),Gp}var CI;function rP(){return CI||(CI=1,(function(e){var t=Ti&&Ti.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Ti&&Ti.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(VF(),e)})(Ti)),Ti}var zp={},DI;function i_(){return DI||(DI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.createMappingsHelper=e.AddMappingError=e.Mappings=e.Mapping=e.MultipleMapping=e.RangeMapping=e.AnyMapping=e.SingleMapping=e.ContractNetwork=e.MappingType=void 0;const t=Ne();var r;(function(d){d.SINGLE="single",d.ANY="any",d.MULTIPLE="multiple",d.RANGE="range"})(r=e.MappingType||(e.MappingType={}));var n;(function(d){d.MAINNET="mainnet",d.BASE_MAINNET="base_mainnet",d.BASE_SEPOLIA="base_sepolia",d.MONAD_MAINNET="monad_mainnet",d.MONAD_TESTNET="monad_testnet",d.APE_MAINNET="ape_mainnet",d.APE_CALDERA="ape_caldera",d.MATIC="matic",d.SEPOLIA="sepolia",d.AMOY="amoy"})(n=e.ContractNetwork||(e.ContractNetwork={}));var i;(function(d){d.schema={type:"object",properties:{type:{type:"string",const:r.SINGLE},id:{type:"string",pattern:"^[0-9]+$"}},required:["type","id"],additionalProperties:!1},d.validate=(0,t.generateLazyValidator)(d.schema)})(i=e.SingleMapping||(e.SingleMapping={}));var a;(function(d){d.schema={type:"object",properties:{type:{type:"string",const:r.ANY}},required:["type"],additionalProperties:!1},d.validate=(0,t.generateLazyValidator)(d.schema)})(a=e.AnyMapping||(e.AnyMapping={}));var s;(function(d){d._fromLessThanOrEqualTo={keyword:"_fromLessThanOrEqualTo",validate:function(p,E){if(!E||!E.from||!E.to)return!1;let{to:A,from:R}=E;return(typeof R!="bigint"||typeof A!="bigint")&&(R=BigInt(R),A=BigInt(A)),R<=A},errors:!1},d.schema={type:"object",properties:{type:{type:"string",const:r.RANGE},from:{type:"string",pattern:"^[0-9]+$"},to:{type:"string",pattern:"^[0-9]+$"}},required:["type","from","to"],additionalProperties:!1,_fromLessThanOrEqualTo:!0},d.validate=(0,t.generateLazyValidator)(d.schema,[d._fromLessThanOrEqualTo])})(s=e.RangeMapping||(e.RangeMapping={}));var o;(function(d){d.schema={type:"object",properties:{type:{type:"string",const:r.MULTIPLE},ids:{type:"array",items:{type:"string",pattern:"^[0-9]+$"},minItems:1,uniqueItems:!0}},required:["type","ids"],additionalProperties:!1},d.validate=(0,t.generateLazyValidator)(d.schema)})(o=e.MultipleMapping||(e.MultipleMapping={}));var u;(function(d){d.schema={type:"object",properties:{type:{type:"string",enum:Object.values(r)}},required:["type"],oneOf:[i.schema,a.schema,s.schema,o.schema]},d.validate=(0,t.generateLazyValidator)(d.schema,[s._fromLessThanOrEqualTo])})(u=e.Mapping||(e.Mapping={})),(function(d){d._isMappingsValid={keyword:"_isMappingsValid",validate:function(p,E){try{c(E)}catch{return!1}return!0},errors:!1},d.innerSchema={type:"object",patternProperties:{"^0x[0-9a-fA-F]{40}$":{type:"array",items:u.schema}},minProperties:1,required:[],additionalProperties:!1};const m=Object.values(n).reduce((p,E)=>(p[E]=d.innerSchema,p),{});d.schema={type:"object",properties:m,minProperties:1,additionalProperties:!1,_isMappingsValid:!0},d.validate=(0,t.generateLazyValidator)(d.schema,[s._fromLessThanOrEqualTo,d._isMappingsValid])})(e.Mappings||(e.Mappings={}));class l extends Error{constructor(m,p,E){super(m),this.existingMapping=p,this.conflictingMapping=E}}e.AddMappingError=l;function c(d={}){const m={};for(const[h,T]of Object.entries(d)){m[h]={};for(const[w,P]of Object.entries(T))for(const B of P)v(h,w,B)}function p(){return JSON.parse(JSON.stringify(m))}function E(h,T,w){const P=BigInt(h);return P>=BigInt(T)&&P<=BigInt(w)}function A(h,T){switch(T.type){case r.SINGLE:return h.id===T.id;case r.MULTIPLE:return T.ids.includes(h.id);case r.RANGE:return E(h.id,T.from,T.to);default:return!1}}function R(h,T){switch(T.type){case r.SINGLE:return h.ids.includes(T.id);case r.MULTIPLE:return h.ids.some(w=>T.ids.includes(w));case r.RANGE:return h.ids.some(w=>E(w,T.from,T.to));default:return!1}}function O(h,T){switch(T.type){case r.SINGLE:return E(T.id,h.from,h.to);case r.MULTIPLE:return T.ids.some(w=>E(w,h.from,h.to));case r.RANGE:return BigInt(h.from)<=BigInt(T.to)&&BigInt(h.to)>=BigInt(T.from)}}function f(h,T){if(h.type===r.ANY||T.type===r.ANY)return!0;switch(h.type){case r.SINGLE:return A(h,T);case r.MULTIPLE:return R(h,T);case r.RANGE:return O(h,T)}}function v(h,T,w){var P,B;const J=T.toLowerCase();m[h]=(P=m[h])!==null&&P!==void 0?P:{},m[h][J]=(B=m[h][J])!==null&&B!==void 0?B:[];for(const K of m[h][J])if(f(K,w))throw new l(`Cannot add mapping to contract ${J} on network ${h} because it overlaps with existing mapping`,K,w);m[h][J].push(w)}function b(h,T,w){var P;return!((P=m[h])===null||P===void 0)&&P[T]?m[h][T].some(B=>{switch(B.type){case r.SINGLE:return B.id===w;case r.ANY:return!0;case r.MULTIPLE:return B.ids.includes(w);case r.RANGE:return BigInt(w)>=BigInt(B.from)&&BigInt(w)<=BigInt(B.to)}}):!1}return{addMapping:v,getMappings:p,includesNft:b}}e.createMappingsHelper=c})(zp)),zp}var jI;function a_(){return jI||(jI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.isThirdParty=e.schema=void 0;const t=Ne(),r=rP(),n=i_();e.schema={type:"object",properties:{merkleProof:r.MerkleProof.schema,content:{type:"object",nullable:!1,additionalProperties:{type:"string"},required:[]},mappings:Object.assign({nullable:!0},n.Mappings.schema)},required:["merkleProof","content"],_containsHashingKeys:!0};const i={keyword:"_containsHashingKeys",validate:function(o,u){var l;const c=u;return!((l=c==null?void 0:c.merkleProof)===null||l===void 0)&&l.hashingKeys?c.merkleProof.hashingKeys.every(d=>c.hasOwnProperty(d)):!1},errors:!1},a=(0,t.generateLazyValidator)(e.schema,[i,n.RangeMapping._fromLessThanOrEqualTo,n.Mappings._isMappingsValid]);function s(o){return a(o)}e.isThirdParty=s})(Hp)),Hp}var Wp={},Yp={},$r={},$I;function nP(){if($I)return $r;$I=1,Object.defineProperty($r,"__esModule",{value:!0}),$r.isBaseEmote=$r.isBaseAvatar=$r.requiredBaseItemProps=$r.baseItemProperties=void 0;const e=eP(),t=tP(),r=r_();$r.baseItemProperties=Object.assign(Object.assign({},r.displayableProperties),{id:{type:"string"},name:{type:"string"},description:{type:"string"},i18n:{type:"array",items:e.I18N.schema,minItems:1,uniqueItemProperties:["code"],errorMessage:'${0#} array should not have duplicates for "code"'},thumbnail:{type:"string"},image:{type:"string"},metrics:Object.assign(Object.assign({},t.Metrics.schema),{nullable:!0})}),$r.requiredBaseItemProps=["id","name","description","i18n","thumbnail","image"];function n(a){if(!a||!a.id)return!1;const s=a.id.split(":"),o=s[1]==="decentraland",u=s[3]==="base-avatars";return s.length===5&&o&&u}$r.isBaseAvatar=n;function i(a){if(!a||!a.id)return!1;const s=a.id.split(":");return s.length===5&&s[1]==="decentraland"&&s[3]==="base-emotes"}return $r.isBaseEmote=i,$r}var LI;function HF(){return LI||(LI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Wearable=void 0;const t=Ne(),r=aa(),n=t_(),i=nP(),a=n_(),s=a_(),o=e_(),u=i_();(function(l){l.schema={type:"object",properties:Object.assign(Object.assign(Object.assign(Object.assign({},i.baseItemProperties),a.standardProperties),s.schema.properties.thirdPartyProps),{data:{type:"object",properties:{replaces:{type:"array",items:o.HideableWearableCategory.schema},hides:{type:"array",items:o.HideableWearableCategory.schema},tags:{type:"array",items:{type:"string",minLength:1}},representations:{type:"array",items:n.WearableRepresentation.schema,minItems:1},category:r.WearableCategory.schema,removesDefaultHiding:{type:"array",nullable:!0,items:o.HideableWearableCategory.schema},blockVrmExport:{type:"boolean",nullable:!0},outlineCompatible:{type:"boolean",nullable:!0}},required:["replaces","hides","tags","representations","category"]}}),additionalProperties:!0,required:[],oneOf:[{required:["id","i18n"],prohibited:["merkleProof","content","collectionAddress","rarity","mappings"],_isBaseAvatar:!0},{required:[...i.requiredBaseItemProps,"data","collectionAddress","rarity"],prohibited:["merkleProof","content","mappings"]},{required:[...i.requiredBaseItemProps,"data","merkleProof","content"],prohibited:["collectionAddress","rarity"],_isThirdParty:!0}],errorMessage:{oneOf:"either standard XOR thirdparty properties conditions must be met"}};const c={keyword:"_isThirdParty",validate:(m,p)=>!m||(0,s.isThirdParty)(p),errors:!1},d={keyword:"_isBaseAvatar",validate:(m,p)=>!m||(0,i.isBaseAvatar)(p),errors:!1};l.validate=(0,t.generateLazyValidator)(l.schema,[c,d,u.RangeMapping._fromLessThanOrEqualTo,u.Mappings._isMappingsValid])})(e.Wearable||(e.Wearable={}))})(Yp)),Yp}var qI;function GF(){return qI||(qI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.HideableWearableCategory=e.BodyPartCategory=e.WearableCategory=e.Wearable=e.WearableRepresentation=void 0;var t=t_();Object.defineProperty(e,"WearableRepresentation",{enumerable:!0,get:function(){return t.WearableRepresentation}});var r=HF();Object.defineProperty(e,"Wearable",{enumerable:!0,get:function(){return r.Wearable}});var n=aa();Object.defineProperty(e,"WearableCategory",{enumerable:!0,get:function(){return n.WearableCategory}});var i=WN();Object.defineProperty(e,"BodyPartCategory",{enumerable:!0,get:function(){return i.BodyPartCategory}});var a=e_();Object.defineProperty(e,"HideableWearableCategory",{enumerable:!0,get:function(){return a.HideableWearableCategory}})})(Wp)),Wp}var Kp={},Jp={},Xp={},Qp={},kI;function iP(){return kI||(kI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteCategory=void 0;const t=Ne();(function(r){r.DANCE="dance",r.STUNT="stunt",r.GREETINGS="greetings",r.FUN="fun",r.POSES="poses",r.REACTIONS="reactions",r.HORROR="horror",r.MISCELLANEOUS="miscellaneous"})(e.EmoteCategory||(e.EmoteCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.EmoteCategory||(e.EmoteCategory={}))})(Qp)),Qp}var Zp={},BI;function aP(){return BI||(BI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteRepresentationADR74=void 0;const t=Ne(),r=xg();(function(n){n.schema={type:"object",properties:{bodyShapes:{type:"array",items:r.BodyShape.schema,minItems:1,uniqueItems:!0},mainFile:{type:"string",minLength:1},contents:{type:"array",items:{type:"string"},minItems:1,uniqueItems:!0,contains:{const:{$data:"2/mainFile"}},errorMessage:{contains:"contents should contain mainFile: ${1/mainFile}"}}},required:["bodyShapes","mainFile","contents"]},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EmoteRepresentationADR74||(e.EmoteRepresentationADR74={}))})(Zp)),Zp}var xp={},UI;function sP(){return UI||(UI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.OutcomeGroup=e.StartAnimation=e.EmoteClip=e.ArmatureId=void 0;const t=Ne();var r;(function(i){i.Armature="Armature",i.Armature_Prop="Armature_Prop",i.Armature_Other="Armature_Other"})(r=e.ArmatureId||(e.ArmatureId={})),(function(i){i.schema={type:"string",enum:Object.values(i)},i.validate=(0,t.generateLazyValidator)(i.schema)})(r=e.ArmatureId||(e.ArmatureId={}));var n;(function(i){i.schema={type:"object",properties:{animation:{type:"string",minLength:1,errorMessage:"animation must be a non-empty string (GLB clip name)"}},required:["animation"],additionalProperties:!1,errorMessage:{required:{animation:"animation is required (GLB clip name)"}}},i.validate=(0,t.generateLazyValidator)(i.schema)})(n=e.EmoteClip||(e.EmoteClip={})),(function(i){i.schema={type:"object",properties:{loop:{type:"boolean",errorMessage:"startAnimation.loop must be a boolean"},[r.Armature]:Object.assign(Object.assign({},n.schema),{errorMessage:"startAnimation.Armature is required and must contain valid animation data"}),[r.Armature_Prop]:Object.assign(Object.assign({},n.schema),{nullable:!0,errorMessage:"startAnimation.Armature_Prop must contain valid animation data when provided"}),audio:{type:"string",nullable:!0,errorMessage:"audio must be a string (audio clip filename) when provided"}},required:["loop",r.Armature],additionalProperties:!1,errorMessage:{required:{loop:"startAnimation.loop is required",[r.Armature]:"startAnimation.Armature is required"}}},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.StartAnimation||(e.StartAnimation={})),(function(i){i.schema={type:"object",properties:{title:{type:"string",minLength:1,errorMessage:"outcome.title must be a non-empty string"},loop:{type:"boolean",errorMessage:"outcome.loop must be a boolean"},clips:{type:"object",properties:Object.values(r).reduce((a,s)=>(a[s]=Object.assign(Object.assign({},n.schema),{nullable:!0,errorMessage:`outcome.clips.${s} must contain valid animation data when provided`}),a),{}),additionalProperties:!0,minProperties:1,errorMessage:"outcome.clips must contain at least one armature animation"},audio:{type:"string",nullable:!0,errorMessage:"audio must be a string (audio clip filename) when provided"}},required:["title","loop","clips"],additionalProperties:!1,errorMessage:{required:{title:"outcome.title is required",loop:"outcome.loop is required",clips:"outcome.clips is required"}}},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.OutcomeGroup||(e.OutcomeGroup={}))})(xp)),xp}var FI;function oP(){return FI||(FI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteDataADR74=void 0;const t=iP(),r=Ne(),n=aP(),i=sP();(function(a){a.schema={type:"object",properties:{tags:{type:"array",items:{type:"string",minLength:1}},representations:{type:"array",items:n.EmoteRepresentationADR74.schema,minItems:1},category:t.EmoteCategory.schema,loop:{type:"boolean"},startAnimation:Object.assign(Object.assign({},i.StartAnimation.schema),{nullable:!0}),randomizeOutcomes:{type:"boolean",nullable:!0},outcomes:{type:"array",items:i.OutcomeGroup.schema,minItems:1,maxItems:3,nullable:!0}},required:["category","tags","representations","loop"],dependencies:{startAnimation:["randomizeOutcomes","outcomes"],randomizeOutcomes:["startAnimation","outcomes"],outcomes:["startAnimation","randomizeOutcomes"]},additionalProperties:!0},a.validate=(0,r.generateLazyValidator)(a.schema)})(e.EmoteDataADR74||(e.EmoteDataADR74={}))})(Xp)),Xp}var VI;function zF(){return VI||(VI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Emote=void 0;const t=uP(),r=Ne(),n=nP(),i=n_(),a=a_(),s=oP();(function(o){o.schema={type:"object",properties:Object.assign(Object.assign(Object.assign(Object.assign({},n.baseItemProperties),i.standardProperties),a.schema.properties),{emoteDataADR74:s.EmoteDataADR74.schema}),additionalProperties:!0,required:[...n.requiredBaseItemProps],oneOf:[{required:["emoteDataADR74"],oneOf:[{required:["id","i18n"],prohibited:["merkleProof","content","collectionAddress","rarity"],_isBaseEmote:!0},{required:["collectionAddress","rarity"],prohibited:["merkleProof","content"],errorMessage:"standard properties conditions are not met"},{required:["merkleProof","content","id","name","description","i18n","image","thumbnail","emoteDataADR74"],_isThirdParty:!0,prohibited:["collectionAddress","rarity"],errorMessage:"thirdparty properties conditions are not met"}],errorMessage:{oneOf:"emote should have either standard or thirdparty properties"}}],errorMessage:{oneOf:'emote should have "emoteDataADR74" and match its schema'}};const u={keyword:"_isThirdParty",validate:(c,d)=>!c||(0,t.isThirdParty)(d),errors:!1},l={keyword:"_isBaseEmote",validate:(c,d)=>!c||(0,n.isBaseEmote)(d),errors:!1};o.validate=(0,r.generateLazyValidator)(o.schema,[u,l,t.RangeMapping._fromLessThanOrEqualTo,t.Mappings._isMappingsValid])})(e.Emote||(e.Emote={}))})(Jp)),Jp}var em={},HI;function WF(){return HI||(HI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmotePlayMode=void 0;const t=Ne();(function(r){r.SIMPLE="simple",r.LOOP="loop"})(e.EmotePlayMode||(e.EmotePlayMode={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.EmotePlayMode||(e.EmotePlayMode={}))})(em)),em}var tm={},GI;function YF(){return GI||(GI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteOutcomeType=void 0;const t=Ne();(function(r){r.SIMPLE_OUTCOME="so",r.MULTIPLE_OUTCOME="mo",r.RANDOM_OUTCOME="ro"})(e.EmoteOutcomeType||(e.EmoteOutcomeType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.EmoteOutcomeType||(e.EmoteOutcomeType={}))})(tm)),tm}var zI;function KF(){return zI||(zI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EmoteOutcomeType=e.EmotePlayMode=e.EmoteCategory=e.StartAnimation=e.OutcomeGroup=e.EmoteClip=e.ArmatureId=e.EmoteDataADR74=e.EmoteRepresentationADR74=e.Emote=void 0;var t=zF();Object.defineProperty(e,"Emote",{enumerable:!0,get:function(){return t.Emote}});var r=aP();Object.defineProperty(e,"EmoteRepresentationADR74",{enumerable:!0,get:function(){return r.EmoteRepresentationADR74}});var n=oP();Object.defineProperty(e,"EmoteDataADR74",{enumerable:!0,get:function(){return n.EmoteDataADR74}});var i=sP();Object.defineProperty(e,"ArmatureId",{enumerable:!0,get:function(){return i.ArmatureId}}),Object.defineProperty(e,"EmoteClip",{enumerable:!0,get:function(){return i.EmoteClip}}),Object.defineProperty(e,"OutcomeGroup",{enumerable:!0,get:function(){return i.OutcomeGroup}}),Object.defineProperty(e,"StartAnimation",{enumerable:!0,get:function(){return i.StartAnimation}});var a=iP();Object.defineProperty(e,"EmoteCategory",{enumerable:!0,get:function(){return a.EmoteCategory}});var s=WF();Object.defineProperty(e,"EmotePlayMode",{enumerable:!0,get:function(){return s.EmotePlayMode}});var o=YF();Object.defineProperty(e,"EmoteOutcomeType",{enumerable:!0,get:function(){return o.EmoteOutcomeType}})})(Kp)),Kp}var WI;function uP(){return WI||(WI=1,(function(e){var t=bi&&bi.__createBinding||(Object.create?(function(l,c,d,m){m===void 0&&(m=d);var p=Object.getOwnPropertyDescriptor(c,d);(!p||("get"in p?!c.__esModule:p.writable||p.configurable))&&(p={enumerable:!0,get:function(){return c[d]}}),Object.defineProperty(l,m,p)}):(function(l,c,d,m){m===void 0&&(m=d),l[m]=c[d]})),r=bi&&bi.__exportStar||function(l,c){for(var d in l)d!=="default"&&!Object.prototype.hasOwnProperty.call(c,d)&&t(c,l,d)};Object.defineProperty(e,"__esModule",{value:!0}),e.isThirdParty=e.isStandard=e.BodyShape=e.Metrics=e.Locale=e.I18N=void 0;var n=eP();Object.defineProperty(e,"I18N",{enumerable:!0,get:function(){return n.I18N}});var i=xN();Object.defineProperty(e,"Locale",{enumerable:!0,get:function(){return i.Locale}});var a=tP();Object.defineProperty(e,"Metrics",{enumerable:!0,get:function(){return a.Metrics}});var s=xg();Object.defineProperty(e,"BodyShape",{enumerable:!0,get:function(){return s.BodyShape}});var o=n_();Object.defineProperty(e,"isStandard",{enumerable:!0,get:function(){return o.isStandard}});var u=a_();Object.defineProperty(e,"isThirdParty",{enumerable:!0,get:function(){return u.isThirdParty}}),r(i_(),e),r(GF(),e),r(KF(),e)})(bi)),bi}var rm={},nm={},YI;function Po(){return YI||(YI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.AuthChain=e.AuthLink=e.AuthLinkType=void 0;const t=Ne();var r;(function(i){i.SIGNER="SIGNER",i.ECDSA_PERSONAL_EPHEMERAL="ECDSA_EPHEMERAL",i.ECDSA_PERSONAL_SIGNED_ENTITY="ECDSA_SIGNED_ENTITY",i.ECDSA_EIP_1654_EPHEMERAL="ECDSA_EIP_1654_EPHEMERAL",i.ECDSA_EIP_1654_SIGNED_ENTITY="ECDSA_EIP_1654_SIGNED_ENTITY"})(r=e.AuthLinkType||(e.AuthLinkType={}));var n;(function(i){i.schema={type:"object",properties:{type:{type:"string",enum:Object.values(r)},payload:{type:"string"},signature:{type:"string",nullable:!0}},required:["payload","type"],if:{properties:{type:{not:{const:r.SIGNER}}}},then:{required:["signature"]},else:{oneOf:[{properties:{signature:{type:"string",const:""}},required:["signature"]},{properties:{signature:{type:"null"}}}]}},i.validate=(0,t.generateLazyValidator)(i.schema)})(n=e.AuthLink||(e.AuthLink={})),(function(i){i.schema={type:"array",items:n.schema,minItems:1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.AuthChain||(e.AuthChain={}))})(nm)),nm}var KI;function JF(){return KI||(KI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PointerChangesSyncDeployment=e.SnapshotSyncDeployment=void 0;const t=sa(),r=Po(),n=Ne();(function(i){i.schema={type:"object",properties:{entityId:{type:"string"},entityType:{type:"string"},pointers:{type:"array",items:{type:"string"},minItems:1},authChain:r.AuthChain.schema,entityTimestamp:{type:"number",minimum:0}},oneOf:[{properties:{entityId:t.IPFSv1.schema}},{properties:{entityId:t.IPFSv2.schema}}],required:["entityId","entityType","pointers","entityTimestamp","authChain"]},i.validate=(0,n.generateLazyValidator)(i.schema)})(e.SnapshotSyncDeployment||(e.SnapshotSyncDeployment={})),(function(i){i.schema={type:"object",properties:{entityId:{type:"string"},entityType:{type:"string"},pointers:{type:"array",items:{type:"string"},minItems:1},authChain:r.AuthChain.schema,entityTimestamp:{type:"number",minimum:0},localTimestamp:{type:"number",minimum:0}},oneOf:[{properties:{entityId:t.IPFSv1.schema}},{properties:{entityId:t.IPFSv2.schema}}],required:["entityId","entityType","pointers","localTimestamp","entityTimestamp","authChain"]},i.validate=(0,n.generateLazyValidator)(i.schema)})(e.PointerChangesSyncDeployment||(e.PointerChangesSyncDeployment={}))})(rm)),rm}var im={},am={},JI;function cP(){return JI||(JI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ContentMapping=void 0;const t=sa(),r=Ne();(function(n){n.schema={type:"object",properties:{file:{type:"string",minLength:1},hash:{type:"string",oneOf:[t.IPFSv1.schema,t.IPFSv2.schema]}},required:["file","hash"]},n.validate=(0,r.generateLazyValidator)(n.schema)})(e.ContentMapping||(e.ContentMapping={}))})(am)),am}var XI;function lP(){return XI||(XI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Entity=e.EntityType=void 0;const t=sa(),r=cP(),n=Ne();(function(i){i.SCENE="scene",i.PROFILE="profile",i.WEARABLE="wearable",i.STORE="store",i.EMOTE="emote",i.OUTFITS="outfits"})(e.EntityType||(e.EntityType={})),(function(i){i.schema={type:"object",properties:{version:{type:"string",enum:["v3"]},id:{type:"string",oneOf:[t.IPFSv1.schema,t.IPFSv2.schema]},type:{type:"string"},pointers:{type:"array",items:{type:"string",minLength:1}},timestamp:{type:"number",minimum:0},content:{type:"array",items:r.ContentMapping.schema},metadata:{type:"object",nullable:!0}},required:["version","id","type","pointers","timestamp","content"]},i.validate=(0,n.generateLazyValidator)(i.schema)})(e.Entity||(e.Entity={}))})(im)),im}var sm={},QI;function XF(){return QI||(QI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.DeploymentWithAuthChain=void 0;const t=Po(),r=Ne();(function(n){n.schema={type:"object",properties:{entityId:{type:"string"},entityType:{type:"string"},pointers:{type:"array",items:{type:"string"},minItems:1},localTimestamp:{type:"number",minimum:0},authChain:t.AuthChain.schema},required:["entityId","entityType","pointers","localTimestamp","authChain"]},n.validate=(0,r.generateLazyValidator)(n.schema)})(e.DeploymentWithAuthChain||(e.DeploymentWithAuthChain={}))})(sm)),sm}var Si={},om={},ZI;function QF(){return ZI||(ZI=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Outfits=e.Outfit=void 0;const t=aa(),r=sa(),n=Ne();var i;(function(a){a.schema={type:"object",required:["bodyShape","eyes","hair","skin","wearables"],properties:{bodyShape:{type:"string"},eyes:{type:"object",required:["color"],properties:{color:r.Color3.schema}},hair:{type:"object",required:["color"],properties:{color:r.Color3.schema}},skin:{type:"object",required:["color"],properties:{color:r.Color3.schema}},wearables:{type:"array",items:{type:"string"}},forceRender:{type:"array",nullable:!0,items:t.WearableCategory.schema}},additionalProperties:!0},a.validate=(0,n.generateLazyValidator)(a.schema)})(i=e.Outfit||(e.Outfit={})),(function(a){a.schema={type:"object",required:["outfits","namesForExtraSlots"],properties:{outfits:{type:"array",items:{type:"object",required:["slot","outfit"],properties:{slot:{type:"number"},outfit:i.schema}}},namesForExtraSlots:{type:"array",uniqueItems:!0,items:{type:"string"}}},additionalProperties:!0},a.validate=(0,n.generateLazyValidator)(a.schema)})(e.Outfits||(e.Outfits={}))})(om)),om}var xI;function ZF(){return xI||(xI=1,(function(e){var t=Si&&Si.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Si&&Si.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(QF(),e)})(Si)),Si}var Ii={},um={},e1;function dP(){return e1||(e1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.NotificationOptOutScope=e.NotificationType=void 0,(function(t){t.BADGE_GRANTED="badge_granted",t.BID_ACCEPTED="bid_accepted",t.BID_RECEIVED="bid_received",t.EVENTS_STARTED="events_started",t.EVENTS_STARTS_SOON="events_starts_soon",t.EVENT_CREATED="event_created",t.GOVERNANCE_ANNOUNCEMENT="governance_announcement",t.GOVERNANCE_AUTHORED_PROPOSAL_FINISHED="governance_authored_proposal_finished",t.GOVERNANCE_COAUTHOR_REQUESTED="governance_coauthor_requested",t.GOVERNANCE_CLIFF_ENDED="governance_cliff_ended",t.GOVERNANCE_NEW_COMMENT_ON_PROJECT_UPDATE="governance_new_comment_on_project_update",t.GOVERNANCE_NEW_COMMENT_ON_PROPOSAL="governance_new_comment_on_proposal",t.GOVERNANCE_PROPOSAL_ENACTED="governance_proposal_enacted",t.GOVERNANCE_VOTING_ENDED_VOTER="governance_voting_ended_voter",t.GOVERNANCE_PITCH_PASSED="governance_pitch_passed",t.GOVERNANCE_TENDER_PASSED="governance_tender_passed",t.GOVERNANCE_WHALE_VOTE="governance_whale_vote",t.GOVERNANCE_VOTED_ON_BEHALF="governance_voted_on_behalf",t.ITEM_SOLD="item_sold",t.ITEM_PUBLISHED="item_published",t.LAND_RENTAL_ENDED="rental_ended",t.LAND_RENTED="rental_started",t.REWARD_ASSIGNED="reward_assignment",t.REWARD_CAMPAIGN_OUT_OF_FUNDS="reward_campaign_out_of_funds",t.REWARD_CAMPAIGN_GAS_PRICE_HIGHER_THAN_EXPECTED="reward_campaign_gas_price_higher_than_expected",t.REWARD_CAMPAIGN_OUT_OF_STOCK="reward_campaign_out_of_stock",t.REWARD_DELAYED="reward_delayed",t.REWARD_IN_PROGRESS="reward_in_progress",t.ROYALTIES_EARNED="royalties_earned",t.SOCIAL_SERVICE_FRIENDSHIP_REQUEST="social_service_friendship_request",t.SOCIAL_SERVICE_FRIENDSHIP_ACCEPTED="social_service_friendship_accepted",t.WORLDS_ACCESS_RESTORED="worlds_access_restored",t.WORLDS_ACCESS_RESTRICTED="worlds_access_restricted",t.WORLDS_MISSING_RESOURCES="worlds_missing_resources",t.WORLDS_PERMISSION_GRANTED="worlds_permission_granted",t.WORLDS_PERMISSION_REVOKED="worlds_permission_revoked",t.CREDITS_GOAL_COMPLETED="credits_goal_completed",t.CREDITS_ON_DEMAND_GRANTED="credits_on_demand_granted",t.STREAMING_KEY_RESET="streaming_key_reset",t.STREAMING_KEY_REVOKE="streaming_key_revoke",t.STREAMING_KEY_EXPIRED="streaming_key_expired",t.STREAMING_TIME_EXCEEDED="streaming_time_exceeded",t.STREAMING_PLACE_UPDATED="streaming_place_updated",t.CREDITS_REMINDER_COMPLETE_GOALS="credits_reminder_complete_goals",t.CREDITS_REMINDER_CLAIM_CREDITS="credits_reminder_claim_credits",t.CREDITS_REMINDER_USAGE="credits_reminder_usage",t.CREDITS_REMINDER_USAGE_24_HOURS="credits_reminder_usage_24_hours",t.CREDITS_REMINDER_DO_NOT_MISS_OUT="credits_reminder_do_not_miss_out",t.CREDITS_NEW_SEASON_REMINDER="credits_new_season_reminder",t.REFERRAL_INVITED_USERS_ACCEPTED="referral_invited_users_accepted",t.REFERRAL_NEW_TIER_REACHED="referral_new_tier_reached",t.COMMUNITY_DELETED="community_deleted",t.COMMUNITY_DELETED_CONTENT_VIOLATION="community_deleted_content_violation",t.COMMUNITY_RENAMED="community_renamed",t.COMMUNITY_MEMBER_BANNED="community_member_banned",t.COMMUNITY_MEMBER_REMOVED="community_member_removed",t.COMMUNITY_REQUEST_TO_JOIN_RECEIVED="community_request_to_join_received",t.COMMUNITY_REQUEST_TO_JOIN_ACCEPTED="community_request_to_join_accepted",t.COMMUNITY_INVITE_RECEIVED="community_invite_received",t.COMMUNITY_OWNERSHIP_TRANSFERRED="community_ownership_transferred",t.COMMUNITY_POST_ADDED="community_post_added",t.COMMUNITY_VOICE_CHAT_STARTED="community_voice_chat_started",t.USER_BANNED_FROM_SCENE="user_banned_from_scene",t.USER_UNBANNED_FROM_SCENE="user_unbanned_from_scene",t.TRANSFER_RECEIVED="transfer_received",t.TIP_RECEIVED="tip_received",t.BANNED="banned",t.BAN_WARNING="ban_warning",t.BAN_LIFTED="ban_lifted"})(e.NotificationType||(e.NotificationType={})),(function(t){t.COMMUNITY="community"})(e.NotificationOptOutScope||(e.NotificationOptOutScope={}))})(um)),um}var cm={},lm={},t1;function fP(){return t1||(t1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SubscriptionDetails=void 0;const t=Ne(),r=dP(),n={type:"object",required:["email","in_app"],properties:{email:{type:"boolean"},in_app:{type:"boolean"}}},i=Object.values(r.NotificationType).reduce((a,s)=>(a[s]=n,a),{});(function(a){a.schema={type:"object",required:["ignore_all_email","ignore_all_in_app","message_type"],properties:{ignore_all_email:{type:"boolean"},ignore_all_in_app:{type:"boolean"},message_type:{type:"object",required:Object.values(r.NotificationType),additionalProperties:!1,properties:i}}},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.SubscriptionDetails||(e.SubscriptionDetails={}))})(lm)),lm}var dm={},r1;function pP(){return r1||(r1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Email=void 0,(function(t){t.schema={type:"string",pattern:"^[\\w\\-\\.]+@([\\w-]+\\.)+[\\w-]{2,}$"};const r=new RegExp(t.schema.pattern);t.validate=n=>r.test(n)})(e.Email||(e.Email={}))})(dm)),dm}var n1;function xF(){return n1||(n1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Subscription=void 0;const t=Ne(),r=fP(),n=sa(),i=pP();(function(a){a.schema={type:"object",required:["address","details"],properties:{address:n.EthAddress.schema,email:Object.assign(Object.assign({},i.Email.schema),{nullable:!0}),details:r.SubscriptionDetails.schema}},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Subscription||(e.Subscription={}))})(cm)),cm}var i1;function e2(){return i1||(i1=1,(function(e){var t=Ii&&Ii.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Ii&&Ii.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(dP(),e),r(xF(),e),r(fP(),e)})(Ii)),Ii}var Ri={},fm={},a1;function dr(){return a1||(a1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Events=void 0,(function(t){(function(r){r.BLOCKCHAIN="blockchain",r.CATALYST_DEPLOYMENT="catalyst-deployment",r.WORLD="world",r.CLIENT="client",r.WEB="web",r.MARKETPLACE="marketplace",r.REWARDS="rewards",r.BADGE="badge",r.ASSET_BUNDLE="asset-bundle",r.SOCIAL_SERVICE="social-service",r.CREDITS_SERVICE="credits-service",r.STREAMING="streaming",r.COMMS="comms",r.REFERRAL="referral",r.COMMUNITY="community",r.CAMERA="camera",r.EVENT="event",r.GOVERNANCE="governance",r.MODERATION="moderation"})(t.Type||(t.Type={})),(function(r){(function(n){n.BID_ACCEPTED="bid-accepted",n.ITEM_SOLD="item-sold",n.RENTAL_ENDED="land-rental-ended",n.RENTAL_STARTED="land-rental-started",n.ROYALTIES_EARNED="royalties-earned",n.COLLECTION_CREATED="collection-created",n.ITEM_PUBLISHED="item-published",n.TRANSFER_RECEIVED="transfer-received",n.TIP_RECEIVED="tip-received"})(r.Blockchain||(r.Blockchain={})),(function(n){n.BID_RECEIVED="bid-received"})(r.Marketplace||(r.Marketplace={})),(function(n){n.SCENE="scene",n.PROFILE="profile",n.WEARABLE="wearable",n.STORE="store",n.EMOTE="emote",n.OUTFITS="outfits"})(r.CatalystDeployment||(r.CatalystDeployment={})),(function(n){n.DEPLOYMENT="deployment",n.WORLD_SETTINGS_CHANGED="world_settings_changed",n.WORLD_SCENES_UNDEPLOYMENT="world_scenes_undeployment",n.WORLD_UNDEPLOYMENT="world_undeployment",n.WORLD_SPAWN_COORDINATE_SET="world_spawn_coordinate_set",n.WORLDS_PERMISSION_GRANTED="worlds_permission_granted",n.WORLDS_PERMISSION_REVOKED="worlds_permission_revoked",n.WORLDS_ACCESS_RESTORED="worlds_access_restored",n.WORLDS_ACCESS_RESTRICTED="worlds_access_restricted",n.WORLDS_MISSING_RESOURCES="worlds_missing_resources"})(r.Worlds||(r.Worlds={})),(function(n){n.LOGGED_IN="logged-in",n.LOGGED_IN_CACHED="logged-in-cached",n.MOVE_TO_PARCEL="move-to-parcel",n.USED_EMOTE="used-emote",n.PASSPORT_OPENED="passport-opened",n.WALKED_DISTANCE="walked-distance",n.VERTICAL_HEIGHT_REACHED="vertical-height-reached"})(r.Client||(r.Client={})),(function(n){n.AUTH_IDENTIFY="auth-identify"})(r.Web||(r.Web={})),(function(n){n.REWARD_IN_PROGRESS="reward-in-progress",n.REWARD_ASSIGNED="reward-assigned",n.CAMPAIGN_OUT_OF_FUNDS="campaign-out-of-funds",n.CAMPAIGN_GAS_PRICE_HIGHER_THAN_EXPECTED="campaign-gas-price-higher-than-expected",n.CAMPAIGN_OUT_OF_STOCK="campaign-out-of-stock",n.REWARD_DELAYED="reward-delayed"})(r.Rewards||(r.Rewards={})),(function(n){n.GRANTED="badge-granted"})(r.Badge||(r.Badge={})),(function(n){n.CONVERTED="converted",n.MANUALLY_QUEUED="manually-queued"})(r.AssetBundle||(r.AssetBundle={})),(function(n){n.FRIENDSHIP_REQUEST="friendship-request",n.FRIENDSHIP_ACCEPTED="friendship-accepted"})(r.SocialService||(r.SocialService={})),(function(n){n.CREDITS_GOAL_COMPLETED="credits-goal-completed",n.COMPLETE_GOALS_REMINDER="complete-goals-reminder",n.CLAIM_CREDITS_REMINDER="claim-credits-reminder",n.DO_NOT_MISS_OUT_REMINDER="do-not-miss-out-reminder",n.USAGE_REMINDER="usage-reminder",n.USAGE_24_HOURS_REMINDER="usage-24-hours-reminder",n.ON_DEMAND_CREDITS_GRANTED="on-demand-credits-granted",n.NEW_SEASON_REMINDER="new-season-reminder"})(r.CreditsService||(r.CreditsService={})),(function(n){n.STREAMING_KEY_RESET="streaming-key-reset",n.STREAMING_KEY_REVOKE="streaming-key-revoke",n.STREAMING_KEY_EXPIRED="streaming-key-expired",n.STREAMING_TIME_EXCEEDED="streaming-time-exceeded",n.STREAMING_PLACE_UPDATED="streaming-place-updated",n.COMMUNITY_STREAMING_ENDED="community-streaming-ended"})(r.Streaming||(r.Streaming={})),(function(n){n.USER_JOINED_ROOM="user-joined-room",n.USER_LEFT_ROOM="user-left-room",n.USER_BANNED_FROM_SCENE="user-banned-from-scene",n.USER_UNBANNED_FROM_SCENE="user-unbanned-from-scene"})(r.Comms||(r.Comms={})),(function(n){n.REFERRAL_INVITED_USERS_ACCEPTED="referral-invited-users-accepted",n.REFERRAL_NEW_TIER_REACHED="referral-new-tier-reached"})(r.Referral||(r.Referral={})),(function(n){n.DELETED="community-deleted",n.DELETED_CONTENT_VIOLATION="community-deleted-content-violation",n.RENAMED="community-renamed",n.MEMBER_BANNED="community-member-banned",n.MEMBER_LEFT="community-member-left",n.MEMBER_REMOVED="community-member-removed",n.REQUEST_TO_JOIN_RECEIVED="community-request-to-join-received",n.REQUEST_TO_JOIN_ACCEPTED="community-request-to-join-accepted",n.INVITE_RECEIVED="community-invite-received",n.OWNERSHIP_TRANSFERRED="community-ownership-transferred",n.POST_ADDED="community-post-added",n.VOICE_CHAT_STARTED="community-voice-chat-started"})(r.Community||(r.Community={})),(function(n){n.PHOTO_TAKEN="photo-taken",n.PHOTO_PRIVACY_CHANGED="photo-privacy-changed"})(r.Camera||(r.Camera={})),(function(n){n.EVENT_CREATED="event-created",n.EVENT_STARTS_SOON="event-starts-soon",n.EVENT_STARTED="event-started",n.EVENT_ENDED="event-ended"})(r.Event||(r.Event={})),(function(n){n.PROPOSAL_ENACTED="governance_proposal_enacted",n.COAUTHOR_REQUESTED="governance_coauthor_requested",n.PITCH_PASSED="governance_pitch_passed",n.TENDER_PASSED="governance_tender_passed",n.AUTHORED_PROPOSAL_FINISHED="governance_authored_proposal_finished",n.VOTING_ENDED_VOTER="governance_voting_ended_voter",n.NEW_COMMENT_ON_PROPOSAL="governance_new_comment_on_proposal",n.NEW_COMMENT_ON_PROJECT_UPDATED="governance_new_comment_on_project_update",n.WHALE_VOTE="governance_whale_vote",n.VOTED_ON_BEHALF="governance_voted_on_behalf",n.CLIFF_ENDED="governance_cliff_ended"})(r.Governance||(r.Governance={})),(function(n){n.USER_BAN_CREATED="user-ban-created",n.USER_BAN_LIFTED="user-ban-lifted",n.USER_WARNING_CREATED="user-warning-created"})(r.Moderation||(r.Moderation={}))})(t.SubType||(t.SubType={}))})(e.Events||(e.Events={}))})(fm)),fm}var pm={},s1;function t2(){return s1||(s1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TipReceivedEvent=e.TransferReceivedEvent=e.CollectionCreatedEvent=e.RoyaltiesEarnedEvent=e.RentalStartedEvent=e.RentalEndedEvent=e.ItemPublishedEvent=e.ItemSoldEvent=e.BidAcceptedEvent=void 0;const t=Ne(),r=dr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.BID_ACCEPTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},seller:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},price:{type:"string"},title:{type:"string"},description:{type:"string"},network:{type:"string"}},required:["address","image","seller","category","link","price","title","network"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.BidAcceptedEvent||(e.BidAcceptedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.ITEM_SOLD},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},buyer:{type:"string"},seller:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},tokenId:{type:"string"},network:{type:"string"},title:{type:"string"},description:{type:"string"}},required:["address","image","seller","category","link","network","title","description"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.ItemSoldEvent||(e.ItemSoldEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.ITEM_PUBLISHED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{creator:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},itemId:{type:"string"},network:{type:"string"},urn:{type:"string"}},required:["creator","category","itemId","network","urn"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.ItemPublishedEvent||(e.ItemPublishedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.RENTAL_ENDED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},contract:{type:"string"},land:{type:"string",nullable:!0},lessor:{type:"string"},tenant:{type:"string"},operator:{type:"string"},startedAt:{type:"string"},endedAt:{type:"string"},tokenId:{type:"string"},link:{type:"string"},title:{type:"string"},description:{type:"string",nullable:!0}},required:["address","contract","lessor","tenant","operator","startedAt","endedAt","tokenId","link","title"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.RentalEndedEvent||(e.RentalEndedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.RENTAL_STARTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},contract:{type:"string"},land:{type:"string",nullable:!0},lessor:{type:"string"},tenant:{type:"string"},operator:{type:"string"},startedAt:{type:"string"},endedAt:{type:"string"},tokenId:{type:"string"},link:{type:"string"},title:{type:"string"},description:{type:"string",nullable:!0}},required:["address","contract","lessor","tenant","operator","startedAt","endedAt","tokenId","link","title"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.RentalStartedEvent||(e.RentalStartedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.ROYALTIES_EARNED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},royaltiesCut:{type:"string"},royaltiesCollector:{type:"string"},network:{type:"string"},title:{type:"string"},description:{type:"string",nullable:!0}},required:["address","image","category","link","royaltiesCut","royaltiesCollector","network","title"]}},required:["type","subType","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.RoyaltiesEarnedEvent||(e.RoyaltiesEarnedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.COLLECTION_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{creator:{type:"string"},name:{type:"string"}},required:["creator","name"]}},required:["type","subType","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CollectionCreatedEvent||(e.CollectionCreatedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.TRANSFER_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{senderAddress:{type:"string"},receiverAddress:{type:"string"},tokenUri:{type:"string",nullable:!0}},required:["senderAddress","receiverAddress"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.TransferReceivedEvent||(e.TransferReceivedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BLOCKCHAIN},subType:{type:"string",const:r.Events.SubType.Blockchain.TIP_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{senderAddress:{type:"string"},receiverAddress:{type:"string"},amount:{type:"string"}},required:["senderAddress","receiverAddress","amount"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.TipReceivedEvent||(e.TipReceivedEvent={}))})(pm)),pm}var mm={},o1;function r2(){return o1||(o1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CatalystDeploymentEvent=void 0;const t=Po(),r=Ne(),n=lP(),i=dr();(function(a){a.schema={type:"object",properties:{type:{type:"string",const:i.Events.Type.CATALYST_DEPLOYMENT},subType:{type:"string",enum:Object.values(i.Events.SubType.CatalystDeployment)},key:{type:"string"},timestamp:{type:"number",minimum:1},entity:n.Entity.schema,authChain:t.AuthChain.schema},required:["type","subType","entity","authChain","key","timestamp"],additionalProperties:!1},a.validate=(0,r.generateLazyValidator)(a.schema)})(e.CatalystDeploymentEvent||(e.CatalystDeploymentEvent={}))})(mm)),mm}var hm={},u1;function n2(){return u1||(u1=1,Object.defineProperty(hm,"__esModule",{value:!0})),hm}var ym={},c1;function i2(){return c1||(c1=1,Object.defineProperty(ym,"__esModule",{value:!0})),ym}var gm={},l1;function a2(){return l1||(l1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.BidReceivedEvent=void 0;const t=Ne(),r=dr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MARKETPLACE},subType:{type:"string",const:r.Events.SubType.Marketplace.BID_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},image:{type:"string"},seller:{type:"string"},category:{type:"string"},rarity:{type:"string",nullable:!0},link:{type:"string"},nftName:{type:"string",nullable:!0},price:{type:"string"},title:{type:"string"},description:{type:"string"},network:{type:"string"}},required:["address","image","seller","category","link","price","title","network"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.BidReceivedEvent||(e.BidReceivedEvent={}))})(gm)),gm}var _m={},Es={},d1;function Il(){if(d1)return Es;d1=1,Object.defineProperty(Es,"__esModule",{value:!0}),Es.createEventSchema=void 0;function e(t,r,n){return{type:"object",properties:{type:{type:"string",const:t},subType:{type:"string",const:r},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:n},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1}}return Es.createEventSchema=e,Es}var f1;function s2(){return f1||(f1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.RewardDelayedEvent=e.CampaignOutOfStockEvent=e.CampaignGasPriceHigherThanExpectedEvent=e.CampaignOutOfFundsEvent=e.RewardAssignedEvent=e.RewardInProgressEvent=void 0;const t=Ne(),r=dr(),n=Il(),i={type:"object",properties:{title:{type:"string"},description:{type:"string"},link:{type:"string",nullable:!0},beneficiary:{type:"string"},tokenName:{type:"string"},tokenImage:{type:"string"},tokenRarity:{type:"string",nullable:!0},tokenCategory:{type:"string",nullable:!0}},required:["title","description","beneficiary","tokenName","tokenImage"],additionalProperties:!1},a={type:"object",properties:{title:{type:"string"},description:{type:"string"},link:{type:"string",nullable:!0},owner:{type:"string"},campaignId:{type:"string"},campaignName:{type:"string"}},required:["title","description","owner","campaignId","campaignName"],additionalProperties:!1};(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.REWARD_IN_PROGRESS,i),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.RewardInProgressEvent||(e.RewardInProgressEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.REWARD_ASSIGNED,i),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.RewardAssignedEvent||(e.RewardAssignedEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.CAMPAIGN_OUT_OF_FUNDS,a),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.CampaignOutOfFundsEvent||(e.CampaignOutOfFundsEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.CAMPAIGN_GAS_PRICE_HIGHER_THAN_EXPECTED,a),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.CampaignGasPriceHigherThanExpectedEvent||(e.CampaignGasPriceHigherThanExpectedEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.CAMPAIGN_OUT_OF_STOCK,a),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.CampaignOutOfStockEvent||(e.CampaignOutOfStockEvent={})),(function(s){s.schema=(0,n.createEventSchema)(r.Events.Type.REWARDS,r.Events.SubType.Rewards.REWARD_DELAYED,i),s.validate=(0,t.generateLazyValidator)(s.schema)})(e.RewardDelayedEvent||(e.RewardDelayedEvent={}))})(_m)),_m}var Em={},p1;function o2(){return p1||(p1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CreditsClaimReminderEvent=e.CreditsDoNotMissOutReminderEvent=e.CreditsUsage24HoursReminderEvent=e.CreditsNewSeasonReminderEvent=e.CreditsUsageReminderEvent=e.CreditsCompleteGoalsReminderEvent=e.CreditsGoalCompletedEvent=e.CreditsOnDemandEvent=e.FriendshipAcceptedEvent=e.FriendshipRequestEvent=e.AssetBundleConversionManuallyQueuedEvent=e.AssetBundleConversionFinishedEvent=e.BadgeGrantedEvent=void 0;const t=Ne(),r=dr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.BADGE},subType:{type:"string",const:r.Events.SubType.Badge.GRANTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{badgeId:{type:"string"},badgeTierName:{type:"string",nullable:!0},badgeName:{type:"string"},badgeImageUrl:{type:"string"},address:{type:"string"}},required:["badgeId","badgeName","badgeImageUrl","address"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.BadgeGrantedEvent||(e.BadgeGrantedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.ASSET_BUNDLE},subType:{type:"string",const:r.Events.SubType.AssetBundle.CONVERTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{entityId:{type:"string"},platform:{type:"string",enum:["windows","mac","webgl"]},statusCode:{type:"number"},isLods:{type:"boolean"},isWorld:{type:"boolean"},version:{type:"string"}},required:["entityId","platform","statusCode","isLods","isWorld","version"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.AssetBundleConversionFinishedEvent||(e.AssetBundleConversionFinishedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.ASSET_BUNDLE},subType:{type:"string",const:r.Events.SubType.AssetBundle.MANUALLY_QUEUED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{entityId:{type:"string"},platform:{type:"string",enum:["windows","mac","webgl"]},isLods:{type:"boolean"},isPriority:{type:"boolean"},version:{type:"string"}},required:["entityId","platform","isLods"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.AssetBundleConversionManuallyQueuedEvent||(e.AssetBundleConversionManuallyQueuedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.SOCIAL_SERVICE},subType:{type:"string",const:r.Events.SubType.SocialService.FRIENDSHIP_REQUEST},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{requestId:{type:"string"},sender:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]},receiver:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]},message:{type:"string",nullable:!0}},required:["requestId","sender","receiver"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.FriendshipRequestEvent||(e.FriendshipRequestEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.SOCIAL_SERVICE},subType:{type:"string",const:r.Events.SubType.SocialService.FRIENDSHIP_ACCEPTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{requestId:{type:"string"},sender:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]},receiver:{type:"object",properties:{address:{type:"string"},name:{type:"string"},profileImageUrl:{type:"string"},hasClaimedName:{type:"boolean"}},required:["address","name","profileImageUrl","hasClaimedName"]}},required:["requestId","sender","receiver"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.FriendshipAcceptedEvent||(e.FriendshipAcceptedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.ON_DEMAND_CREDITS_GRANTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{creditsGranted:{type:"number",minimum:1},address:{type:"string"},granterAddress:{type:"string"}},required:["creditsGranted","address","granterAddress"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsOnDemandEvent||(e.CreditsOnDemandEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.CREDITS_GOAL_COMPLETED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{goalId:{type:"string"},creditsObtained:{type:"number",minimum:0},seasonId:{type:"number",minimum:1},weekNumber:{type:"number",minimum:1},address:{type:"string"}},required:["goalId","creditsObtained","seasonId","weekNumber","address"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsGoalCompletedEvent||(e.CreditsGoalCompletedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.COMPLETE_GOALS_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},seasonId:{type:"number",minimum:1},weekNumber:{type:"number",minimum:1},pendingGoalIds:{type:"array",items:{type:"string"},minItems:1}},required:["address","seasonId","weekNumber","pendingGoalIds"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsCompleteGoalsReminderEvent||(e.CreditsCompleteGoalsReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.USAGE_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},creditsAmount:{type:"number",minimum:1},expirationDate:{type:"string"},expirationDay:{type:"string"}},required:["address","creditsAmount","expirationDate","expirationDay"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsUsageReminderEvent||(e.CreditsUsageReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.NEW_SEASON_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{addresses:{type:"array",items:{type:"string"}},seasonName:{type:"string"},startDate:{type:"string"},endDate:{type:"string"}},required:["addresses","seasonName","startDate","endDate"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsNewSeasonReminderEvent||(e.CreditsNewSeasonReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.USAGE_24_HOURS_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},creditsAmount:{type:"number",minimum:1},expirationDate:{type:"string"}},required:["address","creditsAmount","expirationDate"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsUsage24HoursReminderEvent||(e.CreditsUsage24HoursReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.DO_NOT_MISS_OUT_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"}},required:["address"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsDoNotMissOutReminderEvent||(e.CreditsDoNotMissOutReminderEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CREDITS_SERVICE},subType:{type:"string",const:r.Events.SubType.CreditsService.CLAIM_CREDITS_REMINDER},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{address:{type:"string"},seasonId:{type:"number",minimum:1},weekNumber:{type:"number",minimum:1}},required:["address","seasonId","weekNumber"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!0},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CreditsClaimReminderEvent||(e.CreditsClaimReminderEvent={}))})(Em)),Em}var vm={},m1;function u2(){return m1||(m1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CommunityStreamingEndedEvent=e.StreamingPlaceUpdatedEvent=e.StreamingTimeExceededEvent=e.StreamingKeyExpiredEvent=e.StreamingKeyRevokeEvent=e.StreamingKeyResetEvent=void 0;const t=Ne(),r=dr(),n=Il(),i={type:"object",properties:{title:{type:"string"},description:{type:"string"},position:{type:"string"},worldName:{type:"string",nullable:!0},isWorld:{type:"boolean"},url:{type:"string"},address:{type:"string"},image:{type:"string"}},required:["position","isWorld","url","title","description","address","image"],additionalProperties:!1};(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_KEY_RESET,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingKeyResetEvent||(e.StreamingKeyResetEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_KEY_REVOKE,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingKeyRevokeEvent||(e.StreamingKeyRevokeEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_KEY_EXPIRED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingKeyExpiredEvent||(e.StreamingKeyExpiredEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_TIME_EXCEEDED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingTimeExceededEvent||(e.StreamingTimeExceededEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.STREAMING_PLACE_UPDATED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.StreamingPlaceUpdatedEvent||(e.StreamingPlaceUpdatedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.STREAMING,r.Events.SubType.Streaming.COMMUNITY_STREAMING_ENDED,{type:"object",properties:{communityId:{type:"string"},totalParticipants:{type:"number"}},required:["communityId","totalParticipants"],additionalProperties:!1}),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.CommunityStreamingEndedEvent||(e.CommunityStreamingEndedEvent={}))})(vm)),vm}var bm={},h1;function c2(){return h1||(h1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.UserUnbannedFromSceneEvent=e.UserBannedFromSceneEvent=e.UserLeftRoomEvent=e.UserJoinedRoomEvent=e.RoomType=void 0;const t=Ne(),r=dr();var n;(function(i){i.PRIVATE_MESSAGE="private-message",i.VOICE_CHAT="voice-chat",i.COMMUNITY_VOICE_CHAT="community-voice-chat",i.ISLAND="island",i.SCENE="scene",i.WORLD="world",i.UNKNOWN="unknown"})(n=e.RoomType||(e.RoomType={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_JOINED_ROOM},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{parcel:{type:"string"},sceneId:{type:"string"},userAddress:{type:"string"},realmName:{type:"string"},islandName:{type:"string",nullable:!0},communityId:{type:"string",nullable:!0},voiceChatId:{type:"string",nullable:!0},isWorld:{type:"boolean"},roomType:{type:"string",enum:Object.values(n)}},required:["parcel","sceneId","userAddress","realmName","isWorld","roomType"]}},required:["type","subType","key","timestamp","metadata"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserJoinedRoomEvent||(e.UserJoinedRoomEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_LEFT_ROOM},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{userAddress:{type:"string"},realmName:{type:"string"},isWorld:{type:"boolean"},roomType:{type:"string",enum:Object.values(n)},sceneId:{type:"string",nullable:!0},islandName:{type:"string",nullable:!0},communityId:{type:"string",nullable:!0},voiceChatId:{type:"string",nullable:!0}},required:["isWorld","userAddress","realmName","roomType"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserLeftRoomEvent||(e.UserLeftRoomEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_BANNED_FROM_SCENE},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{placeTitle:{type:"string"},userAddress:{type:"string"}},required:["placeTitle","userAddress"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserBannedFromSceneEvent||(e.UserBannedFromSceneEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMS},subType:{type:"string",const:r.Events.SubType.Comms.USER_UNBANNED_FROM_SCENE},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{placeTitle:{type:"string"},userAddress:{type:"string"}},required:["placeTitle","userAddress"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.UserUnbannedFromSceneEvent||(e.UserUnbannedFromSceneEvent={}))})(bm)),bm}var Tm={},y1;function l2(){return y1||(y1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ReferralNewTierReachedEvent=e.ReferralInvitedUsersAcceptedEvent=void 0;const t=Ne(),r=dr(),n=Il(),i={type:"object",properties:{title:{type:"string"},description:{type:"string"},address:{type:"string"},tier:{type:"number",minimum:1},url:{type:"string"},image:{type:"string"},invitedUserAddress:{type:"string"},invitedUsers:{type:"number",minimum:1},rarity:{type:"string",nullable:!0}},required:["address","tier","url","title","description","image","invitedUserAddress"],additionalProperties:!1};(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.REFERRAL,r.Events.SubType.Referral.REFERRAL_INVITED_USERS_ACCEPTED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.ReferralInvitedUsersAcceptedEvent||(e.ReferralInvitedUsersAcceptedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.REFERRAL,r.Events.SubType.Referral.REFERRAL_NEW_TIER_REACHED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.ReferralNewTierReachedEvent||(e.ReferralNewTierReachedEvent={}))})(Tm)),Tm}var Sm={},g1;function d2(){return g1||(g1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CommunityVoiceChatStartedEvent=e.CommunityOwnershipTransferredEvent=e.CommunityPostAddedEvent=e.CommunityInviteReceivedEvent=e.CommunityRequestToJoinAcceptedEvent=e.CommunityRequestToJoinReceivedEvent=e.CommunityMemberRemovedEvent=e.CommunityMemberLeftEvent=e.CommunityMemberBannedEvent=e.CommunityRenamedEvent=e.CommunityDeletedContentViolationEvent=e.CommunityDeletedEvent=void 0;const t=Ne(),r=dr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.DELETED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},memberAddresses:{type:"array",items:{type:"string"}},thumbnailUrl:{type:"string"}},required:["id","name","memberAddresses","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityDeletedEvent||(e.CommunityDeletedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.DELETED_CONTENT_VIOLATION},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},ownerAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["id","name","ownerAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityDeletedContentViolationEvent||(e.CommunityDeletedContentViolationEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.RENAMED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},oldName:{type:"string"},newName:{type:"string"},memberAddresses:{type:"array",items:{type:"string"}},thumbnailUrl:{type:"string"}},required:["id","oldName","newName","memberAddresses","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityRenamedEvent||(e.CommunityRenamedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.MEMBER_BANNED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["id","name","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityMemberBannedEvent||(e.CommunityMemberBannedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.MEMBER_LEFT},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},memberAddress:{type:"string"}},required:["id","memberAddress"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityMemberLeftEvent||(e.CommunityMemberLeftEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.MEMBER_REMOVED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{id:{type:"string"},name:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["id","name","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityMemberRemovedEvent||(e.CommunityMemberRemovedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.REQUEST_TO_JOIN_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},memberAddress:{type:"string"},memberName:{type:"string"},thumbnailUrl:{type:"string"},addressesToNotify:{type:"array",items:{type:"string"}}},required:["communityId","communityName","memberAddress","memberName","thumbnailUrl","addressesToNotify"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityRequestToJoinReceivedEvent||(e.CommunityRequestToJoinReceivedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.REQUEST_TO_JOIN_ACCEPTED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["communityId","communityName","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityRequestToJoinAcceptedEvent||(e.CommunityRequestToJoinAcceptedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.INVITE_RECEIVED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},memberAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["communityId","communityName","memberAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityInviteReceivedEvent||(e.CommunityInviteReceivedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.POST_ADDED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},thumbnailUrl:{type:"string"},postId:{type:"string"},authorAddress:{type:"string"},addressesToNotify:{type:"array",items:{type:"string"}}},required:["addressesToNotify","communityId","communityName","thumbnailUrl","postId","authorAddress"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityPostAddedEvent||(e.CommunityPostAddedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.OWNERSHIP_TRANSFERRED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},oldOwnerAddress:{type:"string"},newOwnerAddress:{type:"string"},thumbnailUrl:{type:"string"}},required:["communityId","communityName","oldOwnerAddress","newOwnerAddress","thumbnailUrl"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityOwnershipTransferredEvent||(e.CommunityOwnershipTransferredEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.COMMUNITY},subType:{type:"string",const:r.Events.SubType.Community.VOICE_CHAT_STARTED},key:{type:"string"},timestamp:{type:"number",minimum:1},metadata:{type:"object",properties:{communityId:{type:"string"},communityName:{type:"string"},thumbnailUrl:{type:"string"},addressesToNotify:{type:"array",items:{type:"string"}}},required:["communityId","communityName","thumbnailUrl","addressesToNotify"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.CommunityVoiceChatStartedEvent||(e.CommunityVoiceChatStartedEvent={}))})(Sm)),Sm}var Im={},_1;function f2(){return _1||(_1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PhotoTakenEvent=e.PhotoPrivacyChangedEvent=void 0;const t=Ne(),r=dr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CAMERA},subType:{type:"string",const:r.Events.SubType.Camera.PHOTO_PRIVACY_CHANGED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{userAddress:{type:"string"},photoId:{type:"string"},isPublic:{type:"boolean"}},required:["userAddress","photoId","isPublic"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.PhotoPrivacyChangedEvent||(e.PhotoPrivacyChangedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.CAMERA},subType:{type:"string",const:r.Events.SubType.Camera.PHOTO_TAKEN},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{sceneId:{type:"string"},userAddress:{type:"string"},realm:{type:"string"},photoId:{type:"string"},isPublic:{type:"boolean"},users:{type:"array",items:{type:"object",properties:{address:{type:"string"},isEmoting:{type:"boolean"}},required:["address","isEmoting"],additionalProperties:!1}},placeId:{type:"string",nullable:!0}},required:["userAddress","realm","photoId","isPublic","users"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.PhotoTakenEvent||(e.PhotoTakenEvent={}))})(Im)),Im}var Rm={},E1;function p2(){return E1||(E1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.EventEndedEvent=e.EventCreatedEvent=e.EventStartsSoonEvent=e.EventStartedEvent=void 0;const t=Ne(),r=dr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_STARTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string"},image:{type:"string"},link:{type:"string"},communityId:{type:"string"},communityThumbnail:{type:"string",nullable:!0},title:{type:"string"},description:{type:"string"},attendee:{type:"string"}},required:["name","image","link"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventStartedEvent||(e.EventStartedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_STARTS_SOON},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string"},image:{type:"string"},link:{type:"string"},startsAt:{type:"string"},endsAt:{type:"string"},title:{type:"string"},description:{type:"string"},attendee:{type:"string"}},required:["name","image","link","startsAt","endsAt"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventStartsSoonEvent||(e.EventStartsSoonEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string"},image:{type:"string"},communityId:{type:"string"},communityName:{type:"string"},communityThumbnail:{type:"string",nullable:!0},title:{type:"string"},description:{type:"string"},attendee:{type:"string"}},required:["name","image"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventCreatedEvent||(e.EventCreatedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.EVENT},subType:{type:"string",const:r.Events.SubType.Event.EVENT_ENDED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{communityId:{type:"string",nullable:!0},totalAttendees:{type:"number"}},required:["totalAttendees"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.EventEndedEvent||(e.EventEndedEvent={}))})(Rm)),Rm}var Am={},v1;function m2(){return v1||(v1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.GovernanceCliffEndedEvent=e.GovernanceVotedOnBehalfEvent=e.GovernanceWhaleVoteEvent=e.GovernanceNewCommentOnProjectUpdatedEvent=e.GovernanceNewCommentOnProposalEvent=e.GovernanceVotingEndedVoterEvent=e.GovernanceAuthoredProposalFinishedEvent=e.GovernanceTenderPassedEvent=e.GovernancePitchPassedEvent=e.GovernanceCoauthorRequestedEvent=e.GovernanceProposalEnactedEvent=void 0;const t=Ne(),r=dr(),n=Il(),i={type:"object",properties:{proposalId:{type:"string"},proposalTitle:{type:"string"},title:{type:"string"},description:{type:"string"},link:{type:"string"},address:{type:"string"}},required:["proposalId","proposalTitle","title","description","link","address"],additionalProperties:!1};(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.PROPOSAL_ENACTED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceProposalEnactedEvent||(e.GovernanceProposalEnactedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.COAUTHOR_REQUESTED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceCoauthorRequestedEvent||(e.GovernanceCoauthorRequestedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.PITCH_PASSED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernancePitchPassedEvent||(e.GovernancePitchPassedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.TENDER_PASSED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceTenderPassedEvent||(e.GovernanceTenderPassedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.AUTHORED_PROPOSAL_FINISHED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceAuthoredProposalFinishedEvent||(e.GovernanceAuthoredProposalFinishedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.VOTING_ENDED_VOTER,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceVotingEndedVoterEvent||(e.GovernanceVotingEndedVoterEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.NEW_COMMENT_ON_PROPOSAL,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceNewCommentOnProposalEvent||(e.GovernanceNewCommentOnProposalEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.NEW_COMMENT_ON_PROJECT_UPDATED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceNewCommentOnProjectUpdatedEvent||(e.GovernanceNewCommentOnProjectUpdatedEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.WHALE_VOTE,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceWhaleVoteEvent||(e.GovernanceWhaleVoteEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.VOTED_ON_BEHALF,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceVotedOnBehalfEvent||(e.GovernanceVotedOnBehalfEvent={})),(function(a){a.schema=(0,n.createEventSchema)(r.Events.Type.GOVERNANCE,r.Events.SubType.Governance.CLIFF_ENDED,i),a.validate=(0,t.generateLazyValidator)(a.schema)})(e.GovernanceCliffEndedEvent||(e.GovernanceCliffEndedEvent={}))})(Am)),Am}var wm={},b1;function h2(){return b1||(b1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WorldsMissingResourcesEvent=e.WorldsAccessRestrictedEvent=e.WorldsPermissionGrantedEvent=e.WorldsPermissionRevokedEvent=e.WorldsAccessRestoredEvent=e.WorldDeploymentEvent=e.WorldUndeploymentEvent=e.WorldScenesUndeploymentEvent=e.WorldSpawnCoordinateSetEvent=e.WorldSettingsChangedEvent=void 0;const t=Po(),r=Ne(),n=dr();(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_SETTINGS_CHANGED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{worldName:{type:"string"},title:{type:"string",nullable:!0},description:{type:"string",nullable:!0},contentRating:{type:"string",nullable:!0},skyboxTime:{type:"number",nullable:!0},categories:{type:"array",items:{type:"string"},nullable:!0},singlePlayer:{type:"boolean",nullable:!0},showInPlaces:{type:"boolean",nullable:!0},thumbnailUrl:{type:"string",nullable:!0},accessType:{type:"string",nullable:!0}},required:["worldName"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1}})(e.WorldSettingsChangedEvent||(e.WorldSettingsChangedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_SPAWN_COORDINATE_SET},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{name:{type:"string",pattern:"^[a-zA-Z0-9_-]+\\.dcl\\.eth|[a-zA-Z0-9_-]+\\.eth$"},oldCoordinate:{type:"object",properties:{x:{type:"number"},y:{type:"number"}},required:["x","y"],additionalProperties:!1,nullable:!0},newCoordinate:{type:"object",properties:{x:{type:"number"},y:{type:"number"}},required:["x","y"],additionalProperties:!1}},required:["name","oldCoordinate","newCoordinate"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldSpawnCoordinateSetEvent||(e.WorldSpawnCoordinateSetEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_SCENES_UNDEPLOYMENT},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{worldName:{type:"string"},scenes:{type:"array",items:{type:"object",properties:{entityId:{type:"string"},baseParcel:{type:"string"}},required:["entityId","baseParcel"],additionalProperties:!1},minItems:1}},required:["worldName","scenes"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldScenesUndeploymentEvent||(e.WorldScenesUndeploymentEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLD_UNDEPLOYMENT},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{worldName:{type:"string"}},required:["worldName"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldUndeploymentEvent||(e.WorldUndeploymentEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.DEPLOYMENT},key:{type:"string"},timestamp:{type:"number",minimum:0},entity:{type:"object",properties:{entityId:{type:"string"},authChain:t.AuthChain.schema},additionalProperties:!0,required:["entityId","authChain"]},contentServerUrls:{type:"array",items:{type:"string"},nullable:!0},force:{type:"boolean",nullable:!0},animation:{type:"string",nullable:!0},lods:{type:"array",items:{type:"string"},nullable:!0}},required:["type","subType","key","timestamp","entity"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldDeploymentEvent||(e.WorldDeploymentEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_ACCESS_RESTORED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},url:{type:"string"},attendee:{type:"string"}},required:["title","description","url","attendee"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsAccessRestoredEvent||(e.WorldsAccessRestoredEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_PERMISSION_REVOKED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},world:{type:"string"},permissions:{type:"array",items:{type:"string"}},url:{type:"string"},address:{type:"string"}},required:["title","description","world","permissions","url","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsPermissionRevokedEvent||(e.WorldsPermissionRevokedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_PERMISSION_GRANTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},world:{type:"string"},permissions:{type:"array",items:{type:"string"}},url:{type:"string"},address:{type:"string"}},required:["title","description","world","permissions","url","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsPermissionGrantedEvent||(e.WorldsPermissionGrantedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_ACCESS_RESTRICTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},when:{type:"number"},address:{type:"string"}},required:["title","description","when","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsAccessRestrictedEvent||(e.WorldsAccessRestrictedEvent={})),(function(i){i.schema={type:"object",properties:{type:{type:"string",const:n.Events.Type.WORLD},subType:{type:"string",const:n.Events.SubType.Worlds.WORLDS_MISSING_RESOURCES},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{title:{type:"string"},description:{type:"string"},url:{type:"string"},when:{type:"number"},address:{type:"string"}},required:["title","description","url","when","address"],additionalProperties:!1}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},i.validate=(0,r.generateLazyValidator)(i.schema)})(e.WorldsMissingResourcesEvent||(e.WorldsMissingResourcesEvent={}))})(wm)),wm}var Om={},T1;function y2(){return T1||(T1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.UserWarningCreatedEvent=e.UserBanLiftedEvent=e.UserBanCreatedEvent=void 0;const t=Ne(),r=dr();(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MODERATION},subType:{type:"string",const:r.Events.SubType.Moderation.USER_BAN_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{id:{type:"string"},bannedAddress:{type:"string"},bannedBy:{type:"string"},reason:{type:"string"},bannedAt:{type:"number",minimum:0},expiresAt:{type:"number",nullable:!0,minimum:0},customMessage:{type:"string",nullable:!0}},required:["id","bannedAddress","bannedBy","reason","bannedAt","expiresAt"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.UserBanCreatedEvent||(e.UserBanCreatedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MODERATION},subType:{type:"string",const:r.Events.SubType.Moderation.USER_BAN_LIFTED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{id:{type:"string"},bannedAddress:{type:"string"},liftedBy:{type:"string"},liftedAt:{type:"number",minimum:0}},required:["id","bannedAddress","liftedBy","liftedAt"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.UserBanLiftedEvent||(e.UserBanLiftedEvent={})),(function(n){n.schema={type:"object",properties:{type:{type:"string",const:r.Events.Type.MODERATION},subType:{type:"string",const:r.Events.SubType.Moderation.USER_WARNING_CREATED},key:{type:"string"},timestamp:{type:"number",minimum:0},metadata:{type:"object",properties:{id:{type:"string"},warnedAddress:{type:"string"},warnedBy:{type:"string"},reason:{type:"string"},warnedAt:{type:"number",minimum:0}},required:["id","warnedAddress","warnedBy","reason","warnedAt"]}},required:["type","subType","key","timestamp","metadata"],additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.UserWarningCreatedEvent||(e.UserWarningCreatedEvent={}))})(Om)),Om}var S1;function g2(){return S1||(S1=1,(function(e){var t=Ri&&Ri.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Ri&&Ri.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(dr(),e),r(t2(),e),r(r2(),e),r(n2(),e),r(i2(),e),r(a2(),e),r(s2(),e),r(o2(),e),r(u2(),e),r(c2(),e),r(l2(),e),r(d2(),e),r(f2(),e),r(p2(),e),r(m2(),e),r(h2(),e),r(y2(),e)})(Ri)),Ri}var I1;function s_(){return I1||(I1=1,(function(e){var t=Ei&&Ei.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Ei&&Ei.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(BF(),e),r(FF(),e),r(uP(),e),r(r_(),e),r(rP(),e),r(JF(),e),r(lP(),e),r(XF(),e),r(ZF(),e),r(e2(),e),r(g2(),e)})(Ei)),Ei}var R1;function _2(){return R1||(R1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.WearableJson=void 0;const t=Sl(),r=aa(),n=t_(),i=Ne(),a=s_();(function(s){s.schema={type:"object",properties:{description:{type:"string"},rarity:Object.assign(Object.assign({},t.Rarity.schema),{nullable:!0}),name:{type:"string"},data:{type:"object",properties:{replaces:{type:"array",items:r.WearableCategory.schema},hides:{type:"array",items:r.WearableCategory.schema},tags:{type:"array",items:{type:"string",minLength:1}},representations:{type:"array",items:n.WearableRepresentation.schema,minItems:1},category:r.WearableCategory.schema,removesDefaultHiding:{type:"array",nullable:!0,items:a.HideableWearableCategory.schema},blockVrmExport:{type:"boolean",nullable:!0},outlineCompatible:{type:"boolean",nullable:!0}},required:["replaces","hides","tags","representations","category"]}},additionalProperties:!0,required:["description","name","data"]},s.validate=(0,i.generateLazyValidator)(s.schema)})(e.WearableJson||(e.WearableJson={}))})(Tp)),Tp}var A1;function E2(){return A1||(A1=1,(function(e){var t=_i&&_i.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=_i&&_i.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(qF(),e),r(_2(),e)})(_i)),_i}var w1;function v2(){return w1||(w1=1,(function(e){var t=yi&&yi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=yi&&yi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(LF(),e),r(E2(),e)})(yi)),yi}var Ai={},Nm={},O1;function b2(){return O1||(O1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Account=e.AccountSortBy=void 0;const t=Ne();(function(r){r.MOST_SALES="most_sales",r.MOST_PURCHASES="most_purchases",r.MOST_SPENT="most_spent",r.MOST_EARNED="most_earned",r.MOST_ROYALTIES="most_royalties",r.MOST_COLLECTIONS="most_collections"})(e.AccountSortBy||(e.AccountSortBy={})),(function(r){r.schema={type:"object",properties:{id:{type:"string"},address:{type:"string"},sales:{type:"integer"},purchases:{type:"integer"},spent:{type:"string"},earned:{type:"string"},royalties:{type:"string"},collections:{type:"number"}},required:["id","address","sales","purchases","spent","earned","royalties","collections"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Account||(e.Account={}))})(Nm)),Nm}var Pm={},Mm={},N1;function mP(){return N1||(N1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getChainId=e.ChainName=void 0;const t=Ne(),r=Gr();var n;(function(a){a.ETHEREUM_MAINNET="Ethereum Mainnet",a.ETHEREUM_ROPSTEN="Ropsten",a.ETHEREUM_RINKEBY="Rinkeby",a.ETHEREUM_GOERLI="Goerli",a.ETHEREUM_KOVAN="Kovan",a.ETHEREUM_SEPOLIA="Sepolia",a.MATIC_MAINNET="Polygon",a.MATIC_MUMBAI="Mumbai",a.MATIC_AMOY="Amoy",a.AVALANCHE_MAINNET="Avalanche",a.BINANCE_MAINNET="Binance Smart Chain",a.ARBITRUM_MAINNET="Arbitrum",a.OPTIMISM_MAINNET="Optimism",a.FANTOM_MAINNET="Fantom"})(n=e.ChainName||(e.ChainName={}));function i(a){switch(a){case n.ETHEREUM_MAINNET:return r.ChainId.ETHEREUM_MAINNET;case n.ETHEREUM_ROPSTEN:return r.ChainId.ETHEREUM_ROPSTEN;case n.ETHEREUM_RINKEBY:return r.ChainId.ETHEREUM_RINKEBY;case n.ETHEREUM_GOERLI:return r.ChainId.ETHEREUM_GOERLI;case n.ETHEREUM_KOVAN:return r.ChainId.ETHEREUM_KOVAN;case n.ETHEREUM_SEPOLIA:return r.ChainId.ETHEREUM_SEPOLIA;case n.MATIC_MAINNET:return r.ChainId.MATIC_MAINNET;case n.MATIC_MUMBAI:return r.ChainId.MATIC_MUMBAI;case n.MATIC_AMOY:return r.ChainId.MATIC_AMOY;case n.AVALANCHE_MAINNET:return r.ChainId.AVALANCHE_MAINNET;case n.BINANCE_MAINNET:return r.ChainId.BSC_MAINNET;case n.ARBITRUM_MAINNET:return r.ChainId.ARBITRUM_MAINNET;case n.OPTIMISM_MAINNET:return r.ChainId.OPTIMISM_MAINNET;case n.FANTOM_MAINNET:return r.ChainId.FANTOM_MAINNET;default:return null}}e.getChainId=i,(function(a){a.schema={type:"string",enum:Object.values(a)},a.validate=(0,t.generateLazyValidator)(a.schema)})(n=e.ChainName||(e.ChainName={}))})(Mm)),Mm}var Cm={},P1;function Hr(){return P1||(P1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Network=void 0;const t=Ne();(function(r){r.ETHEREUM="ETHEREUM",r.MATIC="MATIC",r.AVALANCHE="AVALANCHE",r.BSC="BINANCE SMART CHAIN",r.OPTIMISM="OPTIMISM",r.ARBITRUM="ARBITRUM",r.FANTOM="FANTOM"})(e.Network||(e.Network={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Network||(e.Network={}))})(Cm)),Cm}var M1;function Gr(){return M1||(M1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.getNetwork=e.getNetworkMapping=e.getURNProtocol=e.getChainName=e.ChainId=void 0;const t=Ne(),r=mP(),n=Hr();var i;(function(l){l[l.ETHEREUM_MAINNET=1]="ETHEREUM_MAINNET",l[l.ETHEREUM_ROPSTEN=3]="ETHEREUM_ROPSTEN",l[l.ETHEREUM_RINKEBY=4]="ETHEREUM_RINKEBY",l[l.ETHEREUM_GOERLI=5]="ETHEREUM_GOERLI",l[l.ETHEREUM_KOVAN=42]="ETHEREUM_KOVAN",l[l.ETHEREUM_SEPOLIA=11155111]="ETHEREUM_SEPOLIA",l[l.MATIC_MAINNET=137]="MATIC_MAINNET",l[l.MATIC_MUMBAI=80001]="MATIC_MUMBAI",l[l.MATIC_AMOY=80002]="MATIC_AMOY",l[l.BSC_MAINNET=56]="BSC_MAINNET",l[l.OPTIMISM_MAINNET=10]="OPTIMISM_MAINNET",l[l.ARBITRUM_MAINNET=42161]="ARBITRUM_MAINNET",l[l.FANTOM_MAINNET=250]="FANTOM_MAINNET",l[l.AVALANCHE_MAINNET=43114]="AVALANCHE_MAINNET"})(i=e.ChainId||(e.ChainId={}));function a(l){switch(l){case i.ETHEREUM_MAINNET:return r.ChainName.ETHEREUM_MAINNET;case i.ETHEREUM_ROPSTEN:return r.ChainName.ETHEREUM_ROPSTEN;case i.ETHEREUM_RINKEBY:return r.ChainName.ETHEREUM_RINKEBY;case i.ETHEREUM_GOERLI:return r.ChainName.ETHEREUM_GOERLI;case i.ETHEREUM_KOVAN:return r.ChainName.ETHEREUM_KOVAN;case i.ETHEREUM_SEPOLIA:return r.ChainName.ETHEREUM_SEPOLIA;case i.MATIC_MAINNET:return r.ChainName.MATIC_MAINNET;case i.MATIC_MUMBAI:return r.ChainName.MATIC_MUMBAI;case i.MATIC_AMOY:return r.ChainName.MATIC_AMOY;case i.BSC_MAINNET:return r.ChainName.BINANCE_MAINNET;case i.ARBITRUM_MAINNET:return r.ChainName.ARBITRUM_MAINNET;case i.OPTIMISM_MAINNET:return r.ChainName.OPTIMISM_MAINNET;case i.FANTOM_MAINNET:return r.ChainName.FANTOM_MAINNET;case i.AVALANCHE_MAINNET:return r.ChainName.AVALANCHE_MAINNET;default:return null}}e.getChainName=a;function s(l){switch(l){case i.ETHEREUM_MAINNET:return"ethereum";case i.ETHEREUM_ROPSTEN:return"ropsten";case i.ETHEREUM_RINKEBY:return"rinkeby";case i.ETHEREUM_GOERLI:return"goerli";case i.ETHEREUM_KOVAN:return"kovan";case i.ETHEREUM_SEPOLIA:return"sepolia";case i.MATIC_MAINNET:return"matic";case i.MATIC_MUMBAI:return"mumbai";case i.MATIC_AMOY:return"amoy";default:return""}}e.getURNProtocol=s;function o(l){const c={[n.Network.BSC]:i.BSC_MAINNET,[n.Network.OPTIMISM]:i.OPTIMISM_MAINNET,[n.Network.ARBITRUM]:i.ARBITRUM_MAINNET,[n.Network.FANTOM]:i.FANTOM_MAINNET,[n.Network.AVALANCHE]:i.AVALANCHE_MAINNET};switch(l){case i.ETHEREUM_MAINNET:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_MAINNET,[n.Network.MATIC]:i.MATIC_MAINNET},c);case i.ETHEREUM_ROPSTEN:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_ROPSTEN,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_RINKEBY:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_RINKEBY,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_GOERLI:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_GOERLI,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_KOVAN:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_KOVAN,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.ETHEREUM_SEPOLIA:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_SEPOLIA,[n.Network.MATIC]:i.MATIC_AMOY},c);case i.MATIC_MAINNET:return Object.assign({[n.Network.ETHEREUM]:i.MATIC_MAINNET,[n.Network.MATIC]:i.MATIC_MAINNET},c);case i.MATIC_MUMBAI:return Object.assign({[n.Network.ETHEREUM]:i.MATIC_MUMBAI,[n.Network.MATIC]:i.MATIC_MUMBAI},c);case i.MATIC_AMOY:return Object.assign({[n.Network.ETHEREUM]:i.MATIC_AMOY,[n.Network.MATIC]:i.MATIC_AMOY},c);default:return Object.assign({[n.Network.ETHEREUM]:i.ETHEREUM_MAINNET,[n.Network.MATIC]:i.MATIC_MAINNET},c)}}e.getNetworkMapping=o;function u(l){switch(l){case i.ETHEREUM_MAINNET:case i.ETHEREUM_ROPSTEN:case i.ETHEREUM_GOERLI:case i.ETHEREUM_KOVAN:case i.ETHEREUM_RINKEBY:case i.ETHEREUM_SEPOLIA:return n.Network.ETHEREUM;case i.MATIC_MAINNET:case i.MATIC_MUMBAI:case i.MATIC_AMOY:return n.Network.MATIC;case i.BSC_MAINNET:return n.Network.BSC;case i.OPTIMISM_MAINNET:return n.Network.OPTIMISM;case i.ARBITRUM_MAINNET:return n.Network.ARBITRUM;case i.FANTOM_MAINNET:return n.Network.FANTOM;case i.AVALANCHE_MAINNET:return n.Network.AVALANCHE}}e.getNetwork=u,(function(l){l.schema={type:"number",enum:Object.values(l)},l.validate=(0,t.generateLazyValidator)(l.schema)})(i=e.ChainId||(e.ChainId={}))})(Pm)),Pm}var Dm={},C1;function T2(){return C1||(C1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Collection=e.CollectionSortBy=void 0;const t=Ne(),r=Gr(),n=Hr();(function(i){i.NEWEST="newest",i.NAME="name",i.RECENTLY_REVIEWED="recently_reviewed",i.RECENTLY_LISTED="recently_listed",i.SIZE="size"})(e.CollectionSortBy||(e.CollectionSortBy={})),(function(i){i.schema={type:"object",properties:{urn:{type:"string"},creator:{type:"string"},name:{type:"string"},contractAddress:{type:"string"},size:{type:"integer"},isOnSale:{type:"boolean"},createdAt:{type:"integer"},updatedAt:{type:"integer"},reviewedAt:{type:"integer"},network:n.Network.schema,chainId:r.ChainId.schema,firstListedAt:{type:"integer",nullable:!0}},required:["urn","creator","name","contractAddress","isOnSale","size","createdAt","updatedAt","reviewedAt","network","chainId"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.Collection||(e.Collection={}))})(Dm)),Dm}var jm={},$m={},D1;function Rl(){return D1||(D1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.NFTCategory=void 0;const t=Ne();(function(r){r.PARCEL="parcel",r.ESTATE="estate",r.WEARABLE="wearable",r.ENS="ens",r.EMOTE="emote"})(e.NFTCategory||(e.NFTCategory={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.NFTCategory||(e.NFTCategory={}))})($m)),$m}var j1;function S2(){return j1||(j1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Contract=e.ContractSortBy=void 0;const t=Ne(),r=Gr(),n=Hr(),i=Rl();(function(a){a.NAME="name"})(e.ContractSortBy||(e.ContractSortBy={})),(function(a){a.schema={type:"object",properties:{name:{type:"string"},address:{type:"string"},category:i.NFTCategory.schema,network:n.Network.schema,chainId:r.ChainId.schema},required:["name","address","category","network","chainId"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Contract||(e.Contract={}))})(jm)),jm}var Lm={},qm={},$1;function hP(){return $1||($1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.NFT=e.NFTSortBy=void 0;const t=Ne(),r=Gr(),n=s_(),i=Hr(),a=Rl(),s=Sl(),o=aa();(function(u){u.NAME="name",u.NEWEST="newest",u.RECENTLY_LISTED="recently_listed",u.RECENTLY_SOLD="recently_sold",u.CHEAPEST="cheapest",u.RENTAL_LISTING_DATE="rental_listing_date",u.RENTAL_DATE="rented_date",u.MAX_RENTAL_PRICE="max_rental_price",u.MIN_RENTAL_PRICE="min_rental_price"})(e.NFTSortBy||(e.NFTSortBy={})),(function(u){u.schema={type:"object",properties:{id:{type:"string"},tokenId:{type:"string"},contractAddress:{type:"string"},activeOrderId:{type:"string",nullable:!0},utility:{type:"string",nullable:!0},openRentalId:{type:"string",nullable:!0},owner:{type:"string"},name:{type:"string"},image:{type:"string"},url:{type:"string"},data:{type:"object",nullable:!1,properties:{parcel:{type:"object",properties:{description:{type:["string"],nullable:!0},x:{type:"string"},y:{type:"string"},estate:{type:"object",properties:{tokenId:{type:"string"},name:{type:"string"}},required:["tokenId","name"],nullable:!0}},required:["description","x","y","estate"],nullable:!0},estate:{type:"object",properties:{description:{type:["string"],nullable:!0},size:{type:"integer"},parcels:{type:"array",items:{type:"object",properties:{x:{type:"number"},y:{type:"number"}},required:["x","y"]}}},required:["description","size","parcels"],nullable:!0},wearable:{type:"object",properties:{bodyShapes:{type:"array",items:n.BodyShape.schema},category:o.WearableCategory.schema,description:{type:"string"},rarity:s.Rarity.schema,isSmart:{type:"boolean"}},required:["bodyShapes","category","description","rarity","isSmart"],nullable:!0},ens:{type:"object",properties:{subdomain:{type:"string"}},required:["subdomain"],nullable:!0},emote:{type:"object",properties:{bodyShapes:{type:"array",items:n.BodyShape.schema},category:n.EmoteCategory.schema,description:{type:"string"},rarity:s.Rarity.schema,loop:{type:"boolean"},hasSound:{type:"boolean"},hasGeometry:{type:"boolean"},outcomeType:{type:"string",nullable:!0}},required:["bodyShapes","category","description","rarity","loop"],nullable:!0}},required:[]},issuedId:{type:"string",nullable:!0},itemId:{type:"string",nullable:!0},category:a.NFTCategory.schema,network:i.Network.schema,chainId:r.ChainId.schema,createdAt:{type:"integer"},updatedAt:{type:"integer"},soldAt:{type:"integer"},urn:{type:"string",nullable:!0}},required:["id","tokenId","contractAddress","activeOrderId","openRentalId","owner","name","image","url","data","issuedId","itemId","category","network","chainId","createdAt","updatedAt","soldAt"]},u.validate=(0,t.generateLazyValidator)(u.schema)})(e.NFT||(e.NFT={}))})(qm)),qm}var L1;function I2(){return L1||(L1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Item=e.ItemSortBy=void 0;const t=Ne(),r=Gr(),n=Hr(),i=hP(),a=Rl();(function(s){s.NAME="name",s.NEWEST="newest",s.RECENTLY_REVIEWED="recently_reviewed",s.RECENTLY_SOLD="recently_sold",s.RECENTLY_LISTED="recently_listed",s.CHEAPEST="cheapest"})(e.ItemSortBy||(e.ItemSortBy={})),(function(s){s.schema={type:"object",properties:{id:{type:"string"},name:{type:"string"},thumbnail:{type:"string"},url:{type:"string"},category:a.NFTCategory.schema,contractAddress:{type:"string"},itemId:{type:"string"},rarity:{type:"string"},price:{type:"string"},available:{type:"integer"},isOnSale:{type:"boolean"},creator:{type:"string"},beneficiary:{type:"string",nullable:!0},tradeId:{type:"string",nullable:!0},tradeContractAddress:{type:"string",nullable:!0},data:i.NFT.schema.properties.data,network:n.Network.schema,chainId:r.ChainId.schema,urn:{type:"string"},createdAt:{type:"integer"},updatedAt:{type:"integer"},reviewedAt:{type:"integer"},soldAt:{type:"integer"},firstListedAt:{type:"integer",nullable:!0},picks:{type:"object",properties:{pickedByUser:{type:"boolean",nullable:!0},count:{type:"integer"}},required:["count"],nullable:!0},minPrice:{type:"string",nullable:!0},utility:{type:"string",nullable:!0},minListingPrice:{type:"string",nullable:!0},maxListingPrice:{type:"string",nullable:!0},listings:{type:"integer",nullable:!0},owners:{type:"integer",nullable:!0},tradeExpiresAt:{type:"integer",nullable:!0}},required:["id","name","thumbnail","url","category","contractAddress","itemId","rarity","price","available","isOnSale","creator","data","network","chainId","createdAt","updatedAt","soldAt"]},s.validate=(0,t.generateLazyValidator)(s.schema)})(e.Item||(e.Item={}))})(Lm)),Lm}var km={},q1;function o_(){return q1||(q1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ListingStatus=void 0;const t=Ne();(function(r){r.OPEN="open",r.SOLD="sold",r.CANCELLED="cancelled"})(e.ListingStatus||(e.ListingStatus={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.ListingStatus||(e.ListingStatus={}))})(km)),km}var Bm={},k1;function R2(){return k1||(k1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.MetaTransaction=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{from:{type:"string"},params:{type:"array",items:[{type:"string"},{type:"string"}],additionalItems:!1,minItems:2}},additionalProperties:!1,required:["from","params"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.MetaTransaction||(e.MetaTransaction={}))})(Bm)),Bm}var Um={},B1;function A2(){return B1||(B1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Mint=e.MintSortBy=void 0;const t=Ne(),r=Gr(),n=Hr();(function(i){i.RECENTLY_MINTED="recently_minted",i.MOST_EXPENSIVE="most_expensive"})(e.MintSortBy||(e.MintSortBy={})),(function(i){i.schema={type:"object",properties:{id:{type:"string"},creator:{type:"string"},beneficiary:{type:"string"},minter:{type:"string"},price:{type:"string",nullable:!0},contractAddress:{type:"string"},tokenId:{type:"string"},itemId:{type:"string"},issuedId:{type:"string"},timestamp:{type:"integer"},network:n.Network.schema,chainId:r.ChainId.schema},required:["id","creator","beneficiary","minter","itemId","tokenId","issuedId","contractAddress","price","timestamp","network","chainId"]},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.Mint||(e.Mint={}))})(Um)),Um}var Fm={},U1;function w2(){return U1||(U1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.CatalogSortDirection=e.CatalogSortBy=void 0,(function(t){t.NEWEST="newest",t.RECENTLY_SOLD="recently_sold",t.CHEAPEST="cheapest",t.MOST_EXPENSIVE="most_expensive",t.RECENTLY_LISTED="recently_listed"})(e.CatalogSortBy||(e.CatalogSortBy={})),(function(t){t.ASC="asc",t.DESC="desc"})(e.CatalogSortDirection||(e.CatalogSortDirection={}))})(Fm)),Fm}var Vm={},F1;function O2(){return F1||(F1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Order=e.OrderSortBy=void 0;const t=Ne(),r=Gr(),n=o_(),i=Hr();(function(a){a.RECENTLY_LISTED="recently_listed",a.RECENTLY_UPDATED="recently_updated",a.CHEAPEST="cheapest",a.ISSUED_ID_ASC="issued_id_asc",a.ISSUED_ID_DESC="issued_id_desc",a.OLDEST="oldest"})(e.OrderSortBy||(e.OrderSortBy={})),(function(a){a.schema={type:"object",properties:{id:{type:"string"},marketplaceAddress:{type:"string"},contractAddress:{type:"string"},tokenId:{type:"string"},owner:{type:"string"},buyer:{type:["string"],nullable:!0},price:{type:"string"},status:n.ListingStatus.schema,network:i.Network.schema,chainId:r.ChainId.schema,expiresAt:{type:"integer"},createdAt:{type:"integer"},updatedAt:{type:"integer"},issuedId:{type:"string"},tradeId:{type:"string",nullable:!0}},required:["id","marketplaceAddress","contractAddress","tokenId","owner","buyer","price","status","network","chainId","expiresAt","createdAt","updatedAt"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Order||(e.Order={}))})(Vm)),Vm}var Hm={},V1;function N2(){return V1||(V1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.ProviderType=void 0;const t=Ne();(function(r){r.INJECTED="injected",r.MAGIC="magic",r.MAGIC_TEST="magic_test",r.FORTMATIC="formatic",r.NETWORK="network",r.WALLET_CONNECT="wallet_connect",r.WALLET_CONNECT_V2="wallet_connect_v2",r.WALLET_LINK="wallet_link",r.METAMASK_MOBILE="metamask_mobile",r.AUTH_SERVER="auth_server",r.THIRDWEB="thirdweb"})(e.ProviderType||(e.ProviderType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.ProviderType||(e.ProviderType={}))})(Hm)),Hm}var Gm={},H1;function yP(){return H1||(H1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SaleType=void 0;const t=Ne();(function(r){r.ORDER="order",r.BID="bid",r.MINT="mint"})(e.SaleType||(e.SaleType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.SaleType||(e.SaleType={}))})(Gm)),Gm}var zm={},G1;function P2(){return G1||(G1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Sale=e.SaleSortBy=void 0;const t=Ne(),r=Gr(),n=yP(),i=Hr();(function(a){a.RECENTLY_SOLD="recently_sold",a.MOST_EXPENSIVE="most_expensive"})(e.SaleSortBy||(e.SaleSortBy={})),(function(a){a.schema={type:"object",properties:{id:{type:"string"},type:n.SaleType.schema,buyer:{type:"string"},seller:{type:"string"},price:{type:"string"},contractAddress:{type:"string"},tokenId:{type:"string"},itemId:{type:"string"},txHash:{type:"string"},timestamp:{type:"integer"},network:i.Network.schema,chainId:r.ChainId.schema},required:["id","buyer","seller","itemId","tokenId","price","contractAddress","timestamp","txHash","network","chainId"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Sale||(e.Sale={}))})(zm)),zm}var Wm={},z1;function M2(){return z1||(z1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.RentalListingCreation=e.PeriodCreation=e.RentalsListingsSortBy=e.RentalsListingsFilterByCategory=e.RentalsListingSortDirection=e.RentalStatus=void 0;const t=Ne(),r=Gr(),n=Hr();(function(a){a.OPEN="open",a.CANCELLED="cancelled",a.EXECUTED="executed",a.CLAIMED="claimed"})(e.RentalStatus||(e.RentalStatus={})),(function(a){a.ASC="asc",a.DESC="desc"})(e.RentalsListingSortDirection||(e.RentalsListingSortDirection={})),(function(a){a.PARCEL="parcel",a.ESTATE="estate"})(e.RentalsListingsFilterByCategory||(e.RentalsListingsFilterByCategory={})),(function(a){a.LAND_CREATION_DATE="land_creation_date",a.RENTAL_LISTING_DATE="rental_listing_date",a.RENTAL_DATE="rented_date",a.NAME="name",a.MAX_RENTAL_PRICE="max_rental_price",a.MIN_RENTAL_PRICE="min_rental_price"})(e.RentalsListingsSortBy||(e.RentalsListingsSortBy={}));var i;(function(a){a.schema={type:"object",properties:{minDays:{type:"integer",minimum:0,maximum:2147483647},maxDays:{type:"integer",minimum:0,maximum:2147483647},pricePerDay:{type:"string",pattern:"^[0-9]+$"}},additionalProperties:!1,required:["minDays","maxDays","pricePerDay"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(i=e.PeriodCreation||(e.PeriodCreation={})),(function(a){a.schema={type:"object",properties:{network:n.Network.schema,chainId:r.ChainId.schema,expiration:{type:"number",minimum:0},signature:{type:"string",minLength:1},tokenId:{type:"string",minLength:1},nonces:{type:"array",minItems:3,maxItems:3,items:{minLength:1,type:"string",pattern:"^[0-9]+$"}},contractAddress:{type:"string",pattern:"^0x[a-fA-F0-9]{40}$"},rentalContractAddress:{type:"string",pattern:"^0x[a-fA-F0-9]{40}$"},periods:{type:"array",minItems:1,maxItems:100,uniqueItems:!0,items:i.schema},target:{type:"string",pattern:"^0x[a-fA-F0-9]{40}$"}},additionalProperties:!1,required:["network","chainId","expiration","signature","nonces","tokenId","contractAddress","rentalContractAddress","periods","target"]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.RentalListingCreation||(e.RentalListingCreation={}))})(Wm)),Wm}var Ym={},W1;function C2(){return W1||(W1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.AnalyticsDayDataSortBy=void 0,(function(t){t.DATE="date",t.MOST_SALES="most_sales"})(e.AnalyticsDayDataSortBy||(e.AnalyticsDayDataSortBy={}))})(Ym)),Ym}var Km={},Y1;function D2(){return Y1||(Y1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Store=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{id:{type:"string"},version:{type:"number"},owner:{type:"string"},description:{type:"string"},links:{type:"array",items:{type:"object",properties:{name:{type:"string"},url:{type:"string"}},required:["name","url"]}},images:{type:"array",items:{type:"object",properties:{name:{type:"string"},file:{type:"string"}},required:["name","file"]}}},required:["id","version","owner","description","links","images"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.Store||(e.Store={}))})(Km)),Km}var Jm={},K1;function j2(){return K1||(K1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.GenderFilterOption=e.WearableGender=void 0;const t=Ne();(function(r){r.MALE="male",r.FEMALE="female"})(e.WearableGender||(e.WearableGender={})),(function(r){r.MALE="male",r.FEMALE="female",r.UNISEX="unisex"})(e.GenderFilterOption||(e.GenderFilterOption={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.WearableGender||(e.WearableGender={}))})(Jm)),Jm}var Xm={},J1;function $2(){return J1||(J1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.World=e.isInsideWorldLimits=e.getWorld=void 0;const t=Ne();function r(){return{validWorldRanges:[{xMin:-150,yMin:-150,xMax:150,yMax:150},{xMin:62,yMin:151,xMax:162,yMax:158},{xMin:151,yMin:144,xMax:162,yMax:150},{xMin:151,yMin:59,xMax:163,yMax:143}]}}e.getWorld=r;function n(i,a){const s=r().validWorldRanges;for(const o of s)if(i>=o.xMin&&i<=o.xMax&&a>=o.yMin&&a<=o.yMax)return!0;return!1}e.isInsideWorldLimits=n,(function(i){i.schema={type:"object",required:["validWorldRanges"],properties:{validWorldRanges:{type:"array",default:[{xMin:-150,yMin:-150,xMax:150,yMax:150}],items:{type:"object",required:["xMin","yMin","xMax","yMax"],properties:{xMin:{type:"integer"},yMin:{type:"integer"},xMax:{type:"integer"},yMax:{type:"integer"}}}}},additionalProperties:!1},i.validate=(0,t.generateLazyValidator)(i.schema)})(e.World||(e.World={}))})(Xm)),Xm}var Qm={},X1;function L2(){return X1||(X1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Bid=e.BidSortBy=void 0;const t=Ne(),r=Gr(),n=o_(),i=Hr();(function(a){a.RECENTLY_OFFERED="recently_offered",a.RECENTLY_UPDATED="recently_updated",a.MOST_EXPENSIVE="most_expensive"})(e.BidSortBy||(e.BidSortBy={})),(function(a){const s={properties:{id:{type:"string"},bidder:{type:"string"},seller:{type:"string"},price:{type:"string"},fingerprint:{type:"string"},status:n.ListingStatus.schema,contractAddress:{type:"string"},network:i.Network.schema,chainId:r.ChainId.schema,expiresAt:{type:"integer"},createdAt:{type:"integer"},updatedAt:{type:"integer"}},required:["id","bidder","seller","price","fingerprint","status","contractAddress","network","chainId","expiresAt","createdAt","updatedAt"]};a.schema={type:"object",required:[],oneOf:[{properties:Object.assign(Object.assign({},s.properties),{tradeId:{type:"string"},tokenId:{type:"string"}}),required:[...s.required,"tradeId","tokenId"]},{type:"object",properties:Object.assign(Object.assign({},s.properties),{tradeId:{type:"string"},itemId:{type:"string"}}),required:[...s.required,"tradeId","itemId"]},{type:"object",properties:Object.assign(Object.assign({},s.properties),{bidAddress:{type:"string"},blockchainId:{type:"string"},blockNumber:{type:"string"},tokenId:{type:"string"}}),required:[...s.required,"bidAddress","blockchainId","blockNumber","tokenId"]}]},a.validate=(0,t.generateLazyValidator)(a.schema)})(e.Bid||(e.Bid={}))})(Qm)),Qm}var Zm={},Q1;function q2(){return Q1||(Q1=1,Object.defineProperty(Zm,"__esModule",{value:!0})),Zm}var xm={},Z1;function k2(){return Z1||(Z1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.TradeAssetDirection=e.TradeAssetType=e.TradeType=void 0,(function(t){t.BID="bid",t.PUBLIC_NFT_ORDER="public_nft_order",t.PUBLIC_ITEM_ORDER="public_item_order"})(e.TradeType||(e.TradeType={})),(function(t){t[t.ERC20=1]="ERC20",t[t.USD_PEGGED_MANA=2]="USD_PEGGED_MANA",t[t.ERC721=3]="ERC721",t[t.COLLECTION_ITEM=4]="COLLECTION_ITEM"})(e.TradeAssetType||(e.TradeAssetType={})),(function(t){t.SENT="sent",t.RECEIVED="received"})(e.TradeAssetDirection||(e.TradeAssetDirection={}))})(xm)),xm}var wi={},eh={},x1;function B2(){return x1||(x1=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewCamera=void 0;const t=Ne();(function(r){r.STATIC="static",r.INTERACTIVE="interactive"})(e.PreviewCamera||(e.PreviewCamera={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewCamera||(e.PreviewCamera={}))})(eh)),eh}var th={},eR;function U2(){return eR||(eR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewUnityMode=void 0,(function(t){t.AUTH="authentication",t.BUILDER="builder",t.MARKETPLACE="marketplace",t.PROFILE="profile",t.CONFIG="configurator",t.JESUS="jesus"})(e.PreviewUnityMode||(e.PreviewUnityMode={}))})(th)),th}var rh={},tR;function F2(){return tR||(tR=1,Object.defineProperty(rh,"__esModule",{value:!0})),rh}var nh={},rR;function V2(){return rR||(rR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewEmoteEventType=void 0;const t=Ne();(function(r){r.ANIMATION_PLAY="animation_play",r.ANIMATION_PAUSE="animation_pause",r.ANIMATION_LOOP="animation_loop",r.ANIMATION_END="animation_end",r.ANIMATION_PLAYING="animation_playing"})(e.PreviewEmoteEventType||(e.PreviewEmoteEventType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewEmoteEventType||(e.PreviewEmoteEventType={}))})(nh)),nh}var ih={},nR;function H2(){return nR||(nR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewEmote=void 0;const t=Ne();(function(r){r.IDLE="idle",r.WALK="walk",r.RUN="run",r.JUMP="jump",r.CLAP="clap",r.DAB="dab",r.DANCE="dance",r.FASHION="fashion",r.FASHION_2="fashion-2",r.FASHION_3="fashion-3",r.FASHION_4="fashion-4",r.LOVE="love",r.MONEY="money",r.FIST_PUMP="fist-pump",r.HEAD_EXPLODE="head-explode",r.WAVE="wave"})(e.PreviewEmote||(e.PreviewEmote={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewEmote||(e.PreviewEmote={}))})(ih)),ih}var ah={},iR;function G2(){return iR||(iR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.sendMessage=e.PreviewRenderer=e.PreviewMessageType=void 0;const t=Ne();(function(n){n.READY="ready",n.LOAD="load",n.ERROR="error",n.UPDATE="update",n.CONTROLLER_REQUEST="controller_request",n.CONTROLLER_RESPONSE="controller_response",n.EMOTE_EVENT="emote_event"})(e.PreviewMessageType||(e.PreviewMessageType={})),(function(n){n.BABYLON="babylon",n.UNITY="unity"})(e.PreviewRenderer||(e.PreviewRenderer={})),(function(n){n.schema={type:"string",enum:Object.values(n)},n.validate=(0,t.generateLazyValidator)(n.schema)})(e.PreviewMessageType||(e.PreviewMessageType={}));const r=(n,i,a,s="*")=>{const o={type:i,payload:a};n.postMessage(o,s)};e.sendMessage=r})(ah)),ah}var sh={},aR;function z2(){return aR||(aR=1,Object.defineProperty(sh,"__esModule",{value:!0})),sh}var oh={},sR;function W2(){return sR||(sR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewProjection=void 0;const t=Ne();(function(r){r.ORTHOGRAPHIC="orthographic",r.PERSPECTIVE="perspective"})(e.PreviewProjection||(e.PreviewProjection={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewProjection||(e.PreviewProjection={}))})(oh)),oh}var uh={},oR;function Y2(){return oR||(oR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.PreviewType=void 0;const t=Ne();(function(r){r.TEXTURE="texture",r.WEARABLE="wearable",r.AVATAR="avatar"})(e.PreviewType||(e.PreviewType={})),(function(r){r.schema={type:"string",enum:Object.values(r)},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.PreviewType||(e.PreviewType={}))})(uh)),uh}var ch={},uR;function K2(){return uR||(uR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.SpringBoneParams=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{stiffness:{type:"number",minimum:0,maximum:5},gravityPower:{type:"number",minimum:0,maximum:10},gravityDir:{type:"array",items:[{type:"number"},{type:"number"},{type:"number"}],minItems:3,maxItems:3},dragForce:{type:"number",minimum:0,maximum:1},center:{type:"integer",minimum:0,nullable:!0}},required:["stiffness","gravityPower","gravityDir","dragForce"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.SpringBoneParams||(e.SpringBoneParams={}))})(ch)),ch}var lh={},cR;function J2(){return cR||(cR=1,Object.defineProperty(lh,"__esModule",{value:!0})),lh}var dh={},lR;function X2(){return lR||(lR=1,Object.defineProperty(dh,"__esModule",{value:!0})),dh}var fh={},dR;function Q2(){return dR||(dR=1,Object.defineProperty(fh,"__esModule",{value:!0})),fh}var ph={},fR;function Z2(){return fR||(fR=1,Object.defineProperty(ph,"__esModule",{value:!0})),ph}var mh={},pR;function x2(){return pR||(pR=1,Object.defineProperty(mh,"__esModule",{value:!0})),mh}var hh={},mR;function eV(){return mR||(mR=1,Object.defineProperty(hh,"__esModule",{value:!0})),hh}var yh={},hR;function tV(){return hR||(hR=1,Object.defineProperty(yh,"__esModule",{value:!0})),yh}var gh={},yR;function rV(){return yR||(yR=1,Object.defineProperty(gh,"__esModule",{value:!0})),gh}var gR;function nV(){return gR||(gR=1,(function(e){var t=wi&&wi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=wi&&wi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(B2(),e),r(U2(),e),r(F2(),e),r(V2(),e),r(H2(),e),r(G2(),e),r(z2(),e),r(W2(),e),r(Y2(),e),r(K2(),e),r(J2(),e),r(X2(),e),r(Q2(),e),r(Z2(),e),r(x2(),e),r(eV(),e),r(tV(),e),r(rV(),e)})(wi)),wi}var Oi={},vs={},_R;function iV(){if(_R)return vs;_R=1,Object.defineProperty(vs,"__esModule",{value:!0}),vs.isSysLink=void 0;const e=t=>t!==null&&typeof t=="object"&&"sys"in t&&"id"in t.sys;return vs.isSysLink=e,vs}var bs={},ER;function aV(){if(ER)return bs;ER=1,Object.defineProperty(bs,"__esModule",{value:!0}),bs.ContentfulLocale=void 0;var e;return(function(t){t.enUS="en-US",t.es="es",t.zh="zh"})(e||(e={})),bs.ContentfulLocale=e,bs}var _h={},vR;function sV(){return vR||(vR=1,Object.defineProperty(_h,"__esModule",{value:!0})),_h}var bR;function oV(){return bR||(bR=1,(function(e){var t=Oi&&Oi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Oi&&Oi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(iV(),e),r(aV(),e),r(sV(),e)})(Oi)),Oi}var TR;function uV(){return TR||(TR=1,(function(e){var t=Ai&&Ai.__createBinding||(Object.create?(function(J,K,z,U){U===void 0&&(U=z);var F=Object.getOwnPropertyDescriptor(K,z);(!F||("get"in F?!K.__esModule:F.writable||F.configurable))&&(F={enumerable:!0,get:function(){return K[z]}}),Object.defineProperty(J,U,F)}):(function(J,K,z,U){U===void 0&&(U=z),J[U]=K[z]})),r=Ai&&Ai.__exportStar||function(J,K){for(var z in J)z!=="default"&&!Object.prototype.hasOwnProperty.call(K,z)&&t(K,J,z)};Object.defineProperty(e,"__esModule",{value:!0}),e.isInsideWorldLimits=e.getWorld=e.World=e.GenderFilterOption=e.WearableGender=e.Store=e.AnalyticsDayDataSortBy=e.PeriodCreation=e.RentalListingCreation=e.RentalsListingsSortBy=e.RentalsListingsFilterByCategory=e.RentalsListingSortDirection=e.RentalStatus=e.SaleSortBy=e.Sale=e.SaleType=e.Rarity=e.ProviderType=e.OrderSortBy=e.Order=e.CatalogSortDirection=e.CatalogSortBy=e.NFTSortBy=e.NFT=e.NFTCategory=e.Network=e.MintSortBy=e.Mint=e.MetaTransaction=e.ListingStatus=e.ItemSortBy=e.Item=e.ContractSortBy=e.Contract=e.CollectionSortBy=e.Collection=e.getChainId=e.ChainName=e.getURNProtocol=e.getChainName=e.ChainId=e.AccountSortBy=e.Account=void 0;var n=b2();Object.defineProperty(e,"Account",{enumerable:!0,get:function(){return n.Account}}),Object.defineProperty(e,"AccountSortBy",{enumerable:!0,get:function(){return n.AccountSortBy}});var i=Gr();Object.defineProperty(e,"ChainId",{enumerable:!0,get:function(){return i.ChainId}}),Object.defineProperty(e,"getChainName",{enumerable:!0,get:function(){return i.getChainName}}),Object.defineProperty(e,"getURNProtocol",{enumerable:!0,get:function(){return i.getURNProtocol}});var a=mP();Object.defineProperty(e,"ChainName",{enumerable:!0,get:function(){return a.ChainName}}),Object.defineProperty(e,"getChainId",{enumerable:!0,get:function(){return a.getChainId}});var s=T2();Object.defineProperty(e,"Collection",{enumerable:!0,get:function(){return s.Collection}}),Object.defineProperty(e,"CollectionSortBy",{enumerable:!0,get:function(){return s.CollectionSortBy}});var o=S2();Object.defineProperty(e,"Contract",{enumerable:!0,get:function(){return o.Contract}}),Object.defineProperty(e,"ContractSortBy",{enumerable:!0,get:function(){return o.ContractSortBy}});var u=I2();Object.defineProperty(e,"Item",{enumerable:!0,get:function(){return u.Item}}),Object.defineProperty(e,"ItemSortBy",{enumerable:!0,get:function(){return u.ItemSortBy}});var l=o_();Object.defineProperty(e,"ListingStatus",{enumerable:!0,get:function(){return l.ListingStatus}});var c=R2();Object.defineProperty(e,"MetaTransaction",{enumerable:!0,get:function(){return c.MetaTransaction}});var d=A2();Object.defineProperty(e,"Mint",{enumerable:!0,get:function(){return d.Mint}}),Object.defineProperty(e,"MintSortBy",{enumerable:!0,get:function(){return d.MintSortBy}});var m=Hr();Object.defineProperty(e,"Network",{enumerable:!0,get:function(){return m.Network}});var p=Rl();Object.defineProperty(e,"NFTCategory",{enumerable:!0,get:function(){return p.NFTCategory}});var E=hP();Object.defineProperty(e,"NFT",{enumerable:!0,get:function(){return E.NFT}}),Object.defineProperty(e,"NFTSortBy",{enumerable:!0,get:function(){return E.NFTSortBy}});var A=w2();Object.defineProperty(e,"CatalogSortBy",{enumerable:!0,get:function(){return A.CatalogSortBy}}),Object.defineProperty(e,"CatalogSortDirection",{enumerable:!0,get:function(){return A.CatalogSortDirection}});var R=O2();Object.defineProperty(e,"Order",{enumerable:!0,get:function(){return R.Order}}),Object.defineProperty(e,"OrderSortBy",{enumerable:!0,get:function(){return R.OrderSortBy}});var O=N2();Object.defineProperty(e,"ProviderType",{enumerable:!0,get:function(){return O.ProviderType}});var f=Sl();Object.defineProperty(e,"Rarity",{enumerable:!0,get:function(){return f.Rarity}});var v=yP();Object.defineProperty(e,"SaleType",{enumerable:!0,get:function(){return v.SaleType}});var b=P2();Object.defineProperty(e,"Sale",{enumerable:!0,get:function(){return b.Sale}}),Object.defineProperty(e,"SaleSortBy",{enumerable:!0,get:function(){return b.SaleSortBy}});var h=M2();Object.defineProperty(e,"RentalStatus",{enumerable:!0,get:function(){return h.RentalStatus}}),Object.defineProperty(e,"RentalsListingSortDirection",{enumerable:!0,get:function(){return h.RentalsListingSortDirection}}),Object.defineProperty(e,"RentalsListingsFilterByCategory",{enumerable:!0,get:function(){return h.RentalsListingsFilterByCategory}}),Object.defineProperty(e,"RentalsListingsSortBy",{enumerable:!0,get:function(){return h.RentalsListingsSortBy}}),Object.defineProperty(e,"RentalListingCreation",{enumerable:!0,get:function(){return h.RentalListingCreation}}),Object.defineProperty(e,"PeriodCreation",{enumerable:!0,get:function(){return h.PeriodCreation}});var T=C2();Object.defineProperty(e,"AnalyticsDayDataSortBy",{enumerable:!0,get:function(){return T.AnalyticsDayDataSortBy}});var w=D2();Object.defineProperty(e,"Store",{enumerable:!0,get:function(){return w.Store}});var P=j2();Object.defineProperty(e,"WearableGender",{enumerable:!0,get:function(){return P.WearableGender}}),Object.defineProperty(e,"GenderFilterOption",{enumerable:!0,get:function(){return P.GenderFilterOption}});var B=$2();Object.defineProperty(e,"World",{enumerable:!0,get:function(){return B.World}}),Object.defineProperty(e,"getWorld",{enumerable:!0,get:function(){return B.getWorld}}),Object.defineProperty(e,"isInsideWorldLimits",{enumerable:!0,get:function(){return B.isInsideWorldLimits}}),r(L2(),e),r(q2(),e),r(k2(),e),r(nV(),e),r(oV(),e)})(Ai)),Ai}var Eh={},SR;function cV(){return SR||(SR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.LinkerAuthorization=void 0;const t=Ne();(function(r){r.schema={type:"object",properties:{name:{type:"string"},desc:{type:"string"},startDate:{type:"string",nullable:!0},endDate:{type:"string",nullable:!0},contactInfo:{type:"object",properties:{name:{type:"string"}},required:["name"]},onlyDev:{type:"boolean",nullable:!0},addresses:{type:"array",items:{type:"string"},minItems:1},plots:{type:"array",items:{type:"string"},minItems:1}},required:["name","desc","contactInfo","addresses","plots"]},r.validate=(0,t.generateLazyValidator)(r.schema)})(e.LinkerAuthorization||(e.LinkerAuthorization={}))})(Eh)),Eh}var Ni={},vh={},Ts={},IR;function gP(){if(IR)return Ts;IR=1,Object.defineProperty(Ts,"__esModule",{value:!0}),Ts.isInExceptionBlock=void 0;function e(i,a){return i>=62&&i<=150&&a>=151&&a<=158}function t(i,a){return i>=151&&i<=162&&a>=144&&a<=158}function r(i,a){return i>=151&&i<=163&&a>=59&&a<=143}function n(i,a){return e(i,a)||t(i,a)||r(i,a)}return Ts.isInExceptionBlock=n,Ts}var RR;function lV(){return RR||(RR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.Parcel=e.PARCEL_LIMITS=void 0;const t=Ne(),r=gP();e.PARCEL_LIMITS={minX:-150,maxX:150,minY:-150,maxY:150},(function(n){n._isInLimits={keyword:"_isInLimits",validate:function(p,E){return!E||typeof E.x!="number"||typeof E.y!="number"?!1:o(E)||(0,r.isInExceptionBlock)(E.x,E.y)},errors:!1},n.schema={type:"object",required:["x","y"],properties:{x:{type:"number"},y:{type:"number"}},_isInLimits:!0,additionalProperties:!1},n.validate=(0,t.generateLazyValidator)(n.schema,[n._isInLimits]);function i({x:m,y:p}){return`${m},${p}`}n.parcelToString=i;function a(m){const p=m.match(/^(-?\d+),(-?\d+)$/);if(!p)return null;const[,E,A]=p,R=parseInt(E,10),O=parseInt(A,10);return{x:R,y:O}}n.stringToParcel=a;function s(m){const p=a(m);return p?n.validate(p):!1}n.isParcelStringValid=s;function o(m){const{x:p,y:E}=m;return p>=e.PARCEL_LIMITS.minX&&p<=e.PARCEL_LIMITS.maxX&&E>=e.PARCEL_LIMITS.minY&&E<=e.PARCEL_LIMITS.maxY}n.isInStandardBounds=o;function u(m){return(0,r.isInExceptionBlock)(m.x,m.y)}n.isExceptionParcel=u;function l(m){return o(m)||u(m)}n.isInBounds=l;function c(m){return n.validate(m)}n.isValid=c;function d(m){const p=a(m);return p?n.validate(p):!1}n.isValidString=d})(e.Parcel||(e.Parcel={}))})(vh)),vh}var Pi={},AR;function dV(){if(AR)return Pi;AR=1,Object.defineProperty(Pi,"__esModule",{value:!0}),Pi.validateUrlInstance=Pi.validateUrl=void 0;const e={allowLocalhost:!1,allowedPorts:[]};function t(p,E=2){let A=p;for(let R=0;R<E;R++)try{A=decodeURIComponent(A)}catch{break}return A.normalize("NFKC")}function r(p){return/[\u0000-\u001F\u007F-\u009F\u202A-\u202E\u2066-\u2069]/.test(p)}function n(p){return!!(p.username||p.password)}function i(p){return/\\/.test(p)}const a=["80","443"];function s(p,E){return!!p.port&&!E.includes(p.port)}function o(p){const E=p.toLowerCase();return!!(E==="localhost"||E.endsWith(".local")||/^(127\.|10\.|172\.(1[6-9]|2[0-9]|3[0-1])\.|192\.168\.|169\.254\.)/.test(E)||E==="::1"||E==="[::1]"||E.startsWith("fe80:")||E.startsWith("fc00:"))}function u(p){if(p.startsWith("//"))return null;try{return{url:new URL(p),wasRelative:!1}}catch{try{return{url:new URL(p,"https://example.com"),wasRelative:!0}}catch{return null}}}function l(p){const E=t(String(p).toLowerCase());return!(r(E)||i(E))}function c(p){return!(!p||p.includes("..")||p.includes("//")||r(p)||i(p))}function d(p,E={}){const A=Object.assign(Object.assign({},e),E),R=[...a,...A.allowedPorts];if(!p||p.length===0||p.length>4096||r(p)||i(p))return!1;const O=t(p);if(r(O)||i(O)||p.startsWith("//"))return!1;const f=u(p);if(!f)return!1;const{url:v,wasRelative:b}=f;if(v.protocol!=="http:"&&v.protocol!=="https:"&&v.protocol!==""||n(v)||i(p)||i(v.href)||!b&&(s(v,R)||!A.allowLocalhost&&v.hostname&&o(v.hostname))||!c(v.pathname)||v.pathname.length>2048)return!1;const h=Array.from(v.searchParams.entries());if(h.length>50||(v.search?v.search.startsWith("?")?v.search.length-1:v.search.length:0)>2048)return!1;for(const[w,P]of h)if(w.length===0||!l(w)||!l(P)||w.length>128||P.length>1024)return!1;return!(v.hash&&r(v.hash))}Pi.validateUrl=d;function m(p,E={}){return d(p.toString(),E)}return Pi.validateUrlInstance=m,Pi}var wR;function fV(){return wR||(wR=1,(function(e){var t=Ni&&Ni.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Ni&&Ni.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(lV(),e),r(gP(),e),r(dV(),e)})(Ni)),Ni}var OR;function pV(){return OR||(OR=1,(function(e){var t=Dr&&Dr.__createBinding||(Object.create?(function(s,o,u,l){l===void 0&&(l=u);var c=Object.getOwnPropertyDescriptor(o,u);(!c||("get"in c?!o.__esModule:c.writable||c.configurable))&&(c={enumerable:!0,get:function(){return o[u]}}),Object.defineProperty(s,l,c)}):(function(s,o,u,l){l===void 0&&(l=u),s[l]=o[u]})),r=Dr&&Dr.__setModuleDefault||(Object.create?(function(s,o){Object.defineProperty(s,"default",{enumerable:!0,value:o})}):function(s,o){s.default=o}),n=Dr&&Dr.__importStar||function(s){if(s&&s.__esModule)return s;var o={};if(s!=null)for(var u in s)u!=="default"&&Object.prototype.hasOwnProperty.call(s,u)&&t(o,s,u);return r(o,s),o},i=Dr&&Dr.__exportStar||function(s,o){for(var u in s)u!=="default"&&!Object.prototype.hasOwnProperty.call(o,u)&&t(o,s,u)};Object.defineProperty(e,"__esModule",{value:!0}),e.sdk=void 0;const a=n(v2());e.sdk=a,i(Ne(),e),i(uV(),e),i(s_(),e),i(sa(),e),i(cV(),e),i(Po(),e),i(cP(),e),i(pP(),e),i(fV(),e)})(Dr)),Dr}var NR;function _P(){return NR||(NR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.AuthLink=e.AuthLinkType=e.AuthChain=void 0;const t=pV();Object.defineProperty(e,"AuthChain",{enumerable:!0,get:function(){return t.AuthChain}}),Object.defineProperty(e,"AuthLink",{enumerable:!0,get:function(){return t.AuthLink}}),Object.defineProperty(e,"AuthLinkType",{enumerable:!0,get:function(){return t.AuthLinkType}})})(_p)),_p}var PR;function EP(){return PR||(PR=1,(function(e){var t=Cr&&Cr.__createBinding||(Object.create?(function(X,W,$,D){D===void 0&&(D=$);var L=Object.getOwnPropertyDescriptor(W,$);(!L||("get"in L?!W.__esModule:L.writable||L.configurable))&&(L={enumerable:!0,get:function(){return W[$]}}),Object.defineProperty(X,D,L)}):(function(X,W,$,D){D===void 0&&(D=$),X[D]=W[$]})),r=Cr&&Cr.__setModuleDefault||(Object.create?(function(X,W){Object.defineProperty(X,"default",{enumerable:!0,value:W})}):function(X,W){X.default=W}),n=Cr&&Cr.__importStar||(function(){var X=function(W){return X=Object.getOwnPropertyNames||function($){var D=[];for(var L in $)Object.prototype.hasOwnProperty.call($,L)&&(D[D.length]=L);return D},X(W)};return function(W){if(W&&W.__esModule)return W;var $={};if(W!=null)for(var D=X(W),L=0;L<D.length;L++)D[L]!=="default"&&t($,W,D[L]);return r($,W),$}})(),i=Cr&&Cr.__importDefault||function(X){return X&&X.__esModule?X:{default:X}};Object.defineProperty(e,"__esModule",{value:!0}),e.parseEmphemeralPayload=e.EIP_1654_SIGNED_ENTITY_VALIDATOR=e.ECDSA_EIP_1654_EPHEMERAL_VALIDATOR=e.ECDSA_PERSONAL_EPHEMERAL_VALIDATOR=e.ECDSA_SIGNED_ENTITY_VALIDATOR=e.SIGNER_VALIDATOR=e.Authenticator=e.createEthereumMessageHash=e.ERC1654_MAGIC_VALUE=e.VALID_SIGNATURE=void 0,e.validateSignature=m,e.isValidAuthChain=p,e.createEIP1271MessageHash=E,e.createSimpleAuthChain=A,e.createAuthChain=R,e.initializeAuthChain=O,e.signPayload=f,e.createSignature=v,e.ownerAddress=b,e.getEphemeralMessage=h,e.getEphemeralSignatureType=z,e.getSignedIdentitySignatureType=U,e.parseEphemeralPayload=F,e.isValidEIP1271Signature=ue;const a=n(bl()),s=bF(),o=MF(),u=i(CF()),l=DF(),c=_P();e.VALID_SIGNATURE="VALID_SIGNATURE",e.ERC1654_MAGIC_VALUE="1626ba7e";const d=132;async function m(X,W,$,D=Date.now()){let L="";if(!p(W))return{ok:!1,message:"ERROR: Malformed authChain"};for(const N of W){const j=re(N.type);try{const{nextAuthority:Z}=await j(L,N,{provider:$,dateToValidateExpirationInMillis:D});L=Z||""}catch(Z){const Ee=Z instanceof Error?Z.message:String(Z);return{ok:!1,message:`ERROR. Link type: ${N.type}. ${Ee}.`}}}const H=L===X;return{ok:H,message:H?void 0:`ERROR: Invalid final authority. Expected: ${X}. Current ${L}.`}}function p(X){for(const[W,$]of X.entries())if(W===0&&$.type!==c.AuthLinkType.SIGNER||$.type===c.AuthLinkType.SIGNER&&W!==0)return!1;return!0}function E(X){return(0,a.hexToBytes)((0,a.sha3)((0,a.stringToUtf8Bytes)(X)))}function A(X,W,$){return[{type:c.AuthLinkType.SIGNER,payload:W,signature:""},{type:U($),payload:X,signature:$}]}function R(X,W,$,D){const L=(0,l.moveMinutes)($),H=h(W.address,L),N=v(X,H),j=v(W,D);return[{type:c.AuthLinkType.SIGNER,payload:X.address,signature:""},{type:c.AuthLinkType.ECDSA_PERSONAL_EPHEMERAL,payload:H,signature:N},{type:c.AuthLinkType.ECDSA_PERSONAL_SIGNED_ENTITY,payload:D,signature:j}]}async function O(X,W,$,D){const L=(0,l.moveMinutes)($),H=h(W.address,L),N=await D(H),j=[{type:c.AuthLinkType.SIGNER,payload:X,signature:""},{type:z(N),payload:H,signature:N}];return{ephemeralIdentity:W,expiration:L,authChain:j}}function f(X,W){const $=v(X.ephemeralIdentity,W);return[...X.authChain,{type:c.AuthLinkType.ECDSA_PERSONAL_SIGNED_ENTITY,payload:W,signature:$}]}e.createEthereumMessageHash=o.createEthereumMessageHash;function v(X,W){return(0,o.ethSign)((0,a.hexToBytes)(X.privateKey),W)}function b(X){return X.length>0&&X[0].type===c.AuthLinkType.SIGNER?X[0].payload:"Invalid-Owner-Address"}function h(X,W){return`Decentraland Login
|
|
71
|
+
Ephemeral address: ${X}
|
|
72
|
+
Expiration: ${W.toISOString()}`}e.Authenticator={validateSignature:m,isValidAuthChain:p,createEIP1271MessageHash:E,createSimpleAuthChain:A,createAuthChain:R,initializeAuthChain:O,signPayload:f,createEthereumMessageHash:e.createEthereumMessageHash,createSignature:v,ownerAddress:b,getEphemeralMessage:h};const T=async(X,W)=>({nextAuthority:W.payload});e.SIGNER_VALIDATOR=T;const w=async(X,W)=>{if(!W.signature)throw new Error("Invalid AuthLink. 'signature' must be present for type 'ECDSA_SIGNED_ENTITY_VALIDATOR'");const $=(0,o.recoverAddressFromEthSignature)(W.signature,W.payload),D=X.toLocaleLowerCase(),L=$.toLocaleLowerCase();if(D===L)return{nextAuthority:W.payload};throw new Error(`Invalid signer address. Expected: ${D}. Actual: ${L}`)};e.ECDSA_SIGNED_ENTITY_VALIDATOR=w;const P=async(X,W,$)=>{if(!W.signature)throw new Error("Invalid AuthLink. 'signature' must be present for type 'ECDSA_PERSONAL_EPHEMERAL_VALIDATOR'");const{message:D,ephemeralAddress:L,expiration:H}=F(W.payload),N=($==null?void 0:$.dateToValidateExpirationInMillis)||Date.now();if(H>N){const j=(0,o.recoverAddressFromEthSignature)(W.signature,D),Z=X.toLocaleLowerCase(),Ee=j.toLocaleLowerCase();if(Z===Ee)return{nextAuthority:L};throw new Error(`Invalid signer address. Expected: ${Z}. Actual: ${Ee}`)}throw new Error(`Ephemeral key expired. Expiration: ${H}. Test: ${N}`)};e.ECDSA_PERSONAL_EPHEMERAL_VALIDATOR=P;const B=async(X,W,$)=>{if(!W.signature)throw new Error("Invalid AuthLink. 'signature' must be present for type 'ECDSA_EIP_1654_EPHEMERAL_VALIDATOR'");const{message:D,ephemeralAddress:L,expiration:H}=F(W.payload),N=($==null?void 0:$.dateToValidateExpirationInMillis)||Date.now();if(H>N&&await ae($==null?void 0:$.provider,X,D,W.signature,N))return{nextAuthority:L};throw new Error(`Ephemeral key expired. Expiration: ${H}. Test: ${N}`)};e.ECDSA_EIP_1654_EPHEMERAL_VALIDATOR=B;const J=async(X,W,$)=>{if(!W.signature)throw new Error("Invalid AuthLink. 'signature' must be present for type 'EIP_1654_SIGNED_ENTITY_VALIDATOR'");if(!$)throw new Error("Missing validation options for 'EIP_1654_SIGNED_ENTITY_VALIDATOR'");if(await ae($.provider,X,W.payload,W.signature,$.dateToValidateExpirationInMillis))return{nextAuthority:W.payload};throw new Error("Invalid validation")};e.EIP_1654_SIGNED_ENTITY_VALIDATOR=J;const K=async(X,W)=>({error:"Error Validator."});function z(X){return X.length===d?c.AuthLinkType.ECDSA_PERSONAL_EPHEMERAL:c.AuthLinkType.ECDSA_EIP_1654_EPHEMERAL}function U(X){return X.length===d?c.AuthLinkType.ECDSA_PERSONAL_SIGNED_ENTITY:c.AuthLinkType.ECDSA_EIP_1654_SIGNED_ENTITY}function F(X){const W=X.replace(/\r/g,""),$=W.split(`
|
|
73
|
+
`),D="Ephemeral address: ",L="Expiration: ";if($.length<3||!$[1].startsWith(D)||!$[2].startsWith(L))throw new Error(`Invalid ephemeral payload. Expected 3 lines with "${D}" on line 2 and "${L}" on line 3.`);const H=$[1].substring(D.length),N=$[2].substring(L.length),j=Date.parse(N);if(Number.isNaN(j))throw new Error(`Invalid expiration date in ephemeral payload: "${N}"`);return{message:W,ephemeralAddress:H,expiration:j}}e.parseEmphemeralPayload=F;async function ue(X,W,$,D){const L=E(W),H=(0,a.hexToBytes)($);let N;try{N=(0,a.bytesToHex)(await X.isValidSignature(L,H,D))}catch{}if(N===e.ERC1654_MAGIC_VALUE)return!0;const j=(0,o.createEthereumMessageHash)(W);try{N=(0,a.bytesToHex)(await X.isValidSignature(j,H,D))}catch{}return N===e.ERC1654_MAGIC_VALUE}async function ae(X,W,$,D,L){if(!X)throw new Error("Missing provider");const H=new a.default(X),N=await(0,s.SignatureValidator)(H,W);let j=await ue(N,$,D);if(j)return!0;const Z=new u.default(H);try{const{block:Ee}=await Z.getDate(L,!1);if(j=await ue(N,$,D,Ee),j)return!0}catch(Ee){const _e=Ee instanceof Error?Ee.message:String(Ee);throw new Error(`Invalid validation. Error: ${_e}`)}throw new Error(`Invalid validation. Expected: ${e.ERC1654_MAGIC_VALUE}. Actual: ${j}`)}function re(X){switch(X){case c.AuthLinkType.SIGNER:return e.SIGNER_VALIDATOR;case c.AuthLinkType.ECDSA_PERSONAL_EPHEMERAL:return e.ECDSA_PERSONAL_EPHEMERAL_VALIDATOR;case c.AuthLinkType.ECDSA_PERSONAL_SIGNED_ENTITY:return e.ECDSA_SIGNED_ENTITY_VALIDATOR;case c.AuthLinkType.ECDSA_EIP_1654_EPHEMERAL:return e.ECDSA_EIP_1654_EPHEMERAL_VALIDATOR;case c.AuthLinkType.ECDSA_EIP_1654_SIGNED_ENTITY:return e.EIP_1654_SIGNED_ENTITY_VALIDATOR;default:return K}}})(Cr)),Cr}var _n={},MR;function mV(){return MR||(MR=1,Object.defineProperty(_n,"__esModule",{value:!0}),_n.AUTH_METADATA_HEADER=_n.AUTH_TIMESTAMP_HEADER=_n.AUTH_CHAIN_HEADER_PREFIX=void 0,_n.AUTH_CHAIN_HEADER_PREFIX="x-identity-auth-chain-",_n.AUTH_TIMESTAMP_HEADER="x-identity-timestamp",_n.AUTH_METADATA_HEADER="x-identity-metadata"),_n}var CR;function hV(){return CR||(CR=1,(function(e){var t=mi&&mi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=mi&&mi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(EP(),e),r(mV(),e),r(_P(),e)})(mi)),mi}var yV=hV(),Mi={},Lr={},Cc={exports:{}},Dc={exports:{}},DR;function u_(){return DR||(DR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(n){if(n==null)throw new TypeError("Expected a string but received a ".concat(n));if(n.constructor.name!=="String")throw new TypeError("Expected a string but received a ".concat(n.constructor.name))}e.exports=t.default,e.exports.default=t.default})(Dc,Dc.exports)),Dc.exports}var jc={exports:{}},jR;function gV(){return jR||(jR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function r(i){return Object.prototype.toString.call(i)==="[object RegExp]"}function n(i,a){for(var s=0;s<a.length;s++){var o=a[s];if(i===o||r(o)&&o.test(i))return!0}return!1}e.exports=t.default,e.exports.default=t.default})(jc,jc.exports)),jc.exports}var $c={exports:{}},$R;function _V(){return $R||($R=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var r=function(i,a){return i.indexOf(a)!==-1};t.default=r,e.exports=t.default,e.exports.default=t.default})($c,$c.exports)),$c.exports}var Lc={exports:{}},qc={exports:{}},LR;function vP(){return LR||(LR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function r(i){"@babel/helpers - typeof";return r=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},r(i)}function n(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},a=arguments.length>1?arguments[1]:void 0;(r(i)!=="object"||i===null)&&(i={});for(var s in a)typeof i[s]>"u"&&(i[s]=a[s]);return i}e.exports=t.default,e.exports.default=t.default})(qc,qc.exports)),qc.exports}var qR;function EV(){return qR||(qR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=s;var r=i(u_()),n=i(vP());function i(o){return o&&o.__esModule?o:{default:o}}var a={require_tld:!0,allow_underscores:!1,allow_trailing_dot:!1,allow_numeric_tld:!1,allow_wildcard:!1,ignore_max_length:!1};function s(o,u){(0,r.default)(o),u=(0,n.default)(u,a),u.allow_trailing_dot&&o[o.length-1]==="."&&(o=o.substring(0,o.length-1)),u.allow_wildcard===!0&&o.indexOf("*.")===0&&(o=o.substring(2));var l=o.split("."),c=l[l.length-1];return u.require_tld&&(l.length<2||!u.allow_numeric_tld&&!/^([a-z\u00A1-\u00A8\u00AA-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]{2,}|xn[a-z0-9-]{2,})$/i.test(c)||/\s/.test(c))||!u.allow_numeric_tld&&/^\d+$/.test(c)?!1:l.every(function(d){return!(d.length>63&&!u.ignore_max_length||!/^[a-z_\u00a1-\uffff0-9-]+$/i.test(d)||/[\uff01-\uff5e]/.test(d)||/^-|-$/.test(d)||!u.allow_underscores&&/_/.test(d))})}e.exports=t.default,e.exports.default=t.default})(Lc,Lc.exports)),Lc.exports}var kc={exports:{}},kR;function vV(){return kR||(kR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=c;var r=n(u_());function n(d){return d&&d.__esModule?d:{default:d}}function i(d){"@babel/helpers - typeof";return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(m){return typeof m}:function(m){return m&&typeof Symbol=="function"&&m.constructor===Symbol&&m!==Symbol.prototype?"symbol":typeof m},i(d)}var a="(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])",s="(".concat(a,"[.]){3}").concat(a),o=new RegExp("^".concat(s,"$")),u="(?:[0-9a-fA-F]{1,4})",l=new RegExp("^("+"(?:".concat(u,":){7}(?:").concat(u,"|:)|")+"(?:".concat(u,":){6}(?:").concat(s,"|:").concat(u,"|:)|")+"(?:".concat(u,":){5}(?::").concat(s,"|(:").concat(u,"){1,2}|:)|")+"(?:".concat(u,":){4}(?:(:").concat(u,"){0,1}:").concat(s,"|(:").concat(u,"){1,3}|:)|")+"(?:".concat(u,":){3}(?:(:").concat(u,"){0,2}:").concat(s,"|(:").concat(u,"){1,4}|:)|")+"(?:".concat(u,":){2}(?:(:").concat(u,"){0,3}:").concat(s,"|(:").concat(u,"){1,5}|:)|")+"(?:".concat(u,":){1}(?:(:").concat(u,"){0,4}:").concat(s,"|(:").concat(u,"){1,6}|:)|")+"(?::((?::".concat(u,"){0,5}:").concat(s,"|(?::").concat(u,"){1,7}|:))")+")(%[0-9a-zA-Z.]{1,})?$");function c(d){var m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};(0,r.default)(d);var p=(i(m)==="object"?m.version:arguments[1])||"";return p?p.toString()==="4"?o.test(d):p.toString()==="6"?l.test(d):!1:c(d,{version:4})||c(d,{version:6})}e.exports=t.default,e.exports.default=t.default})(kc,kc.exports)),kc.exports}var BR;function bV(){return BR||(BR=1,(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=O;var r=u(u_()),n=u(gV()),i=u(_V()),a=u(EV()),s=u(vV()),o=u(vP());function u(f){return f&&f.__esModule?f:{default:f}}function l(f,v){return E(f)||p(f,v)||d(f,v)||c()}function c(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
74
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function d(f,v){if(f){if(typeof f=="string")return m(f,v);var b={}.toString.call(f).slice(8,-1);return b==="Object"&&f.constructor&&(b=f.constructor.name),b==="Map"||b==="Set"?Array.from(f):b==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(b)?m(f,v):void 0}}function m(f,v){(v==null||v>f.length)&&(v=f.length);for(var b=0,h=Array(v);b<v;b++)h[b]=f[b];return h}function p(f,v){var b=f==null?null:typeof Symbol<"u"&&f[Symbol.iterator]||f["@@iterator"];if(b!=null){var h,T,w,P,B=[],J=!0,K=!1;try{if(w=(b=b.call(f)).next,v!==0)for(;!(J=(h=w.call(b)).done)&&(B.push(h.value),B.length!==v);J=!0);}catch(z){K=!0,T=z}finally{try{if(!J&&b.return!=null&&(P=b.return(),Object(P)!==P))return}finally{if(K)throw T}}return B}}function E(f){if(Array.isArray(f))return f}var A={protocols:["http","https","ftp"],require_tld:!0,require_protocol:!1,require_host:!0,require_port:!1,require_valid_protocol:!0,allow_underscores:!1,allow_trailing_dot:!1,allow_protocol_relative_urls:!1,allow_fragments:!0,allow_query_components:!0,validate_length:!0,max_allowed_length:2084},R=/^\[([^\]]+)\](?::([0-9]+))?$/;function O(f,v){if((0,r.default)(f),!f||/[\s<>]/.test(f)||f.indexOf("mailto:")===0||(v=(0,o.default)(v,A),v.validate_length&&f.length>v.max_allowed_length)||!v.allow_fragments&&(0,i.default)(f,"#")||!v.allow_query_components&&((0,i.default)(f,"?")||(0,i.default)(f,"&")))return!1;var b,h,T,w,P,B,J,K;J=f.split("#"),f=J.shift(),J=f.split("?"),f=J.shift();var z=f.match(/^([a-z][a-z0-9+\-.]*):/i),U=!1,F=function(ce){return U=!0,b=ce.toLowerCase(),v.require_valid_protocol&&v.protocols.indexOf(b)===-1?!1:f.substring(z[0].length)};if(z){var ue=z[1],ae=f.substring(z[0].length),re=ae.slice(0,2)==="//";if(re){if(f=F(ue),f===!1)return!1}else{var X=ae.indexOf("/"),W=X===-1?ae:ae.substring(0,X),$=W.indexOf("@");if($!==-1){var D=W.substring(0,$),L=/^[a-zA-Z0-9\-_.%:]*$/,H=L.test(D),N=/%[0-9a-fA-F]{2}/.test(D);if(H&&!N){if(v.require_protocol)return!1}else if(f=F(ue),f===!1)return!1}else{var j=/^[0-9]/.test(ae);if(j){if(v.require_protocol)return!1}else if(f=F(ue),f===!1)return!1}}}else if(v.require_protocol)return!1;if(f.slice(0,2)==="//"){if(!U&&!v.allow_protocol_relative_urls)return!1;f=f.slice(2)}if(f==="")return!1;if(J=f.split("/"),f=J.shift(),f===""&&!v.require_host)return!0;if(J=f.split("@"),J.length>1){if(v.disallow_auth||J[0]===""||(h=J.shift(),h.indexOf(":")>=0&&h.split(":").length>2))return!1;var Z=h.split(":"),Ee=l(Z,2),_e=Ee[0],Se=Ee[1];if(_e===""&&Se==="")return!1}w=J.join("@"),B=null,K=null;var Ie=w.match(R);if(Ie?(T="",K=Ie[1],B=Ie[2]||null):(J=w.split(":"),T=J.shift(),J.length&&(B=J.join(":"))),B!==null&&B.length>0){if(P=parseInt(B,10),!/^[0-9]+$/.test(B)||P<=0||P>65535)return!1}else if(v.require_port)return!1;return v.host_whitelist?(0,n.default)(T,v.host_whitelist):T===""&&!v.require_host?!0:!(!(0,s.default)(T)&&!(0,a.default)(T,v)&&(!K||!(0,s.default)(K,6))||(T=T||K,v.host_blacklist&&(0,n.default)(T,v.host_blacklist)))}e.exports=t.default,e.exports.default=t.default})(Cc,Cc.exports)),Cc.exports}var bh={},UR;function bP(){return UR||(UR=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.localStorageClearIdentity=e.localStorageStoreIdentity=e.localStorageGetIdentity=e.createMessage=e.SINGLE_SIGN_ON_TARGET=e.Action=void 0;var t;(function(o){o.GET="get",o.STORE="store",o.CLEAR="clear",o.PING="ping"})(t||(e.Action=t={})),e.SINGLE_SIGN_ON_TARGET="single-sign-on";function r(o){return{target:e.SINGLE_SIGN_ON_TARGET,...o}}e.createMessage=r;function n(o){const u=localStorage.getItem(s(o));if(!u)return null;let l;try{l=JSON.parse(u)}catch{return a(o),null}return l.expiration=new Date(l.expiration),l.expiration.getTime()<=Date.now()?(a(o),null):l}e.localStorageGetIdentity=n;function i(o,u){new Date(u.expiration).getTime()>Date.now()&&localStorage.setItem(s(o),JSON.stringify(u))}e.localStorageStoreIdentity=i;function a(o){localStorage.removeItem(s(o))}e.localStorageClearIdentity=a;function s(o){if(!/^0x[a-fA-F0-9]{40}$/.test(o))throw new Error("User must be a valid ethereum address");return`single-sign-on-${o.toLowerCase()}`}})(bh)),bh}var FR;function TV(){if(FR)return Lr;FR=1,Object.defineProperty(Lr,"__esModule",{value:!0}),Lr.clearIdentity=Lr.storeIdentity=Lr.getIdentity=Lr.init=void 0;const e=bV(),t=bP(),r=t.SINGLE_SIGN_ON_TARGET,n=500,i=5;let a=0,s="";const o={protocols:["https"],require_protocol:!0};function u(R,O={}){if(!(0,e.default)(R,{...o,...O}))throw new Error(`Invalid url: ${R}`);if(s)throw new Error("Already initialized");const f=document.createElement("iframe");f.id=r,f.src=R,f.style.width="0",f.style.height="0",f.style.border="none",f.style.position="absolute",document.body.appendChild(f),s=R}Lr.init=u;async function l(R){let O;try{O=(await p(await m(),t.Action.GET,{user:R})).identity??null}catch(f){A(f),O=(0,t.localStorageGetIdentity)(R)}return O}Lr.getIdentity=l;async function c(R,O){try{await p(await m(),t.Action.STORE,{user:R,identity:O})}catch(f){A(f),(0,t.localStorageStoreIdentity)(R,O)}}Lr.storeIdentity=c;async function d(R){try{await p(await m(),t.Action.CLEAR,{user:R})}catch(O){A(O),(0,t.localStorageClearIdentity)(R)}}Lr.clearIdentity=d;async function m(){if(!s)throw new Error("Not initialized");for(let R=0;R<i;R++){const O=document.getElementById(r),f=O==null?void 0:O.contentWindow;if(!f){await E(n);continue}try{await p(f,t.Action.PING,{},n)}catch{continue}return f}throw new Error("Could not get iframe because it is not ready or cannot be communicated with")}async function p(R,O,f,v=0){a++;const b=a;let h=null;const T=new Promise((w,P)=>{h=({data:B})=>{!B||B.target!==t.SINGLE_SIGN_ON_TARGET||B.id!==b||(B.error?P(new Error(B.error)):w(B))},window.addEventListener("message",h)});R.postMessage((0,t.createMessage)({id:b,action:O,...f}),s);try{return await(v?Promise.race([T,new Promise((w,P)=>setTimeout(()=>P(new Error("Did not receive a response in time")),v))]):T)}catch(w){throw w}finally{h&&window.removeEventListener("message",h)}}function E(R){return new Promise(O=>setTimeout(O,R))}function A(R){console.warn("Could not get identity from iframe, falling back to localStorage. Error:",R.message)}return Lr}var VR;function SV(){return VR||(VR=1,(function(e){var t=Mi&&Mi.__createBinding||(Object.create?(function(n,i,a,s){s===void 0&&(s=a);var o=Object.getOwnPropertyDescriptor(i,a);(!o||("get"in o?!i.__esModule:o.writable||o.configurable))&&(o={enumerable:!0,get:function(){return i[a]}}),Object.defineProperty(n,s,o)}):(function(n,i,a,s){s===void 0&&(s=a),n[s]=i[a]})),r=Mi&&Mi.__exportStar||function(n,i){for(var a in n)a!=="default"&&!Object.prototype.hasOwnProperty.call(i,a)&&t(i,n,a)};Object.defineProperty(e,"__esModule",{value:!0}),r(TV(),e),r(bP(),e)})(Mi)),Mi}var ag=SV();function IV(e){const{host:t}=e;return t.endsWith(".org")||t.endsWith(".co")?un.PRODUCTION:t.endsWith(".today")||t.endsWith(".net")?un.STAGING:t.endsWith(".io")||t.endsWith(".zone")?un.DEVELOPMENT:null}function RV(e){const t=new URLSearchParams(e.search),r=t.get("ENV")||t.get("env");if(r){const n=r.toLowerCase();if(SP(n))return n}return null}var HR={},un;(function(e){e.DEVELOPMENT="dev",e.STAGING="stg",e.PRODUCTION="prod"})(un||(un={}));function TP(){return Object.values(un)}function SP(e){return TP().includes(e)}function Bc(e){if(SP(e))return e;throw new Error(`Invalid value for DCL_DEFAULT_ENV. Found "${e}", possible values are ${TP().map(t=>`"${t}"`).join(", ")}.`)}function AV(e={}){const{DCL_DEFAULT_ENV:t,REACT_APP_DCL_DEFAULT_ENV:r,VITE_DCL_DEFAULT_ENV:n,GATSBY_DCL_DEFAULT_ENV:i}=e;if(t&&r&&t!==r)throw new Error("You have defined both DCL_DEFAULT_ENV and REACT_APP_DCL_DEFAULT_ENV with different values");if(t&&n&&t!==n)throw new Error("You have defined both DCL_DEFAULT_ENV and VITE_DCL_DEFAULT_ENV with different values");if(t&&i&&t!==i)throw new Error("You have defined both DCL_DEFAULT_ENV and GATSBY_DCL_DEFAULT_ENV with different values");if(r&&i&&r!==i)throw new Error("You have defined both REACT_APP_DCL_DEFAULT_ENV and GATSBY_DCL_DEFAULT_ENV with different values");return t?Bc(t):r?Bc(r):n?Bc(n):i?Bc(i):un.PRODUCTION}function wV(e){if(typeof window<"u"){const r=RV(window.location);if(r)return r;const n=IV(window.location);if(n)return n}return AV(typeof e>"u"&&typeof Uc=="object"&&typeof HR=="object"?HR:e)}function OV(e,t){const r=wV(t==null?void 0:t.systemEnvVariables),n=e[r];return{get:(i,a="")=>{if(!n)throw new Error(`Could not find a config for env=${r}`);return i in n?n[i]:a},is:i=>r===i,getEnv:()=>r}}const NV="development",PV="80002",MV="https://marketplace-api.decentraland.zone",CV="https://marketplace-api.decentraland.zone",DV="/auth",jV="https://rpc.decentraland.org/amoy",$V="https://credits.decentraland.zone",LV="https://builder-api.decentraland.zone",qV="https://peer.decentraland.zone",kV="",BV="",UV="",FV="",VV={ENVIRONMENT:NV,CHAIN_ID:PV,MARKETPLACE_SERVER_URL:MV,NFT_API_URL:CV,AUTH_URL:DV,RPC_URL:jV,CREDITS_SERVER_URL:$V,BUILDER_SERVER_URL:LV,PEER_URL:qV,SHOP_SERVER_URL:kV,STRIPE_PUBLISHABLE_KEY:BV,SEGMENT_WRITE_KEY:UV,SENTRY_DSN:FV},HV="staging",GV="80002",zV="https://marketplace-api.decentraland.zone",WV="https://marketplace-api.decentraland.zone",YV="/auth",KV="https://rpc.decentraland.org/amoy",JV="https://credits.decentraland.zone",XV="https://builder-api.decentraland.zone",QV="https://peer.decentraland.zone",ZV="",xV="",eH="",tH="",rH={ENVIRONMENT:HV,CHAIN_ID:GV,MARKETPLACE_SERVER_URL:zV,NFT_API_URL:WV,AUTH_URL:YV,RPC_URL:KV,CREDITS_SERVER_URL:JV,BUILDER_SERVER_URL:XV,PEER_URL:QV,SHOP_SERVER_URL:ZV,STRIPE_PUBLISHABLE_KEY:xV,SEGMENT_WRITE_KEY:eH,SENTRY_DSN:tH},nH="production",iH="137",aH="https://marketplace-api.decentraland.org",sH="https://marketplace-api.decentraland.org",oH="/auth",uH="https://rpc.decentraland.org/polygon",cH="https://credits.decentraland.org",lH="https://builder-api.decentraland.org",dH="https://peer.decentraland.org",fH="",pH="",mH="",hH="",yH={ENVIRONMENT:nH,CHAIN_ID:iH,MARKETPLACE_SERVER_URL:aH,NFT_API_URL:sH,AUTH_URL:oH,RPC_URL:uH,CREDITS_SERVER_URL:cH,BUILDER_SERVER_URL:lH,PEER_URL:dH,SHOP_SERVER_URL:fH,STRIPE_PUBLISHABLE_KEY:pH,SEGMENT_WRITE_KEY:mH,SENTRY_DSN:hH},gH={},br=OV({[un.DEVELOPMENT]:VV,[un.STAGING]:rH,[un.PRODUCTION]:yH},{systemEnvVariables:{VITE_DCL_DEFAULT_ENV:"dev"}}),rr=gH,Dt={marketplaceServerUrl:rr.VITE_MARKETPLACE_SERVER_URL??br.get("MARKETPLACE_SERVER_URL"),nftApiUrl:rr.VITE_NFT_API_URL??br.get("NFT_API_URL"),chainId:Number(rr.VITE_CHAIN_ID??br.get("CHAIN_ID")),authUrl:rr.VITE_AUTH_URL??br.get("AUTH_URL"),rpcUrl:rr.VITE_RPC_URL??br.get("RPC_URL"),creditsServerUrl:rr.VITE_CREDITS_SERVER_URL??br.get("CREDITS_SERVER_URL"),builderServerUrl:rr.VITE_BUILDER_SERVER_URL??br.get("BUILDER_SERVER_URL"),peerUrl:rr.VITE_PEER_URL??br.get("PEER_URL"),shopServerUrl:rr.VITE_SHOP_SERVER_URL??br.get("SHOP_SERVER_URL"),stripePublishableKey:rr.VITE_STRIPE_PK??br.get("STRIPE_PUBLISHABLE_KEY"),segmentWriteKey:rr.VITE_SEGMENT_WRITE_KEY??br.get("SEGMENT_WRITE_KEY"),sentryDsn:rr.VITE_SENTRY_DSN??br.get("SENTRY_DSN"),sentryEnvironment:rr.VITE_SENTRY_ENVIRONMENT??(Number(rr.VITE_CHAIN_ID??br.get("CHAIN_ID"))===80002?"dev":"prod"),sentryRelease:rr.VITE_SENTRY_RELEASE??`shop@${rr.VITE_APP_VERSION??"0.0.0-dev"}`},_H=744*60;async function IP(){return(await Xt(async()=>{const{connection:e}=await import("./index-POoM1fB4.js").then(t=>t.i);return{connection:e}},__vite__mapDeps([6,1]))).connection}async function EH(e){if(!e.account)throw new Error("No account returned by the wallet");const t=e.account.toLowerCase(),r=new _M(e.provider),n=r.getSigner();let i=ag.localStorageGetIdentity(t);if(!i){const a=EM.createRandom();i=await yV.Authenticator.initializeAuthChain(t,{address:a.address,publicKey:C_(a.publicKey),privateKey:C_(a.privateKey)},_H,s=>n.signMessage(s)),ag.localStorageStoreIdentity(t,i)}return{address:t,chainId:e.chainId,signer:n,web3Provider:r,identity:i,providerType:e.providerType}}function vH(){const e=encodeURIComponent(window.location.href);window.location.replace(`${Dt.authUrl}/login?redirectTo=${e}`)}async function bH(){try{const t=await(await IP()).tryPreviousConnection();return!t.account||!ag.localStorageGetIdentity(t.account.toLowerCase())?null:await EH(t)}catch{return null}}async function TH(){try{await(await IP()).disconnect()}catch{}}const SH=typeof crypto<"u"&&"randomUUID"in crypto?crypto.randomUUID():`s-${String(performance.now())}`,IH=Dt.chainId===80002?"amoy":"polygon",RH=Dt.chainId===80002?"dev":"prod";function RP(){return window.analytics}function AH(){let e=null;try{e=Al.getState().session}catch{e=null}return{address:(e==null?void 0:e.address)??null,is_signed_in:!!e,session_id:SH,network:IH,app_env:RH}}function Ji(e,t={}){const r={...AH(),...t},n=RP();n&&n.track(e,r)}function wH(e,t={}){const r=RP();r&&r.identify(e.toLowerCase(),t)}function OH(e){Ji("Shop Viewed Page",{page:e})}function GR(e){return e===oo.ProviderType.MAGIC||e===oo.ProviderType.MAGIC_TEST?"magic":"wallet"}function NH(e){const t=`shop:seen:${e.toLowerCase()}`;try{return localStorage.getItem(t)?!1:(localStorage.setItem(t,"1"),!0)}catch{return!1}}function uo(e){return Math.round(e*10)/100}function AP(e){return!e.tokenId}function k3(e){return{item_id:e.itemId??null,contract_address:e.contractAddress,token_id:e.tokenId??null,trade_id:e.tradeId??null,price_credits:e.priceCredits,price_usd:uo(e.priceCredits),rarity:e.rarity,creator:e.creator||null,is_primary:AP(e)}}function B3(e){const t=e.reduce((n,i)=>n+i.priceCredits,0),r=e.some(AP);return{items:e.map(n=>({item_id:n.itemId??null,contract_address:n.contractAddress,token_id:n.tokenId??null,price_usd:uo(n.priceCredits)})),value_credits:t,value_usd:uo(t),purchase_type:r?"item":"nft_resale",is_primary:r}}function PH(e){const t=e;if((t==null?void 0:t.code)===4001)return"user_rejected";const r=((t==null?void 0:t.message)??"").toLowerCase();return r.includes("reject")||r.includes("denied")||r.includes("cancel")?"user_rejected":r.includes("insufficient")?"insufficient_credits":r.includes("not for sale")||r.includes("no active listing")||r.includes("sold")?"not_for_sale":"unknown"}function U3(e){return PH(e)==="user_rejected"}function MH(e){const t=window;if(t.analytics&&t.analytics.invoked)return;const r=t.analytics||[];r.invoked=!0,r.methods=["track","identify","page","group","alias","ready","on","once","off","reset","setAnonymousId"],r.factory=n=>(...i)=>(r.push([n,...i]),r);for(const n of r.methods)r[n]=r.factory(n);r.load=n=>{const i=document.createElement("script");i.async=!0,i.src=`https://cdn.segment.com/analytics.js/v1/${encodeURIComponent(n)}/analytics.min.js`,document.head.appendChild(i)},t.analytics=r,r.load(e),r.page()}let zR=!1;function CH(){if(zR)return;zR=!0;const e=Dt.segmentWriteKey;e&&MH(e)}let sg=null;function DH(e){sg=e}function WR(e,t={}){const r=typeof t.flow=="string"?`error in ${t.flow}`:"error";if(console.error(`[shop] ${r}`,e,t),sg)try{sg(e,t)}catch{}}const jH=/0x[a-fA-F0-9]{130}\b/g,$H=/0x[a-fA-F0-9]{64}\b/g,LH=/(sk_[a-z]+_[A-Za-z0-9]+|pi_[A-Za-z0-9]+_secret_[A-Za-z0-9]+|[A-Za-z0-9-]*secret[A-Za-z0-9-]*)/gi,qH=/(signature|private|identity|authchain|auth_chain|ephemeral|token|secret|password|cookie|authorization)/i;function Ss(e){return e.replace(jH,"<signature>").replace(LH,"<secret>").replace($H,"<hex32>")}function kH(e){var r;e.message&&(e.message=Ss(e.message));for(const n of((r=e.exception)==null?void 0:r.values)??[])n.value&&(n.value=Ss(n.value));for(const n of e.breadcrumbs??[])n.message&&(n.message=Ss(n.message));e.request&&(e.request.url&&(e.request.url=Ss(e.request.url)),delete e.request.cookies,delete e.request.headers);const t=n=>{if(n)for(const i of Object.keys(n)){if(qH.test(i)){delete n[i];continue}typeof n[i]=="string"&&(n[i]=Ss(n[i]))}};return t(e.tags),t(e.extra),e}let YR=!1;function BH(){if(YR)return;const e=Dt.sentryDsn;if(!e)return;YR=!0,Oq({dsn:e,environment:Dt.sentryEnvironment,release:Dt.sentryRelease,integrations:[new hL],tracesSampleRate:.01,sendDefaultPii:!1,ignoreErrors:[/user rejected/i,/user denied/i,"ResizeObserver loop limit exceeded"],beforeSend:kH});const t=UH();t&&kD({id:t}),DH((r,n)=>Ig(r,{extra:n}))}function UH(){var e;try{return((e=Al.getState().session)==null?void 0:e.address)??null}catch{return null}}const Th="shop:signing_in",Al=Ro(e=>({session:null,connecting:!1,error:null,signIn:()=>{try{sessionStorage.setItem(Th,"1")}catch{}vH()},disconnect:async()=>{Ji("Shop Signed Out");try{await TH()}catch(t){WR(t,{flow:"wallet",step:"disconnect"})}e({session:null})},restore:async()=>{let t;try{t=await bH()}catch(n){WR(n,{flow:"wallet",step:"restore"});return}if(!t)return;e({session:t}),wH(t.address,{sign_in_method:GR(t.providerType)});let r=!1;try{r=sessionStorage.getItem(Th)==="1",r&&sessionStorage.removeItem(Th)}catch{}r&&Ji("Shop Signed In",{method:GR(t.providerType),is_new_user:NH(t.address)})}})),FH=Dt.peerUrl;function wP(e){return tl({queryKey:["profile",e],enabled:!!e,staleTime:5*6e4,queryFn:async()=>{var n;const t=await fetch(`${FH}/lambdas/profiles/${e.toLowerCase()}`);if(!t.ok)return;const r=await t.json();return(n=r==null?void 0:r.avatars)==null?void 0:n[0]}})}var En={},Sh={},KR;function OP(){return KR||(KR=1,Object.defineProperty(Sh,"__esModule",{value:!0})),Sh}var vn={},xr={},ya={},Ci={},JR={},Is,XR;function zr(){if(XR)return Is;XR=1;var e=function(t){return t&&t.Math===Math&&t};return Is=e(typeof globalThis=="object"&&globalThis)||e(typeof window=="object"&&window)||e(typeof self=="object"&&self)||e(typeof vy=="object"&&vy)||e(typeof Is=="object"&&Is)||(function(){return this})()||Function("return this")(),Is}var Ih,QR;function oa(){return QR||(QR=1,Ih=function(e){try{return!!e()}catch{return!0}}),Ih}var Rh,ZR;function wl(){if(ZR)return Rh;ZR=1;var e=oa();return Rh=!e(function(){var t=(function(){}).bind();return typeof t!="function"||t.hasOwnProperty("prototype")}),Rh}var Ah,xR;function VH(){if(xR)return Ah;xR=1;var e=wl(),t=Function.prototype,r=t.apply,n=t.call;return Ah=typeof Reflect=="object"&&Reflect.apply||(e?n.bind(r):function(){return n.apply(r,arguments)}),Ah}var wh,eA;function es(){if(eA)return wh;eA=1;var e=wl(),t=Function.prototype,r=t.call,n=e&&t.bind.bind(r,r);return wh=e?n:function(i){return function(){return r.apply(i,arguments)}},wh}var Oh,tA;function NP(){if(tA)return Oh;tA=1;var e=es(),t=e({}.toString),r=e("".slice);return Oh=function(n){return r(t(n),8,-1)},Oh}var Nh,rA;function PP(){if(rA)return Nh;rA=1;var e=NP(),t=es();return Nh=function(r){if(e(r)==="Function")return t(r)},Nh}var Ph,nA;function ua(){if(nA)return Ph;nA=1;var e=typeof document=="object"&&document.all;return Ph=typeof e>"u"&&e!==void 0?function(t){return typeof t=="function"||t===e}:function(t){return typeof t=="function"},Ph}var Mh={},Ch,iA;function Mo(){if(iA)return Ch;iA=1;var e=oa();return Ch=!e(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}),Ch}var Dh,aA;function c_(){if(aA)return Dh;aA=1;var e=wl(),t=Function.prototype.call;return Dh=e?t.bind(t):function(){return t.apply(t,arguments)},Dh}var jh={},sA;function HH(){if(sA)return jh;sA=1;var e={}.propertyIsEnumerable,t=Object.getOwnPropertyDescriptor,r=t&&!e.call({1:2},1);return jh.f=r?function(i){var a=t(this,i);return!!a&&a.enumerable}:e,jh}var $h,oA;function MP(){return oA||(oA=1,$h=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}}),$h}var Lh,uA;function GH(){if(uA)return Lh;uA=1;var e=es(),t=oa(),r=NP(),n=Object,i=e("".split);return Lh=t(function(){return!n("z").propertyIsEnumerable(0)})?function(a){return r(a)==="String"?i(a,""):n(a)}:n,Lh}var qh,cA;function CP(){return cA||(cA=1,qh=function(e){return e==null}),qh}var kh,lA;function DP(){if(lA)return kh;lA=1;var e=CP(),t=TypeError;return kh=function(r){if(e(r))throw new t("Can't call method on "+r);return r},kh}var Bh,dA;function zH(){if(dA)return Bh;dA=1;var e=GH(),t=DP();return Bh=function(r){return e(t(r))},Bh}var Uh,fA;function Ol(){if(fA)return Uh;fA=1;var e=ua();return Uh=function(t){return typeof t=="object"?t!==null:e(t)},Uh}var Fh,pA;function jP(){return pA||(pA=1,Fh={}),Fh}var Vh,mA;function WH(){if(mA)return Vh;mA=1;var e=jP(),t=zr(),r=ua(),n=function(i){return r(i)?i:void 0};return Vh=function(i,a){return arguments.length<2?n(e[i])||n(t[i]):e[i]&&e[i][a]||t[i]&&t[i][a]},Vh}var Hh,hA;function YH(){if(hA)return Hh;hA=1;var e=es();return Hh=e({}.isPrototypeOf),Hh}var Gh,yA;function KH(){if(yA)return Gh;yA=1;var e=zr(),t=e.navigator,r=t&&t.userAgent;return Gh=r?String(r):"",Gh}var zh,gA;function JH(){if(gA)return zh;gA=1;var e=zr(),t=KH(),r=e.process,n=e.Deno,i=r&&r.versions||n&&n.version,a=i&&i.v8,s,o;return a&&(s=a.split("."),o=s[0]>0&&s[0]<4?1:+(s[0]+s[1])),!o&&t&&(s=t.match(/Edge\/(\d+)/),(!s||s[1]>=74)&&(s=t.match(/Chrome\/(\d+)/),s&&(o=+s[1]))),zh=o,zh}var Wh,_A;function $P(){if(_A)return Wh;_A=1;var e=JH(),t=oa(),r=zr(),n=r.String;return Wh=!!Object.getOwnPropertySymbols&&!t(function(){var i=Symbol("symbol detection");return!n(i)||!(Object(i)instanceof Symbol)||!Symbol.sham&&e&&e<41}),Wh}var Yh,EA;function LP(){if(EA)return Yh;EA=1;var e=$P();return Yh=e&&!Symbol.sham&&typeof Symbol.iterator=="symbol",Yh}var Kh,vA;function qP(){if(vA)return Kh;vA=1;var e=WH(),t=ua(),r=YH(),n=LP(),i=Object;return Kh=n?function(a){return typeof a=="symbol"}:function(a){var s=e("Symbol");return t(s)&&r(s.prototype,i(a))},Kh}var Jh,bA;function XH(){if(bA)return Jh;bA=1;var e=String;return Jh=function(t){try{return e(t)}catch{return"Object"}},Jh}var Xh,TA;function kP(){if(TA)return Xh;TA=1;var e=ua(),t=XH(),r=TypeError;return Xh=function(n){if(e(n))return n;throw new r(t(n)+" is not a function")},Xh}var Qh,SA;function QH(){if(SA)return Qh;SA=1;var e=kP(),t=CP();return Qh=function(r,n){var i=r[n];return t(i)?void 0:e(i)},Qh}var Zh,IA;function ZH(){if(IA)return Zh;IA=1;var e=c_(),t=ua(),r=Ol(),n=TypeError;return Zh=function(i,a){var s,o;if(a==="string"&&t(s=i.toString)&&!r(o=e(s,i))||t(s=i.valueOf)&&!r(o=e(s,i))||a!=="string"&&t(s=i.toString)&&!r(o=e(s,i)))return o;throw new n("Can't convert object to primitive value")},Zh}var xh={exports:{}},ey,RA;function xH(){return RA||(RA=1,ey=!0),ey}var ty,AA;function eG(){if(AA)return ty;AA=1;var e=zr(),t=Object.defineProperty;return ty=function(r,n){try{t(e,r,{value:n,configurable:!0,writable:!0})}catch{e[r]=n}return n},ty}var wA;function tG(){if(wA)return xh.exports;wA=1;var e=xH(),t=zr(),r=eG(),n="__core-js_shared__",i=xh.exports=t[n]||r(n,{});return(i.versions||(i.versions=[])).push({version:"3.49.0",mode:e?"pure":"global",copyright:"© 2013–2025 Denis Pushkarev (zloirock.ru), 2025–2026 CoreJS Company (core-js.io). All rights reserved.",license:"https://github.com/zloirock/core-js/blob/v3.49.0/LICENSE",source:"https://github.com/zloirock/core-js"}),xh.exports}var ry,OA;function rG(){if(OA)return ry;OA=1;var e=tG();return ry=function(t,r){return e[t]||(e[t]=r||{})},ry}var ny,NA;function nG(){if(NA)return ny;NA=1;var e=DP(),t=Object;return ny=function(r){return t(e(r))},ny}var iy,PA;function l_(){if(PA)return iy;PA=1;var e=es(),t=nG(),r=e({}.hasOwnProperty);return iy=Object.hasOwn||function(i,a){return r(t(i),a)},iy}var ay,MA;function iG(){if(MA)return ay;MA=1;var e=es(),t=0,r=Math.random(),n=e(1.1.toString);return ay=function(i){return"Symbol("+(i===void 0?"":i)+")_"+n(++t+r,36)},ay}var sy,CA;function aG(){if(CA)return sy;CA=1;var e=zr(),t=rG(),r=l_(),n=iG(),i=$P(),a=LP(),s=e.Symbol,o=t("wks"),u=a?s.for||s:s&&s.withoutSetter||n;return sy=function(l){return r(o,l)||(o[l]=i&&r(s,l)?s[l]:u("Symbol."+l)),o[l]},sy}var oy,DA;function sG(){if(DA)return oy;DA=1;var e=c_(),t=Ol(),r=qP(),n=QH(),i=ZH(),a=aG(),s=TypeError,o=a("toPrimitive");return oy=function(u,l){if(!t(u)||r(u))return u;var c=n(u,o),d;if(c){if(l===void 0&&(l="default"),d=e(c,u,l),!t(d)||r(d))return d;throw new s("Can't convert object to primitive value")}return l===void 0&&(l="number"),i(u,l)},oy}var uy,jA;function BP(){if(jA)return uy;jA=1;var e=sG(),t=qP();return uy=function(r){var n=e(r,"string");return t(n)?n:n+""},uy}var cy,$A;function oG(){if($A)return cy;$A=1;var e=zr(),t=Ol(),r=e.document,n=t(r)&&t(r.createElement);return cy=function(i){return n?r.createElement(i):{}},cy}var ly,LA;function UP(){if(LA)return ly;LA=1;var e=Mo(),t=oa(),r=oG();return ly=!e&&!t(function(){return Object.defineProperty(r("div"),"a",{get:function(){return 7}}).a!==7}),ly}var qA;function uG(){if(qA)return Mh;qA=1;var e=Mo(),t=c_(),r=HH(),n=MP(),i=zH(),a=BP(),s=l_(),o=UP(),u=Object.getOwnPropertyDescriptor;return Mh.f=e?u:function(c,d){if(c=i(c),d=a(d),o)try{return u(c,d)}catch{}if(s(c,d))return n(!t(r.f,c,d),c[d])},Mh}var dy,kA;function cG(){if(kA)return dy;kA=1;var e=oa(),t=ua(),r=/#|\.prototype\./,n=function(u,l){var c=a[i(u)];return c===o?!0:c===s?!1:t(l)?e(l):!!l},i=n.normalize=function(u){return String(u).replace(r,".").toLowerCase()},a=n.data={},s=n.NATIVE="N",o=n.POLYFILL="P";return dy=n,dy}var fy,BA;function lG(){if(BA)return fy;BA=1;var e=PP(),t=kP(),r=wl(),n=e(e.bind);return fy=function(i,a){return t(i),a===void 0?i:r?n(i,a):function(){return i.apply(a,arguments)}},fy}var py={},my,UA;function dG(){if(UA)return my;UA=1;var e=Mo(),t=oa();return my=e&&t(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42}),my}var hy,FA;function fG(){if(FA)return hy;FA=1;var e=Ol(),t=String,r=TypeError;return hy=function(n){if(e(n))return n;throw new r(t(n)+" is not an object")},hy}var VA;function pG(){if(VA)return py;VA=1;var e=Mo(),t=UP(),r=dG(),n=fG(),i=BP(),a=TypeError,s=Object.defineProperty,o=Object.getOwnPropertyDescriptor,u="enumerable",l="configurable",c="writable";return py.f=e?r?function(m,p,E){if(n(m),p=i(p),n(E),typeof m=="function"&&p==="prototype"&&"value"in E&&c in E&&!E[c]){var A=o(m,p);A&&A[c]&&(m[p]=E.value,E={configurable:l in E?E[l]:A[l],enumerable:u in E?E[u]:A[u],writable:!1})}return s(m,p,E)}:s:function(m,p,E){if(n(m),p=i(p),n(E),t)try{return s(m,p,E)}catch{}if("get"in E||"set"in E)throw new a("Accessors not supported");return"value"in E&&(m[p]=E.value),m},py}var yy,HA;function mG(){if(HA)return yy;HA=1;var e=Mo(),t=pG(),r=MP();return yy=e?function(n,i,a){return t.f(n,i,r(1,a))}:function(n,i,a){return n[i]=a,n},yy}var gy,GA;function hG(){if(GA)return gy;GA=1;var e=zr(),t=VH(),r=PP(),n=ua(),i=uG().f,a=cG(),s=jP(),o=lG(),u=mG(),l=l_(),c=function(d){var m=function(p,E,A){if(this instanceof m){switch(arguments.length){case 0:return new d;case 1:return new d(p);case 2:return new d(p,E)}return new d(p,E,A)}return t(d,this,arguments)};return m.prototype=d.prototype,m};return gy=function(d,m){var p=d.target,E=d.global,A=d.stat,R=d.proto,O=E?e:A?e[p]:e[p]&&e[p].prototype,f=E?s:s[p]||u(s,p,{})[p],v=f.prototype,b,h,T,w,P,B,J,K,z;for(w in m)b=a(E?w:p+(A?".":"#")+w,d.forced),h=!b&&O&&l(O,w),B=f[w],h&&(d.dontCallGetSet?(z=i(O,w),J=z&&z.value):J=O[w]),P=h&&J?J:m[w],!(!b&&!R&&typeof B==typeof P)&&(d.bind&&h?K=o(P,e):d.wrap&&h?K=c(P):R&&n(P)?K=r(P):K=P,(d.sham||P&&P.sham||B&&B.sham)&&u(K,"sham",!0),u(f,w,K),R&&(T=p+"Prototype",l(s,T)||u(s,T,{}),u(s[T],w,P),d.real&&v&&(b||!v[w])&&u(v,w,P)))},gy}var zA;function yG(){if(zA)return JR;zA=1;var e=hG(),t=zr();return e({global:!0,forced:t.globalThis!==t},{globalThis:t}),JR}var _y,WA;function gG(){return WA||(WA=1,yG(),_y=zr()),_y}var Ey,YA;function _G(){if(YA)return Ey;YA=1;var e=gG();return Ey=e,Ey}var KA;function FP(){if(KA)return Ci;KA=1;var e=Ci&&Ci.__importDefault||function(n){return n&&n.__esModule?n:{default:n}};Object.defineProperty(Ci,"__esModule",{value:!0}),Ci.getImplementation=void 0;var t=e(_G());function r(n,i){var a,s=(a=n[i])!==null&&a!==void 0?a:t.default[i];if(!s)throw new ReferenceError('"'+i+'" is not defined');return s}return Ci.getImplementation=r,Ci}var JA;function VP(){if(JA)return ya;JA=1;var e=ya&&ya.__values||function(o){var u=typeof Symbol=="function"&&Symbol.iterator,l=u&&o[u],c=0;if(l)return l.call(o);if(o&&typeof o.length=="number")return{next:function(){return o&&c>=o.length&&(o=void 0),{value:o&&o[c++],done:!o}}};throw new TypeError(u?"Object is not iterable.":"Symbol.iterator is not defined.")};Object.defineProperty(ya,"__esModule",{value:!0});var t=EP(),r=FP(),n="x-identity-auth-chain-",i="x-identity-timestamp",a="x-identity-metadata";function s(o){o===void 0&&(o={});var u=(0,r.getImplementation)(o,"Headers");return function(c,d,m,p,E){var A,R,O=new u(E),f=String(Date.now()),v=JSON.stringify(p),b=[d,m,f,v].join(":").toLowerCase(),h=0,T=t.Authenticator.signPayload(c,b);try{for(var w=e(T),P=w.next();!P.done;P=w.next()){var B=P.value;O.set(n+h,JSON.stringify(B)),h++}}catch(J){A={error:J}}finally{try{P&&!P.done&&(R=w.return)&&R.call(w)}finally{if(A)throw A.error}}return O.set(i,f),O.set(a,v),O}}return ya.default=s,ya}var XA;function HP(){if(XA)return xr;XA=1;var e=xr&&xr.__assign||function(){return e=Object.assign||function(s){for(var o,u=1,l=arguments.length;u<l;u++){o=arguments[u];for(var c in o)Object.prototype.hasOwnProperty.call(o,c)&&(s[c]=o[c])}return s},e.apply(this,arguments)},t=xr&&xr.__rest||function(s,o){var u={};for(var l in s)Object.prototype.hasOwnProperty.call(s,l)&&o.indexOf(l)<0&&(u[l]=s[l]);if(s!=null&&typeof Object.getOwnPropertySymbols=="function")for(var c=0,l=Object.getOwnPropertySymbols(s);c<l.length;c++)o.indexOf(l[c])<0&&Object.prototype.propertyIsEnumerable.call(s,l[c])&&(u[l[c]]=s[l[c]]);return u},r=xr&&xr.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};Object.defineProperty(xr,"__esModule",{value:!0});var n=r(VP()),i=FP();function a(s){s===void 0&&(s={});var o=(0,n.default)(s),u=(0,i.getImplementation)(s,"URL"),l=(0,i.getImplementation)(s,"Request"),c=(0,i.getImplementation)(s,"fetch");return function(m,p){if(p&&p.identity){var E=p.identity,A=p.metadata,R=t(p,["identity","metadata"]);if(typeof m=="string"||m instanceof u||globalThis.URL&&m instanceof globalThis.URL){var O=typeof m=="string"?new u(m):m,f=new l(O.toString(),e(e({},R),{headers:o(E,p.method||"GET",O.pathname,A||{},R==null?void 0:R.headers)}));return c(f)}var v=new u(m.url),b=new l(m),h=o(E,m.method||"GET",v.pathname,A||{});return h.forEach(function(T,w){b.headers.set(w,T)}),c(b)}return c(m,p)}}return xr.default=a,xr}var QA;function EG(){return QA||(QA=1,(function(e){var t=vn&&vn.__createBinding||(Object.create?(function(s,o,u,l){l===void 0&&(l=u),Object.defineProperty(s,l,{enumerable:!0,get:function(){return o[u]}})}):(function(s,o,u,l){l===void 0&&(l=u),s[l]=o[u]})),r=vn&&vn.__exportStar||function(s,o){for(var u in s)u!=="default"&&!Object.prototype.hasOwnProperty.call(o,u)&&t(o,s,u)},n=vn&&vn.__importDefault||function(s){return s&&s.__esModule?s:{default:s}};Object.defineProperty(e,"__esModule",{value:!0}),e.signedHeaderFactory=e.signedFetchFactory=void 0,r(OP(),e);var i=HP();Object.defineProperty(e,"signedFetchFactory",{enumerable:!0,get:function(){return n(i).default}});var a=VP();Object.defineProperty(e,"signedHeaderFactory",{enumerable:!0,get:function(){return n(a).default}})})(vn)),vn}var ZA;function vG(){return ZA||(ZA=1,(function(e){var t=En&&En.__createBinding||(Object.create?(function(a,s,o,u){u===void 0&&(u=o),Object.defineProperty(a,u,{enumerable:!0,get:function(){return s[o]}})}):(function(a,s,o,u){u===void 0&&(u=o),a[u]=s[o]})),r=En&&En.__exportStar||function(a,s){for(var o in a)o!=="default"&&!Object.prototype.hasOwnProperty.call(s,o)&&t(s,a,o)},n=En&&En.__importDefault||function(a){return a&&a.__esModule?a:{default:a}};Object.defineProperty(e,"__esModule",{value:!0}),r(OP(),e),r(EG(),e);var i=n(HP());e.default=(0,i.default)()})(En)),En}var bG=vG();const Nl=mw(bG);async function TG(e,t){const r=`${Dt.creditsServerUrl}/users/${e.toLowerCase()}/credits`,n=await Nl(r,{method:"GET",identity:t,metadata:{}});if(!n.ok)throw new Error(`getUserCredits ${n.status}: ${await n.text()}`);return n.json()}async function SG(e,t){const{usd:r}=await TG(e,t);return r??{balanceCents:0,credits:0}}async function F3(e,t,r){const n=`${Dt.creditsServerUrl}/credits/authorize`,i=await Nl(n,{method:"POST",identity:e,metadata:{},headers:{"Content-Type":"application/json"},body:JSON.stringify({usdPriceCents:t,tradeId:r})});if(!i.ok)throw new Error(`authorizeUsdCredit ${i.status}: ${await i.text()}`);return i.json()}async function V3(e,t,r){const n=new URLSearchParams;n.set("status","all"),n.set("limit",String(r.first)),(r==null?void 0:r.skip)!=null&&n.set("offset",String(r.skip));const i=n.toString(),a=`${Dt.creditsServerUrl}/users/${e.toLowerCase()}/purchases${i?`?${i}`:""}`,s=await Nl(a,{method:"GET",identity:t,metadata:{}});if(!s.ok)throw new Error(`fetchUserPurchases ${s.status}: ${await s.text()}`);const o=await s.json(),u=o.purchases??[],l=(r==null?void 0:r.skip)??0,c=r==null?void 0:r.first,d=typeof o.total=="number"?o.total:l+u.length+(u.length>=c?1:0);return{items:u,total:d}}async function H3(e,t){if(t.length===0)return 0;const r=`${Dt.creditsServerUrl}/credits/authorize/cancel`,n=await Nl(r,{method:"POST",identity:e,metadata:{},headers:{"Content-Type":"application/json"},body:JSON.stringify({salts:t})});if(!n.ok)throw new Error(`cancelUsdIntents ${n.status}: ${await n.text()}`);return(await n.json()).released??0}async function G3(e,t=1e3){const r=await fetch(`${Dt.creditsServerUrl}/dev/mint-usd`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({address:e.toLowerCase(),usdCents:t})});if(!r.ok)throw new Error(`devMintUsd ${r.status}: ${await r.text()}`);return r.json()}function IG(e){return tl({queryKey:["usd-balance",e==null?void 0:e.address],enabled:!!e,staleTime:3e4,queryFn:async()=>SG(e.address,e.identity)})}const RG=e=>uo(e.reduce((t,r)=>t+r.priceCredits,0)),Ra=Ro((e,t)=>({items:[],open:!1,add:(r,n="grid")=>{const i=t().items.some(s=>s.id===r.id);if(e(s=>i?{open:!0}:{items:[...s.items,r],open:!0}),i)return;const a=t().items;Ji("Shop Added To Cart",{item_id:r.itemId??null,contract_address:r.contractAddress,price_credits:r.priceCredits,price_usd:uo(r.priceCredits),is_primary:!r.tokenId,source:n,cart_size:a.length,cart_value_usd:RG(a)})},remove:r=>{const n=t().items.find(i=>i.id===r);e(i=>({items:i.items.filter(a=>a.id!==r)})),n&&Ji("Shop Removed From Cart",{item_id:n.itemId??null,cart_size:t().items.length})},clear:()=>e({items:[]}),setOpen:r=>e({open:r})})),Xi={name:"credits",nameSingular:"credit",symbol:"◈",iconClass:"ico-credits"};function z3(e){return`${e} ${e===1?Xi.nameSingular:Xi.name}`}function AG(){const e=Ra(a=>a.items),t=Ra(a=>a.open),r=Ra(a=>a.setOpen),n=Ye.useRef(null),i=e.reduce((a,s)=>a+s.priceCredits,0);return Ye.useEffect(()=>{if(!t)return;const a=setTimeout(()=>r(!1),4500),s=o=>{n.current&&!n.current.contains(o.target)&&r(!1)};return document.addEventListener("mousedown",s),()=>{clearTimeout(a),document.removeEventListener("mousedown",s)}},[t,e.length,r]),!t||e.length===0?null:fe.jsxs("div",{className:"cart-pop",ref:n,role:"dialog","aria-label":"Cart",children:[fe.jsxs("div",{className:"cart-pop__head",children:[fe.jsx("span",{className:"ico ico-cart","aria-hidden":!0})," Added to cart"]}),fe.jsx("div",{className:"cart-pop__list",children:e.slice(-4).map(a=>fe.jsxs("div",{className:"cart-pop__row",children:[fe.jsx("div",{className:"cart-pop__thumb",children:a.thumbnail?fe.jsx("img",{src:a.thumbnail,alt:a.name}):null}),fe.jsx("div",{className:"cart-pop__name",title:a.name,children:a.name}),fe.jsxs("div",{className:"cart-pop__price",children:[Xi.symbol," ",a.priceCredits]})]},a.id))}),fe.jsxs("div",{className:"cart-pop__foot",children:[fe.jsxs("span",{className:"cart-pop__total",children:[e.length," item",e.length>1?"s":""," · ",fe.jsxs("strong",{children:[Xi.symbol," ",i]})]}),fe.jsx(Gc,{className:"btn btn--purple btn--sm",to:"/cart",onClick:()=>r(!1),children:"Checkout"})]})]})}function el({className:e}){return fe.jsx("span",{className:`ico ${Xi.iconClass}${e?` ${e}`:""}`,"aria-hidden":!0})}function wG(){const{session:e,connecting:t,signIn:r,disconnect:n,restore:i}=Al(),a=e==null?void 0:e.address,{data:s,isLoading:o}=wP(a),{data:u}=IG(e),l=Ra(R=>R.items.length),c=ug(),[d,m]=Ye.useState(""),p=Ye.useRef();Ye.useEffect(()=>{i()},[i]);function E(R){c(R.trim()?`/assets?q=${encodeURIComponent(R.trim())}`:"/assets",{replace:!0})}function A(R){m(R),p.current&&clearTimeout(p.current),p.current=setTimeout(()=>E(R),300)}return fe.jsxs(fe.Fragment,{children:[fe.jsx(Lq,{activePage:"shop",isSignedIn:!!e,isSigningIn:t,isLoadingProfile:!!e&&o,address:a,avatar:s,onClickSignIn:()=>r(),onClickSignOut:()=>void n()}),fe.jsxs("div",{className:"subnav",children:[fe.jsxs("nav",{className:"subnav__tabs",children:[fe.jsx(Dn,{to:"/overview",children:"Overview"}),fe.jsx(Dn,{to:"/assets",children:"Assets"}),fe.jsx(Dn,{to:"/market",children:"Market"}),fe.jsx(Dn,{to:"/my-assets",children:"My Assets"}),fe.jsx(Dn,{to:"/my-favorites",children:"My Favorites"}),e?fe.jsx(Dn,{to:"/my-purchases",children:"My Purchases"}):null]}),fe.jsxs("div",{className:"subnav__search",children:[fe.jsx("span",{className:"ico ico-search subnav__search-ico","aria-hidden":!0}),fe.jsx("input",{value:d,placeholder:"Search item, creator, collection, name...",onChange:R=>A(R.target.value),onKeyDown:R=>{R.key==="Enter"&&(p.current&&clearTimeout(p.current),E(d))}})]}),e?fe.jsxs("span",{className:"subnav__balance",title:`Your ${Xi.name}`,children:[fe.jsx(el,{className:"subnav__balance-ico"}),(u==null?void 0:u.credits)??0]}):null,fe.jsxs(Dn,{to:"/credits",className:"subnav__credits",children:[fe.jsx(el,{className:"subnav__credits-ico"}),"Get ",Xi.name]}),fe.jsxs("div",{className:"subnav__cart-wrap",children:[fe.jsxs(Dn,{to:"/cart",className:"subnav__cart","aria-label":"Cart",children:[fe.jsx("span",{className:"ico ico-cart","aria-hidden":!0}),l>0?fe.jsx("span",{className:"subnav__cart-badge",children:l}):null]}),fe.jsx(AG,{})]})]})]})}let OG=0;const Zs=Ro(e=>({toasts:[],push:t=>{const r=++OG;return e(n=>({toasts:[...n.toasts,{...t,id:r}]})),r},dismiss:t=>e(r=>({toasts:r.toasts.filter(n=>n.id!==t)}))})),W3={success:e=>Zs.getState().push({message:e,kind:"success"}),error:e=>Zs.getState().push({message:e,kind:"error"}),info:e=>Zs.getState().push({message:e,kind:"info"})},NG={success:"✓",error:"!",info:"i"};function PG({t:e}){const t=Zs(r=>r.dismiss);return Ye.useEffect(()=>{const r=setTimeout(()=>t(e.id),4500);return()=>clearTimeout(r)},[e.id,t]),fe.jsxs("div",{className:`toast toast--${e.kind}`,role:"status",onClick:()=>t(e.id),children:[fe.jsx("span",{className:"toast__icon","aria-hidden":!0,children:NG[e.kind]}),fe.jsx("span",{className:"toast__msg",children:e.message})]})}function MG(){const e=Zs(t=>t.toasts);return e.length===0?null:fe.jsx("div",{className:"toaster","aria-live":"polite",children:e.map(t=>fe.jsx(PG,{t},t.id))})}const CG=Ye.lazy(()=>Xt(()=>import("./index-CeSnh-cF.js"),__vite__mapDeps([7,1,8,5,3,4,9])).then(e=>({default:e.WearablePreview})));function GP(e){return fe.jsx(Ye.Suspense,{fallback:null,children:fe.jsx(CG,{...e})})}function DG(){const[e,t]=Ye.useState(!1);return Ye.useEffect(()=>{if(typeof window.requestIdleCallback=="function"){const n=window.requestIdleCallback(()=>t(!0),{timeout:3e3});return()=>window.cancelIdleCallback(n)}const r=window.setTimeout(()=>t(!0),1500);return()=>window.clearTimeout(r)},[]),e?fe.jsx("div",{"aria-hidden":!0,style:{position:"fixed",left:-9999,top:-9999,width:2,height:2,opacity:0,overflow:"hidden",pointerEvents:"none"},children:fe.jsx(GP,{id:"preview-warmer",profile:"default",dev:Dt.chainId===80002,disableBackground:!0,disableFadeEffect:!0})}):null}function jG(){const e=Al(t=>t.session);Ye.useEffect(()=>{if(!e||e.providerType!==oo.ProviderType.INJECTED)return;const t=e.web3Provider.provider;if(!(t!=null&&t.on)||!t.removeListener)return;const r=e.address.toLowerCase(),n=(...i)=>{var o;((o=(i[0]??[])[0])==null?void 0:o.toLowerCase())!==r&&window.location.reload()};return t.on("accountsChanged",n),()=>{var i;return(i=t.removeListener)==null?void 0:i.call(t,"accountsChanged",n)}},[e])}const d_=`${Dt.nftApiUrl}/v1`;function zP(e){if(!e)return 0;try{return Math.ceil(Number(yw(e))*10)}catch{return 0}}function Y3(e){if(!e)return 0;try{const t=BigInt(e),r=10n**16n;return Number((t+r-1n)/r)}catch{return 0}}async function K3(e){const{listings:t}=await Pl({contractAddress:e,first:200}),r={};for(const n of t)n.listingType!=="primary"||n.itemId==null||(r[String(n.itemId)]={isOnSale:!0,priceCredits:n.priceCredits,tradeId:n.tradeId});return r}async function $G(e,t){var a;const r=new URLSearchParams({contractAddress:e,tokenId:t,first:"1"}),n=await fetch(`${d_}/nfts?${r.toString()}`);if(!n.ok)return null;const{data:i}=await n.json();return((a=i==null?void 0:i[0])==null?void 0:a.nft)??null}function WP(e){return{id:e.tradeId,tradeId:e.tradeId,name:e.name,creator:e.creator,contractAddress:e.contractAddress,itemId:e.itemId,tokenId:e.tokenId??void 0,category:e.category,wearableCategory:e.wearableCategory??void 0,rarity:e.rarity,network:e.network,chainId:e.chainId,thumbnail:e.thumbnail,priceCredits:e.priceCredits,gender:null}}async function Pl(e){var i,a;const t=new URLSearchParams;(e.category==="wearable"||e.category==="emote")&&t.set("category",e.category),e.first!=null&&t.set("first",String(e.first)),e.skip!=null&&t.set("skip",String(e.skip)),e.contractAddress&&t.set("contractAddress",e.contractAddress),e.itemId!=null&&t.set("itemId",e.itemId),(i=e.rarities)!=null&&i.length&&t.set("rarity",e.rarities.join(",")),(a=e.wearableCategories)!=null&&a.length&&t.set("wearableCategory",e.wearableCategories.join(",")),e.minPriceCredits!=null&&t.set("minPriceCredits",String(e.minPriceCredits)),e.maxPriceCredits!=null&&t.set("maxPriceCredits",String(e.maxPriceCredits)),e.search&&t.set("search",e.search),e.sortBy&&t.set("sortBy",e.sortBy);const r=await fetch(`${Dt.marketplaceServerUrl}/v3/catalog/shop?${t.toString()}`);if(!r.ok)throw new Error(`fetchShopListings ${r.status}`);const n=await r.json();return{listings:n.data??[],total:n.total??0}}async function J3(e,t){const{listings:r}=await Pl({contractAddress:e,itemId:t,first:1});return r[0]?WP(r[0]):null}async function LG({first:e=100,...t}={}){const{listings:r,total:n}=await Pl({...t,first:e});return{items:r.map(WP),total:n}}function qG(e){return{tradeId:e.tradeId,listingType:"primary",contractAddress:e.contractAddress,itemId:e.itemId??"",name:e.name??"",thumbnail:e.thumbnail??"",rarity:e.rarity??"common",category:e.category??"wearable",wearableCategory:e.wearableCategory??null,creator:e.creator??"",manaWei:e.manaWei,available:e.available??0,network:e.network??"MATIC",chainId:e.chainId??Dt.chainId,createdAt:e.createdAt??0}}async function X3({first:e=100,...t}={}){var s,o;const r=new URLSearchParams;(t.category==="wearable"||t.category==="emote")&&r.set("category",t.category),r.set("first",String(e)),t.skip!=null&&r.set("skip",String(t.skip)),(s=t.rarities)!=null&&s.length&&r.set("rarity",t.rarities.join(",")),(o=t.wearableCategories)!=null&&o.length&&r.set("wearableCategory",t.wearableCategories.join(",")),t.search&&r.set("search",t.search),t.sortBy&&r.set("sortBy",t.sortBy);const n=await fetch(`${Dt.marketplaceServerUrl}/v3/catalog/legacy?${r.toString()}`);if(!n.ok)throw new Error(`fetchLegacyListings ${n.status}`);const i=await n.json(),a=i.data??[];return{items:a.map(qG),total:i.total??a.length}}async function Q3(e,{category:t="wearable",first:r=48,skip:n=0}={}){const i=new URLSearchParams({owner:e.toLowerCase(),category:t,first:String(r),skip:String(n),sortBy:"newest",orderDirection:"desc"}),a=await fetch(`${d_}/nfts?${i.toString()}`);if(!a.ok)throw new Error(`Failed to fetch assets (${a.status})`);const{data:s,total:o}=await a.json();return{assets:s.map(l=>{var c,d,m,p,E;return{id:l.nft.id,contractAddress:l.nft.contractAddress,tokenId:l.nft.tokenId,itemId:l.nft.itemId??null,name:l.nft.name,category:l.nft.category,image:l.nft.image,rarity:((d=(c=l.nft.data)==null?void 0:c.wearable)==null?void 0:d.rarity)??((p=(m=l.nft.data)==null?void 0:m.emote)==null?void 0:p.rarity),network:l.nft.network,chainId:l.nft.chainId,isOnSale:l.order!=null,listingPrice:l.order?zP(l.order.price):void 0,tradeId:(E=l.order)==null?void 0:E.tradeId}}),total:o}}const kG="dcl:marketplace";async function Z3(e,t){const{TradeService:r}=await Xt(async()=>{const{TradeService:i}=await import("./TradeService-BK-xq9ht.js");return{TradeService:i}},__vite__mapDeps([10,5,1,11,2,6]));return new r(kG,Dt.marketplaceServerUrl,()=>t).addTrade(e)}async function YP(e){const t=await fetch(`${Dt.marketplaceServerUrl}/v1/trades/${e}`);if(!t.ok)throw new Error(`fetchTrade ${t.status}`);const r=await t.json();return r.data??r}async function BG(e,t){const r=new URLSearchParams({contractAddress:e,itemId:t,first:"1"}),n=await fetch(`${d_}/items?${r.toString()}`);if(!n.ok)return null;const{data:i}=await n.json();return(i==null?void 0:i[0])??null}async function x3(e){var u,l;let t;try{t=await YP(e)}catch{return null}const r=(u=t.sent)==null?void 0:u[0],n=(l=t.received)==null?void 0:l[0],i=zP(n==null?void 0:n.amount),a=(r==null?void 0:r.contractAddress)??"",s=(r==null?void 0:r.value)??"";if(!a)return{name:"Item",thumbnail:"",credits:i,contractAddress:""};if((r==null?void 0:r.assetType)===oo.TradeAssetType.COLLECTION_ITEM){const c=await BG(a,s);return{name:(c==null?void 0:c.name)??"Item",thumbnail:(c==null?void 0:c.thumbnail)??"",credits:i,contractAddress:a,itemId:s}}const o=await $G(a,s);return{name:(o==null?void 0:o.name)??`#${s}`,thumbnail:(o==null?void 0:o.image)??"",credits:i,contractAddress:a,tokenId:s}}async function e4(e,t){var i;const{listings:r}=await Pl({contractAddress:e,itemId:t,first:1}),n=(i=r[0])==null?void 0:i.tradeId;return n?YP(n):null}const UG={};function FG(e,t){let r;try{r=e()}catch{return}return{getItem:i=>{var a;const s=u=>u===null?null:JSON.parse(u,void 0),o=(a=r.getItem(i))!=null?a:null;return o instanceof Promise?o.then(s):s(o)},setItem:(i,a)=>r.setItem(i,JSON.stringify(a,void 0)),removeItem:i=>r.removeItem(i)}}const co=e=>t=>{try{const r=e(t);return r instanceof Promise?r:{then(n){return co(n)(r)},catch(n){return this}}}catch(r){return{then(n){return this},catch(n){return co(n)(r)}}}},VG=(e,t)=>(r,n,i)=>{let a={getStorage:()=>localStorage,serialize:JSON.stringify,deserialize:JSON.parse,partialize:R=>R,version:0,merge:(R,O)=>({...O,...R}),...t},s=!1;const o=new Set,u=new Set;let l;try{l=a.getStorage()}catch{}if(!l)return e((...R)=>{console.warn(`[zustand persist middleware] Unable to update item '${a.name}', the given storage is currently unavailable.`),r(...R)},n,i);const c=co(a.serialize),d=()=>{const R=a.partialize({...n()});let O;const f=c({state:R,version:a.version}).then(v=>l.setItem(a.name,v)).catch(v=>{O=v});if(O)throw O;return f},m=i.setState;i.setState=(R,O)=>{m(R,O),d()};const p=e((...R)=>{r(...R),d()},n,i);let E;const A=()=>{var R;if(!l)return;s=!1,o.forEach(f=>f(n()));const O=((R=a.onRehydrateStorage)==null?void 0:R.call(a,n()))||void 0;return co(l.getItem.bind(l))(a.name).then(f=>{if(f)return a.deserialize(f)}).then(f=>{if(f)if(typeof f.version=="number"&&f.version!==a.version){if(a.migrate)return a.migrate(f.state,f.version);console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return f.state}).then(f=>{var v;return E=a.merge(f,(v=n())!=null?v:p),r(E,!0),d()}).then(()=>{O==null||O(E,void 0),s=!0,u.forEach(f=>f(E))}).catch(f=>{O==null||O(void 0,f)})};return i.persist={setOptions:R=>{a={...a,...R},R.getStorage&&(l=R.getStorage())},clearStorage:()=>{l==null||l.removeItem(a.name)},getOptions:()=>a,rehydrate:()=>A(),hasHydrated:()=>s,onHydrate:R=>(o.add(R),()=>{o.delete(R)}),onFinishHydration:R=>(u.add(R),()=>{u.delete(R)})},A(),E||p},HG=(e,t)=>(r,n,i)=>{let a={storage:FG(()=>localStorage),partialize:A=>A,version:0,merge:(A,R)=>({...R,...A}),...t},s=!1;const o=new Set,u=new Set;let l=a.storage;if(!l)return e((...A)=>{console.warn(`[zustand persist middleware] Unable to update item '${a.name}', the given storage is currently unavailable.`),r(...A)},n,i);const c=()=>{const A=a.partialize({...n()});return l.setItem(a.name,{state:A,version:a.version})},d=i.setState;i.setState=(A,R)=>{d(A,R),c()};const m=e((...A)=>{r(...A),c()},n,i);i.getInitialState=()=>m;let p;const E=()=>{var A,R;if(!l)return;s=!1,o.forEach(f=>{var v;return f((v=n())!=null?v:m)});const O=((R=a.onRehydrateStorage)==null?void 0:R.call(a,(A=n())!=null?A:m))||void 0;return co(l.getItem.bind(l))(a.name).then(f=>{if(f)if(typeof f.version=="number"&&f.version!==a.version){if(a.migrate)return[!0,a.migrate(f.state,f.version)];console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,f.state];return[!1,void 0]}).then(f=>{var v;const[b,h]=f;if(p=a.merge(h,(v=n())!=null?v:m),r(p,!0),b)return c()}).then(()=>{O==null||O(p,void 0),p=n(),s=!0,u.forEach(f=>f(p))}).catch(f=>{O==null||O(void 0,f)})};return i.persist={setOptions:A=>{a={...a,...A},A.storage&&(l=A.storage)},clearStorage:()=>{l==null||l.removeItem(a.name)},getOptions:()=>a,rehydrate:()=>E(),hasHydrated:()=>s,onHydrate:A=>(o.add(A),()=>{o.delete(A)}),onFinishHydration:A=>(u.add(A),()=>{u.delete(A)})},a.skipHydration||E(),p||m},GG=(e,t)=>"getStorage"in t||"serialize"in t||"deserialize"in t?((UG?"production":void 0)!=="production"&&console.warn("[DEPRECATED] `getStorage`, `serialize` and `deserialize` options are deprecated. Use `storage` option instead."),VG(e,t)):HG(e,t),zG=GG,xA=Ro()(zG(e=>({items:{},toggle:t=>e(r=>{const n={...r.items};return n[t.id]?delete n[t.id]:n[t.id]=t,{items:n}}),remove:t=>e(r=>{const n={...r.items};return delete n[t],{items:n}})}),{name:"shop-favorites"}));function WG(e){return/^0x[a-fA-F0-9]{40}$/.test(e)?`${e.slice(0,6)}…${e.slice(-4)}`:e}function YG({address:e,className:t,linkToProfile:r}){var u,l;const n=ug(),{data:i}=wP(e);if(!e)return null;const a=(i==null?void 0:i.name)||WG(e),s=(l=(u=i==null?void 0:i.avatar)==null?void 0:u.snapshots)==null?void 0:l.face256,o=fe.jsxs(fe.Fragment,{children:[s?fe.jsx("img",{className:"creator__ava",src:s,alt:"",loading:"lazy"}):fe.jsx("span",{className:"creator__ava creator__ava--ph","aria-hidden":!0}),fe.jsxs("span",{className:"creator__name",children:["By ",a]})]});return r?fe.jsx("button",{className:`creator creator--link${t?` ${t}`:""}`,title:`View ${a}`,onClick:c=>{c.stopPropagation(),n(`/creator/${e}`)},children:o}):fe.jsx("span",{className:`creator${t?` ${t}`:""}`,children:o})}function ew(e){if(!e)return"#a09ba8";try{return oo.Rarity.getColor(e.toLowerCase())}catch{return"#a09ba8"}}function KG(e){const t=e.replace("#","");if(t.length<6)return"#161518";const r=parseInt(t.slice(0,2),16),n=parseInt(t.slice(2,4),16),i=parseInt(t.slice(4,6),16);return .299*r+.587*n+.114*i>150?"#161518":"#ffffff"}const JG=120,XG=250;function QG(e){return e==="male"?"♂":e==="female"?"♀":e==="unisex"?"⚥":""}function f_(e){const{item:t}=e,r=e.mode==="market",[n,i]=Ye.useState(!1),[a,s]=Ye.useState(!1),o=Ye.useRef(),u=Ye.useRef(),l=Ra(T=>T.add),c=Ra(T=>T.items.some(w=>w.id===t.id)),d=xA(T=>T.toggle),m=xA(T=>!!T.items[t.id]),p=ug(),E=!!t.contractAddress&&!!t.itemId,A=t.tokenId??t.itemId,R=!r&&!!t.contractAddress&&!!A;function O(){R&&p(`/item/${t.contractAddress}/${A}`,{state:{item:t,tradeId:t.tradeId}})}function f(){o.current&&clearTimeout(o.current),u.current&&clearTimeout(u.current),s(!1),o.current=setTimeout(()=>i(!0),JG)}function v(){o.current&&clearTimeout(o.current),u.current&&clearTimeout(u.current),i(!1),s(!1)}function b(){u.current&&clearTimeout(u.current),u.current=setTimeout(()=>s(!0),XG)}const h=QG(t.gender);return fe.jsxs("article",{className:`card${n?" card--hover":""}`,style:R?{cursor:"pointer"}:void 0,onMouseEnter:f,onMouseLeave:v,onClick:O,role:R?"link":void 0,tabIndex:R?0:void 0,onKeyDown:R?T=>{(T.key==="Enter"||T.key===" ")&&(T.preventDefault(),O())}:void 0,children:[fe.jsxs("div",{className:"card__media",children:[fe.jsx("button",{className:`card__fav${m?" is-on":""}`,onClick:T=>{T.stopPropagation(),d(t)},"aria-label":m?"Remove from favorites":"Add to favorites",children:fe.jsx("span",{className:"ico ico-heart","aria-hidden":!0})}),t.thumbnail?fe.jsx("img",{className:`card__img${n&&a?" card__img--hidden":""}`,src:t.thumbnail,alt:t.name,loading:"lazy"}):null,n&&E?fe.jsxs(fe.Fragment,{children:[fe.jsx("div",{className:`card__preview${a?" is-ready":""}`,children:fe.jsx(GP,{contractAddress:t.contractAddress,itemId:t.itemId??void 0,profile:"default",dev:Dt.chainId===80002,disableBackground:!0,disableFadeEffect:!0,onLoad:b})}),fe.jsx("span",{className:"card__preview-shield","aria-hidden":!0}),a?null:fe.jsx("span",{className:"card__loadbar","aria-hidden":!0})]}):null]}),fe.jsxs("div",{className:"card__body",children:[fe.jsx("div",{className:"card__name",title:t.name,children:t.name}),t.creator?fe.jsx(YG,{address:t.creator,className:"card__creator",linkToProfile:!0}):fe.jsx("div",{className:"card__creator",children:" "}),n?r&&e.mode==="market"?fe.jsx("button",{className:"card__cart",onClick:T=>{T.stopPropagation(),e.onBuyNow(t)},disabled:e.marketPriceCredits==null,children:e.marketPriceCredits==null?"UNAVAILABLE":"BUY NOW"}):fe.jsxs("button",{className:`card__cart${c?" is-in":""}`,onClick:T=>{T.stopPropagation(),l(t,"grid")},disabled:c,children:[fe.jsx("span",{className:"ico ico-cart-solid card__cart-ico","aria-hidden":!0}),c?"IN CART":"ADD TO CART"]}):fe.jsxs("div",{className:"card__meta",children:[r&&e.mode==="market"?fe.jsxs("div",{className:"card__price card__price--market",children:[fe.jsx("span",{className:"card__approx","aria-hidden":!0,children:"≈"}),fe.jsx(el,{className:"card__diamond"}),e.marketPriceCredits==null?"—":e.marketPriceCredits,fe.jsx("span",{className:"chip card__market-chip",children:"Market price"})]}):fe.jsxs("div",{className:"card__price",children:[fe.jsx(el,{className:"card__diamond"}),t.priceCredits]}),fe.jsxs("div",{className:"card__chips",children:[fe.jsx("span",{className:"chip chip--rarity",style:{background:ew(t.rarity),color:KG(ew(t.rarity))},children:t.rarity}),t.category==="wearable"?fe.jsx("span",{className:"chip chip--icon",children:fe.jsx("span",{className:"ico ico-eyewear","aria-hidden":!0})}):null,h?fe.jsx("span",{className:"chip chip--icon",children:h}):null]})]})]})]})}function ZG(e){if(!e)return 0;try{return Math.ceil(Number(yw(e))*10)}catch{return 0}}function xG(e){if(!e||e.length===0)return null;const t=e.some(n=>n.includes("Male")),r=e.some(n=>n.includes("Female"));return t&&r?"unisex":t?"male":r?"female":null}function KP(e){var t,r,n,i,a,s;return{id:e.id,name:e.name,creator:e.creator??"",contractAddress:e.contractAddress,itemId:e.itemId??null,category:e.category,wearableCategory:((r=(t=e.data)==null?void 0:t.wearable)==null?void 0:r.category)??((i=(n=e.data)==null?void 0:n.emote)==null?void 0:i.category),rarity:e.rarity??"common",network:e.network,chainId:e.chainId,thumbnail:e.thumbnail??"",priceCredits:ZG(e.price??e.minPrice),gender:xG((s=(a=e.data)==null?void 0:a.wearable)==null?void 0:s.bodyShapes)}}async function t4(e,{first:t=20,skip:r=0}={}){const n=new URLSearchParams({contractAddress:e,first:String(t),skip:String(r),includeSocialEmotes:"false"}),i=await fetch(`${Dt.nftApiUrl}/v1/items?${n.toString()}`);if(!i.ok)throw new Error(`fetchCollectionItems ${i.status}`);const{data:a,total:s}=await i.json(),o=(a??[]).map(KP);return{items:o,total:s??r+o.length}}async function e3(e,{first:t=60,skip:r=0}={}){const n=new URLSearchParams({creator:e,first:String(t),skip:String(r),includeSocialEmotes:"false"}),i=await fetch(`${Dt.nftApiUrl}/v1/items?${n.toString()}`);if(!i.ok)throw new Error(`fetchCreatorItems ${i.status}`);const{data:a,total:s}=await i.json(),o=(a??[]).map(KP);return{items:o,total:s??r+o.length}}const JP="shop:followed-creators:v1",t3=200;function r3(){try{const e=localStorage.getItem(JP);if(!e)return[];const t=JSON.parse(e);return Array.isArray(t)?t.filter(r=>typeof r=="string"):[]}catch{return[]}}function tw(e){try{localStorage.setItem(JP,JSON.stringify(e))}catch{}}const n3=Ro((e,t)=>({followed:r3(),isFollowing:r=>t().followed.includes(r.toLowerCase()),follow:r=>{const n=r.toLowerCase();if(!n||t().followed.includes(n))return;const i=[n,...t().followed].slice(0,t3);tw(i),e({followed:i}),Ji("Shop Followed Creator",{creator_address:n,following_count:i.length})},unfollow:r=>{const n=r.toLowerCase();if(!t().followed.includes(n))return;const i=t().followed.filter(a=>a!==n);tw(i),e({followed:i}),Ji("Shop Unfollowed Creator",{creator_address:n,following_count:i.length})},toggle:r=>t().isFollowing(r)?t().unfollow(r):t().follow(r)})),i3=8,a3=8,s3=12;function o3(){const t=n3(i=>i.followed).slice(0,i3),{data:r=[],isLoading:n}=tl({queryKey:["followed-creators-row",t.join(",")],enabled:t.length>0,queryFn:async()=>{const i=await Promise.all(t.map(a=>e3(a,{first:a3}).then(s=>s.items).catch(()=>[])));return u3(i).filter(a=>a.priceCredits>0).slice(0,s3)}});return t.length===0||!n&&r.length===0?null:fe.jsxs("section",{className:"row",children:[fe.jsx("div",{className:"row__head",children:fe.jsx("h2",{className:"row__title",children:"From creators you follow"})}),fe.jsx("div",{className:"row__track",children:n?Array.from({length:6}).map((i,a)=>fe.jsx("div",{className:"card card--skeleton"},a)):r.map(i=>fe.jsx(f_,{item:i},i.id))})]})}function u3(e){const t=[],r=new Set,n=e.reduce((i,a)=>Math.max(i,a.length),0);for(let i=0;i<n;i++)for(const a of e){const s=a[i];s&&!r.has(s.id)&&(r.add(s.id),t.push(s))}return t}const XP="shop:recently-viewed",QP=12;function ZP(){try{const e=localStorage.getItem(XP);if(!e)return[];const t=JSON.parse(e);return Array.isArray(t)?t.slice(0,QP):[]}catch{return[]}}function r4(e){if(e!=null&&e.id)try{const t=[e,...ZP().filter(r=>r.id!==e.id)].slice(0,QP);localStorage.setItem(XP,JSON.stringify(t))}catch{}}function c3({excludeId:e}){const t=Ye.useMemo(()=>ZP().filter(r=>r.id!==e),[e]);return t.length===0?null:fe.jsxs("section",{className:"row",children:[fe.jsx("div",{className:"row__head",children:fe.jsx("h2",{className:"row__title",children:"Recently viewed"})}),fe.jsx("div",{className:"row__track",children:t.map(r=>fe.jsx(f_,{item:r},r.id))})]})}function rw({title:e,items:t,loading:r}){return fe.jsxs("section",{className:"row",children:[fe.jsxs("div",{className:"row__head",children:[fe.jsx("h2",{className:"row__title",children:e}),fe.jsxs(Gc,{className:"row__viewall",to:"/assets",children:["VIEW ALL ",fe.jsx("span",{className:"ico ico-viewall","aria-hidden":!0})]})]}),fe.jsx("div",{className:"row__track",children:r?Array.from({length:6}).map((n,i)=>fe.jsx("div",{className:"card card--skeleton"},i)):t.map(n=>fe.jsx(f_,{item:n},n.id))})]})}function l3(){const{data:e,isLoading:t}=tl({queryKey:["overview-listings"],queryFn:()=>LG({first:24})}),r=(e==null?void 0:e.items)??[];return fe.jsxs("div",{className:"overview",children:[fe.jsx("section",{className:"hero",children:fe.jsxs("div",{className:"hero__inner",children:[fe.jsx("h1",{className:"hero__title",children:"FASHION WEEK OUTFITS"}),fe.jsx(Gc,{className:"btn btn--purple",to:"/assets",children:"EXPLORE COLLECTION"})]})}),fe.jsx(o3,{}),fe.jsx(c3,{}),t||r.length>0?fe.jsxs(fe.Fragment,{children:[fe.jsx(rw,{title:"Featured",items:r.slice(0,12),loading:t}),r.length>6?fe.jsx(rw,{title:"New Creations",items:r.slice(6,18),loading:!1}):null]}):fe.jsxs("div",{className:"overview__empty",children:[fe.jsx("p",{className:"overview__empty-title",children:"New drops are on the way"}),fe.jsx("p",{className:"muted",children:"There are no items on sale right now — check back soon."}),fe.jsx(Gc,{className:"btn btn--purple",to:"/assets",children:"Browse the shop"})]})]})}const d3={"/overview":"overview","/assets":"assets","/market":"market","/my-assets":"my_assets","/my-favorites":"favorites","/my-purchases":"my_purchases","/import":"import","/cart":"cart","/credits":"credits","/success":"success"},f3=Ye.lazy(()=>Xt(()=>import("./Assets-FMrABFH_.js"),__vite__mapDeps([12,1,13,14,15,5])).then(e=>({default:e.Assets}))),p3=Ye.lazy(()=>Xt(()=>import("./Market-Cr-J1I9u.js"),__vite__mapDeps([16,1,17,11,5,13,14,18,19,15])).then(e=>({default:e.Market}))),m3=Ye.lazy(()=>Xt(()=>import("./ItemDetail-Sn2B-MA3.js"),__vite__mapDeps([20,1,18,11,5,19,21])).then(e=>({default:e.ItemDetail}))),h3=Ye.lazy(()=>Xt(()=>import("./Collection-DJjtkyI0.js"),__vite__mapDeps([22,1,23,24,13,14,15,5])).then(e=>({default:e.Collection}))),y3=Ye.lazy(()=>Xt(()=>import("./Creator-Cd6xMnQk.js"),__vite__mapDeps([25,1,23,24,13,14,15,5])).then(e=>({default:e.Creator}))),g3=Ye.lazy(()=>Xt(()=>import("./MyAssets-CpoF2iAy.js"),__vite__mapDeps([26,1,27,18,11,5,17,28,14,15,29])).then(e=>({default:e.MyAssets}))),_3=Ye.lazy(()=>Xt(()=>import("./MyFavorites-b3vHnYMr.js"),__vite__mapDeps([30,1,14,5])).then(e=>({default:e.MyFavorites}))),E3=Ye.lazy(()=>Xt(()=>import("./MyPurchases-DVXmppAu.js"),__vite__mapDeps([31,1,14,15,5])).then(e=>({default:e.MyPurchases}))),v3=Ye.lazy(()=>Xt(()=>import("./ImportListings-CXvHkADP.js"),__vite__mapDeps([32,1,27,18,11,5,17,28,33])).then(e=>({default:e.ImportListings}))),b3=Ye.lazy(()=>Xt(()=>import("./Cart-COyAPJn1.js"),__vite__mapDeps([34,1,18,11,5,19])).then(e=>({default:e.Cart}))),T3=Ye.lazy(()=>Xt(()=>import("./GetCredits-BC7Z51_v.js"),__vite__mapDeps([35,1,9,4,5])).then(e=>({default:e.GetCredits}))),S3=Ye.lazy(()=>Xt(()=>import("./Success-CNdczbFT.js"),__vite__mapDeps([36,1,28,5])).then(e=>({default:e.Success}))),I3=Ye.lazy(()=>Xt(()=>import("./NotFound-BK3mhtdy.js"),__vite__mapDeps([37,1])).then(e=>({default:e.NotFound})));function R3(){return fe.jsx("div",{className:"page-loading","aria-busy":"true",children:fe.jsx("span",{className:"spinner","aria-hidden":!0})})}function A3(){return fe.jsxs("div",{className:"overview__empty",children:[fe.jsx("p",{className:"overview__empty-title",children:"Something went wrong"}),fe.jsx("p",{className:"muted",children:"This page hit an unexpected error. Try reloading."}),fe.jsx("button",{className:"btn btn--purple",onClick:()=>window.location.reload(),children:"Reload"})]})}function w3(){jG();const e=pM();return Ye.useEffect(()=>{CH()},[]),Ye.useEffect(()=>{const t=e.pathname,r=d3[t]??(t.startsWith("/item/")?"item":t.startsWith("/collection/")?"collection":t.startsWith("/creator/")?"creator":"other");OH(r)},[e.pathname]),fe.jsxs(fe.Fragment,{children:[fe.jsx(MG,{}),fe.jsx(DG,{}),fe.jsx(wG,{}),fe.jsx("main",{className:"page",children:fe.jsx(Lg,{fallback:fe.jsx(A3,{}),children:fe.jsx(Ye.Suspense,{fallback:fe.jsx(R3,{}),children:fe.jsxs(mM,{children:[fe.jsx(sr,{path:"/",element:fe.jsx(hM,{to:"/overview",replace:!0})}),fe.jsx(sr,{path:"/overview",element:fe.jsx(l3,{})}),fe.jsx(sr,{path:"/assets",element:fe.jsx(f3,{})}),fe.jsx(sr,{path:"/market",element:fe.jsx(p3,{})}),fe.jsx(sr,{path:"/item/:contractAddress/:tokenId",element:fe.jsx(m3,{})}),fe.jsx(sr,{path:"/collection/:contractAddress",element:fe.jsx(h3,{})}),fe.jsx(sr,{path:"/creator/:address",element:fe.jsx(y3,{})}),fe.jsx(sr,{path:"/my-assets",element:fe.jsx(g3,{})}),fe.jsx(sr,{path:"/my-favorites",element:fe.jsx(_3,{})}),fe.jsx(sr,{path:"/my-purchases",element:fe.jsx(E3,{})}),fe.jsx(sr,{path:"/import",element:fe.jsx(v3,{})}),fe.jsx(sr,{path:"/cart",element:fe.jsx(b3,{})}),fe.jsx(sr,{path:"/credits",element:fe.jsx(T3,{})}),fe.jsx(sr,{path:"/success",element:fe.jsx(S3,{})}),fe.jsx(sr,{path:"*",element:fe.jsx(I3,{})})]})})})})]})}BH();const O3=new GM({defaultOptions:{queries:{staleTime:3e4,refetchOnWindowFocus:!1}}});yM.createRoot(document.getElementById("root")).render(fe.jsx(hw.StrictMode,{children:fe.jsx(WM,{client:O3,children:fe.jsx(gM,{children:fe.jsx(w3,{})})})}));export{$U as $,f_ as A,cb as B,Xi as C,n3 as D,e3 as E,el as F,W3 as G,z3 as H,X3 as I,j3 as J,D3 as K,nC as L,C3 as M,Nl as N,G3 as O,wP as P,qM as Q,k3 as R,r4 as S,J3 as T,Q3 as U,K3 as V,GP as W,OV as X,un as Y,Vr as Z,Xt as _,YG as a,bG as a0,No as a1,Zg as a2,cF as a3,KU as a4,Fg as a5,gN as a6,_N as a7,t4 as b,Al as c,V3 as d,tl as e,LG as f,x3 as g,YP as h,Dt as i,Ra as j,IG as k,zM as l,uo as m,e4 as n,F3 as o,Z3 as p,B3 as q,U3 as r,WR as s,Ji as t,xA as u,PH as v,H3 as w,Y3 as x,oo as y,Fr as z};
|