@multiversx/sdk-dapp 5.1.2 → 5.1.3

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.
Files changed (503) hide show
  1. package/out/__chunks__/{chunk-ZS4EBCWC.mjs → chunk-2GG67TZD.mjs} +2 -2
  2. package/out/__chunks__/chunk-2IUBMLF4.mjs +2 -0
  3. package/out/__chunks__/{chunk-CAA4VJRH.mjs.map → chunk-2IUBMLF4.mjs.map} +3 -3
  4. package/out/__chunks__/{chunk-YD2O3NV7.mjs → chunk-2KE2BNG7.mjs} +2 -2
  5. package/out/__chunks__/{chunk-2L25IGHZ.mjs → chunk-2KPILBQ2.mjs} +2 -2
  6. package/out/__chunks__/chunk-3JHE6RJX.mjs +2 -0
  7. package/out/__chunks__/{chunk-2DUVXRMU.mjs → chunk-3MJNBS6H.mjs} +2 -2
  8. package/out/__chunks__/{chunk-7VNNDJ7P.mjs → chunk-463K27BJ.mjs} +2 -2
  9. package/out/__chunks__/{chunk-7ONKP4ZG.mjs → chunk-4AGZHXFR.mjs} +2 -2
  10. package/out/__chunks__/{chunk-I6WJ63GD.mjs → chunk-4N34K4EN.mjs} +2 -2
  11. package/out/__chunks__/{chunk-IZ4B4B35.mjs → chunk-4PILLRHM.mjs} +2 -2
  12. package/out/__chunks__/{chunk-54XYKDH7.mjs → chunk-555CAG7Y.mjs} +2 -2
  13. package/out/__chunks__/{chunk-2ONA7QPD.mjs → chunk-5DP2QBUG.mjs} +2 -2
  14. package/out/__chunks__/{chunk-5KVNYLOM.mjs → chunk-6DWUEZO7.mjs} +2 -2
  15. package/out/__chunks__/{chunk-IWROXIQ5.mjs → chunk-6V76WUHS.mjs} +2 -2
  16. package/out/__chunks__/{chunk-VRG2R5C7.mjs → chunk-76A63VDO.mjs} +2 -2
  17. package/out/__chunks__/{chunk-UXYMY3HG.mjs → chunk-7HNMIUES.mjs} +2 -2
  18. package/out/__chunks__/{chunk-3CKDOF3O.mjs → chunk-A3CEGIRB.mjs} +2 -2
  19. package/out/__chunks__/chunk-AIKQPMR3.mjs +2 -0
  20. package/out/__chunks__/{chunk-LPGMDX6Q.mjs → chunk-AYURCZHZ.mjs} +2 -2
  21. package/out/__chunks__/chunk-BHAHZQVO.mjs +2 -0
  22. package/out/__chunks__/chunk-BHAHZQVO.mjs.map +7 -0
  23. package/out/__chunks__/{chunk-DJ2HTZOV.mjs → chunk-BUHHNIJJ.mjs} +2 -2
  24. package/out/__chunks__/{chunk-RNSBN5JT.mjs → chunk-C25AGRYE.mjs} +2 -2
  25. package/out/__chunks__/{chunk-RJOP7SCI.mjs → chunk-CIB3ITZR.mjs} +2 -2
  26. package/out/__chunks__/chunk-CUS6AHOH.mjs +2 -0
  27. package/out/__chunks__/chunk-DSVSX4ZT.mjs +2 -0
  28. package/out/__chunks__/chunk-DSVSX4ZT.mjs.map +7 -0
  29. package/out/__chunks__/chunk-DZ2BIDRW.mjs +2 -0
  30. package/out/__chunks__/chunk-DZ2BIDRW.mjs.map +7 -0
  31. package/out/__chunks__/chunk-EAH7XGM3.mjs +2 -0
  32. package/out/__chunks__/chunk-EAH7XGM3.mjs.map +7 -0
  33. package/out/__chunks__/{chunk-6PDGQGIS.mjs → chunk-EEWLVNMR.mjs} +2 -2
  34. package/out/__chunks__/{chunk-AXCK3KRV.mjs → chunk-END5ZJQH.mjs} +2 -2
  35. package/out/__chunks__/{chunk-I4HR64FU.mjs → chunk-F4RI663J.mjs} +2 -2
  36. package/out/__chunks__/{chunk-Y7QM3LPW.mjs → chunk-GVTM4RFC.mjs} +2 -2
  37. package/out/__chunks__/{chunk-YFXATY46.mjs → chunk-H3DYNUJU.mjs} +2 -2
  38. package/out/__chunks__/{chunk-BGUYSNNW.mjs → chunk-IBM2AHR2.mjs} +2 -2
  39. package/out/__chunks__/{chunk-FVFVOSQ4.mjs → chunk-J2SRCAF3.mjs} +2 -2
  40. package/out/__chunks__/chunk-J5EJIWY3.mjs +2 -0
  41. package/out/__chunks__/{chunk-WJI5FXSZ.mjs → chunk-JNJ4L4QD.mjs} +2 -2
  42. package/out/__chunks__/{chunk-KXUILKL2.mjs → chunk-JNUF7URZ.mjs} +2 -2
  43. package/out/__chunks__/chunk-JQDWP4DW.mjs +2 -0
  44. package/out/__chunks__/{chunk-S5YFFC7A.mjs → chunk-JW2RVDMU.mjs} +2 -2
  45. package/out/__chunks__/chunk-KIOUFP5Q.mjs +1 -0
  46. package/out/__chunks__/{chunk-CAAMS3C5.mjs → chunk-KIQFGAFN.mjs} +2 -2
  47. package/out/__chunks__/{chunk-5AZZG5KG.mjs → chunk-KJCSIEAC.mjs} +2 -2
  48. package/out/__chunks__/{chunk-4AUL3FHT.mjs → chunk-LC3EPABR.mjs} +2 -2
  49. package/out/__chunks__/{chunk-NZWPA245.mjs → chunk-MUMHVEIZ.mjs} +2 -2
  50. package/out/__chunks__/{chunk-LQ6WESDL.mjs → chunk-MZEDBAQE.mjs} +2 -2
  51. package/out/__chunks__/chunk-N342XMFH.mjs +6 -0
  52. package/out/__chunks__/chunk-N342XMFH.mjs.map +7 -0
  53. package/out/__chunks__/{chunk-PHMJQ5FC.mjs → chunk-NA5CDQ5C.mjs} +2 -2
  54. package/out/__chunks__/chunk-NJSC7RC2.mjs +2 -0
  55. package/out/__chunks__/chunk-OE5E647N.mjs +2 -0
  56. package/out/__chunks__/chunk-OFSHYRXC.mjs +2 -0
  57. package/out/__chunks__/chunk-OL6LWUIJ.mjs +1 -0
  58. package/out/__chunks__/chunk-OL6LWUIJ.mjs.map +7 -0
  59. package/out/__chunks__/chunk-OOVV574D.mjs +2 -0
  60. package/out/__chunks__/chunk-OOVV574D.mjs.map +7 -0
  61. package/out/__chunks__/{chunk-2HKAVY3C.mjs → chunk-PBMO4Y47.mjs} +2 -2
  62. package/out/__chunks__/{chunk-BQP6NPQM.mjs → chunk-PETVWH5Z.mjs} +2 -2
  63. package/out/__chunks__/{chunk-OCGNA44K.mjs → chunk-PIBYPDMV.mjs} +2 -2
  64. package/out/__chunks__/chunk-PLMCHSS6.mjs +2 -0
  65. package/out/__chunks__/chunk-PLMCHSS6.mjs.map +7 -0
  66. package/out/__chunks__/{chunk-DG77T3NS.mjs → chunk-PWXUYZF5.mjs} +2 -2
  67. package/out/__chunks__/{chunk-PO3ODHJ7.mjs → chunk-Q62OP5VI.mjs} +2 -2
  68. package/out/__chunks__/{chunk-Z63LDNZJ.mjs → chunk-QEU6LCSD.mjs} +2 -2
  69. package/out/__chunks__/{chunk-O24MRZB2.mjs → chunk-QGTHGE7E.mjs} +2 -2
  70. package/out/__chunks__/{chunk-XNIJIKGB.mjs → chunk-QLEOO5UN.mjs} +2 -2
  71. package/out/__chunks__/{chunk-BNBD3WVN.mjs → chunk-RBJ3O63I.mjs} +2 -2
  72. package/out/__chunks__/chunk-RN2VZOXB.mjs +2 -0
  73. package/out/__chunks__/{chunk-KP4MUQKU.mjs → chunk-S2HQMNW6.mjs} +2 -2
  74. package/out/__chunks__/{chunk-27OTZWDO.mjs → chunk-SYNNW6IN.mjs} +2 -2
  75. package/out/__chunks__/{chunk-STVYY4LI.mjs → chunk-SZ3AWPZH.mjs} +2 -2
  76. package/out/__chunks__/{chunk-XUADWD55.mjs → chunk-T2BVHJVW.mjs} +2 -2
  77. package/out/__chunks__/chunk-T3JST5WU.mjs +2 -0
  78. package/out/__chunks__/chunk-T3JST5WU.mjs.map +7 -0
  79. package/out/__chunks__/chunk-TFZ46GCB.mjs +1 -0
  80. package/out/__chunks__/chunk-TFZ46GCB.mjs.map +7 -0
  81. package/out/__chunks__/{chunk-72D44IHE.mjs → chunk-TJYR4CV6.mjs} +2 -2
  82. package/out/__chunks__/{chunk-GSRRAPL5.mjs → chunk-TSK44JFJ.mjs} +2 -2
  83. package/out/__chunks__/{chunk-N6QD4PLA.mjs → chunk-TURUYZA7.mjs} +2 -2
  84. package/out/__chunks__/chunk-U6OAEGT3.mjs +2 -0
  85. package/out/__chunks__/{chunk-ARAO6B2F.mjs → chunk-UGUQSBY5.mjs} +2 -2
  86. package/out/__chunks__/{chunk-DNFWIYZH.mjs → chunk-UNBTFF6K.mjs} +2 -2
  87. package/out/__chunks__/{chunk-TMMUB3IK.mjs → chunk-VQ4GD4WE.mjs} +2 -2
  88. package/out/__chunks__/{chunk-OP2PPPAN.mjs → chunk-VX6FOSXG.mjs} +2 -2
  89. package/out/__chunks__/{chunk-KAQ5IXKK.mjs → chunk-W6P2TQ3N.mjs} +2 -2
  90. package/out/__chunks__/{chunk-E5CUE265.mjs → chunk-WC4UR2ZF.mjs} +2 -2
  91. package/out/__chunks__/chunk-WJQVMI33.mjs +2 -0
  92. package/out/__chunks__/chunk-WJQVMI33.mjs.map +7 -0
  93. package/out/__chunks__/chunk-WJTCBV34.mjs +2 -0
  94. package/out/__chunks__/{chunk-6BF62TP4.mjs → chunk-WJXCNHT3.mjs} +2 -2
  95. package/out/__chunks__/chunk-XDYKH6G4.mjs +2 -0
  96. package/out/__chunks__/{chunk-KX5J6EMC.mjs.map → chunk-XDYKH6G4.mjs.map} +1 -1
  97. package/out/__chunks__/chunk-XFP6N66W.mjs +2 -0
  98. package/out/__chunks__/{chunk-CYEMHPEX.mjs → chunk-XHRRQNPV.mjs} +2 -2
  99. package/out/__chunks__/{chunk-DCX2NQAU.mjs → chunk-XIDZCWKE.mjs} +2 -2
  100. package/out/__chunks__/chunk-XIQFXEMO.mjs +2 -0
  101. package/out/__chunks__/{chunk-2SVWHJC4.mjs → chunk-XJQ4VZS2.mjs} +2 -2
  102. package/out/__chunks__/{chunk-JV7AJLRI.mjs → chunk-XQUUCE53.mjs} +2 -2
  103. package/out/__chunks__/{chunk-FFHHIKMI.mjs → chunk-Y7BUJTYP.mjs} +2 -2
  104. package/out/__chunks__/{chunk-H4DISFAI.mjs → chunk-YCSATFGK.mjs} +2 -2
  105. package/out/__chunks__/chunk-YJFGRD5R.mjs +2 -0
  106. package/out/__chunks__/chunk-YJIAAC7S.mjs +2 -0
  107. package/out/__chunks__/{chunk-XHKNB4IP.mjs → chunk-YY724VZR.mjs} +2 -2
  108. package/out/__chunks__/{chunk-4XIT3N7Y.mjs → chunk-ZDCPV3O4.mjs} +2 -2
  109. package/out/__chunks__/{chunk-UJUAT5NK.mjs → chunk-ZEQI7SII.mjs} +2 -2
  110. package/out/__chunks__/{chunk-PAAJPYAE.mjs → chunk-ZKAIQNIL.mjs} +2 -2
  111. package/out/__chunks__/{chunk-IR743HKQ.mjs → chunk-ZMLJXSO5.mjs} +2 -2
  112. package/out/__chunks__/{chunk-HOJ7JMTW.mjs → chunk-ZP44CDGG.mjs} +2 -2
  113. package/out/__chunks__/chunk-ZQOG6A2Z.mjs +2 -0
  114. package/out/__chunks__/{chunk-S53SAYHR.mjs → chunk-ZQOIMST2.mjs} +2 -2
  115. package/out/__mocks__/accountConfig.mjs +1 -1
  116. package/out/__mocks__/data/index.mjs +1 -1
  117. package/out/__mocks__/index.mjs +1 -1
  118. package/out/__mocks__/server.mjs +1 -1
  119. package/out/__mocks__/utils/index.mjs +1 -1
  120. package/out/apiCalls/account/getScamAddressData.mjs +1 -1
  121. package/out/apiCalls/configuration/getCleanApiAddress.mjs +1 -1
  122. package/out/apiCalls/configuration/getGasStationMetadata.mjs +1 -1
  123. package/out/apiCalls/index.mjs +1 -1
  124. package/out/apiCalls/tokens/getPersistedTokenDetails.mjs +1 -1
  125. package/out/apiCalls/tokens/getTokenDetails.mjs +1 -1
  126. package/out/apiCalls/tokens/index.mjs +1 -1
  127. package/out/apiCalls/transactions/getServerTransactionsByHashes.mjs +1 -1
  128. package/out/apiCalls/transactions/getTransactionByHash.mjs +1 -1
  129. package/out/apiCalls/transactions/getTransactionsByHashes.mjs +1 -1
  130. package/out/constants/browser.constants.mjs +1 -1
  131. package/out/constants/index.mjs +1 -1
  132. package/out/constants/storage.constants.mjs +1 -1
  133. package/out/constants/transactions.constants.cjs +3 -0
  134. package/out/constants/transactions.constants.cjs.map +2 -2
  135. package/out/constants/transactions.constants.d.ts +1 -0
  136. package/out/constants/transactions.constants.mjs +1 -1
  137. package/out/constants/window.constants.cjs +1 -1
  138. package/out/constants/window.constants.cjs.map +1 -1
  139. package/out/constants/window.constants.mjs +1 -1
  140. package/out/controllers/TransactionsHistoryController/TransactionsHistoryController.mjs +1 -1
  141. package/out/controllers/TransactionsHistoryController/index.mjs +1 -1
  142. package/out/controllers/TransactionsTableController/TransactionsTableController.mjs +1 -1
  143. package/out/controllers/TransactionsTableController/index.mjs +1 -1
  144. package/out/index.mjs +1 -1
  145. package/out/lib/sdkDappUi.mjs +1 -1
  146. package/out/managers/LogoutManager/LogoutManager.mjs +1 -1
  147. package/out/managers/NotificationsFeedManager/NotificationsFeedManager.mjs +1 -1
  148. package/out/managers/NotificationsFeedManager/index.mjs +1 -1
  149. package/out/managers/TransactionManager/TransactionManager.mjs +1 -1
  150. package/out/managers/TransactionManager/helpers/getAreTransactionsCorssShards.mjs +1 -1
  151. package/out/managers/TransactionManager/helpers/getToastDuration.mjs +1 -1
  152. package/out/managers/TransactionManager/helpers/getTransactionsStatus.mjs +1 -1
  153. package/out/managers/TransactionManager/index.mjs +1 -1
  154. package/out/managers/UnlockPanelManager/UnlockPanelManager.mjs +1 -1
  155. package/out/managers/UnlockPanelManager/index.mjs +1 -1
  156. package/out/managers/index.mjs +1 -1
  157. package/out/managers/internal/LedgerConnectStateManager/LedgerConnectStateManager.mjs +1 -1
  158. package/out/managers/internal/LedgerConnectStateManager/index.mjs +1 -1
  159. package/out/managers/internal/LedgerIdleStateManager/LedgerIdleStateManager.mjs +1 -1
  160. package/out/managers/internal/PendingTransactionsStateManager/PendingTransactionsStateManager.mjs +1 -1
  161. package/out/managers/internal/PendingTransactionsStateManager/index.mjs +1 -1
  162. package/out/managers/internal/SidePanelBaseManager/SidePanelBaseManager.mjs +1 -1
  163. package/out/managers/internal/SidePanelBaseManager/index.mjs +1 -1
  164. package/out/managers/internal/SignTransactionsStateManager/SignTransactionsStateManager.mjs +1 -1
  165. package/out/managers/internal/SignTransactionsStateManager/index.mjs +1 -1
  166. package/out/managers/internal/ToastManager/ToastManager.cjs +3 -6
  167. package/out/managers/internal/ToastManager/ToastManager.cjs.map +2 -2
  168. package/out/managers/internal/ToastManager/ToastManager.d.ts +1 -1
  169. package/out/managers/internal/ToastManager/ToastManager.mjs +1 -1
  170. package/out/managers/internal/ToastManager/helpers/LifetimeManager.mjs +1 -1
  171. package/out/managers/internal/ToastManager/helpers/createToastsFromTransactions.mjs +1 -1
  172. package/out/managers/internal/ToastManager/helpers/createTransactionToast.mjs +1 -1
  173. package/out/managers/internal/ToastManager/helpers/getToastDataStateByStatus.mjs +1 -1
  174. package/out/managers/internal/UIBaseManager/UIBaseManager.mjs +1 -1
  175. package/out/managers/internal/WalletConnectStateManager/WalletConnectStateManager.mjs +1 -1
  176. package/out/managers/internal/WalletConnectStateManager/index.mjs +1 -1
  177. package/out/managers/internal/index.mjs +1 -1
  178. package/out/methods/account/getAccount.mjs +1 -1
  179. package/out/methods/account/getAccountInfo.mjs +1 -1
  180. package/out/methods/account/getAddress.mjs +1 -1
  181. package/out/methods/account/getIsLoggedIn.mjs +1 -1
  182. package/out/methods/account/getLatestNonce.mjs +1 -1
  183. package/out/methods/initApp/gastStationMetadata/setGasStationMetadata.mjs +1 -1
  184. package/out/methods/initApp/initApp.mjs +1 -1
  185. package/out/methods/initApp/initApp.mjs.map +1 -1
  186. package/out/methods/initApp/websocket/initializeWebsocketConnection.mjs +1 -1
  187. package/out/methods/initApp/websocket/registerWebsocket.mjs +1 -1
  188. package/out/methods/loginInfo/getLoginInfo.mjs +1 -1
  189. package/out/methods/network/getEgldLabel.mjs +1 -1
  190. package/out/methods/network/getExplorerAddress.mjs +1 -1
  191. package/out/methods/network/getNetworkConfig.mjs +1 -1
  192. package/out/methods/trackTransactions/helpers/checkTransactionStatus/checkBatch.mjs +1 -1
  193. package/out/methods/trackTransactions/helpers/checkTransactionStatus/checkTransactionStatus.mjs +1 -1
  194. package/out/methods/trackTransactions/helpers/checkTransactionStatus/index.mjs +1 -1
  195. package/out/methods/trackTransactions/helpers/checkTransactionStatus/manageFailedTransactions.mjs +1 -1
  196. package/out/methods/trackTransactions/helpers/getPollingInterval.mjs +1 -1
  197. package/out/methods/trackTransactions/trackTransactions.mjs +1 -1
  198. package/out/methods/transactions/getFailedTransactions.mjs +1 -1
  199. package/out/methods/transactions/getFailedTransactionsSessions.mjs +1 -1
  200. package/out/methods/transactions/getPendingTransactions.mjs +1 -1
  201. package/out/methods/transactions/getPendingTransactionsSessions.mjs +1 -1
  202. package/out/methods/transactions/getSuccessfulTransactions.mjs +1 -1
  203. package/out/methods/transactions/getSuccessfulTransactionsSessions.mjs +1 -1
  204. package/out/methods/transactions/getTransactionSessions.mjs +1 -1
  205. package/out/providers/DappProvider/DappProvider.mjs +1 -1
  206. package/out/providers/DappProvider/helpers/login/helpers/accountLogin.mjs +1 -1
  207. package/out/providers/DappProvider/helpers/login/helpers/extractAddressFromToken.mjs +1 -1
  208. package/out/providers/DappProvider/helpers/login/helpers/getAccountFromToken.mjs +1 -1
  209. package/out/providers/DappProvider/helpers/login/helpers/getModifiedLoginToken.mjs +1 -1
  210. package/out/providers/DappProvider/helpers/login/login.mjs +1 -1
  211. package/out/providers/DappProvider/helpers/logout/logout.mjs +1 -1
  212. package/out/providers/DappProvider/helpers/signErrors/handleSignError.mjs +1 -1
  213. package/out/providers/DappProvider/helpers/signMessage/signMessageWithProvider.mjs +1 -1
  214. package/out/providers/DappProvider/helpers/signTransactions/signTransactionsWithProvider.mjs +1 -1
  215. package/out/providers/DappProvider/index.mjs +1 -1
  216. package/out/providers/ProviderFactory.mjs +1 -1
  217. package/out/providers/helpers/accountProvider.mjs +1 -1
  218. package/out/providers/helpers/cancelCrossWindowAction.mjs +1 -1
  219. package/out/providers/helpers/restoreProvider.mjs +1 -1
  220. package/out/providers/index.mjs +1 -1
  221. package/out/providers/strategies/BaseProviderStrategy/BaseProviderStrategy.mjs +1 -1
  222. package/out/providers/strategies/CrossWindowProviderStrategy/CrossWindowProviderStrategy.mjs +1 -1
  223. package/out/providers/strategies/CrossWindowProviderStrategy/index.mjs +1 -1
  224. package/out/providers/strategies/ExtensionProviderStrategy/ExtensionProviderStrategy.mjs +1 -1
  225. package/out/providers/strategies/ExtensionProviderStrategy/index.mjs +1 -1
  226. package/out/providers/strategies/IframeProviderStrategy/IframeProviderStrategy.mjs +1 -1
  227. package/out/providers/strategies/IframeProviderStrategy/index.mjs +1 -1
  228. package/out/providers/strategies/LedgerProviderStrategy/LedgerProviderStrategy.mjs +1 -1
  229. package/out/providers/strategies/LedgerProviderStrategy/helpers/authenticateLedgerAccount.mjs +1 -1
  230. package/out/providers/strategies/LedgerProviderStrategy/helpers/getAuthTokenText.mjs +1 -1
  231. package/out/providers/strategies/LedgerProviderStrategy/helpers/getLedgerConfiguration.mjs +1 -1
  232. package/out/providers/strategies/LedgerProviderStrategy/helpers/getLedgerProvider.mjs +1 -1
  233. package/out/providers/strategies/LedgerProviderStrategy/helpers/getLedgerVersionOptions.mjs +1 -1
  234. package/out/providers/strategies/LedgerProviderStrategy/helpers/index.mjs +1 -1
  235. package/out/providers/strategies/LedgerProviderStrategy/helpers/initializeLedgerProvider.mjs +1 -1
  236. package/out/providers/strategies/LedgerProviderStrategy/helpers/signLedgerMessage.mjs +1 -1
  237. package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/index.mjs +1 -1
  238. package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/updateAccountsList.mjs +1 -1
  239. package/out/providers/strategies/LedgerProviderStrategy/index.mjs +1 -1
  240. package/out/providers/strategies/WalletConnectProviderStrategy/WalletConnectProviderStrategy.mjs +1 -1
  241. package/out/providers/strategies/WalletConnectProviderStrategy/index.mjs +1 -1
  242. package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/WebviewClient.mjs +1 -1
  243. package/out/providers/strategies/WebviewProviderStrategy/WebviewClient/index.mjs +1 -1
  244. package/out/providers/strategies/WebviewProviderStrategy/WebviewProviderStrategy.mjs +1 -1
  245. package/out/providers/strategies/WebviewProviderStrategy/index.mjs +1 -1
  246. package/out/providers/strategies/helpers/getPendingTransactionsHandlers.mjs +1 -1
  247. package/out/providers/strategies/helpers/index.mjs +1 -1
  248. package/out/providers/strategies/helpers/signMessage/signMessage.mjs +1 -1
  249. package/out/providers/strategies/helpers/signTransactions/helpers/calculateFeeLimit.mjs +1 -1
  250. package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/getCommonData.mjs +1 -1
  251. package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/decodeDataField.cjs +2 -221
  252. package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/decodeDataField.cjs.map +3 -3
  253. package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/decodeDataField.mjs +1 -1
  254. package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/getExtractTransactionsInfo.mjs +1 -1
  255. package/out/providers/strategies/helpers/signTransactions/helpers/getFeeData.mjs +1 -1
  256. package/out/providers/strategies/helpers/signTransactions/helpers/getMultiEsdtTransferData/getMultiEsdtTransferData.mjs +1 -1
  257. package/out/providers/strategies/helpers/signTransactions/helpers/getMultiEsdtTransferData/helpers/getTokenFromData.mjs +1 -1
  258. package/out/providers/strategies/helpers/signTransactions/helpers/getMultiEsdtTransferData/helpers/parseMultiEsdtTransferDataForMultipleTransactions.mjs +1 -1
  259. package/out/providers/strategies/helpers/signTransactions/helpers/guardTransactions/guardTransactions.mjs +1 -1
  260. package/out/providers/strategies/helpers/signTransactions/signTransactions.mjs +1 -1
  261. package/out/providers/strategies/index.mjs +1 -1
  262. package/out/react/account/useGetAccount.mjs +1 -1
  263. package/out/react/account/useGetAccountInfo.mjs +1 -1
  264. package/out/react/account/useGetIsLoggedIn.mjs +1 -1
  265. package/out/react/account/useGetLatestNonce.mjs +1 -1
  266. package/out/react/index.mjs +1 -1
  267. package/out/react/loginInfo/useGetLoginInfo.mjs +1 -1
  268. package/out/react/network/useGetNetworkConfig.mjs +1 -1
  269. package/out/react/store/getReactStore.mjs +1 -1
  270. package/out/react/store/useSelector.mjs +1 -1
  271. package/out/react/transactions/useGetFailedTransactions.mjs +1 -1
  272. package/out/react/transactions/useGetFailedTransactionsSessions.mjs +1 -1
  273. package/out/react/transactions/useGetPendingTransactions.mjs +1 -1
  274. package/out/react/transactions/useGetPendingTransactionsSessions.mjs +1 -1
  275. package/out/react/transactions/useGetSuccessfulTransactions.mjs +1 -1
  276. package/out/react/transactions/useGetSuccessfulTransactionsSessions.mjs +1 -1
  277. package/out/react/transactions/useGetTransactionSessions.mjs +1 -1
  278. package/out/services/index.mjs +1 -1
  279. package/out/services/nativeAuth/index.mjs +1 -1
  280. package/out/services/nativeAuth/methods/buildNativeAuthConfig.mjs +1 -1
  281. package/out/services/nativeAuth/methods/getDefaultNativeAuthConfig.mjs +1 -1
  282. package/out/services/nativeAuth/methods/index.mjs +1 -1
  283. package/out/services/nativeAuth/nativeAuth.mjs +1 -1
  284. package/out/store/actions/account/accountActions.mjs +1 -1
  285. package/out/store/actions/account/index.mjs +1 -1
  286. package/out/store/actions/cache/cacheActions.mjs +1 -1
  287. package/out/store/actions/cache/index.mjs +1 -1
  288. package/out/store/actions/config/configActions.mjs +1 -1
  289. package/out/store/actions/config/index.mjs +1 -1
  290. package/out/store/actions/index.mjs +1 -1
  291. package/out/store/actions/loginInfo/loginInfoActions.mjs +1 -1
  292. package/out/store/actions/network/index.mjs +1 -1
  293. package/out/store/actions/network/initializeNetwork.mjs +1 -1
  294. package/out/store/actions/network/networkActions.mjs +1 -1
  295. package/out/store/actions/sharedActions/index.mjs +1 -1
  296. package/out/store/actions/sharedActions/sharedActions.mjs +1 -1
  297. package/out/store/actions/toasts/index.mjs +1 -1
  298. package/out/store/actions/toasts/toastsActions.mjs +1 -1
  299. package/out/store/actions/transactions/transactionsActions.mjs +1 -1
  300. package/out/store/actions/ui/index.mjs +1 -1
  301. package/out/store/actions/ui/uiActions.mjs +1 -1
  302. package/out/store/middleware/applyMiddlewares.mjs +1 -1
  303. package/out/store/middleware/index.mjs +1 -1
  304. package/out/store/middleware/logoutMiddleware.mjs +1 -1
  305. package/out/store/selectors/index.mjs +1 -1
  306. package/out/store/storage/index.mjs +1 -1
  307. package/out/store/storage/storageCallback.mjs +1 -1
  308. package/out/store/store.mjs +1 -1
  309. package/out/types/index.mjs +1 -1
  310. package/out/utils/ComponentFactory.mjs +1 -1
  311. package/out/utils/account/index.mjs +1 -1
  312. package/out/utils/account/refreshAccount.mjs +1 -1
  313. package/out/utils/account/refreshNativeAuthTokenLogin.mjs +1 -1
  314. package/out/utils/dateTime/index.mjs +1 -1
  315. package/out/utils/index.mjs +1 -1
  316. package/out/utils/transactions/getActiveTransactionsStatus.mjs +1 -1
  317. package/out/utils/transactions/getDecodedDataField/getDecodedDataField.cjs +111 -0
  318. package/out/utils/transactions/getDecodedDataField/getDecodedDataField.cjs.map +7 -0
  319. package/out/utils/transactions/getDecodedDataField/getDecodedDataField.d.ts +9 -0
  320. package/out/utils/transactions/getDecodedDataField/getDecodedDataField.mjs +2 -0
  321. package/out/utils/transactions/getDecodedDataField/getDecodedDataField.mjs.map +7 -0
  322. package/out/utils/transactions/getDecodedDataField/helpers/decodeByMethod.cjs +90 -0
  323. package/out/utils/transactions/getDecodedDataField/helpers/decodeByMethod.cjs.map +7 -0
  324. package/out/utils/transactions/getDecodedDataField/helpers/decodeByMethod.d.ts +8 -0
  325. package/out/utils/transactions/getDecodedDataField/helpers/decodeByMethod.mjs +2 -0
  326. package/out/utils/transactions/getDecodedDataField/helpers/decodeByMethod.mjs.map +7 -0
  327. package/out/utils/transactions/getDecodedDataField/helpers/decodeHighlight.cjs +48 -0
  328. package/out/utils/transactions/getDecodedDataField/helpers/decodeHighlight.cjs.map +7 -0
  329. package/out/utils/transactions/getDecodedDataField/helpers/decodeHighlight.d.ts +9 -0
  330. package/out/utils/transactions/getDecodedDataField/helpers/decodeHighlight.mjs +2 -0
  331. package/out/utils/transactions/getDecodedDataField/helpers/decodeHighlight.mjs.map +7 -0
  332. package/out/utils/transactions/getDecodedDataField/helpers/getDecodedParts.cjs +45 -0
  333. package/out/utils/transactions/getDecodedDataField/helpers/getDecodedParts.cjs.map +7 -0
  334. package/out/utils/transactions/getDecodedDataField/helpers/getDecodedParts.d.ts +9 -0
  335. package/out/utils/transactions/getDecodedDataField/helpers/getDecodedParts.mjs +2 -0
  336. package/out/utils/transactions/getDecodedDataField/helpers/getDecodedParts.mjs.map +7 -0
  337. package/out/utils/transactions/getDecodedDataField/helpers/getDisplayValueAndValidationWarnings.cjs +61 -0
  338. package/out/utils/transactions/getDecodedDataField/helpers/getDisplayValueAndValidationWarnings.cjs.map +7 -0
  339. package/out/utils/transactions/getDecodedDataField/helpers/getDisplayValueAndValidationWarnings.d.ts +9 -0
  340. package/out/utils/transactions/getDecodedDataField/helpers/getDisplayValueAndValidationWarnings.mjs +2 -0
  341. package/out/utils/transactions/getDecodedDataField/helpers/getDisplayValueAndValidationWarnings.mjs.map +7 -0
  342. package/out/utils/transactions/getDecodedDataField/helpers/getHexValidationWarnings.cjs +39 -0
  343. package/out/utils/transactions/getDecodedDataField/helpers/getHexValidationWarnings.cjs.map +7 -0
  344. package/out/utils/transactions/getDecodedDataField/helpers/getHexValidationWarnings.d.ts +1 -0
  345. package/out/utils/transactions/getDecodedDataField/helpers/getHexValidationWarnings.mjs +2 -0
  346. package/out/utils/transactions/getDecodedDataField/helpers/getHexValidationWarnings.mjs.map +7 -0
  347. package/out/utils/transactions/getDecodedDataField/helpers/getSmartDecodedParts.cjs +52 -0
  348. package/out/utils/transactions/getDecodedDataField/helpers/getSmartDecodedParts.cjs.map +7 -0
  349. package/out/utils/transactions/getDecodedDataField/helpers/getSmartDecodedParts.d.ts +7 -0
  350. package/out/utils/transactions/getDecodedDataField/helpers/getSmartDecodedParts.mjs +2 -0
  351. package/out/utils/transactions/getDecodedDataField/helpers/getSmartDecodedParts.mjs.map +7 -0
  352. package/out/utils/transactions/getDecodedDataField/helpers/index.cjs +33 -0
  353. package/out/utils/transactions/getDecodedDataField/helpers/index.cjs.map +7 -0
  354. package/out/utils/transactions/getDecodedDataField/helpers/index.d.ts +6 -0
  355. package/out/utils/transactions/getDecodedDataField/helpers/index.mjs +2 -0
  356. package/out/utils/transactions/getDecodedDataField/helpers/index.mjs.map +7 -0
  357. package/out/utils/transactions/getDecodedDataField/index.cjs +25 -0
  358. package/out/utils/transactions/getDecodedDataField/index.cjs.map +7 -0
  359. package/out/utils/transactions/getDecodedDataField/index.d.ts +2 -0
  360. package/out/utils/transactions/getDecodedDataField/index.mjs +2 -0
  361. package/out/utils/transactions/getDecodedDataField/index.mjs.map +7 -0
  362. package/out/utils/transactions/getInterpretedTransaction/getInterpretedTransaction.mjs +1 -1
  363. package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/getTransactionValue.mjs +1 -1
  364. package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/helpers/index.mjs +1 -1
  365. package/out/utils/transactions/getInterpretedTransaction/getTransactionValue/index.mjs +1 -1
  366. package/out/utils/transactions/getInterpretedTransaction/helpers/getLockedAccountName.mjs +1 -1
  367. package/out/utils/transactions/getInterpretedTransaction/helpers/getReceiptMessage.mjs +1 -1
  368. package/out/utils/transactions/getInterpretedTransaction/helpers/getShardText.mjs +1 -1
  369. package/out/utils/transactions/getInterpretedTransaction/helpers/getTokenFromData.mjs +1 -1
  370. package/out/utils/transactions/getInterpretedTransaction/helpers/getTransactionIconInfo.mjs +1 -1
  371. package/out/utils/transactions/getInterpretedTransaction/helpers/getTransactionMessages.mjs +1 -1
  372. package/out/utils/transactions/getInterpretedTransaction/helpers/index.mjs +1 -1
  373. package/out/utils/transactions/getInterpretedTransaction/index.mjs +1 -1
  374. package/out/utils/transactions/getTransactionsHistory/getTransactionsHistory.mjs +1 -1
  375. package/out/utils/transactions/getTransactionsHistory/helpers/getCachedTransactionListItem.mjs +1 -1
  376. package/out/utils/transactions/getTransactionsHistory/helpers/getTransactionAsset.mjs +1 -1
  377. package/out/utils/transactions/getTransactionsHistory/helpers/index.mjs +1 -1
  378. package/out/utils/transactions/getTransactionsHistory/helpers/mapServerTransactionsToListItems.mjs +1 -1
  379. package/out/utils/transactions/getTransactionsHistory/helpers/mapTransactionToListItem.mjs +1 -1
  380. package/out/utils/transactions/getTransactionsHistory/index.mjs +1 -1
  381. package/out/utils/transactions/index.cjs +2 -0
  382. package/out/utils/transactions/index.cjs.map +2 -2
  383. package/out/utils/transactions/index.d.ts +1 -0
  384. package/out/utils/transactions/index.mjs +1 -1
  385. package/out/utils/validation/index.mjs +1 -1
  386. package/out/utils/validation/isContract.mjs +1 -1
  387. package/out/utils/visual/index.mjs +1 -1
  388. package/out/utils/visual/switchTheme.mjs +1 -1
  389. package/out/utils/window/getIsInIframe.mjs +1 -1
  390. package/out/utils/window/getWindowParentOrigin.mjs +1 -1
  391. package/out/utils/window/index.mjs +1 -1
  392. package/package.json +1 -1
  393. package/out/__chunks__/chunk-3NQTC6AZ.mjs +0 -2
  394. package/out/__chunks__/chunk-4EMQSUU6.mjs +0 -2
  395. package/out/__chunks__/chunk-5JYD7XMI.mjs +0 -2
  396. package/out/__chunks__/chunk-6CQMLD25.mjs +0 -1
  397. package/out/__chunks__/chunk-BETSOJFK.mjs +0 -6
  398. package/out/__chunks__/chunk-BETSOJFK.mjs.map +0 -7
  399. package/out/__chunks__/chunk-CAA4VJRH.mjs +0 -2
  400. package/out/__chunks__/chunk-IRBGQJE4.mjs +0 -2
  401. package/out/__chunks__/chunk-J64N3RXX.mjs +0 -2
  402. package/out/__chunks__/chunk-JN5CTLWW.mjs +0 -2
  403. package/out/__chunks__/chunk-KK25BEMY.mjs +0 -2
  404. package/out/__chunks__/chunk-KX5J6EMC.mjs +0 -2
  405. package/out/__chunks__/chunk-LTRQRVWX.mjs +0 -2
  406. package/out/__chunks__/chunk-LY3MRREN.mjs +0 -2
  407. package/out/__chunks__/chunk-LY3MRREN.mjs.map +0 -7
  408. package/out/__chunks__/chunk-MGHFXYZ5.mjs +0 -2
  409. package/out/__chunks__/chunk-MK36TMYT.mjs +0 -2
  410. package/out/__chunks__/chunk-OF3XH6ZU.mjs +0 -2
  411. package/out/__chunks__/chunk-QQEQNSRI.mjs +0 -2
  412. package/out/__chunks__/chunk-SGQJOLH2.mjs +0 -2
  413. package/out/__chunks__/chunk-TMOMM4JN.mjs +0 -2
  414. package/out/__chunks__/chunk-XUI3Z5NN.mjs +0 -2
  415. package/out/__chunks__/chunk-YVLFUMPH.mjs +0 -2
  416. /package/out/__chunks__/{chunk-ZS4EBCWC.mjs.map → chunk-2GG67TZD.mjs.map} +0 -0
  417. /package/out/__chunks__/{chunk-YD2O3NV7.mjs.map → chunk-2KE2BNG7.mjs.map} +0 -0
  418. /package/out/__chunks__/{chunk-2L25IGHZ.mjs.map → chunk-2KPILBQ2.mjs.map} +0 -0
  419. /package/out/__chunks__/{chunk-IRBGQJE4.mjs.map → chunk-3JHE6RJX.mjs.map} +0 -0
  420. /package/out/__chunks__/{chunk-2DUVXRMU.mjs.map → chunk-3MJNBS6H.mjs.map} +0 -0
  421. /package/out/__chunks__/{chunk-7VNNDJ7P.mjs.map → chunk-463K27BJ.mjs.map} +0 -0
  422. /package/out/__chunks__/{chunk-7ONKP4ZG.mjs.map → chunk-4AGZHXFR.mjs.map} +0 -0
  423. /package/out/__chunks__/{chunk-I6WJ63GD.mjs.map → chunk-4N34K4EN.mjs.map} +0 -0
  424. /package/out/__chunks__/{chunk-IZ4B4B35.mjs.map → chunk-4PILLRHM.mjs.map} +0 -0
  425. /package/out/__chunks__/{chunk-54XYKDH7.mjs.map → chunk-555CAG7Y.mjs.map} +0 -0
  426. /package/out/__chunks__/{chunk-2ONA7QPD.mjs.map → chunk-5DP2QBUG.mjs.map} +0 -0
  427. /package/out/__chunks__/{chunk-5KVNYLOM.mjs.map → chunk-6DWUEZO7.mjs.map} +0 -0
  428. /package/out/__chunks__/{chunk-IWROXIQ5.mjs.map → chunk-6V76WUHS.mjs.map} +0 -0
  429. /package/out/__chunks__/{chunk-VRG2R5C7.mjs.map → chunk-76A63VDO.mjs.map} +0 -0
  430. /package/out/__chunks__/{chunk-UXYMY3HG.mjs.map → chunk-7HNMIUES.mjs.map} +0 -0
  431. /package/out/__chunks__/{chunk-3CKDOF3O.mjs.map → chunk-A3CEGIRB.mjs.map} +0 -0
  432. /package/out/__chunks__/{chunk-5JYD7XMI.mjs.map → chunk-AIKQPMR3.mjs.map} +0 -0
  433. /package/out/__chunks__/{chunk-LPGMDX6Q.mjs.map → chunk-AYURCZHZ.mjs.map} +0 -0
  434. /package/out/__chunks__/{chunk-DJ2HTZOV.mjs.map → chunk-BUHHNIJJ.mjs.map} +0 -0
  435. /package/out/__chunks__/{chunk-RNSBN5JT.mjs.map → chunk-C25AGRYE.mjs.map} +0 -0
  436. /package/out/__chunks__/{chunk-RJOP7SCI.mjs.map → chunk-CIB3ITZR.mjs.map} +0 -0
  437. /package/out/__chunks__/{chunk-LTRQRVWX.mjs.map → chunk-CUS6AHOH.mjs.map} +0 -0
  438. /package/out/__chunks__/{chunk-6PDGQGIS.mjs.map → chunk-EEWLVNMR.mjs.map} +0 -0
  439. /package/out/__chunks__/{chunk-AXCK3KRV.mjs.map → chunk-END5ZJQH.mjs.map} +0 -0
  440. /package/out/__chunks__/{chunk-I4HR64FU.mjs.map → chunk-F4RI663J.mjs.map} +0 -0
  441. /package/out/__chunks__/{chunk-Y7QM3LPW.mjs.map → chunk-GVTM4RFC.mjs.map} +0 -0
  442. /package/out/__chunks__/{chunk-YFXATY46.mjs.map → chunk-H3DYNUJU.mjs.map} +0 -0
  443. /package/out/__chunks__/{chunk-BGUYSNNW.mjs.map → chunk-IBM2AHR2.mjs.map} +0 -0
  444. /package/out/__chunks__/{chunk-FVFVOSQ4.mjs.map → chunk-J2SRCAF3.mjs.map} +0 -0
  445. /package/out/__chunks__/{chunk-J64N3RXX.mjs.map → chunk-J5EJIWY3.mjs.map} +0 -0
  446. /package/out/__chunks__/{chunk-WJI5FXSZ.mjs.map → chunk-JNJ4L4QD.mjs.map} +0 -0
  447. /package/out/__chunks__/{chunk-KXUILKL2.mjs.map → chunk-JNUF7URZ.mjs.map} +0 -0
  448. /package/out/__chunks__/{chunk-MK36TMYT.mjs.map → chunk-JQDWP4DW.mjs.map} +0 -0
  449. /package/out/__chunks__/{chunk-S5YFFC7A.mjs.map → chunk-JW2RVDMU.mjs.map} +0 -0
  450. /package/out/__chunks__/{chunk-6CQMLD25.mjs.map → chunk-KIOUFP5Q.mjs.map} +0 -0
  451. /package/out/__chunks__/{chunk-CAAMS3C5.mjs.map → chunk-KIQFGAFN.mjs.map} +0 -0
  452. /package/out/__chunks__/{chunk-5AZZG5KG.mjs.map → chunk-KJCSIEAC.mjs.map} +0 -0
  453. /package/out/__chunks__/{chunk-4AUL3FHT.mjs.map → chunk-LC3EPABR.mjs.map} +0 -0
  454. /package/out/__chunks__/{chunk-NZWPA245.mjs.map → chunk-MUMHVEIZ.mjs.map} +0 -0
  455. /package/out/__chunks__/{chunk-LQ6WESDL.mjs.map → chunk-MZEDBAQE.mjs.map} +0 -0
  456. /package/out/__chunks__/{chunk-PHMJQ5FC.mjs.map → chunk-NA5CDQ5C.mjs.map} +0 -0
  457. /package/out/__chunks__/{chunk-XUI3Z5NN.mjs.map → chunk-NJSC7RC2.mjs.map} +0 -0
  458. /package/out/__chunks__/{chunk-MGHFXYZ5.mjs.map → chunk-OE5E647N.mjs.map} +0 -0
  459. /package/out/__chunks__/{chunk-TMOMM4JN.mjs.map → chunk-OFSHYRXC.mjs.map} +0 -0
  460. /package/out/__chunks__/{chunk-2HKAVY3C.mjs.map → chunk-PBMO4Y47.mjs.map} +0 -0
  461. /package/out/__chunks__/{chunk-BQP6NPQM.mjs.map → chunk-PETVWH5Z.mjs.map} +0 -0
  462. /package/out/__chunks__/{chunk-OCGNA44K.mjs.map → chunk-PIBYPDMV.mjs.map} +0 -0
  463. /package/out/__chunks__/{chunk-DG77T3NS.mjs.map → chunk-PWXUYZF5.mjs.map} +0 -0
  464. /package/out/__chunks__/{chunk-PO3ODHJ7.mjs.map → chunk-Q62OP5VI.mjs.map} +0 -0
  465. /package/out/__chunks__/{chunk-Z63LDNZJ.mjs.map → chunk-QEU6LCSD.mjs.map} +0 -0
  466. /package/out/__chunks__/{chunk-O24MRZB2.mjs.map → chunk-QGTHGE7E.mjs.map} +0 -0
  467. /package/out/__chunks__/{chunk-XNIJIKGB.mjs.map → chunk-QLEOO5UN.mjs.map} +0 -0
  468. /package/out/__chunks__/{chunk-BNBD3WVN.mjs.map → chunk-RBJ3O63I.mjs.map} +0 -0
  469. /package/out/__chunks__/{chunk-4EMQSUU6.mjs.map → chunk-RN2VZOXB.mjs.map} +0 -0
  470. /package/out/__chunks__/{chunk-KP4MUQKU.mjs.map → chunk-S2HQMNW6.mjs.map} +0 -0
  471. /package/out/__chunks__/{chunk-27OTZWDO.mjs.map → chunk-SYNNW6IN.mjs.map} +0 -0
  472. /package/out/__chunks__/{chunk-STVYY4LI.mjs.map → chunk-SZ3AWPZH.mjs.map} +0 -0
  473. /package/out/__chunks__/{chunk-XUADWD55.mjs.map → chunk-T2BVHJVW.mjs.map} +0 -0
  474. /package/out/__chunks__/{chunk-72D44IHE.mjs.map → chunk-TJYR4CV6.mjs.map} +0 -0
  475. /package/out/__chunks__/{chunk-GSRRAPL5.mjs.map → chunk-TSK44JFJ.mjs.map} +0 -0
  476. /package/out/__chunks__/{chunk-N6QD4PLA.mjs.map → chunk-TURUYZA7.mjs.map} +0 -0
  477. /package/out/__chunks__/{chunk-3NQTC6AZ.mjs.map → chunk-U6OAEGT3.mjs.map} +0 -0
  478. /package/out/__chunks__/{chunk-ARAO6B2F.mjs.map → chunk-UGUQSBY5.mjs.map} +0 -0
  479. /package/out/__chunks__/{chunk-DNFWIYZH.mjs.map → chunk-UNBTFF6K.mjs.map} +0 -0
  480. /package/out/__chunks__/{chunk-TMMUB3IK.mjs.map → chunk-VQ4GD4WE.mjs.map} +0 -0
  481. /package/out/__chunks__/{chunk-OP2PPPAN.mjs.map → chunk-VX6FOSXG.mjs.map} +0 -0
  482. /package/out/__chunks__/{chunk-KAQ5IXKK.mjs.map → chunk-W6P2TQ3N.mjs.map} +0 -0
  483. /package/out/__chunks__/{chunk-E5CUE265.mjs.map → chunk-WC4UR2ZF.mjs.map} +0 -0
  484. /package/out/__chunks__/{chunk-SGQJOLH2.mjs.map → chunk-WJTCBV34.mjs.map} +0 -0
  485. /package/out/__chunks__/{chunk-6BF62TP4.mjs.map → chunk-WJXCNHT3.mjs.map} +0 -0
  486. /package/out/__chunks__/{chunk-JN5CTLWW.mjs.map → chunk-XFP6N66W.mjs.map} +0 -0
  487. /package/out/__chunks__/{chunk-CYEMHPEX.mjs.map → chunk-XHRRQNPV.mjs.map} +0 -0
  488. /package/out/__chunks__/{chunk-DCX2NQAU.mjs.map → chunk-XIDZCWKE.mjs.map} +0 -0
  489. /package/out/__chunks__/{chunk-QQEQNSRI.mjs.map → chunk-XIQFXEMO.mjs.map} +0 -0
  490. /package/out/__chunks__/{chunk-2SVWHJC4.mjs.map → chunk-XJQ4VZS2.mjs.map} +0 -0
  491. /package/out/__chunks__/{chunk-JV7AJLRI.mjs.map → chunk-XQUUCE53.mjs.map} +0 -0
  492. /package/out/__chunks__/{chunk-FFHHIKMI.mjs.map → chunk-Y7BUJTYP.mjs.map} +0 -0
  493. /package/out/__chunks__/{chunk-H4DISFAI.mjs.map → chunk-YCSATFGK.mjs.map} +0 -0
  494. /package/out/__chunks__/{chunk-KK25BEMY.mjs.map → chunk-YJFGRD5R.mjs.map} +0 -0
  495. /package/out/__chunks__/{chunk-OF3XH6ZU.mjs.map → chunk-YJIAAC7S.mjs.map} +0 -0
  496. /package/out/__chunks__/{chunk-XHKNB4IP.mjs.map → chunk-YY724VZR.mjs.map} +0 -0
  497. /package/out/__chunks__/{chunk-4XIT3N7Y.mjs.map → chunk-ZDCPV3O4.mjs.map} +0 -0
  498. /package/out/__chunks__/{chunk-UJUAT5NK.mjs.map → chunk-ZEQI7SII.mjs.map} +0 -0
  499. /package/out/__chunks__/{chunk-PAAJPYAE.mjs.map → chunk-ZKAIQNIL.mjs.map} +0 -0
  500. /package/out/__chunks__/{chunk-IR743HKQ.mjs.map → chunk-ZMLJXSO5.mjs.map} +0 -0
  501. /package/out/__chunks__/{chunk-HOJ7JMTW.mjs.map → chunk-ZP44CDGG.mjs.map} +0 -0
  502. /package/out/__chunks__/{chunk-YVLFUMPH.mjs.map → chunk-ZQOG6A2Z.mjs.map} +0 -0
  503. /package/out/__chunks__/{chunk-S53SAYHR.mjs.map → chunk-ZQOIMST2.mjs.map} +0 -0
@@ -0,0 +1,2 @@
1
+ import{a as t}from"./chunk-END5ZJQH.mjs";var o={async getTransactionsHistory(s){return await t(s)}};export{o as a};
2
+ //# sourceMappingURL=chunk-OE5E647N.mjs.map
@@ -0,0 +1,2 @@
1
+ import{s as e}from"./chunk-AYURCZHZ.mjs";import{b as r}from"./chunk-SAAOQW7P.mjs";function d(t=e()){return r(t).explorerAddress}export{d as a};
2
+ //# sourceMappingURL=chunk-OFSHYRXC.mjs.map
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=chunk-OL6LWUIJ.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "sourcesContent": [],
5
+ "mappings": "",
6
+ "names": []
7
+ }
@@ -0,0 +1,2 @@
1
+ import{a as n}from"./chunk-HH5SA7BX.mjs";import{a as s}from"./chunk-I3MK6KZJ.mjs";import{Address as d}from"@multiversx/sdk-core";import c from"bignumber.js";var l=({data:e,decodeMethod:i,transactionTokens:t})=>{switch(i){case"text":try{return Buffer.from(e,"hex").toString("utf8")}catch{return e}case"decimal":return e!==""?new c(e,16).toString(10):"";case"smart":try{let r=d.newFromHex(e).toString();if(s(r))return r}catch{}try{let r=Buffer.from(e,"hex").toString("utf8");if(n(r))return r;{if(t&&[...t.esdts,...t.nfts].some(f=>r.includes(f)))return r;let o=new c(e,16);return o.isFinite()?o.toString(10):e}}catch{return e}case"raw":default:return e}};export{l as a};
2
+ //# sourceMappingURL=chunk-OOVV574D.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/utils/transactions/getDecodedDataField/helpers/decodeByMethod.ts"],
4
+ "sourcesContent": ["import { Address } from '@multiversx/sdk-core';\nimport BigNumber from 'bignumber.js';\n\nimport {\n DecodeMethodEnum,\n TransactionTokensType\n} from 'types/serverTransactions.types';\nimport { isUtf8 } from 'utils/decoders';\nimport { addressIsValid } from 'utils/validation/addressIsValid';\n\ninterface IDecodeByMethod {\n data: string;\n decodeMethod: DecodeMethodEnum | string;\n transactionTokens?: TransactionTokensType;\n}\n\nexport const decodeByMethod = ({\n data,\n decodeMethod,\n transactionTokens\n}: IDecodeByMethod) => {\n switch (decodeMethod) {\n case DecodeMethodEnum.text:\n try {\n return Buffer.from(data, 'hex').toString('utf8');\n } catch {\n return data;\n }\n\n case DecodeMethodEnum.decimal:\n return data !== '' ? new BigNumber(data, 16).toString(10) : '';\n case DecodeMethodEnum.smart:\n try {\n const bech32Encoded = Address.newFromHex(data).toString();\n\n if (addressIsValid(bech32Encoded)) {\n return bech32Encoded;\n }\n } catch {\n // skip\n }\n\n try {\n const decoded = Buffer.from(data, 'hex').toString('utf8');\n\n if (!isUtf8(decoded)) {\n if (transactionTokens) {\n const tokens = [\n ...transactionTokens.esdts,\n ...transactionTokens.nfts\n ];\n\n if (tokens.some((token) => decoded.includes(token))) {\n return decoded;\n }\n }\n\n const bigNumber = new BigNumber(data, 16);\n\n return bigNumber.isFinite() ? bigNumber.toString(10) : data;\n } else {\n return decoded;\n }\n } catch {\n return data;\n }\n\n case DecodeMethodEnum.raw:\n default:\n return data;\n }\n};\n"],
5
+ "mappings": "kFAAA,OAAS,WAAAA,MAAe,uBACxB,OAAOC,MAAe,eAef,IAAMC,EAAiB,CAAC,CAC7B,KAAAC,EACA,aAAAC,EACA,kBAAAC,CACF,IAAuB,CACrB,OAAQD,EAAc,CACpB,WACE,GAAI,CACF,OAAO,OAAO,KAAKD,EAAM,KAAK,EAAE,SAAS,MAAM,CACjD,MAAQ,CACN,OAAOA,CACT,CAEF,cACE,OAAOA,IAAS,GAAK,IAAIG,EAAUH,EAAM,EAAE,EAAE,SAAS,EAAE,EAAI,GAC9D,YACE,GAAI,CACF,IAAMI,EAAgBC,EAAQ,WAAWL,CAAI,EAAE,SAAS,EAExD,GAAIM,EAAeF,CAAa,EAC9B,OAAOA,CAEX,MAAQ,CAER,CAEA,GAAI,CACF,IAAMG,EAAU,OAAO,KAAKP,EAAM,KAAK,EAAE,SAAS,MAAM,EAExD,GAAKQ,EAAOD,CAAO,EAgBjB,OAAOA,EAhBa,CACpB,GAAIL,GACa,CACb,GAAGA,EAAkB,MACrB,GAAGA,EAAkB,IACvB,EAEW,KAAMO,GAAUF,EAAQ,SAASE,CAAK,CAAC,EAChD,OAAOF,EAIX,IAAMG,EAAY,IAAIP,EAAUH,EAAM,EAAE,EAExC,OAAOU,EAAU,SAAS,EAAIA,EAAU,SAAS,EAAE,EAAIV,CACzD,CAGF,MAAQ,CACN,OAAOA,CACT,CAEF,UACA,QACE,OAAOA,CACX,CACF",
6
+ "names": ["Address", "BigNumber", "decodeByMethod", "data", "decodeMethod", "transactionTokens", "BigNumber", "bech32Encoded", "Address", "addressIsValid", "decoded", "isUtf8", "token", "bigNumber"]
7
+ }
@@ -1,2 +1,2 @@
1
- import{j as p,q as e}from"./chunk-LPGMDX6Q.mjs";import{c as i}from"./chunk-NTEMINYA.mjs";var T=()=>e().setState(p),a=({address:o,providerType:d})=>{e().setState(({account:r,loginInfo:t})=>{r.address=o,r.publicKey=new i(o).toHex(),t&&(t.providerType=d)},!1,"loginAction")};export{T as a,a as b};
2
- //# sourceMappingURL=chunk-2HKAVY3C.mjs.map
1
+ import{j as p,q as e}from"./chunk-AYURCZHZ.mjs";import{c as i}from"./chunk-NTEMINYA.mjs";var T=()=>e().setState(p),a=({address:o,providerType:d})=>{e().setState(({account:r,loginInfo:t})=>{r.address=o,r.publicKey=new i(o).toHex(),t&&(t.providerType=d)},!1,"loginAction")};export{T as a,a as b};
2
+ //# sourceMappingURL=chunk-PBMO4Y47.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as e}from"./chunk-GSRRAPL5.mjs";import o from"axios";var n="transactions/ppu";async function l(a,s){let r=`${e(s)}/${n}/${a}`;try{let{data:t}=await o.get(r);return t?{[a]:{lastBlock:t.lastBlock,fast:t.fast,faster:t.faster}}:null}catch(t){return console.error("Error fetching gas station metadata from:",r,t),null}}export{l as a};
2
- //# sourceMappingURL=chunk-BQP6NPQM.mjs.map
1
+ import{a as e}from"./chunk-TSK44JFJ.mjs";import o from"axios";var n="transactions/ppu";async function l(a,s){let r=`${e(s)}/${n}/${a}`;try{let{data:t}=await o.get(r);return t?{[a]:{lastBlock:t.lastBlock,fast:t.fast,faster:t.faster}}:null}catch(t){return console.error("Error fetching gas station metadata from:",r,t),null}}export{l as a};
2
+ //# sourceMappingURL=chunk-PETVWH5Z.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as n}from"./chunk-FMQYLMTU.mjs";import{b as s,c as r}from"./chunk-RNSBN5JT.mjs";async function l({results:e,hash:i,sessionId:t}){let a=e?.find(o=>o?.returnMessage!=="");r({sessionId:t,transaction:{...a,hash:i,status:"fail",inTransit:!1}}),s({sessionId:t,status:"fail",errorMessage:a?.returnMessage}),await n({sessionId:t,status:"fail"})}export{l as a};
2
- //# sourceMappingURL=chunk-OCGNA44K.mjs.map
1
+ import{a as n}from"./chunk-FMQYLMTU.mjs";import{b as s,c as r}from"./chunk-C25AGRYE.mjs";async function l({results:e,hash:i,sessionId:t}){let a=e?.find(o=>o?.returnMessage!=="");r({sessionId:t,transaction:{...a,hash:i,status:"fail",inTransit:!1}}),s({sessionId:t,status:"fail",errorMessage:a?.returnMessage}),await n({sessionId:t,status:"fail"})}export{l as a};
2
+ //# sourceMappingURL=chunk-PIBYPDMV.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as d}from"./chunk-N342XMFH.mjs";import{h as o}from"./chunk-OEPTRJEB.mjs";var D=({data:r,highlight:a,identifier:i})=>{let e={};return Object.values(o).forEach(t=>{let c=d({data:r,identifier:i,decodeMethod:t,highlight:a});e[t]=c}),e};export{D as a};
2
+ //# sourceMappingURL=chunk-PLMCHSS6.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/providers/strategies/helpers/signTransactions/helpers/getCommonData/helpers/decodeDataField.ts"],
4
+ "sourcesContent": ["import {\n DecodeMethodEnum,\n DecodedDisplayType\n} from 'types/serverTransactions.types';\nimport { getDecodedDataField } from 'utils/transactions/getDecodedDataField';\n\nexport const getAllDecodedFormats = ({\n data,\n highlight,\n identifier\n}: {\n data: string;\n highlight: string | null;\n identifier?: string;\n}) => {\n const decodedFormats: Partial<Record<DecodeMethodEnum, DecodedDisplayType>> =\n {};\n\n Object.values(DecodeMethodEnum).forEach((decodeMethod) => {\n const decodedData = getDecodedDataField({\n data,\n identifier,\n decodeMethod,\n highlight\n });\n\n decodedFormats[decodeMethod] = decodedData;\n });\n\n return decodedFormats;\n};\n"],
5
+ "mappings": "kFAMO,IAAMA,EAAuB,CAAC,CACnC,KAAAC,EACA,UAAAC,EACA,WAAAC,CACF,IAIM,CACJ,IAAMC,EACJ,CAAC,EAEH,cAAO,OAAOC,CAAgB,EAAE,QAASC,GAAiB,CACxD,IAAMC,EAAcC,EAAoB,CACtC,KAAAP,EACA,WAAAE,EACA,aAAAG,EACA,UAAAJ,CACF,CAAC,EAEDE,EAAeE,CAAY,EAAIC,CACjC,CAAC,EAEMH,CACT",
6
+ "names": ["getAllDecodedFormats", "data", "highlight", "identifier", "decodedFormats", "DecodeMethodEnum", "decodeMethod", "decodedData", "getDecodedDataField"]
7
+ }
@@ -1,2 +1,2 @@
1
- import{a as e}from"./chunk-KX5J6EMC.mjs";var t=()=>{if(!e)return"";try{let r=e.document?.referrer;return r?new URL(r).origin:""}catch(r){return console.error(r),""}};export{t as a};
2
- //# sourceMappingURL=chunk-DG77T3NS.mjs.map
1
+ import{a as e}from"./chunk-XDYKH6G4.mjs";var t=()=>{if(!e)return"";try{let r=e.document?.referrer;return r?new URL(r).origin:""}catch(r){return console.error(r),""}};export{t as a};
2
+ //# sourceMappingURL=chunk-PWXUYZF5.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as e}from"./chunk-KXUILKL2.mjs";var t={closeConnectionRef:void 0};async function c(n){let{closeConnection:o}=await e(n);t.closeConnectionRef=o}export{t as a,c as b};
2
- //# sourceMappingURL=chunk-PO3ODHJ7.mjs.map
1
+ import{a as e}from"./chunk-JNUF7URZ.mjs";var t={closeConnectionRef:void 0};async function c(n){let{closeConnection:o}=await e(n);t.closeConnectionRef=o}export{t as a,c as b};
2
+ //# sourceMappingURL=chunk-Q62OP5VI.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as V}from"./chunk-7Z7IX367.mjs";import{a as B}from"./chunk-VCQBYNNS.mjs";import{a as $}from"./chunk-LN5UXO64.mjs";import{a as _}from"./chunk-PHOF3Z5D.mjs";import{a as U}from"./chunk-RBZC4PEU.mjs";import{a as R}from"./chunk-BQX7MJR6.mjs";import{a as M}from"./chunk-BETSOJFK.mjs";import{a as w}from"./chunk-URJQWHBM.mjs";import{a as O}from"./chunk-YGI3KXMZ.mjs";import{a as x}from"./chunk-I6WJ63GD.mjs";import{a as v}from"./chunk-RYIJWGFA.mjs";import{t as G}from"./chunk-LY3MRREN.mjs";import{a as L}from"./chunk-TMOMM4JN.mjs";import{a as h}from"./chunk-BRJNX4JF.mjs";import{a as b,c as C,f as u}from"./chunk-PJWJZHIS.mjs";import{a as P}from"./chunk-KD2IQ32V.mjs";import{c as f}from"./chunk-TI37DKBT.mjs";import{k as A}from"./chunk-LHEH7L4L.mjs";import{a as F}from"./chunk-KX5J6EMC.mjs";import{BigNumber as yt}from"bignumber.js";async function Kt({allTransactions:T,currentScreenIndex:m,egldLabel:o,network:e,gasPriceData:c,price:S,address:p,username:z,shard:j,signedIndexes:i,parsedTransactionsByDataField:q}){let t=T[m],H=t?.transaction?.sender.toString(),K=t?.transaction,D=null,y=null,W=R({egldLabel:o,sender:H,apiAddress:e.apiAddress,address:p,parsedTransactionsByDataField:q}),a=t.transaction.toPlainObject(),n=await W(t),d=!n?.transactionTokenInfo?.tokenId,{tokenId:g,nonce:l,amount:I=""}=n?.transactionTokenInfo??{},Z=g&&l&&l.length>0?`${g}-${l}`:g,J=await x({tokenId:Z}),{esdtPrice:Q,tokenDecimals:X,type:r,identifier:s,tokenImageUrl:Y}=J;if(r==="SemiFungibleESDT"||r==="NonFungibleESDT")y={type:r,identifier:s,amount:I,imageURL:Y};else{let E=({addCommas:Dt})=>u({input:d?t.transaction.value.toString():I,decimals:d?Number(e.decimals):X,digits:Number(e.digits),showLastNonZeroDecimal:!1,addCommas:Dt}),ut=E({addCommas:!0}),ft=E({addCommas:!1}),Tt=Number(d?S:Q),St=O({amount:ft,usd:Tt,addEqualSign:!0});D={identifier:(s===A?o:s)??o,amount:ut,usdValue:St}}let{feeLimitFormatted:tt,feeInFiatLimit:nt}=w({transaction:K,price:S}),ot=$({shard:j,initialGasPrice:c.initialGasPrice,transaction:a,gasStationMetadata:e.gasStationMetadata}),et=_({transaction:a,gasPriceData:c}),it=G().getType(),at=v(it),N=T.length,rt=i.length>0?i[i.length-1]+1:0,st=f(t.transaction.data.toString()??""),k=U(n?.transactionTokenInfo),mt=M({data:st,identifier:s,highlight:k}),ct=L(),pt=h({to:`/${P}/${p}`,explorerAddress:ct}),dt=N===1||n?.needsSigning&&!i.includes(m),gt=u({input:et.toString(),decimals:C,addCommas:!0,digits:b}),lt=new yt(a.gasLimit).toFormat({decimalSeparator:",",groupSeparator:".",groupSize:3});return{commonData:{receiver:a.receiver.toString(),data:f(t.transaction.data.toString()??""),decodedData:mt,gasPrice:gt,gasLimit:lt,explorerLink:pt,ppu:c.ppu,ppuOptions:ot,egldLabel:o,tokenType:V(r),feeLimit:tt,feeInFiatLimit:nt,transactionsCount:N,currentIndex:m,currentIndexToSign:rt,highlight:k,scCall:B(n?.transactionTokenInfo),needsSigning:dt,isEditable:n?.needsSigning,providerName:at,address:p,username:z,origin:F.location?.origin},tokenTransaction:D,fungibleTransaction:y}}export{Kt as a};
2
- //# sourceMappingURL=chunk-Z63LDNZJ.mjs.map
1
+ import{a as M}from"./chunk-PLMCHSS6.mjs";import{a as V}from"./chunk-7Z7IX367.mjs";import{a as B}from"./chunk-VCQBYNNS.mjs";import{a as $}from"./chunk-LN5UXO64.mjs";import{a as _}from"./chunk-PHOF3Z5D.mjs";import{a as U}from"./chunk-RBZC4PEU.mjs";import{a as R}from"./chunk-BQX7MJR6.mjs";import{a as w}from"./chunk-URJQWHBM.mjs";import{a as O}from"./chunk-YGI3KXMZ.mjs";import{a as x}from"./chunk-4N34K4EN.mjs";import{a as v}from"./chunk-RYIJWGFA.mjs";import{t as G}from"./chunk-T3JST5WU.mjs";import{a as L}from"./chunk-OFSHYRXC.mjs";import{a as h}from"./chunk-BRJNX4JF.mjs";import{a as b,c as C,f as u}from"./chunk-PJWJZHIS.mjs";import{a as P}from"./chunk-KD2IQ32V.mjs";import{c as f}from"./chunk-TI37DKBT.mjs";import{k as A}from"./chunk-LHEH7L4L.mjs";import{a as F}from"./chunk-XDYKH6G4.mjs";import{BigNumber as yt}from"bignumber.js";async function Kt({allTransactions:T,currentScreenIndex:m,egldLabel:o,network:e,gasPriceData:c,price:S,address:p,username:z,shard:j,signedIndexes:i,parsedTransactionsByDataField:q}){let t=T[m],H=t?.transaction?.sender.toString(),K=t?.transaction,D=null,y=null,W=R({egldLabel:o,sender:H,apiAddress:e.apiAddress,address:p,parsedTransactionsByDataField:q}),a=t.transaction.toPlainObject(),n=await W(t),d=!n?.transactionTokenInfo?.tokenId,{tokenId:g,nonce:l,amount:I=""}=n?.transactionTokenInfo??{},Z=g&&l&&l.length>0?`${g}-${l}`:g,J=await x({tokenId:Z}),{esdtPrice:Q,tokenDecimals:X,type:r,identifier:s,tokenImageUrl:Y}=J;if(r==="SemiFungibleESDT"||r==="NonFungibleESDT")y={type:r,identifier:s,amount:I,imageURL:Y};else{let E=({addCommas:Dt})=>u({input:d?t.transaction.value.toString():I,decimals:d?Number(e.decimals):X,digits:Number(e.digits),showLastNonZeroDecimal:!1,addCommas:Dt}),ut=E({addCommas:!0}),ft=E({addCommas:!1}),Tt=Number(d?S:Q),St=O({amount:ft,usd:Tt,addEqualSign:!0});D={identifier:(s===A?o:s)??o,amount:ut,usdValue:St}}let{feeLimitFormatted:tt,feeInFiatLimit:nt}=w({transaction:K,price:S}),ot=$({shard:j,initialGasPrice:c.initialGasPrice,transaction:a,gasStationMetadata:e.gasStationMetadata}),et=_({transaction:a,gasPriceData:c}),it=G().getType(),at=v(it),N=T.length,rt=i.length>0?i[i.length-1]+1:0,st=f(t.transaction.data.toString()??""),k=U(n?.transactionTokenInfo),mt=M({data:st,identifier:s,highlight:k}),ct=L(),pt=h({to:`/${P}/${p}`,explorerAddress:ct}),dt=N===1||n?.needsSigning&&!i.includes(m),gt=u({input:et.toString(),decimals:C,addCommas:!0,digits:b}),lt=new yt(a.gasLimit).toFormat({decimalSeparator:",",groupSeparator:".",groupSize:3});return{commonData:{receiver:a.receiver.toString(),data:f(t.transaction.data.toString()??""),decodedData:mt,gasPrice:gt,gasLimit:lt,explorerLink:pt,ppu:c.ppu,ppuOptions:ot,egldLabel:o,tokenType:V(r),feeLimit:tt,feeInFiatLimit:nt,transactionsCount:N,currentIndex:m,currentIndexToSign:rt,highlight:k,scCall:B(n?.transactionTokenInfo),needsSigning:dt,isEditable:n?.needsSigning,providerName:at,address:p,username:z,origin:F.location?.origin},tokenTransaction:D,fungibleTransaction:y}}export{Kt as a};
2
+ //# sourceMappingURL=chunk-QEU6LCSD.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as B}from"./chunk-YVLFUMPH.mjs";import{a as b}from"./chunk-YD2O3NV7.mjs";import{a as k}from"./chunk-QXC4D3AC.mjs";import{a as R}from"./chunk-XHKNB4IP.mjs";import{a as D}from"./chunk-Z63LDNZJ.mjs";import{a as I}from"./chunk-PHOF3Z5D.mjs";import{a as j}from"./chunk-URJQWHBM.mjs";import{a as _}from"./chunk-KP4MUQKU.mjs";import{a as A}from"./chunk-72D44IHE.mjs";import{a as O}from"./chunk-XUI3Z5NN.mjs";import{s as x}from"./chunk-LPGMDX6Q.mjs";import{b as v}from"./chunk-SAAOQW7P.mjs";import{a as G,c as U,f as F}from"./chunk-PJWJZHIS.mjs";import{a as w}from"./chunk-NTEMINYA.mjs";import{c as N}from"./chunk-MGFIOCA4.mjs";async function Dn({transactions:z=[],handleSign:H,guardTransactions:K=_}){let{account:{address:y,shard:h,username:E}}=B(),g=v(x()),C=O(),{allTransactions:r,parsedTransactionsByDataField:L}=R(z),p=[],n=A.getInstance();if(await n.openUI(),!n)throw new Error("Unable to establish connection with sign screens");let W=async()=>{await b(),n.closeUI()};return n.subscribeToEventBus("CLOSE_SIGN_TRANSACTIONS",W),new Promise(async(X,M)=>{let d=[],Y=await k({baseURL:g.apiAddress});n.notifyDataUpdate(),n.initializeGasPriceMap(r.map(a=>a.transaction));let l=Y?.price,t=0,T=async()=>{let c=r[t]?.transaction,i=Number(c.nonce);try{n.updateIsLoading(!0);let{commonData:o,tokenTransaction:e,fungibleTransaction:s}=await D({allTransactions:r,currentScreenIndex:t,egldLabel:C,network:g,gasPriceData:n.ppuMap[i],price:l,address:y,username:E,shard:h,signedIndexes:p,parsedTransactionsByDataField:L});e&&n.updateTokenTransaction(e),s&&n.updateNonFungibleTransaction(s.type,s),n.updateCommonData(o)}catch(o){throw console.error(`Error fetching common data for transaction at index ${t}:`,o),o}finally{n.updateIsLoading(!1)}},$=()=>{t>0&&(t--,T())},q=(a=0)=>{let i=r[t].transaction,o=Number(i.nonce);n.updateGasPriceMap({nonce:o,ppu:a}),n.updateCommonData({ppu:a});let e=i.toPlainObject(),s=I({transaction:e,gasPriceData:n.ppuMap[o]}),P=w.newFromPlainObject({...e,gasPrice:s}),u=j({transaction:P,price:l}),m=F({input:s.toString(),decimals:U,addCommas:!0,digits:G});n.updateCommonData({feeLimit:u.feeLimitFormatted,feeInFiatLimit:u.feeInFiatLimit,gasPrice:m,ppu:a})},J=async()=>{M(new Error("Transaction signing cancelled by user")),await b(),n.closeUI()},f=()=>{t<n.transactionsCount-1&&(t++,T())},Q=async()=>{let c=r[t].transaction,i=Number(c.nonce),{commonData:o}=await D({allTransactions:r,currentScreenIndex:t,egldLabel:C,network:g,gasPriceData:n.ppuMap[i],price:l,address:y,username:E,shard:h,signedIndexes:p,parsedTransactionsByDataField:L});if(!o.needsSigning)return p.push(t),f();let e=c.toPlainObject(),s=e.nonce,P=I({transaction:e,gasPriceData:n.ppuMap[s]}),u=w.newFromPlainObject({...e,gasPrice:P});try{let m=await H([u]);m&&(p.push(t),d.push(m[0]));let nn=t===r.length-1,tn=r.filter(S=>S.needsSigning),an=d.length===tn.length;if(nn&&an){let S=await K(d);return n.closeUI(),X(S)}f()}catch(m){n.closeUI(),M(m)}},V=new Map([["NEXT_SIGN_TRANSACTIONS",f],["CONFIRM_SIGN_TRANSACTIONS",Q],["CLOSE_SIGN_TRANSACTIONS",J],["BACK_SIGN_TRANSACTIONS",$],["SET_PPU_SIGN_TRANSACTIONS",q]]);function Z(){for(let[a,c]of V)n.subscribeToEventBus(a,c)}Z(),await T()})}export{Dn as a};
2
- //# sourceMappingURL=chunk-O24MRZB2.mjs.map
1
+ import{a as B}from"./chunk-ZQOG6A2Z.mjs";import{a as b}from"./chunk-2KE2BNG7.mjs";import{a as k}from"./chunk-QXC4D3AC.mjs";import{a as D}from"./chunk-QEU6LCSD.mjs";import{a as I}from"./chunk-PHOF3Z5D.mjs";import{a as _}from"./chunk-S2HQMNW6.mjs";import{a as R}from"./chunk-YY724VZR.mjs";import{a as j}from"./chunk-URJQWHBM.mjs";import{a as A}from"./chunk-TJYR4CV6.mjs";import{a as O}from"./chunk-NJSC7RC2.mjs";import{s as x}from"./chunk-AYURCZHZ.mjs";import{b as v}from"./chunk-SAAOQW7P.mjs";import{a as G,c as U,f as F}from"./chunk-PJWJZHIS.mjs";import{a as w}from"./chunk-NTEMINYA.mjs";import{c as N}from"./chunk-MGFIOCA4.mjs";async function Dn({transactions:z=[],handleSign:H,guardTransactions:K=_}){let{account:{address:y,shard:h,username:E}}=B(),g=v(x()),C=O(),{allTransactions:r,parsedTransactionsByDataField:L}=R(z),p=[],n=A.getInstance();if(await n.openUI(),!n)throw new Error("Unable to establish connection with sign screens");let W=async()=>{await b(),n.closeUI()};return n.subscribeToEventBus("CLOSE_SIGN_TRANSACTIONS",W),new Promise(async(X,M)=>{let d=[],Y=await k({baseURL:g.apiAddress});n.notifyDataUpdate(),n.initializeGasPriceMap(r.map(a=>a.transaction));let l=Y?.price,t=0,T=async()=>{let c=r[t]?.transaction,i=Number(c.nonce);try{n.updateIsLoading(!0);let{commonData:o,tokenTransaction:e,fungibleTransaction:s}=await D({allTransactions:r,currentScreenIndex:t,egldLabel:C,network:g,gasPriceData:n.ppuMap[i],price:l,address:y,username:E,shard:h,signedIndexes:p,parsedTransactionsByDataField:L});e&&n.updateTokenTransaction(e),s&&n.updateNonFungibleTransaction(s.type,s),n.updateCommonData(o)}catch(o){throw console.error(`Error fetching common data for transaction at index ${t}:`,o),o}finally{n.updateIsLoading(!1)}},$=()=>{t>0&&(t--,T())},q=(a=0)=>{let i=r[t].transaction,o=Number(i.nonce);n.updateGasPriceMap({nonce:o,ppu:a}),n.updateCommonData({ppu:a});let e=i.toPlainObject(),s=I({transaction:e,gasPriceData:n.ppuMap[o]}),P=w.newFromPlainObject({...e,gasPrice:s}),u=j({transaction:P,price:l}),m=F({input:s.toString(),decimals:U,addCommas:!0,digits:G});n.updateCommonData({feeLimit:u.feeLimitFormatted,feeInFiatLimit:u.feeInFiatLimit,gasPrice:m,ppu:a})},J=async()=>{M(new Error("Transaction signing cancelled by user")),await b(),n.closeUI()},f=()=>{t<n.transactionsCount-1&&(t++,T())},Q=async()=>{let c=r[t].transaction,i=Number(c.nonce),{commonData:o}=await D({allTransactions:r,currentScreenIndex:t,egldLabel:C,network:g,gasPriceData:n.ppuMap[i],price:l,address:y,username:E,shard:h,signedIndexes:p,parsedTransactionsByDataField:L});if(!o.needsSigning)return p.push(t),f();let e=c.toPlainObject(),s=e.nonce,P=I({transaction:e,gasPriceData:n.ppuMap[s]}),u=w.newFromPlainObject({...e,gasPrice:P});try{let m=await H([u]);m&&(p.push(t),d.push(m[0]));let nn=t===r.length-1,tn=r.filter(S=>S.needsSigning),an=d.length===tn.length;if(nn&&an){let S=await K(d);return n.closeUI(),X(S)}f()}catch(m){n.closeUI(),M(m)}},V=new Map([["NEXT_SIGN_TRANSACTIONS",f],["CONFIRM_SIGN_TRANSACTIONS",Q],["CLOSE_SIGN_TRANSACTIONS",J],["BACK_SIGN_TRANSACTIONS",$],["SET_PPU_SIGN_TRANSACTIONS",q]]);function Z(){for(let[a,c]of V)n.subscribeToEventBus(a,c)}Z(),await T()})}export{Dn as a};
2
+ //# sourceMappingURL=chunk-QGTHGE7E.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as u}from"./chunk-TQA3JDNV.mjs";import{s}from"./chunk-LPGMDX6Q.mjs";import{e as a}from"./chunk-UERJ6AKK.mjs";function x(n){let e=s(),o=u(e),c=a(e),t=Object.keys(o).map(Number).reduce((r,m)=>{let i=o[m]?.transactions||[];return Math.max(r,...i.map(l=>l.nonce),0)},0);return t>0&&(t+=1),n==null?Math.max(t,c):Math.max(t,n.nonce,c)}export{x as a};
2
- //# sourceMappingURL=chunk-XNIJIKGB.mjs.map
1
+ import{a as u}from"./chunk-TQA3JDNV.mjs";import{s}from"./chunk-AYURCZHZ.mjs";import{e as a}from"./chunk-UERJ6AKK.mjs";function x(n){let e=s(),o=u(e),c=a(e),t=Object.keys(o).map(Number).reduce((r,m)=>{let i=o[m]?.transactions||[];return Math.max(r,...i.map(l=>l.nonce),0)},0);return t>0&&(t+=1),n==null?Math.max(t,c):Math.max(t,n.nonce,c)}export{x as a};
2
+ //# sourceMappingURL=chunk-QLEOO5UN.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as u}from"./chunk-7CA6UKPK.mjs";import{b as T}from"./chunk-5KVNYLOM.mjs";import{c}from"./chunk-TI37DKBT.mjs";function D({transactions:i}){let e=[],o={};return!i||i.length===0?{allTransactions:e,parsedTransactionsByDataField:o}:(i.forEach((n,m)=>{let p=c(n.data.toString()??""),s=u(p);if(s.length>0)s.forEach((t,a)=>{let r=a===s.length-1,l={transaction:n,multiTxData:t.data,transactionIndex:a,needsSigning:r};o[t.data]={tokenId:t.token?t.token:"",amount:t.amount?t.amount:"",type:t.type,nonce:t.nonce?t.nonce:"",multiTxData:t.data,receiver:t.receiver},e.push(l)});else{let t=c(n.data.toString()??""),{tokenId:a,amount:r}=T(t);a&&(o[t]={tokenId:a,amount:r,receiver:n.receiver.toBech32()}),e.push({transaction:n,transactionIndex:m,multiTxData:t,needsSigning:!0})}}),{allTransactions:e,parsedTransactionsByDataField:o})}export{D as a};
2
- //# sourceMappingURL=chunk-BNBD3WVN.mjs.map
1
+ import{a as u}from"./chunk-7CA6UKPK.mjs";import{b as T}from"./chunk-6DWUEZO7.mjs";import{c}from"./chunk-TI37DKBT.mjs";function D({transactions:i}){let e=[],o={};return!i||i.length===0?{allTransactions:e,parsedTransactionsByDataField:o}:(i.forEach((n,m)=>{let p=c(n.data.toString()??""),s=u(p);if(s.length>0)s.forEach((t,a)=>{let r=a===s.length-1,l={transaction:n,multiTxData:t.data,transactionIndex:a,needsSigning:r};o[t.data]={tokenId:t.token?t.token:"",amount:t.amount?t.amount:"",type:t.type,nonce:t.nonce?t.nonce:"",multiTxData:t.data,receiver:t.receiver},e.push(l)});else{let t=c(n.data.toString()??""),{tokenId:a,amount:r}=T(t);a&&(o[t]={tokenId:a,amount:r,receiver:n.receiver.toBech32()}),e.push({transaction:n,transactionIndex:m,multiTxData:t,needsSigning:!0})}}),{allTransactions:e,parsedTransactionsByDataField:o})}export{D as a};
2
+ //# sourceMappingURL=chunk-RBJ3O63I.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as t}from"./chunk-ZKAIQNIL.mjs";import{c as n}from"./chunk-AYURCZHZ.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-RN2VZOXB.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as s}from"./chunk-SUBC3H4J.mjs";import{a as t}from"./chunk-U64LDJTG.mjs";import{a as n}from"./chunk-5JYD7XMI.mjs";import{s as e}from"./chunk-LPGMDX6Q.mjs";import{b as o}from"./chunk-SAAOQW7P.mjs";var w=async r=>{let{isGuarded:i}=n();if(!s({isGuarded:i,transactions:r}))return r;let a=r[0].sender.toBech32(),{walletAddress:d}=o(e());return await(await t({address:a,walletUrl:d}))?.guardTransactions(r)||[]};export{w as a};
2
- //# sourceMappingURL=chunk-KP4MUQKU.mjs.map
1
+ import{a as s}from"./chunk-SUBC3H4J.mjs";import{a as t}from"./chunk-U64LDJTG.mjs";import{a as n}from"./chunk-AIKQPMR3.mjs";import{s as e}from"./chunk-AYURCZHZ.mjs";import{b as o}from"./chunk-SAAOQW7P.mjs";var w=async r=>{let{isGuarded:i}=n();if(!s({isGuarded:i,transactions:r}))return r;let a=r[0].sender.toBech32(),{walletAddress:d}=o(e());return await(await t({address:a,walletUrl:d}))?.guardTransactions(r)||[]};export{w as a};
2
+ //# sourceMappingURL=chunk-S2HQMNW6.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as i}from"./chunk-PO3ODHJ7.mjs";import{a}from"./chunk-OF3XH6ZU.mjs";import{a as u}from"./chunk-2HKAVY3C.mjs";import{c as n}from"./chunk-2SVWHJC4.mjs";import{a as s}from"./chunk-KX5J6EMC.mjs";var c=(o,t)=>{let r=`sdk-dapp-logout-event-${o}`,e=t.getItem(r);e&&o!==e||(t.setItem(r,o),t.removeItem(r))};async function L({provider:o,options:t={shouldBroadcastLogoutAcrossTabs:!0}}){let r=a();t.shouldBroadcastLogoutAcrossTabs&&s.localStorage&&c(r,s.localStorage);try{return u(),n.forEach(g=>g()),n.clear(),i.closeConnectionRef?.(),await o.logout()}catch(e){return console.error("Logging out error:",e),!1}}export{L as a};
2
- //# sourceMappingURL=chunk-27OTZWDO.mjs.map
1
+ import{a as i}from"./chunk-Q62OP5VI.mjs";import{a}from"./chunk-YJIAAC7S.mjs";import{a as u}from"./chunk-PBMO4Y47.mjs";import{c as n}from"./chunk-XJQ4VZS2.mjs";import{a as s}from"./chunk-XDYKH6G4.mjs";var c=(o,t)=>{let r=`sdk-dapp-logout-event-${o}`,e=t.getItem(r);e&&o!==e||(t.setItem(r,o),t.removeItem(r))};async function L({provider:o,options:t={shouldBroadcastLogoutAcrossTabs:!0}}){let r=a();t.shouldBroadcastLogoutAcrossTabs&&s.localStorage&&c(r,s.localStorage);try{return u(),n.forEach(g=>g()),n.clear(),i.closeConnectionRef?.(),await o.logout()}catch(e){return console.error("Logging out error:",e),!1}}export{L as a};
2
+ //# sourceMappingURL=chunk-SYNNW6IN.mjs.map
@@ -1,2 +1,2 @@
1
- import{d as s}from"./chunk-7VNNDJ7P.mjs";import{a as u}from"./chunk-XUADWD55.mjs";import{s as c}from"./chunk-LPGMDX6Q.mjs";import{b as d}from"./chunk-SAAOQW7P.mjs";import{a as v}from"./chunk-CDQ2BNUD.mjs";import{a}from"./chunk-PLUWBWJ2.mjs";var i=class i extends u{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&&i.onClose&&i.onClose(),this.closeUI()};this.handleLogin=async({type:e,anchor:o})=>{if(!i.loginHandler)throw new Error("Login callback not initialized. Please call `init()` first.");try{this.isSimpleLoginCallback(i.loginHandler)?(await(await s.create({type:e,anchor:o})).login(),i.loginHandler()):i.loginHandler({type:e,anchor:o}),await this.handleCloseUI({isLoginFinished:!0})}catch(t){console.error(t),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 i.instance||(i.instance=new i),i.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,t=[...Object.values(a).filter(n=>![a.none,a.webview].includes(n)),...e.map(n=>n.type)],P=e.reduce((n,r)=>(n[r.type]=r.name,n),{}),l={...v,...P};return(i.allowedProviders?i?.allowedProviders.filter(n=>t.includes(n)):t).map(n=>{let r=e.find(g=>g.type===n);return r||{name:n in l?l[n]:n,type:n}})}};i.loginHandler=null,i.onClose=null,i.allowedProviders=null;var p=i;export{p as a};
2
- //# sourceMappingURL=chunk-STVYY4LI.mjs.map
1
+ import{d as s}from"./chunk-463K27BJ.mjs";import{a as u}from"./chunk-T2BVHJVW.mjs";import{s as c}from"./chunk-AYURCZHZ.mjs";import{b as d}from"./chunk-SAAOQW7P.mjs";import{a as v}from"./chunk-CDQ2BNUD.mjs";import{a}from"./chunk-PLUWBWJ2.mjs";var i=class i extends u{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&&i.onClose&&i.onClose(),this.closeUI()};this.handleLogin=async({type:e,anchor:o})=>{if(!i.loginHandler)throw new Error("Login callback not initialized. Please call `init()` first.");try{this.isSimpleLoginCallback(i.loginHandler)?(await(await s.create({type:e,anchor:o})).login(),i.loginHandler()):i.loginHandler({type:e,anchor:o}),await this.handleCloseUI({isLoginFinished:!0})}catch(t){console.error(t),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 i.instance||(i.instance=new i),i.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,t=[...Object.values(a).filter(n=>![a.none,a.webview].includes(n)),...e.map(n=>n.type)],P=e.reduce((n,r)=>(n[r.type]=r.name,n),{}),l={...v,...P};return(i.allowedProviders?i?.allowedProviders.filter(n=>t.includes(n)):t).map(n=>{let r=e.find(g=>g.type===n);return r||{name:n in l?l[n]:n,type:n}})}};i.loginHandler=null,i.onClose=null,i.allowedProviders=null;var p=i;export{p as a};
2
+ //# sourceMappingURL=chunk-SZ3AWPZH.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as n}from"./chunk-FFHHIKMI.mjs";import{a as t}from"./chunk-KK25BEMY.mjs";var i=class extends n{constructor({uiDataUpdateEvent:e,uiTag:s}){super({uiDataUpdateEvent:e,uiTag:s});this.isOpen=!1;this.data=this.getInitialData()}async openUI(){this.isOpen&&this.uiElement||(await super.init(),this.setIsSidePanelOpen(!0))}destroy(){if(this.setIsSidePanelOpen(!1),this.uiElement?.closeWithAnimation){this.uiElement?.closeWithAnimation?.().finally(()=>{super.destroy()});return}super.destroy()}closeUI(){this.resetData(),this.destroy()}setIsSidePanelOpen(e){this.isOpen=e,t(e)}};export{i as a};
2
- //# sourceMappingURL=chunk-XUADWD55.mjs.map
1
+ import{a as n}from"./chunk-Y7BUJTYP.mjs";import{a as t}from"./chunk-YJFGRD5R.mjs";var i=class extends n{constructor({uiDataUpdateEvent:e,uiTag:s}){super({uiDataUpdateEvent:e,uiTag:s});this.isOpen=!1;this.data=this.getInitialData()}async openUI(){this.isOpen&&this.uiElement||(await super.init(),this.setIsSidePanelOpen(!0))}destroy(){if(this.setIsSidePanelOpen(!1),this.uiElement?.closeWithAnimation){this.uiElement?.closeWithAnimation?.().finally(()=>{super.destroy()});return}super.destroy()}closeUI(){this.resetData(),this.destroy()}setIsSidePanelOpen(e){this.isOpen=e,t(e)}};export{i as a};
2
+ //# sourceMappingURL=chunk-T2BVHJVW.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as et}from"./chunk-OE5E647N.mjs";import{a as mt}from"./chunk-6UZHM5LW.mjs";import{a as S}from"./chunk-ZEQI7SII.mjs";import{a as Tt}from"./chunk-KIQFGAFN.mjs";import{a as w}from"./chunk-3MJNBS6H.mjs";import{a as It}from"./chunk-4ODPAHHA.mjs";import{a as gt}from"./chunk-SYNNW6IN.mjs";import{b as C}from"./chunk-Q62OP5VI.mjs";import{a as dt}from"./chunk-RN2VZOXB.mjs";import{a as ht}from"./chunk-MDVI45IV.mjs";import{a as ft}from"./chunk-W6P2TQ3N.mjs";import{a as f}from"./chunk-CUS6AHOH.mjs";import{a as X}from"./chunk-YJIAAC7S.mjs";import{a as ut}from"./chunk-T2BVHJVW.mjs";import{a as L}from"./chunk-QLEOO5UN.mjs";import{a as b,f as pt}from"./chunk-MUMHVEIZ.mjs";import{d as rt}from"./chunk-C25AGRYE.mjs";import{k as it,l as nt,n as at}from"./chunk-65L5EBBL.mjs";import{b as lt}from"./chunk-PBMO4Y47.mjs";import{a as A}from"./chunk-HORSXVIV.mjs";import{a as vt}from"./chunk-AIKQPMR3.mjs";import{a as Q}from"./chunk-UGUQSBY5.mjs";import{a as E}from"./chunk-QTKK6OSJ.mjs";import{a as J}from"./chunk-6ACLOUQ3.mjs";import{a as y}from"./chunk-NZYB675D.mjs";import{a as j}from"./chunk-YSCND2MX.mjs";import{a as yt}from"./chunk-NJN53MJV.mjs";import{a as Z,b as tt,g as ot,l as st}from"./chunk-2IUBMLF4.mjs";import{a as V,b as q,q as u,s as Y}from"./chunk-AYURCZHZ.mjs";import{c as H,f as $}from"./chunk-UERJ6AKK.mjs";import{b as g}from"./chunk-VNLGNNIL.mjs";import{b as v}from"./chunk-6JM4DPOH.mjs";import{b as G,c as K,f as z}from"./chunk-NTEMINYA.mjs";import{b as Et}from"./chunk-76URRONH.mjs";import{a as ct}from"./chunk-EEWLVNMR.mjs";import{a as I}from"./chunk-PLUWBWJ2.mjs";import W from"lodash.isequal";import Lt from"lodash.isequal";var Ft="NOTIFICATIONS_FEED_STORE_SUBSCRIBE",x=class e extends ut{constructor(){super({uiDataUpdateEvent:"OPEN_NOTIFICATIONS_FEED",uiTag:"mvx-notifications-feed"});this.store=u();this.initialData={pendingTransactions:[],historicTransactions:[]};this.data={...this.initialData}}static getInstance(){return e.instance||(e.instance=new e),e.instance}isNotificationsFeedOpen(){return this.isOpen}async openNotificationsFeed(){T.getInstance().hideToasts(),await this.openUI(),await this.updateDataAndNotifications();let s=this.store.subscribe(async({toasts:i,transactions:n},{toasts:a,transactions:c})=>{(!Lt(a.transactionToasts,i.transactionToasts)||!Lt(c,n))&&await this.updateDataAndNotifications()});this.unsubscribeFunctions.set(Ft,[s]),this.eventBus?.publish("OPEN_NOTIFICATIONS_FEED"),await this.updateDataAndNotifications()}async handleCloseUI(){let o=T.getInstance();this.closeUI(),await o.showToasts()}async setupEventListeners(){this.eventBus&&(this.subscribeToEventBus("CLOSE_NOTIFICATIONS_FEED",this.handleCloseUI.bind(this)),this.subscribeToEventBus("CLEAR_NOTIFICATIONS_FEED_HISTORY",this.handleClearNotificationsFeedHistory.bind(this)))}async updateDataAndNotifications(){let{transactions:o,account:s,toasts:i,network:n}=this.store.getState(),{pendingTransactionToasts:a}=await S({toastList:i,transactionsSessions:o,account:s});this.data.pendingTransactions=a,this.data.historicTransactions=await et.getTransactionsHistory({transactionsSessions:o,address:s.address,explorerAddress:n.network.explorerAddress,egldLabel:n.network.egldLabel}),await this.updateNotificationsFeed()}handleClearNotificationsFeedHistory(){rt(),this.resetData(),this.updateNotificationsFeed()}async updateNotificationsFeed(){this.eventBus&&(this.eventBus.publish("PENDING_TRANSACTIONS_UPDATE",this.data.pendingTransactions),this.eventBus.publish("TRANSACTIONS_HISTORY_UPDATE",this.data.historicTransactions))}};import R from"bignumber.js";var N=class e{constructor(){this.store=u();this.warningLogoutTimeoutRef=null;this.actualLogoutTimeoutRef=null;this.plannedLogoutTimeoutRef=null;this.plannedLogoutKey=null;this.init=async()=>{if(!this.shouldStart())return;let t=this.store.getState(),o=g(t),{isExpired:s}=E(o?.nativeAuthToken);s?h().logout():this.addPlannedLogout()};this.stop=()=>{clearTimeout(this.warningLogoutTimeoutRef??0),clearTimeout(this.plannedLogoutTimeoutRef??0),clearTimeout(this.actualLogoutTimeoutRef??0),this.warningLogoutTimeoutRef=null,this.plannedLogoutTimeoutRef=null,this.actualLogoutTimeoutRef=null,this.plannedLogoutKey=null};this.shouldStart=()=>{let t=this.store.getState(),o=g(t),s=$(t);return!!(o?.nativeAuthToken&&s)};this.addPlannedLogout=()=>{let t=h(),o=H(this.store.getState()),s=t.getType()===I.webview;if(!o||s)return;this.addLogoutWarning();let i=g(this.store.getState()),{secondsUntilExpires:n,expiresAt:a}=E(i?.nativeAuthToken),c=new R(String(n)),r=`${o}_${a}`,m=this.plannedLogoutKey===r;if(!(n&&c.isGreaterThan(0))||m)return;this.plannedLogoutKey=r,clearTimeout(this.plannedLogoutTimeoutRef??0);let d=c.times(1e3);this.actualLogoutTimeoutRef=setTimeout(()=>{T.getInstance().createCustomToast({toastId:"native-auth-logout",iconClassName:"warning",title:"Logging out",icon:"times",message:"Your session has expired!"}),this.actualLogoutTimeoutRef=null},d.toNumber()-3e3),this.plannedLogoutTimeoutRef=setTimeout(()=>{t.logout(),this.plannedLogoutTimeoutRef=null,this.plannedLogoutKey=null},d.toNumber())};this.addLogoutWarning=()=>{if(this.warningLogoutTimeoutRef)return;let t=v(this.store.getState()),o=g(this.store.getState()),{secondsUntilExpires:s}=E(o?.nativeAuthToken),i=new R(String(s)),n=i.times(1e3);if(!s||i.isLessThanOrEqualTo(0)||!t?.tokenExpirationToastWarningSeconds)return;let c=new R(t?.tokenExpirationToastWarningSeconds??0).times(1e3),r=i.times(1e3).minus(c),m=mt(n.toNumber()),p=r.isLessThanOrEqualTo(0)?0:r.toNumber();clearTimeout(this.warningLogoutTimeoutRef??0),this.warningLogoutTimeoutRef=setTimeout(()=>{T.getInstance().createCustomToast({toastId:"native-auth-expired",iconClassName:"warning",title:"Session Expiration Warning",icon:"hourglass",message:`Your session will expire in ${m}!`}),this.warningLogoutTimeoutRef=null},p)}}static getInstance(){return e.instance||(e.instance=new e),e.instance}};async function B({address:e,provider:t,apiAddress:o}){let s=await y({address:e,baseURL:o});if(!s)throw new Error("Account not found");lt({address:e,providerType:t.getType()});let i={...s,username:A(s.username),nonce:L(s)};b(i),await C(e),w(),s.shard!=null&&await Tt({shard:Number(s.shard),apiAddress:o})}async function kt(e){let{network:{apiAddress:t}}=f();await e.login();let o=await e.getAddress();if(!o)throw new Error("Address not found");return await B({address:o,provider:e,apiAddress:t}),{address:o}}async function Dt({provider:e,nativeAuthConfig:t,token:o}){let{network:{apiAddress:s}}=f(),i=Q(t),n=o;n||(n=await i.initialize({noCache:!0}));let{address:a,signature:c,...r}=await e.login({token:n});if(!a)return console.warn("Login cancelled."),null;if(!c)return console.error("Failed to sign login token"),null;let p=J(r?.accessToken)?r.accessToken:i.getToken({address:a,token:n,signature:c});q({loginToken:n,signature:c,nativeAuthToken:p});let d=await dt({loginToken:n,extraInfoData:{multisig:r?.multisig,impersonate:r?.impersonate},address:a});return await B({address:d,provider:e,apiAddress:s}),{address:d,signature:c}}async function St(e,t){let o=v(Y());if(o)return await Dt({provider:e,nativeAuthConfig:o,token:t?.token});let{address:s}=await kt(e);return await C(s),w(),{address:s}}var U={error:{title:"Error when signing".toString(),iconClassName:"danger",toastId:`${tt}-${Date.now()}`},warning:{title:"Signing canceled".toString(),iconClassName:"warning",toastId:`${Z}-${Date.now()}`}},Rt={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"},Bt=e=>{for(let[t,o]of Object.entries(Rt))if(e.includes(t))return o;return"Error when signing"};function _(e,t="error"){let o=e?.message,s=Bt(o),n=s!=="Error when signing"?"warning":t,a=Object.keys(U).includes(n)?U[n]:U.error,{toastId:c,iconClassName:r,title:m}=a;return M({toastId:c,duration:1e4,icon:"times",iconClassName:r,message:s,title:m}),s}async function bt({provider:e,transactions:t,options:o={}}){await Ct();let{isGuarded:s,activeGuardianAddress:i,nonce:n}=vt(),a=e.getType()===I.ledger,c=It({latestNonce:n,transactions:t}),r=i&&s&&!o.skipGuardian?c?.map(p=>(p.version=G.withTxOptions().valueOf(),p.options=z.withOptions({guarded:!0,...a?{hashSign:!0}:{}}).valueOf(),p.guardian=K.newFromBech32(i),p)):c,m=await e.signTransactions(r)??[];return pt(n+m.length),m}var O=class{constructor(t){this._isLoggingOut=!1;this.provider=t}init(){return this.provider.init()}async login(t){let o=await St(this.provider,t);return V(this.provider.getType()),wt(this),N.getInstance().init(),o}isInitialized(){return this.provider.isInitialized()}async logout(t={shouldBroadcastLogoutAcrossTabs:!0}){if(this._isLoggingOut)return console.warn("Logout already in progress"),!1;this._isLoggingOut=!0;let o=await gt({provider:this.provider,options:t});return this._isLoggingOut=!1,o}getType(){return this.provider.getType()}getProvider(){return this.provider}async signTransactions(t,o){try{return await bt({provider:this.provider,transactions:t,options:o})}catch(s){let i=_(s);throw new Error(i)}}async signMessage(t,o){try{return await ft({provider:this.provider,message:t,options:o})}catch(s){let i=_(s,"warning");throw new Error(i)}}async verifyMessage(t){return await ht(t)}cancelLogin(){this.provider.cancelLogin?.()}};var At=null;function wt(e){At=e}function h(){return At||new O(Et)}var Ut=async()=>{try{let e=X(),{network:t}=f();try{let o=await y({address:e,baseURL:t.apiAddress});if(o!=null){let s={...o,username:A(o.username),nonce:L(o)};return b(s),s}}catch(o){console.error("Failed getting account ",o)}}catch(e){console.error("Failed getting address ",e)}return null};async function Ct(){let e=h();if(e==null)throw"Provider not initialized";try{if(!e.init)throw"Current provider does not have init() function";return await e.init()?Ut():void 0}catch(t){console.error("Failed initializing provider ",t)}}var F={},l={},_t=(e,t)=>{u().setState(({toasts:o})=>{let s=o.customToasts.length>0?Math.max(...o.customToasts.map(r=>parseInt(r.toastId.split("-").pop()??"0"))):0,i=t??`custom-toast-${s+1}`,n=o.customToasts.findIndex(r=>r.toastId===i),a={...e,toastId:i};if(n!==-1){o.customToasts[n]=a;return}o.customToasts.push({...a,toastId:i})},!1,"addCustomToast")},P=e=>{u().setState(({toasts:t})=>{t.customToasts=t.customToasts.filter(o=>o.toastId!==e)},!1,"removeCustomToast")},xt=()=>{u().setState(({toasts:e})=>{e.customToasts=[]},!1,"removeAllCustomToasts")},zs=()=>{u().setState(({toasts:e})=>{e.transactionToasts=[]})},Nt=({toastId:e,totalDuration:t})=>{let o="";return u().setState(({toasts:s})=>{let i=s.transactionToasts.length>0?Math.max(...s.transactionToasts.map(n=>parseInt(n.toastId.split("-").pop()??"0"))):0;o=e??`transaction-toast-${i+1}`,s.transactionToasts.push({startTime:j(),endTime:yt(t),toastId:o})},!1,"addTransactionToast"),o},k=e=>{u().setState(({toasts:t})=>{t.transactionToasts=t.transactionToasts.filter(o=>o.toastId!==e)},!1,"removeTransactionToast"),delete l[e],delete F[e]},M=e=>{let{toasts:t}=u().getState(),o=t.customToasts.length>0?Math.max(...t.customToasts.map(i=>parseInt(i.toastId.split("-").pop()??"0"))):0,s=e.toastId||`custom-toast-${o+1}`;return e.onClose&&(l[s]=e.onClose),e.instantiateToastElement?(F[s]=e.instantiateToastElement,u().setState(({toasts:i})=>{let n=i.customToasts.findIndex(r=>r.toastId===s),a={...e,instantiateToastElement:null,toastId:s};n!==-1?i.customToasts[n]=a:i.customToasts.push(a)},!1,"createCustomToast"),s):(_t(e,s),s)};var Mt=1e4,D=class{constructor(){this.timeoutIntervals=new Map;this.successfulToastLifetime=Mt;this.start=t=>{if(this.stop(t),this.successfulToastLifetime<=0)return;let o=setTimeout(()=>{k(t)},this.successfulToastLifetime);this.timeoutIntervals.set(t,o)};this.startWithCustomDuration=(t,o)=>{if(this.stop(t),o<=0)return;let s=setTimeout(()=>{P(t);let i=l[t];i?.()},o);this.timeoutIntervals.set(t,s)};this.stop=t=>{let o=this.timeoutIntervals.get(t);o&&(clearTimeout(o),this.timeoutIntervals.delete(t))}}init({successfulToastLifetime:t}){this.successfulToastLifetime=t||Mt}destroy(){this.timeoutIntervals.forEach(t=>clearTimeout(t)),this.timeoutIntervals.clear()}};var T=class e{constructor(){this.isCreatingElement=!1;this.toastsElement=null;this.transactionToasts=[];this.customToasts=[];this.storeToastsSubscription=()=>null;this.eventBusUnsubscribeFunctions=[];this.eventBus=null;this.store=u();this.destroy(),this.lifetimeManager=new D,this.notificationsFeedManager=x.getInstance()}async init({successfulToastLifetime:t=5e3}={}){this.successfulToastLifetime=t,this.lifetimeManager.init({successfulToastLifetime:t}),await this.updateTransactionToastsList(),await this.updateCustomToastList(),await this.subscribeToEventBusNotifications(),this.storeToastsSubscription=this.store.subscribe(async({toasts:o,transactions:s},{toasts:i,transactions:n})=>{(!W(i.transactionToasts,o.transactionToasts)||!W(n,s))&&await this.updateTransactionToastsList(),W(i.customToasts,o.customToasts)||await this.updateCustomToastList()})}static getInstance(){return e.instance||(e.instance=new e),e.instance}handleCompletedTransaction(t){let{transactions:o}=this.store.getState(),s=o[t];if(!s)return!1;let{status:i}=s,n=at(i),a=nt(i),c=it(i),r=a||c||n;return r?(this.successfulToastLifetime&&this.lifetimeManager.start(t),r):(this.lifetimeManager.stop(t),r)}async createTransactionToast(t,o){let s=Nt({toastId:t,totalDuration:o});return this.handleCompletedTransaction(t),await this.updateTransactionToastsList(),s}createCustomToast(t){let o=M(t);return this.updateCustomToastList(),o}async updateTransactionToastsList(){let{toasts:t,transactions:o,account:s}=this.store.getState(),{pendingTransactionToasts:i,completedTransactionToasts:n}=await S({toastList:t,transactionsSessions:o,account:s});this.transactionToasts=[...i,...n];for(let a of t.transactionToasts)this.handleCompletedTransaction(a.toastId);await this.publishTransactionToasts()}async updateCustomToastList(){let{toasts:t}=this.store.getState();this.customToasts=[];for(let o of t.customToasts){let i="message"in o?{...o}:{...o,instantiateToastElement:F[o.toastId]};this.customToasts.push(i),o.duration&&this.lifetimeManager.startWithCustomDuration(o.toastId,o.duration)}this.eventBus?.publish("CUSTOM_TOAST_DATA_UPDATE",this.customToasts)}async createToastListElement(){return this.toastsElement?this.toastsElement:(this.isCreatingElement||(this.isCreatingElement=!0,this.toastsElement=await ct.create({name:"mvx-toast-list"}),this.isCreatingElement=!1),this.toastsElement)}handleTransactionToastClose(t){this.handleCompletedTransaction(t)&&k(t)}async subscribeToEventBusNotifications(){let t=await this.createToastListElement();if(t){if(this.eventBus=await t.getEventBus(),!this.eventBus)throw new Error("eventBus is not initialized");this.eventBus.subscribe("CLOSE_TOAST",this.closeToast.bind(this)),this.eventBusUnsubscribeFunctions.push(()=>{this.eventBus?.unsubscribe("CLOSE_TOAST",this.closeToast.bind(this))}),this.eventBus.subscribe("OPEN_NOTIFICATIONS_FEED",this.handleOpenNotificationsFeed.bind(this)),this.eventBusUnsubscribeFunctions.push(()=>{this.eventBus?.unsubscribe("OPEN_NOTIFICATIONS_FEED",this.handleOpenNotificationsFeed.bind(this))})}}async showToasts(){this.eventBus?.publish("SHOW_TOAST_LIST",null),await this.updateCustomToastList(),await this.updateTransactionToastsList()}hideToasts(){this.eventBus?.publish("HIDE_TOAST_LIST",null)}async handleOpenNotificationsFeed(){this.notificationsFeedManager.openNotificationsFeed()}closeToast(t){if(this.customToasts.find(s=>s.toastId===t)){this.lifetimeManager.stop(t);let s=l[t];s?.(),P(t);return}this.handleTransactionToastClose(t)}async publishTransactionToasts(){if(this.notificationsFeedManager.isNotificationsFeedOpen()&&this.eventBus){this.eventBus.publish("TRANSACTION_TOAST_DATA_UPDATE",this.transactionToasts),this.hideToasts();return}if(!this.eventBus){let t=await this.createToastListElement();if(!t)return;this.eventBus=await t.getEventBus()}this.eventBus.publish("TRANSACTION_TOAST_DATA_UPDATE",this.transactionToasts)}destroy(){this.storeToastsSubscription(),this.lifetimeManager?.destroy(),this.notificationsFeedManager?.destroy(),xt(),this.eventBusUnsubscribeFunctions.forEach(t=>t()),this.eventBusUnsubscribeFunctions=[]}};export{x as a,F as b,l as c,_t as d,P as e,xt as f,zs as g,Nt as h,k as i,M as j,D as k,T as l,N as m,B as n,St as o,_ as p,bt as q,O as r,wt as s,h as t,Ct as u};
2
+ //# sourceMappingURL=chunk-T3JST5WU.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/managers/internal/ToastManager/ToastManager.ts", "../../src/managers/NotificationsFeedManager/NotificationsFeedManager.ts", "../../src/managers/LogoutManager/LogoutManager.ts", "../../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", "../../src/managers/internal/ToastManager/helpers/LifetimeManager.ts"],
4
+ "sourcesContent": ["import isEqual from 'lodash.isequal';\nimport { DEFAULT_TOAST_LIEFTIME } from 'constants/transactions.constants';\nimport { UITagsEnum } from 'constants/UITags.enum';\nimport { MvxToastList } from 'lib/sdkDappUi';\nimport { NotificationsFeedManager } from 'managers/NotificationsFeedManager/NotificationsFeedManager';\nimport {\n customToastCloseHandlersDictionary,\n customToastComponentDictionary,\n removeAllCustomToasts,\n removeCustomToast,\n removeTransactionToast,\n addTransactionToast,\n createCustomToast\n} from 'store/actions/toasts/toastsActions';\nimport {\n getIsTransactionFailed,\n getIsTransactionSuccessful,\n getIsTransactionTimedOut\n} from 'store/actions/transactions/transactionStateByStatus';\n\nimport { CustomToastType } from 'store/slices/toast/toastSlice.types';\nimport { getStore } from 'store/store';\nimport { IEventBus } from 'types/manager.types';\nimport { ProviderErrorsEnum } from 'types/provider.types';\nimport { ComponentFactory } from 'utils/ComponentFactory';\nimport { createToastsFromTransactions } from './helpers/createToastsFromTransactions';\nimport { LifetimeManager } from './helpers/LifetimeManager';\nimport { ITransactionToast, ToastEventsEnum } from './types';\n\ninterface IToastManager {\n successfulToastLifetime?: number;\n}\n\nexport class ToastManager {\n private readonly lifetimeManager: LifetimeManager;\n private isCreatingElement = false;\n private static instance: ToastManager;\n private toastsElement: MvxToastList | null = null;\n private transactionToasts: ITransactionToast[] = [];\n private customToasts: CustomToastType[] = [];\n private successfulToastLifetime?: number;\n private storeToastsSubscription: () => void = () => null;\n private readonly notificationsFeedManager: NotificationsFeedManager;\n private eventBusUnsubscribeFunctions: (() => void)[] = [];\n private eventBus: IEventBus<\n ITransactionToast[] | CustomToastType[] | null\n > | null = null;\n\n store = getStore();\n\n constructor() {\n this.destroy();\n this.lifetimeManager = new LifetimeManager();\n\n this.notificationsFeedManager = NotificationsFeedManager.getInstance();\n }\n\n public async init({\n successfulToastLifetime = DEFAULT_TOAST_LIEFTIME\n }: IToastManager = {}) {\n this.successfulToastLifetime = successfulToastLifetime;\n\n this.lifetimeManager.init({ successfulToastLifetime });\n\n await this.updateTransactionToastsList();\n await this.updateCustomToastList();\n\n await this.subscribeToEventBusNotifications();\n\n this.storeToastsSubscription = this.store.subscribe(\n async (\n { toasts, transactions },\n { toasts: prevToasts, transactions: prevTransactions }\n ) => {\n if (\n !isEqual(prevToasts.transactionToasts, toasts.transactionToasts) ||\n !isEqual(prevTransactions, transactions)\n ) {\n await this.updateTransactionToastsList();\n }\n\n if (!isEqual(prevToasts.customToasts, toasts.customToasts)) {\n await this.updateCustomToastList();\n }\n }\n );\n }\n\n public static getInstance(): ToastManager {\n if (!ToastManager.instance) {\n ToastManager.instance = new ToastManager();\n }\n return ToastManager.instance;\n }\n\n private handleCompletedTransaction(toastId: string): boolean {\n const { transactions } = this.store.getState();\n const transaction = transactions[toastId];\n\n if (!transaction) {\n return false;\n }\n\n const { status } = transaction;\n const isTimedOut = getIsTransactionTimedOut(status);\n const isFailed = getIsTransactionFailed(status);\n const isSuccessful = getIsTransactionSuccessful(status);\n const isCompleted = isFailed || isSuccessful || isTimedOut;\n\n if (isCompleted) {\n if (this.successfulToastLifetime) {\n this.lifetimeManager.start(toastId);\n }\n return isCompleted;\n }\n\n this.lifetimeManager.stop(toastId);\n return isCompleted;\n }\n\n public async createTransactionToast(\n toastId: string,\n totalDuration: number\n ): Promise<string> {\n const newToastId = addTransactionToast({\n toastId,\n totalDuration\n });\n\n this.handleCompletedTransaction(toastId);\n await this.updateTransactionToastsList();\n return newToastId;\n }\n\n public createCustomToast(toast: CustomToastType): string {\n const toastId = createCustomToast(toast);\n this.updateCustomToastList();\n return toastId;\n }\n\n private async updateTransactionToastsList() {\n const {\n toasts: toastList,\n transactions: transactionsSessions,\n account\n } = this.store.getState();\n\n const { pendingTransactionToasts, completedTransactionToasts } =\n await createToastsFromTransactions({\n toastList,\n transactionsSessions,\n account\n });\n\n this.transactionToasts = [\n ...pendingTransactionToasts,\n ...completedTransactionToasts\n ];\n\n for (const toast of toastList.transactionToasts) {\n this.handleCompletedTransaction(toast.toastId);\n }\n\n await this.publishTransactionToasts();\n }\n\n private async updateCustomToastList() {\n const { toasts: toastList } = this.store.getState();\n this.customToasts = [];\n\n for (const toast of toastList.customToasts) {\n const isSimpleToast = 'message' in toast;\n\n const newToast: CustomToastType = isSimpleToast\n ? { ...toast }\n : {\n ...toast,\n instantiateToastElement:\n customToastComponentDictionary[toast.toastId]\n };\n this.customToasts.push(newToast);\n\n if (toast.duration) {\n this.lifetimeManager.startWithCustomDuration(\n toast.toastId,\n toast.duration\n );\n }\n }\n this.eventBus?.publish(\n ToastEventsEnum.CUSTOM_TOAST_DATA_UPDATE,\n this.customToasts\n );\n }\n\n private async createToastListElement(): Promise<MvxToastList | null> {\n if (this.toastsElement) {\n return this.toastsElement;\n }\n\n if (!this.isCreatingElement) {\n this.isCreatingElement = true;\n\n this.toastsElement = await ComponentFactory.create<MvxToastList>({\n name: UITagsEnum.TOAST_LIST\n });\n\n this.isCreatingElement = false;\n }\n\n return this.toastsElement;\n }\n\n private handleTransactionToastClose(toastId: string) {\n const isCompleted = this.handleCompletedTransaction(toastId);\n\n if (isCompleted) {\n removeTransactionToast(toastId);\n }\n }\n\n private async subscribeToEventBusNotifications() {\n const toastsElement = await this.createToastListElement();\n\n if (!toastsElement) {\n return;\n }\n\n this.eventBus = await toastsElement.getEventBus();\n if (!this.eventBus) {\n throw new Error(ProviderErrorsEnum.eventBusError);\n }\n\n this.eventBus.subscribe(ToastEventsEnum.CLOSE, this.closeToast.bind(this));\n\n this.eventBusUnsubscribeFunctions.push(() => {\n this.eventBus?.unsubscribe(\n ToastEventsEnum.CLOSE,\n this.closeToast.bind(this)\n );\n });\n\n this.eventBus.subscribe(\n ToastEventsEnum.OPEN_NOTIFICATIONS_FEED,\n this.handleOpenNotificationsFeed.bind(this)\n );\n\n this.eventBusUnsubscribeFunctions.push(() => {\n this.eventBus?.unsubscribe(\n ToastEventsEnum.OPEN_NOTIFICATIONS_FEED,\n this.handleOpenNotificationsFeed.bind(this)\n );\n });\n }\n\n public async showToasts() {\n this.eventBus?.publish(ToastEventsEnum.SHOW, null);\n\n await this.updateCustomToastList();\n await this.updateTransactionToastsList();\n }\n\n public hideToasts() {\n this.eventBus?.publish(ToastEventsEnum.HIDE, null);\n }\n\n private async handleOpenNotificationsFeed() {\n this.notificationsFeedManager.openNotificationsFeed();\n }\n\n public closeToast(toastId: string) {\n const customToast = this.customToasts.find(\n (toast) => toast.toastId === toastId\n );\n\n if (customToast) {\n this.lifetimeManager.stop(toastId);\n const handleClose = customToastCloseHandlersDictionary[toastId];\n handleClose?.();\n removeCustomToast(toastId);\n return;\n }\n\n this.handleTransactionToastClose(toastId);\n }\n\n private async publishTransactionToasts() {\n if (\n this.notificationsFeedManager.isNotificationsFeedOpen() &&\n this.eventBus\n ) {\n this.eventBus.publish(\n ToastEventsEnum.TRANSACTION_TOAST_DATA_UPDATE,\n this.transactionToasts\n );\n\n this.hideToasts();\n return;\n }\n\n if (!this.eventBus) {\n const toastsElement = await this.createToastListElement();\n\n if (!toastsElement) {\n return;\n }\n\n this.eventBus = await toastsElement.getEventBus();\n }\n\n this.eventBus.publish(\n ToastEventsEnum.TRANSACTION_TOAST_DATA_UPDATE,\n this.transactionToasts\n );\n }\n\n public destroy() {\n this.storeToastsSubscription();\n this.lifetimeManager?.destroy();\n this.notificationsFeedManager?.destroy();\n removeAllCustomToasts();\n this.eventBusUnsubscribeFunctions.forEach((unsubscribe) => unsubscribe());\n this.eventBusUnsubscribeFunctions = [];\n }\n}\n", "import isEqual from 'lodash.isequal';\nimport { UITagsEnum } from 'constants/UITags.enum';\nimport { TransactionsHistoryController } from 'controllers/TransactionsHistoryController';\nimport { ITransactionListItem, MvxNotificationsFeed } from 'lib/sdkDappUi';\nimport { clearCompletedTransactions } from 'store/actions/transactions/transactionsActions';\nimport { getStore } from 'store/store';\nimport { NotificationsFeedEventsEnum } from './types';\nimport { ToastManager } from '../internal';\nimport { SidePanelBaseManager } from '../internal/SidePanelBaseManager/SidePanelBaseManager';\nimport { createToastsFromTransactions } from '../internal/ToastManager/helpers/createToastsFromTransactions';\nimport { ITransactionToast } from '../internal/ToastManager/types';\n\ninterface INotificationsFeedManagerData {\n pendingTransactions: ITransactionToast[];\n historicTransactions: ITransactionListItem[];\n}\n\nconst NOTIFICATIONS_FEED_STORE_SUBSCRIBE = 'NOTIFICATIONS_FEED_STORE_SUBSCRIBE';\n\nexport class NotificationsFeedManager extends SidePanelBaseManager<\n MvxNotificationsFeed,\n INotificationsFeedManagerData,\n NotificationsFeedEventsEnum | typeof NOTIFICATIONS_FEED_STORE_SUBSCRIBE\n> {\n private static instance: NotificationsFeedManager;\n private readonly store = getStore();\n\n protected initialData: INotificationsFeedManagerData = {\n pendingTransactions: [],\n historicTransactions: []\n };\n\n public static getInstance(): NotificationsFeedManager {\n if (!NotificationsFeedManager.instance) {\n NotificationsFeedManager.instance = new NotificationsFeedManager();\n }\n return NotificationsFeedManager.instance;\n }\n\n constructor() {\n super({\n uiDataUpdateEvent: NotificationsFeedEventsEnum.OPEN,\n uiTag: UITagsEnum.NOTIFICATIONS_FEED\n });\n this.data = { ...this.initialData };\n }\n\n public isNotificationsFeedOpen(): boolean {\n return this.isOpen;\n }\n\n /**\n * Open the notifications feed and toggle off the toast manager.\n */\n public async openNotificationsFeed(): Promise<void> {\n const toastManager = ToastManager.getInstance();\n toastManager.hideToasts();\n await this.openUI();\n await this.updateDataAndNotifications();\n\n const storeToastsUnsubscribe = this.store.subscribe(\n async (\n { toasts, transactions },\n { toasts: prevToasts, transactions: prevTransactions }\n ) => {\n if (\n !isEqual(prevToasts.transactionToasts, toasts.transactionToasts) ||\n !isEqual(prevTransactions, transactions)\n ) {\n await this.updateDataAndNotifications();\n }\n }\n );\n this.unsubscribeFunctions.set(NOTIFICATIONS_FEED_STORE_SUBSCRIBE, [\n storeToastsUnsubscribe\n ]);\n\n this.eventBus?.publish(NotificationsFeedEventsEnum.OPEN);\n await this.updateDataAndNotifications();\n }\n\n /**\n * Close the notifications feed and toggle on the toast manager.\n */\n protected async handleCloseUI() {\n const toastManager = ToastManager.getInstance();\n this.closeUI();\n await toastManager.showToasts();\n }\n\n protected async setupEventListeners() {\n if (!this.eventBus) {\n return;\n }\n\n this.subscribeToEventBus(\n NotificationsFeedEventsEnum.CLOSE,\n this.handleCloseUI.bind(this)\n );\n\n this.subscribeToEventBus(\n NotificationsFeedEventsEnum.CLEAR,\n this.handleClearNotificationsFeedHistory.bind(this)\n );\n }\n\n protected async updateDataAndNotifications() {\n const { transactions, account, toasts, network } = this.store.getState();\n\n const { pendingTransactionToasts } = await createToastsFromTransactions({\n toastList: toasts,\n transactionsSessions: transactions,\n account\n });\n\n this.data.pendingTransactions = pendingTransactionToasts;\n\n this.data.historicTransactions =\n await TransactionsHistoryController.getTransactionsHistory({\n transactionsSessions: transactions,\n address: account.address,\n explorerAddress: network.network.explorerAddress,\n egldLabel: network.network.egldLabel\n });\n\n await this.updateNotificationsFeed();\n }\n\n private handleClearNotificationsFeedHistory() {\n clearCompletedTransactions();\n this.resetData();\n this.updateNotificationsFeed();\n }\n\n private async updateNotificationsFeed() {\n if (!this.eventBus) {\n return;\n }\n\n this.eventBus.publish(\n NotificationsFeedEventsEnum.PENDING_TRANSACTIONS_UPDATE,\n this.data.pendingTransactions\n );\n\n this.eventBus.publish(\n NotificationsFeedEventsEnum.TRANSACTIONS_HISTORY_UPDATE,\n this.data.historicTransactions\n );\n }\n}\n", "import BigNumber from 'bignumber.js';\nimport { ToastIconsEnum } from 'managers/internal/ToastManager/helpers/getToastDataStateByStatus';\nimport { ToastManager } from 'managers/internal/ToastManager/ToastManager';\nimport { getAccountProvider } from 'providers/helpers/accountProvider';\nimport { ProviderTypeEnum } from 'providers/types/providerFactory.types';\nimport { getTokenExpiration } from 'services/nativeAuth/methods/getTokenExpiration';\nimport {\n addressSelector,\n isLoggedInSelector\n} from 'store/selectors/accountSelectors';\nimport { nativeAuthConfigSelector } from 'store/selectors/configSelectors';\nimport { tokenLoginSelector } from 'store/selectors/loginInfoSelectors';\nimport { getStore } from 'store/store';\nimport { getHumanReadableTokenExpirationTime } from './helpers/getHumanReadableTokenExpirationTime';\n\nexport class LogoutManager {\n private static instance: LogoutManager;\n private store = getStore();\n private warningLogoutTimeoutRef: ReturnType<typeof setInterval> | null = null;\n private actualLogoutTimeoutRef: ReturnType<typeof setInterval> | null = null;\n private plannedLogoutTimeoutRef: ReturnType<typeof setInterval> | null = null;\n private plannedLogoutKey: string | null = null;\n\n public static getInstance(): LogoutManager {\n if (!LogoutManager.instance) {\n LogoutManager.instance = new LogoutManager();\n }\n return LogoutManager.instance;\n }\n\n private constructor() {}\n\n public init = async () => {\n if (!this.shouldStart()) {\n return;\n }\n\n const state = this.store.getState();\n const tokenLogin = tokenLoginSelector(state);\n\n const { isExpired: isNativeAuthTokenExpired } = getTokenExpiration(\n tokenLogin?.nativeAuthToken\n );\n\n if (isNativeAuthTokenExpired) {\n const provider = getAccountProvider();\n provider.logout();\n } else {\n this.addPlannedLogout();\n }\n };\n\n public stop = () => {\n clearTimeout(this.warningLogoutTimeoutRef ?? 0);\n clearTimeout(this.plannedLogoutTimeoutRef ?? 0);\n clearTimeout(this.actualLogoutTimeoutRef ?? 0);\n\n this.warningLogoutTimeoutRef = null;\n this.plannedLogoutTimeoutRef = null;\n this.actualLogoutTimeoutRef = null;\n this.plannedLogoutKey = null;\n };\n\n private readonly shouldStart = (): boolean => {\n const state = this.store.getState();\n const tokenLogin = tokenLoginSelector(state);\n const isLoggedIn = isLoggedInSelector(state);\n return Boolean(tokenLogin?.nativeAuthToken && isLoggedIn);\n };\n\n private addPlannedLogout = () => {\n const provider = getAccountProvider();\n const address = addressSelector(this.store.getState());\n const isWebviewLogin = provider.getType() === ProviderTypeEnum.webview;\n\n // prevent unexpected logout if webview login\n if (!address || isWebviewLogin) {\n return;\n }\n\n this.addLogoutWarning();\n\n const tokenLogin = tokenLoginSelector(this.store.getState());\n\n const { secondsUntilExpires, expiresAt } = getTokenExpiration(\n tokenLogin?.nativeAuthToken\n );\n\n // Handle the actual logout functionality.\n const secondsUntilExpiresBN = new BigNumber(String(secondsUntilExpires));\n const plannedLogoutKey = `${address}_${expiresAt}`;\n const plannedLogoutSet = this.plannedLogoutKey === plannedLogoutKey;\n\n const isValidInterval =\n secondsUntilExpires && secondsUntilExpiresBN.isGreaterThan(0);\n\n if (!isValidInterval || plannedLogoutSet) {\n return;\n }\n\n this.plannedLogoutKey = plannedLogoutKey;\n\n clearTimeout(this.plannedLogoutTimeoutRef ?? 0);\n const millisecondsUntilLogout = secondsUntilExpiresBN.times(1000);\n\n this.actualLogoutTimeoutRef = setTimeout(() => {\n ToastManager.getInstance().createCustomToast({\n toastId: 'native-auth-logout',\n iconClassName: 'warning',\n title: 'Logging out',\n icon: ToastIconsEnum.times,\n message: 'Your session has expired!'\n });\n this.actualLogoutTimeoutRef = null;\n }, millisecondsUntilLogout.toNumber() - 3000);\n\n this.plannedLogoutTimeoutRef = setTimeout(() => {\n provider.logout();\n this.plannedLogoutTimeoutRef = null;\n this.plannedLogoutKey = null;\n }, millisecondsUntilLogout.toNumber());\n };\n\n private readonly addLogoutWarning = () => {\n if (this.warningLogoutTimeoutRef) {\n return;\n }\n\n const nativeAuthConfig = nativeAuthConfigSelector(this.store.getState());\n const tokenLogin = tokenLoginSelector(this.store.getState());\n\n const { secondsUntilExpires } = getTokenExpiration(\n tokenLogin?.nativeAuthToken\n );\n\n const secondsUntilExpiresBN = new BigNumber(String(secondsUntilExpires));\n const millisecondsUntilLogout = secondsUntilExpiresBN.times(1000);\n\n if (\n !secondsUntilExpires ||\n secondsUntilExpiresBN.isLessThanOrEqualTo(0) ||\n !nativeAuthConfig?.tokenExpirationToastWarningSeconds\n ) {\n return;\n }\n\n const logoutWarningOffsetSeconds = new BigNumber(\n nativeAuthConfig?.tokenExpirationToastWarningSeconds ?? 0\n );\n\n const logoutWarningOffsetMilliseconds =\n logoutWarningOffsetSeconds.times(1000);\n\n const millisecondsUntilLogoutWarning = secondsUntilExpiresBN\n .times(1000)\n .minus(logoutWarningOffsetMilliseconds);\n\n const readableMinutesUntilLogout = getHumanReadableTokenExpirationTime(\n millisecondsUntilLogout.toNumber()\n );\n\n const timeoutUntilLogoutWarning =\n millisecondsUntilLogoutWarning.isLessThanOrEqualTo(0)\n ? 0\n : millisecondsUntilLogoutWarning.toNumber();\n\n clearTimeout(this.warningLogoutTimeoutRef ?? 0);\n\n this.warningLogoutTimeoutRef = setTimeout(() => {\n ToastManager.getInstance().createCustomToast({\n toastId: 'native-auth-expired',\n iconClassName: 'warning',\n title: 'Session Expiration Warning',\n icon: ToastIconsEnum.hourglass,\n message: `Your session will expire in ${readableMinutesUntilLogout}!`\n });\n this.warningLogoutTimeoutRef = null;\n }, timeoutUntilLogoutWarning);\n };\n}\n", "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 { decodeNativeAuthToken } from 'services/nativeAuth/helpers/decodeNativeAuthToken';\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 // nativeAuthToken received from hub login\n const decodedToken = decodeNativeAuthToken(loginResult?.accessToken);\n\n const nativeAuthToken = decodedToken\n ? loginResult.accessToken\n : 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 { LogoutManager } from 'managers/LogoutManager/LogoutManager';\nimport { setAccountProvider } from 'providers/helpers/accountProvider';\nimport { setProviderType } from 'store/actions/loginInfo/loginInfoActions';\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 private _isLoggingOut = false;\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 setProviderType(this.provider.getType());\n setAccountProvider(this);\n LogoutManager.getInstance().init();\n return data;\n }\n\n isInitialized(): boolean {\n return this.provider.isInitialized();\n }\n\n async logout(\n options = {\n shouldBroadcastLogoutAcrossTabs: true\n }\n ): Promise<boolean> {\n if (this._isLoggingOut) {\n console.warn('Logout already in progress');\n return false;\n }\n\n this._isLoggingOut = true;\n\n const isLoggedOut = await logout({ provider: this.provider, options });\n\n this._isLoggingOut = false;\n\n return isLoggedOut;\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}): string => {\n let newToastId: string = '';\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 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 return newToastId;\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", "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 = 10_000;\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": "8iDAAA,OAAOA,MAAa,iBCApB,OAAOC,OAAa,iBAiBpB,IAAMC,GAAqC,qCAE9BC,EAAN,MAAMC,UAAiCC,EAI5C,CAgBA,aAAc,CACZ,MAAM,CACJ,4CACA,8BACF,CAAC,EAlBH,KAAiB,MAAQC,EAAS,EAElC,KAAU,YAA6C,CACrD,oBAAqB,CAAC,EACtB,qBAAsB,CAAC,CACzB,EAcE,KAAK,KAAO,CAAE,GAAG,KAAK,WAAY,CACpC,CAbA,OAAc,aAAwC,CACpD,OAAKF,EAAyB,WAC5BA,EAAyB,SAAW,IAAIA,GAEnCA,EAAyB,QAClC,CAUO,yBAAmC,CACxC,OAAO,KAAK,MACd,CAKA,MAAa,uBAAuC,CAC7BG,EAAa,YAAY,EACjC,WAAW,EACxB,MAAM,KAAK,OAAO,EAClB,MAAM,KAAK,2BAA2B,EAEtC,IAAMC,EAAyB,KAAK,MAAM,UACxC,MACE,CAAE,OAAAC,EAAQ,aAAAC,CAAa,EACvB,CAAE,OAAQC,EAAY,aAAcC,CAAiB,IAClD,EAED,CAACC,GAAQF,EAAW,kBAAmBF,EAAO,iBAAiB,GAC/D,CAACI,GAAQD,EAAkBF,CAAY,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AU,0BAA8B,IAAI,CACnD,CAEA,MAAc,6BAA8B,CAC1C,KAAK,yBAAyB,sBAAsB,CACtD,CAEO,WAAWzB,EAAiB,CAKjC,GAJoB,KAAK,aAAa,KACnCa,GAAUA,EAAM,UAAYb,CAC/B,EAEiB,CACf,KAAK,gBAAgB,KAAKA,CAAO,EACjC,IAAM0B,EAAcC,EAAmC3B,CAAO,EAC9D0B,IAAc,EACdE,EAAkB5B,CAAO,EACzB,MACF,CAEA,KAAK,4BAA4BA,CAAO,CAC1C,CAEA,MAAc,0BAA2B,CACvC,GACE,KAAK,yBAAyB,wBAAwB,GACtD,KAAK,SACL,CACA,KAAK,SAAS,wCAEZ,KAAK,iBACP,EAEA,KAAK,WAAW,EAChB,MACF,CAEA,GAAI,CAAC,KAAK,SAAU,CAClB,IAAMyB,EAAgB,MAAM,KAAK,uBAAuB,EAExD,GAAI,CAACA,EACH,OAGF,KAAK,SAAW,MAAMA,EAAc,YAAY,CAClD,CAEA,KAAK,SAAS,wCAEZ,KAAK,iBACP,CACF,CAEO,SAAU,CACf,KAAK,wBAAwB,EAC7B,KAAK,iBAAiB,QAAQ,EAC9B,KAAK,0BAA0B,QAAQ,EACvCI,GAAsB,EACtB,KAAK,6BAA6B,QAASC,GAAgBA,EAAY,CAAC,EACxE,KAAK,6BAA+B,CAAC,CACvC,CACF",
6
+ "names": ["isEqual", "isEqual", "NOTIFICATIONS_FEED_STORE_SUBSCRIBE", "NotificationsFeedManager", "_NotificationsFeedManager", "SidePanelBaseManager", "getStore", "ToastManager", "storeToastsUnsubscribe", "toasts", "transactions", "prevToasts", "prevTransactions", "isEqual", "toastManager", "account", "network", "pendingTransactionToasts", "createToastsFromTransactions", "TransactionsHistoryController", "clearCompletedTransactions", "BigNumber", "LogoutManager", "_LogoutManager", "getStore", "state", "tokenLogin", "tokenLoginSelector", "isNativeAuthTokenExpired", "getTokenExpiration", "getAccountProvider", "isLoggedIn", "isLoggedInSelector", "provider", "address", "addressSelector", "isWebviewLogin", "ProviderTypeEnum", "secondsUntilExpires", "expiresAt", "secondsUntilExpiresBN", "BigNumber", "plannedLogoutKey", "plannedLogoutSet", "millisecondsUntilLogout", "ToastManager", "nativeAuthConfig", "nativeAuthConfigSelector", "logoutWarningOffsetMilliseconds", "millisecondsUntilLogoutWarning", "readableMinutesUntilLogout", "getHumanReadableTokenExpirationTime", "timeoutUntilLogoutWarning", "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", "decodeNativeAuthToken", "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", "data", "login", "setProviderType", "setAccountProvider", "LogoutManager", "isLoggedOut", "logout", "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", "DEFAULT_SUCCESSFUL_TOAST_LIFETIME", "LifetimeManager", "toastId", "timeout", "removeTransactionToast", "duration", "removeCustomToast", "handleClose", "customToastCloseHandlersDictionary", "successfulToastLifetime", "interval", "ToastManager", "_ToastManager", "getStore", "LifetimeManager", "NotificationsFeedManager", "successfulToastLifetime", "toasts", "transactions", "prevToasts", "prevTransactions", "isEqual", "toastId", "transaction", "status", "isTimedOut", "getIsTransactionTimedOut", "isFailed", "getIsTransactionFailed", "isSuccessful", "getIsTransactionSuccessful", "isCompleted", "totalDuration", "newToastId", "addTransactionToast", "toast", "createCustomToast", "toastList", "transactionsSessions", "account", "pendingTransactionToasts", "completedTransactionToasts", "createToastsFromTransactions", "newToast", "customToastComponentDictionary", "ComponentFactory", "removeTransactionToast", "toastsElement", "handleClose", "customToastCloseHandlersDictionary", "removeCustomToast", "removeAllCustomToasts", "unsubscribe"]
7
+ }
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=chunk-TFZ46GCB.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": [],
4
+ "sourcesContent": [],
5
+ "mappings": "",
6
+ "names": []
7
+ }
@@ -1,2 +1,2 @@
1
- import{a as s}from"./chunk-XUADWD55.mjs";import{c as e}from"./chunk-MGFIOCA4.mjs";var o=class i extends s{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE_SIGN_TRANSACTIONS",uiTag:"mvx-sign-transactions-panel"});this.addressesPerPage=10;this._ppuMap={};this.initialData={commonData:{transactionsCount:0,currentIndexToSign:0,egldLabel:"",currentIndex:0,ppuOptions:[],address:"",origin:""},tokenTransaction:null,nftTransaction:null,sftTransaction:null};this.data={...this.initialData}}static getInstance(){return i.instance||(i.instance=new i),i.instance}get transactionsCount(){return this.data.commonData.transactionsCount}initializeGasPriceMap(a){let t=0;a.filter(n=>n!=null).forEach(n=>{let r=n?Number(n.gasPrice):0;this.updateGasPriceMap({nonce:Number(n.nonce),ppu:t,initialGasPrice:r})}),this.updateCommonData({ppu:t})}updateGasPriceMap({nonce:a,ppu:t,initialGasPrice:n}){this._ppuMap[a]={...this._ppuMap[a],ppu:t},n&&(this._ppuMap[a].initialGasPrice=n)}updateCommonData(a){this.data.commonData={...this.data.commonData,...a},this.notifyDataUpdate()}updateIsLoading(a){this.data.isLoading=a,this.notifyDataUpdate()}updateTokenTransaction(a){this.data.tokenTransaction=a,this.data.sftTransaction=null,this.data.nftTransaction=null,this.notifyDataUpdate()}updateNonFungibleTransaction(a,t){switch(a){case"NonFungibleESDT":this.data.nftTransaction=t,this.data.tokenTransaction=null,this.data.sftTransaction=null;break;case"SemiFungibleESDT":this.data.sftTransaction=t,this.data.nftTransaction=null,this.data.tokenTransaction=null;break;default:break}this.notifyDataUpdate()}get currentScreenIndex(){return this.data.commonData.currentIndex}get ppuMap(){return this._ppuMap}async setupEventListeners(){this.eventBus&&this.subscribeToEventBus("CLOSE_SIGN_TRANSACTIONS",this.closeUI.bind(this))}};export{o as a};
2
- //# sourceMappingURL=chunk-72D44IHE.mjs.map
1
+ import{a as s}from"./chunk-T2BVHJVW.mjs";import{c as e}from"./chunk-MGFIOCA4.mjs";var o=class i extends s{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE_SIGN_TRANSACTIONS",uiTag:"mvx-sign-transactions-panel"});this.addressesPerPage=10;this._ppuMap={};this.initialData={commonData:{transactionsCount:0,currentIndexToSign:0,egldLabel:"",currentIndex:0,ppuOptions:[],address:"",origin:""},tokenTransaction:null,nftTransaction:null,sftTransaction:null};this.data={...this.initialData}}static getInstance(){return i.instance||(i.instance=new i),i.instance}get transactionsCount(){return this.data.commonData.transactionsCount}initializeGasPriceMap(a){let t=0;a.filter(n=>n!=null).forEach(n=>{let r=n?Number(n.gasPrice):0;this.updateGasPriceMap({nonce:Number(n.nonce),ppu:t,initialGasPrice:r})}),this.updateCommonData({ppu:t})}updateGasPriceMap({nonce:a,ppu:t,initialGasPrice:n}){this._ppuMap[a]={...this._ppuMap[a],ppu:t},n&&(this._ppuMap[a].initialGasPrice=n)}updateCommonData(a){this.data.commonData={...this.data.commonData,...a},this.notifyDataUpdate()}updateIsLoading(a){this.data.isLoading=a,this.notifyDataUpdate()}updateTokenTransaction(a){this.data.tokenTransaction=a,this.data.sftTransaction=null,this.data.nftTransaction=null,this.notifyDataUpdate()}updateNonFungibleTransaction(a,t){switch(a){case"NonFungibleESDT":this.data.nftTransaction=t,this.data.tokenTransaction=null,this.data.sftTransaction=null;break;case"SemiFungibleESDT":this.data.sftTransaction=t,this.data.nftTransaction=null,this.data.tokenTransaction=null;break;default:break}this.notifyDataUpdate()}get currentScreenIndex(){return this.data.commonData.currentIndex}get ppuMap(){return this._ppuMap}async setupEventListeners(){this.eventBus&&this.subscribeToEventBus("CLOSE_SIGN_TRANSACTIONS",this.closeUI.bind(this))}};export{o as a};
2
+ //# sourceMappingURL=chunk-TJYR4CV6.mjs.map
@@ -1,2 +1,2 @@
1
- import{s as r}from"./chunk-LPGMDX6Q.mjs";import{b as e}from"./chunk-SAAOQW7P.mjs";var d=s=>{let o=e(r()),t=s??o.apiAddress;return t.endsWith("/")?t.slice(0,-1):t};export{d as a};
2
- //# sourceMappingURL=chunk-GSRRAPL5.mjs.map
1
+ import{s as r}from"./chunk-AYURCZHZ.mjs";import{b as e}from"./chunk-SAAOQW7P.mjs";var d=s=>{let o=e(r()),t=s??o.apiAddress;return t.endsWith("/")?t.slice(0,-1):t};export{d as a};
2
+ //# sourceMappingURL=chunk-TSK44JFJ.mjs.map
@@ -1,2 +1,2 @@
1
- import{s as e}from"./chunk-LPGMDX6Q.mjs";import{b as t}from"./chunk-SAAOQW7P.mjs";import{x as r}from"./chunk-KD2IQ32V.mjs";import i from"axios";var T=async o=>{let{apiAddress:s}=t(e()),{data:a}=await i.get(`${s}/${r}`,{params:{hashes:o.join(","),withScResults:!0}});return a};export{T as a};
2
- //# sourceMappingURL=chunk-N6QD4PLA.mjs.map
1
+ import{s as e}from"./chunk-AYURCZHZ.mjs";import{b as t}from"./chunk-SAAOQW7P.mjs";import{x as r}from"./chunk-KD2IQ32V.mjs";import i from"axios";var T=async o=>{let{apiAddress:s}=t(e()),{data:a}=await i.get(`${s}/${r}`,{params:{hashes:o.join(","),withScResults:!0}});return a};export{T as a};
2
+ //# sourceMappingURL=chunk-TURUYZA7.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as t}from"./chunk-EMIDMARK.mjs";import{q as e}from"./chunk-AYURCZHZ.mjs";var m=()=>t(e());export{m as a};
2
+ //# sourceMappingURL=chunk-U6OAEGT3.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as l}from"./chunk-QTKK6OSJ.mjs";import{a as h}from"./chunk-BGUYSNNW.mjs";import{a as g}from"./chunk-3S57OP4Z.mjs";import{NativeAuthClient as y}from"@multiversx/sdk-native-auth-client";var H=f=>{let{origin:o,apiAddress:i,expirySeconds:r,blockHashShard:s,extraInfo:u,gatewayUrl:d,extraRequestHeaders:k}=h(f),e=new y({origin:o,apiUrl:i,expirySeconds:r,blockHashShard:s,gatewayUrl:d,extraRequestHeaders:k});return{initialize:async t=>{if(!i||!o)return"";let a=()=>e.getCurrentBlockHash(),n=t?.latestBlockInfo;n??=await g({apiAddress:i,blockHashShard:s,getBlockHash:a,noCache:t?.noCache});let{hash:p,timestamp:c}=n,m=e.encodeValue(JSON.stringify({...t?.extraInfo??u,...c?{timestamp:c}:{}}));return`${e.encodeValue(o)}.${p}.${r}.${m}`},getToken:({address:t,token:a,signature:n})=>e.getToken(t,a,n),getTokenExpiration:l}};export{H as a};
2
- //# sourceMappingURL=chunk-ARAO6B2F.mjs.map
1
+ import{a as g}from"./chunk-3S57OP4Z.mjs";import{a as l}from"./chunk-QTKK6OSJ.mjs";import{a as h}from"./chunk-IBM2AHR2.mjs";import{NativeAuthClient as y}from"@multiversx/sdk-native-auth-client";var H=f=>{let{origin:o,apiAddress:i,expirySeconds:r,blockHashShard:s,extraInfo:u,gatewayUrl:d,extraRequestHeaders:k}=h(f),e=new y({origin:o,apiUrl:i,expirySeconds:r,blockHashShard:s,gatewayUrl:d,extraRequestHeaders:k});return{initialize:async t=>{if(!i||!o)return"";let a=()=>e.getCurrentBlockHash(),n=t?.latestBlockInfo;n??=await g({apiAddress:i,blockHashShard:s,getBlockHash:a,noCache:t?.noCache});let{hash:p,timestamp:c}=n,m=e.encodeValue(JSON.stringify({...t?.extraInfo??u,...c?{timestamp:c}:{}}));return`${e.encodeValue(o)}.${p}.${r}.${m}`},getToken:({address:t,token:a,signature:n})=>e.getToken(t,a,n),getTokenExpiration:l}};export{H as a};
2
+ //# sourceMappingURL=chunk-UGUQSBY5.mjs.map
@@ -1,2 +1,2 @@
1
- import{d as c}from"./chunk-L7L56ZTG.mjs";import{a as T}from"./chunk-V4YC4AKQ.mjs";import{a as p}from"./chunk-OLOCTHIE.mjs";import{b as m}from"./chunk-ZS4EBCWC.mjs";import{a as k}from"./chunk-B72JAXSF.mjs";import{a as g}from"./chunk-6GREKTLP.mjs";import{a as f}from"./chunk-ZJ2WPN2K.mjs";import{a as d}from"./chunk-HS34AFHY.mjs";import{a}from"./chunk-B3IKUIRK.mjs";import{a as r}from"./chunk-BRJNX4JF.mjs";import{a as t}from"./chunk-DBIIY2TX.mjs";import{a as s}from"./chunk-7CELSV4S.mjs";function z({transaction:e,address:h,explorerAddress:o}){let y=e.tokenIdentifier??m(e.data).tokenId,n=d(e),u=f(e),l={timeAgo:c(e.timestamp*1e3,!0),tooltip:a({value:e.timestamp,noSeconds:!1,utc:!0})},v=k({address:h,transaction:e,receiver:n}),I={actionDescription:e.action?.description,name:T(e)},S=g(e),D=r({explorerAddress:o,to:t.accountDetails(e.sender)}),L=r({explorerAddress:o,to:t.accountDetails(n)}),A=r({explorerAddress:o,to:t.senderShard(e.senderShard)}),H=r({explorerAddress:o,to:t.receiverShard(e.receiverShard)}),i=e.originalTxHash||e.txHash,x=r({explorerAddress:o,to:t.transactionDetails(i)});return{...e,txHash:i,tokenIdentifier:y,receiver:n,receiverAssets:u,transactionDetails:{age:l,direction:v,method:I,iconInfo:p(e),transactionTokens:S,isContract:s(e.sender)},links:{senderLink:D,receiverLink:L,senderShardLink:A,receiverShardLink:H,transactionLink:x}}}export{z as a};
2
- //# sourceMappingURL=chunk-DNFWIYZH.mjs.map
1
+ import{d as c}from"./chunk-L7L56ZTG.mjs";import{a as T}from"./chunk-V4YC4AKQ.mjs";import{a as p}from"./chunk-OLOCTHIE.mjs";import{b as m}from"./chunk-2GG67TZD.mjs";import{a as k}from"./chunk-B72JAXSF.mjs";import{a as g}from"./chunk-6GREKTLP.mjs";import{a as f}from"./chunk-ZJ2WPN2K.mjs";import{a as d}from"./chunk-HS34AFHY.mjs";import{a}from"./chunk-B3IKUIRK.mjs";import{a as r}from"./chunk-BRJNX4JF.mjs";import{a as t}from"./chunk-DBIIY2TX.mjs";import{a as s}from"./chunk-7CELSV4S.mjs";function z({transaction:e,address:h,explorerAddress:o}){let y=e.tokenIdentifier??m(e.data).tokenId,n=d(e),u=f(e),l={timeAgo:c(e.timestamp*1e3,!0),tooltip:a({value:e.timestamp,noSeconds:!1,utc:!0})},v=k({address:h,transaction:e,receiver:n}),I={actionDescription:e.action?.description,name:T(e)},S=g(e),D=r({explorerAddress:o,to:t.accountDetails(e.sender)}),L=r({explorerAddress:o,to:t.accountDetails(n)}),A=r({explorerAddress:o,to:t.senderShard(e.senderShard)}),H=r({explorerAddress:o,to:t.receiverShard(e.receiverShard)}),i=e.originalTxHash||e.txHash,x=r({explorerAddress:o,to:t.transactionDetails(i)});return{...e,txHash:i,tokenIdentifier:y,receiver:n,receiverAssets:u,transactionDetails:{age:l,direction:v,method:I,iconInfo:p(e),transactionTokens:S,isContract:s(e.sender)},links:{senderLink:D,receiverLink:L,senderShardLink:A,receiverShardLink:H,transactionLink:x}}}export{z as a};
2
+ //# sourceMappingURL=chunk-UNBTFF6K.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as S}from"./chunk-EAJBSX6Y.mjs";import{a as s}from"./chunk-NTOY6GTP.mjs";import{c as r,d as a}from"./chunk-CAA4VJRH.mjs";import{s as e}from"./chunk-LPGMDX6Q.mjs";import{a as n}from"./chunk-UERJ6AKK.mjs";var u=t=>{let o=0,i=n(e())?.shard;return S(t)?(t.forEach(c=>{let m=s(c,i);o+=m?5*6e3:6e3}),o):(o=s(t,i)?5*6e3:6e3,o)};export{u as a};
2
- //# sourceMappingURL=chunk-TMMUB3IK.mjs.map
1
+ import{a as S}from"./chunk-EAJBSX6Y.mjs";import{a as s}from"./chunk-NTOY6GTP.mjs";import{c as r,d as a}from"./chunk-2IUBMLF4.mjs";import{s as e}from"./chunk-AYURCZHZ.mjs";import{a as n}from"./chunk-UERJ6AKK.mjs";var u=t=>{let o=0,i=n(e())?.shard;return S(t)?(t.forEach(c=>{let m=s(c,i);o+=m?5*6e3:6e3}),o):(o=s(t,i)?5*6e3:6e3,o)};export{u as a};
2
+ //# sourceMappingURL=chunk-VQ4GD4WE.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as i}from"./chunk-FFHHIKMI.mjs";var c=class n extends i{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE",uiTag:"mvx-ledger-connect"});this.addressesPerPage=10;this.allAccounts=[];this.initialConnectScreenData={};this.connectScreenData={...this.initialConnectScreenData};this.initialAccountScreenData={accounts:this.allAccounts,startIndex:0,addressesPerPage:this.addressesPerPage,isLoading:!0};this.accountScreenData={...this.initialAccountScreenData};this.initialConfirmScreenData={selectedAddress:"",explorerLink:""};this.confirmScreenData={...this.initialConfirmScreenData};this.initialData={connectScreenData:this.initialConnectScreenData,accountScreenData:this.initialAccountScreenData,confirmScreenData:this.initialConfirmScreenData};this.data=this.getInitialData()}static getInstance(){return n.instance||(n.instance=new n),n.instance}updateAllAccounts(e){this.allAccounts=e,this.accountScreenData.accounts=e}updateStartIndex(e){this.accountScreenData.startIndex=e}updateConnectScreen(e){this.connectScreenData={...this.connectScreenData,...e},this.data.confirmScreenData=null,this.data.accountScreenData=null,this.data.connectScreenData=this.connectScreenData,this.notifyDataUpdate()}updateAccountScreen(e){this.accountScreenData={...this.accountScreenData,...e},this.data.confirmScreenData=null,this.data.accountScreenData=this.accountScreenData,this.notifyDataUpdate()}updateConfirmScreen(e){this.confirmScreenData={...this.confirmScreenData,...e},this.data.accountScreenData=null,this.data.confirmScreenData=this.confirmScreenData,this.notifyDataUpdate()}getAccountScreenData(){return this.data.accountScreenData}getConfirmScreenData(){return this.data.confirmScreenData}getAllAccounts(){return this.allAccounts}subscribeToProviderInit({handleRetry:e,handleCancel:t}){this.eventBus&&(this.eventBus.subscribe("CONNECT_DEVICE",e),this.eventBus.subscribe("CLOSE",t),this.eventBus.subscribe("UI_DISCONNECTED",this.destroy.bind(this)))}unsubscribeFromProviderInit({handleRetry:e,handleCancel:t}){this.eventBus&&(this.eventBus.unsubscribe("CONNECT_DEVICE",e),this.eventBus.unsubscribe("CLOSE",t),this.eventBus.unsubscribe("UI_DISCONNECTED",this.destroy.bind(this)))}subscribeToAuthEvents({handleCancel:e,handleAccessWallet:t,handleGoToPage:a}){this.eventBus&&(this.eventBus.subscribe("CLOSE",e),this.eventBus.subscribe("ACCESS_WALLET",t),this.eventBus.subscribe("GO_TO_PAGE",a))}unsubscribeFromAuthEvents({handleCancel:e,handleAccessWallet:t,handleGoToPage:a}){this.eventBus&&(this.eventBus.unsubscribe("CLOSE",e),this.eventBus.unsubscribe("ACCESS_WALLET",t),this.eventBus.unsubscribe("GO_TO_PAGE",a))}handleClose(){this.anchor?this.anchor?.dispatchEvent(new CustomEvent("ANCHOR_CLOSE",{composed:!1,bubbles:!1})):this.destroy()}resetData(){this.accountScreenData={...this.initialAccountScreenData},this.confirmScreenData={...this.initialConfirmScreenData},this.connectScreenData={...this.initialConnectScreenData},super.resetData()}async setupEventListeners(){this.eventBus&&this.eventBus.subscribe("CLOSE",this.handleClose.bind(this))}};export{c as a};
2
- //# sourceMappingURL=chunk-OP2PPPAN.mjs.map
1
+ import{a as i}from"./chunk-Y7BUJTYP.mjs";var c=class n extends i{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE",uiTag:"mvx-ledger-connect"});this.addressesPerPage=10;this.allAccounts=[];this.initialConnectScreenData={};this.connectScreenData={...this.initialConnectScreenData};this.initialAccountScreenData={accounts:this.allAccounts,startIndex:0,addressesPerPage:this.addressesPerPage,isLoading:!0};this.accountScreenData={...this.initialAccountScreenData};this.initialConfirmScreenData={selectedAddress:"",explorerLink:""};this.confirmScreenData={...this.initialConfirmScreenData};this.initialData={connectScreenData:this.initialConnectScreenData,accountScreenData:this.initialAccountScreenData,confirmScreenData:this.initialConfirmScreenData};this.data=this.getInitialData()}static getInstance(){return n.instance||(n.instance=new n),n.instance}updateAllAccounts(e){this.allAccounts=e,this.accountScreenData.accounts=e}updateStartIndex(e){this.accountScreenData.startIndex=e}updateConnectScreen(e){this.connectScreenData={...this.connectScreenData,...e},this.data.confirmScreenData=null,this.data.accountScreenData=null,this.data.connectScreenData=this.connectScreenData,this.notifyDataUpdate()}updateAccountScreen(e){this.accountScreenData={...this.accountScreenData,...e},this.data.confirmScreenData=null,this.data.accountScreenData=this.accountScreenData,this.notifyDataUpdate()}updateConfirmScreen(e){this.confirmScreenData={...this.confirmScreenData,...e},this.data.accountScreenData=null,this.data.confirmScreenData=this.confirmScreenData,this.notifyDataUpdate()}getAccountScreenData(){return this.data.accountScreenData}getConfirmScreenData(){return this.data.confirmScreenData}getAllAccounts(){return this.allAccounts}subscribeToProviderInit({handleRetry:e,handleCancel:t}){this.eventBus&&(this.eventBus.subscribe("CONNECT_DEVICE",e),this.eventBus.subscribe("CLOSE",t),this.eventBus.subscribe("UI_DISCONNECTED",this.destroy.bind(this)))}unsubscribeFromProviderInit({handleRetry:e,handleCancel:t}){this.eventBus&&(this.eventBus.unsubscribe("CONNECT_DEVICE",e),this.eventBus.unsubscribe("CLOSE",t),this.eventBus.unsubscribe("UI_DISCONNECTED",this.destroy.bind(this)))}subscribeToAuthEvents({handleCancel:e,handleAccessWallet:t,handleGoToPage:a}){this.eventBus&&(this.eventBus.subscribe("CLOSE",e),this.eventBus.subscribe("ACCESS_WALLET",t),this.eventBus.subscribe("GO_TO_PAGE",a))}unsubscribeFromAuthEvents({handleCancel:e,handleAccessWallet:t,handleGoToPage:a}){this.eventBus&&(this.eventBus.unsubscribe("CLOSE",e),this.eventBus.unsubscribe("ACCESS_WALLET",t),this.eventBus.unsubscribe("GO_TO_PAGE",a))}handleClose(){this.anchor?this.anchor?.dispatchEvent(new CustomEvent("ANCHOR_CLOSE",{composed:!1,bubbles:!1})):this.destroy()}resetData(){this.accountScreenData={...this.initialAccountScreenData},this.confirmScreenData={...this.initialConfirmScreenData},this.connectScreenData={...this.initialConnectScreenData},super.resetData()}async setupEventListeners(){this.eventBus&&this.eventBus.subscribe("CLOSE",this.handleClose.bind(this))}};export{c as a};
2
+ //# sourceMappingURL=chunk-VX6FOSXG.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as o}from"./chunk-OF3XH6ZU.mjs";import{c as e,g as s}from"./chunk-NTEMINYA.mjs";async function m({message:r,provider:a,options:n}){let g=o(),i=new s({address:new e(g),data:r.data});return await a.signMessage(i,n)}export{m as a};
2
- //# sourceMappingURL=chunk-KAQ5IXKK.mjs.map
1
+ import{a as o}from"./chunk-YJIAAC7S.mjs";import{c as e,g as s}from"./chunk-NTEMINYA.mjs";async function m({message:r,provider:a,options:n}){let g=o(),i=new s({address:new e(g),data:r.data});return await a.signMessage(i,n)}export{m as a};
2
+ //# sourceMappingURL=chunk-W6P2TQ3N.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as e}from"./chunk-FFHHIKMI.mjs";var n=class t extends e{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE",uiTag:"mvx-wallet-connect"});this.initialData={wcURI:"",walletConnectDeepLink:""};this.data={...this.initialData}}static getInstance(){return t.instance||(t.instance=new t),t.instance}handleClose(a){a?.isLoginFinished||(this.anchor?this.anchor.dispatchEvent(new CustomEvent("ANCHOR_CLOSE",{composed:!1,bubbles:!1})):this.destroy())}async setupEventListeners(){this.eventBus&&(this.eventBus.subscribe("CLOSE",this.handleClose.bind(this)),this.eventBus.subscribe("UI_DISCONNECTED",this.destroy.bind(this)))}};export{n as a};
2
- //# sourceMappingURL=chunk-E5CUE265.mjs.map
1
+ import{a as e}from"./chunk-Y7BUJTYP.mjs";var n=class t extends e{constructor(){super({uiDataUpdateEvent:"DATA_UPDATE",uiTag:"mvx-wallet-connect"});this.initialData={wcURI:"",walletConnectDeepLink:""};this.data={...this.initialData}}static getInstance(){return t.instance||(t.instance=new t),t.instance}handleClose(a){a?.isLoginFinished||(this.anchor?this.anchor.dispatchEvent(new CustomEvent("ANCHOR_CLOSE",{composed:!1,bubbles:!1})):this.destroy())}async setupEventListeners(){this.eventBus&&(this.eventBus.subscribe("CLOSE",this.handleClose.bind(this)),this.eventBus.subscribe("UI_DISCONNECTED",this.destroy.bind(this)))}};export{n as a};
2
+ //# sourceMappingURL=chunk-WC4UR2ZF.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as d}from"./chunk-BHAHZQVO.mjs";import{a as i}from"./chunk-OOVV574D.mjs";var m=({data:o,decodeMethod:e,delimiter:r,identifier:c})=>{let t=o.split("@"),n=t.map(g=>i({data:g,decodeMethod:e}));return d({parts:t,initialDecodedParts:n,identifier:c,decodeMethod:e}).join(r)};export{m as a};
2
+ //# sourceMappingURL=chunk-WJQVMI33.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/utils/transactions/getDecodedDataField/helpers/decodeHighlight.ts"],
4
+ "sourcesContent": ["import { DecodeMethodEnum } from 'types/serverTransactions.types';\nimport { decodeByMethod } from './decodeByMethod';\nimport { getDecodedParts } from './getDecodedParts';\n\ninterface IDecodeHighlight {\n data: string;\n decodeMethod: DecodeMethodEnum;\n delimiter: string;\n identifier?: string;\n}\n\nexport const decodeHighlight = ({\n data,\n decodeMethod,\n delimiter,\n identifier\n}: IDecodeHighlight) => {\n const parts = data.split('@');\n\n const initialDecodedParts = parts.map((part) => {\n return decodeByMethod({ data: part, decodeMethod });\n });\n\n const decodedHighlight = getDecodedParts({\n parts,\n initialDecodedParts,\n identifier,\n decodeMethod\n });\n\n return decodedHighlight.join(delimiter);\n};\n"],
5
+ "mappings": "kFAWO,IAAMA,EAAkB,CAAC,CAC9B,KAAAC,EACA,aAAAC,EACA,UAAAC,EACA,WAAAC,CACF,IAAwB,CACtB,IAAMC,EAAQJ,EAAK,MAAM,GAAG,EAEtBK,EAAsBD,EAAM,IAAKE,GAC9BC,EAAe,CAAE,KAAMD,EAAM,aAAAL,CAAa,CAAC,CACnD,EASD,OAPyBO,EAAgB,CACvC,MAAAJ,EACA,oBAAAC,EACA,WAAAF,EACA,aAAAF,CACF,CAAC,EAEuB,KAAKC,CAAS,CACxC",
6
+ "names": ["decodeHighlight", "data", "decodeMethod", "delimiter", "identifier", "parts", "initialDecodedParts", "part", "decodeByMethod", "getDecodedParts"]
7
+ }
@@ -0,0 +1,2 @@
1
+ import{s as e}from"./chunk-AYURCZHZ.mjs";import{f as t}from"./chunk-UERJ6AKK.mjs";function n(o=e()){return t(o)}export{n as a};
2
+ //# sourceMappingURL=chunk-WJTCBV34.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as r}from"./chunk-ARAO6B2F.mjs";import{a as o}from"./chunk-WE7YOBO7.mjs";async function p({loginToken:i,extraInfoData:n}){if(i==null||Object.keys(n).length===0)return null;let t=o(String(i)),{timestamp:e,...a}=t?.extraInfo||{};if(!(t&&e!=null))return null;let s={hash:String(t?.blockHash),timestamp:Number(e)};return await r({extraInfo:{...a,...n},expirySeconds:t?.ttl,origin:t?.origin}).initialize({latestBlockInfo:s})}export{p as a};
2
- //# sourceMappingURL=chunk-6BF62TP4.mjs.map
1
+ import{a as r}from"./chunk-UGUQSBY5.mjs";import{a as o}from"./chunk-WE7YOBO7.mjs";async function p({loginToken:i,extraInfoData:n}){if(i==null||Object.keys(n).length===0)return null;let t=o(String(i)),{timestamp:e,...a}=t?.extraInfo||{};if(!(t&&e!=null))return null;let s={hash:String(t?.blockHash),timestamp:Number(e)};return await r({extraInfo:{...a,...n},expirySeconds:t?.ttl,origin:t?.origin}).initialize({latestBlockInfo:s})}export{p as a};
2
+ //# sourceMappingURL=chunk-WJXCNHT3.mjs.map
@@ -0,0 +1,2 @@
1
+ var o=typeof window<"u"?window:{},n="5.1.3";export{o as a,n as b};
2
+ //# sourceMappingURL=chunk-XDYKH6G4.mjs.map
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/constants/window.constants.ts"],
4
- "sourcesContent": ["export const safeWindow: Window =\n typeof window !== 'undefined' ? window : ({} as Window);\n\nexport const version = '5.1.2'; // will be replaced at build time\n"],
4
+ "sourcesContent": ["export const safeWindow: Window =\n typeof window !== 'undefined' ? window : ({} as Window);\n\nexport const version = '5.1.3'; // will be replaced at build time\n"],
5
5
  "mappings": "AAAO,IAAMA,EACX,OAAO,OAAW,IAAc,OAAU,CAAC,EAEhCC,EAAU",
6
6
  "names": ["safeWindow", "version"]
7
7
  }
@@ -0,0 +1,2 @@
1
+ import{a}from"./chunk-XDYKH6G4.mjs";var o=()=>a.localStorage;export{o as a};
2
+ //# sourceMappingURL=chunk-XFP6N66W.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as s}from"./chunk-O7LCTC4K.mjs";import{s as m}from"./chunk-LPGMDX6Q.mjs";import{b as a}from"./chunk-SAAOQW7P.mjs";import{o as r,u as i}from"./chunk-KD2IQ32V.mjs";import{a as c}from"./chunk-3FXHIV6O.mjs";async function b({tokenId:o}){let t=a(m()),{isNft:k}=c(o),n=o,p=k?r:i;if(!n)return{tokenDecimals:Number(t.decimals),tokenLabel:"",tokenAvatar:""};try{let{data:e}=await s.get(`${t.apiAddress}/${p}/${n}`),f=e?e?.decimals:Number(t.decimals),l=e?e?.name:"",d=e?e?.assets?.svgUrl??e?.media?.[0]?.thumbnailUrl:"";return{tokenDecimals:f,tokenLabel:l,type:e?.type,tokenAvatar:d,identifier:e?.identifier,assets:e?.assets,esdtPrice:e?.price,ticker:e?.ticker,name:e?.name}}catch(e){return{error:`Error fetching token ${n}: ${e.toString()}`,tokenDecimals:Number(t.decimals),tokenLabel:"",tokenAvatar:"",identifier:n}}}export{b as a};
2
- //# sourceMappingURL=chunk-CYEMHPEX.mjs.map
1
+ import{a as s}from"./chunk-O7LCTC4K.mjs";import{s as m}from"./chunk-AYURCZHZ.mjs";import{b as a}from"./chunk-SAAOQW7P.mjs";import{o as r,u as i}from"./chunk-KD2IQ32V.mjs";import{a as c}from"./chunk-3FXHIV6O.mjs";async function b({tokenId:o}){let t=a(m()),{isNft:k}=c(o),n=o,p=k?r:i;if(!n)return{tokenDecimals:Number(t.decimals),tokenLabel:"",tokenAvatar:""};try{let{data:e}=await s.get(`${t.apiAddress}/${p}/${n}`),f=e?e?.decimals:Number(t.decimals),l=e?e?.name:"",d=e?e?.assets?.svgUrl??e?.media?.[0]?.thumbnailUrl:"";return{tokenDecimals:f,tokenLabel:l,type:e?.type,tokenAvatar:d,identifier:e?.identifier,assets:e?.assets,esdtPrice:e?.price,ticker:e?.ticker,name:e?.name}}catch(e){return{error:`Error fetching token ${n}: ${e.toString()}`,tokenDecimals:Number(t.decimals),tokenLabel:"",tokenAvatar:"",identifier:n}}}export{b as a};
2
+ //# sourceMappingURL=chunk-XHRRQNPV.mjs.map