@multiversx/sdk-dapp 5.0.0-alpha.9 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +78 -39
- package/out/__chunks__/{chunk-LDOKRGUQ.mjs → chunk-254WMLVS.mjs} +2 -2
- package/out/__chunks__/{chunk-PCPDM6RD.mjs → chunk-2EFXW7IG.mjs} +2 -2
- package/out/__chunks__/{chunk-PVEKU2X3.mjs → chunk-2S5FRZJR.mjs} +2 -2
- package/out/__chunks__/chunk-2SIHYJET.mjs +2 -0
- package/out/__chunks__/chunk-2SIHYJET.mjs.map +7 -0
- package/out/__chunks__/chunk-3NFKZZ7W.mjs +2 -0
- package/out/__chunks__/{chunk-IMEJ3BE5.mjs.map → chunk-3NFKZZ7W.mjs.map} +3 -3
- package/out/__chunks__/chunk-3ZEUVYQF.mjs +2 -0
- package/out/__chunks__/chunk-3ZEUVYQF.mjs.map +7 -0
- package/out/__chunks__/{chunk-ST4GGUZM.mjs → chunk-42LFLNPA.mjs} +2 -2
- package/out/__chunks__/chunk-4AKPP7B3.mjs +2 -0
- package/out/__chunks__/{chunk-ZGRKIA6G.mjs → chunk-4QDHGYT4.mjs} +2 -2
- package/out/__chunks__/{chunk-ZGRKIA6G.mjs.map → chunk-4QDHGYT4.mjs.map} +2 -2
- package/out/__chunks__/{chunk-DGBTQM4A.mjs → chunk-4TZC3NF3.mjs} +2 -2
- package/out/__chunks__/{chunk-N2V7UF7S.mjs → chunk-4XP7BVJD.mjs} +2 -2
- package/out/__chunks__/chunk-4YU2DWHA.mjs +2 -0
- package/out/__chunks__/chunk-4YU2DWHA.mjs.map +7 -0
- package/out/__chunks__/chunk-4YZQBDUE.mjs +2 -0
- package/out/__chunks__/chunk-4ZZJX7E7.mjs +2 -0
- package/out/__chunks__/chunk-5LB2KNTP.mjs +2 -0
- package/out/__chunks__/chunk-5LB2KNTP.mjs.map +7 -0
- package/out/__chunks__/chunk-5OM6KD5S.mjs +2 -0
- package/out/__chunks__/chunk-6D2RBTVV.mjs +2 -0
- package/out/__chunks__/chunk-6D2RBTVV.mjs.map +7 -0
- package/out/__chunks__/{chunk-JIECCAME.mjs → chunk-6G7ATMU7.mjs} +2 -2
- package/out/__chunks__/chunk-6GNNYFMN.mjs +2 -0
- package/out/__chunks__/chunk-6JM4DPOH.mjs +2 -0
- package/out/__chunks__/{chunk-IEJTMYFW.mjs.map → chunk-6JM4DPOH.mjs.map} +3 -3
- package/out/__chunks__/{chunk-K3WBBSXJ.mjs → chunk-6P7EXGAB.mjs} +2 -2
- package/out/__chunks__/{chunk-4PHZ25O4.mjs → chunk-6RGWVDNQ.mjs} +2 -2
- package/out/__chunks__/chunk-6UZHM5LW.mjs +2 -0
- package/out/__chunks__/chunk-6UZHM5LW.mjs.map +7 -0
- package/out/__chunks__/chunk-6ZL2QC74.mjs +2 -0
- package/out/__chunks__/chunk-745QCLQC.mjs +2 -0
- package/out/__chunks__/chunk-745QCLQC.mjs.map +7 -0
- package/out/__chunks__/{chunk-RHFDU5Y4.mjs → chunk-ABHYXD3U.mjs} +2 -2
- package/out/__chunks__/{chunk-4CJBDKYR.mjs → chunk-AF2QSDSV.mjs} +2 -2
- package/out/__chunks__/{chunk-3OKWBJFM.mjs → chunk-B2RDSGON.mjs} +2 -2
- package/out/__chunks__/{chunk-XNPY3DUJ.mjs → chunk-B7ZKW5ML.mjs} +2 -2
- package/out/__chunks__/{chunk-FMUDQBZE.mjs → chunk-BETSOJFK.mjs} +2 -2
- package/out/__chunks__/chunk-BG6QTPZ4.mjs +2 -0
- package/out/__chunks__/chunk-BG6QTPZ4.mjs.map +7 -0
- package/out/__chunks__/{chunk-JZLYRNNP.mjs → chunk-BHAZ2W52.mjs} +2 -2
- package/out/__chunks__/{chunk-I7BB2JJP.mjs → chunk-BOAJJ4FX.mjs} +2 -2
- package/out/__chunks__/chunk-BOAJJ4FX.mjs.map +7 -0
- package/out/__chunks__/{chunk-PRULMJH7.mjs → chunk-BQ2I655N.mjs} +2 -2
- package/out/__chunks__/{chunk-RUPRP5GS.mjs → chunk-BVLXVOIC.mjs} +2 -2
- package/out/__chunks__/{chunk-RUPRP5GS.mjs.map → chunk-BVLXVOIC.mjs.map} +2 -2
- package/out/__chunks__/chunk-CAA4VJRH.mjs +2 -0
- package/out/__chunks__/{chunk-QD3CFFVT.mjs.map → chunk-CAA4VJRH.mjs.map} +3 -3
- package/out/__chunks__/chunk-CBF72LQF.mjs +2 -0
- package/out/__chunks__/chunk-CIY7IH2N.mjs +2 -0
- package/out/__chunks__/{chunk-EA6KZGPV.mjs → chunk-CJQAA4EP.mjs} +2 -2
- package/out/__chunks__/chunk-CKTFPRJS.mjs +2 -0
- package/out/__chunks__/chunk-CKTFPRJS.mjs.map +7 -0
- package/out/__chunks__/chunk-CVPP4HQE.mjs +2 -0
- package/out/__chunks__/chunk-CVPP4HQE.mjs.map +7 -0
- package/out/__chunks__/chunk-CYCS3K6Q.mjs +2 -0
- package/out/__chunks__/{chunk-SUN3MVLZ.mjs.map → chunk-CYCS3K6Q.mjs.map} +2 -2
- package/out/__chunks__/chunk-D5SD7UPB.mjs +2 -0
- package/out/__chunks__/chunk-D5SD7UPB.mjs.map +7 -0
- package/out/__chunks__/chunk-DGYPNF4O.mjs +2 -0
- package/out/__chunks__/chunk-E7BYYSVM.mjs +2 -0
- package/out/__chunks__/{chunk-QAVA2C6Y.mjs → chunk-EQEYL6AE.mjs} +2 -2
- package/out/__chunks__/{chunk-V6GKT3ZN.mjs → chunk-FAOCLLIW.mjs} +2 -2
- package/out/__chunks__/{chunk-A5EXECZV.mjs → chunk-FIVH6RKU.mjs} +2 -2
- package/out/__chunks__/chunk-FMQYLMTU.mjs +2 -0
- package/out/__chunks__/chunk-FMQYLMTU.mjs.map +7 -0
- package/out/__chunks__/{chunk-RIQNG4I7.mjs → chunk-FSCOQWQN.mjs} +2 -2
- package/out/__chunks__/{chunk-Z3IZ47ZD.mjs → chunk-FZFKEGPM.mjs} +2 -2
- package/out/__chunks__/{chunk-RDMU5LTQ.mjs → chunk-GFTTAANM.mjs} +2 -2
- package/out/__chunks__/{chunk-5N755C2P.mjs → chunk-GT2HLNE7.mjs} +2 -2
- package/out/__chunks__/{chunk-ITYCILLF.mjs → chunk-H7BJSM6C.mjs} +2 -2
- package/out/__chunks__/{chunk-HQSB4ISG.mjs → chunk-HIUWEH2W.mjs} +2 -2
- package/out/__chunks__/{chunk-5RVSN75H.mjs → chunk-HUITKXBO.mjs} +2 -2
- package/out/__chunks__/{chunk-PNT4VF66.mjs → chunk-HXXZKQRJ.mjs} +2 -2
- package/out/__chunks__/chunk-I37JLMZH.mjs +2 -0
- package/out/__chunks__/chunk-I6BXGQLQ.mjs +2 -0
- package/out/__chunks__/chunk-I6BXGQLQ.mjs.map +7 -0
- package/out/__chunks__/chunk-IBSC2B7Q.mjs +2 -0
- package/out/__chunks__/{chunk-LYC7ERBA.mjs → chunk-ID7WYMJZ.mjs} +2 -2
- package/out/__chunks__/chunk-ID7WYMJZ.mjs.map +7 -0
- package/out/__chunks__/chunk-IMPOALRX.mjs +2 -0
- package/out/__chunks__/{chunk-RHN3VD44.mjs.map → chunk-IMPOALRX.mjs.map} +2 -2
- package/out/__chunks__/{chunk-P3EYUM5Z.mjs → chunk-INWUHEQN.mjs} +2 -2
- package/out/__chunks__/{chunk-ZNZKP2Z7.mjs → chunk-ISPOZQQO.mjs} +2 -2
- package/out/__chunks__/{chunk-24NXU72Y.mjs → chunk-IXUYZYD2.mjs} +2 -2
- package/out/__chunks__/chunk-JR23TXKP.mjs +2 -0
- package/out/__chunks__/chunk-JR23TXKP.mjs.map +7 -0
- package/out/__chunks__/{chunk-QVQGVVKN.mjs → chunk-JZ7434LN.mjs} +2 -2
- package/out/__chunks__/{chunk-WZWDFTW3.mjs → chunk-KSMSBTTQ.mjs} +2 -2
- package/out/__chunks__/chunk-L4QPPHVR.mjs +2 -0
- package/out/__chunks__/{chunk-FP2LZG6I.mjs.map → chunk-L4QPPHVR.mjs.map} +1 -1
- package/out/__chunks__/{chunk-EOX35D4L.mjs → chunk-LIPGE2RA.mjs} +2 -2
- package/out/__chunks__/{chunk-YPCJBYUY.mjs → chunk-LUDF7ZUR.mjs} +2 -2
- package/out/__chunks__/{chunk-43DKHDU2.mjs → chunk-MRV6OG7P.mjs} +2 -2
- package/out/__chunks__/chunk-N2RYRHHL.mjs +2 -0
- package/out/__chunks__/{chunk-ZWISUUBJ.mjs → chunk-NJPTQNCT.mjs} +2 -2
- package/out/__chunks__/chunk-NPZ5PO2W.mjs +2 -0
- package/out/__chunks__/chunk-NQ6SJRHZ.mjs +2 -0
- package/out/__chunks__/{chunk-XDXMB6H5.mjs.map → chunk-NQ6SJRHZ.mjs.map} +1 -1
- package/out/__chunks__/chunk-O2DO3WJJ.mjs +2 -0
- package/out/__chunks__/chunk-O2DO3WJJ.mjs.map +7 -0
- package/out/__chunks__/{chunk-ZMEIT65B.mjs → chunk-OD4ANAAQ.mjs} +2 -2
- package/out/__chunks__/chunk-OZ4ZZI3H.mjs +2 -0
- package/out/__chunks__/{chunk-IEJARRBP.mjs.map → chunk-OZ4ZZI3H.mjs.map} +2 -2
- package/out/__chunks__/chunk-P32DZ2CO.mjs +2 -0
- package/out/__chunks__/{chunk-45WVS4H5.mjs.map → chunk-P32DZ2CO.mjs.map} +2 -2
- package/out/__chunks__/{chunk-4OEPT2V4.mjs → chunk-P3BXXGQA.mjs} +2 -2
- package/out/__chunks__/chunk-PHNC5JMP.mjs +2 -0
- package/out/__chunks__/chunk-PHNC5JMP.mjs.map +7 -0
- package/out/__chunks__/{chunk-5AR7YU5K.mjs → chunk-PJDJEPY2.mjs} +2 -2
- package/out/__chunks__/chunk-QJGFIK7H.mjs +2 -0
- package/out/__chunks__/chunk-QJGFIK7H.mjs.map +7 -0
- package/out/__chunks__/{chunk-MZNVCQVB.mjs → chunk-QSYQIJEO.mjs} +2 -2
- package/out/__chunks__/{chunk-YEXBSKXL.mjs → chunk-QWV25ZSJ.mjs} +2 -2
- package/out/__chunks__/chunk-RBUHL65H.mjs +2 -0
- package/out/__chunks__/chunk-RBUHL65H.mjs.map +7 -0
- package/out/__chunks__/chunk-RFKBUN7S.mjs +2 -0
- package/out/__chunks__/chunk-RFKBUN7S.mjs.map +7 -0
- package/out/__chunks__/{chunk-ZHGCNNB5.mjs → chunk-RM4VHHXR.mjs} +2 -2
- package/out/__chunks__/{chunk-XW2GCCBZ.mjs → chunk-RRKNYQ6D.mjs} +2 -2
- package/out/__chunks__/chunk-RSUHZ7IH.mjs +2 -0
- package/out/__chunks__/chunk-RVO7H26H.mjs +2 -0
- package/out/__chunks__/chunk-RVO7H26H.mjs.map +7 -0
- package/out/__chunks__/{chunk-NHXPNROG.mjs → chunk-S2FQWSUO.mjs} +1 -1
- package/out/__chunks__/chunk-S2FQWSUO.mjs.map +7 -0
- package/out/__chunks__/{chunk-AJOTPFJL.mjs → chunk-S4WKQEYF.mjs} +2 -2
- package/out/__chunks__/chunk-SLH6IQJJ.mjs +2 -0
- package/out/__chunks__/chunk-SLH6IQJJ.mjs.map +7 -0
- package/out/__chunks__/{chunk-I7ODJJY3.mjs → chunk-TI73UXGG.mjs} +2 -2
- package/out/__chunks__/chunk-TNXSVX5O.mjs +2 -0
- package/out/__chunks__/chunk-TNXSVX5O.mjs.map +7 -0
- package/out/__chunks__/chunk-TQA3JDNV.mjs +2 -0
- package/out/__chunks__/chunk-TQA3JDNV.mjs.map +7 -0
- package/out/__chunks__/{chunk-RI7FD4HM.mjs → chunk-TSUMQ3HX.mjs} +2 -2
- package/out/__chunks__/{chunk-RI7FD4HM.mjs.map → chunk-TSUMQ3HX.mjs.map} +1 -1
- package/out/__chunks__/{chunk-426U6FXN.mjs → chunk-U34BNBOX.mjs} +2 -2
- package/out/__chunks__/{chunk-SPSO2A53.mjs → chunk-U64LDJTG.mjs} +2 -2
- package/out/__chunks__/chunk-UAW7SD6P.mjs +2 -0
- package/out/__chunks__/{chunk-N6FJMYEB.mjs → chunk-V2C7APME.mjs} +2 -2
- package/out/__chunks__/{chunk-A64HMPMV.mjs → chunk-VFAKQ7NM.mjs} +2 -2
- package/out/__chunks__/chunk-VQAKIVIO.mjs +2 -0
- package/out/__chunks__/chunk-VQAKIVIO.mjs.map +7 -0
- package/out/__chunks__/{chunk-ETHHR4HF.mjs → chunk-VXLJWKLG.mjs} +2 -2
- package/out/__chunks__/chunk-WHEXX3BD.mjs +1 -0
- package/out/__chunks__/chunk-WPXNKIUP.mjs +2 -0
- package/out/__chunks__/chunk-WPXNKIUP.mjs.map +7 -0
- package/out/__chunks__/{chunk-4TSUWSFU.mjs → chunk-XPYJSDNF.mjs} +2 -2
- package/out/__chunks__/chunk-YA5U6YEL.mjs +2 -0
- package/out/__chunks__/{chunk-RXAVE5OL.mjs → chunk-YKRSCVRE.mjs} +2 -2
- package/out/__chunks__/chunk-YO3ATAA6.mjs +2 -0
- package/out/__chunks__/chunk-YO3ATAA6.mjs.map +7 -0
- package/out/__chunks__/chunk-YUITECZ5.mjs +1 -0
- package/out/__chunks__/chunk-Z4OHB36I.mjs +2 -0
- package/out/__chunks__/chunk-ZWVYAOKB.mjs +2 -0
- package/out/__chunks__/chunk-ZWVYAOKB.mjs.map +7 -0
- package/out/__chunks__/{chunk-SJYCKFH4.mjs → chunk-ZXIBFH6X.mjs} +2 -2
- package/out/__mocks__/accountConfig.mjs +1 -1
- package/out/__mocks__/index.mjs +1 -1
- package/out/__mocks__/server.mjs +1 -1
- 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/transactions.constants.d.ts +1 -0
- package/out/constants/transactions.constants.js +2 -1
- package/out/constants/transactions.constants.js.map +1 -1
- package/out/constants/transactions.constants.mjs +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/sdkWebWalletCrossWindowProvider.d.ts +2 -0
- package/out/lib/sdkWebWalletCrossWindowProvider.js +4 -1
- package/out/lib/sdkWebWalletCrossWindowProvider.js.map +1 -1
- package/out/lib/sdkWebWalletCrossWindowProvider.mjs +1 -1
- package/out/managers/LogoutManager/LogoutManager.d.ts +15 -0
- package/out/managers/LogoutManager/LogoutManager.js +137 -0
- package/out/managers/LogoutManager/LogoutManager.js.map +1 -0
- package/out/managers/LogoutManager/LogoutManager.mjs +2 -0
- package/out/managers/LogoutManager/helpers/getHumanReadableTokenExpirationTime.d.ts +1 -0
- package/out/managers/LogoutManager/helpers/getHumanReadableTokenExpirationTime.js +33 -0
- package/out/managers/LogoutManager/helpers/getHumanReadableTokenExpirationTime.js.map +1 -0
- package/out/managers/LogoutManager/helpers/getHumanReadableTokenExpirationTime.mjs +2 -0
- package/out/managers/LogoutManager/helpers/tests/getHumanReadableTokenExpirationTime.test.d.ts +1 -0
- package/out/managers/LogoutManager/helpers/tests/getHumanReadableTokenExpirationTime.test.js +48 -0
- package/out/managers/LogoutManager/helpers/tests/getHumanReadableTokenExpirationTime.test.js.map +1 -0
- package/out/managers/NotificationsFeedManager/NotificationsFeedManager.d.ts +2 -1
- package/out/managers/NotificationsFeedManager/NotificationsFeedManager.js +13 -3
- package/out/managers/NotificationsFeedManager/NotificationsFeedManager.js.map +1 -1
- package/out/managers/NotificationsFeedManager/NotificationsFeedManager.mjs +1 -1
- package/out/managers/NotificationsFeedManager/index.mjs +1 -1
- package/out/managers/TransactionManager/TransactionManager.d.ts +17 -5
- package/out/managers/TransactionManager/TransactionManager.js +18 -1
- package/out/managers/TransactionManager/TransactionManager.js.map +1 -1
- package/out/managers/TransactionManager/TransactionManager.mjs +1 -1
- package/out/managers/TransactionManager/TransactionManager.types.d.ts +12 -0
- package/out/{providers/strategies/CrossWindowProviderStrategy/types/crossWindow.types.js → managers/TransactionManager/TransactionManager.types.js} +1 -1
- package/out/managers/TransactionManager/TransactionManager.types.js.map +1 -0
- package/out/managers/TransactionManager/TransactionManager.types.mjs +1 -0
- package/out/managers/TransactionManager/helpers/getAreTransactionsCorssShards.mjs +1 -1
- package/out/managers/TransactionManager/helpers/getToastDuration.mjs +1 -1
- package/out/managers/TransactionManager/helpers/getTransactionsStatus.mjs +1 -1
- package/out/managers/TransactionManager/helpers/sessionCallbacks.d.ts +7 -0
- package/out/managers/TransactionManager/helpers/sessionCallbacks.js +14 -0
- package/out/managers/TransactionManager/helpers/sessionCallbacks.js.map +1 -0
- package/out/managers/TransactionManager/helpers/sessionCallbacks.mjs +2 -0
- package/out/managers/TransactionManager/index.mjs +1 -1
- package/out/managers/UnlockPanelManager/UnlockPanelManager.js +1 -3
- package/out/managers/UnlockPanelManager/UnlockPanelManager.js.map +1 -1
- package/out/managers/UnlockPanelManager/UnlockPanelManager.mjs +1 -1
- package/out/managers/UnlockPanelManager/UnlockPanelManager.types.d.ts +12 -5
- package/out/managers/UnlockPanelManager/UnlockPanelManager.types.js.map +1 -1
- package/out/managers/UnlockPanelManager/UnlockPanelManager.types.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.d.ts +0 -1
- package/out/managers/internal/LedgerIdleStateManager/LedgerIdleStateManager.js +7 -14
- package/out/managers/internal/LedgerIdleStateManager/LedgerIdleStateManager.js.map +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.d.ts +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.d.ts +6 -4
- package/out/managers/internal/ToastManager/ToastManager.js +27 -19
- package/out/managers/internal/ToastManager/ToastManager.js.map +1 -1
- package/out/managers/internal/ToastManager/ToastManager.mjs +1 -1
- package/out/managers/internal/ToastManager/helpers/LifetimeManager.js +1 -1
- package/out/managers/internal/ToastManager/helpers/LifetimeManager.js.map +1 -1
- package/out/managers/internal/ToastManager/helpers/LifetimeManager.mjs +1 -1
- package/out/managers/internal/ToastManager/helpers/createToastsFromTransactions.js.map +1 -1
- package/out/managers/internal/ToastManager/helpers/createToastsFromTransactions.mjs +1 -1
- package/out/managers/internal/ToastManager/helpers/createTransactionToast.mjs +1 -1
- package/out/managers/internal/ToastManager/helpers/getToastDataStateByStatus.mjs +1 -1
- package/out/managers/internal/ToastManager/types/index.mjs +1 -1
- package/out/managers/internal/ToastManager/types/toast.types.d.ts +3 -1
- package/out/managers/internal/ToastManager/types/toast.types.js +2 -0
- package/out/managers/internal/ToastManager/types/toast.types.js.map +1 -1
- package/out/managers/internal/ToastManager/types/toast.types.mjs +1 -1
- package/out/managers/internal/UIBaseManager/UIBaseManager.d.ts +1 -1
- package/out/managers/internal/UIBaseManager/UIBaseManager.js +2 -2
- package/out/managers/internal/UIBaseManager/UIBaseManager.js.map +1 -1
- package/out/managers/internal/UIBaseManager/UIBaseManager.mjs +1 -1
- package/out/managers/internal/WalletConnectStateManager/WalletConnectStateManager.js +2 -1
- package/out/managers/internal/WalletConnectStateManager/WalletConnectStateManager.js.map +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.js +16 -8
- package/out/methods/initApp/initApp.js.map +1 -1
- package/out/methods/initApp/initApp.mjs +1 -1
- package/out/methods/initApp/initApp.mjs.map +3 -3
- package/out/methods/initApp/initApp.types.d.ts +34 -5
- 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.js +27 -10
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/checkBatch.js.map +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.d.ts +1 -1
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/manageFailedTransactions.js +7 -2
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/manageFailedTransactions.js.map +1 -1
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/manageFailedTransactions.mjs +1 -1
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/runSessionCallbacks.d.ts +7 -0
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/runSessionCallbacks.js +24 -0
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/runSessionCallbacks.js.map +1 -0
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/runSessionCallbacks.mjs +2 -0
- package/out/methods/trackTransactions/helpers/checkTransactionStatus/runSessionCallbacks.mjs.map +7 -0
- package/out/methods/trackTransactions/helpers/getPollingInterval.mjs +1 -1
- package/out/methods/trackTransactions/trackTransactions.mjs +1 -1
- package/out/methods/transactions/getFailedTransactions.d.ts +1 -0
- package/out/methods/transactions/getFailedTransactions.js +10 -0
- package/out/methods/transactions/getFailedTransactions.js.map +1 -0
- package/out/methods/transactions/getFailedTransactions.mjs +2 -0
- package/out/methods/transactions/getFailedTransactions.mjs.map +7 -0
- package/out/methods/transactions/getFailedTransactionsSessions.d.ts +1 -0
- package/out/methods/transactions/getFailedTransactionsSessions.js +10 -0
- package/out/methods/transactions/getFailedTransactionsSessions.js.map +1 -0
- package/out/methods/transactions/getFailedTransactionsSessions.mjs +2 -0
- package/out/methods/transactions/getFailedTransactionsSessions.mjs.map +7 -0
- package/out/methods/transactions/getPendingTransactions.mjs +1 -1
- package/out/methods/transactions/getPendingTransactionsSessions.mjs +1 -1
- package/out/methods/transactions/getSuccessfulTransactions.d.ts +1 -0
- package/out/methods/transactions/getSuccessfulTransactions.js +10 -0
- package/out/methods/transactions/getSuccessfulTransactions.js.map +1 -0
- package/out/methods/transactions/getSuccessfulTransactions.mjs +2 -0
- package/out/methods/transactions/getSuccessfulTransactions.mjs.map +7 -0
- package/out/methods/transactions/getSuccessfulTransactionsSessions.d.ts +1 -0
- package/out/methods/transactions/getSuccessfulTransactionsSessions.js +10 -0
- package/out/methods/transactions/getSuccessfulTransactionsSessions.js.map +1 -0
- package/out/methods/transactions/getSuccessfulTransactionsSessions.mjs +2 -0
- package/out/methods/transactions/getSuccessfulTransactionsSessions.mjs.map +7 -0
- package/out/methods/transactions/getTransactionSessions.mjs +1 -1
- package/out/providers/DappProvider/DappProvider.d.ts +1 -2
- package/out/providers/DappProvider/DappProvider.js +16 -6
- package/out/providers/DappProvider/DappProvider.js.map +1 -1
- 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.mjs +1 -1
- package/out/providers/DappProvider/helpers/logout/logout.js +1 -7
- package/out/providers/DappProvider/helpers/logout/logout.js.map +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.js +0 -5
- package/out/providers/DappProvider/helpers/signMessage/signMessageWithProvider.js.map +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.js +10 -8
- package/out/providers/ProviderFactory.js.map +1 -1
- 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.js +2 -1
- package/out/providers/helpers/clearInitiatedLogins.js.map +1 -1
- package/out/providers/helpers/clearInitiatedLogins.mjs +1 -1
- package/out/providers/helpers/emptyProvider.mjs +1 -1
- package/out/providers/helpers/restoreProvider.js +6 -3
- package/out/providers/helpers/restoreProvider.js.map +1 -1
- 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.d.ts +0 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/CrossWindowProviderStrategy.js +0 -15
- package/out/providers/strategies/CrossWindowProviderStrategy/CrossWindowProviderStrategy.js.map +1 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/CrossWindowProviderStrategy.mjs +1 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/index.d.ts +0 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/index.js +0 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/index.js.map +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.js +13 -2
- package/out/providers/strategies/WalletConnectProviderStrategy/WalletConnectProviderStrategy.js.map +1 -1
- package/out/providers/strategies/WalletConnectProviderStrategy/WalletConnectProviderStrategy.mjs +1 -1
- package/out/providers/strategies/WalletConnectProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/WalletConnectProviderStrategy/types/index.mjs +1 -1
- package/out/providers/strategies/WalletConnectProviderStrategy/types/walletConnect.types.d.ts +1 -0
- package/out/providers/strategies/WalletConnectProviderStrategy/types/walletConnect.types.mjs +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/WebviewClient.d.ts +20 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/WebviewClient.js +147 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/WebviewClient.js.map +1 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/WebviewClient.mjs +2 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/WebviewClient.mjs.map +7 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/index.d.ts +1 -0
- package/out/providers/strategies/{CrossWindowProviderStrategy/types → WebviewProviderStrategy/WebviewClient}/index.js +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/index.js.map +1 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/index.mjs +2 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/index.mjs.map +7 -0
- package/out/providers/strategies/WebviewProviderStrategy/WebviewProviderStrategy.js +9 -1
- package/out/providers/strategies/WebviewProviderStrategy/WebviewProviderStrategy.js.map +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/WebviewProviderStrategy.mjs +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/index.mjs +1 -1
- package/out/providers/strategies/WebviewProviderStrategy/tests/webview.test.js +20 -17
- package/out/providers/strategies/WebviewProviderStrategy/tests/webview.test.js.map +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.js +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/getCommonData.js.map +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/getCommonData.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/decodeDataField.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/getExtractTransactionsInfo.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/tests/getCommonData.test.js +6 -6
- package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/tests/getCommonData.test.js.map +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getFeeData.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getMultiEsdtTransferData/getMultiEsdtTransferData.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getMultiEsdtTransferData/helpers/getTokenFromData.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/getMultiEsdtTransferData/helpers/parseMultiEsdtTransferDataForMultipleTransactions.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/guardTransactions/getCrossWindowProvider.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/guardTransactions/guardTransactions.js +0 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/guardTransactions/guardTransactions.js.map +1 -1
- package/out/providers/strategies/helpers/signTransactions/helpers/guardTransactions/guardTransactions.mjs +1 -1
- package/out/providers/strategies/helpers/signTransactions/signTransactions.js +27 -20
- package/out/providers/strategies/helpers/signTransactions/signTransactions.js.map +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.d.ts +1 -2
- package/out/providers/types/providerFactory.types.js.map +1 -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.d.ts +1 -0
- package/out/react/transactions/useGetFailedTransactions.js +11 -0
- package/out/react/transactions/useGetFailedTransactions.js.map +1 -0
- package/out/react/transactions/useGetFailedTransactions.mjs +2 -0
- package/out/react/transactions/useGetFailedTransactions.mjs.map +7 -0
- package/out/react/transactions/useGetFailedTransactionsSessions.d.ts +1 -0
- package/out/react/transactions/useGetFailedTransactionsSessions.js +11 -0
- package/out/react/transactions/useGetFailedTransactionsSessions.js.map +1 -0
- package/out/react/transactions/useGetFailedTransactionsSessions.mjs +2 -0
- package/out/react/transactions/useGetFailedTransactionsSessions.mjs.map +7 -0
- package/out/react/transactions/useGetPendingTransactions.mjs +1 -1
- package/out/react/transactions/useGetPendingTransactionsSessions.mjs +1 -1
- package/out/react/transactions/useGetSuccessfulTransactions.d.ts +1 -0
- package/out/react/transactions/useGetSuccessfulTransactions.js +11 -0
- package/out/react/transactions/useGetSuccessfulTransactions.js.map +1 -0
- package/out/react/transactions/useGetSuccessfulTransactions.mjs +2 -0
- package/out/react/transactions/useGetSuccessfulTransactions.mjs.map +7 -0
- package/out/react/transactions/useGetSuccessfulTransactionsSessions.d.ts +1 -0
- package/out/react/transactions/useGetSuccessfulTransactionsSessions.js +11 -0
- package/out/react/transactions/useGetSuccessfulTransactionsSessions.js.map +1 -0
- package/out/react/transactions/useGetSuccessfulTransactionsSessions.mjs +2 -0
- package/out/react/transactions/useGetSuccessfulTransactionsSessions.mjs.map +7 -0
- 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.d.ts +2 -1
- package/out/services/nativeAuth/methods/getDefaultNativeAuthConfig.js +12 -5
- package/out/services/nativeAuth/methods/getDefaultNativeAuthConfig.js.map +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.js +6 -8
- package/out/services/nativeAuth/nativeAuth.js.map +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.d.ts +0 -2
- package/out/store/actions/config/configActions.js +1 -5
- package/out/store/actions/config/configActions.js.map +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.js.map +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.d.ts +1 -1
- package/out/store/actions/toasts/toastsActions.js +3 -1
- package/out/store/actions/toasts/toastsActions.js.map +1 -1
- package/out/store/actions/toasts/toastsActions.mjs +1 -1
- package/out/store/actions/transactions/transactionsActions.d.ts +6 -4
- package/out/store/actions/transactions/transactionsActions.js +16 -7
- package/out/store/actions/transactions/transactionsActions.js.map +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/selectors/configSelectors.d.ts +0 -1
- package/out/store/selectors/configSelectors.js +1 -5
- package/out/store/selectors/configSelectors.js.map +1 -1
- package/out/store/selectors/configSelectors.mjs +1 -1
- package/out/store/selectors/index.mjs +1 -1
- package/out/store/selectors/transactionsSelector.d.ts +2 -0
- package/out/store/selectors/transactionsSelector.js +29 -1
- package/out/store/selectors/transactionsSelector.js.map +1 -1
- package/out/store/selectors/transactionsSelector.mjs +1 -1
- package/out/store/slices/config/config.types.d.ts +0 -2
- package/out/store/slices/config/configSlice.js +0 -1
- package/out/store/slices/config/configSlice.js.map +1 -1
- package/out/store/slices/config/configSlice.mjs +1 -1
- package/out/store/slices/config/index.mjs +1 -1
- package/out/store/slices/index.mjs +1 -1
- 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/types/index.d.ts +1 -0
- package/out/types/index.js +1 -0
- package/out/types/index.js.map +1 -1
- package/out/types/index.mjs +1 -1
- package/out/types/theme.types.d.ts +4 -0
- package/out/types/theme.types.js +9 -0
- package/out/types/theme.types.js.map +1 -0
- package/out/types/theme.types.mjs +2 -0
- package/out/types/theme.types.mjs.map +7 -0
- package/out/types/transactions.types.d.ts +4 -0
- package/out/types/transactions.types.mjs.map +1 -1
- package/out/utils/ComponentFactory.d.ts +14 -0
- package/out/utils/{createUIElement.js → ComponentFactory.js} +14 -4
- package/out/utils/ComponentFactory.js.map +1 -0
- package/out/utils/ComponentFactory.mjs +2 -0
- package/out/utils/ComponentFactory.mjs.map +7 -0
- package/out/utils/account/index.d.ts +1 -0
- package/out/utils/account/index.js +1 -0
- package/out/utils/account/index.js.map +1 -1
- package/out/utils/account/index.mjs +1 -1
- package/out/utils/account/refreshAccount.mjs +1 -1
- package/out/{core/providers/DappProvider/helpers/login/helpers → utils/account}/refreshNativeAuthTokenLogin.d.ts +2 -2
- package/out/{core/providers/DappProvider/helpers/login/helpers → utils/account}/refreshNativeAuthTokenLogin.js +6 -9
- package/out/utils/account/refreshNativeAuthTokenLogin.js.map +1 -0
- package/out/utils/account/refreshNativeAuthTokenLogin.mjs +2 -0
- package/out/utils/account/refreshNativeAuthTokenLogin.mjs.map +7 -0
- package/out/utils/decoders/index.mjs +1 -1
- package/out/utils/index.d.ts +1 -0
- package/out/utils/index.js +1 -0
- package/out/utils/index.js.map +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/getTransactionValue/getTransactionValue.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/helpers/getTitleText.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/helpers/getValueFromDataField.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/helpers/getValueFromOperations.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/helpers/index.mjs +1 -1
- package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/index.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/getTokenFromData.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/getTransactionAction.mjs +1 -1
- package/out/utils/transactions/getTransactionsHistory/helpers/getTransactionAsset.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/helpers/mapTransactionToListItem.mjs +1 -1
- package/out/utils/transactions/getTransactionsHistory/index.mjs +1 -1
- package/out/utils/transactions/index.mjs +1 -1
- package/out/utils/validation/index.mjs +1 -1
- package/out/utils/validation/isContract.mjs +1 -1
- package/out/utils/visual/index.d.ts +1 -0
- package/out/utils/visual/index.js +18 -0
- package/out/utils/visual/index.js.map +1 -0
- package/out/utils/visual/index.mjs +2 -0
- package/out/utils/visual/index.mjs.map +7 -0
- package/out/utils/visual/switchTheme.d.ts +2 -0
- package/out/utils/visual/switchTheme.js +15 -0
- package/out/utils/visual/switchTheme.js.map +1 -0
- package/out/utils/visual/switchTheme.mjs +2 -0
- package/out/utils/visual/switchTheme.mjs.map +7 -0
- package/out/utils/walletconnect/__mocks__/sdkWalletconnectProvider.mjs +1 -1
- package/out/utils/window/getIsInIframe.mjs +1 -1
- package/out/utils/window/getWindowLocation.js +7 -1
- package/out/utils/window/getWindowLocation.js.map +1 -1
- package/out/utils/window/getWindowLocation.mjs +1 -1
- package/out/utils/window/getWindowParentOrigin.mjs +1 -1
- package/out/utils/window/index.mjs +1 -1
- package/package.json +14 -14
- package/out/__chunks__/chunk-2GSNHNKW.mjs +0 -1
- package/out/__chunks__/chunk-3RRSLNNU.mjs +0 -2
- package/out/__chunks__/chunk-3RRSLNNU.mjs.map +0 -7
- package/out/__chunks__/chunk-45WVS4H5.mjs +0 -2
- package/out/__chunks__/chunk-4MQGFX5E.mjs +0 -2
- package/out/__chunks__/chunk-4ROJWFSB.mjs +0 -2
- package/out/__chunks__/chunk-762K2LVS.mjs +0 -2
- package/out/__chunks__/chunk-762K2LVS.mjs.map +0 -7
- package/out/__chunks__/chunk-A5M7ZH6X.mjs +0 -2
- package/out/__chunks__/chunk-ABKSM4D4.mjs +0 -2
- package/out/__chunks__/chunk-ABKSM4D4.mjs.map +0 -7
- package/out/__chunks__/chunk-ASWTHX52.mjs +0 -2
- package/out/__chunks__/chunk-CG25USRH.mjs +0 -2
- package/out/__chunks__/chunk-CG25USRH.mjs.map +0 -7
- package/out/__chunks__/chunk-CO3V5DOG.mjs +0 -1
- package/out/__chunks__/chunk-CTUOKFTQ.mjs +0 -2
- package/out/__chunks__/chunk-CTUOKFTQ.mjs.map +0 -7
- package/out/__chunks__/chunk-CUZ44CDY.mjs +0 -2
- package/out/__chunks__/chunk-CUZ44CDY.mjs.map +0 -7
- package/out/__chunks__/chunk-DEAM4WOQ.mjs +0 -2
- package/out/__chunks__/chunk-DKGAK7SX.mjs +0 -2
- package/out/__chunks__/chunk-DKGAK7SX.mjs.map +0 -7
- package/out/__chunks__/chunk-DQKFSHIR.mjs +0 -2
- package/out/__chunks__/chunk-DQKFSHIR.mjs.map +0 -7
- package/out/__chunks__/chunk-ETES5ZQ7.mjs +0 -2
- package/out/__chunks__/chunk-EXEJDQ3E.mjs +0 -2
- package/out/__chunks__/chunk-EXEJDQ3E.mjs.map +0 -7
- package/out/__chunks__/chunk-FFNSZC37.mjs +0 -2
- package/out/__chunks__/chunk-FFNSZC37.mjs.map +0 -7
- package/out/__chunks__/chunk-FLC6QSZB.mjs +0 -1
- package/out/__chunks__/chunk-FP2LZG6I.mjs +0 -2
- package/out/__chunks__/chunk-GGJ4EA5D.mjs +0 -2
- package/out/__chunks__/chunk-GZLK5ERT.mjs +0 -2
- package/out/__chunks__/chunk-GZLK5ERT.mjs.map +0 -7
- package/out/__chunks__/chunk-HO3JCUZA.mjs +0 -2
- package/out/__chunks__/chunk-HOYYQCKG.mjs +0 -2
- package/out/__chunks__/chunk-I7BB2JJP.mjs.map +0 -7
- package/out/__chunks__/chunk-IEJARRBP.mjs +0 -2
- package/out/__chunks__/chunk-IEJTMYFW.mjs +0 -2
- package/out/__chunks__/chunk-IMEJ3BE5.mjs +0 -2
- package/out/__chunks__/chunk-IMGZJVC6.mjs +0 -2
- package/out/__chunks__/chunk-IMGZJVC6.mjs.map +0 -7
- package/out/__chunks__/chunk-JR3FBBRR.mjs +0 -2
- package/out/__chunks__/chunk-JR3FBBRR.mjs.map +0 -7
- package/out/__chunks__/chunk-LRHRFWQ4.mjs +0 -2
- package/out/__chunks__/chunk-LRHRFWQ4.mjs.map +0 -7
- package/out/__chunks__/chunk-LTFLMSOC.mjs +0 -2
- package/out/__chunks__/chunk-LTFLMSOC.mjs.map +0 -7
- package/out/__chunks__/chunk-LYC7ERBA.mjs.map +0 -7
- package/out/__chunks__/chunk-LYTBUMNM.mjs +0 -2
- package/out/__chunks__/chunk-MIQ3KCUL.mjs +0 -2
- package/out/__chunks__/chunk-MIQ3KCUL.mjs.map +0 -7
- package/out/__chunks__/chunk-NHXPNROG.mjs.map +0 -7
- package/out/__chunks__/chunk-NXKEIB75.mjs +0 -2
- package/out/__chunks__/chunk-QCXM7FCT.mjs +0 -2
- package/out/__chunks__/chunk-QD3CFFVT.mjs +0 -2
- package/out/__chunks__/chunk-QMCJDKKV.mjs +0 -2
- package/out/__chunks__/chunk-QMCJDKKV.mjs.map +0 -7
- package/out/__chunks__/chunk-R3TQP7YH.mjs +0 -2
- package/out/__chunks__/chunk-RBN5PDCE.mjs +0 -2
- package/out/__chunks__/chunk-RHN3VD44.mjs +0 -2
- package/out/__chunks__/chunk-RMF4WLMK.mjs +0 -2
- package/out/__chunks__/chunk-RMF4WLMK.mjs.map +0 -7
- package/out/__chunks__/chunk-RNZEARAQ.mjs +0 -2
- package/out/__chunks__/chunk-SB35K4FJ.mjs +0 -2
- package/out/__chunks__/chunk-SB35K4FJ.mjs.map +0 -7
- package/out/__chunks__/chunk-SUN3MVLZ.mjs +0 -2
- package/out/__chunks__/chunk-T3HV6CCC.mjs +0 -2
- package/out/__chunks__/chunk-T3HV6CCC.mjs.map +0 -7
- package/out/__chunks__/chunk-UAZVYE3I.mjs +0 -2
- package/out/__chunks__/chunk-UHDDSK3N.mjs +0 -2
- package/out/__chunks__/chunk-WO6GJTV2.mjs +0 -2
- package/out/__chunks__/chunk-WO6GJTV2.mjs.map +0 -7
- package/out/__chunks__/chunk-XDXMB6H5.mjs +0 -2
- package/out/__chunks__/chunk-YB2E5WOO.mjs +0 -2
- package/out/__chunks__/chunk-YB2E5WOO.mjs.map +0 -7
- package/out/__chunks__/chunk-ZTSNKYSA.mjs +0 -2
- package/out/core/providers/DappProvider/helpers/login/helpers/refreshNativeAuthTokenLogin.js.map +0 -1
- package/out/core/providers/DappProvider/helpers/login/helpers/refreshNativeAuthTokenLogin.mjs +0 -2
- package/out/core/providers/DappProvider/helpers/login/helpers/refreshNativeAuthTokenLogin.mjs.map +0 -7
- package/out/providers/strategies/CrossWindowProviderStrategy/types/crossWindow.types.d.ts +0 -6
- package/out/providers/strategies/CrossWindowProviderStrategy/types/crossWindow.types.js.map +0 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/types/crossWindow.types.mjs +0 -2
- package/out/providers/strategies/CrossWindowProviderStrategy/types/index.d.ts +0 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/types/index.js.map +0 -1
- package/out/providers/strategies/CrossWindowProviderStrategy/types/index.mjs +0 -2
- package/out/utils/createUIElement.d.ts +0 -9
- package/out/utils/createUIElement.js.map +0 -1
- package/out/utils/createUIElement.mjs +0 -2
- /package/out/__chunks__/{chunk-LDOKRGUQ.mjs.map → chunk-254WMLVS.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-PCPDM6RD.mjs.map → chunk-2EFXW7IG.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-PVEKU2X3.mjs.map → chunk-2S5FRZJR.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ST4GGUZM.mjs.map → chunk-42LFLNPA.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-GGJ4EA5D.mjs.map → chunk-4AKPP7B3.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-DGBTQM4A.mjs.map → chunk-4TZC3NF3.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-N2V7UF7S.mjs.map → chunk-4XP7BVJD.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-QCXM7FCT.mjs.map → chunk-4YZQBDUE.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-HO3JCUZA.mjs.map → chunk-4ZZJX7E7.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-RBN5PDCE.mjs.map → chunk-5OM6KD5S.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-JIECCAME.mjs.map → chunk-6G7ATMU7.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-UAZVYE3I.mjs.map → chunk-6GNNYFMN.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-K3WBBSXJ.mjs.map → chunk-6P7EXGAB.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4PHZ25O4.mjs.map → chunk-6RGWVDNQ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-RNZEARAQ.mjs.map → chunk-6ZL2QC74.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-RHFDU5Y4.mjs.map → chunk-ABHYXD3U.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4CJBDKYR.mjs.map → chunk-AF2QSDSV.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-3OKWBJFM.mjs.map → chunk-B2RDSGON.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-XNPY3DUJ.mjs.map → chunk-B7ZKW5ML.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-FMUDQBZE.mjs.map → chunk-BETSOJFK.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-JZLYRNNP.mjs.map → chunk-BHAZ2W52.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-PRULMJH7.mjs.map → chunk-BQ2I655N.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-R3TQP7YH.mjs.map → chunk-CBF72LQF.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ETES5ZQ7.mjs.map → chunk-CIY7IH2N.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-EA6KZGPV.mjs.map → chunk-CJQAA4EP.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-UHDDSK3N.mjs.map → chunk-DGYPNF4O.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-DEAM4WOQ.mjs.map → chunk-E7BYYSVM.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-QAVA2C6Y.mjs.map → chunk-EQEYL6AE.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-V6GKT3ZN.mjs.map → chunk-FAOCLLIW.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-A5EXECZV.mjs.map → chunk-FIVH6RKU.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-RIQNG4I7.mjs.map → chunk-FSCOQWQN.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-Z3IZ47ZD.mjs.map → chunk-FZFKEGPM.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-RDMU5LTQ.mjs.map → chunk-GFTTAANM.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-5N755C2P.mjs.map → chunk-GT2HLNE7.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ITYCILLF.mjs.map → chunk-H7BJSM6C.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-HQSB4ISG.mjs.map → chunk-HIUWEH2W.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-5RVSN75H.mjs.map → chunk-HUITKXBO.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-PNT4VF66.mjs.map → chunk-HXXZKQRJ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-A5M7ZH6X.mjs.map → chunk-I37JLMZH.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4MQGFX5E.mjs.map → chunk-IBSC2B7Q.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-P3EYUM5Z.mjs.map → chunk-INWUHEQN.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZNZKP2Z7.mjs.map → chunk-ISPOZQQO.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-24NXU72Y.mjs.map → chunk-IXUYZYD2.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-QVQGVVKN.mjs.map → chunk-JZ7434LN.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-WZWDFTW3.mjs.map → chunk-KSMSBTTQ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-EOX35D4L.mjs.map → chunk-LIPGE2RA.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-YPCJBYUY.mjs.map → chunk-LUDF7ZUR.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-43DKHDU2.mjs.map → chunk-MRV6OG7P.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-NXKEIB75.mjs.map → chunk-N2RYRHHL.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZWISUUBJ.mjs.map → chunk-NJPTQNCT.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4ROJWFSB.mjs.map → chunk-NPZ5PO2W.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZMEIT65B.mjs.map → chunk-OD4ANAAQ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4OEPT2V4.mjs.map → chunk-P3BXXGQA.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-5AR7YU5K.mjs.map → chunk-PJDJEPY2.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-MZNVCQVB.mjs.map → chunk-QSYQIJEO.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-YEXBSKXL.mjs.map → chunk-QWV25ZSJ.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZHGCNNB5.mjs.map → chunk-RM4VHHXR.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-XW2GCCBZ.mjs.map → chunk-RRKNYQ6D.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-HOYYQCKG.mjs.map → chunk-RSUHZ7IH.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-AJOTPFJL.mjs.map → chunk-S4WKQEYF.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-I7ODJJY3.mjs.map → chunk-TI73UXGG.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-426U6FXN.mjs.map → chunk-U34BNBOX.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-SPSO2A53.mjs.map → chunk-U64LDJTG.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ASWTHX52.mjs.map → chunk-UAW7SD6P.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-N6FJMYEB.mjs.map → chunk-V2C7APME.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-A64HMPMV.mjs.map → chunk-VFAKQ7NM.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ETHHR4HF.mjs.map → chunk-VXLJWKLG.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-2GSNHNKW.mjs.map → chunk-WHEXX3BD.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-4TSUWSFU.mjs.map → chunk-XPYJSDNF.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-LYTBUMNM.mjs.map → chunk-YA5U6YEL.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-RXAVE5OL.mjs.map → chunk-YKRSCVRE.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-CO3V5DOG.mjs.map → chunk-YUITECZ5.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-ZTSNKYSA.mjs.map → chunk-Z4OHB36I.mjs.map} +0 -0
- /package/out/__chunks__/{chunk-SJYCKFH4.mjs.map → chunk-ZXIBFH6X.mjs.map} +0 -0
- /package/out/{__chunks__/chunk-FLC6QSZB.mjs.map → managers/LogoutManager/LogoutManager.mjs.map} +0 -0
- /package/out/{providers/strategies/CrossWindowProviderStrategy/types/crossWindow.types.mjs.map → managers/LogoutManager/helpers/getHumanReadableTokenExpirationTime.mjs.map} +0 -0
- /package/out/{providers/strategies/CrossWindowProviderStrategy/types/index.mjs.map → managers/TransactionManager/TransactionManager.types.mjs.map} +0 -0
- /package/out/{utils/createUIElement.mjs.map → managers/TransactionManager/helpers/sessionCallbacks.mjs.map} +0 -0
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./switchTheme"), exports);
|
|
18
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/utils/visual/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.switchTheme = void 0;
|
|
4
|
+
const window_constants_1 = require("../../constants/window.constants");
|
|
5
|
+
function switchTheme(theme) {
|
|
6
|
+
try {
|
|
7
|
+
if (!window_constants_1.safeWindow) {
|
|
8
|
+
return;
|
|
9
|
+
}
|
|
10
|
+
window_constants_1.safeWindow.document.documentElement.dataset.theme = theme;
|
|
11
|
+
}
|
|
12
|
+
catch (_err) { }
|
|
13
|
+
}
|
|
14
|
+
exports.switchTheme = switchTheme;
|
|
15
|
+
//# sourceMappingURL=switchTheme.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"switchTheme.js","sourceRoot":"","sources":["../../../src/utils/visual/switchTheme.ts"],"names":[],"mappings":";;;AAAA,iEAAwD;AAGxD,SAAgB,WAAW,CAAC,KAAsB;IAChD,IAAI,CAAC;QACH,IAAI,CAAC,6BAAU,EAAE,CAAC;YAChB,OAAO;QACT,CAAC;QACD,6BAAU,CAAC,QAAQ,CAAC,eAAe,CAAC,OAAO,CAAC,KAAK,GAAG,KAAK,CAAC;IAC5D,CAAC;IAAC,OAAO,IAAI,EAAE,CAAC,CAAA,CAAC;AACnB,CAAC;AAPD,kCAOC"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e}from"../../../__chunks__/chunk-
|
|
1
|
+
import{a as e}from"../../../__chunks__/chunk-QWV25ZSJ.mjs";import"../../../__chunks__/chunk-S2FQWSUO.mjs";var t={},o={},s=e;export{t as WalletConnectMethodsEnum,o as WalletConnectOptionalMethodsEnum,s as WalletConnectV2Provider};
|
|
2
2
|
//# sourceMappingURL=sdkWalletconnectProvider.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../__chunks__/chunk-
|
|
1
|
+
import{a}from"../../__chunks__/chunk-YKRSCVRE.mjs";import"../../__chunks__/chunk-4TZC3NF3.mjs";import"../../__chunks__/chunk-L4QPPHVR.mjs";import"../../__chunks__/chunk-B2UIPHJ3.mjs";export{a as getIsInIframe};
|
|
2
2
|
//# sourceMappingURL=getIsInIframe.mjs.map
|
|
@@ -3,7 +3,13 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.getWindowLocation = void 0;
|
|
4
4
|
const isWindowAvailable_1 = require("./isWindowAvailable");
|
|
5
5
|
const getWindowLocation = () => {
|
|
6
|
-
|
|
6
|
+
let isAvailable;
|
|
7
|
+
try {
|
|
8
|
+
isAvailable = (0, isWindowAvailable_1.isWindowAvailable)();
|
|
9
|
+
}
|
|
10
|
+
catch (_error) {
|
|
11
|
+
isAvailable = false;
|
|
12
|
+
}
|
|
7
13
|
if (!isAvailable) {
|
|
8
14
|
return {
|
|
9
15
|
pathname: '',
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getWindowLocation.js","sourceRoot":"","sources":["../../../src/utils/window/getWindowLocation.ts"],"names":[],"mappings":";;;AAAA,2DAAwD;AAUjD,MAAM,iBAAiB,GAAG,GAA0B,EAAE;IAC3D,
|
|
1
|
+
{"version":3,"file":"getWindowLocation.js","sourceRoot":"","sources":["../../../src/utils/window/getWindowLocation.ts"],"names":[],"mappings":";;;AAAA,2DAAwD;AAUjD,MAAM,iBAAiB,GAAG,GAA0B,EAAE;IAC3D,IAAI,WAAoB,CAAC;IAEzB,IAAI,CAAC;QACH,WAAW,GAAG,IAAA,qCAAiB,GAAE,CAAC;IACpC,CAAC;IAAC,OAAO,MAAM,EAAE,CAAC;QAChB,WAAW,GAAG,KAAK,CAAC;IACtB,CAAC;IAED,IAAI,CAAC,WAAW,EAAE,CAAC;QACjB,OAAO;YACL,QAAQ,EAAE,EAAE;YACZ,IAAI,EAAE,EAAE;YACR,MAAM,EAAE,EAAE;YACV,IAAI,EAAE,EAAE;YACR,MAAM,EAAE,EAAE;SACX,CAAC;IACJ,CAAC;IAED,MAAM,EACJ,QAAQ,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,EAAE,EACnD,GAAG,MAAM,CAAC;IAEX,OAAO;QACL,QAAQ;QACR,IAAI;QACJ,MAAM;QACN,IAAI;QACJ,MAAM;KACP,CAAC;AACJ,CAAC,CAAC;AA9BW,QAAA,iBAAiB,qBA8B5B"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../__chunks__/chunk-
|
|
1
|
+
import{a}from"../../__chunks__/chunk-CKTFPRJS.mjs";import"../../__chunks__/chunk-B2UIPHJ3.mjs";export{a as getWindowLocation};
|
|
2
2
|
//# sourceMappingURL=getWindowLocation.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a}from"../../__chunks__/chunk-
|
|
1
|
+
import{a}from"../../__chunks__/chunk-4TZC3NF3.mjs";import"../../__chunks__/chunk-L4QPPHVR.mjs";export{a as getWindowParentOrigin};
|
|
2
2
|
//# sourceMappingURL=getWindowParentOrigin.mjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import"../../__chunks__/chunk-DTQL3IDP.mjs";import{a as b}from"../../__chunks__/chunk-
|
|
1
|
+
import"../../__chunks__/chunk-DTQL3IDP.mjs";import{a as b}from"../../__chunks__/chunk-CKTFPRJS.mjs";import{a as f}from"../../__chunks__/chunk-YKRSCVRE.mjs";import"../../__chunks__/chunk-4TZC3NF3.mjs";import{a as e}from"../../__chunks__/chunk-EHDGJUEU.mjs";import{a as d}from"../../__chunks__/chunk-HOCSCRJF.mjs";import"../../__chunks__/chunk-L4QPPHVR.mjs";import{a as c}from"../../__chunks__/chunk-UE3IBKCO.mjs";import"../../__chunks__/chunk-H6IZMTJK.mjs";import{a}from"../../__chunks__/chunk-B2UIPHJ3.mjs";export{d as buildUrlParams,e as getIsAuthRoute,f as getIsInIframe,b as getWindowLocation,a as isWindowAvailable,c as sanitizeCallbackUrl};
|
|
2
2
|
//# sourceMappingURL=index.mjs.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@multiversx/sdk-dapp",
|
|
3
|
-
"version": "5.0.0
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"main": "out/index.js",
|
|
5
5
|
"module": "out/index.mjs",
|
|
6
6
|
"types": "out/index.d.ts",
|
|
@@ -33,18 +33,16 @@
|
|
|
33
33
|
},
|
|
34
34
|
"dependencies": {
|
|
35
35
|
"@lifeomic/axios-fetch": "3.0.1",
|
|
36
|
-
"@multiversx/sdk-core": "^14.x",
|
|
37
|
-
"@multiversx/sdk-dapp-utils": "^2.x",
|
|
38
36
|
"@multiversx/sdk-extension-provider": "5.0.0",
|
|
39
37
|
"@multiversx/sdk-hw-provider": "8.0.0",
|
|
40
38
|
"@multiversx/sdk-metamask-provider": "2.0.0",
|
|
41
|
-
"@multiversx/sdk-native-auth-client": "
|
|
39
|
+
"@multiversx/sdk-native-auth-client": "2.0.1",
|
|
42
40
|
"@multiversx/sdk-wallet": "4.6.0",
|
|
43
|
-
"@multiversx/sdk-wallet-connect-provider": "6.0.
|
|
44
|
-
"@multiversx/sdk-web-wallet-cross-window-provider": "3.1.
|
|
41
|
+
"@multiversx/sdk-wallet-connect-provider": "6.0.2",
|
|
42
|
+
"@multiversx/sdk-web-wallet-cross-window-provider": "3.1.3",
|
|
45
43
|
"@multiversx/sdk-web-wallet-iframe-provider": "3.0.3",
|
|
46
44
|
"@multiversx/sdk-web-wallet-provider": "5.0.0",
|
|
47
|
-
"@multiversx/sdk-webview-provider": "3.1.
|
|
45
|
+
"@multiversx/sdk-webview-provider": "3.1.2",
|
|
48
46
|
"immer": "10.1.1",
|
|
49
47
|
"linkifyjs": "4.3.1",
|
|
50
48
|
"lodash.isempty": "4.4.0",
|
|
@@ -60,11 +58,11 @@
|
|
|
60
58
|
"peerDependencies": {
|
|
61
59
|
"@multiversx/sdk-core": "^14.x",
|
|
62
60
|
"@multiversx/sdk-dapp-utils": "^2.x",
|
|
63
|
-
"axios": ">=1.
|
|
64
|
-
"bignumber.js": "9.x"
|
|
61
|
+
"axios": ">=1.10.0",
|
|
62
|
+
"bignumber.js": "^9.x"
|
|
65
63
|
},
|
|
66
64
|
"optionalDependencies": {
|
|
67
|
-
"@multiversx/sdk-dapp-ui": ">=0.0.
|
|
65
|
+
"@multiversx/sdk-dapp-ui": ">=0.0.13"
|
|
68
66
|
},
|
|
69
67
|
"resolutions": {
|
|
70
68
|
"strip-ansi": "6.0.1",
|
|
@@ -73,6 +71,8 @@
|
|
|
73
71
|
"devDependencies": {
|
|
74
72
|
"@eslint/js": "9.15.0",
|
|
75
73
|
"@swc/core": "1.4.17",
|
|
74
|
+
"@multiversx/sdk-core": "^14.x",
|
|
75
|
+
"@multiversx/sdk-dapp-utils": "^2.x",
|
|
76
76
|
"@swc/jest": "0.2.36",
|
|
77
77
|
"@types/jest": "29.5.13",
|
|
78
78
|
"@types/lodash.isempty": "4.4.9",
|
|
@@ -82,12 +82,12 @@
|
|
|
82
82
|
"@types/lodash.trimend": "4.5.9",
|
|
83
83
|
"@types/lodash.uniq": "4.5.9",
|
|
84
84
|
"@types/node": "20.12.8",
|
|
85
|
-
"@types/react": "18.2.
|
|
85
|
+
"@types/react": "18.2.0",
|
|
86
86
|
"@typescript-eslint/eslint-plugin": "8.15.0",
|
|
87
87
|
"@typescript-eslint/parser": "8.15.0",
|
|
88
|
-
"axios": ">=1.
|
|
88
|
+
"axios": ">=1.10.0",
|
|
89
89
|
"axios-mock-adapter": "1.22.0",
|
|
90
|
-
"bignumber.js": "9.x",
|
|
90
|
+
"bignumber.js": "^9.x",
|
|
91
91
|
"esbuild": "0.21.1",
|
|
92
92
|
"esbuild-node-externals": "1.14.0",
|
|
93
93
|
"esbuild-plugin-replace": "1.3.0",
|
|
@@ -107,7 +107,7 @@
|
|
|
107
107
|
"msw": "1.3.1",
|
|
108
108
|
"node-stdlib-browser": "1.2.0",
|
|
109
109
|
"prettier": "3.2.5",
|
|
110
|
-
"react": "18.
|
|
110
|
+
"react": "18.2.0",
|
|
111
111
|
"rimraf": "5.0.6",
|
|
112
112
|
"ts-jest": "29.1.2",
|
|
113
113
|
"tsc-alias": "1.8.9",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=chunk-2GSNHNKW.mjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{b as s,d as i,h as o}from"./chunk-DKGAK7SX.mjs";var r=1e4,u=class{constructor(){this.timeoutIntervals=new Map;this.successfulToastLifetime=r;this.start=t=>{if(this.stop(t),this.successfulToastLifetime<=0)return;let e=setTimeout(()=>{o(t)},this.successfulToastLifetime);this.timeoutIntervals.set(t,e)};this.startWithCustomDuration=(t,e)=>{if(this.stop(t),e<=0)return;let a=setTimeout(()=>{i(t);let n=s[t];n?.()},e);this.timeoutIntervals.set(t,a)};this.stop=t=>{let e=this.timeoutIntervals.get(t);e&&(clearTimeout(e),this.timeoutIntervals.delete(t))}}init({successfulToastLifetime:t}){this.successfulToastLifetime=t||r}destroy(){this.timeoutIntervals.forEach(t=>clearTimeout(t)),this.timeoutIntervals.clear()}};export{u as a};
|
|
2
|
-
//# sourceMappingURL=chunk-3RRSLNNU.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/managers/internal/ToastManager/helpers/LifetimeManager.ts"],
|
|
4
|
-
"sourcesContent": ["import {\n customToastCloseHandlersDictionary,\n removeCustomToast,\n removeTransactionToast\n} from 'store/actions/toasts/toastsActions';\n\ninterface IToastProgressManagerParams {\n successfulToastLifetime?: number;\n}\n\nconst DEFAULT_SUCCESSFUL_TOAST_LIFETIME = 10000;\n\nexport class LifetimeManager {\n private timeoutIntervals: Map<string, ReturnType<typeof setTimeout>> =\n new Map();\n private successfulToastLifetime: number = DEFAULT_SUCCESSFUL_TOAST_LIFETIME;\n\n constructor() {}\n\n public init({ successfulToastLifetime }: IToastProgressManagerParams) {\n this.successfulToastLifetime =\n successfulToastLifetime || DEFAULT_SUCCESSFUL_TOAST_LIFETIME;\n }\n\n public start = (toastId: string) => {\n this.stop(toastId);\n\n if (this.successfulToastLifetime <= 0) {\n return;\n }\n\n const timeout = setTimeout(() => {\n removeTransactionToast(toastId);\n }, this.successfulToastLifetime);\n\n this.timeoutIntervals.set(toastId, timeout);\n };\n\n public startWithCustomDuration = (toastId: string, duration: number) => {\n this.stop(toastId);\n\n if (duration <= 0) {\n return;\n }\n\n const timeout = setTimeout(() => {\n removeCustomToast(toastId);\n const handleClose = customToastCloseHandlersDictionary[toastId];\n handleClose?.();\n }, duration);\n\n this.timeoutIntervals.set(toastId, timeout);\n };\n\n public stop = (toastId: string) => {\n const timeout = this.timeoutIntervals.get(toastId);\n if (timeout) {\n clearTimeout(timeout);\n this.timeoutIntervals.delete(toastId);\n }\n };\n\n public destroy() {\n this.timeoutIntervals.forEach((interval) => clearTimeout(interval));\n this.timeoutIntervals.clear();\n }\n}\n"],
|
|
5
|
-
"mappings": "uDAUA,IAAMA,EAAoC,IAE7BC,EAAN,KAAsB,CAK3B,aAAc,CAJd,KAAQ,iBACN,IAAI,IACN,KAAQ,wBAAkCD,EAS1C,KAAO,MAASE,GAAoB,CAGlC,GAFA,KAAK,KAAKA,CAAO,EAEb,KAAK,yBAA2B,EAClC,OAGF,IAAMC,EAAU,WAAW,IAAM,CAC/BC,EAAuBF,CAAO,CAChC,EAAG,KAAK,uBAAuB,EAE/B,KAAK,iBAAiB,IAAIA,EAASC,CAAO,CAC5C,EAEA,KAAO,wBAA0B,CAACD,EAAiBG,IAAqB,CAGtE,GAFA,KAAK,KAAKH,CAAO,EAEbG,GAAY,EACd,OAGF,IAAMF,EAAU,WAAW,IAAM,CAC/BG,EAAkBJ,CAAO,EACzB,IAAMK,EAAcC,EAAmCN,CAAO,EAC9DK,IAAc,CAChB,EAAGF,CAAQ,EAEX,KAAK,iBAAiB,IAAIH,EAASC,CAAO,CAC5C,EAEA,KAAO,KAAQD,GAAoB,CACjC,IAAMC,EAAU,KAAK,iBAAiB,IAAID,CAAO,EAC7CC,IACF,aAAaA,CAAO,EACpB,KAAK,iBAAiB,OAAOD,CAAO,EAExC,CA3Ce,CAER,KAAK,CAAE,wBAAAO,CAAwB,EAAgC,CACpE,KAAK,wBACHA,GAA2BT,CAC/B,CAwCO,SAAU,CACf,KAAK,iBAAiB,QAASU,GAAa,aAAaA,CAAQ,CAAC,EAClE,KAAK,iBAAiB,MAAM,CAC9B,CACF",
|
|
6
|
-
"names": ["DEFAULT_SUCCESSFUL_TOAST_LIFETIME", "LifetimeManager", "toastId", "timeout", "removeTransactionToast", "duration", "removeCustomToast", "handleClose", "customToastCloseHandlersDictionary", "successfulToastLifetime", "interval"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as g}from"./chunk-3S57OP4Z.mjs";import{a as l}from"./chunk-QTKK6OSJ.mjs";import{a as f}from"./chunk-RIQNG4I7.mjs";import{NativeAuthClient as y}from"@multiversx/sdk-native-auth-client";var H=h=>{let{origin:o,apiAddress:i,expirySeconds:r,blockHashShard:s,extraInfo:u,gatewayUrl:d,extraRequestHeaders:k}=f(h),n=new y({origin:o,apiUrl:i,expirySeconds:r,blockHashShard:s,gatewayUrl:d,extraRequestHeaders:k});return{initialize:async t=>{if(!i||!o)return"";let a=()=>n.getCurrentBlockHash(),e=t?.latestBlockInfo;e||(e=await g({apiAddress:i,blockHashShard:s,getBlockHash:a,noCache:t?.noCache}));let{hash:p,timestamp:c}=e,m=n.encodeValue(JSON.stringify({...t?.extraInfo??u,...c?{timestamp:c}:{}}));return`${n.encodeValue(o)}.${p}.${r}.${m}`},getToken:({address:t,token:a,signature:e})=>n.getToken(t,a,e),getTokenExpiration:l}};export{H as a};
|
|
2
|
-
//# sourceMappingURL=chunk-45WVS4H5.mjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as m}from"./chunk-VMFJUT3G.mjs";import{a as e}from"./chunk-FP2LZG6I.mjs";var E=async({name:t,anchor:o})=>{if(await m(e),!e.document)return{};let n=e.document.createElement(t);return(o||e.document.body).appendChild(n),await customElements.whenDefined(t),n};export{E as a};
|
|
2
|
-
//# sourceMappingURL=chunk-762K2LVS.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/utils/createUIElement.ts"],
|
|
4
|
-
"sourcesContent": ["import { IEventBus } from '@multiversx/sdk-dapp-ui/dist/loader';\nimport { safeWindow } from 'constants/index';\nimport { UITagsEnum } from 'constants/UITags.enum';\nimport { defineCustomElements } from 'lib/sdkDappUi';\n\nexport interface CreateEventBusUIElementType extends HTMLElement {\n getEventBus: () => Promise<IEventBus | null>;\n}\n\nexport const createUIElement = async <T = CreateEventBusUIElementType>({\n name,\n anchor\n}: {\n name: UITagsEnum;\n anchor?: HTMLElement;\n}) => {\n await defineCustomElements(safeWindow);\n\n if (!safeWindow.document) {\n return {} as T;\n }\n\n const element = safeWindow.document.createElement(name);\n const rootElement = anchor || safeWindow.document.body;\n rootElement.appendChild(element);\n await customElements.whenDefined(name);\n\n return element as T;\n};\n"],
|
|
5
|
-
"mappings": "kFASO,IAAMA,EAAkB,MAAwC,CACrE,KAAAC,EACA,OAAAC,CACF,IAGM,CAGJ,GAFA,MAAMC,EAAqBC,CAAU,EAEjC,CAACA,EAAW,SACd,MAAO,CAAC,EAGV,IAAMC,EAAUD,EAAW,SAAS,cAAcH,CAAI,EAEtD,OADoBC,GAAUE,EAAW,SAAS,MACtC,YAAYC,CAAO,EAC/B,MAAM,eAAe,YAAYJ,CAAI,EAE9BI,CACT",
|
|
6
|
-
"names": ["createUIElement", "name", "anchor", "defineCustomElements", "safeWindow", "element"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{d as s}from"./chunk-MIQ3KCUL.mjs";import{a as p}from"./chunk-LYC7ERBA.mjs";import{u as c}from"./chunk-ZGRKIA6G.mjs";import{b as d}from"./chunk-SAAOQW7P.mjs";import{a as v}from"./chunk-I7ODJJY3.mjs";import{a}from"./chunk-NHXPNROG.mjs";var n=class n extends p{constructor(){super({uiTag:"mvx-unlock-panel",uiDataUpdateEvent:"OPEN"});this.initialData={providers:null,walletAddress:null};this.openUnlockPanel=async()=>{let{walletAddress:e}=d(c());this.data={providers:this.getProvidersList(),walletAddress:e},await this.openUI(),this.notifyDataUpdate()};this.setupEventListeners=async()=>{this.eventBus&&(this.subscribeToEventBus("LOGIN",this.handleLogin),this.subscribeToEventBus("CANCEL_LOGIN",this.handleCancelLogin),this.subscribeToEventBus("CLOSE",this.handleCloseUI))};this.handleCloseUI=async e=>{!e?.isLoginFinished&&n.onClose&&n.onClose(),this.closeUI()};this.handleLogin=async({type:e,anchor:o})=>{if(!n.loginHandler)throw new Error("Login callback not initialized. Please call `init()` first.");try{this.isSimpleLoginCallback(n.loginHandler)?(await(await s.create({type:e,anchor:o})).login(),n.loginHandler()):n.loginHandler({type:e,anchor:o}),await this.handleCloseUI({isLoginFinished:!0})}catch(r){console.error(r),this.eventBus?.publish("CANCEL_IN_PROVIDER",this.data)}};this.handleCancelLogin=async()=>{await s.destroy()};this.isSimpleLoginCallback=e=>e.length===0;this.data=this.initialData}static getInstance(){return n.instance||(n.instance=new n),n.instance}static init(e){return this.loginHandler=e.loginHandler,this.allowedProviders=e.allowedProviders,e.onClose&&(this.onClose=e.onClose),this.getInstance()}getProvidersList(){let e=s.customProviders,r=[...Object.values(a).filter(i=>i!==a.none&&i!==a.webview),...e.map(i=>i.type)],P=e.reduce((i,t)=>(i[t.type]=t.name,i),{}),l={...v,...P};return(n.allowedProviders?n?.allowedProviders.map(i=>i.type).filter(i=>r.includes(i)):r).map(i=>{let t=e.find(g=>g.type===i);return t||{name:i in l?l[i]:i,type:i}})}};n.loginHandler=null,n.onClose=null,n.allowedProviders=null;var u=n;export{u as a};
|
|
2
|
-
//# sourceMappingURL=chunk-ABKSM4D4.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/managers/UnlockPanelManager/UnlockPanelManager.ts"],
|
|
4
|
-
"sourcesContent": ["import { providerLabels } from 'constants/providerFactory.constants';\nimport { UITagsEnum } from 'constants/UITags.enum';\nimport { MvxUnlockPanel } from 'lib/sdkDappUi';\nimport { ProviderFactory } from 'providers/ProviderFactory';\nimport {\n IProviderBase,\n IProviderFactory,\n ICustomProvider,\n ProviderTypeEnum,\n ProviderType\n} from 'providers/types/providerFactory.types';\nimport { networkSelector } from 'store/selectors';\nimport { getState } from 'store/store';\nimport {\n OnCloseUnlockPanelType,\n LoginHandlerType,\n UnlockPanelEventsEnum,\n UnlockPanelManagerInitParamsType\n} from './UnlockPanelManager.types';\nimport { SidePanelBaseManager } from '../internal/SidePanelBaseManager';\n\ninterface IUnlockPanelManagerData {\n providers: IProviderBase[] | null;\n walletAddress: string | null;\n}\n\nexport class UnlockPanelManager extends SidePanelBaseManager<\n MvxUnlockPanel,\n IUnlockPanelManagerData,\n UnlockPanelEventsEnum\n> {\n protected initialData: IUnlockPanelManagerData = {\n providers: null,\n walletAddress: null\n };\n\n private static instance: UnlockPanelManager;\n private static loginHandler: LoginHandlerType | null = null;\n private static onClose: OnCloseUnlockPanelType | null = null;\n private static allowedProviders?: ICustomProvider[] | null = null;\n\n constructor() {\n super({\n uiTag: UITagsEnum.UNLOCK_PANEL,\n uiDataUpdateEvent: UnlockPanelEventsEnum.OPEN\n });\n\n this.data = this.initialData;\n }\n\n public static getInstance(): UnlockPanelManager {\n if (!UnlockPanelManager.instance) {\n UnlockPanelManager.instance = new UnlockPanelManager();\n }\n return UnlockPanelManager.instance;\n }\n\n public static init(params: UnlockPanelManagerInitParamsType) {\n this.loginHandler = params.loginHandler;\n this.allowedProviders = params.allowedProviders;\n\n if (params.onClose) {\n this.onClose = params.onClose;\n }\n\n return this.getInstance();\n }\n\n public openUnlockPanel = async () => {\n const { walletAddress } = networkSelector(getState());\n\n this.data = {\n providers: this.getProvidersList(),\n walletAddress\n };\n\n await this.openUI();\n this.notifyDataUpdate();\n };\n\n protected setupEventListeners = async () => {\n if (!this.eventBus) {\n return;\n }\n\n this.subscribeToEventBus(UnlockPanelEventsEnum.LOGIN, this.handleLogin);\n this.subscribeToEventBus(\n UnlockPanelEventsEnum.CANCEL_LOGIN,\n this.handleCancelLogin\n );\n this.subscribeToEventBus(UnlockPanelEventsEnum.CLOSE, this.handleCloseUI);\n };\n\n private readonly handleCloseUI = async (options?: {\n isLoginFinished?: boolean;\n }) => {\n if (!options?.isLoginFinished && UnlockPanelManager.onClose) {\n UnlockPanelManager.onClose();\n }\n\n this.closeUI();\n };\n\n private readonly handleLogin = async ({ type, anchor }: IProviderFactory) => {\n if (!UnlockPanelManager.loginHandler) {\n throw new Error(\n 'Login callback not initialized. Please call `init()` first.'\n );\n }\n\n try {\n if (this.isSimpleLoginCallback(UnlockPanelManager.loginHandler)) {\n const provider = await ProviderFactory.create({ type, anchor });\n await provider.login();\n UnlockPanelManager.loginHandler();\n } else {\n UnlockPanelManager.loginHandler({ type, anchor });\n }\n await this.handleCloseUI({ isLoginFinished: true });\n } catch (error) {\n console.error(error);\n this.eventBus?.publish(\n UnlockPanelEventsEnum.CANCEL_IN_PROVIDER,\n this.data\n );\n }\n };\n\n private readonly handleCancelLogin = async () => {\n await ProviderFactory.destroy();\n };\n\n private readonly isSimpleLoginCallback = (\n login: LoginHandlerType\n ): login is () => void => {\n const takesZeroArguments = login.length === 0;\n return takesZeroArguments;\n };\n\n private getProvidersList(): IProviderBase[] {\n const customProviders = ProviderFactory.customProviders;\n\n const defaultProviderTypes = Object.values(ProviderTypeEnum).filter(\n (type) =>\n type !== ProviderTypeEnum.none && type !== ProviderTypeEnum.webview\n );\n\n const allAvailableProviderTypes = [\n ...defaultProviderTypes,\n ...customProviders.map((p) => p.type)\n ];\n\n const customProviderLabels = customProviders.reduce(\n (acc, provider) => {\n acc[provider.type] = provider.name;\n return acc;\n },\n {} as Record<ProviderType, string>\n );\n\n const allAvailableLabels = {\n ...providerLabels,\n ...customProviderLabels\n };\n\n const allowedProviderTypes = UnlockPanelManager.allowedProviders\n ? UnlockPanelManager?.allowedProviders\n .map((p) => p.type)\n .filter((type) => allAvailableProviderTypes.includes(type))\n : allAvailableProviderTypes;\n\n const providerList = allowedProviderTypes.map((type) => {\n const custom = customProviders.find(\n (customProvider) => customProvider.type === type\n );\n if (custom) {\n return custom;\n }\n\n return {\n name: type in allAvailableLabels ? allAvailableLabels[type] : type,\n type\n };\n });\n\n return providerList;\n }\n}\n"],
|
|
5
|
-
"mappings": "iPA0BO,IAAMA,EAAN,MAAMA,UAA2BC,CAItC,CAWA,aAAc,CACZ,MAAM,CACJ,yBACA,wBACF,CAAC,EAdH,KAAU,YAAuC,CAC/C,UAAW,KACX,cAAe,IACjB,EAkCA,KAAO,gBAAkB,SAAY,CACnC,GAAM,CAAE,cAAAC,CAAc,EAAIC,EAAgBC,EAAS,CAAC,EAEpD,KAAK,KAAO,CACV,UAAW,KAAK,iBAAiB,EACjC,cAAAF,CACF,EAEA,M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AAOC,CAAgB,EAAE,OAC1DR,GACCA,IAASQ,EAAiB,MAAQR,IAASQ,EAAiB,OAChE,EAIE,GAAGF,EAAgB,IAAKG,GAAMA,EAAE,IAAI,CACtC,EAEMC,EAAuBJ,EAAgB,OAC3C,CAACK,EAAKC,KACJD,EAAIC,EAAS,IAAI,EAAIA,EAAS,KACvBD,GAET,CAAC,CACH,EAEME,EAAqB,CACzB,GAAGC,EACH,GAAGJ,CACL,EAsBA,OApB6BhB,EAAmB,iBAC5CA,GAAoB,iBACjB,IAAKe,GAAMA,EAAE,IAAI,EACjB,OAAQT,GAASO,EAA0B,SAASP,CAAI,CAAC,EAC5DO,GAEsC,IAAKP,GAAS,CACtD,IAAMe,EAAST,EAAgB,KAC5BU,GAAmBA,EAAe,OAAShB,CAC9C,EACA,OAAIe,GAIG,CACL,KAAMf,KAAQa,EAAqBA,EAAmBb,CAAI,EAAIA,EAC9D,KAAAA,CACF,CACF,CAAC,CAGH,CACF,EAjKaN,EAWI,aAAwC,KAX5CA,EAYI,QAAyC,KAZ7CA,EAaI,iBAA8C,KAbxD,IAAMuB,EAANvB",
|
|
6
|
-
"names": ["_UnlockPanelManager", "SidePanelBaseManager", "walletAddress", "networkSelector", "getState", "options", "type", "anchor", "ProviderFactory", "error", "login", "params", "customProviders", "allAvailableProviderTypes", "ProviderTypeEnum", "p", "customProviderLabels", "acc", "provider", "allAvailableLabels", "providerLabels", "custom", "customProvider", "UnlockPanelManager"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{d as p}from"./chunk-MIQ3KCUL.mjs";import{a as f}from"./chunk-ETES5ZQ7.mjs";import{o as n}from"./chunk-DKGAK7SX.mjs";import{u as i}from"./chunk-ZGRKIA6G.mjs";import{d as t}from"./chunk-VNLGNNIL.mjs";import{a as e}from"./chunk-NHXPNROG.mjs";import{a as m}from"./chunk-RXAVE5OL.mjs";async function y(){let c=m(),s=f(),r=c?e.webview:t(i());if(!r)return;let o=await p.create({type:r});if(!o)throw new Error("Provider not found");!s&&r===e.webview&&await o.login(),n(o)}export{y as a};
|
|
2
|
-
//# sourceMappingURL=chunk-CG25USRH.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/providers/helpers/restoreProvider.ts"],
|
|
4
|
-
"sourcesContent": ["import { getIsLoggedIn } from 'methods/account/getIsLoggedIn';\nimport { ProviderTypeEnum } from 'providers/types/providerFactory.types';\nimport { providerTypeSelector } from 'store/selectors';\nimport { getState } from 'store/store';\nimport { getIsInIframe } from 'utils/window/getIsInIframe';\nimport { setAccountProvider } from './accountProvider';\nimport { ProviderFactory } from '../ProviderFactory';\n\nexport async function restoreProvider() {\n const isInIframe = getIsInIframe();\n const isLoggedIn = getIsLoggedIn();\n\n const type = isInIframe\n ? ProviderTypeEnum.webview\n : providerTypeSelector(getState());\n\n if (!type) {\n return;\n }\n\n const provider = await ProviderFactory.create({\n type\n });\n\n if (!provider) {\n throw new Error('Provider not found');\n }\n\n if (!isLoggedIn && type === ProviderTypeEnum.webview) {\n await provider.login();\n }\n\n setAccountProvider(provider);\n}\n"],
|
|
5
|
-
"mappings": "+RAQA,eAAsBA,GAAkB,CACtC,IAAMC,EAAaC,EAAc,EAC3BC,EAAaC,EAAc,EAE3BC,EAAOJ,EACTK,EAAiB,QACjBC,EAAqBC,EAAS,CAAC,EAEnC,GAAI,CAACH,EACH,OAGF,IAAMI,EAAW,MAAMC,EAAgB,OAAO,CAC5C,KAAAL,CACF,CAAC,EAED,GAAI,CAACI,EACH,MAAM,IAAI,MAAM,oBAAoB,EAGlC,CAACN,GAAcE,IAASC,EAAiB,SAC3C,MAAMG,EAAS,MAAM,EAGvBE,EAAmBF,CAAQ,CAC7B",
|
|
6
|
-
"names": ["restoreProvider", "isInIframe", "getIsInIframe", "isLoggedIn", "getIsLoggedIn", "type", "ProviderTypeEnum", "providerTypeSelector", "getState", "provider", "ProviderFactory", "setAccountProvider"]
|
|
7
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=chunk-CO3V5DOG.mjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as n}from"./chunk-4TBVQD27.mjs";import{s as o}from"./chunk-ZGRKIA6G.mjs";var l=t=>o().setState(({config:e})=>{e.nativeAuthConfig=t},!1,"setNativeAuthConfig"),c=t=>o().setState(({config:e})=>{e.websocketStatus=t},!1,"setWebsocketStatus"),f=t=>o().setState(({config:e})=>{let s=t.walletConnectV2RelayAddress||n.walletConnectV2RelayAddress,i=t.walletConnectDeepLink||n.walletConnectDeepLink;e.walletConnectConfig={...t,walletConnectDeepLink:i,walletConnectV2RelayAddress:s}},!1,"setWalletConnectConfig"),r=t=>o().setState(({config:e})=>{e.crossWindowConfig=t},!1,"setCrossWindowConfig");export{l as a,c as b,f as c,r as d};
|
|
2
|
-
//# sourceMappingURL=chunk-CTUOKFTQ.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/store/actions/config/configActions.ts"],
|
|
4
|
-
"sourcesContent": ["import { fallbackWalletConnectConfigurations } from 'constants/walletConnect.constants';\nimport { WebsocketConnectionStatusEnum } from 'constants/websocket.constants';\nimport { CrossWindowConfig } from 'providers/strategies/CrossWindowProviderStrategy/types';\nimport { WalletConnectConfig } from 'providers/strategies/WalletConnectProviderStrategy/types';\nimport { NativeAuthConfigType } from 'services/nativeAuth/nativeAuth.types';\nimport { getStore } from 'store/store';\n\nexport const setNativeAuthConfig = (config: NativeAuthConfigType) =>\n getStore().setState(\n ({ config: state }) => {\n state.nativeAuthConfig = config;\n },\n false,\n 'setNativeAuthConfig'\n );\n\nexport const setWebsocketStatus = (status: WebsocketConnectionStatusEnum) =>\n getStore().setState(\n ({ config: state }) => {\n state.websocketStatus = status;\n },\n false,\n 'setWebsocketStatus'\n );\n\nexport const setWalletConnectConfig = (config: WalletConnectConfig) =>\n getStore().setState(\n ({ config: state }) => {\n const walletConnectV2RelayAddress =\n config.walletConnectV2RelayAddress ||\n fallbackWalletConnectConfigurations.walletConnectV2RelayAddress;\n const walletConnectDeepLink =\n config.walletConnectDeepLink ||\n fallbackWalletConnectConfigurations.walletConnectDeepLink;\n\n state.walletConnectConfig = {\n ...config,\n walletConnectDeepLink,\n walletConnectV2RelayAddress\n };\n },\n false,\n 'setWalletConnectConfig'\n );\n\nexport const setCrossWindowConfig = (config: CrossWindowConfig) =>\n getStore().setState(\n ({ config: state }) => {\n state.crossWindowConfig = config;\n },\n false,\n 'setCrossWindowConfig'\n );\n"],
|
|
5
|
-
"mappings": "kFAOO,IAAMA,EAAuBC,GAClCC,EAAS,EAAE,SACT,CAAC,CAAE,OAAQC,CAAM,IAAM,CACrBA,EAAM,iBAAmBF,CAC3B,EACA,GACA,qBACF,EAEWG,EAAsBC,GACjCH,EAAS,EAAE,SACT,CAAC,CAAE,OAAQC,CAAM,IAAM,CACrBA,EAAM,gBAAkBE,CAC1B,EACA,GACA,oBACF,EAEWC,EAA0BL,GACrCC,EAAS,EAAE,SACT,CAAC,CAAE,OAAQC,CAAM,IAAM,CACrB,IAAMI,EACJN,EAAO,6BACPO,EAAoC,4BAChCC,EACJR,EAAO,uBACPO,EAAoC,sBAEtCL,EAAM,oBAAsB,CAC1B,GAAGF,EACH,sBAAAQ,EACA,4BAAAF,CACF,CACF,EACA,GACA,wBACF,EAEWG,EAAwBT,GACnCC,EAAS,EAAE,SACT,CAAC,CAAE,OAAQC,CAAM,IAAM,CACrBA,EAAM,kBAAoBF,CAC5B,EACA,GACA,sBACF",
|
|
6
|
-
"names": ["setNativeAuthConfig", "config", "getStore", "state", "setWebsocketStatus", "status", "setWalletConnectConfig", "walletConnectV2RelayAddress", "fallbackWalletConnectConfigurations", "walletConnectDeepLink", "setCrossWindowConfig"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{b as a,c as n}from"./chunk-RMF4WLMK.mjs";function m({results:r,hash:e,sessionId:s}){let t=r?.find(i=>i?.returnMessage!=="");n({sessionId:s,transaction:{...t,hash:e,status:"fail",inTransit:!1}}),a({sessionId:s,status:"fail",errorMessage:t?.returnMessage})}export{m as a};
|
|
2
|
-
//# sourceMappingURL=chunk-CUZ44CDY.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/methods/trackTransactions/helpers/checkTransactionStatus/manageFailedTransactions.ts"],
|
|
4
|
-
"sourcesContent": ["import {\n updateTransactionStatus,\n updateTransactionsSession\n} from 'store/actions/transactions/transactionsActions';\nimport {\n TransactionBatchStatusesEnum,\n TransactionServerStatusesEnum\n} from 'types/enums.types';\nimport { ResultType } from 'types/serverTransactions.types';\nimport { SignedTransactionType } from 'types/transactions.types';\n\nexport function manageFailedTransactions({\n results,\n hash,\n sessionId\n}: {\n results: ResultType[];\n hash: string;\n sessionId: string;\n}) {\n const resultWithError = results?.find(\n (scResult) => scResult?.returnMessage !== ''\n );\n\n updateTransactionStatus({\n sessionId,\n transaction: {\n ...(resultWithError as unknown as SignedTransactionType),\n hash,\n status: TransactionServerStatusesEnum.fail,\n inTransit: false\n }\n });\n\n updateTransactionsSession({\n sessionId,\n status: TransactionBatchStatusesEnum.fail,\n errorMessage: resultWithError?.returnMessage\n });\n}\n"],
|
|
5
|
-
"mappings": "gDAWO,SAASA,EAAyB,CACvC,QAAAC,EACA,KAAAC,EACA,UAAAC,CACF,EAIG,CACD,IAAMC,EAAkBH,GAAS,KAC9BI,GAAaA,GAAU,gBAAkB,EAC5C,EAEAC,EAAwB,CACtB,UAAAH,EACA,YAAa,CACX,GAAIC,EACJ,KAAAF,EACA,cACA,UAAW,EACb,CACF,CAAC,EAEDK,EAA0B,CACxB,UAAAJ,EACA,cACA,aAAcC,GAAiB,aACjC,CAAC,CACH",
|
|
6
|
-
"names": ["manageFailedTransactions", "results", "hash", "sessionId", "resultWithError", "scResult", "updateTransactionStatus", "updateTransactionsSession"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as U}from"./chunk-XNPY3DUJ.mjs";import{a as v}from"./chunk-MZNVCQVB.mjs";import{a as D,b as R,g as F}from"./chunk-QD3CFFVT.mjs";import{a as z}from"./chunk-WO6GJTV2.mjs";import{b as f}from"./chunk-24NXU72Y.mjs";import{a as _}from"./chunk-HO3JCUZA.mjs";import{a as j}from"./chunk-4ODPAHHA.mjs";import{a as $}from"./chunk-Z5CDCI3Y.mjs";import{a as G}from"./chunk-EXEJDQ3E.mjs";import{a as u}from"./chunk-LYTBUMNM.mjs";import{a as L}from"./chunk-RNZEARAQ.mjs";import{a as V}from"./chunk-DEAM4WOQ.mjs";import{a as T}from"./chunk-P3EYUM5Z.mjs";import{a as l,f as O}from"./chunk-ZNZKP2Z7.mjs";import{a as M}from"./chunk-45WVS4H5.mjs";import{b as W}from"./chunk-ETHHR4HF.mjs";import{a as h}from"./chunk-HORSXVIV.mjs";import{a as g}from"./chunk-6FXEHNGW.mjs";import{a as K}from"./chunk-NJN53MJV.mjs";import{a as b}from"./chunk-YSCND2MX.mjs";import{b as k,s as m,u as N}from"./chunk-ZGRKIA6G.mjs";import{b as I}from"./chunk-IEJTMYFW.mjs";import{b as C,c as P,f as S}from"./chunk-R53MCZI6.mjs";import{b as B}from"./chunk-YEXBSKXL.mjs";import{a as E}from"./chunk-NHXPNROG.mjs";async function w({address:t,provider:o,apiAddress:r}){let e=await g({address:t,baseURL:r});if(!e)throw new Error("Account not found");W({address:t,providerType:o.getType()});let n={...e,username:h(e.username),nonce:T(e)};l(n),await f(t),v(),e.shard!=null&&await U({shard:Number(e.shard),apiAddress:r})}async function ot(t){let{network:{apiAddress:o}}=u();await t.login();let r=await t.getAddress();if(!r)throw new Error("Address not found");return await w({address:r,provider:t,apiAddress:o}),{address:r}}async function rt({provider:t,nativeAuthConfig:o,token:r}){let{network:{apiAddress:e}}=u(),n=M(o),s=r;s||(s=await n.initialize({noCache:!0}));let{address:i,signature:c,...a}=await t.login({token:s});if(!i)return console.warn("Login cancelled."),null;if(!c)return console.error("Failed to sign login token"),null;let p=n.getToken({address:i,token:s,signature:c});k({loginToken:s,signature:c,nativeAuthToken:p});let d=await _({loginToken:s,extraInfoData:{multisig:a?.multisig,impersonate:a?.impersonate},address:i});return await w({address:d,provider:t,apiAddress:e}),{address:d,signature:c}}async function H(t,o){let r=I(N());if(r)return await rt({provider:t,nativeAuthConfig:r,token:o?.token});let{address:e}=await ot(t);return await f(e),v(),{address:e}}var y={error:{title:"Error when signing".toString(),iconClassName:"danger",toastId:`${R}-${Date.now()}`},warning:{title:"Signing canceled".toString(),iconClassName:"warning",toastId:`${D}-${Date.now()}`}},et={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"},nt=t=>{for(let[o,r]of Object.entries(et))if(t.includes(o))return r;return"Error when signing"};function A(t,o="error"){let r=t?.message,e=nt(r),s=e!=="Error when signing"?"warning":o,i=Object.keys(y).includes(s)?y[s]:y.error,{toastId:c,iconClassName:a,title:p}=i;return q({toastId:c,duration:1e4,icon:"times",iconClassName:a,message:e,title:p}),e}async function J({provider:t,transactions:o,options:r={}}){await Q();let{isGuarded:e,activeGuardianAddress:n,nonce:s}=V(),i=t.getType()===E.ledger,c=j({latestNonce:s,transactions:o}),a=n&&e&&!r.skipGuardian?c?.map(d=>(d.version=C.withTxOptions().valueOf(),d.options=S.withOptions({guarded:!0,...i?{hashSign:!0}:{}}).valueOf(),d.guardian=P.newFromBech32(n),d)):c,p=await t.signTransactions(a)??[];return O(s+p.length),p}var x=class{constructor(o){this.provider=o}init(){return this.provider.init()}async login(o){return await H(this.provider,o)}isInitialized(){return this.provider.isInitialized()}async logout(o={shouldBroadcastLogoutAcrossTabs:!0,hasConsentPopup:!1}){return await z({provider:this.provider,options:o})}setShouldShowConsentPopup(o){this.provider.setShouldShowConsentPopup?.(o)}getType(){return this.provider.getType()}getProvider(){return this.provider}async signTransactions(o,r){try{return await J({provider:this.provider,transactions:o,options:r})}catch(e){let n=A(e);throw new Error(n)}}async signMessage(o,r){try{return await G({provider:this.provider,message:o,options:r})}catch(e){let n=A(e,"warning");throw new Error(n)}}async verifyMessage(o){return await $(o)}cancelLogin(){this.provider.cancelLogin?.()}};var X=null;function go(t){X=t}function Y(){return X||new x(B)}var st=async()=>{try{let t=L(),{network:o}=u();try{let r=await g({address:t,baseURL:o.apiAddress});if(r!=null){let e={...r,username:h(r.username),nonce:T(r)};return l(e),e}}catch(r){console.error("Failed getting account ",r)}}catch(t){console.error("Failed getting address ",t)}return null};async function Q(){let t=Y();if(t==null)throw"Provider not initialized";try{if(!t.init)throw"Current provider does not have init() function";return await t.init()?st():void 0}catch(o){console.error("Failed initializing provider ",o)}}var Z={},tt={},it=(t,o)=>{m().setState(({toasts:r})=>{let e=r.customToasts.length>0?Math.max(...r.customToasts.map(a=>parseInt(a.toastId.split("-").pop()??"0"))):0,n=o??`custom-toast-${e+1}`,s=r.customToasts.findIndex(a=>a.toastId===n),i={...t,toastId:n};if(s!==-1){r.customToasts[s]=i;return}r.customToasts.push({...i,toastId:n})},!1,"addCustomToast")},_o=t=>{m().setState(({toasts:o})=>{o.customToasts=o.customToasts.filter(r=>r.toastId!==t)},!1,"removeCustomToast")},zo=()=>{m().setState(({toasts:t})=>{t.customToasts=[]},!1,"removeAllCustomToasts")},Go=()=>{m().setState(({toasts:t})=>{t.transactionToasts=[]})},$o=({toastId:t,totalDuration:o})=>{m().setState(({toasts:r})=>{let e=r.transactionToasts.length>0?Math.max(...r.transactionToasts.map(s=>parseInt(s.toastId.split("-").pop()??"0"))):0,n=t||`transaction-toast-${e+1}`;r.transactionToasts.push({startTime:b(),endTime:K(o),toastId:n})},!1,"addTransactionToast")},Vo=t=>{m().setState(({toasts:o})=>{o.transactionToasts=o.transactionToasts.filter(r=>r.toastId!==t)},!1,"removeTransactionToast"),delete tt[t],delete Z[t]},q=t=>{let{toasts:o}=m().getState(),r=o.customToasts.length>0?Math.max(...o.customToasts.map(n=>parseInt(n.toastId.split("-").pop()??"0"))):0,e=t.toastId||`custom-toast-${r+1}`;return t.onClose&&(tt[e]=t.onClose),t.instantiateToastElement?(Z[e]=t.instantiateToastElement,m().setState(({toasts:n})=>{let s=n.customToasts.findIndex(a=>a.toastId===e),i={...t,instantiateToastElement:null,toastId:e};s!==-1?n.customToasts[s]=i:n.customToasts.push(i)},!1,"createCustomToast"),e):(it(t,e),e)};export{Z as a,tt as b,it as c,_o as d,zo as e,Go as f,$o as g,Vo as h,q as i,w as j,H as k,A as l,J as m,x as n,go as o,Y as p,Q as q};
|
|
2
|
-
//# sourceMappingURL=chunk-DKGAK7SX.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/providers/DappProvider/helpers/login/helpers/accountLogin.ts", "../../src/providers/DappProvider/helpers/login/login.ts", "../../src/providers/DappProvider/helpers/signErrors/handleSignError.ts", "../../src/providers/DappProvider/helpers/signTransactions/signTransactionsWithProvider.ts", "../../src/providers/DappProvider/DappProvider.ts", "../../src/providers/helpers/accountProvider.ts", "../../src/utils/account/refreshAccount.ts", "../../src/store/actions/toasts/toastsActions.ts"],
|
|
4
|
-
"sourcesContent": ["import { getLatestNonce } from 'methods/account/getLatestNonce';\nimport { setGasStationMetadata } from 'methods/initApp/gastStationMetadata/setGasStationMetadata';\nimport { registerWebsocketListener } from 'methods/initApp/websocket/registerWebsocket';\nimport { trackTransactions } from 'methods/trackTransactions/trackTransactions';\nimport { IProvider } from 'providers/types/providerFactory.types';\nimport { loginAction } from 'store/actions';\nimport { setAccount } from 'store/actions/account';\nimport { AccountType } from 'types/account.types';\nimport { fetchAccount } from 'utils/account/fetchAccount';\nimport { trimUsernameDomain } from 'utils/account/trimUsernameDomain';\n\ninterface IAccountLoginProps {\n address: string;\n provider: IProvider;\n apiAddress: string;\n}\n\nexport async function accountLogin({\n address,\n provider,\n apiAddress\n}: IAccountLoginProps) {\n const account = await fetchAccount({\n address,\n baseURL: apiAddress\n });\n\n if (!account) {\n throw new Error('Account not found');\n }\n\n loginAction({\n address,\n providerType: provider.getType()\n });\n\n const newAccount: AccountType = {\n ...account,\n username: trimUsernameDomain(account.username),\n nonce: getLatestNonce(account)\n };\n\n setAccount(newAccount);\n\n await registerWebsocketListener(address);\n trackTransactions();\n\n if (account.shard != null) {\n await setGasStationMetadata({\n shard: Number(account.shard),\n apiAddress\n });\n }\n}\n", "import { registerWebsocketListener } from 'methods/initApp/websocket/registerWebsocket';\nimport { getNetworkConfig } from 'methods/network/getNetworkConfig';\nimport { trackTransactions } from 'methods/trackTransactions/trackTransactions';\nimport { IProvider } from 'providers/types/providerFactory.types';\nimport { nativeAuth } from 'services/nativeAuth';\nimport { NativeAuthConfigType } from 'services/nativeAuth/nativeAuth.types';\nimport { setTokenLogin } from 'store/actions/loginInfo/loginInfoActions';\nimport { nativeAuthConfigSelector } from 'store/selectors';\nimport { getState } from 'store/store';\nimport { accountLogin } from './helpers/accountLogin';\nimport { extractAddressFromToken } from './helpers/extractAddressFromToken';\n\nasync function loginWithoutNativeToken(provider: IProvider) {\n const {\n network: { apiAddress }\n } = getNetworkConfig();\n\n await provider.login();\n\n const address = await provider.getAddress();\n\n if (!address) {\n throw new Error('Address not found');\n }\n\n await accountLogin({ address, provider, apiAddress });\n\n return {\n address\n };\n}\n\nasync function loginWithNativeToken({\n provider,\n nativeAuthConfig,\n token\n}: {\n provider: IProvider;\n nativeAuthConfig: NativeAuthConfigType;\n token?: string;\n}) {\n const {\n network: { apiAddress }\n } = getNetworkConfig();\n\n const nativeAuthClient = nativeAuth(nativeAuthConfig);\n let loginToken = token;\n\n if (!loginToken) {\n loginToken = await nativeAuthClient.initialize({\n noCache: true\n });\n }\n\n const { address, signature, ...loginResult } = await provider.login({\n token: loginToken\n });\n\n if (!address) {\n console.warn('Login cancelled.');\n return null;\n }\n\n if (!signature) {\n console.error('Failed to sign login token');\n return null;\n }\n\n const nativeAuthToken = nativeAuthClient.getToken({\n address,\n token: loginToken,\n signature\n });\n\n setTokenLogin({\n loginToken,\n signature,\n nativeAuthToken\n });\n\n const extractedAddress = await extractAddressFromToken({\n loginToken,\n extraInfoData: {\n multisig: loginResult?.multisig,\n impersonate: loginResult?.impersonate\n },\n address\n });\n\n await accountLogin({\n address: extractedAddress,\n provider,\n apiAddress\n });\n\n return {\n address: extractedAddress,\n signature\n };\n}\n\nexport async function login(provider: IProvider, options?: { token?: string }) {\n const nativeAuthConfig = nativeAuthConfigSelector(getState());\n\n if (nativeAuthConfig) {\n const data = await loginWithNativeToken({\n provider,\n nativeAuthConfig,\n token: options?.token\n });\n return data;\n }\n\n const { address } = await loginWithoutNativeToken(provider);\n\n await registerWebsocketListener(address);\n trackTransactions();\n\n return { address };\n}\n", "import {\n CANCEL_TRANSACTION_TOAST_DEFAULT_DURATION,\n CANCEL_TRANSACTION_TOAST_ID,\n ERROR_SIGNING_TOAST_ID\n} from 'constants/transactions.constants';\nimport { ToastIconsEnum } from 'managers/internal/ToastManager/helpers/getToastDataStateByStatus';\nimport { createCustomToast } from 'store/actions';\nimport { SigningErrorsEnum, SigningWarningsEnum } from 'types/enums.types';\n\nconst states = {\n error: {\n title: SigningErrorsEnum.errorSigning.toString(),\n iconClassName: 'danger',\n toastId: `${ERROR_SIGNING_TOAST_ID}-${Date.now()}`\n },\n warning: {\n title: SigningWarningsEnum.cancelled.toString(),\n iconClassName: 'warning',\n toastId: `${CANCEL_TRANSACTION_TOAST_ID}-${Date.now()}`\n }\n};\n\nconst errorsMap = {\n extensionResponse: 'Unable to sign transactions', // extension\n 'Transaction canceled': 'Transaction canceled', // web wallet\n 'cancelled by user': 'Transaction signing cancelled by user', // custom\n 'denied by the user': 'Transaction signing denied by the user' // ledger\n};\n\nconst getUserError = (error: string) => {\n for (const [key, value] of Object.entries(errorsMap)) {\n if (error.includes(key)) {\n return value;\n }\n }\n return SigningErrorsEnum.errorSigning;\n};\n\nexport function handleSignError(\n error: unknown,\n type: 'error' | 'warning' = 'error'\n) {\n const originalError = (error as Error)?.message;\n const errorMessage = getUserError(originalError);\n\n const isKnownError = errorMessage !== SigningErrorsEnum.errorSigning;\n\n const errorType = isKnownError ? 'warning' : type;\n\n const state = Object.keys(states).includes(errorType)\n ? states[errorType]\n : states.error;\n\n const { toastId, iconClassName, title } = state;\n\n createCustomToast({\n toastId,\n duration: CANCEL_TRANSACTION_TOAST_DEFAULT_DURATION,\n icon: ToastIconsEnum.times,\n iconClassName,\n message: errorMessage,\n title\n });\n\n return errorMessage;\n}\n", "import {\n Address,\n Transaction,\n TransactionOptions,\n TransactionVersion\n} from 'lib/sdkCore';\nimport { getAccount } from 'methods/account/getAccount';\nimport {\n IProvider,\n ProviderTypeEnum\n} from 'providers/types/providerFactory.types';\nimport { setAccountNonce } from 'store/actions';\nimport { refreshAccount } from 'utils';\nimport { computeNonces } from '../computeNonces/computeNonces';\n\nexport type SignTransactionsOptionsType = {\n skipGuardian?: boolean;\n};\n\ntype SignTransactionsType = {\n provider: IProvider;\n transactions: Transaction[];\n options?: SignTransactionsOptionsType;\n};\n\nexport async function signTransactionsWithProvider({\n provider,\n transactions,\n options = {}\n}: SignTransactionsType): Promise<Transaction[]> {\n await refreshAccount();\n const { isGuarded, activeGuardianAddress, nonce } = getAccount();\n const isLedger = provider.getType() === ProviderTypeEnum.ledger;\n\n const transactionsWithComputedNonce = computeNonces({\n latestNonce: nonce,\n transactions\n });\n\n const transactionsToSign =\n activeGuardianAddress && isGuarded && !options.skipGuardian\n ? transactionsWithComputedNonce?.map((transaction) => {\n transaction.version = TransactionVersion.withTxOptions().valueOf();\n transaction.options = TransactionOptions.withOptions({\n guarded: true,\n ...(isLedger ? { hashSign: true } : {})\n }).valueOf();\n\n transaction.guardian = Address.newFromBech32(activeGuardianAddress);\n\n return transaction;\n })\n : transactionsWithComputedNonce;\n\n const signedTransactions: Transaction[] =\n (await provider.signTransactions(transactionsToSign)) ?? [];\n\n setAccountNonce(nonce + signedTransactions.length);\n\n return signedTransactions;\n}\n", "import { Message, Transaction } from 'lib/sdkCore';\nimport { IProvider } from '../types/providerFactory.types';\nimport { login } from './helpers/login/login';\nimport { logout } from './helpers/logout/logout';\nimport { handleSignError } from './helpers/signErrors/handleSignError';\nimport { signMessageWithProvider } from './helpers/signMessage/signMessageWithProvider';\nimport {\n verifyMessage,\n VerifyMessageReturnType\n} from './helpers/signMessage/verifyMessage';\nimport {\n signTransactionsWithProvider,\n SignTransactionsOptionsType\n} from './helpers/signTransactions/signTransactionsWithProvider';\n\nexport class DappProvider {\n private provider: IProvider;\n\n constructor(provider: IProvider) {\n this.provider = provider;\n }\n\n init(): Promise<boolean> {\n return this.provider.init();\n }\n\n async login(options?: { token?: string }) {\n const data = await login(this.provider, options);\n return data;\n }\n\n isInitialized(): boolean {\n return this.provider.isInitialized();\n }\n\n async logout(\n options = {\n shouldBroadcastLogoutAcrossTabs: true,\n hasConsentPopup: false\n }\n ): Promise<boolean> {\n return await logout({ provider: this.provider, options });\n }\n\n setShouldShowConsentPopup(shouldShow: boolean): void {\n this.provider.setShouldShowConsentPopup?.(shouldShow);\n }\n\n getType() {\n return this.provider.getType();\n }\n\n /**\n * @returns The original provider instance.\n */\n getProvider() {\n return this.provider;\n }\n\n async signTransactions(\n transactions: Transaction[],\n options?: SignTransactionsOptionsType\n ): Promise<Transaction[]> {\n try {\n const signedTransactions = await signTransactionsWithProvider({\n provider: this.provider,\n transactions,\n options\n });\n return signedTransactions;\n } catch (error) {\n const errorMessage = handleSignError(error);\n throw new Error(errorMessage);\n }\n }\n\n async signMessage(\n message: Message,\n options?: {\n hasConsentPopup?: boolean;\n }\n ): Promise<Message | null> {\n try {\n const signedMessage = await signMessageWithProvider({\n provider: this.provider,\n message,\n options\n });\n return signedMessage;\n } catch (error) {\n const errorMessage = handleSignError(error, 'warning');\n throw new Error(errorMessage);\n }\n }\n\n /**\n * @param signedMessage - The signed message to verify in form of a JSON string with `address`, `message` and `signature` properties.\n * @returns The verification result with `isVerified`, `message` and `address` properties.\n */\n async verifyMessage(signedMessage: string): Promise<VerifyMessageReturnType> {\n return await verifyMessage(signedMessage);\n }\n\n cancelLogin(): void {\n this.provider.cancelLogin?.();\n }\n}\n", "import { IProvider } from 'providers/types/providerFactory.types';\nimport { DappProvider } from '../DappProvider';\nimport { emptyProvider } from './emptyProvider';\n\nexport type ProvidersType = IProvider;\n\nlet accountProvider: DappProvider | null = null;\n\nexport function setAccountProvider<TProvider extends DappProvider | null>(\n provider: TProvider\n) {\n accountProvider = provider;\n}\n\nexport function getAccountProvider(): DappProvider {\n return accountProvider || new DappProvider(emptyProvider);\n}\n", "import { getAddress } from 'methods/account/getAddress';\nimport { getLatestNonce } from 'methods/account/getLatestNonce';\nimport { getNetworkConfig } from 'methods/network/getNetworkConfig';\nimport { getAccountProvider } from 'providers/helpers/accountProvider';\nimport { setAccount } from 'store/actions';\nimport { fetchAccount } from './fetchAccount';\nimport { trimUsernameDomain } from './trimUsernameDomain';\n\nconst setNewAccount = async () => {\n try {\n const address = getAddress();\n const { network } = getNetworkConfig();\n\n try {\n const account = await fetchAccount({\n address,\n baseURL: network.apiAddress\n });\n\n if (account != null) {\n const accountData = {\n ...account,\n username: trimUsernameDomain(account.username),\n nonce: getLatestNonce(account)\n };\n\n setAccount(accountData);\n\n return accountData;\n }\n } catch (e) {\n console.error('Failed getting account ', e);\n }\n } catch (e) {\n console.error('Failed getting address ', e);\n }\n\n return null;\n};\n\nexport async function refreshAccount() {\n const provider = getAccountProvider();\n\n if (provider == null) {\n throw 'Provider not initialized';\n }\n\n try {\n if (!provider.init) {\n throw 'Current provider does not have init() function';\n }\n\n const initialized = await provider.init();\n\n if (!initialized) {\n return;\n }\n\n return setNewAccount();\n } catch (e) {\n console.error('Failed initializing provider ', e);\n }\n\n return undefined;\n}\n", "import {\n CustomToastType,\n IComponentToast\n} from 'store/slices/toast/toastSlice.types';\nimport { getStore } from 'store/store';\nimport { getUnixTimestamp, getUnixTimestampWithAddedMilliseconds } from 'utils';\n\nexport const customToastComponentDictionary: Record<\n string,\n IComponentToast['instantiateToastElement']\n> = {};\nexport const customToastCloseHandlersDictionary: Record<string, () => void> =\n {};\n\nexport const addCustomToast = (\n customToast: CustomToastType,\n currentToastId?: string\n) => {\n getStore().setState(\n ({ toasts: state }) => {\n const lastToastIndex =\n state.customToasts.length > 0\n ? Math.max(\n ...state.customToasts.map((toast) =>\n parseInt(toast.toastId.split('-').pop() ?? '0')\n )\n )\n : 0;\n const toastId = currentToastId ?? `custom-toast-${lastToastIndex + 1}`;\n\n const existingToastIndex = state.customToasts.findIndex(\n (toast) => toast.toastId === toastId\n );\n\n const newToast: CustomToastType = {\n ...customToast,\n toastId\n };\n\n const isToastFound = existingToastIndex !== -1;\n\n if (isToastFound) {\n state.customToasts[existingToastIndex] = newToast;\n return;\n }\n\n state.customToasts.push({\n ...newToast,\n toastId\n });\n },\n false,\n 'addCustomToast'\n );\n};\n\nexport const removeCustomToast = (toastId: string) => {\n getStore().setState(\n ({ toasts: state }) => {\n state.customToasts = state.customToasts.filter(\n (toast) => toast.toastId !== toastId\n );\n },\n false,\n 'removeCustomToast'\n );\n};\n\nexport const removeAllCustomToasts = () => {\n getStore().setState(\n ({ toasts: state }) => {\n state.customToasts = [];\n },\n false,\n 'removeAllCustomToasts'\n );\n};\n\nexport const removeAllTransactionToasts = () => {\n getStore().setState(({ toasts: state }) => {\n state.transactionToasts = [];\n });\n};\n\nexport const addTransactionToast = ({\n toastId,\n totalDuration\n}: {\n toastId: string;\n totalDuration: number;\n}) => {\n getStore().setState(\n ({ toasts: state }) => {\n const lastToastIndex =\n state.transactionToasts.length > 0\n ? Math.max(\n ...state.transactionToasts.map((toast) =>\n parseInt(toast.toastId.split('-').pop() ?? '0')\n )\n )\n : 0;\n const newToastId = toastId || `transaction-toast-${lastToastIndex + 1}`;\n\n state.transactionToasts.push({\n startTime: getUnixTimestamp(),\n endTime: getUnixTimestampWithAddedMilliseconds(totalDuration),\n toastId: newToastId\n });\n },\n false,\n 'addTransactionToast'\n );\n};\n\nexport const removeTransactionToast = (toastId: string) => {\n getStore().setState(\n ({ toasts: state }) => {\n state.transactionToasts = state.transactionToasts.filter((toast) => {\n return toast.toastId !== toastId;\n });\n },\n false,\n 'removeTransactionToast'\n );\n\n delete customToastCloseHandlersDictionary[toastId];\n delete customToastComponentDictionary[toastId];\n};\n\nexport const createCustomToast = (props: CustomToastType) => {\n const { toasts } = getStore().getState();\n\n const lastToastIndex =\n toasts.customToasts.length > 0\n ? Math.max(\n ...toasts.customToasts.map((toast) =>\n parseInt(toast.toastId.split('-').pop() ?? '0')\n )\n )\n : 0;\n\n const toastId = props.toastId || `custom-toast-${lastToastIndex + 1}`;\n\n if (props.onClose) {\n customToastCloseHandlersDictionary[toastId] = props.onClose;\n }\n\n if (props.instantiateToastElement) {\n customToastComponentDictionary[toastId] = props.instantiateToastElement;\n\n getStore().setState(\n ({ toasts: state }) => {\n const existingToastIndex = state.customToasts.findIndex(\n (toast) => toast.toastId === toastId\n );\n\n const toast: CustomToastType = {\n ...props,\n instantiateToastElement: null,\n toastId\n };\n\n const isToastFound = existingToastIndex !== -1;\n\n if (isToastFound) {\n state.customToasts[existingToastIndex] = toast;\n } else {\n state.customToasts.push(toast);\n }\n },\n false,\n 'createCustomToast'\n );\n\n return toastId;\n }\n\n addCustomToast(props, toastId);\n return toastId;\n};\n"],
|
|
5
|
-
"mappings": "kjCAiBA,eAAsBA,EAAa,CACjC,QAAAC,EACA,SAAAC,EACA,WAAAC,CACF,EAAuB,CACrB,IAAMC,EAAU,MAAMC,EAAa,CACjC,QAAAJ,EACA,QAASE,CACX,CAAC,EAED,GAAI,CAACC,EACH,MAAM,IAAI,MAAM,mBAAmB,EAGrCE,EAAY,CACV,QAAAL,EACA,aAAcC,EAAS,QAAQ,CACjC,CAAC,EAED,IAAMK,EAA0B,CAC9B,GAAGH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,UAAYC,CAC/B,EAEMD,EAAyB,CAC7B,GAAGc,EACH,wBAAyB,KACzB,QAAAb,CACF,EAEqBC,IAAuB,GAG1CJ,EAAM,aAAaI,CAAkB,EAAIF,EAEzCF,EAAM,aAAa,KAAKE,CAAK,CAEjC,EACA,GACA,mBACF,EAEOC,IAGTP,GAAeoB,EAAOb,CAAO,EACtBA,EACT",
|
|
6
|
-
"names": ["accountLogin", "address", "provider", "apiAddress", "account", "fetchAccount", "loginAction", "newAccount", "trimUsernameDomain", "getLatestNonce", "setAccount", "registerWebsocketListener", "trackTransactions", "setGasStationMetadata", "loginWithoutNativeToken", "provider", "apiAddress", "getNetworkConfig", "address", "accountLogin", "loginWithNativeToken", "nativeAuthConfig", "token", "nativeAuthClient", "nativeAuth", "loginToken", "signature", "loginResult", "nativeAuthToken", "setTokenLogin", "extractedAddress", "extractAddressFromToken", "login", "options", "nativeAuthConfigSelector", "getState", "registerWebsocketListener", "trackTransactions", "states", "ERROR_SIGNING_TOAST_ID", "CANCEL_TRANSACTION_TOAST_ID", "errorsMap", "getUserError", "error", "key", "value", "handleSignError", "type", "originalError", "errorMessage", "errorType", "state", "toastId", "iconClassName", "title", "createCustomToast", "signTransactionsWithProvider", "provider", "transactions", "options", "refreshAccount", "isGuarded", "activeGuardianAddress", "nonce", "getAccount", "isLedger", "ProviderTypeEnum", "transactionsWithComputedNonce", "computeNonces", "transactionsToSign", "transaction", "TransactionVersion", "TransactionOptions", "Address", "signedTransactions", "setAccountNonce", "DappProvider", "provider", "options", "login", "logout", "shouldShow", "transactions", "signTransactionsWithProvider", "error", "errorMessage", "handleSignError", "message", "signMessageWithProvider", "signedMessage", "verifyMessage", "accountProvider", "setAccountProvider", "provider", "getAccountProvider", "DappProvider", "emptyProvider", "setNewAccount", "address", "getAddress", "network", "getNetworkConfig", "account", "fetchAccount", "accountData", "trimUsernameDomain", "getLatestNonce", "setAccount", "e", "refreshAccount", "provider", "getAccountProvider", "customToastComponentDictionary", "customToastCloseHandlersDictionary", "addCustomToast", "customToast", "currentToastId", "getStore", "state", "lastToastIndex", "toast", "toastId", "existingToastIndex", "newToast", "removeCustomToast", "removeAllCustomToasts", "removeAllTransactionToasts", "addTransactionToast", "totalDuration", "newToastId", "getUnixTimestamp", "getUnixTimestampWithAddedMilliseconds", "removeTransactionToast", "createCustomToast", "props", "toasts"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as o}from"./chunk-PVEKU2X3.mjs";import{a as t}from"./chunk-NHXPNROG.mjs";import{b as e}from"./chunk-FP2LZG6I.mjs";import{WebviewProvider as n}from"@multiversx/sdk-webview-provider/out/WebviewProvider";var s=class extends o{constructor(r){super(r?.address);this.cancelAction=async()=>{this.provider.cancelAction()};this.signTransactions=async r=>{if(!this.provider)throw new Error("Provider is not initialized.");try{return await this.provider.signTransactions(r)||[]}catch(i){throw this.cancelAction(),i}};this.signMessage=async r=>{if(!this.provider)throw new Error("Provider is not initialized.");try{return await this.provider.signMessage(r)}catch(i){throw this.cancelAction(),i}};this.provider=n.getInstance(),this._login=this.provider.login.bind(this.provider)}async init(){return this.initializeAddress(),this.initializeProvider()}logout(){return this.provider.logout()}getType(){return t.webview}getAddress(){throw new Error("Method not implemented.")}setAccount(r){return this.provider.setAccount(r)}isInitialized(){return this.provider.isInitialized()}async initializeProvider(){let r=await this.provider.init(e);return this.address&&this.setAccount({address:this.address}),r}};export{s as a};
|
|
2
|
-
//# sourceMappingURL=chunk-DQKFSHIR.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/providers/strategies/WebviewProviderStrategy/WebviewProviderStrategy.ts"],
|
|
4
|
-
"sourcesContent": ["import { WebviewProvider } from '@multiversx/sdk-webview-provider/out/WebviewProvider';\nimport { version } from 'constants/window.constants';\nimport { Message, Transaction } from 'lib/sdkCore';\nimport { IDAppProviderAccount } from 'lib/sdkDappUtils';\nimport {\n ProviderTypeEnum,\n ProviderType\n} from 'providers/types/providerFactory.types';\nimport { ProviderErrorsEnum } from 'types/provider.types';\nimport { BaseProviderStrategy } from '../BaseProviderStrategy/BaseProviderStrategy';\n\ntype WebviewProviderProps = {\n address?: string;\n};\n\nexport class WebviewProviderStrategy extends BaseProviderStrategy {\n private readonly provider: WebviewProvider;\n\n constructor(config?: WebviewProviderProps) {\n super(config?.address);\n this.provider = WebviewProvider.getInstance();\n this._login = this.provider.login.bind(this.provider);\n }\n\n async init(): Promise<boolean> {\n this.initializeAddress();\n return this.initializeProvider();\n }\n\n logout(): Promise<boolean> {\n return this.provider.logout();\n }\n\n getType(): ProviderType {\n return ProviderTypeEnum.webview;\n }\n\n getAddress(): Promise<string | undefined> {\n throw new Error('Method not implemented.');\n }\n\n setAccount(account: IDAppProviderAccount): void {\n return this.provider.setAccount(account);\n }\n\n isInitialized(): boolean {\n return this.provider.isInitialized();\n }\n\n private async initializeProvider() {\n const isInitialized = await this.provider.init(version);\n\n if (this.address) {\n this.setAccount({ address: this.address });\n }\n\n return isInitialized;\n }\n\n cancelAction = async () => {\n this.provider.cancelAction();\n };\n\n signTransactions = async (transactions: Transaction[]) => {\n if (!this.provider) {\n throw new Error(ProviderErrorsEnum.notInitialized);\n }\n\n try {\n const signedTransactions =\n await this.provider.signTransactions(transactions);\n return signedTransactions || [];\n } catch (error) {\n this.cancelAction();\n throw error;\n }\n };\n\n signMessage = async (message: Message) => {\n if (!this.provider) {\n throw new Error(ProviderErrorsEnum.notInitialized);\n }\n\n try {\n const signedMessage = await this.provider.signMessage(message);\n return signedMessage;\n } catch (error) {\n this.cancelAction();\n throw error;\n }\n };\n}\n"],
|
|
5
|
-
"mappings": "2HAAA,OAAS,mBAAAA,MAAuB,uDAezB,IAAMC,EAAN,cAAsCC,CAAqB,CAGhE,YAAYC,EAA+B,CACzC,MAAMA,GAAQ,OAAO,EAwCvB,kBAAe,SAAY,CACzB,KAAK,SAAS,aAAa,CAC7B,EAEA,sBAAmB,MAAOC,GAAgC,CACxD,GAAI,CAAC,KAAK,SACR,MAAM,IAAI,oCAAuC,EAGnD,GAAI,CAGF,OADE,MAAM,KAAK,SAAS,iBAAiBA,CAAY,GACtB,CAAC,CAChC,OAASC,EAAO,CACd,WAAK,aAAa,EACZA,CACR,CACF,EAEA,iBAAc,MAAOC,GAAqB,CACxC,GAAI,CAAC,KAAK,SACR,MAAM,IAAI,oCAAuC,EAGnD,GAAI,CAEF,OADsB,MAAM,KAAK,SAAS,YAAYA,CAAO,CAE/D,OAASD,EAAO,CACd,WAAK,aAAa,EACZA,CACR,CACF,EAtEE,KAAK,SAAWE,EAAgB,YAAY,EAC5C,KAAK,OAAS,KAAK,SAAS,MAAM,KAAK,KAAK,QAAQ,CACtD,CAEA,MAAM,MAAyB,CAC7B,YAAK,kBAAkB,EAChB,KAAK,mBAAmB,CACjC,CAEA,QAA2B,CACzB,OAAO,KAAK,SAAS,OAAO,CAC9B,CAEA,SAAwB,CACtB,OAAOC,EAAiB,OAC1B,CAEA,YAA0C,CACxC,MAAM,IAAI,MAAM,yBAAyB,CAC3C,CAEA,WAAWC,EAAqC,CAC9C,OAAO,KAAK,SAAS,WAAWA,CAAO,CACzC,CAEA,eAAyB,CACvB,OAAO,KAAK,SAAS,cAAc,CACrC,CAEA,MAAc,oBAAqB,CACjC,IAAMC,EAAgB,MAAM,KAAK,SAAS,KAAKC,CAAO,EAEtD,OAAI,KAAK,SACP,KAAK,WAAW,CAAE,QAAS,KAAK,OAAQ,CAAC,EAGpCD,CACT,CAkCF",
|
|
6
|
-
"names": ["WebviewProvider", "WebviewProviderStrategy", "BaseProviderStrategy", "config", "transactions", "error", "message", "WebviewProvider", "ProviderTypeEnum", "account", "isInitialized", "version"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a}from"./chunk-RNZEARAQ.mjs";import{c as o,g as n}from"./chunk-R53MCZI6.mjs";import{a as r}from"./chunk-NHXPNROG.mjs";async function M({message:i,provider:s,options:e}){let t=a(),d=new n({address:new o(t),data:i.data});return e?.hasConsentPopup&&s.getType()===r.crossWindow&&s.setShouldShowConsentPopup(!0),await s.signMessage(d,e)}export{M as a};
|
|
2
|
-
//# sourceMappingURL=chunk-EXEJDQ3E.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/providers/DappProvider/helpers/signMessage/signMessageWithProvider.ts"],
|
|
4
|
-
"sourcesContent": ["import { Message, Address } from 'lib/sdkCore';\nimport { CrossWindowProvider } from 'lib/sdkWebWalletCrossWindowProvider';\nimport { getAddress } from 'methods/account/getAddress';\nimport {\n IProvider,\n ProviderTypeEnum\n} from 'providers/types/providerFactory.types';\n\nexport type SignMessageType = {\n provider: IProvider;\n message: Message;\n options?: {\n hasConsentPopup?: boolean;\n };\n};\n\nexport async function signMessageWithProvider({\n message,\n provider,\n options\n}: SignMessageType): Promise<Message | null> {\n const address = getAddress();\n\n const messageToSign = new Message({\n address: new Address(address),\n data: message.data\n });\n\n if (\n options?.hasConsentPopup &&\n provider.getType() === ProviderTypeEnum.crossWindow\n ) {\n (provider as unknown as CrossWindowProvider).setShouldShowConsentPopup(\n true\n ); // TODO: is this still needed ?\n }\n\n const signedMessage = await provider.signMessage(messageToSign, options);\n\n return signedMessage;\n}\n"],
|
|
5
|
-
"mappings": "6HAgBA,eAAsBA,EAAwB,CAC5C,QAAAC,EACA,SAAAC,EACA,QAAAC,CACF,EAA6C,CAC3C,IAAMC,EAAUC,EAAW,EAErBC,EAAgB,IAAIC,EAAQ,CAChC,QAAS,IAAIC,EAAQJ,CAAO,EAC5B,KAAMH,EAAQ,IAChB,CAAC,EAED,OACEE,GAAS,iBACTD,EAAS,QAAQ,IAAMO,EAAiB,aAEvCP,EAA4C,0BAC3C,EACF,EAGoB,MAAMA,EAAS,YAAYI,EAAeH,CAAO,CAGzE",
|
|
6
|
-
"names": ["signMessageWithProvider", "message", "provider", "options", "address", "getAddress", "messageToSign", "Message", "Address", "ProviderTypeEnum"]
|
|
7
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/lib/sdkWebWalletCrossWindowProvider.ts"],
|
|
4
|
-
"sourcesContent": ["export { CrossWindowProvider } from '@multiversx/sdk-web-wallet-cross-window-provider/out/CrossWindowProvider/CrossWindowProvider';\n"],
|
|
5
|
-
"mappings": "AAAA,OAAS,uBAAAA,MAA2B",
|
|
6
|
-
"names": ["CrossWindowProvider"]
|
|
7
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
//# sourceMappingURL=chunk-FLC6QSZB.mjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as e}from"./chunk-I7BB2JJP.mjs";var n=class t extends e{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE",uiTag:"mvx-wallet-connect"});this.initialData={wcURI:""};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-GZLK5ERT.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/managers/internal/WalletConnectStateManager/WalletConnectStateManager.ts"],
|
|
4
|
-
"sourcesContent": ["import { UITagsEnum } from 'constants/UITags.enum';\nimport { MvxWalletConnect } from 'lib/sdkDappUi';\nimport { UnlockPanelEventsEnum } from 'managers/UnlockPanelManager/UnlockPanelManager.types';\nimport {\n WalletConnectEventsEnum,\n IWalletConnectModalData\n} from 'providers/strategies/WalletConnectProviderStrategy/types/walletConnect.types';\nimport { UIBaseManager } from '../UIBaseManager/UIBaseManager';\n\nexport class WalletConnectStateManager extends UIBaseManager<\n MvxWalletConnect,\n IWalletConnectModalData,\n WalletConnectEventsEnum\n> {\n private static instance: WalletConnectStateManager;\n\n protected initialData: IWalletConnectModalData = {\n wcURI: ''\n };\n\n public static getInstance(): WalletConnectStateManager {\n if (!WalletConnectStateManager.instance) {\n WalletConnectStateManager.instance = new WalletConnectStateManager();\n }\n return WalletConnectStateManager.instance;\n }\n\n constructor() {\n super({\n uiDataUpdateEvent: WalletConnectEventsEnum.DATA_UPDATE,\n uiTag: UITagsEnum.WALLET_CONNECT\n });\n this.data = { ...this.initialData };\n }\n\n public handleClose(options?: { isLoginFinished?: boolean }) {\n if (options?.isLoginFinished) {\n return;\n }\n\n if (this.anchor) {\n this.anchor.dispatchEvent(\n new CustomEvent(UnlockPanelEventsEnum.ANCHOR_CLOSE, {\n composed: false,\n bubbles: false\n })\n );\n } else {\n this.destroy();\n }\n }\n\n protected async setupEventListeners() {\n if (!this.eventBus) {\n return;\n }\n\n this.eventBus.subscribe(\n WalletConnectEventsEnum.CLOSE,\n this.handleClose.bind(this)\n );\n\n this.eventBus.subscribe(\n WalletConnectEventsEnum.UI_DISCONNECTED,\n this.destroy.bind(this)\n );\n }\n}\n"],
|
|
5
|
-
"mappings": "yCASO,IAAMA,EAAN,MAAMC,UAAkCC,CAI7C,CAcA,aAAc,CACZ,MAAM,CACJ,gCACA,0BACF,CAAC,EAfH,KAAU,YAAuC,CAC/C,MAAO,EACT,EAcE,KAAK,KAAO,CAAE,GAAG,KAAK,WAAY,CACpC,CAbA,OAAc,aAAyC,CACrD,OAAKD,EAA0B,WAC7BA,EAA0B,SAAW,IAAIA,GAEpCA,EAA0B,QACnC,CAUO,YAAYE,EAAyC,CACtDA,GAAS,kBAIT,KAAK,OACP,KAAK,OAAO,cACV,IAAI,2BAAgD,CAClD,SAAU,GACV,QAAS,EACX,CAAC,CACH,EAEA,KAAK,QAAQ,EAEjB,CAEA,MAAgB,qBAAsB,CAC/B,KAAK,WAIV,KAAK,SAAS,kBAEZ,KAAK,YAAY,KAAK,IAAI,CAC5B,EAEA,KAAK,SAAS,4BAEZ,KAAK,QAAQ,KAAK,IAAI,CACxB,EACF,CACF",
|
|
6
|
-
"names": ["WalletConnectStateManager", "_WalletConnectStateManager", "UIBaseManager", "options"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as t}from"./chunk-K3WBBSXJ.mjs";import{c as n}from"./chunk-ZGRKIA6G.mjs";async function c({loginToken:r,extraInfoData:i,address:e}){let o=await t({originalLoginToken:r,extraInfoData:i,address:e});return o.modifiedLoginToken&&n(o.modifiedLoginToken),o.address}export{c as a};
|
|
2
|
-
//# sourceMappingURL=chunk-HO3JCUZA.mjs.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/managers/internal/UIBaseManager/UIBaseManager.ts"],
|
|
4
|
-
"sourcesContent": ["import { UITagsEnum } from 'constants/UITags.enum';\nimport { IEventBus } from 'lib/sdkDappUi';\nimport { ProviderErrorsEnum } from 'types/provider.types';\nimport {\n CreateEventBusUIElementType,\n createUIElement\n} from 'utils/createUIElement';\n\nexport abstract class UIBaseManager<\n TElement extends CreateEventBusUIElementType,\n TData extends Record<string, any> | null,\n TEventEnum extends string\n> {\n protected eventBus: IEventBus | null = null;\n protected uiElement: TElement | null = null;\n protected isCreatingElement = false;\n protected anchor?: HTMLElement;\n protected uiTag: UITagsEnum;\n protected uiDataUpdateEvent: TEventEnum;\n protected unsubscribeFunctions: Map<TEventEnum, (() => void)[]> = new Map();\n protected abstract initialData: TData;\n protected data: TData;\n\n constructor({\n uiDataUpdateEvent,\n uiTag\n }: {\n uiTag: UITagsEnum;\n uiDataUpdateEvent: TEventEnum;\n }) {\n this.uiDataUpdateEvent = uiDataUpdateEvent;\n this.uiTag = uiTag;\n this.data = this.getInitialData();\n }\n\n public async init(anchor?: HTMLElement) {\n this.anchor = anchor;\n await this.createUIElement(anchor);\n await this.setupEventListeners();\n }\n\n public updateData(newData: Partial<TData>) {\n this.data = { ...this.data, ...newData };\n this.notifyDataUpdate();\n }\n\n public subscribeToEventBus(event: TEventEnum, callback: Function) {\n if (!this.eventBus) {\n throw new Error(ProviderErrorsEnum.eventBusError);\n }\n\n const unsubscribe = this.eventBus?.subscribe(event, callback);\n if (unsubscribe) {\n const existing = this.unsubscribeFunctions.get(event) || [];\n existing.push(unsubscribe);\n this.unsubscribeFunctions.set(event, existing);\n }\n }\n\n public notifyDataUpdate() {\n this.eventBus?.publish(this.uiDataUpdateEvent, this.data);\n }\n\n protected destroy() {\n this.unsubscribeFunctions.forEach((unsubList) =>\n unsubList.forEach((unsubscribe) => unsubscribe())\n );\n this.unsubscribeFunctions.clear();\n this.eventBus = null;\n this.uiElement?.remove();\n this.uiElement = null;\n }\n\n protected getInitialData(): TData {\n return this.initialData;\n }\n\n protected resetData() {\n this.data = this.getInitialData();\n }\n\n protected abstract setupEventListeners(): Promise<void>;\n\n private async createUIElement(\n anchor: HTMLElement | undefined = this.anchor\n ): Promise<TElement | null> {\n if (this.isCreatingElement || this.uiElement) {\n return this.uiElement;\n }\n\n this.isCreatingElement = true;\n\n this.uiElement = await createUIElement<TElement>({\n name: this.uiTag,\n anchor\n });\n\n this.isCreatingElement = false;\n\n if (!this.uiElement) {\n throw new Error(`Failed to create ${this.uiTag} element`);\n }\n\n if (!this.eventBus) {\n this.eventBus = await this.uiElement.getEventBus();\n }\n\n if (!this.eventBus) {\n throw new Error(ProviderErrorsEnum.eventBusError);\n }\n\n return this.uiElement;\n }\n}\n"],
|
|
5
|
-
"mappings": "yCAQO,IAAeA,EAAf,KAIL,CAWA,YAAY,CACV,kBAAAC,EACA,MAAAC,CACF,EAGG,CAhBH,KAAU,SAA6B,KACvC,KAAU,UAA6B,KACvC,KAAU,kBAAoB,GAI9B,KAAU,qBAAwD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K,SAAW,MAAM,KAAK,UAAU,YAAY,GAG/C,CAAC,KAAK,SACR,MAAM,IAAI,mCAAsC,EAGlD,OAAO,KAAK,SACd,CACF",
|
|
6
|
-
"names": ["UIBaseManager", "uiDataUpdateEvent", "uiTag", "anchor", "newData", "event", "callback", "unsubscribe", "existing", "unsubList", "createUIElement"]
|
|
7
|
-
}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{a as s}from"./chunk-M3YL36ZL.mjs";import{a as o}from"./chunk-FFNSZC37.mjs";import{a as i}from"./chunk-NHXPNROG.mjs";var p=t=>(Object.values(i).forEach(r=>{if(r!==t?.skipLoginMethod)switch(r){case i.crossWindow:{let e=o.getInstance();e.isInitialized()&&e.dispose();break}case i.metamask:case i.passkey:{let e=s.getInstance();e.isInitialized()&&e.dispose();break}default:break}}),null);export{p as a};
|
|
2
|
-
//# sourceMappingURL=chunk-IEJARRBP.mjs.map
|