@dcl/shop 0.1.0-28749696583.commit-1ceed46 → 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-aLMhp0dt.js → Assets-FMrABFH_.js} +1 -1
- package/assets/{Cart-De2Zl3dM.js → Cart-COyAPJn1.js} +1 -1
- package/assets/{CircularProgress-zG5DpGEk.js → CircularProgress-ePyo1lbd.js} +1 -1
- package/assets/{Collection-D2tlaWRj.js → Collection-DJjtkyI0.js} +1 -1
- package/assets/{Creator-nG5HN86G.js → Creator-Cd6xMnQk.js} +1 -1
- package/assets/{ExchangeController-DxQ_hnpn.js → ExchangeController-AR7AXGzp.js} +1 -1
- package/assets/{GetCredits-Dpbjid38.js → GetCredits-BC7Z51_v.js} +2 -2
- package/assets/{HelpersUtil-CE2js2MR.js → HelpersUtil-PrvulZLQ.js} +1 -1
- package/assets/{ImportListings-CJDBHXeE.js → ImportListings-CXvHkADP.js} +1 -1
- package/assets/{ItemDetail-8nTYzMUv.js → ItemDetail-Sn2B-MA3.js} +1 -1
- package/assets/{Market-D5ojlVRL.js → Market-Cr-J1I9u.js} +1 -1
- package/assets/{MyAssets-D9VUj3Zr.js → MyAssets-CpoF2iAy.js} +1 -1
- package/assets/{MyFavorites-DeEu4CEV.js → MyFavorites-b3vHnYMr.js} +1 -1
- package/assets/{MyPurchases-DvIbgEFO.js → MyPurchases-DVXmppAu.js} +1 -1
- package/assets/{RealCheckout-DW__EYhq.js → RealCheckout-DO6nD-rf.js} +1 -1
- package/assets/{Success-B3A8ZBjK.js → Success-CNdczbFT.js} +1 -1
- package/assets/{SvgIcon-Bf8o-Oh9.js → SvgIcon-D2AubmSV.js} +1 -1
- package/assets/{SwapController-442j5gZT.js → SwapController-DTKDtDuh.js} +1 -1
- package/assets/{TradeService-Bis1RE0m.js → TradeService-BK-xq9ht.js} +1 -1
- package/assets/{W3MFrameProviderSingleton-BSVX-6L0.js → W3MFrameProviderSingleton-DxZDURuu.js} +3 -3
- package/assets/{WebCryptoP256-bcQGKg-7.js → WebCryptoP256-DslKERu3.js} +1 -1
- package/assets/{basic-DON-N1CW.js → basic-ClTZjNQz.js} +1 -1
- package/assets/{biconomy-CzjuLXKA.js → biconomy-BVk_afT2.js} +1 -1
- package/assets/{buy-5130Im35.js → buy-_5Wro-EH.js} +1 -1
- package/assets/{buy-gasless-CAFJBEcY.js → buy-gasless-Da6cXp5w.js} +1 -1
- package/assets/{ccip-Be3XfiR-.js → ccip-99AVWMCb.js} +1 -1
- package/assets/{ccip-C1VLZjOC.js → ccip-JE6ul9xT.js} +1 -1
- package/assets/{collection-BTAfnBAO.js → collection-Dj1PGTaS.js} +1 -1
- package/assets/{controller-BtovDqDB.js → controller-C8G19uhk.js} +2 -2
- package/assets/{core-CZtd-NIi.js → core-CyJXDVbu.js} +4 -4
- package/assets/{custom-BwG_UShl.js → custom-Cjf2UWeN.js} +1 -1
- package/assets/{data-capture-eO7T9U30.js → data-capture-Byx93Q11.js} +1 -1
- package/assets/{decimals-ChKIkXOS.js → decimals-CTfzGzBe.js} +1 -1
- package/assets/decimals-nJOPAX3f.js +1 -0
- package/assets/{detectExtension-tc_ts8l0.js → detectExtension-D3zYez7t.js} +1 -1
- package/assets/{email-Stqivzcj.js → email-DPOB-SWJ.js} +1 -1
- package/assets/{embedded-wallet-DCapk4p8.js → embedded-wallet-CHJsBta2.js} +1 -1
- package/assets/{engine-DUpcMxaF.js → engine-Bnqy1EVE.js} +1 -1
- package/assets/{estimate-l1-fee-CLHdzsZf.js → estimate-l1-fee-Bl4TKlfd.js} +1 -1
- package/assets/{eth_estimateGas-C29fayI3.js → eth_estimateGas-C6gJZO0T.js} +1 -1
- package/assets/{eth_getStorageAt-CLFvCDZd.js → eth_getStorageAt-3NgDSjye.js} +1 -1
- package/assets/{eth_getTransactionCount-CI8xyokV.js → eth_getTransactionCount-DTwTbWKm.js} +1 -1
- package/assets/{extractIPFS-BGsgU6Dq.js → extractIPFS-CHWW_nBy.js} +1 -1
- package/assets/{features-BVeS0JHV.js → features-HqCYMdFT.js} +1 -1
- package/assets/{fetchTokenMetadata-BLzsI7EC.js → fetchTokenMetadata-CSZ3XllS.js} +2 -2
- package/assets/{generateUtilityClasses-B28mC2Si.js → generateUtilityClasses-68H80U2m.js} +1 -1
- package/assets/{get-ecosystem-wallet-info-R5ARh3Yl.js → get-ecosystem-wallet-info-CVCd4sza.js} +1 -1
- package/assets/{getBalance-BSCY52PD.js → getBalance-yfGcZGGj.js} +1 -1
- package/assets/{getInstalledModules-BS7IiWOH.js → getInstalledModules-DnAA6-I4.js} +1 -1
- package/assets/{getNFT-BK5_-4hT.js → getNFT-BXj9XpaA.js} +1 -1
- package/assets/{getNFT-BwgDFGMN.js → getNFT-vDogDybV.js} +2 -2
- package/assets/{hashTypedData-q9oxx1xt.js → hashTypedData-2doJmUR6.js} +1 -1
- package/assets/{hashTypedData-Cq89-tTo.js → hashTypedData-DaDegzDr.js} +1 -1
- package/assets/{import-8mZnlxOL.js → import-BEVHrqgg.js} +1 -1
- package/assets/{in-app-wallet-calls-DloE1FT2.js → in-app-wallet-calls-C42NJm8M.js} +1 -1
- package/assets/{index-CFdMT9MW.js → index-0AAKBJxH.js} +2 -2
- package/assets/{index-Cs_2iQ3W.js → index-57ur9orY.js} +1 -1
- package/assets/{index-BIzLuINV.js → index-9ge8OUDw.js} +1 -1
- package/assets/{index-BDUVlNpj.js → index-B4bWwh_Y.js} +1 -1
- package/assets/{index-D2dWLs9-.js → index-B9SF-7gB.js} +1 -1
- package/assets/{index-BOcZHHVN.js → index-BG6CN-s7.js} +1 -1
- package/assets/{index-D6jW0QuZ.js → index-BREuBgY2.js} +1 -1
- package/assets/{index-CaaeFuGL.js → index-BVLuv2om.js} +1 -1
- package/assets/{index-BVm65sSQ.js → index-BYlyICGz.js} +1 -1
- package/assets/{index-BF4emFry.js → index-BaKOKooW.js} +1 -1
- package/assets/{index-Dp-0pAj4.js → index-BeD0ry83.js} +1 -1
- package/assets/{index-iF9kiYoZ.js → index-BhzLlo1O.js} +1 -1
- package/assets/{index-CuKnEc0t.js → index-BlH2P_nz.js} +1 -1
- package/assets/{index-Cgp0c25G.js → index-Blv3Wwvz.js} +1 -1
- package/assets/{index-B0pKs-hj.js → index-Bme3obuL.js} +1 -1
- package/assets/{index-DO5kbyL5.js → index-BqkfR3e1.js} +3 -3
- package/assets/{index-C24A9Q_B.js → index-BuPAm941.js} +1 -1
- package/assets/{index-ufiEiZ1d.js → index-Bx92bjWv.js} +1 -1
- package/assets/{index-BD27OB6Q.js → index-C0zr56Qh.js} +1 -1
- package/assets/{index-ZrYHq_rN.js → index-C9WCBveU.js} +1 -1
- package/assets/{index-Ck7C_Qc5.js → index-CB1SUuBM.js} +4 -4
- package/assets/{index-CYxyFUAy.js → index-CDrsSYcA.js} +1 -1
- package/assets/{index-BJxTr96X.js → index-COwpweqw.js} +1 -1
- package/assets/{index-BeFu8hpI.js → index-CRHmObgS.js} +1 -1
- package/assets/{index-DaDPmmBo.js → index-CRiIcVpU.js} +1 -1
- package/assets/{index-B9O7lhLw.js → index-CX7ndFAa.js} +1 -1
- package/assets/{index-BLKJ4eEO.js → index-CbVF1v4U.js} +1 -1
- package/assets/{index-BxSPmv0Y.js → index-CeSnh-cF.js} +1 -1
- package/assets/{index-DM4yPO68.js → index-Chh2iu1U.js} +1 -1
- package/assets/{index-C-jpz5Fa.js → index-CnBS8kzN.js} +1 -1
- package/assets/{index-CjaxrxzI.js → index-CtFbxl_y.js} +1 -1
- package/assets/{index-BE2OdG3f.js → index-Cuo0mhpq.js} +1 -1
- package/assets/{index-DacoqM69.js → index-D7XhLBQ-.js} +1 -1
- package/assets/{index-D-Kw_wUy.js → index-D8ALyBMQ.js} +1 -1
- package/assets/{index-Dm3nVmD3.js → index-DFAtvbN5.js} +1 -1
- package/assets/{index-C0RsmTxE.js → index-DFB_iIuz.js} +1 -1
- package/assets/{index-D58Lm6fy.js → index-DKewLOZ7.js} +1 -1
- package/assets/{index-aWPj5LNH.js → index-DXbLCZL4.js} +1 -1
- package/assets/{index-D6G1eVBw.js → index-DiHK-ypD.js} +1 -1
- package/assets/{index-DIMb2qTx.js → index-DiX8jfOz.js} +1 -1
- package/assets/{index-BAgLTJQC.js → index-Dn9Pxudm.js} +1 -1
- package/assets/{index-DnXaf_28.js → index-DprMjbvv.js} +1 -1
- package/assets/{index-CcZ_aO1r.js → index-Dw8xiBHu.js} +1 -1
- package/assets/{index-BsL6EcA1.js → index-DyGFvyMP.js} +3 -3
- package/assets/{index-C7dh-AbD.js → index-POoM1fB4.js} +2 -2
- package/assets/{index-Bj6vwNIk.js → index-RnHbMsps.js} +1 -1
- package/assets/{index-DWGjNbEm.js → index-VT1wNEWr.js} +1 -1
- package/assets/{index-CCidLmBj.js → index-ZNqzZwnz.js} +1 -1
- package/assets/{index-BydDLvNI.js → index-e_7-B1ow.js} +1 -1
- package/assets/{index-8vuqXajV.js → index-j3O81hit.js} +2 -2
- package/assets/{index-CzK1bz00.js → index-jaAvXNFF.js} +1 -1
- package/assets/{index.es-WIKYy9BI.js → index.es-BCgpKnhB.js} +1 -1
- package/assets/{index.es-BHmJ3HE8.js → index.es-DLOLLwhc.js} +1 -1
- package/assets/{index.es-AvZc0iwU.js → index.es-uQUz0uPi.js} +4 -4
- package/assets/{localBatchGatewayRequest-DAEYAZDW.js → localBatchGatewayRequest-DCKNeCfz.js} +1 -1
- package/assets/{mana-rate-Cj4WJyFX.js → mana-rate-Boaa1HMt.js} +1 -1
- package/assets/network-C9miAzGt.js +1 -0
- package/assets/{networks-eeU54tZ7.js → networks-D0pJRUuY.js} +1 -1
- package/assets/{onramp-DhSiFszx.js → onramp-pQdY_9aS.js} +1 -1
- package/assets/{openzeppelin-TUhCXc3W.js → openzeppelin-diCOMn_P.js} +1 -1
- package/assets/{ownerOf-DU-JKoHi.js → ownerOf-CFYID7oD.js} +1 -1
- package/assets/{parseNft-BvVevHMp.js → parseNft-CmySAMrV.js} +2 -2
- package/assets/{parseSignature-CqBaxebK.js → parseSignature-bCWekXGm.js} +1 -1
- package/assets/{parseSignature-fzdlClLS.js → parseSignature-t4gfdMWw.js} +3 -3
- package/assets/{pay-with-exchange-CcXMWyyR.js → pay-with-exchange-DbEbHfpX.js} +1 -1
- package/assets/{qr-overlay-CoU3_96F.js → qr-overlay-rU0bVDln.js} +1 -1
- package/assets/{receive-DlVMqTPT.js → receive-C22Daqnd.js} +1 -1
- package/assets/{resolveImplementation-DTf71Ha-.js → resolveImplementation-DynwR0lM.js} +1 -1
- package/assets/{rpc-qmK5iTzE.js → rpc-C7dS7ng8.js} +1 -1
- package/assets/{secp256k1-xb6034EE.js → secp256k1-DcKiXZY-.js} +1 -1
- package/assets/{secp256k1-nA5uVAYh.js → secp256k1-DoZorCJw.js} +1 -1
- package/assets/{secp256k1-DFuDr3b6.js → secp256k1-DznyzAlp.js} +1 -1
- package/assets/{send-u3ctJaL6.js → send-DYQ25bRQ.js} +1 -1
- package/assets/{send-batch-transaction-BFEKzC9O.js → send-batch-transaction-EluRyTwS.js} +1 -1
- package/assets/{send-eip712-transaction-BQihd29J.js → send-eip712-transaction-DTR4eE0C.js} +2 -2
- package/assets/{send-gasless-transaction-BqA4bIvc.js → send-gasless-transaction-oXMw6C-s.js} +2 -2
- package/assets/{sendRawTransaction-C8j0qQ9e.js → sendRawTransaction-BU7jVR59.js} +3 -3
- package/assets/{serializeTransaction-Dz4GBhoh.js → serializeTransaction-yZGwGRzm.js} +1 -1
- package/assets/{session-proposal-Db4KYIHa.js → session-proposal-BwNkG3_v.js} +1 -1
- package/assets/{session-request-CihuU88c.js → session-request-CBPwxxaY.js} +2 -2
- package/assets/{sha256-CgtTKrQj.js → sha256-Dh2CN2ka.js} +1 -1
- package/assets/{signing-BpshFomj.js → signing-GS-zzaze.js} +4 -4
- package/assets/{socials-CVrxuzLr.js → socials-D941TnMp.js} +1 -1
- package/assets/{swaps-BgpJ5WXk.js → swaps-5Z0exdjC.js} +1 -1
- package/assets/{thirdweb-CYxasBJb.js → thirdweb-BhSo-VaG.js} +3 -3
- package/assets/{totalSupply-B1JXRs3G.js → totalSupply-Dn2mGU3K.js} +1 -1
- package/assets/{transactionReceipt-C76rMl4n.js → transactionReceipt-DXzK83SA.js} +1 -1
- package/assets/{transactions-4VkJkzU5.js → transactions-BB8fY56R.js} +1 -1
- package/assets/{useInfiniteGrid-DWCJkphW.js → useInfiniteGrid-BdBxLsy8.js} +1 -1
- package/assets/{verifyHash-ETsOfWG5.js → verifyHash-DcUfBKkE.js} +1 -1
- package/assets/{w3m-modal-DnfQqgSb.js → w3m-modal-B_8aqWPZ.js} +1 -1
- package/assets/{w3m-modal-Dsohngdn.js → w3m-modal-C2IuKDb_.js} +1 -1
- package/assets/{wait-for-tx-receipt-B7QM3M94.js → wait-for-tx-receipt-DYUfif7J.js} +1 -1
- package/assets/{wallet-kind-B1XTGpW3.js → wallet-kind-I4wsazAy.js} +1 -1
- package/assets/{wallets-Bvy8SYUi.js → wallets-BCm8dv3V.js} +6 -6
- package/assets/{web-connector-D7aGkNQq.js → web-connector-PEOwt9A9.js} +3 -3
- package/assets/{writeContract-B9ry2Fzp.js → writeContract-KYMfI9ra.js} +1 -1
- package/assets/{zoraTestnet-CbeIIuai.js → zoraTestnet-DOA24Pam.js} +1 -1
- package/index.html +8 -8
- package/package.json +2 -2
- package/assets/decimals-CP_7HUio.js +0 -1
- package/assets/network-BWxaW3rR.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{r as k}from"./index-BV8s6ez1.js";import{az as w}from"./sendRawTransaction-
|
|
1
|
+
import{r as k}from"./index-BV8s6ez1.js";import{az as w}from"./sendRawTransaction-BU7jVR59.js";import{c as I,e as q}from"./hashTypedData-DaDegzDr.js";import"./NetworkUtil-CSluj-ND.js";import"./ethers-DbXGgxrh.js";import"./react-E8ng6RF2.js";import"./index-CB1SUuBM.js";const v=()=>"9.1.0",C=t=>t.toString(16).padStart(2,"0"),R=t=>{const e=new Uint8Array(t/2);return window.crypto.getRandomValues(e),Array.from(e,C).join("")},E=()=>typeof window<"u"?R(10):new Date().getTime().toString(36);class g{}g.makeRequest=(t,e)=>({id:E(),method:t,params:e,env:{sdkVersion:v()}});g.makeResponse=(t,e,s)=>({id:t,success:!0,version:s,data:e});g.makeErrorResponse=(t,e,s)=>({id:t,success:!1,error:e,version:s});var r;(function(t){t.sendTransactions="sendTransactions",t.rpcCall="rpcCall",t.getChainInfo="getChainInfo",t.getSafeInfo="getSafeInfo",t.getTxBySafeTxHash="getTxBySafeTxHash",t.getSafeBalances="getSafeBalances",t.signMessage="signMessage",t.signTypedMessage="signTypedMessage",t.getEnvironmentInfo="getEnvironmentInfo",t.getOffChainSignature="getOffChainSignature",t.requestAddressBook="requestAddressBook",t.wallet_getPermissions="wallet_getPermissions",t.wallet_requestPermissions="wallet_requestPermissions"})(r||(r={}));var f;(function(t){t.requestAddressBook="requestAddressBook"})(f||(f={}));class H{constructor(e=null,s=!1){this.allowedOrigins=null,this.callbacks=new Map,this.debugMode=!1,this.isServer=typeof window>"u",this.isValidMessage=({origin:a,data:n,source:i})=>{const o=!n,l=!this.isServer&&i===window.parent,u=typeof n.version<"u"&&parseInt(n.version.split(".")[0]),B=typeof u=="number"&&u>=1;let y=!0;return Array.isArray(this.allowedOrigins)&&(y=this.allowedOrigins.find(P=>P.test(a))!==void 0),!o&&l&&B&&y},this.logIncomingMessage=a=>{console.info(`Safe Apps SDK v1: A message was received from origin ${a.origin}. `,a.data)},this.onParentMessage=a=>{this.isValidMessage(a)&&(this.debugMode&&this.logIncomingMessage(a),this.handleIncomingMessage(a.data))},this.handleIncomingMessage=a=>{const{id:n}=a,i=this.callbacks.get(n);i&&(i(a),this.callbacks.delete(n))},this.send=(a,n)=>{const i=g.makeRequest(a,n);if(this.isServer)throw new Error("Window doesn't exist");return window.parent.postMessage(i,"*"),new Promise((o,l)=>{this.callbacks.set(i.id,u=>{if(!u.success){l(new Error(u.error));return}o(u)})})},this.allowedOrigins=e,this.debugMode=s,this.isServer||window.addEventListener("message",this.onParentMessage)}}const S=t=>typeof t=="object"&&t!=null&&"domain"in t&&"types"in t&&"message"in t;var m=k();class A{constructor(e){this.communicator=e}async getBySafeTxHash(e){if(!e)throw new Error("Invalid safeTxHash");return(await this.communicator.send(r.getTxBySafeTxHash,{safeTxHash:e})).data}async signMessage(e){const s={message:e};return(await this.communicator.send(r.signMessage,s)).data}async signTypedMessage(e){if(!S(e))throw new Error("Invalid typed data");return(await this.communicator.send(r.signTypedMessage,{typedData:e})).data}async send({txs:e,params:s}){if(!e||!e.length)throw new Error("No transactions were passed");const a={txs:e,params:s};return(await this.communicator.send(r.sendTransactions,a)).data}}const c={eth_call:"eth_call",eth_gasPrice:"eth_gasPrice",eth_getLogs:"eth_getLogs",eth_getBalance:"eth_getBalance",eth_getCode:"eth_getCode",eth_getBlockByHash:"eth_getBlockByHash",eth_getBlockByNumber:"eth_getBlockByNumber",eth_getStorageAt:"eth_getStorageAt",eth_getTransactionByHash:"eth_getTransactionByHash",eth_getTransactionReceipt:"eth_getTransactionReceipt",eth_getTransactionCount:"eth_getTransactionCount",eth_estimateGas:"eth_estimateGas",safe_setSettings:"safe_setSettings"},h={defaultBlockParam:(t="latest")=>t,returnFullTxObjectParam:(t=!1)=>t,blockNumberToHex:t=>Number.isInteger(t)?`0x${t.toString(16)}`:t};class O{constructor(e){this.communicator=e,this.call=this.buildRequest({call:c.eth_call,formatters:[null,h.defaultBlockParam]}),this.getBalance=this.buildRequest({call:c.eth_getBalance,formatters:[null,h.defaultBlockParam]}),this.getCode=this.buildRequest({call:c.eth_getCode,formatters:[null,h.defaultBlockParam]}),this.getStorageAt=this.buildRequest({call:c.eth_getStorageAt,formatters:[null,h.blockNumberToHex,h.defaultBlockParam]}),this.getPastLogs=this.buildRequest({call:c.eth_getLogs}),this.getBlockByHash=this.buildRequest({call:c.eth_getBlockByHash,formatters:[null,h.returnFullTxObjectParam]}),this.getBlockByNumber=this.buildRequest({call:c.eth_getBlockByNumber,formatters:[h.blockNumberToHex,h.returnFullTxObjectParam]}),this.getTransactionByHash=this.buildRequest({call:c.eth_getTransactionByHash}),this.getTransactionReceipt=this.buildRequest({call:c.eth_getTransactionReceipt}),this.getTransactionCount=this.buildRequest({call:c.eth_getTransactionCount,formatters:[null,h.defaultBlockParam]}),this.getGasPrice=this.buildRequest({call:c.eth_gasPrice}),this.getEstimateGas=s=>this.buildRequest({call:c.eth_estimateGas})([s]),this.setSafeSettings=this.buildRequest({call:c.safe_setSettings})}buildRequest(e){const{call:s,formatters:a}=e;return async n=>{a&&Array.isArray(n)&&a.forEach((l,u)=>{l&&(n[u]=l(n[u]))});const i={call:s,params:n||[]};return(await this.communicator.send(r.rpcCall,i)).data}}}const x="0x1626ba7e",V="0x20c13b0b",p=4001;class d extends Error{constructor(e,s,a){super(e),this.code=s,this.data=a,Object.setPrototypeOf(this,d.prototype)}}class _{constructor(e){this.communicator=e}async getPermissions(){return(await this.communicator.send(r.wallet_getPermissions,void 0)).data}async requestPermissions(e){if(!this.isPermissionRequestValid(e))throw new d("Permissions request is invalid",p);try{return(await this.communicator.send(r.wallet_requestPermissions,e)).data}catch{throw new d("Permissions rejected",p)}}isPermissionRequestValid(e){return e.every(s=>typeof s=="object"?Object.keys(s).every(a=>!!Object.values(f).includes(a)):!1)}}const b=(t,e)=>e.some(s=>s.parentCapability===t),M=()=>(t,e,s)=>{const a=s.value;return s.value=async function(){const n=new _(this.communicator);let i=await n.getPermissions();if(b(e,i)||(i=await n.requestPermissions([{[e]:{}}])),!b(e,i))throw new d("Permissions rejected",p);return a.apply(this)},s};var j=function(t,e,s,a){var n=arguments.length,i=n<3?e:a===null?a=Object.getOwnPropertyDescriptor(e,s):a,o;if(typeof Reflect=="object"&&typeof Reflect.decorate=="function")i=Reflect.decorate(t,e,s,a);else for(var l=t.length-1;l>=0;l--)(o=t[l])&&(i=(n<3?o(i):n>3?o(e,s,i):o(e,s))||i);return n>3&&i&&Object.defineProperty(e,s,i),i};class T{constructor(e){this.communicator=e}async getChainInfo(){return(await this.communicator.send(r.getChainInfo,void 0)).data}async getInfo(){return(await this.communicator.send(r.getSafeInfo,void 0)).data}async experimental_getBalances({currency:e="usd"}={}){return(await this.communicator.send(r.getSafeBalances,{currency:e})).data}async check1271Signature(e,s="0x"){const a=await this.getInfo(),n=w({abi:[{constant:!1,inputs:[{name:"_dataHash",type:"bytes32"},{name:"_signature",type:"bytes"}],name:"isValidSignature",outputs:[{name:"",type:"bytes4"}],payable:!1,stateMutability:"nonpayable",type:"function"}],functionName:"isValidSignature",args:[e,s]}),i={call:c.eth_call,params:[{to:a.safeAddress,data:n},"latest"]};try{return(await this.communicator.send(r.rpcCall,i)).data.slice(0,10).toLowerCase()===x}catch{return!1}}async check1271SignatureBytes(e,s="0x"){const a=await this.getInfo(),n=w({abi:[{constant:!1,inputs:[{name:"_data",type:"bytes"},{name:"_signature",type:"bytes"}],name:"isValidSignature",outputs:[{name:"",type:"bytes4"}],payable:!1,stateMutability:"nonpayable",type:"function"}],functionName:"isValidSignature",args:[e,s]}),i={call:c.eth_call,params:[{to:a.safeAddress,data:n},"latest"]};try{return(await this.communicator.send(r.rpcCall,i)).data.slice(0,10).toLowerCase()===V}catch{return!1}}calculateMessageHash(e){return I(e)}calculateTypedMessageHash(e){const s=typeof e.domain.chainId=="object"?e.domain.chainId.toNumber():Number(e.domain.chainId);let a=e.primaryType;if(!a){const n=Object.values(e.types),i=Object.keys(e.types).filter(o=>n.every(l=>l.every(({type:u})=>u.replace("[","").replace("]","")!==o)));if(i.length===0||i.length>1)throw new Error("Please specify primaryType");a=i[0]}return q({message:e.message,domain:{...e.domain,chainId:s,verifyingContract:e.domain.verifyingContract,salt:e.domain.salt},types:e.types,primaryType:a})}async getOffChainSignature(e){return(await this.communicator.send(r.getOffChainSignature,e)).data}async isMessageSigned(e,s="0x"){let a;if(typeof e=="string"&&(a=async()=>{const n=this.calculateMessageHash(e);return await this.isMessageHashSigned(n,s)}),S(e)&&(a=async()=>{const n=this.calculateTypedMessageHash(e);return await this.isMessageHashSigned(n,s)}),a)return await a();throw new Error("Invalid message type")}async isMessageHashSigned(e,s="0x"){const a=[this.check1271Signature.bind(this),this.check1271SignatureBytes.bind(this)];for(const n of a)if(await n(e,s))return!0;return!1}async getEnvironmentInfo(){return(await this.communicator.send(r.getEnvironmentInfo,void 0)).data}async requestAddressBook(){return(await this.communicator.send(r.requestAddressBook,void 0)).data}}j([M()],T.prototype,"requestAddressBook",null);class W{constructor(e={}){const{allowedDomains:s=null,debug:a=!1}=e;this.communicator=new H(s,a),this.eth=new O(this.communicator),this.txs=new A(this.communicator),this.safe=new T(this.communicator),this.wallet=new _(this.communicator)}}const $=m.Operation,z=m.TokenType,J=m.TransactionStatus,Q=m.TransferDirection;export{g as MessageFormatter,r as Methods,$ as Operation,c as RPC_CALLS,f as RestrictedMethods,z as TokenType,J as TransactionStatus,Q as TransferDirection,W as default,v as getSDKVersion,S as isObjectEIP712TypedData};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/PhArrowCircleDown-B305t-Sh.js","assets/property-C9JG5tag.js","assets/PhArrowClockwise-CJPxQhr_.js","assets/PhArrowDown-C4hT9BVu.js","assets/PhArrowLeft-Way4Cu-r.js","assets/PhArrowRight-Cp5ZME0F.js","assets/PhArrowSquareOut-NnrK69c5.js","assets/PhArrowsDownUp-BjBI4ckC.js","assets/PhArrowsLeftRight-CuLpbKRk.js","assets/PhArrowUp-Dph6j8rm.js","assets/PhArrowUpRight-BpJjRRRh.js","assets/PhArrowsClockwise-CFUT8X7R.js","assets/PhBank-Dchr4XQJ.js","assets/PhBrowser-dUu2TrC1.js","assets/PhCaretDown-78IuKU3V.js","assets/PhCaretLeft-_aiyH7n1.js","assets/PhCaretRight-8zJQEuDX.js","assets/PhCaretUp-CiCxKWwN.js","assets/PhCheck-CcADx8br.js","assets/PhCircleHalf-BYzSzd2h.js","assets/PhClock-UItiXeJq.js","assets/PhCompass-CUy3uA7t.js","assets/PhCopy-C-PDgSlZ.js","assets/PhCreditCard-CWRaUT6F.js","assets/PhCurrencyDollar-Cqla3AXT.js","assets/PhDesktop-BBIPrYLl.js","assets/PhDeviceMobile-BdsPaATg.js","assets/PhDotsThree-BMXCQl-0.js","assets/PhVault-l2PHF38a.js","assets/PhEnvelope-yUsis6yU.js","assets/PhFunnelSimple-Ba7BbWTp.js","assets/PhGlobe-DgLxBk5U.js","assets/PhIdentificationCard-Czjmq9Z3.js","assets/PhImage-BAJ_erz6.js","assets/PhInfo-Cr4DhVUE.js","assets/PhLightbulb-BX_7duTr.js","assets/PhMagnifyingGlass-Mygfryvz.js","assets/PhPaperPlaneRight-BeuCA660.js","assets/PhPlus-BMjcHjsT.js","assets/PhPower-CGffGmdb.js","assets/PhPuzzlePiece-wm_GpVSi.js","assets/PhQrCode-DRwRzXCH.js","assets/PhQuestion-M09j2U0T.js","assets/PhQuestionMark-BP9EMB6h.js","assets/PhSealCheck-BfG80yKn.js","assets/PhSignOut-C5YOWlPT.js","assets/PhSpinner-BXooDYzU.js","assets/PhTrash-Biq6rmmL.js","assets/PhUser-CAgZSpGe.js","assets/PhWallet-w25D16It.js","assets/PhWarning-DPEydIPw.js","assets/PhWarningCircle-BqjT745H.js","assets/PhX-s-SmVExa.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{a as M,i as y,b as x,w as h}from"./lit-element-B3y9oplH.js";import{n as s,o as Z,a as A}from"./class-map-CxwNmq0D.js";import{r as E,v as c,d as I}from"./index-
|
|
2
|
+
import{a as M,i as y,b as x,w as h}from"./lit-element-B3y9oplH.js";import{n as s,o as Z,a as A}from"./class-map-CxwNmq0D.js";import{r as E,v as c,d as I}from"./index-BqkfR3e1.js";import{_ as r}from"./index-CB1SUuBM.js";const L=".",C={getSpacingStyles(t,e){if(Array.isArray(t))return t[e]?`var(--apkt-spacing-${t[e]})`:void 0;if(typeof t=="string")return`var(--apkt-spacing-${t})`},getFormattedDate(t){return new Intl.DateTimeFormat("en-US",{month:"short",day:"numeric"}).format(t)},formatCurrency(t=0,e={}){const i=Number(t);return isNaN(i)?"$0.00":new Intl.NumberFormat("en-US",{style:"currency",currency:"USD",minimumFractionDigits:2,maximumFractionDigits:2,...e}).format(i)},getHostName(t){try{return new URL(t).hostname}catch{return""}},getTruncateString({string:t,charsStart:e,charsEnd:i,truncate:o}){return t.length<=e+i?t:o==="end"?`${t.substring(0,e)}...`:o==="start"?`...${t.substring(t.length-i)}`:`${t.substring(0,Math.floor(e))}...${t.substring(t.length-Math.floor(i))}`},generateAvatarColors(t){const i=t.toLowerCase().replace(/^0x/iu,"").replace(/[^a-f0-9]/gu,"").substring(0,6).padEnd(6,"0"),o=this.hexToRgb(i),n=getComputedStyle(document.documentElement).getPropertyValue("--w3m-border-radius-master"),a=100-3*Number(n==null?void 0:n.replace("px","")),p=`${a}% ${a}% at 65% 40%`,d=[];for(let u=0;u<5;u+=1){const m=this.tintColor(o,.15*u);d.push(`rgb(${m[0]}, ${m[1]}, ${m[2]})`)}return`
|
|
3
3
|
--local-color-1: ${d[0]};
|
|
4
4
|
--local-color-2: ${d[1]};
|
|
5
5
|
--local-color-3: ${d[2]};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{i as d,b as u}from"./lit-element-B3y9oplH.js";import{n as p}from"./class-map-CxwNmq0D.js";import{c as m}from"./index-
|
|
1
|
+
import{i as d,b as u}from"./lit-element-B3y9oplH.js";import{n as p}from"./class-map-CxwNmq0D.js";import{c as m}from"./index-Bx92bjWv.js";import{d as f,r as h}from"./index-BqkfR3e1.js";const g=f`
|
|
2
2
|
:host {
|
|
3
3
|
position: relative;
|
|
4
4
|
display: flex;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{i as m,b as h}from"./lit-element-B3y9oplH.js";import{n as b,o as v,r as C}from"./class-map-CxwNmq0D.js";import{d as k,r as g}from"./index-
|
|
1
|
+
import{i as m,b as h}from"./lit-element-B3y9oplH.js";import{n as b,o as v,r as C}from"./class-map-CxwNmq0D.js";import{d as k,r as g}from"./index-BqkfR3e1.js";import{c as y}from"./index-Bx92bjWv.js";import{e as O,n as _}from"./ref-BsAZ42-h.js";import{e as L,i as R,p as j,O as l}from"./W3MFrameProviderSingleton-DxZDURuu.js";const d=j({isLegalCheckboxChecked:!1}),f={state:d,subscribe(e){return R(d,()=>e(d))},subscribeKey(e,t){return L(d,e,t)},setIsLegalCheckboxChecked(e){d.isLegalCheckboxChecked=e}},z=k`
|
|
2
2
|
label {
|
|
3
3
|
display: inline-flex;
|
|
4
4
|
align-items: center;
|