@multiversx/sdk-dapp 5.1.5 → 5.1.7
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/out/__chunks__/chunk-2FDNVFTD.mjs +2 -0
- package/out/__chunks__/{chunk-VRXZUSWL.mjs → chunk-2FHEBVWZ.mjs} +2 -2
- package/out/__chunks__/{chunk-5TAQLAW3.mjs → chunk-2FJUAWNG.mjs} +2 -2
- package/out/__chunks__/{chunk-AQ6D3F5K.mjs → chunk-2Y66XRQK.mjs} +2 -2
- package/out/__chunks__/{chunk-FLN5MNNT.mjs → chunk-3AN3HJA5.mjs} +2 -2
- package/out/__chunks__/chunk-3Z2ACTV6.mjs +2 -0
- package/out/__chunks__/{chunk-PH34FNHZ.mjs → chunk-47FDQOU2.mjs} +2 -2
- package/out/__chunks__/chunk-4JCMNQXS.mjs +2 -0
- package/out/__chunks__/{chunk-HVUUOFDY.mjs → chunk-4MXAQBQ4.mjs} +2 -2
- package/out/__chunks__/{chunk-OHUOJ5P3.mjs → chunk-5A2ZB2NK.mjs} +2 -2
- package/out/__chunks__/chunk-5FVAEFKL.mjs +2 -0
- package/out/__chunks__/{chunk-MZBHPAM4.mjs → chunk-5TKJRIH7.mjs} +2 -2
- package/out/__chunks__/{chunk-6LATG7X5.mjs → chunk-6DI7XSHB.mjs} +2 -2
- package/out/__chunks__/{chunk-IILEKPBI.mjs → chunk-6DW4VXLU.mjs} +2 -2
- package/out/__chunks__/{chunk-CDQ2BNUD.mjs → chunk-6JSWL75O.mjs} +2 -2
- package/out/__chunks__/{chunk-OA5HXCGR.mjs → chunk-726BASBO.mjs} +2 -2
- package/out/__chunks__/chunk-726BASBO.mjs.map +7 -0
- package/out/__chunks__/{chunk-ZFJOYMJ7.mjs → chunk-72BFMMSI.mjs} +2 -2
- package/out/__chunks__/chunk-77NCTJIH.mjs +2 -0
- package/out/__chunks__/{chunk-MUYR3PCB.mjs → chunk-7HP3FIAW.mjs} +2 -2
- package/out/__chunks__/{chunk-WNEPIIEY.mjs → chunk-7XW3S67Y.mjs} +2 -2
- package/out/__chunks__/chunk-AF3RP6VA.mjs +2 -0
- package/out/__chunks__/{chunk-HAA2EO5S.mjs → chunk-AH5RW56M.mjs} +2 -2
- package/out/__chunks__/{chunk-5LRQIZ4G.mjs → chunk-BECHXPBC.mjs} +2 -2
- package/out/__chunks__/{chunk-XM4IYM4M.mjs → chunk-BPKM2DQN.mjs} +2 -2
- package/out/__chunks__/{chunk-7MZD7YCO.mjs → chunk-CRC6EHJB.mjs} +2 -2
- package/out/__chunks__/{chunk-LS3YSRRM.mjs → chunk-DCOMKCXN.mjs} +2 -2
- package/out/__chunks__/{chunk-YTR6YMAJ.mjs → chunk-DWYHYJNY.mjs} +2 -2
- package/out/__chunks__/{chunk-JVKQPCTQ.mjs → chunk-G26BK7D7.mjs} +2 -2
- package/out/__chunks__/{chunk-4JRSZ2WY.mjs → chunk-HGZQIUMH.mjs} +2 -2
- package/out/__chunks__/{chunk-ECTE4GIA.mjs → chunk-HQ3MXZM2.mjs} +2 -2
- package/out/__chunks__/chunk-HSIBZ2L5.mjs +2 -0
- package/out/__chunks__/{chunk-MI73KXKA.mjs → chunk-ILMJWCA5.mjs} +2 -2
- package/out/__chunks__/{chunk-OYO5HAC3.mjs → chunk-J6R5G7CE.mjs} +2 -2
- package/out/__chunks__/{chunk-YAMIPNLB.mjs → chunk-J7WJREOM.mjs} +2 -2
- package/out/__chunks__/{chunk-UGJVHUID.mjs → chunk-JYIAIJ37.mjs} +2 -2
- package/out/__chunks__/{chunk-B3UFF7ML.mjs → chunk-K4MA6VJX.mjs} +2 -2
- package/out/__chunks__/chunk-KDOO7OCC.mjs +2 -0
- package/out/__chunks__/chunk-KDOO7OCC.mjs.map +7 -0
- package/out/__chunks__/{chunk-FCH3TZNB.mjs → chunk-KKP56V4G.mjs} +2 -2
- package/out/__chunks__/chunk-KN26DF7H.mjs +2 -0
- package/out/__chunks__/{chunk-YUBLXI76.mjs → chunk-KOA4KAE3.mjs} +2 -2
- package/out/__chunks__/{chunk-PLUWBWJ2.mjs → chunk-LJX4MW7B.mjs} +1 -1
- package/out/__chunks__/{chunk-PLUWBWJ2.mjs.map → chunk-LJX4MW7B.mjs.map} +1 -1
- package/out/__chunks__/{chunk-GOK56W56.mjs → chunk-LLJ3VLPO.mjs} +2 -2
- package/out/__chunks__/chunk-LNCOC6DZ.mjs +2 -0
- package/out/__chunks__/{chunk-Q5BUVODR.mjs → chunk-LPXPAY7D.mjs} +2 -2
- package/out/__chunks__/chunk-LSBQBQSE.mjs +2 -0
- package/out/__chunks__/chunk-NC2PYW67.mjs +2 -0
- package/out/__chunks__/chunk-NJVYQG4N.mjs +2 -0
- package/out/__chunks__/{chunk-SLWY5XP5.mjs → chunk-NMNJWV6J.mjs} +2 -2
- package/out/__chunks__/{chunk-UVHONPA5.mjs → chunk-NPRED3F5.mjs} +2 -2
- package/out/__chunks__/{chunk-5GAD4GPI.mjs → chunk-NQ2ACSWO.mjs} +2 -2
- package/out/__chunks__/{chunk-LMNAVRBQ.mjs → chunk-NZ5CEUB5.mjs} +2 -2
- package/out/__chunks__/{chunk-E2XW7YVE.mjs → chunk-O3AN3EMP.mjs} +2 -2
- package/out/__chunks__/{chunk-4ADFEGIK.mjs → chunk-O5L6HOQJ.mjs} +2 -2
- package/out/__chunks__/{chunk-37ZYC4SQ.mjs → chunk-O6LQEIE2.mjs} +2 -2
- package/out/__chunks__/{chunk-USDJ7CAG.mjs → chunk-OAKDIMYH.mjs} +2 -2
- package/out/__chunks__/{chunk-EGM63G4K.mjs → chunk-OWV2V6SX.mjs} +2 -2
- package/out/__chunks__/{chunk-DUNGWQ5A.mjs → chunk-P6PUVTFU.mjs} +2 -2
- package/out/__chunks__/{chunk-O5TU5QQI.mjs → chunk-PMOKDTDV.mjs} +2 -2
- package/out/__chunks__/chunk-Q5HWS7FX.mjs +2 -0
- package/out/__chunks__/{chunk-ILGTFJZA.mjs → chunk-QC6KCYKL.mjs} +2 -2
- package/out/__chunks__/{chunk-ASVVZSNW.mjs → chunk-QF3ACWOH.mjs} +2 -2
- package/out/__chunks__/{chunk-3NBR5S3K.mjs → chunk-QIF2DQBN.mjs} +2 -2
- package/out/__chunks__/{chunk-3PAQ2Z7N.mjs → chunk-QZOCKDRL.mjs} +2 -2
- package/out/__chunks__/chunk-R4PAEXYU.mjs +2 -0
- package/out/__chunks__/{chunk-XVCSSYCP.mjs.map → chunk-R4PAEXYU.mjs.map} +2 -2
- package/out/__chunks__/{chunk-6ILB52XY.mjs → chunk-RNWJHZLH.mjs} +2 -2
- package/out/__chunks__/{chunk-4PIC7DFH.mjs → chunk-S2RWU5BV.mjs} +2 -2
- package/out/__chunks__/{chunk-7OBI7GUK.mjs → chunk-S5ZROGZQ.mjs} +2 -2
- package/out/__chunks__/{chunk-AYPDQETP.mjs → chunk-SFAWPLJB.mjs} +2 -2
- package/out/__chunks__/{chunk-TE5XVHX2.mjs → chunk-SUCBDFIP.mjs} +2 -2
- package/out/__chunks__/{chunk-Z745SBSQ.mjs → chunk-TF67ZK65.mjs} +2 -2
- package/out/__chunks__/chunk-TKZHFVMQ.mjs +2 -0
- package/out/__chunks__/chunk-TPJ7KEUB.mjs +2 -0
- package/out/__chunks__/{chunk-KJLFUHEH.mjs.map → chunk-TPJ7KEUB.mjs.map} +1 -1
- package/out/__chunks__/chunk-U66UATGK.mjs +2 -0
- package/out/__chunks__/{chunk-76URRONH.mjs → chunk-UCRVRBTA.mjs} +2 -2
- package/out/__chunks__/{chunk-VEEHHORJ.mjs → chunk-VT5BFUDT.mjs} +2 -2
- package/out/__chunks__/{chunk-Q3XYMQWN.mjs → chunk-WKWVAY3B.mjs} +2 -2
- package/out/__chunks__/{chunk-A5BJAB7T.mjs → chunk-WL56YMKX.mjs} +2 -2
- package/out/__chunks__/{chunk-LPPO6LUR.mjs → chunk-WXS4MAB3.mjs} +2 -2
- package/out/__chunks__/{chunk-XFUNY6KC.mjs → chunk-X25IIGUZ.mjs} +2 -2
- package/out/__chunks__/{chunk-ZM5EFY6B.mjs → chunk-XEENI7BQ.mjs} +2 -2
- package/out/__chunks__/chunk-XKBKAEYF.mjs +2 -0
- package/out/__chunks__/{chunk-RFCXQES5.mjs → chunk-ZG4ZEFUR.mjs} +2 -2
- package/out/__chunks__/{chunk-D4BQCSIY.mjs → chunk-ZSJNTJKG.mjs} +2 -2
- package/out/apiCalls/account/getScamAddressData.mjs +1 -1
- package/out/apiCalls/configuration/getCleanApiAddress.mjs +1 -1
- package/out/apiCalls/configuration/getGasStationMetadata.mjs +1 -1
- package/out/apiCalls/index.mjs +1 -1
- package/out/apiCalls/tokens/getPersistedTokenDetails.mjs +1 -1
- package/out/apiCalls/tokens/getTokenDetails.mjs +1 -1
- package/out/apiCalls/tokens/index.mjs +1 -1
- package/out/apiCalls/transactions/getServerTransactionsByHashes.mjs +1 -1
- package/out/apiCalls/transactions/getTransactionByHash.mjs +1 -1
- package/out/apiCalls/transactions/getTransactionsByHashes.mjs +1 -1
- package/out/constants/browser.constants.mjs +1 -1
- package/out/constants/index.mjs +1 -1
- package/out/constants/providerFactory.constants.mjs +1 -1
- package/out/constants/storage.constants.mjs +1 -1
- package/out/constants/window.constants.cjs +1 -1
- package/out/constants/window.constants.cjs.map +1 -1
- package/out/constants/window.constants.mjs +1 -1
- package/out/controllers/TransactionsHistoryController/TransactionsHistoryController.mjs +1 -1
- package/out/controllers/TransactionsHistoryController/index.mjs +1 -1
- package/out/controllers/TransactionsTableController/TransactionsTableController.mjs +1 -1
- package/out/controllers/TransactionsTableController/index.mjs +1 -1
- package/out/index.mjs +1 -1
- package/out/lib/sdkDappUi.mjs +1 -1
- package/out/managers/LogoutManager/LogoutManager.mjs +1 -1
- package/out/managers/NotificationsFeedManager/NotificationsFeedManager.mjs +1 -1
- package/out/managers/NotificationsFeedManager/index.mjs +1 -1
- package/out/managers/TransactionManager/TransactionManager.mjs +1 -1
- package/out/managers/TransactionManager/helpers/getAreTransactionsCorssShards.mjs +1 -1
- package/out/managers/TransactionManager/helpers/getToastDuration.mjs +1 -1
- package/out/managers/TransactionManager/index.mjs +1 -1
- package/out/managers/UnlockPanelManager/UnlockPanelManager.mjs +1 -1
- package/out/managers/UnlockPanelManager/index.mjs +1 -1
- package/out/managers/index.mjs +1 -1
- package/out/managers/internal/LedgerConnectStateManager/LedgerConnectStateManager.mjs +1 -1
- package/out/managers/internal/LedgerConnectStateManager/index.mjs +1 -1
- package/out/managers/internal/LedgerIdleStateManager/LedgerIdleStateManager.mjs +1 -1
- package/out/managers/internal/PendingTransactionsStateManager/PendingTransactionsStateManager.mjs +1 -1
- package/out/managers/internal/PendingTransactionsStateManager/index.mjs +1 -1
- package/out/managers/internal/SidePanelBaseManager/SidePanelBaseManager.mjs +1 -1
- package/out/managers/internal/SidePanelBaseManager/index.mjs +1 -1
- package/out/managers/internal/SignTransactionsStateManager/SignTransactionsStateManager.mjs +1 -1
- package/out/managers/internal/SignTransactionsStateManager/index.mjs +1 -1
- package/out/managers/internal/ToastManager/ToastManager.mjs +1 -1
- package/out/managers/internal/ToastManager/helpers/LifetimeManager.mjs +1 -1
- package/out/managers/internal/ToastManager/helpers/createToastsFromTransactions.mjs +1 -1
- package/out/managers/internal/UIBaseManager/UIBaseManager.mjs +1 -1
- package/out/managers/internal/WalletConnectStateManager/WalletConnectStateManager.mjs +1 -1
- package/out/managers/internal/WalletConnectStateManager/index.mjs +1 -1
- package/out/managers/internal/index.mjs +1 -1
- package/out/methods/account/getAccount.mjs +1 -1
- package/out/methods/account/getAccountInfo.mjs +1 -1
- package/out/methods/account/getAddress.mjs +1 -1
- package/out/methods/account/getIsLoggedIn.mjs +1 -1
- package/out/methods/account/getLatestNonce.mjs +1 -1
- package/out/methods/initApp/gastStationMetadata/setGasStationMetadata.mjs +1 -1
- package/out/methods/initApp/initApp.cjs +2 -1
- package/out/methods/initApp/initApp.cjs.map +2 -2
- package/out/methods/initApp/initApp.mjs +1 -1
- package/out/methods/initApp/initApp.mjs.map +3 -3
- package/out/methods/initApp/websocket/initializeWebsocketConnection.mjs +1 -1
- package/out/methods/initApp/websocket/registerWebsocket.mjs +1 -1
- package/out/methods/loginInfo/getLoginInfo.mjs +1 -1
- package/out/methods/network/getEgldLabel.mjs +1 -1
- package/out/methods/network/getExplorerAddress.mjs +1 -1
- package/out/methods/network/getNetworkConfig.mjs +1 -1
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/checkBatch.mjs +1 -1
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/checkTransactionStatus.mjs +1 -1
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/index.mjs +1 -1
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/manageFailedTransactions.mjs +1 -1
- package/out/methods/trackTransactions/helpers/getPollingInterval.mjs +1 -1
- package/out/methods/trackTransactions/trackTransactions.mjs +1 -1
- package/out/methods/transactions/getFailedTransactions.mjs +1 -1
- package/out/methods/transactions/getFailedTransactionsSessions.mjs +1 -1
- package/out/methods/transactions/getPendingTransactions.mjs +1 -1
- package/out/methods/transactions/getPendingTransactionsSessions.mjs +1 -1
- package/out/methods/transactions/getSuccessfulTransactions.mjs +1 -1
- package/out/methods/transactions/getSuccessfulTransactionsSessions.mjs +1 -1
- package/out/methods/transactions/getTransactionSessions.mjs +1 -1
- package/out/providers/DappProvider/DappProvider.d.ts +0 -2
- package/out/providers/DappProvider/DappProvider.mjs +1 -1
- package/out/providers/DappProvider/helpers/login/helpers/accountLogin.mjs +1 -1
- package/out/providers/DappProvider/helpers/login/helpers/extractAddressFromToken.mjs +1 -1
- package/out/providers/DappProvider/helpers/login/helpers/getAccountFromToken.mjs +1 -1
- package/out/providers/DappProvider/helpers/login/helpers/getModifiedLoginToken.mjs +1 -1
- package/out/providers/DappProvider/helpers/login/login.cjs +1 -1
- package/out/providers/DappProvider/helpers/login/login.cjs.map +2 -2
- package/out/providers/DappProvider/helpers/login/login.d.ts +0 -2
- package/out/providers/DappProvider/helpers/login/login.mjs +1 -1
- package/out/providers/DappProvider/helpers/logout/logout.mjs +1 -1
- package/out/providers/DappProvider/helpers/signErrors/handleSignError.mjs +1 -1
- package/out/providers/DappProvider/helpers/signMessage/signMessageWithProvider.mjs +1 -1
- package/out/providers/DappProvider/helpers/signTransactions/signTransactionsWithProvider.mjs +1 -1
- package/out/providers/DappProvider/index.mjs +1 -1
- package/out/providers/ProviderFactory.cjs +1 -5
- package/out/providers/ProviderFactory.cjs.map +2 -2
- package/out/providers/ProviderFactory.mjs +1 -1
- package/out/providers/helpers/accountProvider.mjs +1 -1
- package/out/providers/helpers/cancelCrossWindowAction.mjs +1 -1
- package/out/providers/helpers/clearInitiatedLogins.mjs +1 -1
- package/out/providers/helpers/emptyProvider.mjs +1 -1
- package/out/providers/helpers/restoreProvider.cjs +11 -3
- package/out/providers/helpers/restoreProvider.cjs.map +2 -2
- package/out/providers/helpers/restoreProvider.mjs +1 -1
- package/out/providers/index.mjs +1 -1
- package/out/providers/strategies/BaseProviderStrategy/BaseProviderStrategy.mjs +1 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/CrossWindowProviderStrategy.mjs +1 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/ExtensionProviderStrategy/ExtensionProviderStrategy.mjs +1 -1
- package/out/providers/strategies/ExtensionProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/IframeProviderStrategy/IframeProviderStrategy.mjs +1 -1
- package/out/providers/strategies/IframeProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/LedgerProviderStrategy.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/authenticateLedgerAccount.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/getAuthTokenText.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/getLedgerConfiguration.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/getLedgerProvider.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/getLedgerVersionOptions.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/index.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/initializeLedgerProvider.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/signLedgerMessage.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/index.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/updateAccountsList.mjs +1 -1
- package/out/providers/strategies/LedgerProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/WalletConnectProviderStrategy/WalletConnectProviderStrategy.mjs +1 -1
- package/out/providers/strategies/WalletConnectProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/WebviewClient.mjs +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/index.mjs +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/WebviewProviderStrategy.mjs +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/helpers/getPendingTransactionsHandlers.mjs +1 -1
- package/out/providers/strategies/helpers/index.mjs +1 -1
- package/out/providers/strategies/helpers/signMessage/signMessage.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/calculateFeeLimit.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/getCommonData.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/getExtractTransactionsInfo.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getFeeData.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/guardTransactions/guardTransactions.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/signTransactions.mjs +1 -1
- package/out/providers/strategies/index.mjs +1 -1
- package/out/providers/types/providerFactory.types.cjs.map +1 -1
- package/out/providers/types/providerFactory.types.d.ts +2 -1
- package/out/providers/types/providerFactory.types.mjs +1 -1
- package/out/react/account/useGetAccount.mjs +1 -1
- package/out/react/account/useGetAccountInfo.mjs +1 -1
- package/out/react/account/useGetIsLoggedIn.mjs +1 -1
- package/out/react/account/useGetLatestNonce.mjs +1 -1
- package/out/react/index.mjs +1 -1
- package/out/react/loginInfo/useGetLoginInfo.mjs +1 -1
- package/out/react/network/useGetNetworkConfig.mjs +1 -1
- package/out/react/store/getReactStore.mjs +1 -1
- package/out/react/store/useSelector.mjs +1 -1
- package/out/react/transactions/useGetFailedTransactions.mjs +1 -1
- package/out/react/transactions/useGetFailedTransactionsSessions.mjs +1 -1
- package/out/react/transactions/useGetPendingTransactions.mjs +1 -1
- package/out/react/transactions/useGetPendingTransactionsSessions.mjs +1 -1
- package/out/react/transactions/useGetSuccessfulTransactions.mjs +1 -1
- package/out/react/transactions/useGetSuccessfulTransactionsSessions.mjs +1 -1
- package/out/react/transactions/useGetTransactionSessions.mjs +1 -1
- package/out/services/index.mjs +1 -1
- package/out/services/nativeAuth/index.mjs +1 -1
- package/out/services/nativeAuth/methods/buildNativeAuthConfig.mjs +1 -1
- package/out/services/nativeAuth/methods/getDefaultNativeAuthConfig.mjs +1 -1
- package/out/services/nativeAuth/methods/index.mjs +1 -1
- package/out/services/nativeAuth/nativeAuth.mjs +1 -1
- package/out/store/actions/account/accountActions.mjs +1 -1
- package/out/store/actions/account/index.mjs +1 -1
- package/out/store/actions/cache/cacheActions.mjs +1 -1
- package/out/store/actions/cache/index.mjs +1 -1
- package/out/store/actions/config/configActions.mjs +1 -1
- package/out/store/actions/config/index.mjs +1 -1
- package/out/store/actions/index.mjs +1 -1
- package/out/store/actions/loginInfo/loginInfoActions.mjs +1 -1
- package/out/store/actions/network/index.mjs +1 -1
- package/out/store/actions/network/initializeNetwork.mjs +1 -1
- package/out/store/actions/network/networkActions.mjs +1 -1
- package/out/store/actions/sharedActions/index.mjs +1 -1
- package/out/store/actions/sharedActions/sharedActions.mjs +1 -1
- package/out/store/actions/toasts/index.mjs +1 -1
- package/out/store/actions/toasts/toastsActions.mjs +1 -1
- package/out/store/actions/transactions/transactionsActions.mjs +1 -1
- package/out/store/actions/ui/index.mjs +1 -1
- package/out/store/actions/ui/uiActions.mjs +1 -1
- package/out/store/middleware/applyMiddlewares.mjs +1 -1
- package/out/store/middleware/index.mjs +1 -1
- package/out/store/middleware/logoutMiddleware.mjs +1 -1
- package/out/store/slices/toast/toastSlice.types.cjs.map +1 -1
- package/out/store/slices/toast/toastSlice.types.d.ts +1 -0
- package/out/store/storage/index.mjs +1 -1
- package/out/store/storage/storageCallback.mjs +1 -1
- package/out/store/store.mjs +1 -1
- package/out/utils/ComponentFactory.mjs +1 -1
- package/out/utils/account/index.mjs +1 -1
- package/out/utils/account/refreshAccount.mjs +1 -1
- package/out/utils/account/refreshNativeAuthTokenLogin.mjs +1 -1
- package/out/utils/index.mjs +1 -1
- package/out/utils/transactions/getActiveTransactionsStatus.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/getInterpretedTransaction.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/helpers/getLockedAccountName.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/helpers/getReceiptMessage.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/helpers/getShardText.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/helpers/getTransactionIconInfo.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/helpers/getTransactionMessages.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/helpers/index.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/index.mjs +1 -1
- package/out/utils/transactions/getTransactionsHistory/getTransactionsHistory.mjs +1 -1
- package/out/utils/transactions/getTransactionsHistory/helpers/getCachedTransactionListItem.mjs +1 -1
- package/out/utils/transactions/getTransactionsHistory/helpers/index.mjs +1 -1
- package/out/utils/transactions/getTransactionsHistory/helpers/mapServerTransactionsToListItems.mjs +1 -1
- package/out/utils/transactions/getTransactionsHistory/index.mjs +1 -1
- package/out/utils/transactions/index.mjs +1 -1
- package/out/utils/visual/index.mjs +1 -1
- package/out/utils/visual/switchTheme.mjs +1 -1
- package/out/utils/window/getIsInIframe.mjs +1 -1
- package/out/utils/window/getWindowParentOrigin.mjs +1 -1
- package/out/utils/window/index.mjs +1 -1
- package/package.json +5 -5
- package/out/__chunks__/chunk-2WWGLFNR.mjs +0 -2
- package/out/__chunks__/chunk-BMC2YI75.mjs +0 -2
- package/out/__chunks__/chunk-C4A4E2FY.mjs +0 -2
- package/out/__chunks__/chunk-FXR3CXVB.mjs +0 -2
- package/out/__chunks__/chunk-FYEAQFW5.mjs +0 -2
- package/out/__chunks__/chunk-JIOAD7MK.mjs +0 -2
- package/out/__chunks__/chunk-KI2NE6MI.mjs +0 -2
- package/out/__chunks__/chunk-KJLFUHEH.mjs +0 -2
- package/out/__chunks__/chunk-KN6ADSRW.mjs +0 -2
- package/out/__chunks__/chunk-KQ4LLKWZ.mjs +0 -2
- package/out/__chunks__/chunk-OA5HXCGR.mjs.map +0 -7
- package/out/__chunks__/chunk-OKR2YV5J.mjs +0 -2
- package/out/__chunks__/chunk-R55WPJMP.mjs +0 -2
- package/out/__chunks__/chunk-U4MC4F2U.mjs +0 -2
- package/out/__chunks__/chunk-U6BZ2PHS.mjs +0 -2
- package/out/__chunks__/chunk-VOGVARHA.mjs +0 -2
- package/out/__chunks__/chunk-VXNZHN7T.mjs +0 -2
- package/out/__chunks__/chunk-VXNZHN7T.mjs.map +0 -7
- package/out/__chunks__/chunk-XVCSSYCP.mjs +0 -2
- package/out/__chunks__/chunk-Z35H36KH.mjs +0 -2
- package/out/__chunks__/chunk-ZDMHP47O.mjs +0 -2
- /package/out/__chunks__/{chunk-JIOAD7MK.mjs.map → chunk-2FDNVFTD.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-VRXZUSWL.mjs.map → chunk-2FHEBVWZ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-5TAQLAW3.mjs.map → chunk-2FJUAWNG.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-AQ6D3F5K.mjs.map → chunk-2Y66XRQK.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-FLN5MNNT.mjs.map → chunk-3AN3HJA5.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-OKR2YV5J.mjs.map → chunk-3Z2ACTV6.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-PH34FNHZ.mjs.map → chunk-47FDQOU2.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-2WWGLFNR.mjs.map → chunk-4JCMNQXS.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-HVUUOFDY.mjs.map → chunk-4MXAQBQ4.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-OHUOJ5P3.mjs.map → chunk-5A2ZB2NK.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-Z35H36KH.mjs.map → chunk-5FVAEFKL.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-MZBHPAM4.mjs.map → chunk-5TKJRIH7.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-6LATG7X5.mjs.map → chunk-6DI7XSHB.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-IILEKPBI.mjs.map → chunk-6DW4VXLU.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-CDQ2BNUD.mjs.map → chunk-6JSWL75O.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZFJOYMJ7.mjs.map → chunk-72BFMMSI.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-C4A4E2FY.mjs.map → chunk-77NCTJIH.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-MUYR3PCB.mjs.map → chunk-7HP3FIAW.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-WNEPIIEY.mjs.map → chunk-7XW3S67Y.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-R55WPJMP.mjs.map → chunk-AF3RP6VA.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-HAA2EO5S.mjs.map → chunk-AH5RW56M.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-5LRQIZ4G.mjs.map → chunk-BECHXPBC.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-XM4IYM4M.mjs.map → chunk-BPKM2DQN.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-7MZD7YCO.mjs.map → chunk-CRC6EHJB.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-LS3YSRRM.mjs.map → chunk-DCOMKCXN.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-YTR6YMAJ.mjs.map → chunk-DWYHYJNY.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-JVKQPCTQ.mjs.map → chunk-G26BK7D7.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4JRSZ2WY.mjs.map → chunk-HGZQIUMH.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ECTE4GIA.mjs.map → chunk-HQ3MXZM2.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-BMC2YI75.mjs.map → chunk-HSIBZ2L5.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-MI73KXKA.mjs.map → chunk-ILMJWCA5.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-OYO5HAC3.mjs.map → chunk-J6R5G7CE.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-YAMIPNLB.mjs.map → chunk-J7WJREOM.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-UGJVHUID.mjs.map → chunk-JYIAIJ37.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-B3UFF7ML.mjs.map → chunk-K4MA6VJX.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-FCH3TZNB.mjs.map → chunk-KKP56V4G.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-VOGVARHA.mjs.map → chunk-KN26DF7H.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-YUBLXI76.mjs.map → chunk-KOA4KAE3.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-GOK56W56.mjs.map → chunk-LLJ3VLPO.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-KI2NE6MI.mjs.map → chunk-LNCOC6DZ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-Q5BUVODR.mjs.map → chunk-LPXPAY7D.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-FYEAQFW5.mjs.map → chunk-LSBQBQSE.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-U4MC4F2U.mjs.map → chunk-NC2PYW67.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-KQ4LLKWZ.mjs.map → chunk-NJVYQG4N.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-SLWY5XP5.mjs.map → chunk-NMNJWV6J.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-UVHONPA5.mjs.map → chunk-NPRED3F5.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-5GAD4GPI.mjs.map → chunk-NQ2ACSWO.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-LMNAVRBQ.mjs.map → chunk-NZ5CEUB5.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-E2XW7YVE.mjs.map → chunk-O3AN3EMP.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4ADFEGIK.mjs.map → chunk-O5L6HOQJ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-37ZYC4SQ.mjs.map → chunk-O6LQEIE2.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-USDJ7CAG.mjs.map → chunk-OAKDIMYH.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-EGM63G4K.mjs.map → chunk-OWV2V6SX.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-DUNGWQ5A.mjs.map → chunk-P6PUVTFU.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-O5TU5QQI.mjs.map → chunk-PMOKDTDV.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-U6BZ2PHS.mjs.map → chunk-Q5HWS7FX.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ILGTFJZA.mjs.map → chunk-QC6KCYKL.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ASVVZSNW.mjs.map → chunk-QF3ACWOH.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-3NBR5S3K.mjs.map → chunk-QIF2DQBN.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-3PAQ2Z7N.mjs.map → chunk-QZOCKDRL.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-6ILB52XY.mjs.map → chunk-RNWJHZLH.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4PIC7DFH.mjs.map → chunk-S2RWU5BV.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-7OBI7GUK.mjs.map → chunk-S5ZROGZQ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-AYPDQETP.mjs.map → chunk-SFAWPLJB.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-TE5XVHX2.mjs.map → chunk-SUCBDFIP.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-Z745SBSQ.mjs.map → chunk-TF67ZK65.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-FXR3CXVB.mjs.map → chunk-TKZHFVMQ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZDMHP47O.mjs.map → chunk-U66UATGK.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-76URRONH.mjs.map → chunk-UCRVRBTA.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-VEEHHORJ.mjs.map → chunk-VT5BFUDT.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-Q3XYMQWN.mjs.map → chunk-WKWVAY3B.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-A5BJAB7T.mjs.map → chunk-WL56YMKX.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-LPPO6LUR.mjs.map → chunk-WXS4MAB3.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-XFUNY6KC.mjs.map → chunk-X25IIGUZ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZM5EFY6B.mjs.map → chunk-XEENI7BQ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-KN6ADSRW.mjs.map → chunk-XKBKAEYF.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-RFCXQES5.mjs.map → chunk-ZG4ZEFUR.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-D4BQCSIY.mjs.map → chunk-ZSJNTJKG.mjs.map} +0 -0
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{q as c}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{q as c}from"./chunk-DWYHYJNY.mjs";import{a as o}from"./chunk-JMC7CMTU.mjs";var r=e=>{c().setState(({account:t})=>{let s=t.address===e.address;t.accounts={[t.address]:s?e:o}},!1,"setAccount")},u=e=>c().setState(({account:t})=>{t.ledgerAccount=e},!1,"setLedgerAccount"),p=e=>c().setState(({account:t})=>{t.walletConnectAccount=e},!1,"setWalletConnectAccount"),l=e=>c().setState(({account:t})=>{t.websocketEvent={timestamp:Date.now(),message:e}},!1,"setWebsocketEvent"),m=e=>c().setState(({account:t})=>{t.websocketBatchEvent={timestamp:Date.now(),data:e}},!1,"setWebsocketBatchEvent"),A=e=>{c().setState(({account:t})=>{t.accounts[t.address].nonce=e},!1,"setAccountNonce")};export{r as a,u as b,p as c,l as d,m as e,A as f};
|
|
2
|
+
//# sourceMappingURL=chunk-KKP56V4G.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{j as p,q as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{j as p,q as e}from"./chunk-DWYHYJNY.mjs";import{c as i}from"./chunk-NTEMINYA.mjs";var T=()=>e().setState(p),a=({address:o,providerType:d})=>{e().setState(({account:r,loginInfo:t})=>{r.address=o,r.publicKey=new i(o).toHex(),t&&(t.providerType=d)},!1,"loginAction")};export{T as a,a as b};
|
|
2
|
+
//# sourceMappingURL=chunk-KOA4KAE3.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
var e={extension:"extension",metamask:"metamask",passkey:"passkey",walletConnect:"walletConnect",ledger:"ledger",crossWindow:"crossWindow",webview:"webview",none:""};export{e as a};
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
2
|
+
//# sourceMappingURL=chunk-LJX4MW7B.mjs.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
3
|
"sources": ["../../src/providers/types/providerFactory.types.ts"],
|
|
4
|
-
"sourcesContent": ["import type { IDAppProviderBase } from '@multiversx/sdk-dapp-utils';\n\nexport interface IProvider<T extends ProviderType = ProviderType>\n extends IDAppProviderBase {\n init: () => Promise<boolean>;\n login: (options?: { callbackUrl?: string; token?: string }) => Promise<{\n address: string;\n signature: string;\n multisig?: string;\n impersonate?: string;\n accessToken?: string;\n [key: string]: unknown;\n }>;\n logout: () => Promise<boolean>;\n cancelLogin?: () => void;\n getType: () => T;\n getAddress(): Promise<string | undefined>;\n}\n\nexport interface IProviderConfig {\n account?: {\n address: string;\n };\n}\n\nexport const ProviderTypeEnum = {\n extension: 'extension',\n metamask: 'metamask',\n passkey: 'passkey',\n walletConnect: 'walletConnect',\n ledger: 'ledger',\n crossWindow: 'crossWindow',\n webview: 'webview',\n none: ''\n} as const;\n\nexport type
|
|
4
|
+
"sourcesContent": ["import type { IDAppProviderBase } from '@multiversx/sdk-dapp-utils';\n\nexport interface IProvider<T extends ProviderType = ProviderType>\n extends IDAppProviderBase {\n init: () => Promise<boolean>;\n login: (options?: { callbackUrl?: string; token?: string }) => Promise<{\n address: string;\n signature: string;\n multisig?: string;\n impersonate?: string;\n accessToken?: string;\n [key: string]: unknown;\n }>;\n logout: () => Promise<boolean>;\n cancelLogin?: () => void;\n getType: () => T;\n getAddress(): Promise<string | undefined>;\n}\n\nexport interface IProviderConfig {\n account?: {\n address: string;\n };\n}\n\nexport const ProviderTypeEnum = {\n extension: 'extension',\n metamask: 'metamask',\n passkey: 'passkey',\n walletConnect: 'walletConnect',\n ledger: 'ledger',\n crossWindow: 'crossWindow',\n webview: 'webview',\n none: ''\n} as const;\n\nexport type ProviderBaseType =\n (typeof ProviderTypeEnum)[keyof typeof ProviderTypeEnum];\n\nexport type ProviderType = ProviderBaseType | (string & {}); // This allows custom providers to be used as a string\n\nexport interface IProviderFactory<T extends ProviderType = ProviderType> {\n type: T;\n anchor?: HTMLElement;\n}\n\nexport interface IProviderBase<T extends ProviderType = ProviderType> {\n name: string;\n type: T;\n iconUrl?: string;\n}\nexport interface ICustomProvider<T extends ProviderType = ProviderType>\n extends IProviderBase<T> {\n constructor: (options?: {\n address?: string;\n anchor?: HTMLElement;\n }) => Promise<IProvider>;\n}\n"],
|
|
5
5
|
"mappings": "AAyBO,IAAMA,EAAmB,CAC9B,UAAW,YACX,SAAU,WACV,QAAS,UACT,cAAe,gBACf,OAAQ,SACR,YAAa,cACb,QAAS,UACT,KAAM,EACR",
|
|
6
6
|
"names": ["ProviderTypeEnum"]
|
|
7
7
|
}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as o}from"./chunk-4TBVQD27.mjs";import{q as n}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as o}from"./chunk-4TBVQD27.mjs";import{q as n}from"./chunk-DWYHYJNY.mjs";var c=t=>n().setState(({config:e})=>{e.nativeAuthConfig=t},!1,"setNativeAuthConfig"),C=t=>n().setState(({config:e})=>{e.websocketStatus=t},!1,"setWebsocketStatus"),f=t=>n().setState(({config:e})=>{let a=t.walletConnectV2RelayAddress||o.walletConnectV2RelayAddress,s=t.walletConnectDeepLink||o.walletConnectDeepLink;e.walletConnectConfig={...t,walletConnectDeepLink:s,walletConnectV2RelayAddress:a}},!1,"setWalletConnectConfig");export{c as a,C as b,f as c};
|
|
2
|
+
//# sourceMappingURL=chunk-LLJ3VLPO.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as u}from"./chunk-L3MWDI6J.mjs";import{q as i}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as u}from"./chunk-L3MWDI6J.mjs";import{q as i}from"./chunk-DWYHYJNY.mjs";var g=({transactions:s,transactionsDisplayInfo:a,status:e,sessionInformation:t})=>{let o=Date.now().toString();return i().setState(({transactions:n})=>{n[o]={transactions:s,status:e,transactionsDisplayInfo:a,interpretedTransactions:{},sessionInformation:t}},!1,"createTransactionsSession"),o},T=({sessionId:s,status:a,errorMessage:e})=>{i().setState(({transactions:t})=>{t[s].status=a,t[s].errorMessage=e},!1,"updateTransactionsSession")},y=({sessionId:s,transaction:a})=>{let e=null;return i().setState(({transactions:t})=>{let o=t[s]?.transactions;if(o!=null){t[s].transactions=o.map(r=>r.hash===a.hash?{...r,...a??{}}:r);let n=u([...t[s].transactions]);n&&(T({sessionId:s,status:n}),e=n)}},!1,"updateTransactionStatus"),e},h=()=>{i().setState(({transactions:s,toasts:a})=>{let t=Object.keys(s).filter(n=>{let r=s[n];if(!r)return!1;let{status:c}=r;return!(c==="pending"||c==="signed"||c==="sent")});t.forEach(n=>{delete s[n]});let o=a.transactionToasts.filter(n=>!t.includes(n.toastId));a.transactionToasts=o},!1,"clearCompletedTransactions")};export{g as a,T as b,y as c,h as d};
|
|
2
|
+
//# sourceMappingURL=chunk-LPXPAY7D.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as s}from"./chunk-O7LCTC4K.mjs";import{s as m}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as s}from"./chunk-O7LCTC4K.mjs";import{s as m}from"./chunk-DWYHYJNY.mjs";import{b as a}from"./chunk-SAAOQW7P.mjs";import{o as r,u as i}from"./chunk-KD2IQ32V.mjs";import{a as c}from"./chunk-3FXHIV6O.mjs";async function b({tokenId:o}){let t=a(m()),{isNft:k}=c(o),n=o,p=k?r:i;if(!n)return{tokenDecimals:Number(t.decimals),tokenLabel:"",tokenAvatar:""};try{let{data:e}=await s.get(`${t.apiAddress}/${p}/${n}`),f=e?e?.decimals:Number(t.decimals),l=e?e?.name:"",d=e?e?.assets?.svgUrl??e?.media?.[0]?.thumbnailUrl:"";return{tokenDecimals:f,tokenLabel:l,type:e?.type,tokenAvatar:d,identifier:e?.identifier,assets:e?.assets,esdtPrice:e?.price,ticker:e?.ticker,name:e?.name}}catch(e){return{error:`Error fetching token ${n}: ${e.toString()}`,tokenDecimals:Number(t.decimals),tokenLabel:"",tokenAvatar:"",identifier:n}}}export{b as a};
|
|
2
|
+
//# sourceMappingURL=chunk-NMNJWV6J.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as t}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as t}from"./chunk-TPJ7KEUB.mjs";import{MvxLedgerConnect as r}from"@multiversx/sdk-dapp-ui/web-components/mvx-ledger-connect";async function i(n){if(!(typeof t.navigator<"u"&&t.navigator.product==="ReactNative"))try{(await import("@multiversx/sdk-dapp-ui")).defineCustomElements(n)}catch(e){console.warn("@multiversx/sdk-dapp-ui not found"+e)}}export{i as a,r as b};
|
|
2
|
+
//# sourceMappingURL=chunk-NPRED3F5.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{s as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{s as r}from"./chunk-DWYHYJNY.mjs";import{b as e}from"./chunk-SAAOQW7P.mjs";var d=s=>{let o=e(r()),t=s??o.apiAddress;return t.endsWith("/")?t.slice(0,-1):t};export{d as a};
|
|
2
|
+
//# sourceMappingURL=chunk-NQ2ACSWO.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as s}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as s}from"./chunk-HQ3MXZM2.mjs";var a=class{constructor({uiDataUpdateEvent:t,uiTag:e}){this.eventBus=null;this.uiElement=null;this.isCreatingElement=!1;this.unsubscribeFunctions=new Map;this.uiDataUpdateEvent=t,this.uiTag=e,this.data=this.getInitialData()}async init(t){this.anchor=t,await this.createUIElement(t),await this.setupEventListeners()}updateData(t){this.data={...this.data,...t},this.notifyDataUpdate()}subscribeToEventBus(t,e){if(!this.eventBus)throw new Error("eventBus is not initialized");let i=this.eventBus?.subscribe(t,e);if(i){let n=this.unsubscribeFunctions.get(t)||[];n.push(i),this.unsubscribeFunctions.set(t,n)}}notifyDataUpdate(){this.eventBus?.publish(this.uiDataUpdateEvent,this.data)}destroy(){this.unsubscribeFunctions.forEach(t=>t.forEach(e=>e())),this.unsubscribeFunctions.clear(),this.eventBus=null,this.uiElement?.remove?.(),this.uiElement=null}getInitialData(){return this.initialData}resetData(){this.data=this.getInitialData()}async createUIElement(t=this.anchor){if(this.isCreatingElement||this.uiElement)return this.uiElement;if(this.isCreatingElement=!0,this.uiElement=await s.create({name:this.uiTag,anchor:t}),this.isCreatingElement=!1,!this.uiElement)throw new Error(`Failed to create ${this.uiTag} element`);if(this.eventBus||(this.eventBus=await this.uiElement.getEventBus()),!this.eventBus)throw new Error("eventBus is not initialized");return this.uiElement}};export{a};
|
|
2
|
+
//# sourceMappingURL=chunk-NZ5CEUB5.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as g}from"./chunk-LGAWIVRO.mjs";import{s as m}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as g}from"./chunk-LGAWIVRO.mjs";import{s as m}from"./chunk-DWYHYJNY.mjs";import{b as a}from"./chunk-SAAOQW7P.mjs";import{o as s,u as o}from"./chunk-KD2IQ32V.mjs";import{a as c}from"./chunk-3FXHIV6O.mjs";async function I({tokenId:n}){let t=a(m()),r={tokenDecimals:Number(t.decimals),tokenLabel:"",tokenImageUrl:""},{isNft:k}=c(n),i=n,p=k?s:o;if(!i)return r;try{let e=await g(`${t.apiAddress}/${p}/${i}`),l=e?e?.decimals:Number(t.decimals),f=e?e?.name:"",T=e?e?.assets?.svgUrl??e?.media?.[0]?.thumbnailUrl:"";return{tokenDecimals:l,tokenLabel:f,type:e?.type,tokenImageUrl:T,identifier:e?.identifier,assets:e?.assets,esdtPrice:e?.price,ticker:e?.ticker,name:e?.name}}catch(e){return{...r,error:`${e}`}}}export{I as a};
|
|
2
|
+
//# sourceMappingURL=chunk-O3AN3EMP.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as l}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as l}from"./chunk-O3AN3EMP.mjs";import{a as c}from"./chunk-I3MK6KZJ.mjs";var f=async({receiver:n,sender:i,tokenId:s})=>{let t=null,r=null;if(!s)return{senderLockedAccount:t,receiverLockedAccount:r};try{let o=(await l({tokenId:s}))?.assets?.lockedAccounts;if(!o)return{senderLockedAccount:t,receiverLockedAccount:r};for(let e in o)if(c(e)&&(i===e&&(t=e),n===e&&(r=e)),c(o[e])&&(i===o[e]&&(t=o[e]),n===o[e]&&(r=o[e])),t&&r)return{senderLockedAccount:t,receiverLockedAccount:r}}catch(a){console.error("Error getting token details",a)}return{senderLockedAccount:t,receiverLockedAccount:r}};export{f as a};
|
|
2
|
+
//# sourceMappingURL=chunk-O5L6HOQJ.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{s as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{s as e}from"./chunk-DWYHYJNY.mjs";import{b as t}from"./chunk-SAAOQW7P.mjs";import{x as r}from"./chunk-KD2IQ32V.mjs";import i from"axios";var T=async o=>{let{apiAddress:s}=t(e()),{data:a}=await i.get(`${s}/${r}`,{params:{hashes:o.join(","),withScResults:!0}});return a};export{T as a};
|
|
2
|
+
//# sourceMappingURL=chunk-O6LQEIE2.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as i}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as i}from"./chunk-NZ5CEUB5.mjs";var c=class n extends i{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE",uiTag:"mvx-ledger-connect"});this.addressesPerPage=10;this.allAccounts=[];this.initialConnectScreenData={};this.connectScreenData={...this.initialConnectScreenData};this.initialAccountScreenData={accounts:this.allAccounts,startIndex:0,addressesPerPage:this.addressesPerPage,isLoading:!0};this.accountScreenData={...this.initialAccountScreenData};this.initialConfirmScreenData={selectedAddress:"",explorerLink:""};this.confirmScreenData={...this.initialConfirmScreenData};this.initialData={connectScreenData:this.initialConnectScreenData,accountScreenData:this.initialAccountScreenData,confirmScreenData:this.initialConfirmScreenData};this.data=this.getInitialData()}static getInstance(){return n.instance||(n.instance=new n),n.instance}updateAllAccounts(e){this.allAccounts=e,this.accountScreenData.accounts=e}updateStartIndex(e){this.accountScreenData.startIndex=e}updateConnectScreen(e){this.connectScreenData={...this.connectScreenData,...e},this.data.confirmScreenData=null,this.data.accountScreenData=null,this.data.connectScreenData=this.connectScreenData,this.notifyDataUpdate()}updateAccountScreen(e){this.accountScreenData={...this.accountScreenData,...e},this.data.confirmScreenData=null,this.data.accountScreenData=this.accountScreenData,this.notifyDataUpdate()}updateConfirmScreen(e){this.confirmScreenData={...this.confirmScreenData,...e},this.data.accountScreenData=null,this.data.confirmScreenData=this.confirmScreenData,this.notifyDataUpdate()}getAccountScreenData(){return this.data.accountScreenData}getConfirmScreenData(){return this.data.confirmScreenData}getAllAccounts(){return this.allAccounts}subscribeToProviderInit({handleRetry:e,handleCancel:t}){this.eventBus&&(this.eventBus.subscribe("CONNECT_DEVICE",e),this.eventBus.subscribe("CLOSE",t),this.eventBus.subscribe("UI_DISCONNECTED",this.destroy.bind(this)))}unsubscribeFromProviderInit({handleRetry:e,handleCancel:t}){this.eventBus&&(this.eventBus.unsubscribe("CONNECT_DEVICE",e),this.eventBus.unsubscribe("CLOSE",t),this.eventBus.unsubscribe("UI_DISCONNECTED",this.destroy.bind(this)))}subscribeToAuthEvents({handleCancel:e,handleAccessWallet:t,handleGoToPage:a}){this.eventBus&&(this.eventBus.subscribe("CLOSE",e),this.eventBus.subscribe("ACCESS_WALLET",t),this.eventBus.subscribe("GO_TO_PAGE",a))}unsubscribeFromAuthEvents({handleCancel:e,handleAccessWallet:t,handleGoToPage:a}){this.eventBus&&(this.eventBus.unsubscribe("CLOSE",e),this.eventBus.unsubscribe("ACCESS_WALLET",t),this.eventBus.unsubscribe("GO_TO_PAGE",a))}handleClose(){this.anchor?this.anchor?.dispatchEvent(new CustomEvent("ANCHOR_CLOSE",{composed:!1,bubbles:!1})):this.destroy()}resetData(){this.accountScreenData={...this.initialAccountScreenData},this.confirmScreenData={...this.initialConfirmScreenData},this.connectScreenData={...this.initialConnectScreenData},super.resetData()}async setupEventListeners(){this.eventBus&&this.eventBus.subscribe("CLOSE",this.handleClose.bind(this))}};export{c as a};
|
|
2
|
+
//# sourceMappingURL=chunk-OAKDIMYH.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as s}from"./chunk-55W25Q35.mjs";import{a as r}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as s}from"./chunk-55W25Q35.mjs";import{a as r}from"./chunk-X25IIGUZ.mjs";import e from"lodash.isempty";var p=async({transactionsSessions:t,address:i,explorerAddress:a,egldLabel:o})=>{if(e(t))return[];let n=s(t);return r({transactions:n,address:i,explorerAddress:a,egldLabel:o})};export{p as a};
|
|
2
|
+
//# sourceMappingURL=chunk-OWV2V6SX.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as u}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as u}from"./chunk-Q5HWS7FX.mjs";import{a as f}from"./chunk-2FJUAWNG.mjs";import{a as g}from"./chunk-S2RWU5BV.mjs";import{b as a}from"./chunk-DWYHYJNY.mjs";import{c as s,g as r}from"./chunk-NTEMINYA.mjs";var v=async({signMessageCallback:m,nativeAuthClientConfig:o})=>{let{address:t}=u(),c=g(),i=f(o||c),e=await i.initialize({noCache:!!o});if(!e)return null;let h=new r({address:new s(t),data:Buffer.from(`${t}${e}`)}),n=await m(h,{});if(!n?.signature)throw"Message not signed";return a({loginToken:e,signature:Buffer.from(n.signature).toString("hex")}),i.getToken({address:t,token:e,signature:Buffer.from(n.signature).toString("hex")})};export{v as a};
|
|
2
|
+
//# sourceMappingURL=chunk-P6PUVTFU.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a}from"./chunk-S2RWU5BV.mjs";var i=e=>{let t=a();return{origin:e?.origin??t.origin,blockHashShard:e?.blockHashShard,expirySeconds:e?.expirySeconds??t.expirySeconds,apiAddress:e?.apiAddress??t.apiAddress,tokenExpirationToastWarningSeconds:e?.tokenExpirationToastWarningSeconds??t.tokenExpirationToastWarningSeconds,extraInfo:e?.extraInfo??{},gatewayUrl:e?.gatewayUrl,extraRequestHeaders:e?.extraRequestHeaders??{}}};export{i as a};
|
|
2
|
+
//# sourceMappingURL=chunk-PMOKDTDV.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{e as o,f as a,g as i,h as r}from"./chunk-TQA3JDNV.mjs";import{s as c}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{e as o,f as a,g as i,h as r}from"./chunk-TQA3JDNV.mjs";import{s as c}from"./chunk-DWYHYJNY.mjs";function b(){let t=c(),l=r(t),u=i(t),T=a(t),d=o(t),e=Object.keys(d)?.length>0,n=!e&&Object.keys(l)?.length>0,s=!e&&!n&&Object.keys(u)?.length>0,f=!e&&!n&&!s&&Object.keys(T).length>0;return{pending:e,timedOut:n,fail:s,success:f}}export{b as a};
|
|
2
|
+
//# sourceMappingURL=chunk-QC6KCYKL.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as e}from"./chunk-NZ5CEUB5.mjs";var n=class t extends e{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE",uiTag:"mvx-wallet-connect"});this.initialData={wcURI:"",walletConnectDeepLink:""};this.data={...this.initialData}}static getInstance(){return t.instance||(t.instance=new t),t.instance}handleClose(a){a?.isLoginFinished||(this.anchor?this.anchor.dispatchEvent(new CustomEvent("ANCHOR_CLOSE",{composed:!1,bubbles:!1})):this.destroy())}async setupEventListeners(){this.eventBus&&(this.eventBus.subscribe("CLOSE",this.handleClose.bind(this)),this.eventBus.subscribe("UI_DISCONNECTED",this.destroy.bind(this)))}};export{n as a};
|
|
2
|
+
//# sourceMappingURL=chunk-QF3ACWOH.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as w}from"./chunk-QXC4D3AC.mjs";import{a as g}from"./chunk-YGI3KXMZ.mjs";import{a as b}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as w}from"./chunk-QXC4D3AC.mjs";import{a as g}from"./chunk-YGI3KXMZ.mjs";import{a as b}from"./chunk-5FVAEFKL.mjs";import{a as m}from"./chunk-NZYB675D.mjs";import{f}from"./chunk-PJWJZHIS.mjs";import x from"bignumber.js";var F=async({manager:e,provider:d})=>{if(!e||!d)throw new Error("Provider is not initialized.");let{network:u}=b(),s=e.getAccountScreenData()?.startIndex||0,r=e.getAllAccounts(),a=await w({baseURL:u.apiAddress}),l=o=>o.index>=s&&o.index<s+e.addressesPerPage,I=r.reduce((o,n)=>Object.assign(o,{[n.index]:n}),{}),A=r.filter(l),y=!!I[s];if(e.updateAccountScreen({isLoading:!y}),A.length>0){e.updateAccountScreen({accounts:A});return}try{let o=Math.floor(s/e.addressesPerPage),n=await d.getAccounts(o,e.addressesPerPage),L=n.map((t,c)=>({address:t,balance:"...",index:c+s})),P=[...r,...L],h=n.map(t=>m({address:t,baseURL:u.apiAddress})),j=await Promise.all(h),i=P.reduce((t,c)=>Object.assign(t,{[c.address]:c}),{});j.forEach(t=>{if(!t||!a||!a.price)return;let c=new x(t.balance),S=c.dividedBy(x(10).pow(18)).toFormat(4).toString();if(c.isNaN())return;let U=g({amount:f({input:t.balance}),usd:a?.price});i[t.address].balance=S,i[t.address].usdValue=U});let p=Object.values(i).sort((t,c)=>t.index-c.index),O=p.filter(l);e.updateAllAccounts(p),e.updateAccountScreen({accounts:O,isLoading:!1})}catch(o){console.error("Failed to fetch accounts:",o)}};export{F as a};
|
|
2
|
+
//# sourceMappingURL=chunk-QIF2DQBN.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"./chunk-
|
|
2
|
-
//# sourceMappingURL=chunk-
|
|
1
|
+
import{a as e}from"./chunk-O6LQEIE2.mjs";var i=async a=>{let r=a.map(s=>s.hash),n=await e(r);return a.map(s=>{let t=n.find(o=>o?.txHash===s.hash);return{...s,status:t?.status,invalidTransaction:t==null,results:t?.results??[],previousStatus:s.status?.toString()||"",hasStatusChanged:!!(t&&t.status!==s.status)}})};export{i as a};
|
|
2
|
+
//# sourceMappingURL=chunk-QZOCKDRL.mjs.map
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import{a as Et}from"./chunk-QZOCKDRL.mjs";import{a as gt}from"./chunk-NC2PYW67.mjs";import{a as It}from"./chunk-6UZHM5LW.mjs";import{a as O}from"./chunk-J6R5G7CE.mjs";import{a as xt}from"./chunk-S5ZROGZQ.mjs";import{a as wt}from"./chunk-77NCTJIH.mjs";import{a as At}from"./chunk-U66UATGK.mjs";import{a as Lt}from"./chunk-6DW4VXLU.mjs";import{a as y}from"./chunk-FMQYLMTU.mjs";import{a as Ct}from"./chunk-MFUQ5NBC.mjs";import{a as Rt}from"./chunk-4ODPAHHA.mjs";import{a as kt}from"./chunk-BPKM2DQN.mjs";import{b as M}from"./chunk-XEENI7BQ.mjs";import{a as Ot}from"./chunk-4JCMNQXS.mjs";import{a as Pt}from"./chunk-MDVI45IV.mjs";import{a as Mt}from"./chunk-G26BK7D7.mjs";import{a as S}from"./chunk-5FVAEFKL.mjs";import{a as ut}from"./chunk-LNCOC6DZ.mjs";import{a as yt}from"./chunk-SFAWPLJB.mjs";import{a as x}from"./chunk-72BFMMSI.mjs";import{a as k,f as bt}from"./chunk-KKP56V4G.mjs";import{b as f,c as q,d as vt}from"./chunk-LPXPAY7D.mjs";import{k as ft,l as N,n as ht}from"./chunk-65L5EBBL.mjs";import{b as Nt}from"./chunk-KOA4KAE3.mjs";import{a as P}from"./chunk-HORSXVIV.mjs";import{a as Ft}from"./chunk-Q5HWS7FX.mjs";import{a as ct}from"./chunk-2FJUAWNG.mjs";import{a as L}from"./chunk-QTKK6OSJ.mjs";import{a as rt}from"./chunk-6ACLOUQ3.mjs";import{a as A}from"./chunk-NZYB675D.mjs";import{a as at}from"./chunk-YSCND2MX.mjs";import{a as Dt}from"./chunk-NJN53MJV.mjs";import{a as lt,b as pt,g as Tt,l as dt}from"./chunk-2IUBMLF4.mjs";import{b as mt}from"./chunk-TQA3JDNV.mjs";import{a as nt,b as it,q as u,s as E}from"./chunk-DWYHYJNY.mjs";import{c as Q,d as X,f as tt}from"./chunk-UERJ6AKK.mjs";import{b as v}from"./chunk-VNLGNNIL.mjs";import{b}from"./chunk-6JM4DPOH.mjs";import{b as st,c as et,f as ot}from"./chunk-NTEMINYA.mjs";import{b as Bt}from"./chunk-UCRVRBTA.mjs";import{a as St}from"./chunk-HQ3MXZM2.mjs";import{c as w}from"./chunk-JYIAIJ37.mjs";import{b as z}from"./chunk-GGBMHKR4.mjs";import{a as C}from"./chunk-LJX4MW7B.mjs";import J from"lodash.isequal";import Ut from"lodash.isequal";var Zt="NOTIFICATIONS_FEED_STORE_SUBSCRIBE",F=class o extends yt{constructor(){super({uiDataUpdateEvent:"OPEN_NOTIFICATIONS_FEED",uiTag:"mvx-notifications-feed"});this.store=u();this.initialData={pendingTransactions:[],historicTransactions:[]};this.data={...this.initialData}}static getInstance(){return o.instance||(o.instance=new o),o.instance}isNotificationsFeedOpen(){return this.isOpen}async openNotificationsFeed(){T.getInstance().hideToasts(),await this.openUI(),await this.updateDataAndNotifications();let e=this.store.subscribe(async({toasts:n,transactions:i},{toasts:r,transactions:c})=>{(!Ut(r.transactionToasts,n.transactionToasts)||!Ut(c,i))&&await this.updateDataAndNotifications()});this.unsubscribeFunctions.set(Zt,[e]),this.eventBus?.publish("OPEN_NOTIFICATIONS_FEED"),await this.updateDataAndNotifications()}async handleCloseUI(){let s=T.getInstance();this.closeUI(),await s.showToasts()}async setupEventListeners(){this.eventBus&&(this.subscribeToEventBus("CLOSE_NOTIFICATIONS_FEED",this.handleCloseUI.bind(this)),this.subscribeToEventBus("CLEAR_NOTIFICATIONS_FEED_HISTORY",this.handleClearNotificationsFeedHistory.bind(this)))}async updateDataAndNotifications(){let{transactions:s,account:e,toasts:n,network:i}=this.store.getState(),{pendingTransactionToasts:r}=await O({toastList:n,transactionsSessions:s,account:e});this.data.pendingTransactions=r,this.data.historicTransactions=await gt.getTransactionsHistory({transactionsSessions:s,address:e.address,explorerAddress:i.network.explorerAddress,egldLabel:i.network.egldLabel}),await this.updateNotificationsFeed()}handleClearNotificationsFeedHistory(){vt(),this.resetData(),this.updateNotificationsFeed()}async updateNotificationsFeed(){this.eventBus&&(this.eventBus.publish("PENDING_TRANSACTIONS_UPDATE",this.data.pendingTransactions),this.eventBus.publish("TRANSACTIONS_HISTORY_UPDATE",this.data.historicTransactions))}};import V from"bignumber.js";var R=class o{constructor(){this.store=u();this.warningLogoutTimeoutRef=null;this.actualLogoutTimeoutRef=null;this.plannedLogoutTimeoutRef=null;this.plannedLogoutKey=null;this.init=async()=>{if(!this.shouldStart())return;let t=this.store.getState(),s=v(t),{isExpired:e}=L(s?.nativeAuthToken);e?I().logout():this.addPlannedLogout()};this.stop=()=>{clearTimeout(this.warningLogoutTimeoutRef??0),clearTimeout(this.plannedLogoutTimeoutRef??0),clearTimeout(this.actualLogoutTimeoutRef??0),this.warningLogoutTimeoutRef=null,this.plannedLogoutTimeoutRef=null,this.actualLogoutTimeoutRef=null,this.plannedLogoutKey=null};this.shouldStart=()=>{let t=this.store.getState(),s=v(t),e=tt(t);return!!(s?.nativeAuthToken&&e)};this.addPlannedLogout=()=>{let t=I(),s=Q(this.store.getState()),e=t.getType()===C.webview;if(!s||e)return;this.addLogoutWarning();let n=v(this.store.getState()),{secondsUntilExpires:i,expiresAt:r}=L(n?.nativeAuthToken),c=new V(String(i)),a=`${s}_${r}`,m=this.plannedLogoutKey===a;if(!(i&&c.isGreaterThan(0))||m)return;this.plannedLogoutKey=a,clearTimeout(this.plannedLogoutTimeoutRef??0);let d=c.times(1e3);this.actualLogoutTimeoutRef=setTimeout(()=>{T.getInstance().createCustomToast({toastId:"native-auth-logout",iconClassName:"warning",title:"Logging out",icon:"times",message:"Your session has expired!"}),this.actualLogoutTimeoutRef=null},d.toNumber()-3e3),this.plannedLogoutTimeoutRef=setTimeout(()=>{t.logout(),this.plannedLogoutTimeoutRef=null,this.plannedLogoutKey=null},d.toNumber())};this.addLogoutWarning=()=>{if(this.warningLogoutTimeoutRef)return;let t=b(this.store.getState()),s=v(this.store.getState()),{secondsUntilExpires:e}=L(s?.nativeAuthToken),n=new V(String(e)),i=n.times(1e3);if(!e||n.isLessThanOrEqualTo(0)||!t?.tokenExpirationToastWarningSeconds)return;let c=new V(t?.tokenExpirationToastWarningSeconds??0).times(1e3),a=n.times(1e3).minus(c),m=It(i.toNumber()),l=a.isLessThanOrEqualTo(0)?0:a.toNumber();clearTimeout(this.warningLogoutTimeoutRef??0),this.warningLogoutTimeoutRef=setTimeout(()=>{T.getInstance().createCustomToast({toastId:"native-auth-expired",iconClassName:"warning",title:"Session Expiration Warning",icon:"hourglass",message:`Your session will expire in ${m}!`}),this.warningLogoutTimeoutRef=null},l)}}static getInstance(){return o.instance||(o.instance=new o),o.instance}};var B={};async function Qt({serverTransaction:o,sessionId:t,isSequential:s}){let{hash:e,status:n,results:i,invalidTransaction:r,hasStatusChanged:c}=o;try{if(B[e]>30){f({sessionId:t,status:"timedOut"}),await y({sessionId:t,status:"timedOut"});return}if(r&&!s||n==="sent"){B[e]=B[e]?B[e]+1:1;return}if(s&&!n){let m=q({sessionId:t,transaction:o});await y({sessionId:t,status:m});return}if(c){let m=q({sessionId:t,transaction:o});await y({sessionId:t,status:m})}N(n)&&await Lt({sessionId:t,hash:e,results:i})}catch(a){console.error(a),f({sessionId:t,status:"timedOut"}),await y({sessionId:t,status:"timedOut"})}}async function _t({sessionId:o,transactionBatch:t,isSequential:s}){try{if(t==null)return;let e=wt(),n=Ct(t),i=await Et(n);for(let p of i)await Qt({serverTransaction:p,sessionId:o,isSequential:s});if(!i.every(p=>p.status!=="pending"))return;e&&await D();let{transactions:c}=u().getState(),a=c[o];if(a.transactions.every(p=>p.status==="success"))return f({sessionId:o,status:"success"});if(a.transactions.some(p=>p.status==="fail"))return f({sessionId:o,status:"fail"});if(a.transactions.every(p=>p.status==="not executed"))return f({sessionId:o,status:"invalid"})}catch(e){console.error(e)}}async function Wt(){let o=mt(E());if(Object.keys(o).length>0)for(let[t,{transactions:s}]of Object.entries(o))await _t({sessionId:t,transactionBatch:s})}async function U(){let o=u(),t=At(),s=null,e=null,n=X(o.getState())?.timestamp,i=()=>{Wt()},r=()=>{s??=setInterval(i,t)},c=()=>{s&&(clearInterval(s),s=null)},a=()=>{c();let p=o.subscribe(({account:{websocketEvent:g}})=>{g?.message&&n!==g.timestamp&&(n=g.timestamp,i())});w.set("websocketEventReceived",p)},m=()=>{z.status!=="not_initialized"||e||(e=setInterval(()=>{z.status==="completed"&&(clearInterval(e),e=null,a())},1e3))};i();let l=()=>{c(),e&&(clearInterval(e),e=null)},d=o.subscribe(({account:{address:p},config:{websocketStatus:g}},jt)=>{if(jt.config.websocketStatus!==g)switch(g){case"completed":a();break;case"pending":r(),m();break;default:p?r():l();break}});return w.set("websocketStatusChanged",d),w.set("websocketEventReceived",l),{stopTransactionsTracking:l}}async function j({address:o,provider:t,apiAddress:s}){let e=await A({address:o,baseURL:s});if(!e)throw new Error("Account not found");Nt({address:o,providerType:t.getType()});let n={...e,username:P(e.username),nonce:x(e)};k(n),await M(o),U(),e.shard!=null&&await xt({shard:Number(e.shard),apiAddress:s})}async function Xt(o){let{network:{apiAddress:t}}=S();await o.login();let s=await o.getAddress();if(!s)throw new Error("Address not found");return await j({address:s,provider:o,apiAddress:t}),{address:s}}async function ts({provider:o,nativeAuthConfig:t,token:s}){let{network:{apiAddress:e}}=S(),n=ct(t),i=s;i||(i=await n.initialize({noCache:!0}));let{address:r,signature:c,...a}=await o.login({token:i});if(!r)return console.warn("Login cancelled."),null;if(!c)return console.error("Failed to sign login token"),null;let l=rt(a?.accessToken)?a.accessToken:n.getToken({address:r,token:i,signature:c});it({loginToken:i,signature:c,nativeAuthToken:l});let d=await Ot({loginToken:i,extraInfoData:{multisig:a?.multisig,impersonate:a?.impersonate},address:r});return await j({address:d,provider:o,apiAddress:e}),{address:d,signature:c}}async function Ht(o,t){let s=b(E());if(s)return await ts({provider:o,nativeAuthConfig:s,token:t?.token});let{address:e}=await Xt(o);return await M(e),U(),{address:e,signature:""}}var Y={error:{title:"Error when signing".toString(),iconClassName:"danger",toastId:`${pt}-${Date.now()}`},warning:{title:"Signing canceled".toString(),iconClassName:"warning",toastId:`${lt}-${Date.now()}`}},ss={extensionResponse:"Unable to sign transactions","Transaction canceled":"Transaction canceled","cancelled by user":"Transaction signing cancelled by user","denied by the user":"Transaction signing denied by the user"},es=o=>{for(let[t,s]of Object.entries(ss))if(o.includes(t))return s;return"Error when signing"};function Z(o,t="error"){let s=o?.message,e=es(s),i=e!=="Error when signing"?"warning":t,r=Object.keys(Y).includes(i)?Y[i]:Y.error,{toastId:c,iconClassName:a,title:m}=r;return _({toastId:c,duration:1e4,icon:"times",iconClassName:a,message:e,title:m}),e}async function Gt({provider:o,transactions:t,options:s={}}){await D();let{isGuarded:e,activeGuardianAddress:n,nonce:i}=Ft(),r=o.getType()===C.ledger,c=Rt({latestNonce:i,transactions:t}),a=n&&e&&!s.skipGuardian?c?.map(l=>(l.version=st.withTxOptions().valueOf(),l.options=ot.withOptions({guarded:!0,...r?{hashSign:!0}:{}}).valueOf(),l.guardian=et.newFromBech32(n),l)):c,m=await o.signTransactions(a)??[];return bt(i+m.length),m}var W=class{constructor(t){this._isLoggingOut=!1;this.provider=t}init(){return this.provider.init()}async login(t){let s=await Ht(this.provider,t);return nt(this.provider.getType()),$t(this),R.getInstance().init(),s}isInitialized(){return this.provider.isInitialized()}async logout(t={shouldBroadcastLogoutAcrossTabs:!0}){if(this._isLoggingOut)return console.warn("Logout already in progress"),!1;this._isLoggingOut=!0;let s=await kt({provider:this.provider,options:t});return this._isLoggingOut=!1,s}getType(){return this.provider.getType()}getProvider(){return this.provider}async signTransactions(t,s){try{return await Gt({provider:this.provider,transactions:t,options:s})}catch(e){let n=Z(e);throw new Error(n)}}async signMessage(t,s){try{return await Mt({provider:this.provider,message:t,options:s})}catch(e){let n=Z(e,"warning");throw new Error(n)}}async verifyMessage(t){return await Pt(t)}cancelLogin(){this.provider.cancelLogin?.()}};var Kt=null;function $t(o){Kt=o}function I(){return Kt||new W(Bt)}var os=async()=>{try{let o=ut(),{network:t}=S();try{let s=await A({address:o,baseURL:t.apiAddress});if(s!=null){let e={...s,username:P(s.username),nonce:x(s)};return k(e),e}}catch(s){console.error("Failed getting account ",s)}}catch(o){console.error("Failed getting address ",o)}return null};async function D(){let o=I();if(o==null)throw"Provider not initialized";try{if(!o.init)throw"Current provider does not have init() function";return await o.init()?await os():void 0}catch(t){console.error("Failed initializing provider ",t)}}var H={},h={},ns=(o,t)=>{u().setState(({toasts:s})=>{let e=s.customToasts.length>0?Math.max(...s.customToasts.map(a=>parseInt(a.toastId.split("-").pop()??"0"))):0,n=t??`custom-toast-${e+1}`,i=s.customToasts.findIndex(a=>a.toastId===n),r={...o,toastId:n};if(i!==-1){s.customToasts[i]=r;return}s.customToasts.push({...r,toastId:n})},!1,"addCustomToast")},G=o=>{u().setState(({toasts:t})=>{t.customToasts=t.customToasts.filter(s=>s.toastId!==o)},!1,"removeCustomToast")},zt=()=>{u().setState(({toasts:o})=>{o.customToasts=[]},!1,"removeAllCustomToasts")},Wo=()=>{u().setState(({toasts:o})=>{o.transactionToasts=[]})},qt=({toastId:o,totalDuration:t})=>{let s="";return u().setState(({toasts:e})=>{let n=e.transactionToasts.length>0?Math.max(...e.transactionToasts.map(i=>parseInt(i.toastId.split("-").pop()??"0"))):0;s=o??`transaction-toast-${n+1}`,e.transactionToasts.push({startTime:at(),endTime:Dt(t),toastId:s})},!1,"addTransactionToast"),s},$=o=>{u().setState(({toasts:t})=>{t.transactionToasts=t.transactionToasts.filter(s=>s.toastId!==o)},!1,"removeTransactionToast"),delete h[o],delete H[o]},_=o=>{let{toasts:t}=u().getState(),s=t.customToasts.length>0?Math.max(...t.customToasts.map(n=>parseInt(n.toastId.split("-").pop()??"0"))):0,e=o.toastId||`custom-toast-${s+1}`;return o.onClose&&(h[e]=o.onClose),o.instantiateToastElement?(H[e]=o.instantiateToastElement,u().setState(({toasts:n})=>{let i=n.customToasts.findIndex(a=>a.toastId===e),r={...o,instantiateToastElement:null,toastId:e};i!==-1?n.customToasts[i]=r:n.customToasts.push(r)},!1,"createCustomToast"),e):(ns(o,e),e)};var Vt=1e4,K=class{constructor(){this.timeoutIntervals=new Map;this.successfulToastLifetime=Vt;this.start=t=>{if(this.stop(t),this.successfulToastLifetime<=0)return;let s=setTimeout(()=>{$(t)},this.successfulToastLifetime);this.timeoutIntervals.set(t,s)};this.startWithCustomDuration=(t,s)=>{if(this.stop(t),s<=0)return;let e=setTimeout(()=>{G(t);let n=h[t];n?.()},s);this.timeoutIntervals.set(t,e)};this.stop=t=>{let s=this.timeoutIntervals.get(t);s&&(clearTimeout(s),this.timeoutIntervals.delete(t))}}init({successfulToastLifetime:t}){this.successfulToastLifetime=t||Vt}destroy(){this.timeoutIntervals.forEach(t=>clearTimeout(t)),this.timeoutIntervals.clear()}};var T=class o{constructor(){this.isCreatingElement=!1;this.toastsElement=null;this.transactionToasts=[];this.customToasts=[];this.storeToastsSubscription=()=>null;this.eventBusUnsubscribeFunctions=[];this.eventBus=null;this.store=u();this.destroy(),this.lifetimeManager=new K,this.notificationsFeedManager=F.getInstance()}async init({successfulToastLifetime:t=5e3}={}){this.successfulToastLifetime=t,this.lifetimeManager.init({successfulToastLifetime:t}),await this.updateTransactionToastsList(),await this.updateCustomToastList(),await this.subscribeToEventBusNotifications(),this.storeToastsSubscription=this.store.subscribe(async({toasts:s,transactions:e},{toasts:n,transactions:i})=>{(!J(n.transactionToasts,s.transactionToasts)||!J(i,e))&&await this.updateTransactionToastsList(),J(n.customToasts,s.customToasts)||await this.updateCustomToastList()})}static getInstance(){return o.instance||(o.instance=new o),o.instance}handleCompletedTransaction(t){let{transactions:s}=this.store.getState(),e=s[t];if(!e)return!1;let{status:n}=e,i=ht(n),r=N(n),c=ft(n),a=r||c||i;return a?(this.successfulToastLifetime&&this.lifetimeManager.start(t),a):(this.lifetimeManager.stop(t),a)}async createTransactionToast(t,s){let e=qt({toastId:t,totalDuration:s});return this.handleCompletedTransaction(t),await this.updateTransactionToastsList(),e}createCustomToast(t){let s=_(t);return this.updateCustomToastList(),s}async updateTransactionToastsList(){let{toasts:t,transactions:s,account:e}=this.store.getState(),{pendingTransactionToasts:n,completedTransactionToasts:i}=await O({toastList:t,transactionsSessions:s,account:e});this.transactionToasts=[...n,...i];for(let r of t.transactionToasts)this.handleCompletedTransaction(r.toastId);await this.publishTransactionToasts()}async updateCustomToastList(){let{toasts:t}=this.store.getState();this.customToasts=[];for(let s of t.customToasts){let n="message"in s?{...s}:{...s,instantiateToastElement:H[s.toastId]};this.customToasts.push(n),s.duration&&this.lifetimeManager.startWithCustomDuration(s.toastId,s.duration)}this.eventBus?.publish("CUSTOM_TOAST_DATA_UPDATE",this.customToasts)}async createToastListElement(){return this.toastsElement?this.toastsElement:(this.isCreatingElement||(this.isCreatingElement=!0,this.toastsElement=await St.create({name:"mvx-toast-list"}),this.isCreatingElement=!1),this.toastsElement)}handleTransactionToastClose(t){this.handleCompletedTransaction(t)&&$(t)}async subscribeToEventBusNotifications(){let t=await this.createToastListElement();if(t){if(this.eventBus=await t.getEventBus(),!this.eventBus)throw new Error("eventBus is not initialized");this.eventBus.subscribe("CLOSE_TOAST",this.closeToast.bind(this)),this.eventBusUnsubscribeFunctions.push(()=>{this.eventBus?.unsubscribe("CLOSE_TOAST",this.closeToast.bind(this))}),this.eventBus.subscribe("OPEN_NOTIFICATIONS_FEED",this.handleOpenNotificationsFeed.bind(this)),this.eventBusUnsubscribeFunctions.push(()=>{this.eventBus?.unsubscribe("OPEN_NOTIFICATIONS_FEED",this.handleOpenNotificationsFeed.bind(this))})}}async showToasts(){this.eventBus?.publish("SHOW_TOAST_LIST",null),await this.updateCustomToastList(),await this.updateTransactionToastsList()}hideToasts(){this.eventBus?.publish("HIDE_TOAST_LIST",null)}async handleOpenNotificationsFeed(){this.notificationsFeedManager.openNotificationsFeed()}closeToast(t){if(this.customToasts.find(e=>e.toastId===t)){this.lifetimeManager.stop(t);let e=h[t];e?.(),G(t);return}this.handleTransactionToastClose(t)}async publishTransactionToasts(){if(this.notificationsFeedManager.isNotificationsFeedOpen()&&this.eventBus){this.eventBus.publish("TRANSACTION_TOAST_DATA_UPDATE",this.transactionToasts),this.hideToasts();return}if(!this.eventBus){let t=await this.createToastListElement();if(!t)return;this.eventBus=await t.getEventBus()}this.eventBus.publish("TRANSACTION_TOAST_DATA_UPDATE",this.transactionToasts)}destroy(){this.storeToastsSubscription(),this.lifetimeManager?.destroy(),this.notificationsFeedManager?.destroy(),zt(),this.eventBusUnsubscribeFunctions.forEach(t=>t()),this.eventBusUnsubscribeFunctions=[]}};export{F as a,H as b,h as c,ns as d,G as e,zt as f,Wo as g,qt as h,$ as i,_ as j,K as k,T as l,R as m,_t as n,Wt as o,U as p,j as q,Ht as r,Z as s,Gt as t,W as u,$t as v,I as w,D as x};
|
|
2
|
+
//# sourceMappingURL=chunk-R4PAEXYU.mjs.map
|