@multiversx/sdk-dapp 5.0.0-alpha.3 → 5.0.0-alpha.4

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 (104) hide show
  1. package/out/__chunks__/{chunk-ZLBHLHQ3.mjs → chunk-46WBKAT4.mjs} +2 -2
  2. package/out/__chunks__/{chunk-Y2GZNJKO.mjs → chunk-4NMRZJSQ.mjs} +2 -2
  3. package/out/__chunks__/{chunk-TFQFZ5M2.mjs → chunk-773UPGVZ.mjs} +2 -2
  4. package/out/__chunks__/{chunk-XCXU3BVP.mjs → chunk-CRSZQV7V.mjs} +2 -2
  5. package/out/__chunks__/{chunk-ZK3OCDKZ.mjs → chunk-DELLFT6H.mjs} +2 -2
  6. package/out/__chunks__/chunk-GDSFFLIR.mjs +2 -0
  7. package/out/__chunks__/{chunk-D4MNCAND.mjs → chunk-HNEBEFTL.mjs} +2 -2
  8. package/out/__chunks__/{chunk-ZGNDECGJ.mjs → chunk-HWH2SKSH.mjs} +2 -2
  9. package/out/__chunks__/chunk-J7P6SJOM.mjs +2 -0
  10. package/out/__chunks__/chunk-J7P6SJOM.mjs.map +7 -0
  11. package/out/__chunks__/{chunk-G7ZMNJIE.mjs → chunk-MJGS5LXB.mjs} +2 -2
  12. package/out/__chunks__/chunk-N7KSN2OU.mjs +2 -0
  13. package/out/__chunks__/chunk-N7KSN2OU.mjs.map +7 -0
  14. package/out/__chunks__/chunk-OZ3OBQJ6.mjs +2 -0
  15. package/out/__chunks__/chunk-OZ3OBQJ6.mjs.map +7 -0
  16. package/out/__chunks__/{chunk-XKTDOIMV.mjs → chunk-PBIRC7U4.mjs} +2 -2
  17. package/out/__chunks__/{chunk-DHSATBNM.mjs → chunk-PUSIK3N4.mjs} +2 -2
  18. package/out/__chunks__/{chunk-ZIQFQWVJ.mjs → chunk-TCCW2HZK.mjs} +2 -2
  19. package/out/__chunks__/{chunk-643LVXSN.mjs → chunk-U5PPKFAJ.mjs} +2 -2
  20. package/out/__chunks__/{chunk-BTDFQCSV.mjs → chunk-XQLVTH7K.mjs} +2 -2
  21. package/out/__chunks__/{chunk-BJRGP56G.mjs → chunk-YDXS2C4W.mjs} +2 -2
  22. package/out/index.mjs +1 -1
  23. package/out/managers/NotificationsFeedManager/NotificationsFeedManager.mjs +1 -1
  24. package/out/managers/NotificationsFeedManager/index.mjs +1 -1
  25. package/out/managers/TransactionManager/TransactionManager.mjs +1 -1
  26. package/out/managers/TransactionManager/helpers/getAreTransactionsCorssShards.mjs +1 -1
  27. package/out/managers/TransactionManager/helpers/getToastDuration.mjs +1 -1
  28. package/out/managers/TransactionManager/index.mjs +1 -1
  29. package/out/managers/UnlockPanelManager/UnlockPanelManager.mjs +1 -1
  30. package/out/managers/UnlockPanelManager/index.mjs +1 -1
  31. package/out/managers/index.mjs +1 -1
  32. package/out/managers/internal/LedgerIdleStateManager/LedgerIdleStateManager.mjs +1 -1
  33. package/out/managers/internal/ToastManager/ToastManager.mjs +1 -1
  34. package/out/managers/internal/ToastManager/helpers/LifetimeManager.mjs +1 -1
  35. package/out/managers/internal/index.mjs +1 -1
  36. package/out/methods/initApp/initApp.mjs +1 -1
  37. package/out/methods/network/getNetworkConfig.d.ts +1 -1
  38. package/out/methods/network/getNetworkConfig.js +1 -1
  39. package/out/methods/network/getNetworkConfig.js.map +1 -1
  40. package/out/methods/network/getNetworkConfig.mjs +1 -1
  41. package/out/providers/DappProvider/DappProvider.mjs +1 -1
  42. package/out/providers/DappProvider/helpers/login/helpers/accountLogin.mjs +1 -1
  43. package/out/providers/DappProvider/helpers/login/login.js +2 -2
  44. package/out/providers/DappProvider/helpers/login/login.js.map +1 -1
  45. package/out/providers/DappProvider/helpers/login/login.mjs +1 -1
  46. package/out/providers/DappProvider/helpers/signErrors/handleSignError.mjs +1 -1
  47. package/out/providers/DappProvider/helpers/signTransactions/signTransactionsWithProvider.mjs +1 -1
  48. package/out/providers/DappProvider/index.mjs +1 -1
  49. package/out/providers/ProviderFactory.mjs +1 -1
  50. package/out/providers/helpers/accountProvider.mjs +1 -1
  51. package/out/providers/helpers/cancelCrossWindowAction.mjs +1 -1
  52. package/out/providers/helpers/restoreProvider.mjs +1 -1
  53. package/out/providers/index.mjs +1 -1
  54. package/out/providers/strategies/LedgerProviderStrategy/LedgerProviderStrategy.mjs +1 -1
  55. package/out/providers/strategies/LedgerProviderStrategy/helpers/authenticateLedgerAccount.mjs +1 -1
  56. package/out/providers/strategies/LedgerProviderStrategy/helpers/getLedgerProvider.mjs +1 -1
  57. package/out/providers/strategies/LedgerProviderStrategy/helpers/index.mjs +1 -1
  58. package/out/providers/strategies/LedgerProviderStrategy/helpers/initializeLedgerProvider.mjs +1 -1
  59. package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/index.mjs +1 -1
  60. package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/updateAccountsList.js +1 -1
  61. package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/updateAccountsList.js.map +1 -1
  62. package/out/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/updateAccountsList.mjs +1 -1
  63. package/out/providers/strategies/LedgerProviderStrategy/index.mjs +1 -1
  64. package/out/providers/strategies/WalletConnectProviderStrategy/WalletConnectProviderStrategy.mjs +1 -1
  65. package/out/providers/strategies/WalletConnectProviderStrategy/index.mjs +1 -1
  66. package/out/providers/strategies/helpers/signTransactions/helpers/getCommonData/getCommonData.mjs +1 -1
  67. package/out/providers/strategies/helpers/signTransactions/signTransactions.mjs +1 -1
  68. package/out/providers/strategies/index.mjs +1 -1
  69. package/out/react/network/useGetNetworkConfig.d.ts +1 -1
  70. package/out/react/network/useGetNetworkConfig.js +1 -1
  71. package/out/react/network/useGetNetworkConfig.js.map +1 -1
  72. package/out/react/network/useGetNetworkConfig.mjs +1 -1
  73. package/out/react/network/useGetNetworkConfig.mjs.map +3 -3
  74. package/out/store/actions/index.mjs +1 -1
  75. package/out/store/actions/toasts/index.mjs +1 -1
  76. package/out/store/actions/toasts/toastsActions.mjs +1 -1
  77. package/out/utils/account/index.mjs +1 -1
  78. package/out/utils/account/refreshAccount.js +1 -1
  79. package/out/utils/account/refreshAccount.js.map +1 -1
  80. package/out/utils/account/refreshAccount.mjs +1 -1
  81. package/out/utils/index.mjs +1 -1
  82. package/package.json +1 -1
  83. package/out/__chunks__/chunk-3PAMS4NB.mjs +0 -2
  84. package/out/__chunks__/chunk-3PAMS4NB.mjs.map +0 -7
  85. package/out/__chunks__/chunk-53TM7EG4.mjs +0 -2
  86. package/out/__chunks__/chunk-53TM7EG4.mjs.map +0 -7
  87. package/out/__chunks__/chunk-57KVKSEC.mjs +0 -2
  88. package/out/__chunks__/chunk-57KVKSEC.mjs.map +0 -7
  89. package/out/__chunks__/chunk-5KRDLFR5.mjs +0 -2
  90. /package/out/__chunks__/{chunk-ZLBHLHQ3.mjs.map → chunk-46WBKAT4.mjs.map} +0 -0
  91. /package/out/__chunks__/{chunk-Y2GZNJKO.mjs.map → chunk-4NMRZJSQ.mjs.map} +0 -0
  92. /package/out/__chunks__/{chunk-TFQFZ5M2.mjs.map → chunk-773UPGVZ.mjs.map} +0 -0
  93. /package/out/__chunks__/{chunk-XCXU3BVP.mjs.map → chunk-CRSZQV7V.mjs.map} +0 -0
  94. /package/out/__chunks__/{chunk-ZK3OCDKZ.mjs.map → chunk-DELLFT6H.mjs.map} +0 -0
  95. /package/out/__chunks__/{chunk-5KRDLFR5.mjs.map → chunk-GDSFFLIR.mjs.map} +0 -0
  96. /package/out/__chunks__/{chunk-D4MNCAND.mjs.map → chunk-HNEBEFTL.mjs.map} +0 -0
  97. /package/out/__chunks__/{chunk-ZGNDECGJ.mjs.map → chunk-HWH2SKSH.mjs.map} +0 -0
  98. /package/out/__chunks__/{chunk-G7ZMNJIE.mjs.map → chunk-MJGS5LXB.mjs.map} +0 -0
  99. /package/out/__chunks__/{chunk-XKTDOIMV.mjs.map → chunk-PBIRC7U4.mjs.map} +0 -0
  100. /package/out/__chunks__/{chunk-DHSATBNM.mjs.map → chunk-PUSIK3N4.mjs.map} +0 -0
  101. /package/out/__chunks__/{chunk-ZIQFQWVJ.mjs.map → chunk-TCCW2HZK.mjs.map} +0 -0
  102. /package/out/__chunks__/{chunk-643LVXSN.mjs.map → chunk-U5PPKFAJ.mjs.map} +0 -0
  103. /package/out/__chunks__/{chunk-BTDFQCSV.mjs.map → chunk-XQLVTH7K.mjs.map} +0 -0
  104. /package/out/__chunks__/{chunk-BJRGP56G.mjs.map → chunk-YDXS2C4W.mjs.map} +0 -0
@@ -1,2 +1,2 @@
1
- import{a as g}from"./chunk-G7ZMNJIE.mjs";import{a as y}from"./chunk-OYA4AQFY.mjs";import{a as f}from"./chunk-GUHNF5RM.mjs";import{a as c}from"./chunk-67X3ORNS.mjs";import{a as I}from"./chunk-OSYFYAJA.mjs";import{a as l}from"./chunk-LEVR7744.mjs";import{a as w}from"./chunk-BTDFQCSV.mjs";import{a as u}from"./chunk-ZIQFQWVJ.mjs";import{n as m,o as n,p as P}from"./chunk-57KVKSEC.mjs";import{a as p}from"./chunk-6746F2FY.mjs";import{a as s}from"./chunk-CN4RHVUE.mjs";import{IframeLoginTypes as b}from"@multiversx/sdk-web-wallet-iframe-provider/out/constants";var d=class{static set customProviders(t){this._customProviders=t}static get customProviders(){return this._customProviders}static async create({type:t,anchor:o}){let e=null;switch(t){case"extension":{e=await new I().createProvider();break}case"crossWindow":{e=await new l().createProvider();break}case"ledger":{e=await new u().createProvider({anchor:o}),await g.getInstance().init();break}case"metamask":{e=await new c({type:b.metamask}).createProvider();break}case"passkey":{e=await new c({type:b.passkey}).createProvider();break}case"walletConnect":{e=await new w().createProvider({anchor:o});break}case"webview":{e=await new f().createProvider();break}default:{let r=p();for(let a of this._customProviders)a.type===t&&(e=await a.constructor({address:r,anchor:o}));break}}if(!e)throw new Error("Unable to create provider");e.getType=()=>t;let v=new m(e);n(v);let i=t;s(i);let k=["crossWindow","metamask","passkey"].includes(i);return y(k?{skipLoginMethod:i}:null),v}static async destroy(){P().cancelLogin(),n(null),s("")}};d._customProviders=[];export{d as a};
2
- //# sourceMappingURL=chunk-ZLBHLHQ3.mjs.map
1
+ import{a as g}from"./chunk-MJGS5LXB.mjs";import{a as y}from"./chunk-OYA4AQFY.mjs";import{a as f}from"./chunk-GUHNF5RM.mjs";import{a as c}from"./chunk-67X3ORNS.mjs";import{a as I}from"./chunk-OSYFYAJA.mjs";import{a as l}from"./chunk-LEVR7744.mjs";import{a as w}from"./chunk-XQLVTH7K.mjs";import{a as u}from"./chunk-TCCW2HZK.mjs";import{n as m,o as n,p as P}from"./chunk-J7P6SJOM.mjs";import{a as p}from"./chunk-6746F2FY.mjs";import{a as s}from"./chunk-CN4RHVUE.mjs";import{IframeLoginTypes as b}from"@multiversx/sdk-web-wallet-iframe-provider/out/constants";var d=class{static set customProviders(t){this._customProviders=t}static get customProviders(){return this._customProviders}static async create({type:t,anchor:o}){let e=null;switch(t){case"extension":{e=await new I().createProvider();break}case"crossWindow":{e=await new l().createProvider();break}case"ledger":{e=await new u().createProvider({anchor:o}),await g.getInstance().init();break}case"metamask":{e=await new c({type:b.metamask}).createProvider();break}case"passkey":{e=await new c({type:b.passkey}).createProvider();break}case"walletConnect":{e=await new w().createProvider({anchor:o});break}case"webview":{e=await new f().createProvider();break}default:{let r=p();for(let a of this._customProviders)a.type===t&&(e=await a.constructor({address:r,anchor:o}));break}}if(!e)throw new Error("Unable to create provider");e.getType=()=>t;let v=new m(e);n(v);let i=t;s(i);let k=["crossWindow","metamask","passkey"].includes(i);return y(k?{skipLoginMethod:i}:null),v}static async destroy(){P().cancelLogin(),n(null),s("")}};d._customProviders=[];export{d as a};
2
+ //# sourceMappingURL=chunk-46WBKAT4.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as f}from"./chunk-FRDR4A7Z.mjs";import{a as g}from"./chunk-BQL3NILA.mjs";import{p as c}from"./chunk-57KVKSEC.mjs";import{u as n}from"./chunk-CN4RHVUE.mjs";import{g as a}from"./chunk-LTF535HP.mjs";import{e as l}from"./chunk-VNLGNNIL.mjs";import{HWProvider as m}from"@multiversx/sdk-hw-provider";async function A(u){let v=g(),d=u?.shouldInitProvider||!v,o=l(n()),t=a(n()),r=c(),i=new m,I=async()=>{let e=o?.index!=null;if(r instanceof m&&r.isInitialized())return e&&await r.setAddressIndex(o.index),r;if(d&&!await i.init())throw new Error("Failed to initialize Ledger Provider");return e&&await i.setAddressIndex(o.index),i};try{if(!d&&t)return{ledgerProvider:i,ledgerConfig:{version:t.version,dataEnabled:t.hasContractDataEnabled}};let e=await I(),s=await f(e);return{ledgerProvider:e,ledgerConfig:s}}catch(e){throw console.error("Could not initialize ledger app",e),e}}export{A as a};
2
- //# sourceMappingURL=chunk-Y2GZNJKO.mjs.map
1
+ import{a as f}from"./chunk-FRDR4A7Z.mjs";import{a as g}from"./chunk-BQL3NILA.mjs";import{p as c}from"./chunk-J7P6SJOM.mjs";import{u as n}from"./chunk-CN4RHVUE.mjs";import{g as a}from"./chunk-LTF535HP.mjs";import{e as l}from"./chunk-VNLGNNIL.mjs";import{HWProvider as m}from"@multiversx/sdk-hw-provider";async function A(u){let v=g(),d=u?.shouldInitProvider||!v,o=l(n()),t=a(n()),r=c(),i=new m,I=async()=>{let e=o?.index!=null;if(r instanceof m&&r.isInitialized())return e&&await r.setAddressIndex(o.index),r;if(d&&!await i.init())throw new Error("Failed to initialize Ledger Provider");return e&&await i.setAddressIndex(o.index),i};try{if(!d&&t)return{ledgerProvider:i,ledgerConfig:{version:t.version,dataEnabled:t.hasContractDataEnabled}};let e=await I(),s=await f(e);return{ledgerProvider:e,ledgerConfig:s}}catch(e){throw console.error("Could not initialize ledger app",e),e}}export{A as a};
2
+ //# sourceMappingURL=chunk-4NMRZJSQ.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as S}from"./chunk-IJX53ZJI.mjs";import{a as f}from"./chunk-EAJBSX6Y.mjs";import{a as g}from"./chunk-Y3BNMQFP.mjs";import{g as u}from"./chunk-57KVKSEC.mjs";import{h as l}from"./chunk-QD3CFFVT.mjs";import{a as y}from"./chunk-CBIH5QMT.mjs";import{a as m}from"./chunk-AGI2ZR6R.mjs";import{a as T}from"./chunk-L3MWDI6J.mjs";import{u as p}from"./chunk-CN4RHVUE.mjs";import{b as c}from"./chunk-SAAOQW7P.mjs";import{d}from"./chunk-2CNSQULM.mjs";import h from"axios";var r=class r{constructor(){this.send=async a=>{if(a.length===0)throw new Error("No transactions to send");try{if(!f(a))return await this.sendSignedTransactions(a);let t=await this.sendSignedBatchTransactions(a);if(!t.data||t.data.error)throw new Error(t.data?.error??"Failed to send transactions");return t.data.transactions}catch(t){throw t.response?.data?.message??t.message}};this.track=async(a,t={disableToasts:!1})=>{let s=this.sequentialToFlatArray(a).map(i=>({...i,status:i.status??"pending"})),e=T(s),o=m({transactions:s,transactionsDisplayInfo:t.transactionsDisplayInfo,status:e??"sent"});if(t.disableToasts===!0)return o;let n=S(a);return u({toastId:o,totalDuration:n}),o};this.sendSignedTransactions=async a=>{let{apiAddress:t,apiTimeout:s}=c(p()),e=a.map(n=>h.post(`${t}/transactions`,n.toPlainObject(),{timeout:Number(s)}));return(await Promise.all(e)).map(({data:n})=>({...n,status:"pending",hash:n.txHash}))};this.sendSignedBatchTransactions=async a=>{let{address:t}=y(),{apiAddress:s,apiTimeout:e}=c(p());if(!t)return{error:"Invalid address provided. You need to be logged in to send transactions"};let o=this.buildBatchId(t),i={transactions:a.map(A=>A.map(w=>this.parseSignedTransaction(w))),id:o},{data:b}=await h.post(`${s}/batch`,i,{timeout:Number(e)});return{data:b}};this.buildBatchId=a=>`${Date.now().toString()}${l}${a}`;this.sequentialToFlatArray=(a=[])=>this.getIsSequential(a)?a.flat():a;this.getIsSequential=a=>a?.every(t=>Array.isArray(t));this.parseSignedTransaction=a=>{let t=new d,s={...a.toPlainObject(),hash:t.computeTransactionHash(a),status:"pending"};return g({data:s.data})&&(delete s.senderUsername,delete s.receiverUsername),s}}static getInstance(){return r.instance||(r.instance=new r),r.instance}};r.instance=null;var I=r;export{I as a};
2
- //# sourceMappingURL=chunk-TFQFZ5M2.mjs.map
1
+ import{a as S}from"./chunk-IJX53ZJI.mjs";import{a as f}from"./chunk-EAJBSX6Y.mjs";import{a as g}from"./chunk-Y3BNMQFP.mjs";import{g as u}from"./chunk-J7P6SJOM.mjs";import{h as l}from"./chunk-QD3CFFVT.mjs";import{a as y}from"./chunk-CBIH5QMT.mjs";import{a as m}from"./chunk-AGI2ZR6R.mjs";import{a as T}from"./chunk-L3MWDI6J.mjs";import{u as p}from"./chunk-CN4RHVUE.mjs";import{b as c}from"./chunk-SAAOQW7P.mjs";import{d}from"./chunk-2CNSQULM.mjs";import h from"axios";var r=class r{constructor(){this.send=async a=>{if(a.length===0)throw new Error("No transactions to send");try{if(!f(a))return await this.sendSignedTransactions(a);let t=await this.sendSignedBatchTransactions(a);if(!t.data||t.data.error)throw new Error(t.data?.error??"Failed to send transactions");return t.data.transactions}catch(t){throw t.response?.data?.message??t.message}};this.track=async(a,t={disableToasts:!1})=>{let s=this.sequentialToFlatArray(a).map(i=>({...i,status:i.status??"pending"})),e=T(s),o=m({transactions:s,transactionsDisplayInfo:t.transactionsDisplayInfo,status:e??"sent"});if(t.disableToasts===!0)return o;let n=S(a);return u({toastId:o,totalDuration:n}),o};this.sendSignedTransactions=async a=>{let{apiAddress:t,apiTimeout:s}=c(p()),e=a.map(n=>h.post(`${t}/transactions`,n.toPlainObject(),{timeout:Number(s)}));return(await Promise.all(e)).map(({data:n})=>({...n,status:"pending",hash:n.txHash}))};this.sendSignedBatchTransactions=async a=>{let{address:t}=y(),{apiAddress:s,apiTimeout:e}=c(p());if(!t)return{error:"Invalid address provided. You need to be logged in to send transactions"};let o=this.buildBatchId(t),i={transactions:a.map(A=>A.map(w=>this.parseSignedTransaction(w))),id:o},{data:b}=await h.post(`${s}/batch`,i,{timeout:Number(e)});return{data:b}};this.buildBatchId=a=>`${Date.now().toString()}${l}${a}`;this.sequentialToFlatArray=(a=[])=>this.getIsSequential(a)?a.flat():a;this.getIsSequential=a=>a?.every(t=>Array.isArray(t));this.parseSignedTransaction=a=>{let t=new d,s={...a.toPlainObject(),hash:t.computeTransactionHash(a),status:"pending"};return g({data:s.data})&&(delete s.senderUsername,delete s.receiverUsername),s}}static getInstance(){return r.instance||(r.instance=new r),r.instance}};r.instance=null;var I=r;export{I as a};
2
+ //# sourceMappingURL=chunk-773UPGVZ.mjs.map
@@ -1,2 +1,2 @@
1
- import{b as s,d as i,h as o}from"./chunk-57KVKSEC.mjs";var r=1e4,u=class{constructor(){this.timeoutIntervals=new Map;this.successfulToastLifetime=r;this.start=t=>{if(this.stop(t),this.successfulToastLifetime<=0)return;let e=setTimeout(()=>{o(t)},this.successfulToastLifetime);this.timeoutIntervals.set(t,e)};this.startWithCustomDuration=(t,e)=>{if(this.stop(t),e<=0)return;let a=setTimeout(()=>{i(t);let n=s[t];n?.()},e);this.timeoutIntervals.set(t,a)};this.stop=t=>{let e=this.timeoutIntervals.get(t);e&&(clearTimeout(e),this.timeoutIntervals.delete(t))}}init({successfulToastLifetime:t}){this.successfulToastLifetime=t||r}destroy(){this.timeoutIntervals.forEach(t=>clearTimeout(t)),this.timeoutIntervals.clear()}};export{u as a};
2
- //# sourceMappingURL=chunk-XCXU3BVP.mjs.map
1
+ import{b as s,d as i,h as o}from"./chunk-J7P6SJOM.mjs";var r=1e4,u=class{constructor(){this.timeoutIntervals=new Map;this.successfulToastLifetime=r;this.start=t=>{if(this.stop(t),this.successfulToastLifetime<=0)return;let e=setTimeout(()=>{o(t)},this.successfulToastLifetime);this.timeoutIntervals.set(t,e)};this.startWithCustomDuration=(t,e)=>{if(this.stop(t),e<=0)return;let a=setTimeout(()=>{i(t);let n=s[t];n?.()},e);this.timeoutIntervals.set(t,a)};this.stop=t=>{let e=this.timeoutIntervals.get(t);e&&(clearTimeout(e),this.timeoutIntervals.delete(t))}}init({successfulToastLifetime:t}){this.successfulToastLifetime=t||r}destroy(){this.timeoutIntervals.forEach(t=>clearTimeout(t)),this.timeoutIntervals.clear()}};export{u as a};
2
+ //# sourceMappingURL=chunk-CRSZQV7V.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as n}from"./chunk-ZLBHLHQ3.mjs";import{o as i}from"./chunk-57KVKSEC.mjs";import{u as e}from"./chunk-CN4RHVUE.mjs";import{d as t}from"./chunk-VNLGNNIL.mjs";async function d(){let r=t(e());if(!r)return;let o=await n.create({type:r});if(!o)throw new Error("Provider not found");i(o)}export{d as a};
2
- //# sourceMappingURL=chunk-ZK3OCDKZ.mjs.map
1
+ import{a as n}from"./chunk-46WBKAT4.mjs";import{o as i}from"./chunk-J7P6SJOM.mjs";import{u as e}from"./chunk-CN4RHVUE.mjs";import{d as t}from"./chunk-VNLGNNIL.mjs";async function d(){let r=t(e());if(!r)return;let o=await n.create({type:r});if(!o)throw new Error("Provider not found");i(o)}export{d as a};
2
+ //# sourceMappingURL=chunk-DELLFT6H.mjs.map
@@ -0,0 +1,2 @@
1
+ import{p as i}from"./chunk-J7P6SJOM.mjs";var e=async()=>{let o=i();if(o.getType()==="crossWindow"){let r=o;await r.cancelAction(),await r.dispose()}};export{e as a};
2
+ //# sourceMappingURL=chunk-GDSFFLIR.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as l}from"./chunk-Y2GZNJKO.mjs";import{a}from"./chunk-YUFPUG5O.mjs";import{a as c}from"./chunk-BQL3NILA.mjs";var p="Check if the MultiversX App is open on Ledger";async function v({manager:e,resolve:n,reject:d,shouldInitProvider:s}){let i=!c(),t=()=>v({manager:e,resolve:n,reject:d,shouldInitProvider:s}),o=()=>d("Device unavailable");try{e?.updateAccountScreen({isLoading:!0}),e&&i&&e.subscribeToProviderInit({handleRetry:t,handleCancel:o});let r=await l({shouldInitProvider:s});e&&i&&e.unsubscribeFromProviderInit({handleRetry:t,handleCancel:o}),n(r)}catch(r){if(!i)throw r;let{errorMessage:u,defaultErrorMessage:g}=a(r);e?.updateConnectScreen({error:u??g??p}),e&&e.subscribeToProviderInit({handleRetry:t,handleCancel:o})}}export{v as a};
2
- //# sourceMappingURL=chunk-D4MNCAND.mjs.map
1
+ import{a as l}from"./chunk-4NMRZJSQ.mjs";import{a}from"./chunk-YUFPUG5O.mjs";import{a as c}from"./chunk-BQL3NILA.mjs";var p="Check if the MultiversX App is open on Ledger";async function v({manager:e,resolve:n,reject:d,shouldInitProvider:s}){let i=!c(),t=()=>v({manager:e,resolve:n,reject:d,shouldInitProvider:s}),o=()=>d("Device unavailable");try{e?.updateAccountScreen({isLoading:!0}),e&&i&&e.subscribeToProviderInit({handleRetry:t,handleCancel:o});let r=await l({shouldInitProvider:s});e&&i&&e.unsubscribeFromProviderInit({handleRetry:t,handleCancel:o}),n(r)}catch(r){if(!i)throw r;let{errorMessage:u,defaultErrorMessage:g}=a(r);e?.updateConnectScreen({error:u??g??p}),e&&e.subscribeToProviderInit({handleRetry:t,handleCancel:o})}}export{v as a};
2
+ //# sourceMappingURL=chunk-HNEBEFTL.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as O}from"./chunk-WUAYFGWU.mjs";import{a as x}from"./chunk-YQTGKHGB.mjs";import{a as k}from"./chunk-IOKDBFGH.mjs";import{a as b}from"./chunk-5KRDLFR5.mjs";import{a as G}from"./chunk-QXC4D3AC.mjs";import{a as B}from"./chunk-ZMEIT65B.mjs";import{a as D}from"./chunk-BJRGP56G.mjs";import{a as I}from"./chunk-PDT22D2C.mjs";import{a as A}from"./chunk-MCZUQPRA.mjs";import{a as v}from"./chunk-LD4NALNZ.mjs";import{u as F}from"./chunk-CN4RHVUE.mjs";import{b as U}from"./chunk-SAAOQW7P.mjs";import{a as w}from"./chunk-2CNSQULM.mjs";import{c as N}from"./chunk-MGFIOCA4.mjs";async function Sn({transactions:j=[],handleSign:R,guardTransactions:_=v}){let{account:{address:y,shard:E,username:h}}=x(),u=U(F()),C=k(),{allTransactions:e,parsedTransactionsByDataField:L}=B(j),m=[],n=O.getInstance();if(await n.openUI(),!n)throw new Error("Unable to establish connection with sign screens");let z=async()=>{await b(),n.closeUI()};return n.subscribeToEventBus("CLOSE_SIGN_TRANSACTIONS",z),new Promise(async(H,M)=>{let d=[],K=await G({baseURL:u.apiAddress});n.notifyDataUpdate(),n.initializeGasPriceMap(e.map(t=>t.transaction));let l=K?.price,a=0,T=async()=>{let r=e[a]?.transaction,c=Number(r.nonce);n.updateIsLoading(!0);let{commonData:i,tokenTransaction:o,fungibleTransaction:s}=await D({allTransactions:e,currentScreenIndex:a,egldLabel:C,network:u,gasPriceData:n.ppuMap[c],price:l,address:y,username:h,shard:E,signedIndexes:m,parsedTransactionsByDataField:L});n.updateIsLoading(!1),o&&n.updateTokenTransaction(o),s&&n.updateNonFungibleTransaction(s.type,s),n.updateCommonData(i)},W=()=>{a>0&&(a--,T())},X=(t=0)=>{let c=e[a].transaction,i=Number(c.nonce);n.updateGasPriceMap({nonce:i,ppu:t}),n.updateCommonData({ppu:t});let o=c.toPlainObject(),s=I({transaction:o,gasPriceData:n.ppuMap[i]}),P=w.newFromPlainObject({...o,gasPrice:s}),p=A({transaction:P,price:l});n.updateCommonData({feeLimit:p.feeLimitFormatted,feeInFiatLimit:p.feeInFiatLimit,gasPrice:s.toString(),ppu:t})},Y=async()=>{M(new Error("Transaction signing cancelled by user")),await b(),n.closeUI()},f=()=>{a<n.transactionsCount-1&&(a++,T())},q=async()=>{let r=e[a].transaction,c=Number(r.nonce),{commonData:i}=await D({allTransactions:e,currentScreenIndex:a,egldLabel:C,network:u,gasPriceData:n.ppuMap[c],price:l,address:y,username:h,shard:E,signedIndexes:m,parsedTransactionsByDataField:L});if(!i.needsSigning)return m.push(a),f();let o=r.toPlainObject(),s=o.nonce,P=I({transaction:o,gasPriceData:n.ppuMap[s]}),p=w.newFromPlainObject({...o,gasPrice:P});try{let g=await R([p]);g&&(m.push(a),d.push(g[0]));let V=a===e.length-1,Z=e.filter(S=>S.needsSigning),$=d.length===Z.length;if(V&&$){let S=await _(d);return n.closeUI(),H(S)}f()}catch(g){n.closeUI(),M(g)}},J=new Map([["NEXT_SIGN_TRANSACTIONS",f],["CONFIRM_SIGN_TRANSACTIONS",q],["CLOSE_SIGN_TRANSACTIONS",Y],["BACK_SIGN_TRANSACTIONS",W],["SET_PPU_SIGN_TRANSACTIONS",X]]);function Q(){for(let[t,r]of J)n.subscribeToEventBus(t,r)}Q(),await T()})}export{Sn as a};
2
- //# sourceMappingURL=chunk-ZGNDECGJ.mjs.map
1
+ import{a as O}from"./chunk-WUAYFGWU.mjs";import{a as x}from"./chunk-YQTGKHGB.mjs";import{a as k}from"./chunk-IOKDBFGH.mjs";import{a as b}from"./chunk-GDSFFLIR.mjs";import{a as G}from"./chunk-QXC4D3AC.mjs";import{a as B}from"./chunk-ZMEIT65B.mjs";import{a as D}from"./chunk-YDXS2C4W.mjs";import{a as I}from"./chunk-PDT22D2C.mjs";import{a as A}from"./chunk-MCZUQPRA.mjs";import{a as v}from"./chunk-LD4NALNZ.mjs";import{u as F}from"./chunk-CN4RHVUE.mjs";import{b as U}from"./chunk-SAAOQW7P.mjs";import{a as w}from"./chunk-2CNSQULM.mjs";import{c as N}from"./chunk-MGFIOCA4.mjs";async function Sn({transactions:j=[],handleSign:R,guardTransactions:_=v}){let{account:{address:y,shard:E,username:h}}=x(),u=U(F()),C=k(),{allTransactions:e,parsedTransactionsByDataField:L}=B(j),m=[],n=O.getInstance();if(await n.openUI(),!n)throw new Error("Unable to establish connection with sign screens");let z=async()=>{await b(),n.closeUI()};return n.subscribeToEventBus("CLOSE_SIGN_TRANSACTIONS",z),new Promise(async(H,M)=>{let d=[],K=await G({baseURL:u.apiAddress});n.notifyDataUpdate(),n.initializeGasPriceMap(e.map(t=>t.transaction));let l=K?.price,a=0,T=async()=>{let r=e[a]?.transaction,c=Number(r.nonce);n.updateIsLoading(!0);let{commonData:i,tokenTransaction:o,fungibleTransaction:s}=await D({allTransactions:e,currentScreenIndex:a,egldLabel:C,network:u,gasPriceData:n.ppuMap[c],price:l,address:y,username:h,shard:E,signedIndexes:m,parsedTransactionsByDataField:L});n.updateIsLoading(!1),o&&n.updateTokenTransaction(o),s&&n.updateNonFungibleTransaction(s.type,s),n.updateCommonData(i)},W=()=>{a>0&&(a--,T())},X=(t=0)=>{let c=e[a].transaction,i=Number(c.nonce);n.updateGasPriceMap({nonce:i,ppu:t}),n.updateCommonData({ppu:t});let o=c.toPlainObject(),s=I({transaction:o,gasPriceData:n.ppuMap[i]}),P=w.newFromPlainObject({...o,gasPrice:s}),p=A({transaction:P,price:l});n.updateCommonData({feeLimit:p.feeLimitFormatted,feeInFiatLimit:p.feeInFiatLimit,gasPrice:s.toString(),ppu:t})},Y=async()=>{M(new Error("Transaction signing cancelled by user")),await b(),n.closeUI()},f=()=>{a<n.transactionsCount-1&&(a++,T())},q=async()=>{let r=e[a].transaction,c=Number(r.nonce),{commonData:i}=await D({allTransactions:e,currentScreenIndex:a,egldLabel:C,network:u,gasPriceData:n.ppuMap[c],price:l,address:y,username:h,shard:E,signedIndexes:m,parsedTransactionsByDataField:L});if(!i.needsSigning)return m.push(a),f();let o=r.toPlainObject(),s=o.nonce,P=I({transaction:o,gasPriceData:n.ppuMap[s]}),p=w.newFromPlainObject({...o,gasPrice:P});try{let g=await R([p]);g&&(m.push(a),d.push(g[0]));let V=a===e.length-1,Z=e.filter(S=>S.needsSigning),$=d.length===Z.length;if(V&&$){let S=await _(d);return n.closeUI(),H(S)}f()}catch(g){n.closeUI(),M(g)}},J=new Map([["NEXT_SIGN_TRANSACTIONS",f],["CONFIRM_SIGN_TRANSACTIONS",q],["CLOSE_SIGN_TRANSACTIONS",Y],["BACK_SIGN_TRANSACTIONS",W],["SET_PPU_SIGN_TRANSACTIONS",X]]);function Q(){for(let[t,r]of J)n.subscribeToEventBus(t,r)}Q(),await T()})}export{Sn as a};
2
+ //# sourceMappingURL=chunk-HWH2SKSH.mjs.map
@@ -0,0 +1,2 @@
1
+ import{a as F}from"./chunk-YPNKNMW5.mjs";import{a as v}from"./chunk-M3C5NS6M.mjs";import{a as b,b as D,g as R}from"./chunk-QD3CFFVT.mjs";import{a as _}from"./chunk-UFMHCVBL.mjs";import{b as l}from"./chunk-SBQJGS63.mjs";import{a as W}from"./chunk-672ZNZKR.mjs";import{a as V}from"./chunk-4ODPAHHA.mjs";import{a as G}from"./chunk-OTBTZ3NI.mjs";import{a as z}from"./chunk-WVTCO3AV.mjs";import{a as d}from"./chunk-N7KSN2OU.mjs";import{a as L}from"./chunk-6746F2FY.mjs";import{a as $}from"./chunk-CBIH5QMT.mjs";import{a as g}from"./chunk-R7SGL2HW.mjs";import{a as f,f as O}from"./chunk-YAXVLGG3.mjs";import{a as M}from"./chunk-TLKMUVQJ.mjs";import{b as U}from"./chunk-QI2QMNTG.mjs";import{a as T}from"./chunk-6FXEHNGW.mjs";import{a as B}from"./chunk-NJN53MJV.mjs";import{a as E}from"./chunk-YSCND2MX.mjs";import{a as h}from"./chunk-HORSXVIV.mjs";import{b as N,s as m,u as k}from"./chunk-CN4RHVUE.mjs";import{b as I}from"./chunk-IEJTMYFW.mjs";import{b as C,c as P,e as S}from"./chunk-2CNSQULM.mjs";import{b as j}from"./chunk-THQWNWSE.mjs";async function y({address:t,provider:o,apiAddress:r}){let e=await T({address:t,baseURL:r});if(!e)throw new Error("Account not found");U({address:t,providerType:o.getType()});let n={...e,username:h(e.username),nonce:g(e)};f(n),await l(t),v(),e.shard!=null&&await F({shard:Number(e.shard),apiAddress:r})}async function tt(t){let{network:{apiAddress:o}}=d();await t.login();let r=await t.getAddress();if(!r)throw new Error("Address not found");return await y({address:r,provider:t,apiAddress:o}),{address:r}}async function ot(t,o){let{network:{apiAddress:r}}=d(),e=M(o),n=await e.initialize({noCache:!0}),{address:s,signature:i,...c}=await t.login({token:n});if(!s)return console.warn("Login cancelled."),null;if(!i)return console.error("Failed to sign login token"),null;let a=e.getToken({address:s,token:n,signature:i});N({loginToken:n,signature:i,nativeAuthToken:a});let p=await W({loginToken:n,extraInfoData:{multisig:c?.multisig,impersonate:c?.impersonate},address:s});return await y({address:p,provider:t,apiAddress:r}),{address:p,signature:i}}async function K(t){let o=I(k());if(o)return await ot(t,o);let{address:r}=await tt(t);return await l(r),v(),{address:r}}var w={error:{title:"Error when signing".toString(),iconClassName:"danger",toastId:`${D}-${Date.now()}`},warning:{title:"Signing canceled".toString(),iconClassName:"warning",toastId:`${b}-${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"},et=t=>{for(let[o,r]of Object.entries(rt))if(t.includes(o))return r;return"Error when signing"};function A(t,o="error"){let r=t?.message,e=et(r),s=e!=="Error when signing"?"warning":o,i=Object.keys(w).includes(s)?w[s]:w.error,{toastId:c,iconClassName:a,title:p}=i;return H({toastId:c,duration:1e4,icon:"times",iconClassName:a,message:e,title:p}),e}async function q({provider:t,transactions:o,options:r={}}){await J();let{isGuarded:e,activeGuardianAddress:n,nonce:s}=$(),i=t.getType()==="ledger",c=V({latestNonce:s,transactions:o}),a=n&&e&&!r.skipGuardian?c?.map(u=>(u.version=C.withTxOptions().valueOf(),u.options=S.withOptions({guarded:!0,...i?{hashSign:!0}:{}}).valueOf(),u.guardian=P.newFromBech32(n),u)):c,p=await t.signTransactions(a)??[];return O(s+p.length),p}var x=class{constructor(o){this.provider=o}init(){return this.provider.init()}async login(){return await K(this.provider)}isInitialized(){return this.provider.isInitialized()}async logout(o={shouldBroadcastLogoutAcrossTabs:!0,hasConsentPopup:!1}){return await _({provider:this.provider,options:o})}setShouldShowConsentPopup(o){this.provider.setShouldShowConsentPopup?.(o)}getType(){return this.provider.getType()}getProvider(){return this.provider}async signTransactions(o,r){try{return await q({provider:this.provider,transactions:o,options:r})}catch(e){let n=A(e);throw new Error(n)}}async signMessage(o,r){try{return await z({provider:this.provider,message:o,options:r})}catch(e){let n=A(e,"warning");throw new Error(n)}}async verifyMessage(o){return await G(o)}async cancelLogin(){this.provider.cancelLogin?.()}};var Q=null;function To(t){Q=t}function X(){return Q||new x(j)}var nt=async()=>{try{let t=L(),{network:o}=d();try{let r=await T({address:t,baseURL:o.apiAddress});if(r!=null){let e={...r,username:h(r.username),nonce:g(r)};return f(e),e}}catch(r){console.error("Failed getting account ",r)}}catch(t){console.error("Failed getting address ",t)}return null};async function J(){let t=X();if(t==null)throw"Provider not initialized";try{if(!t.init)throw"Current provider does not have init() function";return await t.init()?nt():void 0}catch(o){console.error("Failed initializing provider ",o)}}var Y={},Z={},st=(t,o)=>{m().setState(({toasts:r})=>{let e=r.customToasts.length>0?Math.max(...r.customToasts.map(a=>parseInt(a.toastId.split("-").pop()??"0"))):0,n=o??`custom-toast-${e+1}`,s=r.customToasts.findIndex(a=>a.toastId===n),i={...t,toastId:n};if(s!==-1){r.customToasts[s]=i;return}r.customToasts.push({...i,toastId:n})},!1,"addCustomToast")},_o=t=>{m().setState(({toasts:o})=>{o.customToasts=o.customToasts.filter(r=>r.toastId!==t)},!1,"removeCustomToast")},zo=()=>{m().setState(({toasts:t})=>{t.customToasts=[]},!1,"removeAllCustomToasts")},Go=()=>{m().setState(({toasts:t})=>{t.transactionToasts=[]})},$o=({toastId:t,totalDuration:o})=>{m().setState(({toasts:r})=>{let e=r.transactionToasts.length>0?Math.max(...r.transactionToasts.map(s=>parseInt(s.toastId.split("-").pop()??"0"))):0,n=t||`transaction-toast-${e+1}`;r.transactionToasts.push({startTime:E(),endTime:B(o),toastId:n})},!1,"addTransactionToast")},Vo=t=>{m().setState(({toasts:o})=>{o.transactionToasts=o.transactionToasts.filter(r=>r.toastId!==t)},!1,"removeTransactionToast"),delete Z[t],delete Y[t]},H=t=>{let{toasts:o}=m().getState(),r=o.customToasts.length>0?Math.max(...o.customToasts.map(n=>parseInt(n.toastId.split("-").pop()??"0"))):0,e=t.toastId||`custom-toast-${r+1}`;return t.onClose&&(Z[e]=t.onClose),t.instantiateToastElement?(Y[e]=t.instantiateToastElement,m().setState(({toasts:n})=>{let s=n.customToasts.findIndex(a=>a.toastId===e),i={...t,instantiateToastElement:null,toastId:e};s!==-1?n.customToasts[s]=i:n.customToasts.push(i)},!1,"createCustomToast"),e):(st(t,e),e)};export{Y as a,Z as b,st as c,_o as d,zo as e,Go as f,$o as g,Vo as h,H as i,y as j,K as k,A as l,q as m,x as n,To as o,X as p,J as q};
2
+ //# sourceMappingURL=chunk-J7P6SJOM.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/providers/DappProvider/helpers/login/helpers/accountLogin.ts", "../../src/providers/DappProvider/helpers/login/login.ts", "../../src/providers/DappProvider/helpers/signErrors/handleSignError.ts", "../../src/providers/DappProvider/helpers/signTransactions/signTransactionsWithProvider.ts", "../../src/providers/DappProvider/DappProvider.ts", "../../src/providers/helpers/accountProvider.ts", "../../src/utils/account/refreshAccount.ts", "../../src/store/actions/toasts/toastsActions.ts"],
4
+ "sourcesContent": ["import { getLatestNonce } from 'methods/account/getLatestNonce';\nimport { setGasStationMetadata } from 'methods/initApp/gastStationMetadata/setGasStationMetadata';\nimport { registerWebsocketListener } from 'methods/initApp/websocket/registerWebsocket';\nimport { trackTransactions } from 'methods/trackTransactions/trackTransactions';\nimport { IProvider } from 'providers/types/providerFactory.types';\nimport { loginAction } from 'store/actions';\nimport { setAccount } from 'store/actions/account';\nimport { AccountType } from 'types/account.types';\nimport { fetchAccount } from 'utils/account/fetchAccount';\nimport { trimUsernameDomain } from 'utils/account/trimUsernameDomain';\n\ninterface IAccountLoginProps {\n address: string;\n provider: IProvider;\n apiAddress: string;\n}\n\nexport async function accountLogin({\n address,\n provider,\n apiAddress\n}: IAccountLoginProps) {\n const account = await fetchAccount({\n address,\n baseURL: apiAddress\n });\n\n if (!account) {\n throw new Error('Account not found');\n }\n\n loginAction({\n address,\n providerType: provider.getType()\n });\n\n const newAccount: AccountType = {\n ...account,\n username: trimUsernameDomain(account.username),\n nonce: getLatestNonce(account)\n };\n\n setAccount(newAccount);\n\n await registerWebsocketListener(address);\n trackTransactions();\n\n if (account.shard != null) {\n await setGasStationMetadata({\n shard: Number(account.shard),\n apiAddress\n });\n }\n}\n", "import { registerWebsocketListener } from 'methods/initApp/websocket/registerWebsocket';\nimport { getNetworkConfig } from 'methods/network/getNetworkConfig';\nimport { trackTransactions } from 'methods/trackTransactions/trackTransactions';\nimport { IProvider } from 'providers/types/providerFactory.types';\nimport { nativeAuth } from 'services/nativeAuth';\nimport { NativeAuthConfigType } from 'services/nativeAuth/nativeAuth.types';\nimport { setTokenLogin } from 'store/actions/loginInfo/loginInfoActions';\nimport { nativeAuthConfigSelector } from 'store/selectors';\nimport { getState } from 'store/store';\nimport { accountLogin } from './helpers/accountLogin';\nimport { extractAddressFromToken } from './helpers/extractAddressFromToken';\n\nasync function loginWithoutNativeToken(provider: IProvider) {\n const {\n network: { apiAddress }\n } = getNetworkConfig();\n\n await provider.login();\n\n const address = await provider.getAddress();\n\n if (!address) {\n throw new Error('Address not found');\n }\n\n await accountLogin({ address, provider, apiAddress });\n\n return {\n address\n };\n}\n\nasync function loginWithNativeToken(\n provider: IProvider,\n nativeAuthConfig: NativeAuthConfigType\n) {\n const {\n network: { apiAddress }\n } = getNetworkConfig();\n\n const nativeAuthClient = nativeAuth(nativeAuthConfig);\n\n const loginToken = await nativeAuthClient.initialize({\n noCache: true\n });\n\n const { address, signature, ...loginResult } = await provider.login({\n token: loginToken\n });\n\n if (!address) {\n console.warn('Login cancelled.');\n return null;\n }\n\n if (!signature) {\n console.error('Failed to sign login token');\n return null;\n }\n\n const nativeAuthToken = nativeAuthClient.getToken({\n address,\n token: loginToken,\n signature\n });\n\n setTokenLogin({\n loginToken,\n signature,\n nativeAuthToken\n });\n\n const extractedAddress = await extractAddressFromToken({\n loginToken,\n extraInfoData: {\n multisig: loginResult?.multisig,\n impersonate: loginResult?.impersonate\n },\n address\n });\n\n await accountLogin({\n address: extractedAddress,\n provider,\n apiAddress\n });\n\n return {\n address: extractedAddress,\n signature\n };\n}\n\nexport async function login(provider: IProvider) {\n const nativeAuthConfig = nativeAuthConfigSelector(getState());\n\n if (nativeAuthConfig) {\n return await loginWithNativeToken(provider, nativeAuthConfig);\n }\n\n const { address } = await loginWithoutNativeToken(provider);\n\n await registerWebsocketListener(address);\n trackTransactions();\n\n return { address };\n}\n", "import {\n CANCEL_TRANSACTION_TOAST_DEFAULT_DURATION,\n CANCEL_TRANSACTION_TOAST_ID,\n ERROR_SIGNING_TOAST_ID\n} from 'constants/transactions.constants';\nimport { ToastIconsEnum } from 'managers/internal/ToastManager/helpers/getToastDataStateByStatus';\nimport { createCustomToast } from 'store/actions';\nimport { SigningErrorsEnum, SigningWarningsEnum } from 'types/enums.types';\n\nconst states = {\n error: {\n title: SigningErrorsEnum.errorSigning.toString(),\n iconClassName: 'danger',\n toastId: `${ERROR_SIGNING_TOAST_ID}-${Date.now()}`\n },\n warning: {\n title: SigningWarningsEnum.cancelled.toString(),\n iconClassName: 'warning',\n toastId: `${CANCEL_TRANSACTION_TOAST_ID}-${Date.now()}`\n }\n};\n\nconst errorsMap = {\n extensionResponse: 'Unable to sign transactions', // extension\n 'Transaction canceled': 'Transaction canceled', // web wallet\n 'cancelled by user': 'Transaction signing cancelled by user', // custom\n 'denied by the user': 'Transaction signing denied by the user' // ledger\n};\n\nconst getUserError = (error: string) => {\n for (const [key, value] of Object.entries(errorsMap)) {\n if (error.includes(key)) {\n return value;\n }\n }\n return SigningErrorsEnum.errorSigning;\n};\n\nexport function handleSignError(\n error: unknown,\n type: 'error' | 'warning' = 'error'\n) {\n const originalError = (error as Error)?.message;\n const errorMessage = getUserError(originalError);\n\n const isKnownError = errorMessage !== SigningErrorsEnum.errorSigning;\n\n const errorType = isKnownError ? 'warning' : type;\n\n const state = Object.keys(states).includes(errorType)\n ? states[errorType]\n : states.error;\n\n const { toastId, iconClassName, title } = state;\n\n createCustomToast({\n toastId,\n duration: CANCEL_TRANSACTION_TOAST_DEFAULT_DURATION,\n icon: ToastIconsEnum.times,\n iconClassName,\n message: errorMessage,\n title\n });\n\n return errorMessage;\n}\n", "import {\n Address,\n Transaction,\n TransactionOptions,\n TransactionVersion\n} from 'lib/sdkCore';\nimport { getAccount } from 'methods/account/getAccount';\nimport {\n IProvider,\n ProviderTypeEnum\n} from 'providers/types/providerFactory.types';\nimport { setAccountNonce } from 'store/actions';\nimport { refreshAccount } from 'utils';\nimport { computeNonces } from '../computeNonces/computeNonces';\n\nexport type SignTransactionsOptionsType = {\n skipGuardian?: boolean;\n};\n\ntype SignTransactionsType = {\n provider: IProvider;\n transactions: Transaction[];\n options?: SignTransactionsOptionsType;\n};\n\nexport async function signTransactionsWithProvider({\n provider,\n transactions,\n options = {}\n}: SignTransactionsType): Promise<Transaction[]> {\n await refreshAccount();\n const { isGuarded, activeGuardianAddress, nonce } = getAccount();\n const isLedger = provider.getType() === ProviderTypeEnum.ledger;\n\n const transactionsWithComputedNonce = computeNonces({\n latestNonce: nonce,\n transactions\n });\n\n const transactionsToSign =\n activeGuardianAddress && isGuarded && !options.skipGuardian\n ? transactionsWithComputedNonce?.map((transaction) => {\n transaction.version = TransactionVersion.withTxOptions().valueOf();\n transaction.options = TransactionOptions.withOptions({\n guarded: true,\n ...(isLedger ? { hashSign: true } : {})\n }).valueOf();\n\n transaction.guardian = Address.newFromBech32(activeGuardianAddress);\n\n return transaction;\n })\n : transactionsWithComputedNonce;\n\n const signedTransactions: Transaction[] =\n (await provider.signTransactions(transactionsToSign)) ?? [];\n\n setAccountNonce(nonce + signedTransactions.length);\n\n return signedTransactions;\n}\n", "import { Message, Transaction } from 'lib/sdkCore';\nimport { IProvider } from '../types/providerFactory.types';\nimport { login } from './helpers/login/login';\nimport { logout } from './helpers/logout/logout';\nimport { handleSignError } from './helpers/signErrors/handleSignError';\nimport { signMessageWithProvider } from './helpers/signMessage/signMessageWithProvider';\nimport {\n verifyMessage,\n VerifyMessageReturnType\n} from './helpers/signMessage/verifyMessage';\nimport {\n signTransactionsWithProvider,\n SignTransactionsOptionsType\n} from './helpers/signTransactions/signTransactionsWithProvider';\n\nexport class DappProvider {\n private provider: IProvider;\n\n constructor(provider: IProvider) {\n this.provider = provider;\n }\n\n init() {\n return this.provider.init();\n }\n\n async login() {\n return await login(this.provider);\n }\n\n isInitialized() {\n return this.provider.isInitialized();\n }\n\n async logout(\n options = {\n shouldBroadcastLogoutAcrossTabs: true,\n hasConsentPopup: false\n }\n ) {\n return await logout({ provider: this.provider, options });\n }\n\n setShouldShowConsentPopup(shouldShow: boolean) {\n this.provider.setShouldShowConsentPopup?.(shouldShow);\n }\n\n getType() {\n return this.provider.getType();\n }\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 async verifyMessage(signedMessage: string): Promise<VerifyMessageReturnType> {\n return await verifyMessage(signedMessage);\n }\n\n async cancelLogin() {\n this.provider.cancelLogin?.();\n }\n}\n", "import { IProvider } from 'providers/types/providerFactory.types';\nimport { DappProvider } from '../DappProvider';\nimport { emptyProvider } from './emptyProvider';\n\nexport type ProvidersType = IProvider;\n\nlet accountProvider: DappProvider | null = null;\n\nexport function setAccountProvider<TProvider extends DappProvider | null>(\n provider: TProvider\n) {\n accountProvider = provider;\n}\n\nexport function getAccountProvider(): DappProvider {\n return accountProvider || new DappProvider(emptyProvider);\n}\n", "import { getAddress } from 'methods/account/getAddress';\nimport { getLatestNonce } from 'methods/account/getLatestNonce';\nimport { getNetworkConfig } from 'methods/network/getNetworkConfig';\nimport { getAccountProvider } from 'providers/helpers/accountProvider';\nimport { setAccount } from 'store/actions';\nimport { fetchAccount } from './fetchAccount';\nimport { trimUsernameDomain } from './trimUsernameDomain';\n\nconst setNewAccount = async () => {\n try {\n const address = getAddress();\n const { network } = getNetworkConfig();\n\n try {\n const account = await fetchAccount({\n address,\n baseURL: network.apiAddress\n });\n\n if (account != null) {\n const accountData = {\n ...account,\n username: trimUsernameDomain(account.username),\n nonce: getLatestNonce(account)\n };\n\n setAccount(accountData);\n\n return accountData;\n }\n } catch (e) {\n console.error('Failed getting account ', e);\n }\n } catch (e) {\n console.error('Failed getting address ', e);\n }\n\n return null;\n};\n\nexport async function refreshAccount() {\n const provider = getAccountProvider();\n\n if (provider == null) {\n throw 'Provider not initialized';\n }\n\n try {\n if (!provider.init) {\n throw 'Current provider does not have init() function';\n }\n\n const initialized = await provider.init();\n\n if (!initialized) {\n return;\n }\n\n return setNewAccount();\n } catch (e) {\n console.error('Failed initializing provider ', e);\n }\n\n return undefined;\n}\n", "import {\n CustomToastType,\n IComponentToast\n} from 'store/slices/toast/toastSlice.types';\nimport { getStore } from 'store/store';\nimport { getUnixTimestamp, getUnixTimestampWithAddedMilliseconds } from 'utils';\n\nexport const customToastComponentDictionary: Record<\n string,\n IComponentToast['instantiateToastElement']\n> = {};\nexport const customToastCloseHandlersDictionary: Record<string, () => void> =\n {};\n\nexport const addCustomToast = (\n customToast: CustomToastType,\n currentToastId?: string\n) => {\n getStore().setState(\n ({ toasts: state }) => {\n const lastToastIndex =\n state.customToasts.length > 0\n ? Math.max(\n ...state.customToasts.map((toast) =>\n parseInt(toast.toastId.split('-').pop() ?? '0')\n )\n )\n : 0;\n const toastId = currentToastId ?? `custom-toast-${lastToastIndex + 1}`;\n\n const existingToastIndex = state.customToasts.findIndex(\n (toast) => toast.toastId === toastId\n );\n\n const newToast: CustomToastType = {\n ...customToast,\n toastId\n };\n\n const isToastFound = existingToastIndex !== -1;\n\n if (isToastFound) {\n state.customToasts[existingToastIndex] = newToast;\n return;\n }\n\n state.customToasts.push({\n ...newToast,\n toastId\n });\n },\n false,\n 'addCustomToast'\n );\n};\n\nexport const removeCustomToast = (toastId: string) => {\n getStore().setState(\n ({ toasts: state }) => {\n state.customToasts = state.customToasts.filter(\n (toast) => toast.toastId !== toastId\n );\n },\n false,\n 'removeCustomToast'\n );\n};\n\nexport const removeAllCustomToasts = () => {\n getStore().setState(\n ({ toasts: state }) => {\n state.customToasts = [];\n },\n false,\n 'removeAllCustomToasts'\n );\n};\n\nexport const removeAllTransactionToasts = () => {\n getStore().setState(({ toasts: state }) => {\n state.transactionToasts = [];\n });\n};\n\nexport const addTransactionToast = ({\n toastId,\n totalDuration\n}: {\n toastId: string;\n totalDuration: number;\n}) => {\n getStore().setState(\n ({ toasts: state }) => {\n const lastToastIndex =\n state.transactionToasts.length > 0\n ? Math.max(\n ...state.transactionToasts.map((toast) =>\n parseInt(toast.toastId.split('-').pop() ?? '0')\n )\n )\n : 0;\n const newToastId = toastId || `transaction-toast-${lastToastIndex + 1}`;\n\n state.transactionToasts.push({\n startTime: getUnixTimestamp(),\n endTime: getUnixTimestampWithAddedMilliseconds(totalDuration),\n toastId: newToastId\n });\n },\n false,\n 'addTransactionToast'\n );\n};\n\nexport const removeTransactionToast = (toastId: string) => {\n getStore().setState(\n ({ toasts: state }) => {\n state.transactionToasts = state.transactionToasts.filter((toast) => {\n return toast.toastId !== toastId;\n });\n },\n false,\n 'removeTransactionToast'\n );\n\n delete customToastCloseHandlersDictionary[toastId];\n delete customToastComponentDictionary[toastId];\n};\n\nexport const createCustomToast = (props: CustomToastType) => {\n const { toasts } = getStore().getState();\n\n const lastToastIndex =\n toasts.customToasts.length > 0\n ? Math.max(\n ...toasts.customToasts.map((toast) =>\n parseInt(toast.toastId.split('-').pop() ?? '0')\n )\n )\n : 0;\n\n const toastId = props.toastId || `custom-toast-${lastToastIndex + 1}`;\n\n if (props.onClose) {\n customToastCloseHandlersDictionary[toastId] = props.onClose;\n }\n\n if (props.instantiateToastElement) {\n customToastComponentDictionary[toastId] = props.instantiateToastElement;\n\n getStore().setState(\n ({ toasts: state }) => {\n const existingToastIndex = state.customToasts.findIndex(\n (toast) => toast.toastId === toastId\n );\n\n const toast: CustomToastType = {\n ...props,\n instantiateToastElement: null,\n toastId\n };\n\n const isToastFound = existingToastIndex !== -1;\n\n if (isToastFound) {\n state.customToasts[existingToastIndex] = toast;\n } else {\n state.customToasts.push(toast);\n }\n },\n false,\n 'createCustomToast'\n );\n\n return toastId;\n }\n\n addCustomToast(props, toastId);\n return toastId;\n};\n"],
5
+ "mappings": "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",
6
+ "names": ["accountLogin", "address", "provider", "apiAddress", "account", "fetchAccount", "loginAction", "newAccount", "trimUsernameDomain", "getLatestNonce", "setAccount", "registerWebsocketListener", "trackTransactions", "setGasStationMetadata", "loginWithoutNativeToken", "provider", "apiAddress", "getNetworkConfig", "address", "accountLogin", "loginWithNativeToken", "nativeAuthConfig", "nativeAuthClient", "nativeAuth", "loginToken", "signature", "loginResult", "nativeAuthToken", "setTokenLogin", "extractedAddress", "extractAddressFromToken", "login", "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", "transactionsWithComputedNonce", "computeNonces", "transactionsToSign", "transaction", "TransactionVersion", "TransactionOptions", "Address", "signedTransactions", "setAccountNonce", "DappProvider", "provider", "login", "options", "logout", "shouldShow", "transactions", "signTransactionsWithProvider", "error", "errorMessage", "handleSignError", "message", "signMessageWithProvider", "signedMessage", "verifyMessage", "accountProvider", "setAccountProvider", "provider", "getAccountProvider", "DappProvider", "emptyProvider", "setNewAccount", "address", "getAddress", "network", "getNetworkConfig", "account", "fetchAccount", "accountData", "trimUsernameDomain", "getLatestNonce", "setAccount", "e", "refreshAccount", "provider", "getAccountProvider", "customToastComponentDictionary", "customToastCloseHandlersDictionary", "addCustomToast", "customToast", "currentToastId", "getStore", "state", "lastToastIndex", "toast", "toastId", "existingToastIndex", "newToast", "removeCustomToast", "removeAllCustomToasts", "removeAllTransactionToasts", "addTransactionToast", "totalDuration", "newToastId", "getUnixTimestamp", "getUnixTimestampWithAddedMilliseconds", "removeTransactionToast", "createCustomToast", "props", "toasts"]
7
+ }
@@ -1,2 +1,2 @@
1
- import{a as p}from"./chunk-ZIQFQWVJ.mjs";import{b as v}from"./chunk-4Z3DZ2A3.mjs";import{i as n,n as d,o as l,p as o}from"./chunk-57KVKSEC.mjs";import{s,u as a}from"./chunk-CN4RHVUE.mjs";import{a as i}from"./chunk-LTF535HP.mjs";import{a as c}from"./chunk-VNLGNNIL.mjs";var u=3e4,C=5e3,I=3e3,g=class t{constructor(){this.store=s();this.connectionCheckInterval=null;this.recreateProviderInterval=null;this.init=async()=>{this.startCheckConnectionLoop()};this.shouldCheckConnection=()=>{let{providerType:r}=c(this.store.getState()),e=i(this.store.getState()).address;return!!(r==="ledger"&&e)};this.startCheckConnectionLoop=()=>{this.connectionCheckInterval||(this.connectionCheckInterval=setInterval(async()=>{let r=v(a());if(!(!this.shouldCheckConnection()||r))try{await o().getProvider().getAddress()}catch{if(n({toastId:"ledger-provider-idle-warning",icon:"times",iconClassName:"warning",message:"Unlock your device to continue signing transactions",title:"Ledger disconnected"}),this.reset(),this.recreateProviderInterval)return;this.recreateProviderInterval=setInterval(this.reconnectProvider,C)}},u))};this.getLedgerAddress=async()=>this.shouldCheckConnection()?await o().getProvider().getAddress():void 0;this.reconnectProvider=async()=>{if(this.shouldCheckConnection())try{let e=await new p().createProvider({shouldInitProvider:!0}),h=new d(e);e.getType=()=>"ledger",l(h),this.reset(),clearInterval(this.recreateProviderInterval??0),this.recreateProviderInterval=null,n({toastId:"ledger-provider-idle-warning",duration:I,icon:"check",iconClassName:"success",message:"Your device is ready to sign transactions",title:"Ledger reconnected"}),this.startCheckConnectionLoop()}catch{console.log("Unable to reconnect to Ledger")}};this.reset=()=>{clearInterval(this.connectionCheckInterval??0),this.connectionCheckInterval=null}}static getInstance(){return t.instance||(t.instance=new t),t.instance}};export{g as a};
2
- //# sourceMappingURL=chunk-G7ZMNJIE.mjs.map
1
+ import{a as p}from"./chunk-TCCW2HZK.mjs";import{b as v}from"./chunk-4Z3DZ2A3.mjs";import{i as n,n as d,o as l,p as o}from"./chunk-J7P6SJOM.mjs";import{s,u as a}from"./chunk-CN4RHVUE.mjs";import{a as i}from"./chunk-LTF535HP.mjs";import{a as c}from"./chunk-VNLGNNIL.mjs";var u=3e4,C=5e3,I=3e3,g=class t{constructor(){this.store=s();this.connectionCheckInterval=null;this.recreateProviderInterval=null;this.init=async()=>{this.startCheckConnectionLoop()};this.shouldCheckConnection=()=>{let{providerType:r}=c(this.store.getState()),e=i(this.store.getState()).address;return!!(r==="ledger"&&e)};this.startCheckConnectionLoop=()=>{this.connectionCheckInterval||(this.connectionCheckInterval=setInterval(async()=>{let r=v(a());if(!(!this.shouldCheckConnection()||r))try{await o().getProvider().getAddress()}catch{if(n({toastId:"ledger-provider-idle-warning",icon:"times",iconClassName:"warning",message:"Unlock your device to continue signing transactions",title:"Ledger disconnected"}),this.reset(),this.recreateProviderInterval)return;this.recreateProviderInterval=setInterval(this.reconnectProvider,C)}},u))};this.getLedgerAddress=async()=>this.shouldCheckConnection()?await o().getProvider().getAddress():void 0;this.reconnectProvider=async()=>{if(this.shouldCheckConnection())try{let e=await new p().createProvider({shouldInitProvider:!0}),h=new d(e);e.getType=()=>"ledger",l(h),this.reset(),clearInterval(this.recreateProviderInterval??0),this.recreateProviderInterval=null,n({toastId:"ledger-provider-idle-warning",duration:I,icon:"check",iconClassName:"success",message:"Your device is ready to sign transactions",title:"Ledger reconnected"}),this.startCheckConnectionLoop()}catch{console.log("Unable to reconnect to Ledger")}};this.reset=()=>{clearInterval(this.connectionCheckInterval??0),this.connectionCheckInterval=null}}static getInstance(){return t.instance||(t.instance=new t),t.instance}};export{g as a};
2
+ //# sourceMappingURL=chunk-MJGS5LXB.mjs.map
@@ -0,0 +1,2 @@
1
+ import{u as o}from"./chunk-CN4RHVUE.mjs";import{a as t}from"./chunk-SAAOQW7P.mjs";function f(r=o()){return t(r)}export{f as a};
2
+ //# sourceMappingURL=chunk-N7KSN2OU.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/methods/network/getNetworkConfig.ts"],
4
+ "sourcesContent": ["import { networkConfigSelector } from 'store/selectors/networkSelectors';\nimport { getState } from 'store/store';\n\nexport function getNetworkConfig(state = getState()) {\n return networkConfigSelector(state);\n}\n"],
5
+ "mappings": "kFAGO,SAASA,EAAiBC,EAAQC,EAAS,EAAG,CACnD,OAAOC,EAAsBF,CAAK,CACpC",
6
+ "names": ["getNetworkConfig", "state", "getState", "networkConfigSelector"]
7
+ }
@@ -0,0 +1,2 @@
1
+ import{a as w}from"./chunk-QXC4D3AC.mjs";import{a as g}from"./chunk-YGI3KXMZ.mjs";import{a as b}from"./chunk-N7KSN2OU.mjs";import{a as f}from"./chunk-6FXEHNGW.mjs";import{f as m}from"./chunk-K3G3SPRT.mjs";import x from"bignumber.js";var v=async({manager:e,provider:d})=>{if(!e||!d)throw new Error("Provider is not initialized.");let{network:u}=b(),n=e.getAccountScreenData()?.startIndex||0,r=e.getAllAccounts(),a=await w({baseURL:u.apiAddress}),l=c=>c.index>=n&&c.index<n+e.addressesPerPage,I=r.reduce((c,s)=>Object.assign(c,{[s.index]:s}),{}),A=r.filter(l),y=!!I[n];if(e.updateAccountScreen({isLoading:!y}),A.length>0){e.updateAccountScreen({accounts:A});return}try{let c=await d.getAccounts(n,e.addressesPerPage),s=c.map((t,o)=>({address:t,balance:"...",index:o+n})),L=[...r,...s],j=c.map(t=>f({address:t,baseURL:u.apiAddress})),O=await Promise.all(j),i=L.reduce((t,o)=>Object.assign(t,{[o.address]:o}),{});O.forEach(t=>{if(!t||!a||!a.price)return;let o=new x(t.balance),U=o.dividedBy(x(10).pow(18)).toFormat(4).toString();if(o.isNaN())return;let h=g({amount:m({input:t.balance}),usd:a?.price});i[t.address].balance=U,i[t.address].usdValue=h});let p=Object.values(i).sort((t,o)=>t.index-o.index),S=p.filter(l);e.updateAllAccounts(p),e.updateAccountScreen({accounts:S,isLoading:!1})}catch(c){console.error("Failed to fetch accounts:",c)}};export{v as a};
2
+ //# sourceMappingURL=chunk-OZ3OBQJ6.mjs.map
@@ -0,0 +1,7 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../../src/providers/strategies/LedgerProviderStrategy/helpers/updateAccountsList/updateAccountsList.ts"],
4
+ "sourcesContent": ["import BigNumber from 'bignumber.js';\n\nimport { getEconomics } from 'apiCalls/economics/getEconomics';\nimport { formatAmount } from 'lib/sdkDappUtils';\nimport { getNetworkConfig } from 'methods/network/getNetworkConfig';\nimport { ProviderErrorsEnum } from 'types';\nimport { fetchAccount } from 'utils/account/fetchAccount';\nimport { getUsdValue } from 'utils/operations/getUsdValue';\n\nimport {\n IUpdateAccountsList,\n UpdateAccountObjectType\n} from './updateAccountsList.types';\nimport { ILedgerAccount } from '../../types/ledger.types';\n\n/**\n * Updates the list of accounts and fetches their balances.\n *\n * This function performs the following steps:\n * 1. Checks if the manager and provider are initialized; if not, throws an error.\n * 2. Retrieves the starting index for pagination and the current list of accounts.\n * 3. Checks if there is already data for the current page to avoid unnecessary fetching.\n * 4. If no data is present, it fetches the accounts from the wallet provider.\n * 5. Updates the state manager with the new account data and their balances.\n * 6. Handles errors by reverting to existing accounts and logging the error.\n */\nexport const updateAccountsList = async ({\n manager,\n provider\n}: IUpdateAccountsList) => {\n if (!manager || !provider) {\n throw new Error(ProviderErrorsEnum.notInitialized);\n }\n\n const { network } = getNetworkConfig();\n const startIndex = manager.getAccountScreenData()?.startIndex || 0;\n const allAccounts = manager.getAllAccounts();\n const economics = await getEconomics({ baseURL: network.apiAddress });\n\n const filterByStartIndexRange = (account: ILedgerAccount) =>\n account.index >= startIndex &&\n account.index < startIndex + manager.addressesPerPage;\n\n const allAccountsObject = allAccounts.reduce(\n (accountsObject: UpdateAccountObjectType, account) =>\n Object.assign(accountsObject, { [account.index]: account }),\n {}\n );\n\n const currentAccounts = allAccounts.filter(filterByStartIndexRange);\n const isStartIndexInAccounts = Boolean(allAccountsObject[startIndex]);\n\n manager.updateAccountScreen({\n isLoading: !isStartIndexInAccounts\n });\n\n if (currentAccounts.length > 0) {\n manager.updateAccountScreen({ accounts: currentAccounts });\n return;\n }\n\n try {\n const accountsArray = await provider.getAccounts(\n startIndex,\n manager.addressesPerPage\n );\n\n const accountsWithBalance = accountsArray.map(\n (address, accountIindex): ILedgerAccount => ({\n address,\n balance: '...',\n index: accountIindex + startIndex\n })\n );\n\n const newAllAccounts = [...allAccounts, ...accountsWithBalance];\n const balancePromises = accountsArray.map((address) =>\n fetchAccount({ address, baseURL: network.apiAddress })\n );\n\n const balances = await Promise.all(balancePromises);\n const newAllAccountsObject = newAllAccounts.reduce(\n (accountsObject: UpdateAccountObjectType, account) =>\n Object.assign(accountsObject, { [account.address]: account }),\n\n {}\n );\n\n balances.forEach((account) => {\n if (!account || !economics || !economics.price) {\n return;\n }\n\n const balanceBigNumber = new BigNumber(account.balance);\n const formattedBalance = balanceBigNumber\n .dividedBy(BigNumber(10).pow(18))\n .toFormat(4)\n .toString();\n\n if (balanceBigNumber.isNaN()) {\n return;\n }\n\n const usdValue = getUsdValue({\n amount: formatAmount({ input: account.balance }),\n usd: economics?.price\n });\n\n newAllAccountsObject[account.address].balance = formattedBalance;\n newAllAccountsObject[account.address].usdValue = usdValue;\n });\n\n const newAllAccountsArray = Object.values(newAllAccountsObject).sort(\n (alpha, beta) => alpha.index - beta.index\n );\n\n const accountsScreenArray = newAllAccountsArray.filter(\n filterByStartIndexRange\n );\n\n manager.updateAllAccounts(newAllAccountsArray);\n manager.updateAccountScreen({\n accounts: accountsScreenArray,\n isLoading: false\n });\n } catch (error) {\n console.error('Failed to fetch accounts:', error);\n }\n};\n"],
5
+ "mappings": "6MAAA,OAAOA,MAAe,eA0Bf,IAAMC,EAAqB,MAAO,CACvC,QAAAC,EACA,SAAAC,CACF,IAA2B,CACzB,GAAI,CAACD,GAAW,CAACC,EACf,MAAM,IAAI,oCAAuC,EAGnD,GAAM,CAAE,QAAAC,CAAQ,EAAIC,EAAiB,EAC/BC,EAAaJ,EAAQ,qBAAqB,GAAG,YAAc,EAC3DK,EAAcL,EAAQ,eAAe,EACrCM,EAAY,MAAMC,EAAa,CAAE,QAASL,EAAQ,UAAW,CAAC,EAE9DM,EAA2BC,GAC/BA,EAAQ,OAASL,GACjBK,EAAQ,MAAQL,EAAaJ,EAAQ,iBAEjCU,EAAoBL,EAAY,OACpC,CAACM,EAAyCF,IACxC,OAAO,OAAOE,EAAgB,CAAE,CAACF,EAAQ,KAAK,EAAGA,CAAQ,CAAC,EAC5D,CAAC,CACH,EAEMG,EAAkBP,EAAY,OAAOG,CAAuB,EAC5DK,EAAyB,EAAQH,EAAkBN,CAAU,EAMnE,GAJAJ,EAAQ,oBAAoB,CAC1B,UAAW,CAACa,CACd,CAAC,EAEGD,EAAgB,OAAS,EAAG,CAC9BZ,EAAQ,oBAAoB,CAAE,SAAUY,CAAgB,CAAC,EACzD,MACF,CAEA,GAAI,CACF,IAAME,EAAgB,MAAMb,EAAS,YACnCG,EACAJ,EAAQ,gBACV,EAEMe,EAAsBD,EAAc,IACxC,CAACE,EAASC,KAAmC,CAC3C,QAAAD,EACA,QAAS,MACT,MAAOC,EAAgBb,CACzB,EACF,EAEMc,EAAiB,CAAC,GAAGb,EAAa,GAAGU,CAAmB,EACxDI,EAAkBL,EAAc,IAAKE,GACzCI,EAAa,CAAE,QAAAJ,EAAS,QAASd,EAAQ,UAAW,CAAC,CACvD,EAEMmB,EAAW,MAAM,QAAQ,IAAIF,CAAe,EAC5CG,EAAuBJ,EAAe,OAC1C,CAACP,EAAyCF,IACxC,OAAO,OAAOE,EAAgB,CAAE,CAACF,EAAQ,OAAO,EAAGA,CAAQ,CAAC,EAE9D,CAAC,CACH,EAEAY,EAAS,QAASZ,GAAY,CAC5B,GAAI,CAACA,GAAW,CAACH,GAAa,CAACA,EAAU,MACvC,OAGF,IAAMiB,EAAmB,IAAIC,EAAUf,EAAQ,OAAO,EAChDgB,EAAmBF,EACtB,UAAUC,EAAU,EAAE,EAAE,IAAI,EAAE,CAAC,EAC/B,SAAS,CAAC,EACV,SAAS,EAEZ,GAAID,EAAiB,MAAM,EACzB,OAGF,IAAMG,EAAWC,EAAY,CAC3B,OAAQC,EAAa,CAAE,MAAOnB,EAAQ,OAAQ,CAAC,EAC/C,IAAKH,GAAW,KAClB,CAAC,EAEDgB,EAAqBb,EAAQ,OAAO,EAAE,QAAUgB,EAChDH,EAAqBb,EAAQ,OAAO,EAAE,SAAWiB,CACnD,CAAC,EAED,IAAMG,EAAsB,OAAO,OAAOP,CAAoB,EAAE,KAC9D,CAACQ,EAAOC,IAASD,EAAM,MAAQC,EAAK,KACtC,EAEMC,EAAsBH,EAAoB,OAC9CrB,CACF,EAEAR,EAAQ,kBAAkB6B,CAAmB,EAC7C7B,EAAQ,oBAAoB,CAC1B,SAAUgC,EACV,UAAW,EACb,CAAC,CACH,OAASC,EAAO,CACd,QAAQ,MAAM,4BAA6BA,CAAK,CAClD,CACF",
6
+ "names": ["BigNumber", "updateAccountsList", "manager", "provider", "network", "getNetworkConfig", "startIndex", "allAccounts", "economics", "getEconomics", "filterByStartIndexRange", "account", "allAccountsObject", "accountsObject", "currentAccounts", "isStartIndexInAccounts", "accountsArray", "accountsWithBalance", "address", "accountIindex", "newAllAccounts", "balancePromises", "fetchAccount", "balances", "newAllAccountsObject", "balanceBigNumber", "BigNumber", "formattedBalance", "usdValue", "getUsdValue", "formatAmount", "newAllAccountsArray", "alpha", "beta", "accountsScreenArray", "error"]
7
+ }
@@ -1,2 +1,2 @@
1
- import{a as M}from"./chunk-JO3DZYEB.mjs";import{a as T}from"./chunk-PMPTCB44.mjs";import{a as O}from"./chunk-XCXU3BVP.mjs";import{a as F}from"./chunk-SVNWQXWC.mjs";import{a as g,b as v,d as b,e as C,g as I,h as N}from"./chunk-57KVKSEC.mjs";import{d as E}from"./chunk-AGI2ZR6R.mjs";import{k as l,l as d,n as f}from"./chunk-65L5EBBL.mjs";import{s as c}from"./chunk-CN4RHVUE.mjs";import{a as S}from"./chunk-YMME2BFO.mjs";import p from"lodash.isequal";import A from"lodash.isequal";var L="NOTIFICATIONS_FEED_STORE_SUBSCRIBE",u=class n extends F{constructor(){super({uiDataUpdateEvent:"OPEN_NOTIFICATIONS_FEED",uiTag:"mvx-notifications-feed"});this.store=c();this.initialData={pendingTransactions:[],historicTransactions:[]};this.data={...this.initialData}}static getInstance(){return n.instance||(n.instance=new n),n.instance}isNotificationsFeedOpen(){return this.isOpen}async openNotificationsFeed(){r.getInstance().hideToasts(),await this.openUI(),await this.updateDataAndNotifications();let i=this.store.subscribe(async({toasts:a,transactions:e},{toasts:o,transactions:h})=>{(!A(o.transactionToasts,a.transactionToasts)||!A(h,e))&&await this.updateDataAndNotifications()});this.unsubscribeFunctions.set(L,[i]),this.eventBus?.publish("OPEN_NOTIFICATIONS_FEED"),await this.updateDataAndNotifications()}handleCloseUI(){let s=r.getInstance();this.closeUI(),s.showToasts()}async setupEventListeners(){this.eventBus&&(this.subscribeToEventBus("CLOSE_NOTIFICATIONS_FEED",this.handleCloseUI.bind(this)),this.subscribeToEventBus("CLEAR_NOTIFICATIONS_FEED_HISTORY",this.handleClearNotificationsFeedHistory.bind(this)))}async updateDataAndNotifications(){let{transactions:s,account:i,toasts:a,network:e}=this.store.getState(),{pendingTransactionToasts:o}=await T({toastList:a,transactionsSessions:s,account:i});this.data.pendingTransactions=o,this.data.historicTransactions=await M.getTransactionsHistory({transactionsSessions:s,address:i.address,explorerAddress:e.network.explorerAddress,egldLabel:e.network.egldLabel}),await this.updateNotificationsFeed()}handleClearNotificationsFeedHistory(){E(),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))}};var r=class n{constructor(){this.isCreatingElement=!1;this.toastsElement=null;this.transactionToasts=[];this.customToasts=[];this.storeToastsSubscription=()=>null;this.eventBusUnsubscribeFunctions=[];this.eventBus=null;this.store=c();this.destroy(),this.lifetimeManager=new O,this.notificationsFeedManager=u.getInstance()}async init({successfulToastLifetime:t}={}){this.successfulToastLifetime=t,this.lifetimeManager.init({successfulToastLifetime:t}),this.updateTransactionToastsList(),this.updateCustomToastList(),await this.subscribeToEventBusNotifications(),this.storeToastsSubscription=this.store.subscribe(({toasts:s,transactions:i},{toasts:a,transactions:e})=>{(!p(a.transactionToasts,s.transactionToasts)||!p(e,i))&&this.updateTransactionToastsList(),p(a.customToasts,s.customToasts)||this.updateCustomToastList()})}static getInstance(){return n.instance||(n.instance=new n),n.instance}handleCompletedTransaction(t){let{transactions:s}=this.store.getState(),i=s[t];if(!i)return!1;let{status:a}=i,e=f(a),o=d(a),h=l(a),m=o||h||e;return m?(this.successfulToastLifetime&&this.lifetimeManager.start(t),m):(this.lifetimeManager.stop(t),m)}createTransactionToast(t,s){I({toastId:t,totalDuration:s}),this.handleCompletedTransaction(t),this.updateTransactionToastsList()}async updateTransactionToastsList(){let{toasts:t,transactions:s,account:i}=this.store.getState(),{pendingTransactionToasts:a,completedTransactionToasts:e}=await T({toastList:t,transactionsSessions:s,account:i});this.transactionToasts=[...a,...e];for(let o of t.transactionToasts)this.handleCompletedTransaction(o.toastId);await this.publishTransactionToasts()}async updateCustomToastList(){let{toasts:t}=this.store.getState();this.customToasts=[];for(let s of t.customToasts){let a="message"in s?{...s}:{...s,instantiateToastElement:g[s.toastId]};this.customToasts.push(a),s.duration&&this.lifetimeManager.startWithCustomDuration(s.toastId,s.duration)}this.eventBus?.publish("CUSTOM_TOAST_DATA_UPDATE",this.customToasts)}async createToastListElement(){return this.toastsElement?this.toastsElement:(this.isCreatingElement||(this.isCreatingElement=!0,this.toastsElement=await S({name:"mvx-toast-list"}),this.isCreatingElement=!1),this.toastsElement)}handleTransactionToastClose(t){this.handleCompletedTransaction(t)&&N(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.handleCloseToast.bind(this)),this.eventBusUnsubscribeFunctions.push(()=>{this.eventBus?.unsubscribe("CLOSE_TOAST",this.handleCloseToast.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))})}}showToasts(){this.updateCustomToastList(),this.updateTransactionToastsList()}hideToasts(){this.transactionToasts=[],this.customToasts=[],this.eventBus?.publish("TRANSACTION_TOAST_DATA_UPDATE",this.transactionToasts),this.eventBus?.publish("CUSTOM_TOAST_DATA_UPDATE",this.customToasts)}async handleOpenNotificationsFeed(){this.notificationsFeedManager.openNotificationsFeed()}handleCloseToast(t){if(this.customToasts.find(i=>i.toastId===t)){this.lifetimeManager.stop(t);let i=v[t];i?.(),b(t);return}this.handleTransactionToastClose(t)}async publishTransactionToasts(){if(!this.notificationsFeedManager.isNotificationsFeedOpen()){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(),C(),this.eventBusUnsubscribeFunctions.forEach(t=>t()),this.eventBusUnsubscribeFunctions=[]}};export{u as a,r as b};
2
- //# sourceMappingURL=chunk-XKTDOIMV.mjs.map
1
+ import{a as M}from"./chunk-JO3DZYEB.mjs";import{a as T}from"./chunk-PMPTCB44.mjs";import{a as O}from"./chunk-CRSZQV7V.mjs";import{a as F}from"./chunk-SVNWQXWC.mjs";import{a as g,b as v,d as b,e as C,g as I,h as N}from"./chunk-J7P6SJOM.mjs";import{d as E}from"./chunk-AGI2ZR6R.mjs";import{k as l,l as d,n as f}from"./chunk-65L5EBBL.mjs";import{s as c}from"./chunk-CN4RHVUE.mjs";import{a as S}from"./chunk-YMME2BFO.mjs";import p from"lodash.isequal";import A from"lodash.isequal";var L="NOTIFICATIONS_FEED_STORE_SUBSCRIBE",u=class n extends F{constructor(){super({uiDataUpdateEvent:"OPEN_NOTIFICATIONS_FEED",uiTag:"mvx-notifications-feed"});this.store=c();this.initialData={pendingTransactions:[],historicTransactions:[]};this.data={...this.initialData}}static getInstance(){return n.instance||(n.instance=new n),n.instance}isNotificationsFeedOpen(){return this.isOpen}async openNotificationsFeed(){r.getInstance().hideToasts(),await this.openUI(),await this.updateDataAndNotifications();let i=this.store.subscribe(async({toasts:a,transactions:e},{toasts:o,transactions:h})=>{(!A(o.transactionToasts,a.transactionToasts)||!A(h,e))&&await this.updateDataAndNotifications()});this.unsubscribeFunctions.set(L,[i]),this.eventBus?.publish("OPEN_NOTIFICATIONS_FEED"),await this.updateDataAndNotifications()}handleCloseUI(){let s=r.getInstance();this.closeUI(),s.showToasts()}async setupEventListeners(){this.eventBus&&(this.subscribeToEventBus("CLOSE_NOTIFICATIONS_FEED",this.handleCloseUI.bind(this)),this.subscribeToEventBus("CLEAR_NOTIFICATIONS_FEED_HISTORY",this.handleClearNotificationsFeedHistory.bind(this)))}async updateDataAndNotifications(){let{transactions:s,account:i,toasts:a,network:e}=this.store.getState(),{pendingTransactionToasts:o}=await T({toastList:a,transactionsSessions:s,account:i});this.data.pendingTransactions=o,this.data.historicTransactions=await M.getTransactionsHistory({transactionsSessions:s,address:i.address,explorerAddress:e.network.explorerAddress,egldLabel:e.network.egldLabel}),await this.updateNotificationsFeed()}handleClearNotificationsFeedHistory(){E(),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))}};var r=class n{constructor(){this.isCreatingElement=!1;this.toastsElement=null;this.transactionToasts=[];this.customToasts=[];this.storeToastsSubscription=()=>null;this.eventBusUnsubscribeFunctions=[];this.eventBus=null;this.store=c();this.destroy(),this.lifetimeManager=new O,this.notificationsFeedManager=u.getInstance()}async init({successfulToastLifetime:t}={}){this.successfulToastLifetime=t,this.lifetimeManager.init({successfulToastLifetime:t}),this.updateTransactionToastsList(),this.updateCustomToastList(),await this.subscribeToEventBusNotifications(),this.storeToastsSubscription=this.store.subscribe(({toasts:s,transactions:i},{toasts:a,transactions:e})=>{(!p(a.transactionToasts,s.transactionToasts)||!p(e,i))&&this.updateTransactionToastsList(),p(a.customToasts,s.customToasts)||this.updateCustomToastList()})}static getInstance(){return n.instance||(n.instance=new n),n.instance}handleCompletedTransaction(t){let{transactions:s}=this.store.getState(),i=s[t];if(!i)return!1;let{status:a}=i,e=f(a),o=d(a),h=l(a),m=o||h||e;return m?(this.successfulToastLifetime&&this.lifetimeManager.start(t),m):(this.lifetimeManager.stop(t),m)}createTransactionToast(t,s){I({toastId:t,totalDuration:s}),this.handleCompletedTransaction(t),this.updateTransactionToastsList()}async updateTransactionToastsList(){let{toasts:t,transactions:s,account:i}=this.store.getState(),{pendingTransactionToasts:a,completedTransactionToasts:e}=await T({toastList:t,transactionsSessions:s,account:i});this.transactionToasts=[...a,...e];for(let o of t.transactionToasts)this.handleCompletedTransaction(o.toastId);await this.publishTransactionToasts()}async updateCustomToastList(){let{toasts:t}=this.store.getState();this.customToasts=[];for(let s of t.customToasts){let a="message"in s?{...s}:{...s,instantiateToastElement:g[s.toastId]};this.customToasts.push(a),s.duration&&this.lifetimeManager.startWithCustomDuration(s.toastId,s.duration)}this.eventBus?.publish("CUSTOM_TOAST_DATA_UPDATE",this.customToasts)}async createToastListElement(){return this.toastsElement?this.toastsElement:(this.isCreatingElement||(this.isCreatingElement=!0,this.toastsElement=await S({name:"mvx-toast-list"}),this.isCreatingElement=!1),this.toastsElement)}handleTransactionToastClose(t){this.handleCompletedTransaction(t)&&N(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.handleCloseToast.bind(this)),this.eventBusUnsubscribeFunctions.push(()=>{this.eventBus?.unsubscribe("CLOSE_TOAST",this.handleCloseToast.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))})}}showToasts(){this.updateCustomToastList(),this.updateTransactionToastsList()}hideToasts(){this.transactionToasts=[],this.customToasts=[],this.eventBus?.publish("TRANSACTION_TOAST_DATA_UPDATE",this.transactionToasts),this.eventBus?.publish("CUSTOM_TOAST_DATA_UPDATE",this.customToasts)}async handleOpenNotificationsFeed(){this.notificationsFeedManager.openNotificationsFeed()}handleCloseToast(t){if(this.customToasts.find(i=>i.toastId===t)){this.lifetimeManager.stop(t);let i=v[t];i?.(),b(t);return}this.handleTransactionToastClose(t)}async publishTransactionToasts(){if(!this.notificationsFeedManager.isNotificationsFeedOpen()){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(),C(),this.eventBusUnsubscribeFunctions.forEach(t=>t()),this.eventBusUnsubscribeFunctions=[]}};export{u as a,r as b};
2
+ //# sourceMappingURL=chunk-PBIRC7U4.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as L}from"./chunk-MHCIV2K5.mjs";import{a as s}from"./chunk-53TM7EG4.mjs";import{a as A}from"./chunk-3OKWBJFM.mjs";import{a as h}from"./chunk-4OO7HE5Q.mjs";import{b as x}from"./chunk-YAXVLGG3.mjs";import{g as p}from"./chunk-CN4RHVUE.mjs";import{a as I}from"./chunk-BRJNX4JF.mjs";import{a as f}from"./chunk-KD2IQ32V.mjs";import{BigNumber as w}from"bignumber.js";async function M({options:d,config:i,provider:a,login:c}){let e=L.getInstance(),k=h(),T=A({loginToken:d?.token,version:i.version}),o={manager:e,provider:a};await s(o);let t=await new Promise(async function(v,E){async function g(r){let n=e?e.addressesPerPage??1:1,l=new w(r-1).times(n);e?.updateStartIndex(Math.max(0,parseInt(l.toString()))),await s(o)}async function u(r){if(!(!a||!c)){e?.updateConfirmScreen({...T,selectedAddress:r.selectedAddress,explorerLink:I({to:`/${f}/${r.selectedAddress}`,explorerAddress:k})});try{let n=d?.token?await a.tokenLogin({token:Buffer.from(`${d?.token}{}`),addressIndex:r.addressIndex}):await c({addressIndex:r.addressIndex});v({address:n.address,signature:n.signature?n.signature.toString("hex"):"",addressIndex:r.addressIndex})}catch(n){console.error("User rejected login:",n),!!e?.getConfirmScreenData()&&await s(o)}}}async function m(){await s(o),e.unsubscribeFromAuthEvents({handleCancel:m,handleAccessWallet:u,handleGoToPage:g}),E("User cancelled login")}e.subscribeToAuthEvents({handleCancel:m,handleAccessWallet:u,handleGoToPage:g})}),{version:b,dataEnabled:P}=i;return p({index:t.addressIndex,loginType:"ledger"}),x({address:t.address,index:t.addressIndex,version:b,hasContractDataEnabled:P}),{address:t.address,signature:t.signature}}export{M as a};
2
- //# sourceMappingURL=chunk-DHSATBNM.mjs.map
1
+ import{a as L}from"./chunk-MHCIV2K5.mjs";import{a as s}from"./chunk-OZ3OBQJ6.mjs";import{a as A}from"./chunk-3OKWBJFM.mjs";import{a as h}from"./chunk-4OO7HE5Q.mjs";import{b as x}from"./chunk-YAXVLGG3.mjs";import{g as p}from"./chunk-CN4RHVUE.mjs";import{a as I}from"./chunk-BRJNX4JF.mjs";import{a as f}from"./chunk-KD2IQ32V.mjs";import{BigNumber as w}from"bignumber.js";async function M({options:d,config:i,provider:a,login:c}){let e=L.getInstance(),k=h(),T=A({loginToken:d?.token,version:i.version}),o={manager:e,provider:a};await s(o);let t=await new Promise(async function(v,E){async function g(r){let n=e?e.addressesPerPage??1:1,l=new w(r-1).times(n);e?.updateStartIndex(Math.max(0,parseInt(l.toString()))),await s(o)}async function u(r){if(!(!a||!c)){e?.updateConfirmScreen({...T,selectedAddress:r.selectedAddress,explorerLink:I({to:`/${f}/${r.selectedAddress}`,explorerAddress:k})});try{let n=d?.token?await a.tokenLogin({token:Buffer.from(`${d?.token}{}`),addressIndex:r.addressIndex}):await c({addressIndex:r.addressIndex});v({address:n.address,signature:n.signature?n.signature.toString("hex"):"",addressIndex:r.addressIndex})}catch(n){console.error("User rejected login:",n),!!e?.getConfirmScreenData()&&await s(o)}}}async function m(){await s(o),e.unsubscribeFromAuthEvents({handleCancel:m,handleAccessWallet:u,handleGoToPage:g}),E("User cancelled login")}e.subscribeToAuthEvents({handleCancel:m,handleAccessWallet:u,handleGoToPage:g})}),{version:b,dataEnabled:P}=i;return p({index:t.addressIndex,loginType:"ledger"}),x({address:t.address,index:t.addressIndex,version:b,hasContractDataEnabled:P}),{address:t.address,signature:t.signature}}export{M as a};
2
+ //# sourceMappingURL=chunk-PUSIK3N4.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as l}from"./chunk-DHSATBNM.mjs";import{a as n}from"./chunk-MHCIV2K5.mjs";import{a as h}from"./chunk-LRKA4F33.mjs";import{a as p}from"./chunk-D4MNCAND.mjs";import{a as c}from"./chunk-Y2GZNJKO.mjs";import{a as d}from"./chunk-VLHG5NVE.mjs";import{a as g}from"./chunk-BQL3NILA.mjs";import{a as m}from"./chunk-ZGNDECGJ.mjs";import{i as o}from"./chunk-57KVKSEC.mjs";import{g as t}from"./chunk-QD3CFFVT.mjs";import{a}from"./chunk-VMFJUT3G.mjs";import{a as s}from"./chunk-7QCBLUWB.mjs";var v=class extends d{constructor(i){super(i);this.provider=null;this.config=null;this._signTransactions=null;this._signMessage=null;this.createProvider=async i=>{this.initialize(),await a(s),await this.initLegderConnectManager(i?.anchor);let r=n.getInstance(),{ledgerProvider:e,ledgerConfig:u}=await new Promise((f,T)=>p({manager:r,resolve:f,reject:T,shouldInitProvider:i?.shouldInitProvider}));return this.config=u,this.provider=e,this._login=this.ledgerLogin.bind(this),this._signTransactions=e.signTransactions.bind(e),this._signMessage=e.signMessage.bind(e),this.buildProvider()};this.buildProvider=async()=>{if(!this.provider)throw new Error("Provider is not initialized.");let i=this.provider;return i.setAccount({address:this.address}),i.signTransactions=this.signTransactions,i.signMessage=this.signMessage,i.login=this.login.bind(this),i.cancelLogin=this.cancelLogin,i};this.ledgerLogin=async i=>{if(!this.provider)throw new Error("Provider is not initialized.");if(!i||typeof i.addressIndex!="number")throw new Error("Missing addressIndex for Ledger login");let{address:r,signature:e}=await this.provider.login({addressIndex:i.addressIndex});return{address:r,signature:e??""}};this.loginOperation=async i=>{if(!this.provider)throw new Error("Provider is not initialized.");return await l({options:i,config:this.config,provider:this.provider,login:this.ledgerLogin.bind(this)})};this.initLegderConnectManager=async i=>{if(!!g())return;await n.getInstance().init(i)};this.signTransactions=async i=>{if(!this._signTransactions)throw new Error("Sign transactions method is not initialized.");return await this.rebuildProvider(),await m({transactions:i,handleSign:this._signTransactions.bind(this.provider)})};this.signMessage=async i=>{if(!this.provider||!this._signMessage)throw new Error("Provider is not initialized.");return await this.rebuildProvider(),await h({message:i,handleSignMessage:this._signMessage.bind(this.provider)})};this.rebuildProvider=async()=>{try{await this.provider?.getAddress()}catch{try{let{ledgerProvider:r}=await c({shouldInitProvider:!0});this.provider=r,this._signTransactions=r.signTransactions.bind(r),this._signMessage=r.signMessage.bind(r)}catch(r){throw o({toastId:"ledger-provider-rebuild-error",duration:1e4,icon:"times",iconClassName:"warning",message:"Unlock your device & open the MultiversX App",title:"Ledger unavailable"}),r}}}}};export{v as a};
2
- //# sourceMappingURL=chunk-ZIQFQWVJ.mjs.map
1
+ import{a as l}from"./chunk-PUSIK3N4.mjs";import{a as n}from"./chunk-MHCIV2K5.mjs";import{a as h}from"./chunk-LRKA4F33.mjs";import{a as p}from"./chunk-HNEBEFTL.mjs";import{a as c}from"./chunk-4NMRZJSQ.mjs";import{a as d}from"./chunk-VLHG5NVE.mjs";import{a as g}from"./chunk-BQL3NILA.mjs";import{a as m}from"./chunk-HWH2SKSH.mjs";import{i as o}from"./chunk-J7P6SJOM.mjs";import{g as t}from"./chunk-QD3CFFVT.mjs";import{a}from"./chunk-VMFJUT3G.mjs";import{a as s}from"./chunk-7QCBLUWB.mjs";var v=class extends d{constructor(i){super(i);this.provider=null;this.config=null;this._signTransactions=null;this._signMessage=null;this.createProvider=async i=>{this.initialize(),await a(s),await this.initLegderConnectManager(i?.anchor);let r=n.getInstance(),{ledgerProvider:e,ledgerConfig:u}=await new Promise((f,T)=>p({manager:r,resolve:f,reject:T,shouldInitProvider:i?.shouldInitProvider}));return this.config=u,this.provider=e,this._login=this.ledgerLogin.bind(this),this._signTransactions=e.signTransactions.bind(e),this._signMessage=e.signMessage.bind(e),this.buildProvider()};this.buildProvider=async()=>{if(!this.provider)throw new Error("Provider is not initialized.");let i=this.provider;return i.setAccount({address:this.address}),i.signTransactions=this.signTransactions,i.signMessage=this.signMessage,i.login=this.login.bind(this),i.cancelLogin=this.cancelLogin,i};this.ledgerLogin=async i=>{if(!this.provider)throw new Error("Provider is not initialized.");if(!i||typeof i.addressIndex!="number")throw new Error("Missing addressIndex for Ledger login");let{address:r,signature:e}=await this.provider.login({addressIndex:i.addressIndex});return{address:r,signature:e??""}};this.loginOperation=async i=>{if(!this.provider)throw new Error("Provider is not initialized.");return await l({options:i,config:this.config,provider:this.provider,login:this.ledgerLogin.bind(this)})};this.initLegderConnectManager=async i=>{if(!!g())return;await n.getInstance().init(i)};this.signTransactions=async i=>{if(!this._signTransactions)throw new Error("Sign transactions method is not initialized.");return await this.rebuildProvider(),await m({transactions:i,handleSign:this._signTransactions.bind(this.provider)})};this.signMessage=async i=>{if(!this.provider||!this._signMessage)throw new Error("Provider is not initialized.");return await this.rebuildProvider(),await h({message:i,handleSignMessage:this._signMessage.bind(this.provider)})};this.rebuildProvider=async()=>{try{await this.provider?.getAddress()}catch{try{let{ledgerProvider:r}=await c({shouldInitProvider:!0});this.provider=r,this._signTransactions=r.signTransactions.bind(r),this._signMessage=r.signMessage.bind(r)}catch(r){throw o({toastId:"ledger-provider-rebuild-error",duration:1e4,icon:"times",iconClassName:"warning",message:"Unlock your device & open the MultiversX App",title:"Ledger unavailable"}),r}}}}};export{v as a};
2
+ //# sourceMappingURL=chunk-TCCW2HZK.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as t}from"./chunk-ZLBHLHQ3.mjs";import{a as d}from"./chunk-SVNWQXWC.mjs";import{a as l}from"./chunk-2X7ENE6Y.mjs";import{a}from"./chunk-MCOVQEK7.mjs";var e=class e extends d{constructor(){super({uiTag:"mvx-unlock-panel",uiDataUpdateEvent:"OPEN"});this.initialData=null;this.openUnlockPanel=async()=>{this.data=e.getProvidersList(),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 i=>{!i?.isLoginFinished&&e.onClose&&e.onClose(),this.closeUI()};this.handleLogin=async({type:i,anchor:o})=>{if(!e.loginHandler)throw new Error("Login callback not initialized. Please call `init()` first.");try{this.isSimpleLoginCallback(e.loginHandler)?(await(await t.create({type:i,anchor:o})).login(),e.loginHandler()):e.loginHandler({type:i,anchor:o}),await this.handleCloseUI({isLoginFinished:!0})}catch(r){console.error(r),this.eventBus?.publish("CANCEL_IN_PROVIDER",this.data)}};this.handleCancelLogin=async()=>{await t.destroy()};this.isSimpleLoginCallback=i=>i.length===0;this.data=this.initialData}static getInstance(){return e.instance||(e.instance=new e),e.instance}static init(i){return this.loginHandler=i.loginHandler,this.allowedProviders=i.allowedProviders,i.onClose&&(this.onClose=i.onClose),this.getInstance()}static getProvidersList(){let i=t.customProviders,r=[...Object.values(a).filter(n=>n!==""&&n!=="webview"),...i.map(n=>n.type)];return(this.allowedProviders?this.allowedProviders.filter(n=>r.includes(n)):r).map(n=>{let s=i.find(v=>v.type===n);return s||{name:l[n]??n,type:n}})}};e.loginHandler=null,e.onClose=null,e.allowedProviders=null;var c=e;export{c as a};
2
- //# sourceMappingURL=chunk-643LVXSN.mjs.map
1
+ import{a as t}from"./chunk-46WBKAT4.mjs";import{a as d}from"./chunk-SVNWQXWC.mjs";import{a as l}from"./chunk-2X7ENE6Y.mjs";import{a}from"./chunk-MCOVQEK7.mjs";var e=class e extends d{constructor(){super({uiTag:"mvx-unlock-panel",uiDataUpdateEvent:"OPEN"});this.initialData=null;this.openUnlockPanel=async()=>{this.data=e.getProvidersList(),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 i=>{!i?.isLoginFinished&&e.onClose&&e.onClose(),this.closeUI()};this.handleLogin=async({type:i,anchor:o})=>{if(!e.loginHandler)throw new Error("Login callback not initialized. Please call `init()` first.");try{this.isSimpleLoginCallback(e.loginHandler)?(await(await t.create({type:i,anchor:o})).login(),e.loginHandler()):e.loginHandler({type:i,anchor:o}),await this.handleCloseUI({isLoginFinished:!0})}catch(r){console.error(r),this.eventBus?.publish("CANCEL_IN_PROVIDER",this.data)}};this.handleCancelLogin=async()=>{await t.destroy()};this.isSimpleLoginCallback=i=>i.length===0;this.data=this.initialData}static getInstance(){return e.instance||(e.instance=new e),e.instance}static init(i){return this.loginHandler=i.loginHandler,this.allowedProviders=i.allowedProviders,i.onClose&&(this.onClose=i.onClose),this.getInstance()}static getProvidersList(){let i=t.customProviders,r=[...Object.values(a).filter(n=>n!==""&&n!=="webview"),...i.map(n=>n.type)];return(this.allowedProviders?this.allowedProviders.filter(n=>r.includes(n)):r).map(n=>{let s=i.find(v=>v.type===n);return s||{name:l[n]??n,type:n}})}};e.loginHandler=null,e.onClose=null,e.allowedProviders=null;var c=e;export{c as a};
2
+ //# sourceMappingURL=chunk-U5PPKFAJ.mjs.map
@@ -1,2 +1,2 @@
1
- import{a}from"./chunk-YRHMGKLM.mjs";import{a as h}from"./chunk-BQL3NILA.mjs";import{a as _}from"./chunk-RCBOU6TT.mjs";import{a as P}from"./chunk-DGXP3AZR.mjs";import{e as r,f as A}from"./chunk-FFHVVGYW.mjs";import{p as T}from"./chunk-57KVKSEC.mjs";import{a as I}from"./chunk-QI2QMNTG.mjs";import{u as d}from"./chunk-CN4RHVUE.mjs";import{b as w,c as f}from"./chunk-IEJTMYFW.mjs";import{c as m}from"./chunk-SAAOQW7P.mjs";import{a as M}from"./chunk-VMFJUT3G.mjs";import{a as p}from"./chunk-2X7ENE6Y.mjs";import{a as E}from"./chunk-7QCBLUWB.mjs";import{OptionalOperation as v}from"@multiversx/sdk-wallet-connect-provider/out";var L=[r.CANCEL_ACTION,r.SIGN_LOGIN_TOKEN],O=class{constructor(n){this.provider=null;this.methods=[];this.approval=null;this._login=null;this._signTransactions=null;this._signMessage=null;this.createProvider=async n=>{if(this.initialize(),await M(E),await this.initWalletConnectManager(n?.anchor),!this.provider&&this.config){let{walletConnectProvider:t,dappMethods:e}=await this.createWalletConnectProvider(this.config);this._login=t.login.bind(t),this._signTransactions=t.signTransactions.bind(t),this._signMessage=t.signMessage.bind(t),this.provider=t,this.methods=e}if(this.provider){let{uri:t="",approval:e}=await this.provider.connect({methods:this.methods});this.approval=e,a.getInstance().updateData({wcURI:t})}return this.buildProvider()};this.buildProvider=()=>{if(!this.provider)throw new Error("Provider is not initialized.");let n=this.provider;return n.login=this.login,n.signTransactions=this.signTransactions,n.signMessage=this.signMessage,n};this.initialize=()=>{if(this.config?.walletConnectV2ProjectId)return;let n=f(d());if(!n)throw new Error("Invalid WalletConnect setup");this.config=n};this.initWalletConnectManager=async n=>{if(!!h())return;await a.getInstance().init(n)};this.createWalletConnectProvider=async n=>{let t=h(),e=m(d());if(w(d())&&L.push(r.SIGN_NATIVE_AUTH_TOKEN),!n?.walletConnectV2ProjectId)throw new Error("Invalid WalletConnect setup");let l={onClientLogin:()=>{},onClientLogout:()=>{I()},onClientEvent:o=>{}};try{let{walletConnectV2ProjectId:o,walletConnectV2Options:C={},walletConnectV2RelayAddress:y=""}=n,u=new A(l,e,y,o,C);return await u.init(),{walletConnectProvider:u,dappMethods:L}}catch(o){throw console.error("Unable to connect",o),t&&await T().logout(),o}};this.login=async n=>{if(!this.provider)throw new Error("Provider is not initialized. Call createProvider first.");if(this.provider.isConnected())throw new Error("Unable to connect");let e=async()=>{if(!this.provider)throw new Error("Provider is not initialized.");if(!this._login)throw new Error("Login method is not initialized.");try{await this.provider.init();let i=a.getInstance(),{uri:s="",approval:c}=await this.provider.connect({methods:this.methods});i.updateData({wcURI:s});let g=await this._login({approval:c,token:n?.token}),{address:l="",signature:o=""}=g??{};return i.handleClose({isLoginFinished:!!l}),{address:l,signature:o}}catch{return await e()}};if(!this.approval||!this._login)throw new Error("Approval or login is not initialized");try{let i=await this._login({approval:this.approval,token:n?.token}),{address:s="",signature:c=""}=i??{};return a.getInstance().handleClose({isLoginFinished:!!s}),{address:s,signature:c}}catch(i){return console.error("User rejected connection proposal",i),await e()}};this.signTransactions=async n=>{if(!this.provider||!this._signTransactions)throw new Error("Provider is not initialized.");let{manager:t,onClose:e}=await P({cancelAction:this.cancelAction.bind(this)});t.subscribeToEventBus("CLOSE_PENDING_TRANSACTIONS",e),t.updateData({name:p.walletConnect,type:"walletConnect"});try{return await this._signTransactions(n)}catch(i){throw await e({shouldCancelAction:!0}),await this.sendCustomRequest({method:r.CANCEL_ACTION,action:v.CANCEL_ACTION}),i}finally{t.closeUI()}};this.signMessage=async n=>{if(!this.provider||!this._signMessage)throw new Error("Provider is not initialized.");let t=()=>this.sendCustomRequest({method:r.CANCEL_ACTION,action:v.CANCEL_ACTION});return await _({message:n,handleSignMessage:this._signMessage.bind(this.provider),cancelAction:t,providerType:p.extension})};this.config=n}async cancelAction(){await this.sendCustomRequest({method:r.CANCEL_ACTION,action:v.CANCEL_ACTION})}async sendCustomRequest({action:n,method:t}){if(!this.provider)throw new Error("Provider is not initialized.");try{await this.provider.sendCustomRequest?.({request:{method:t,params:{action:n}}})}catch(e){console.error("Unable to send event",e)}}};export{O as a};
2
- //# sourceMappingURL=chunk-BTDFQCSV.mjs.map
1
+ import{a}from"./chunk-YRHMGKLM.mjs";import{a as h}from"./chunk-BQL3NILA.mjs";import{a as _}from"./chunk-RCBOU6TT.mjs";import{a as P}from"./chunk-DGXP3AZR.mjs";import{e as r,f as A}from"./chunk-FFHVVGYW.mjs";import{p as T}from"./chunk-J7P6SJOM.mjs";import{a as I}from"./chunk-QI2QMNTG.mjs";import{u as d}from"./chunk-CN4RHVUE.mjs";import{b as w,c as f}from"./chunk-IEJTMYFW.mjs";import{c as m}from"./chunk-SAAOQW7P.mjs";import{a as M}from"./chunk-VMFJUT3G.mjs";import{a as p}from"./chunk-2X7ENE6Y.mjs";import{a as E}from"./chunk-7QCBLUWB.mjs";import{OptionalOperation as v}from"@multiversx/sdk-wallet-connect-provider/out";var L=[r.CANCEL_ACTION,r.SIGN_LOGIN_TOKEN],O=class{constructor(n){this.provider=null;this.methods=[];this.approval=null;this._login=null;this._signTransactions=null;this._signMessage=null;this.createProvider=async n=>{if(this.initialize(),await M(E),await this.initWalletConnectManager(n?.anchor),!this.provider&&this.config){let{walletConnectProvider:t,dappMethods:e}=await this.createWalletConnectProvider(this.config);this._login=t.login.bind(t),this._signTransactions=t.signTransactions.bind(t),this._signMessage=t.signMessage.bind(t),this.provider=t,this.methods=e}if(this.provider){let{uri:t="",approval:e}=await this.provider.connect({methods:this.methods});this.approval=e,a.getInstance().updateData({wcURI:t})}return this.buildProvider()};this.buildProvider=()=>{if(!this.provider)throw new Error("Provider is not initialized.");let n=this.provider;return n.login=this.login,n.signTransactions=this.signTransactions,n.signMessage=this.signMessage,n};this.initialize=()=>{if(this.config?.walletConnectV2ProjectId)return;let n=f(d());if(!n)throw new Error("Invalid WalletConnect setup");this.config=n};this.initWalletConnectManager=async n=>{if(!!h())return;await a.getInstance().init(n)};this.createWalletConnectProvider=async n=>{let t=h(),e=m(d());if(w(d())&&L.push(r.SIGN_NATIVE_AUTH_TOKEN),!n?.walletConnectV2ProjectId)throw new Error("Invalid WalletConnect setup");let l={onClientLogin:()=>{},onClientLogout:()=>{I()},onClientEvent:o=>{}};try{let{walletConnectV2ProjectId:o,walletConnectV2Options:C={},walletConnectV2RelayAddress:y=""}=n,u=new A(l,e,y,o,C);return await u.init(),{walletConnectProvider:u,dappMethods:L}}catch(o){throw console.error("Unable to connect",o),t&&await T().logout(),o}};this.login=async n=>{if(!this.provider)throw new Error("Provider is not initialized. Call createProvider first.");if(this.provider.isConnected())throw new Error("Unable to connect");let e=async()=>{if(!this.provider)throw new Error("Provider is not initialized.");if(!this._login)throw new Error("Login method is not initialized.");try{await this.provider.init();let i=a.getInstance(),{uri:s="",approval:c}=await this.provider.connect({methods:this.methods});i.updateData({wcURI:s});let g=await this._login({approval:c,token:n?.token}),{address:l="",signature:o=""}=g??{};return i.handleClose({isLoginFinished:!!l}),{address:l,signature:o}}catch{return await e()}};if(!this.approval||!this._login)throw new Error("Approval or login is not initialized");try{let i=await this._login({approval:this.approval,token:n?.token}),{address:s="",signature:c=""}=i??{};return a.getInstance().handleClose({isLoginFinished:!!s}),{address:s,signature:c}}catch(i){return console.error("User rejected connection proposal",i),await e()}};this.signTransactions=async n=>{if(!this.provider||!this._signTransactions)throw new Error("Provider is not initialized.");let{manager:t,onClose:e}=await P({cancelAction:this.cancelAction.bind(this)});t.subscribeToEventBus("CLOSE_PENDING_TRANSACTIONS",e),t.updateData({name:p.walletConnect,type:"walletConnect"});try{return await this._signTransactions(n)}catch(i){throw await e({shouldCancelAction:!0}),await this.sendCustomRequest({method:r.CANCEL_ACTION,action:v.CANCEL_ACTION}),i}finally{t.closeUI()}};this.signMessage=async n=>{if(!this.provider||!this._signMessage)throw new Error("Provider is not initialized.");let t=()=>this.sendCustomRequest({method:r.CANCEL_ACTION,action:v.CANCEL_ACTION});return await _({message:n,handleSignMessage:this._signMessage.bind(this.provider),cancelAction:t,providerType:p.extension})};this.config=n}async cancelAction(){await this.sendCustomRequest({method:r.CANCEL_ACTION,action:v.CANCEL_ACTION})}async sendCustomRequest({action:n,method:t}){if(!this.provider)throw new Error("Provider is not initialized.");try{await this.provider.sendCustomRequest?.({request:{method:t,params:{action:n}}})}catch(e){console.error("Unable to send event",e)}}};export{O as a};
2
+ //# sourceMappingURL=chunk-XQLVTH7K.mjs.map
@@ -1,2 +1,2 @@
1
- import{a as x}from"./chunk-4OO7HE5Q.mjs";import{a as $}from"./chunk-7Z7IX367.mjs";import{a as _}from"./chunk-VCQBYNNS.mjs";import{a as U}from"./chunk-GHDPXQZ5.mjs";import{a as R}from"./chunk-PDT22D2C.mjs";import{a as M}from"./chunk-RBZC4PEU.mjs";import{a as w}from"./chunk-ROZAXUMC.mjs";import{a as G}from"./chunk-I66YT2S2.mjs";import{a as O}from"./chunk-MCZUQPRA.mjs";import{a as v}from"./chunk-YGI3KXMZ.mjs";import{a as L}from"./chunk-42KJRIAT.mjs";import{a as h}from"./chunk-RYIJWGFA.mjs";import{p as F}from"./chunk-57KVKSEC.mjs";import{a as A}from"./chunk-BRJNX4JF.mjs";import{f as P}from"./chunk-K3G3SPRT.mjs";import{a as E}from"./chunk-KD2IQ32V.mjs";import{c as u}from"./chunk-TI37DKBT.mjs";import{k as C}from"./chunk-LHEH7L4L.mjs";import{a as b}from"./chunk-7QCBLUWB.mjs";async function Vt({allTransactions:f,currentScreenIndex:m,egldLabel:o,network:e,gasPriceData:c,price:T,address:p,username:V,shard:B,signedIndexes:i,parsedTransactionsByDataField:j}){let t=f[m],q=t?.transaction?.sender.toString(),z=t?.transaction,S=null,D=null,H=w({egldLabel:o,sender:q,apiAddress:e.apiAddress,address:p,parsedTransactionsByDataField:j}),a=t.transaction.toPlainObject(),n=await H(t),g=!n?.transactionTokenInfo?.tokenId,{tokenId:d,nonce:l,amount:y=""}=n?.transactionTokenInfo??{},K=d&&l&&l.length>0?`${d}-${l}`:d,W=await L({tokenId:K}),{esdtPrice:Z,tokenDecimals:J,type:r,identifier:s,tokenImageUrl:Q}=W;if(r==="SemiFungibleESDT"||r==="NonFungibleESDT")D={type:r,identifier:s,amount:y,imageURL:Q};else{let I=({addCommas:ut})=>P({input:g?t.transaction.value.toString():y,decimals:g?Number(e.decimals):J,digits:Number(e.digits),showLastNonZeroDecimal:!1,addCommas:ut}),pt=I({addCommas:!0}),gt=I({addCommas:!1}),dt=Number(g?T:Z),lt=v({amount:gt,usd:dt,addEqualSign:!0});S={identifier:(s===C?o:s)??o,amount:pt,usdValue:lt}}let{feeLimitFormatted:X,feeInFiatLimit:Y}=O({transaction:z,price:T}),tt=U({shard:B,initialGasPrice:c.initialGasPrice,transaction:a,gasStationMetadata:e.gasStationMetadata}),nt=R({transaction:a,gasPriceData:c}),ot=F().getType(),et=h(ot),k=f.length,it=i.length>0?i[i.length-1]+1:0,at=u(t.transaction.data.toString()??""),N=M(n?.transactionTokenInfo),rt=G({data:at,identifier:s,highlight:N}),st=x(),mt=A({to:`/${E}/${p}`,explorerAddress:st}),ct=k===1||n?.needsSigning&&!i.includes(m);return{commonData:{receiver:a.receiver.toString(),data:u(t.transaction.data.toString()??""),decodedData:rt,gasPrice:nt.toString(),gasLimit:a.gasLimit.toString(),explorerLink:mt,ppu:c.ppu,ppuOptions:tt,egldLabel:o,tokenType:$(r),feeLimit:X,feeInFiatLimit:Y,transactionsCount:k,currentIndex:m,currentIndexToSign:it,highlight:N,scCall:_(n?.transactionTokenInfo),needsSigning:ct,isEditable:n?.needsSigning,providerName:et,address:p,username:V,origin:b.location.origin},tokenTransaction:S,fungibleTransaction:D}}export{Vt as a};
2
- //# sourceMappingURL=chunk-BJRGP56G.mjs.map
1
+ import{a as x}from"./chunk-4OO7HE5Q.mjs";import{a as $}from"./chunk-7Z7IX367.mjs";import{a as _}from"./chunk-VCQBYNNS.mjs";import{a as U}from"./chunk-GHDPXQZ5.mjs";import{a as R}from"./chunk-PDT22D2C.mjs";import{a as M}from"./chunk-RBZC4PEU.mjs";import{a as w}from"./chunk-ROZAXUMC.mjs";import{a as G}from"./chunk-I66YT2S2.mjs";import{a as O}from"./chunk-MCZUQPRA.mjs";import{a as v}from"./chunk-YGI3KXMZ.mjs";import{a as L}from"./chunk-42KJRIAT.mjs";import{a as h}from"./chunk-RYIJWGFA.mjs";import{p as F}from"./chunk-J7P6SJOM.mjs";import{a as A}from"./chunk-BRJNX4JF.mjs";import{f as P}from"./chunk-K3G3SPRT.mjs";import{a as E}from"./chunk-KD2IQ32V.mjs";import{c as u}from"./chunk-TI37DKBT.mjs";import{k as C}from"./chunk-LHEH7L4L.mjs";import{a as b}from"./chunk-7QCBLUWB.mjs";async function Vt({allTransactions:f,currentScreenIndex:m,egldLabel:o,network:e,gasPriceData:c,price:T,address:p,username:V,shard:B,signedIndexes:i,parsedTransactionsByDataField:j}){let t=f[m],q=t?.transaction?.sender.toString(),z=t?.transaction,S=null,D=null,H=w({egldLabel:o,sender:q,apiAddress:e.apiAddress,address:p,parsedTransactionsByDataField:j}),a=t.transaction.toPlainObject(),n=await H(t),g=!n?.transactionTokenInfo?.tokenId,{tokenId:d,nonce:l,amount:y=""}=n?.transactionTokenInfo??{},K=d&&l&&l.length>0?`${d}-${l}`:d,W=await L({tokenId:K}),{esdtPrice:Z,tokenDecimals:J,type:r,identifier:s,tokenImageUrl:Q}=W;if(r==="SemiFungibleESDT"||r==="NonFungibleESDT")D={type:r,identifier:s,amount:y,imageURL:Q};else{let I=({addCommas:ut})=>P({input:g?t.transaction.value.toString():y,decimals:g?Number(e.decimals):J,digits:Number(e.digits),showLastNonZeroDecimal:!1,addCommas:ut}),pt=I({addCommas:!0}),gt=I({addCommas:!1}),dt=Number(g?T:Z),lt=v({amount:gt,usd:dt,addEqualSign:!0});S={identifier:(s===C?o:s)??o,amount:pt,usdValue:lt}}let{feeLimitFormatted:X,feeInFiatLimit:Y}=O({transaction:z,price:T}),tt=U({shard:B,initialGasPrice:c.initialGasPrice,transaction:a,gasStationMetadata:e.gasStationMetadata}),nt=R({transaction:a,gasPriceData:c}),ot=F().getType(),et=h(ot),k=f.length,it=i.length>0?i[i.length-1]+1:0,at=u(t.transaction.data.toString()??""),N=M(n?.transactionTokenInfo),rt=G({data:at,identifier:s,highlight:N}),st=x(),mt=A({to:`/${E}/${p}`,explorerAddress:st}),ct=k===1||n?.needsSigning&&!i.includes(m);return{commonData:{receiver:a.receiver.toString(),data:u(t.transaction.data.toString()??""),decodedData:rt,gasPrice:nt.toString(),gasLimit:a.gasLimit.toString(),explorerLink:mt,ppu:c.ppu,ppuOptions:tt,egldLabel:o,tokenType:$(r),feeLimit:X,feeInFiatLimit:Y,transactionsCount:k,currentIndex:m,currentIndexToSign:it,highlight:N,scCall:_(n?.transactionTokenInfo),needsSigning:ct,isEditable:n?.needsSigning,providerName:et,address:p,username:V,origin:b.location.origin},tokenTransaction:S,fungibleTransaction:D}}export{Vt as a};
2
+ //# sourceMappingURL=chunk-YDXS2C4W.mjs.map
package/out/index.mjs CHANGED
@@ -1,2 +1,2 @@
1
- import"./__chunks__/chunk-CXE2WQJS.mjs";import"./__chunks__/chunk-2IEOAR7H.mjs";import{a as to}from"./__chunks__/chunk-QQ4OPT5A.mjs";import"./__chunks__/chunk-YV7ZJBAY.mjs";import"./__chunks__/chunk-DXRSXWLQ.mjs";import"./__chunks__/chunk-K5MJ4FMD.mjs";import{a as fo}from"./__chunks__/chunk-X2JK27T3.mjs";import"./__chunks__/chunk-INRKVOET.mjs";import"./__chunks__/chunk-6ET5BDZH.mjs";import{a as mo}from"./__chunks__/chunk-LSKZWWBZ.mjs";import"./__chunks__/chunk-7BRIA6SS.mjs";import{q as er}from"./__chunks__/chunk-57KVKSEC.mjs";import"./__chunks__/chunk-4HEE3XZP.mjs";import"./__chunks__/chunk-SCSHU7XJ.mjs";import"./__chunks__/chunk-RHN3VD44.mjs";import"./__chunks__/chunk-YPNKNMW5.mjs";import"./__chunks__/chunk-L2JWXTGG.mjs";import"./__chunks__/chunk-PEDR76UT.mjs";import"./__chunks__/chunk-M3C5NS6M.mjs";import"./__chunks__/chunk-PLFZHJOX.mjs";import"./__chunks__/chunk-QD3CFFVT.mjs";import"./__chunks__/chunk-UP7CK2EN.mjs";import"./__chunks__/chunk-WGOZYG4T.mjs";import"./__chunks__/chunk-JXO7XRIR.mjs";import"./__chunks__/chunk-5WVAF7RB.mjs";import"./__chunks__/chunk-7OTTISMZ.mjs";import"./__chunks__/chunk-MFUQ5NBC.mjs";import"./__chunks__/chunk-UFMHCVBL.mjs";import"./__chunks__/chunk-SBQJGS63.mjs";import"./__chunks__/chunk-WW4BBBLW.mjs";import"./__chunks__/chunk-ZFXAT6MD.mjs";import{a as po}from"./__chunks__/chunk-Q2Q4XN4M.mjs";import"./__chunks__/chunk-672ZNZKR.mjs";import"./__chunks__/chunk-G2DLIXFQ.mjs";import"./__chunks__/chunk-W4GE4ZDP.mjs";import"./__chunks__/chunk-4ODPAHHA.mjs";import"./__chunks__/chunk-ECEWPZGA.mjs";import"./__chunks__/chunk-OTBTZ3NI.mjs";import"./__chunks__/chunk-WVTCO3AV.mjs";import"./__chunks__/chunk-FTFAEXVE.mjs";import"./__chunks__/chunk-3PAMS4NB.mjs";import"./__chunks__/chunk-6746F2FY.mjs";import"./__chunks__/chunk-CBIH5QMT.mjs";import"./__chunks__/chunk-R7SGL2HW.mjs";import"./__chunks__/chunk-WV5X6BXA.mjs";import"./__chunks__/chunk-YAXVLGG3.mjs";import"./__chunks__/chunk-NWEUIK3A.mjs";import{a as Zo}from"./__chunks__/chunk-TLKMUVQJ.mjs";import"./__chunks__/chunk-3S57OP4Z.mjs";import"./__chunks__/chunk-OJX2TSAZ.mjs";import"./__chunks__/chunk-RIQNG4I7.mjs";import"./__chunks__/chunk-IMGZJVC6.mjs";import"./__chunks__/chunk-QTKK6OSJ.mjs";import"./__chunks__/chunk-6ACLOUQ3.mjs";import"./__chunks__/chunk-WE7YOBO7.mjs";import"./__chunks__/chunk-J32T6OAP.mjs";import"./__chunks__/chunk-UYUKTC4X.mjs";import{a as X}from"./__chunks__/chunk-YK7T6MBD.mjs";import{a as Y}from"./__chunks__/chunk-KMJMQEXI.mjs";import"./__chunks__/chunk-4US7HVCR.mjs";import"./__chunks__/chunk-HC5QPKZT.mjs";import"./__chunks__/chunk-4TBVQD27.mjs";import"./__chunks__/chunk-M3GFSV3G.mjs";import"./__chunks__/chunk-G5DKGX73.mjs";import"./__chunks__/chunk-45H34XLJ.mjs";import"./__chunks__/chunk-AGI2ZR6R.mjs";import"./__chunks__/chunk-L3MWDI6J.mjs";import"./__chunks__/chunk-65L5EBBL.mjs";import"./__chunks__/chunk-L3YPAYXZ.mjs";import"./__chunks__/chunk-QI2QMNTG.mjs";import{a as or}from"./__chunks__/chunk-6FXEHNGW.mjs";import{a as V,b as W}from"./__chunks__/chunk-ZLE5VUWG.mjs";import{a as A}from"./__chunks__/chunk-3GGBXXXJ.mjs";import"./__chunks__/chunk-RMW3YLGD.mjs";import{a as mr}from"./__chunks__/chunk-FPJ2PIFX.mjs";import{a as fr}from"./__chunks__/chunk-NJN53MJV.mjs";import{a as To}from"./__chunks__/chunk-YSCND2MX.mjs";import{a as rr}from"./__chunks__/chunk-HORSXVIV.mjs";import"./__chunks__/chunk-YJK5FPW4.mjs";import{a as br}from"./__chunks__/chunk-36XFDUXN.mjs";import"./__chunks__/chunk-ZAPRDHIW.mjs";import{a as ar}from"./__chunks__/chunk-WVAP3V3E.mjs";import{a as xr}from"./__chunks__/chunk-GIZSIYH4.mjs";import{a as z}from"./__chunks__/chunk-X6MN67NW.mjs";import{a as tr}from"./__chunks__/chunk-XVX7N3JK.mjs";import{a as pr}from"./__chunks__/chunk-HH5SA7BX.mjs";import"./__chunks__/chunk-CDTYHGXZ.mjs";import{a as eo}from"./__chunks__/chunk-3FXHIV6O.mjs";import"./__chunks__/chunk-6CQMLD25.mjs";import{a as dr}from"./__chunks__/chunk-3IYQANTT.mjs";import"./__chunks__/chunk-JR3FBBRR.mjs";import"./__chunks__/chunk-IXBWD6BF.mjs";import{a as Br}from"./__chunks__/chunk-JGULQG2H.mjs";import"./__chunks__/chunk-VCAWVAO5.mjs";import{a as zr}from"./__chunks__/chunk-55W25Q35.mjs";import{a as Ar}from"./__chunks__/chunk-Y3YLDFXK.mjs";import"./__chunks__/chunk-ENTPR3MV.mjs";import"./__chunks__/chunk-NM3KJ3EA.mjs";import"./__chunks__/chunk-BXKFACG5.mjs";import"./__chunks__/chunk-CN4RHVUE.mjs";import"./__chunks__/chunk-T4FRQ4JG.mjs";import"./__chunks__/chunk-IEJTMYFW.mjs";import"./__chunks__/chunk-UTWIKUIK.mjs";import"./__chunks__/chunk-LTF535HP.mjs";import"./__chunks__/chunk-KPK72MOE.mjs";import"./__chunks__/chunk-SAAOQW7P.mjs";import"./__chunks__/chunk-VNLGNNIL.mjs";import"./__chunks__/chunk-ZODTYAYF.mjs";import"./__chunks__/chunk-NLRDRI7Q.mjs";import"./__chunks__/chunk-DKX6JUT6.mjs";import"./__chunks__/chunk-RZ4YTKD7.mjs";import"./__chunks__/chunk-KRWR77QE.mjs";import"./__chunks__/chunk-B7YCKWDU.mjs";import"./__chunks__/chunk-5N4F5T5L.mjs";import"./__chunks__/chunk-SUN3MVLZ.mjs";import"./__chunks__/chunk-HDJOER66.mjs";import"./__chunks__/chunk-A7FTKX2A.mjs";import"./__chunks__/chunk-XKU5QBXG.mjs";import"./__chunks__/chunk-TYYA6E7F.mjs";import"./__chunks__/chunk-KMFYDHOY.mjs";import"./__chunks__/chunk-S2B2ZKIJ.mjs";import"./__chunks__/chunk-2DNGCNYM.mjs";import"./__chunks__/chunk-SQVKVA7X.mjs";import"./__chunks__/chunk-T2YPFNVM.mjs";import"./__chunks__/chunk-X4XULIVT.mjs";import"./__chunks__/chunk-I24YBVHK.mjs";import"./__chunks__/chunk-YMPZDHKF.mjs";import"./__chunks__/chunk-VKEESSBI.mjs";import"./__chunks__/chunk-NB7A4C7L.mjs";import{a as yr}from"./__chunks__/chunk-XO5D3FNU.mjs";import{a as wr}from"./__chunks__/chunk-UF45HLIK.mjs";import"./__chunks__/chunk-TAI3I5BS.mjs";import"./__chunks__/chunk-JTQCNFCR.mjs";import"./__chunks__/chunk-M6ATGCOM.mjs";import{a as vr}from"./__chunks__/chunk-SF7XXVIO.mjs";import"./__chunks__/chunk-54B3EIZC.mjs";import"./__chunks__/chunk-QJ7MRSGB.mjs";import{a as jr}from"./__chunks__/chunk-VDDXFGB2.mjs";import{b as ir}from"./__chunks__/chunk-LNABNVAO.mjs";import"./__chunks__/chunk-HMHP5DPL.mjs";import"./__chunks__/chunk-VIJUIJ4V.mjs";import"./__chunks__/chunk-35MNP3LA.mjs";import"./__chunks__/chunk-TX7PTLVP.mjs";import{a as hr}from"./__chunks__/chunk-WZ2DNB3R.mjs";import"./__chunks__/chunk-BRJNX4JF.mjs";import"./__chunks__/chunk-K3G3SPRT.mjs";import{a as cr}from"./__chunks__/chunk-DBIIY2TX.mjs";import{a as o,b as r,c as e,d as f,e as m,f as p,g as t,h as x,i as a,j as b,k as c,l as d,m as g,n as h,o as i,p as j,q as k,r as l,s as n,t as q,u as s,v as u,w as v,x as w,y}from"./__chunks__/chunk-KD2IQ32V.mjs";import"./__chunks__/chunk-HQQMSHTW.mjs";import"./__chunks__/chunk-UQU2VWPJ.mjs";import{a as qr,b as sr,c as ur}from"./__chunks__/chunk-3NG7LKF4.mjs";import"./__chunks__/chunk-CO3V5DOG.mjs";import{a as _o}from"./__chunks__/chunk-TVELGQIH.mjs";import"./__chunks__/chunk-2BSPSW6X.mjs";import"./__chunks__/chunk-OOJVPJOX.mjs";import"./__chunks__/chunk-OVXVICF7.mjs";import{a as $o}from"./__chunks__/chunk-WZI2I6NX.mjs";import{a as Uo,b as Vo,c as Wo}from"./__chunks__/chunk-TI37DKBT.mjs";import"./__chunks__/chunk-2CNSQULM.mjs";import{a as lr,b as nr}from"./__chunks__/chunk-WRLZ5ICK.mjs";import{a as kr}from"./__chunks__/chunk-I3MK6KZJ.mjs";import{a as gr}from"./__chunks__/chunk-B3IKUIRK.mjs";import"./__chunks__/chunk-THQWNWSE.mjs";import{a as Cr}from"./__chunks__/chunk-2RAULLHL.mjs";import{a as So}from"./__chunks__/chunk-MGQ373AO.mjs";import"./__chunks__/chunk-RPTH42EF.mjs";import{a as Ro}from"./__chunks__/chunk-3UNGCOKO.mjs";import"./__chunks__/chunk-5Y2ZDPP6.mjs";import{a as no,b as qo,c as so,d as uo,e as vo,f as wo,g as yo,h as zo,i as Ao,j as Bo,k as Co}from"./__chunks__/chunk-LHEH7L4L.mjs";import{a as ao,b as bo}from"./__chunks__/chunk-C4CJOZ4L.mjs";import{a as Go,b as Ho,c as Io,d as Jo,e as Ko,f as Lo,g as Mo,h as No,i as Oo,j as Po}from"./__chunks__/chunk-EJV4VNJG.mjs";import{a as Qo}from"./__chunks__/chunk-2X7ENE6Y.mjs";import{a as co,b as go,c as ho,d as io,e as jo,f as ko,g as lo}from"./__chunks__/chunk-FI444OX3.mjs";import{a as Do,b as Eo,c as Fo}from"./__chunks__/chunk-PPA7AFVD.mjs";import{a as K,b as L,c as M,d as N,e as O,f as P,g as Q,h as R,i as S,j as T,k as U}from"./__chunks__/chunk-ULUZWP2P.mjs";import{a as oo,b as ro}from"./__chunks__/chunk-GGBMHKR4.mjs";import{a as Z,b as _,c as $}from"./__chunks__/chunk-MGFIOCA4.mjs";import{a as B,b as C,c as D,d as E,e as F,f as G,g as H,h as I,i as J}from"./__chunks__/chunk-GLXG5BES.mjs";import"./__chunks__/chunk-MCOVQEK7.mjs";import"./__chunks__/chunk-DTQL3IDP.mjs";import{a as Yo}from"./__chunks__/chunk-LRHRFWQ4.mjs";import{a as Gr}from"./__chunks__/chunk-AJEWAECH.mjs";import"./__chunks__/chunk-RVW2ZWCR.mjs";import{a as Fr}from"./__chunks__/chunk-EHDGJUEU.mjs";import{a as Er}from"./__chunks__/chunk-HOCSCRJF.mjs";import{a as xo}from"./__chunks__/chunk-7QCBLUWB.mjs";import{a as Dr}from"./__chunks__/chunk-UE3IBKCO.mjs";import"./__chunks__/chunk-H6IZMTJK.mjs";import{a as Xo}from"./__chunks__/chunk-B2UIPHJ3.mjs";export{o as ACCOUNTS_ENDPOINT,r as ADDRESS_ENDPOINT,Ao as ALL_SHARDS_SHARD_ID,e as BLOCKS_ENDPOINT,f as CODE_ENDPOINT,m as COLLECTIONS_ENDPOINT,p as CONFIG_ENDPOINT,t as CONTRACTS_ENDPOINT,L as DEVNET_CHAIN_ID,M as DEVNET_EGLD_LABEL,x as ECONOMICS_ENDPOINT,_ as ELLIPSIS,$ as EMPTY_PPU,G as ESDTTransferTypesEnum,uo as EXTRA_GAS_LIMIT_GUARDED_TX,B as EnvironmentsEnum,to as FormatAmountController,so as GAS_LIMIT,qo as GAS_PER_DATA_BYTE,vo as GAS_PRICE,no as GAS_PRICE_MODIFIER,H as GuardianActionsEnum,a as IDENTITIES_ENDPOINT,b as KEYS_ENDPOINT,yo as LEDGER_CONTRACT_DATA_ENABLED_VALUE,go as LEDGER_HASH_SIGN_MINIMUM_VERSION,co as LEDGER_MULTI_ACCOUNT_MINIMUM_VERSION,ho as LEDGER_SIGN_AUTH_TOKEN_MINIMUM_VERSION,jo as LEDGER_WITH_GUARDIANS_MINIMUM_VERSION,ko as LEDGER_WITH_USERNAMES_MINIMUM_VERSION,io as LEDGER_WITH_WHITELISTED_TOKENS_MINIMUM_VERSION,c as LOCKED_ACCOUNTS_ENDPOINT,d as LOGS_ENDPOINT,P as MAINNET_CHAIN_ID,Q as MAINNET_EGLD_LABEL,zo as METACHAIN_SHARD_ID,g as MINIBLOCKS_ENDPOINT,T as MULTIVERSX_ORIGIN,Co as MULTI_TRANSFER_EGLD_TOKEN,h as NETWORK_CONFIG_ENDPOINT,i as NFTS_ENDPOINT,j as NODES_ENDPOINT,Z as N_A,k as PROVIDERS_ENDPOINT,_o as ProviderErrorsEnum,Bo as REFUNDED_GAS,l as ROLES_ENDPOINT,n as SC_RESULTS_ENDPOINT,q as STAKE_ENDPOINT,I as SigningErrorsEnum,J as SigningWarningsEnum,$o as SubscriptionsEnum,N as TESTNET_CHAIN_ID,O as TESTNET_EGLD_LABEL,U as TIMEOUT,s as TOKENS_ENDPOINT,v as TRANSACTIONS_BATCH,u as TRANSACTIONS_COUNT_ENDPOINT,w as TRANSACTIONS_ENDPOINT,y as TRANSFERS_ENDPOINT,E as TransactionBatchStatusesEnum,C as TransactionServerStatusesEnum,D as TransactionTypesEnum,F as TypesOfSmartContractCallsEnum,wo as VERSION,Oo as WALLET_PROVIDER_CALLBACK_PARAM,Po as WALLET_PROVIDER_CALLBACK_PARAM_TX_SIGNED,Jo as WALLET_PROVIDER_CONNECT_URL,Ho as WALLET_PROVIDER_DEVNET,Ko as WALLET_PROVIDER_DISCONNECT_URL,Go as WALLET_PROVIDER_MAINNET,Lo as WALLET_PROVIDER_SEND_TRANSACTION_URL,No as WALLET_PROVIDER_SIGN_MESSAGE_URL,Mo as WALLET_PROVIDER_SIGN_TRANSACTION_URL,Io as WALLET_PROVIDER_TESTNET,oo as WebsocketConnectionStatusEnum,V as accountFetcher,kr as addressIsValid,mo as axiosFetcher,z as axiosInstance,Er as buildUrlParams,R as chainIdByEnvironment,S as chainIdToEnvironment,zr as createTransactionsHistoryFromSessions,Wo as decodeBase64,tr as decodePart,Vo as encodeToBase64,cr as explorerUrlBuilder,K as fallbackNetworkConfigurations,or as fetchAccount,W as getAccountFromApi,dr as getActiveTransactionsStatus,ur as getAddressFromDataField,A as getCleanApiAddress,gr as getHumanReadableTimeFormat,eo as getIdentifierType,Fr as getIsAuthRoute,Gr as getIsInIframe,Y as getNetworkConfigFromApi,hr as getReceiverData,X as getServerConfiguration,fo as getTokenDetails,jr as getTransactionAmount,vr as getTransactionAsset,Br as getTransactionsHistory,To as getUnixTimestamp,fr as getUnixTimestampWithAddedMilliseconds,mr as getUnixTimestampWithAddedSeconds,po as getWebsocketUrl,Yo as getWindowLocation,xr as isAscii,bo as isBrowserWithPopupConfirmation,qr as isContract,lr as isHexValidCharacters,nr as isHexValidLength,ao as isSafari,sr as isSelfESDTContract,Uo as isStringBase64,pr as isUtf8,Xo as isWindowAvailable,lo as ledgerErrorCodes,Ar as mapServerTransactionsToListItems,yr as mapTransactionToListItem,Cr as maxDecimals,Zo as nativeAuth,Do as persistConfig,ir as processTransactionAction,wr as processTransactionAssets,Qo as providerLabels,er as refreshAccount,So as retryMultipleTimes,xo as safeWindow,Dr as sanitizeCallbackUrl,br as setAxiosInterceptors,Ro as sleep,Eo as storage,ar as stringContainsNumbers,Fo as subscriptions,rr as trimUsernameDomain,ro as websocketConnection};
1
+ import"./__chunks__/chunk-CXE2WQJS.mjs";import"./__chunks__/chunk-2IEOAR7H.mjs";import{a as to}from"./__chunks__/chunk-QQ4OPT5A.mjs";import"./__chunks__/chunk-YV7ZJBAY.mjs";import"./__chunks__/chunk-DXRSXWLQ.mjs";import"./__chunks__/chunk-K5MJ4FMD.mjs";import{a as fo}from"./__chunks__/chunk-X2JK27T3.mjs";import"./__chunks__/chunk-INRKVOET.mjs";import"./__chunks__/chunk-6ET5BDZH.mjs";import{a as mo}from"./__chunks__/chunk-LSKZWWBZ.mjs";import"./__chunks__/chunk-7BRIA6SS.mjs";import{q as er}from"./__chunks__/chunk-J7P6SJOM.mjs";import"./__chunks__/chunk-4HEE3XZP.mjs";import"./__chunks__/chunk-SCSHU7XJ.mjs";import"./__chunks__/chunk-RHN3VD44.mjs";import"./__chunks__/chunk-YPNKNMW5.mjs";import"./__chunks__/chunk-L2JWXTGG.mjs";import"./__chunks__/chunk-PEDR76UT.mjs";import"./__chunks__/chunk-M3C5NS6M.mjs";import"./__chunks__/chunk-PLFZHJOX.mjs";import"./__chunks__/chunk-QD3CFFVT.mjs";import"./__chunks__/chunk-UP7CK2EN.mjs";import"./__chunks__/chunk-WGOZYG4T.mjs";import"./__chunks__/chunk-JXO7XRIR.mjs";import"./__chunks__/chunk-5WVAF7RB.mjs";import"./__chunks__/chunk-7OTTISMZ.mjs";import"./__chunks__/chunk-MFUQ5NBC.mjs";import"./__chunks__/chunk-UFMHCVBL.mjs";import"./__chunks__/chunk-SBQJGS63.mjs";import"./__chunks__/chunk-WW4BBBLW.mjs";import"./__chunks__/chunk-ZFXAT6MD.mjs";import{a as po}from"./__chunks__/chunk-Q2Q4XN4M.mjs";import"./__chunks__/chunk-672ZNZKR.mjs";import"./__chunks__/chunk-G2DLIXFQ.mjs";import"./__chunks__/chunk-W4GE4ZDP.mjs";import"./__chunks__/chunk-4ODPAHHA.mjs";import"./__chunks__/chunk-ECEWPZGA.mjs";import"./__chunks__/chunk-OTBTZ3NI.mjs";import"./__chunks__/chunk-WVTCO3AV.mjs";import"./__chunks__/chunk-FTFAEXVE.mjs";import"./__chunks__/chunk-N7KSN2OU.mjs";import"./__chunks__/chunk-6746F2FY.mjs";import"./__chunks__/chunk-CBIH5QMT.mjs";import"./__chunks__/chunk-R7SGL2HW.mjs";import"./__chunks__/chunk-WV5X6BXA.mjs";import"./__chunks__/chunk-YAXVLGG3.mjs";import"./__chunks__/chunk-NWEUIK3A.mjs";import{a as Zo}from"./__chunks__/chunk-TLKMUVQJ.mjs";import"./__chunks__/chunk-3S57OP4Z.mjs";import"./__chunks__/chunk-OJX2TSAZ.mjs";import"./__chunks__/chunk-RIQNG4I7.mjs";import"./__chunks__/chunk-IMGZJVC6.mjs";import"./__chunks__/chunk-QTKK6OSJ.mjs";import"./__chunks__/chunk-6ACLOUQ3.mjs";import"./__chunks__/chunk-WE7YOBO7.mjs";import"./__chunks__/chunk-J32T6OAP.mjs";import"./__chunks__/chunk-UYUKTC4X.mjs";import{a as X}from"./__chunks__/chunk-YK7T6MBD.mjs";import{a as Y}from"./__chunks__/chunk-KMJMQEXI.mjs";import"./__chunks__/chunk-4US7HVCR.mjs";import"./__chunks__/chunk-HC5QPKZT.mjs";import"./__chunks__/chunk-4TBVQD27.mjs";import"./__chunks__/chunk-M3GFSV3G.mjs";import"./__chunks__/chunk-G5DKGX73.mjs";import"./__chunks__/chunk-45H34XLJ.mjs";import"./__chunks__/chunk-AGI2ZR6R.mjs";import"./__chunks__/chunk-L3MWDI6J.mjs";import"./__chunks__/chunk-65L5EBBL.mjs";import"./__chunks__/chunk-L3YPAYXZ.mjs";import"./__chunks__/chunk-QI2QMNTG.mjs";import{a as or}from"./__chunks__/chunk-6FXEHNGW.mjs";import{a as V,b as W}from"./__chunks__/chunk-ZLE5VUWG.mjs";import{a as A}from"./__chunks__/chunk-3GGBXXXJ.mjs";import"./__chunks__/chunk-RMW3YLGD.mjs";import{a as mr}from"./__chunks__/chunk-FPJ2PIFX.mjs";import{a as fr}from"./__chunks__/chunk-NJN53MJV.mjs";import{a as To}from"./__chunks__/chunk-YSCND2MX.mjs";import{a as rr}from"./__chunks__/chunk-HORSXVIV.mjs";import"./__chunks__/chunk-YJK5FPW4.mjs";import{a as br}from"./__chunks__/chunk-36XFDUXN.mjs";import"./__chunks__/chunk-ZAPRDHIW.mjs";import{a as ar}from"./__chunks__/chunk-WVAP3V3E.mjs";import{a as xr}from"./__chunks__/chunk-GIZSIYH4.mjs";import{a as z}from"./__chunks__/chunk-X6MN67NW.mjs";import{a as tr}from"./__chunks__/chunk-XVX7N3JK.mjs";import{a as pr}from"./__chunks__/chunk-HH5SA7BX.mjs";import"./__chunks__/chunk-CDTYHGXZ.mjs";import{a as eo}from"./__chunks__/chunk-3FXHIV6O.mjs";import"./__chunks__/chunk-6CQMLD25.mjs";import{a as dr}from"./__chunks__/chunk-3IYQANTT.mjs";import"./__chunks__/chunk-JR3FBBRR.mjs";import"./__chunks__/chunk-IXBWD6BF.mjs";import{a as Br}from"./__chunks__/chunk-JGULQG2H.mjs";import"./__chunks__/chunk-VCAWVAO5.mjs";import{a as zr}from"./__chunks__/chunk-55W25Q35.mjs";import{a as Ar}from"./__chunks__/chunk-Y3YLDFXK.mjs";import"./__chunks__/chunk-ENTPR3MV.mjs";import"./__chunks__/chunk-NM3KJ3EA.mjs";import"./__chunks__/chunk-BXKFACG5.mjs";import"./__chunks__/chunk-CN4RHVUE.mjs";import"./__chunks__/chunk-T4FRQ4JG.mjs";import"./__chunks__/chunk-IEJTMYFW.mjs";import"./__chunks__/chunk-UTWIKUIK.mjs";import"./__chunks__/chunk-LTF535HP.mjs";import"./__chunks__/chunk-KPK72MOE.mjs";import"./__chunks__/chunk-SAAOQW7P.mjs";import"./__chunks__/chunk-VNLGNNIL.mjs";import"./__chunks__/chunk-ZODTYAYF.mjs";import"./__chunks__/chunk-NLRDRI7Q.mjs";import"./__chunks__/chunk-DKX6JUT6.mjs";import"./__chunks__/chunk-RZ4YTKD7.mjs";import"./__chunks__/chunk-KRWR77QE.mjs";import"./__chunks__/chunk-B7YCKWDU.mjs";import"./__chunks__/chunk-5N4F5T5L.mjs";import"./__chunks__/chunk-SUN3MVLZ.mjs";import"./__chunks__/chunk-HDJOER66.mjs";import"./__chunks__/chunk-A7FTKX2A.mjs";import"./__chunks__/chunk-XKU5QBXG.mjs";import"./__chunks__/chunk-TYYA6E7F.mjs";import"./__chunks__/chunk-KMFYDHOY.mjs";import"./__chunks__/chunk-S2B2ZKIJ.mjs";import"./__chunks__/chunk-2DNGCNYM.mjs";import"./__chunks__/chunk-SQVKVA7X.mjs";import"./__chunks__/chunk-T2YPFNVM.mjs";import"./__chunks__/chunk-X4XULIVT.mjs";import"./__chunks__/chunk-I24YBVHK.mjs";import"./__chunks__/chunk-YMPZDHKF.mjs";import"./__chunks__/chunk-VKEESSBI.mjs";import"./__chunks__/chunk-NB7A4C7L.mjs";import{a as yr}from"./__chunks__/chunk-XO5D3FNU.mjs";import{a as wr}from"./__chunks__/chunk-UF45HLIK.mjs";import"./__chunks__/chunk-TAI3I5BS.mjs";import"./__chunks__/chunk-JTQCNFCR.mjs";import"./__chunks__/chunk-M6ATGCOM.mjs";import{a as vr}from"./__chunks__/chunk-SF7XXVIO.mjs";import"./__chunks__/chunk-54B3EIZC.mjs";import"./__chunks__/chunk-QJ7MRSGB.mjs";import{a as jr}from"./__chunks__/chunk-VDDXFGB2.mjs";import{b as ir}from"./__chunks__/chunk-LNABNVAO.mjs";import"./__chunks__/chunk-HMHP5DPL.mjs";import"./__chunks__/chunk-VIJUIJ4V.mjs";import"./__chunks__/chunk-35MNP3LA.mjs";import"./__chunks__/chunk-TX7PTLVP.mjs";import{a as hr}from"./__chunks__/chunk-WZ2DNB3R.mjs";import"./__chunks__/chunk-BRJNX4JF.mjs";import"./__chunks__/chunk-K3G3SPRT.mjs";import{a as cr}from"./__chunks__/chunk-DBIIY2TX.mjs";import{a as o,b as r,c as e,d as f,e as m,f as p,g as t,h as x,i as a,j as b,k as c,l as d,m as g,n as h,o as i,p as j,q as k,r as l,s as n,t as q,u as s,v as u,w as v,x as w,y}from"./__chunks__/chunk-KD2IQ32V.mjs";import"./__chunks__/chunk-HQQMSHTW.mjs";import"./__chunks__/chunk-UQU2VWPJ.mjs";import{a as qr,b as sr,c as ur}from"./__chunks__/chunk-3NG7LKF4.mjs";import"./__chunks__/chunk-CO3V5DOG.mjs";import{a as _o}from"./__chunks__/chunk-TVELGQIH.mjs";import"./__chunks__/chunk-2BSPSW6X.mjs";import"./__chunks__/chunk-OOJVPJOX.mjs";import"./__chunks__/chunk-OVXVICF7.mjs";import{a as $o}from"./__chunks__/chunk-WZI2I6NX.mjs";import{a as Uo,b as Vo,c as Wo}from"./__chunks__/chunk-TI37DKBT.mjs";import"./__chunks__/chunk-2CNSQULM.mjs";import{a as lr,b as nr}from"./__chunks__/chunk-WRLZ5ICK.mjs";import{a as kr}from"./__chunks__/chunk-I3MK6KZJ.mjs";import{a as gr}from"./__chunks__/chunk-B3IKUIRK.mjs";import"./__chunks__/chunk-THQWNWSE.mjs";import{a as Cr}from"./__chunks__/chunk-2RAULLHL.mjs";import{a as So}from"./__chunks__/chunk-MGQ373AO.mjs";import"./__chunks__/chunk-RPTH42EF.mjs";import{a as Ro}from"./__chunks__/chunk-3UNGCOKO.mjs";import"./__chunks__/chunk-5Y2ZDPP6.mjs";import{a as no,b as qo,c as so,d as uo,e as vo,f as wo,g as yo,h as zo,i as Ao,j as Bo,k as Co}from"./__chunks__/chunk-LHEH7L4L.mjs";import{a as ao,b as bo}from"./__chunks__/chunk-C4CJOZ4L.mjs";import{a as Go,b as Ho,c as Io,d as Jo,e as Ko,f as Lo,g as Mo,h as No,i as Oo,j as Po}from"./__chunks__/chunk-EJV4VNJG.mjs";import{a as Qo}from"./__chunks__/chunk-2X7ENE6Y.mjs";import{a as co,b as go,c as ho,d as io,e as jo,f as ko,g as lo}from"./__chunks__/chunk-FI444OX3.mjs";import{a as Do,b as Eo,c as Fo}from"./__chunks__/chunk-PPA7AFVD.mjs";import{a as K,b as L,c as M,d as N,e as O,f as P,g as Q,h as R,i as S,j as T,k as U}from"./__chunks__/chunk-ULUZWP2P.mjs";import{a as oo,b as ro}from"./__chunks__/chunk-GGBMHKR4.mjs";import{a as Z,b as _,c as $}from"./__chunks__/chunk-MGFIOCA4.mjs";import{a as B,b as C,c as D,d as E,e as F,f as G,g as H,h as I,i as J}from"./__chunks__/chunk-GLXG5BES.mjs";import"./__chunks__/chunk-MCOVQEK7.mjs";import"./__chunks__/chunk-DTQL3IDP.mjs";import{a as Yo}from"./__chunks__/chunk-LRHRFWQ4.mjs";import{a as Gr}from"./__chunks__/chunk-AJEWAECH.mjs";import"./__chunks__/chunk-RVW2ZWCR.mjs";import{a as Fr}from"./__chunks__/chunk-EHDGJUEU.mjs";import{a as Er}from"./__chunks__/chunk-HOCSCRJF.mjs";import{a as xo}from"./__chunks__/chunk-7QCBLUWB.mjs";import{a as Dr}from"./__chunks__/chunk-UE3IBKCO.mjs";import"./__chunks__/chunk-H6IZMTJK.mjs";import{a as Xo}from"./__chunks__/chunk-B2UIPHJ3.mjs";export{o as ACCOUNTS_ENDPOINT,r as ADDRESS_ENDPOINT,Ao as ALL_SHARDS_SHARD_ID,e as BLOCKS_ENDPOINT,f as CODE_ENDPOINT,m as COLLECTIONS_ENDPOINT,p as CONFIG_ENDPOINT,t as CONTRACTS_ENDPOINT,L as DEVNET_CHAIN_ID,M as DEVNET_EGLD_LABEL,x as ECONOMICS_ENDPOINT,_ as ELLIPSIS,$ as EMPTY_PPU,G as ESDTTransferTypesEnum,uo as EXTRA_GAS_LIMIT_GUARDED_TX,B as EnvironmentsEnum,to as FormatAmountController,so as GAS_LIMIT,qo as GAS_PER_DATA_BYTE,vo as GAS_PRICE,no as GAS_PRICE_MODIFIER,H as GuardianActionsEnum,a as IDENTITIES_ENDPOINT,b as KEYS_ENDPOINT,yo as LEDGER_CONTRACT_DATA_ENABLED_VALUE,go as LEDGER_HASH_SIGN_MINIMUM_VERSION,co as LEDGER_MULTI_ACCOUNT_MINIMUM_VERSION,ho as LEDGER_SIGN_AUTH_TOKEN_MINIMUM_VERSION,jo as LEDGER_WITH_GUARDIANS_MINIMUM_VERSION,ko as LEDGER_WITH_USERNAMES_MINIMUM_VERSION,io as LEDGER_WITH_WHITELISTED_TOKENS_MINIMUM_VERSION,c as LOCKED_ACCOUNTS_ENDPOINT,d as LOGS_ENDPOINT,P as MAINNET_CHAIN_ID,Q as MAINNET_EGLD_LABEL,zo as METACHAIN_SHARD_ID,g as MINIBLOCKS_ENDPOINT,T as MULTIVERSX_ORIGIN,Co as MULTI_TRANSFER_EGLD_TOKEN,h as NETWORK_CONFIG_ENDPOINT,i as NFTS_ENDPOINT,j as NODES_ENDPOINT,Z as N_A,k as PROVIDERS_ENDPOINT,_o as ProviderErrorsEnum,Bo as REFUNDED_GAS,l as ROLES_ENDPOINT,n as SC_RESULTS_ENDPOINT,q as STAKE_ENDPOINT,I as SigningErrorsEnum,J as SigningWarningsEnum,$o as SubscriptionsEnum,N as TESTNET_CHAIN_ID,O as TESTNET_EGLD_LABEL,U as TIMEOUT,s as TOKENS_ENDPOINT,v as TRANSACTIONS_BATCH,u as TRANSACTIONS_COUNT_ENDPOINT,w as TRANSACTIONS_ENDPOINT,y as TRANSFERS_ENDPOINT,E as TransactionBatchStatusesEnum,C as TransactionServerStatusesEnum,D as TransactionTypesEnum,F as TypesOfSmartContractCallsEnum,wo as VERSION,Oo as WALLET_PROVIDER_CALLBACK_PARAM,Po as WALLET_PROVIDER_CALLBACK_PARAM_TX_SIGNED,Jo as WALLET_PROVIDER_CONNECT_URL,Ho as WALLET_PROVIDER_DEVNET,Ko as WALLET_PROVIDER_DISCONNECT_URL,Go as WALLET_PROVIDER_MAINNET,Lo as WALLET_PROVIDER_SEND_TRANSACTION_URL,No as WALLET_PROVIDER_SIGN_MESSAGE_URL,Mo as WALLET_PROVIDER_SIGN_TRANSACTION_URL,Io as WALLET_PROVIDER_TESTNET,oo as WebsocketConnectionStatusEnum,V as accountFetcher,kr as addressIsValid,mo as axiosFetcher,z as axiosInstance,Er as buildUrlParams,R as chainIdByEnvironment,S as chainIdToEnvironment,zr as createTransactionsHistoryFromSessions,Wo as decodeBase64,tr as decodePart,Vo as encodeToBase64,cr as explorerUrlBuilder,K as fallbackNetworkConfigurations,or as fetchAccount,W as getAccountFromApi,dr as getActiveTransactionsStatus,ur as getAddressFromDataField,A as getCleanApiAddress,gr as getHumanReadableTimeFormat,eo as getIdentifierType,Fr as getIsAuthRoute,Gr as getIsInIframe,Y as getNetworkConfigFromApi,hr as getReceiverData,X as getServerConfiguration,fo as getTokenDetails,jr as getTransactionAmount,vr as getTransactionAsset,Br as getTransactionsHistory,To as getUnixTimestamp,fr as getUnixTimestampWithAddedMilliseconds,mr as getUnixTimestampWithAddedSeconds,po as getWebsocketUrl,Yo as getWindowLocation,xr as isAscii,bo as isBrowserWithPopupConfirmation,qr as isContract,lr as isHexValidCharacters,nr as isHexValidLength,ao as isSafari,sr as isSelfESDTContract,Uo as isStringBase64,pr as isUtf8,Xo as isWindowAvailable,lo as ledgerErrorCodes,Ar as mapServerTransactionsToListItems,yr as mapTransactionToListItem,Cr as maxDecimals,Zo as nativeAuth,Do as persistConfig,ir as processTransactionAction,wr as processTransactionAssets,Qo as providerLabels,er as refreshAccount,So as retryMultipleTimes,xo as safeWindow,Dr as sanitizeCallbackUrl,br as setAxiosInterceptors,Ro as sleep,Eo as storage,ar as stringContainsNumbers,Fo as subscriptions,rr as trimUsernameDomain,ro as websocketConnection};
2
2
  //# sourceMappingURL=index.mjs.map
@@ -1,2 +1,2 @@
1
- import{a}from"../../__chunks__/chunk-XKTDOIMV.mjs";import"../../__chunks__/chunk-RUBOJOJP.mjs";import"../../__chunks__/chunk-JO3DZYEB.mjs";import"../../__chunks__/chunk-T7DVMF2K.mjs";import"../../__chunks__/chunk-JZZ3MOUU.mjs";import"../../__chunks__/chunk-PMPTCB44.mjs";import"../../__chunks__/chunk-5AR7YU5K.mjs";import"../../__chunks__/chunk-VDMJZZU4.mjs";import"../../__chunks__/chunk-XCXU3BVP.mjs";import"../../__chunks__/chunk-YRHMGKLM.mjs";import"../../__chunks__/chunk-RI7FD4HM.mjs";import"../../__chunks__/chunk-HTPPS2MF.mjs";import"../../__chunks__/chunk-WUAYFGWU.mjs";import"../../__chunks__/chunk-FD3HLEX7.mjs";import"../../__chunks__/chunk-IOKDBFGH.mjs";import"../../__chunks__/chunk-4OO7HE5Q.mjs";import"../../__chunks__/chunk-X7AQOVLN.mjs";import"../../__chunks__/chunk-HK7HCSM3.mjs";import"../../__chunks__/chunk-SVNWQXWC.mjs";import"../../__chunks__/chunk-55SACSMS.mjs";import"../../__chunks__/chunk-TO3DGAQU.mjs";import"../../__chunks__/chunk-57KVKSEC.mjs";import"../../__chunks__/chunk-4HEE3XZP.mjs";import"../../__chunks__/chunk-SCSHU7XJ.mjs";import"../../__chunks__/chunk-RHN3VD44.mjs";import"../../__chunks__/chunk-YPNKNMW5.mjs";import"../../__chunks__/chunk-L2JWXTGG.mjs";import"../../__chunks__/chunk-PEDR76UT.mjs";import"../../__chunks__/chunk-M3C5NS6M.mjs";import"../../__chunks__/chunk-PLFZHJOX.mjs";import"../../__chunks__/chunk-QD3CFFVT.mjs";import"../../__chunks__/chunk-UP7CK2EN.mjs";import"../../__chunks__/chunk-WGOZYG4T.mjs";import"../../__chunks__/chunk-JXO7XRIR.mjs";import"../../__chunks__/chunk-5WVAF7RB.mjs";import"../../__chunks__/chunk-7OTTISMZ.mjs";import"../../__chunks__/chunk-MFUQ5NBC.mjs";import"../../__chunks__/chunk-UFMHCVBL.mjs";import"../../__chunks__/chunk-SBQJGS63.mjs";import"../../__chunks__/chunk-WW4BBBLW.mjs";import"../../__chunks__/chunk-ZFXAT6MD.mjs";import"../../__chunks__/chunk-Q2Q4XN4M.mjs";import"../../__chunks__/chunk-672ZNZKR.mjs";import"../../__chunks__/chunk-G2DLIXFQ.mjs";import"../../__chunks__/chunk-W4GE4ZDP.mjs";import"../../__chunks__/chunk-4ODPAHHA.mjs";import"../../__chunks__/chunk-ECEWPZGA.mjs";import"../../__chunks__/chunk-OTBTZ3NI.mjs";import"../../__chunks__/chunk-WVTCO3AV.mjs";import"../../__chunks__/chunk-FTFAEXVE.mjs";import"../../__chunks__/chunk-3PAMS4NB.mjs";import"../../__chunks__/chunk-6746F2FY.mjs";import"../../__chunks__/chunk-CBIH5QMT.mjs";import"../../__chunks__/chunk-R7SGL2HW.mjs";import"../../__chunks__/chunk-WV5X6BXA.mjs";import"../../__chunks__/chunk-YAXVLGG3.mjs";import"../../__chunks__/chunk-NWEUIK3A.mjs";import"../../__chunks__/chunk-TLKMUVQJ.mjs";import"../../__chunks__/chunk-3S57OP4Z.mjs";import"../../__chunks__/chunk-OJX2TSAZ.mjs";import"../../__chunks__/chunk-RIQNG4I7.mjs";import"../../__chunks__/chunk-IMGZJVC6.mjs";import"../../__chunks__/chunk-QTKK6OSJ.mjs";import"../../__chunks__/chunk-6ACLOUQ3.mjs";import"../../__chunks__/chunk-WE7YOBO7.mjs";import"../../__chunks__/chunk-J32T6OAP.mjs";import"../../__chunks__/chunk-UYUKTC4X.mjs";import"../../__chunks__/chunk-YK7T6MBD.mjs";import"../../__chunks__/chunk-KMJMQEXI.mjs";import"../../__chunks__/chunk-4US7HVCR.mjs";import"../../__chunks__/chunk-HC5QPKZT.mjs";import"../../__chunks__/chunk-4TBVQD27.mjs";import"../../__chunks__/chunk-M3GFSV3G.mjs";import"../../__chunks__/chunk-G5DKGX73.mjs";import"../../__chunks__/chunk-45H34XLJ.mjs";import"../../__chunks__/chunk-AGI2ZR6R.mjs";import"../../__chunks__/chunk-L3MWDI6J.mjs";import"../../__chunks__/chunk-65L5EBBL.mjs";import"../../__chunks__/chunk-L3YPAYXZ.mjs";import"../../__chunks__/chunk-QI2QMNTG.mjs";import"../../__chunks__/chunk-6FXEHNGW.mjs";import"../../__chunks__/chunk-ZLE5VUWG.mjs";import"../../__chunks__/chunk-3GGBXXXJ.mjs";import"../../__chunks__/chunk-RMW3YLGD.mjs";import"../../__chunks__/chunk-FPJ2PIFX.mjs";import"../../__chunks__/chunk-NJN53MJV.mjs";import"../../__chunks__/chunk-YSCND2MX.mjs";import"../../__chunks__/chunk-HORSXVIV.mjs";import"../../__chunks__/chunk-YJK5FPW4.mjs";import"../../__chunks__/chunk-36XFDUXN.mjs";import"../../__chunks__/chunk-ZAPRDHIW.mjs";import"../../__chunks__/chunk-WVAP3V3E.mjs";import"../../__chunks__/chunk-GIZSIYH4.mjs";import"../../__chunks__/chunk-X6MN67NW.mjs";import"../../__chunks__/chunk-XVX7N3JK.mjs";import"../../__chunks__/chunk-HH5SA7BX.mjs";import"../../__chunks__/chunk-CDTYHGXZ.mjs";import"../../__chunks__/chunk-3FXHIV6O.mjs";import"../../__chunks__/chunk-6CQMLD25.mjs";import"../../__chunks__/chunk-3IYQANTT.mjs";import"../../__chunks__/chunk-JR3FBBRR.mjs";import"../../__chunks__/chunk-IXBWD6BF.mjs";import"../../__chunks__/chunk-JGULQG2H.mjs";import"../../__chunks__/chunk-VCAWVAO5.mjs";import"../../__chunks__/chunk-55W25Q35.mjs";import"../../__chunks__/chunk-Y3YLDFXK.mjs";import"../../__chunks__/chunk-ENTPR3MV.mjs";import"../../__chunks__/chunk-NM3KJ3EA.mjs";import"../../__chunks__/chunk-BXKFACG5.mjs";import"../../__chunks__/chunk-CN4RHVUE.mjs";import"../../__chunks__/chunk-T4FRQ4JG.mjs";import"../../__chunks__/chunk-IEJTMYFW.mjs";import"../../__chunks__/chunk-UTWIKUIK.mjs";import"../../__chunks__/chunk-LTF535HP.mjs";import"../../__chunks__/chunk-KPK72MOE.mjs";import"../../__chunks__/chunk-SAAOQW7P.mjs";import"../../__chunks__/chunk-VNLGNNIL.mjs";import"../../__chunks__/chunk-ZODTYAYF.mjs";import"../../__chunks__/chunk-NLRDRI7Q.mjs";import"../../__chunks__/chunk-DKX6JUT6.mjs";import"../../__chunks__/chunk-RZ4YTKD7.mjs";import"../../__chunks__/chunk-KRWR77QE.mjs";import"../../__chunks__/chunk-B7YCKWDU.mjs";import"../../__chunks__/chunk-5N4F5T5L.mjs";import"../../__chunks__/chunk-SUN3MVLZ.mjs";import"../../__chunks__/chunk-HDJOER66.mjs";import"../../__chunks__/chunk-A7FTKX2A.mjs";import"../../__chunks__/chunk-XKU5QBXG.mjs";import"../../__chunks__/chunk-TYYA6E7F.mjs";import"../../__chunks__/chunk-KMFYDHOY.mjs";import"../../__chunks__/chunk-S2B2ZKIJ.mjs";import"../../__chunks__/chunk-2DNGCNYM.mjs";import"../../__chunks__/chunk-SQVKVA7X.mjs";import"../../__chunks__/chunk-T2YPFNVM.mjs";import"../../__chunks__/chunk-X4XULIVT.mjs";import"../../__chunks__/chunk-I24YBVHK.mjs";import"../../__chunks__/chunk-YMPZDHKF.mjs";import"../../__chunks__/chunk-VKEESSBI.mjs";import"../../__chunks__/chunk-NB7A4C7L.mjs";import"../../__chunks__/chunk-XO5D3FNU.mjs";import"../../__chunks__/chunk-UF45HLIK.mjs";import"../../__chunks__/chunk-TAI3I5BS.mjs";import"../../__chunks__/chunk-JTQCNFCR.mjs";import"../../__chunks__/chunk-M6ATGCOM.mjs";import"../../__chunks__/chunk-SF7XXVIO.mjs";import"../../__chunks__/chunk-54B3EIZC.mjs";import"../../__chunks__/chunk-QJ7MRSGB.mjs";import"../../__chunks__/chunk-VDDXFGB2.mjs";import"../../__chunks__/chunk-LNABNVAO.mjs";import"../../__chunks__/chunk-HMHP5DPL.mjs";import"../../__chunks__/chunk-VIJUIJ4V.mjs";import"../../__chunks__/chunk-35MNP3LA.mjs";import"../../__chunks__/chunk-TX7PTLVP.mjs";import"../../__chunks__/chunk-WZ2DNB3R.mjs";import"../../__chunks__/chunk-BRJNX4JF.mjs";import"../../__chunks__/chunk-K3G3SPRT.mjs";import"../../__chunks__/chunk-DBIIY2TX.mjs";import"../../__chunks__/chunk-KD2IQ32V.mjs";import"../../__chunks__/chunk-HQQMSHTW.mjs";import"../../__chunks__/chunk-UQU2VWPJ.mjs";import"../../__chunks__/chunk-3NG7LKF4.mjs";import"../../__chunks__/chunk-CO3V5DOG.mjs";import"../../__chunks__/chunk-TVELGQIH.mjs";import"../../__chunks__/chunk-2BSPSW6X.mjs";import"../../__chunks__/chunk-OOJVPJOX.mjs";import"../../__chunks__/chunk-OVXVICF7.mjs";import"../../__chunks__/chunk-WZI2I6NX.mjs";import"../../__chunks__/chunk-TI37DKBT.mjs";import"../../__chunks__/chunk-2CNSQULM.mjs";import"../../__chunks__/chunk-WRLZ5ICK.mjs";import"../../__chunks__/chunk-I3MK6KZJ.mjs";import"../../__chunks__/chunk-B3IKUIRK.mjs";import"../../__chunks__/chunk-THQWNWSE.mjs";import"../../__chunks__/chunk-2RAULLHL.mjs";import"../../__chunks__/chunk-MGQ373AO.mjs";import"../../__chunks__/chunk-RPTH42EF.mjs";import"../../__chunks__/chunk-3UNGCOKO.mjs";import"../../__chunks__/chunk-YMME2BFO.mjs";import"../../__chunks__/chunk-VMFJUT3G.mjs";import"../../__chunks__/chunk-5Y2ZDPP6.mjs";import"../../__chunks__/chunk-LHEH7L4L.mjs";import"../../__chunks__/chunk-C4CJOZ4L.mjs";import"../../__chunks__/chunk-EJV4VNJG.mjs";import"../../__chunks__/chunk-2X7ENE6Y.mjs";import"../../__chunks__/chunk-FI444OX3.mjs";import"../../__chunks__/chunk-PPA7AFVD.mjs";import"../../__chunks__/chunk-ULUZWP2P.mjs";import"../../__chunks__/chunk-GGBMHKR4.mjs";import"../../__chunks__/chunk-MGFIOCA4.mjs";import"../../__chunks__/chunk-GLXG5BES.mjs";import"../../__chunks__/chunk-MCOVQEK7.mjs";import"../../__chunks__/chunk-DTQL3IDP.mjs";import"../../__chunks__/chunk-LRHRFWQ4.mjs";import"../../__chunks__/chunk-AJEWAECH.mjs";import"../../__chunks__/chunk-RVW2ZWCR.mjs";import"../../__chunks__/chunk-EHDGJUEU.mjs";import"../../__chunks__/chunk-HOCSCRJF.mjs";import"../../__chunks__/chunk-7QCBLUWB.mjs";import"../../__chunks__/chunk-UE3IBKCO.mjs";import"../../__chunks__/chunk-H6IZMTJK.mjs";import"../../__chunks__/chunk-B2UIPHJ3.mjs";export{a as NotificationsFeedManager};
1
+ import{a}from"../../__chunks__/chunk-PBIRC7U4.mjs";import"../../__chunks__/chunk-RUBOJOJP.mjs";import"../../__chunks__/chunk-JO3DZYEB.mjs";import"../../__chunks__/chunk-T7DVMF2K.mjs";import"../../__chunks__/chunk-JZZ3MOUU.mjs";import"../../__chunks__/chunk-PMPTCB44.mjs";import"../../__chunks__/chunk-5AR7YU5K.mjs";import"../../__chunks__/chunk-VDMJZZU4.mjs";import"../../__chunks__/chunk-CRSZQV7V.mjs";import"../../__chunks__/chunk-YRHMGKLM.mjs";import"../../__chunks__/chunk-RI7FD4HM.mjs";import"../../__chunks__/chunk-HTPPS2MF.mjs";import"../../__chunks__/chunk-WUAYFGWU.mjs";import"../../__chunks__/chunk-FD3HLEX7.mjs";import"../../__chunks__/chunk-IOKDBFGH.mjs";import"../../__chunks__/chunk-4OO7HE5Q.mjs";import"../../__chunks__/chunk-X7AQOVLN.mjs";import"../../__chunks__/chunk-HK7HCSM3.mjs";import"../../__chunks__/chunk-SVNWQXWC.mjs";import"../../__chunks__/chunk-55SACSMS.mjs";import"../../__chunks__/chunk-TO3DGAQU.mjs";import"../../__chunks__/chunk-J7P6SJOM.mjs";import"../../__chunks__/chunk-4HEE3XZP.mjs";import"../../__chunks__/chunk-SCSHU7XJ.mjs";import"../../__chunks__/chunk-RHN3VD44.mjs";import"../../__chunks__/chunk-YPNKNMW5.mjs";import"../../__chunks__/chunk-L2JWXTGG.mjs";import"../../__chunks__/chunk-PEDR76UT.mjs";import"../../__chunks__/chunk-M3C5NS6M.mjs";import"../../__chunks__/chunk-PLFZHJOX.mjs";import"../../__chunks__/chunk-QD3CFFVT.mjs";import"../../__chunks__/chunk-UP7CK2EN.mjs";import"../../__chunks__/chunk-WGOZYG4T.mjs";import"../../__chunks__/chunk-JXO7XRIR.mjs";import"../../__chunks__/chunk-5WVAF7RB.mjs";import"../../__chunks__/chunk-7OTTISMZ.mjs";import"../../__chunks__/chunk-MFUQ5NBC.mjs";import"../../__chunks__/chunk-UFMHCVBL.mjs";import"../../__chunks__/chunk-SBQJGS63.mjs";import"../../__chunks__/chunk-WW4BBBLW.mjs";import"../../__chunks__/chunk-ZFXAT6MD.mjs";import"../../__chunks__/chunk-Q2Q4XN4M.mjs";import"../../__chunks__/chunk-672ZNZKR.mjs";import"../../__chunks__/chunk-G2DLIXFQ.mjs";import"../../__chunks__/chunk-W4GE4ZDP.mjs";import"../../__chunks__/chunk-4ODPAHHA.mjs";import"../../__chunks__/chunk-ECEWPZGA.mjs";import"../../__chunks__/chunk-OTBTZ3NI.mjs";import"../../__chunks__/chunk-WVTCO3AV.mjs";import"../../__chunks__/chunk-FTFAEXVE.mjs";import"../../__chunks__/chunk-N7KSN2OU.mjs";import"../../__chunks__/chunk-6746F2FY.mjs";import"../../__chunks__/chunk-CBIH5QMT.mjs";import"../../__chunks__/chunk-R7SGL2HW.mjs";import"../../__chunks__/chunk-WV5X6BXA.mjs";import"../../__chunks__/chunk-YAXVLGG3.mjs";import"../../__chunks__/chunk-NWEUIK3A.mjs";import"../../__chunks__/chunk-TLKMUVQJ.mjs";import"../../__chunks__/chunk-3S57OP4Z.mjs";import"../../__chunks__/chunk-OJX2TSAZ.mjs";import"../../__chunks__/chunk-RIQNG4I7.mjs";import"../../__chunks__/chunk-IMGZJVC6.mjs";import"../../__chunks__/chunk-QTKK6OSJ.mjs";import"../../__chunks__/chunk-6ACLOUQ3.mjs";import"../../__chunks__/chunk-WE7YOBO7.mjs";import"../../__chunks__/chunk-J32T6OAP.mjs";import"../../__chunks__/chunk-UYUKTC4X.mjs";import"../../__chunks__/chunk-YK7T6MBD.mjs";import"../../__chunks__/chunk-KMJMQEXI.mjs";import"../../__chunks__/chunk-4US7HVCR.mjs";import"../../__chunks__/chunk-HC5QPKZT.mjs";import"../../__chunks__/chunk-4TBVQD27.mjs";import"../../__chunks__/chunk-M3GFSV3G.mjs";import"../../__chunks__/chunk-G5DKGX73.mjs";import"../../__chunks__/chunk-45H34XLJ.mjs";import"../../__chunks__/chunk-AGI2ZR6R.mjs";import"../../__chunks__/chunk-L3MWDI6J.mjs";import"../../__chunks__/chunk-65L5EBBL.mjs";import"../../__chunks__/chunk-L3YPAYXZ.mjs";import"../../__chunks__/chunk-QI2QMNTG.mjs";import"../../__chunks__/chunk-6FXEHNGW.mjs";import"../../__chunks__/chunk-ZLE5VUWG.mjs";import"../../__chunks__/chunk-3GGBXXXJ.mjs";import"../../__chunks__/chunk-RMW3YLGD.mjs";import"../../__chunks__/chunk-FPJ2PIFX.mjs";import"../../__chunks__/chunk-NJN53MJV.mjs";import"../../__chunks__/chunk-YSCND2MX.mjs";import"../../__chunks__/chunk-HORSXVIV.mjs";import"../../__chunks__/chunk-YJK5FPW4.mjs";import"../../__chunks__/chunk-36XFDUXN.mjs";import"../../__chunks__/chunk-ZAPRDHIW.mjs";import"../../__chunks__/chunk-WVAP3V3E.mjs";import"../../__chunks__/chunk-GIZSIYH4.mjs";import"../../__chunks__/chunk-X6MN67NW.mjs";import"../../__chunks__/chunk-XVX7N3JK.mjs";import"../../__chunks__/chunk-HH5SA7BX.mjs";import"../../__chunks__/chunk-CDTYHGXZ.mjs";import"../../__chunks__/chunk-3FXHIV6O.mjs";import"../../__chunks__/chunk-6CQMLD25.mjs";import"../../__chunks__/chunk-3IYQANTT.mjs";import"../../__chunks__/chunk-JR3FBBRR.mjs";import"../../__chunks__/chunk-IXBWD6BF.mjs";import"../../__chunks__/chunk-JGULQG2H.mjs";import"../../__chunks__/chunk-VCAWVAO5.mjs";import"../../__chunks__/chunk-55W25Q35.mjs";import"../../__chunks__/chunk-Y3YLDFXK.mjs";import"../../__chunks__/chunk-ENTPR3MV.mjs";import"../../__chunks__/chunk-NM3KJ3EA.mjs";import"../../__chunks__/chunk-BXKFACG5.mjs";import"../../__chunks__/chunk-CN4RHVUE.mjs";import"../../__chunks__/chunk-T4FRQ4JG.mjs";import"../../__chunks__/chunk-IEJTMYFW.mjs";import"../../__chunks__/chunk-UTWIKUIK.mjs";import"../../__chunks__/chunk-LTF535HP.mjs";import"../../__chunks__/chunk-KPK72MOE.mjs";import"../../__chunks__/chunk-SAAOQW7P.mjs";import"../../__chunks__/chunk-VNLGNNIL.mjs";import"../../__chunks__/chunk-ZODTYAYF.mjs";import"../../__chunks__/chunk-NLRDRI7Q.mjs";import"../../__chunks__/chunk-DKX6JUT6.mjs";import"../../__chunks__/chunk-RZ4YTKD7.mjs";import"../../__chunks__/chunk-KRWR77QE.mjs";import"../../__chunks__/chunk-B7YCKWDU.mjs";import"../../__chunks__/chunk-5N4F5T5L.mjs";import"../../__chunks__/chunk-SUN3MVLZ.mjs";import"../../__chunks__/chunk-HDJOER66.mjs";import"../../__chunks__/chunk-A7FTKX2A.mjs";import"../../__chunks__/chunk-XKU5QBXG.mjs";import"../../__chunks__/chunk-TYYA6E7F.mjs";import"../../__chunks__/chunk-KMFYDHOY.mjs";import"../../__chunks__/chunk-S2B2ZKIJ.mjs";import"../../__chunks__/chunk-2DNGCNYM.mjs";import"../../__chunks__/chunk-SQVKVA7X.mjs";import"../../__chunks__/chunk-T2YPFNVM.mjs";import"../../__chunks__/chunk-X4XULIVT.mjs";import"../../__chunks__/chunk-I24YBVHK.mjs";import"../../__chunks__/chunk-YMPZDHKF.mjs";import"../../__chunks__/chunk-VKEESSBI.mjs";import"../../__chunks__/chunk-NB7A4C7L.mjs";import"../../__chunks__/chunk-XO5D3FNU.mjs";import"../../__chunks__/chunk-UF45HLIK.mjs";import"../../__chunks__/chunk-TAI3I5BS.mjs";import"../../__chunks__/chunk-JTQCNFCR.mjs";import"../../__chunks__/chunk-M6ATGCOM.mjs";import"../../__chunks__/chunk-SF7XXVIO.mjs";import"../../__chunks__/chunk-54B3EIZC.mjs";import"../../__chunks__/chunk-QJ7MRSGB.mjs";import"../../__chunks__/chunk-VDDXFGB2.mjs";import"../../__chunks__/chunk-LNABNVAO.mjs";import"../../__chunks__/chunk-HMHP5DPL.mjs";import"../../__chunks__/chunk-VIJUIJ4V.mjs";import"../../__chunks__/chunk-35MNP3LA.mjs";import"../../__chunks__/chunk-TX7PTLVP.mjs";import"../../__chunks__/chunk-WZ2DNB3R.mjs";import"../../__chunks__/chunk-BRJNX4JF.mjs";import"../../__chunks__/chunk-K3G3SPRT.mjs";import"../../__chunks__/chunk-DBIIY2TX.mjs";import"../../__chunks__/chunk-KD2IQ32V.mjs";import"../../__chunks__/chunk-HQQMSHTW.mjs";import"../../__chunks__/chunk-UQU2VWPJ.mjs";import"../../__chunks__/chunk-3NG7LKF4.mjs";import"../../__chunks__/chunk-CO3V5DOG.mjs";import"../../__chunks__/chunk-TVELGQIH.mjs";import"../../__chunks__/chunk-2BSPSW6X.mjs";import"../../__chunks__/chunk-OOJVPJOX.mjs";import"../../__chunks__/chunk-OVXVICF7.mjs";import"../../__chunks__/chunk-WZI2I6NX.mjs";import"../../__chunks__/chunk-TI37DKBT.mjs";import"../../__chunks__/chunk-2CNSQULM.mjs";import"../../__chunks__/chunk-WRLZ5ICK.mjs";import"../../__chunks__/chunk-I3MK6KZJ.mjs";import"../../__chunks__/chunk-B3IKUIRK.mjs";import"../../__chunks__/chunk-THQWNWSE.mjs";import"../../__chunks__/chunk-2RAULLHL.mjs";import"../../__chunks__/chunk-MGQ373AO.mjs";import"../../__chunks__/chunk-RPTH42EF.mjs";import"../../__chunks__/chunk-3UNGCOKO.mjs";import"../../__chunks__/chunk-YMME2BFO.mjs";import"../../__chunks__/chunk-VMFJUT3G.mjs";import"../../__chunks__/chunk-5Y2ZDPP6.mjs";import"../../__chunks__/chunk-LHEH7L4L.mjs";import"../../__chunks__/chunk-C4CJOZ4L.mjs";import"../../__chunks__/chunk-EJV4VNJG.mjs";import"../../__chunks__/chunk-2X7ENE6Y.mjs";import"../../__chunks__/chunk-FI444OX3.mjs";import"../../__chunks__/chunk-PPA7AFVD.mjs";import"../../__chunks__/chunk-ULUZWP2P.mjs";import"../../__chunks__/chunk-GGBMHKR4.mjs";import"../../__chunks__/chunk-MGFIOCA4.mjs";import"../../__chunks__/chunk-GLXG5BES.mjs";import"../../__chunks__/chunk-MCOVQEK7.mjs";import"../../__chunks__/chunk-DTQL3IDP.mjs";import"../../__chunks__/chunk-LRHRFWQ4.mjs";import"../../__chunks__/chunk-AJEWAECH.mjs";import"../../__chunks__/chunk-RVW2ZWCR.mjs";import"../../__chunks__/chunk-EHDGJUEU.mjs";import"../../__chunks__/chunk-HOCSCRJF.mjs";import"../../__chunks__/chunk-7QCBLUWB.mjs";import"../../__chunks__/chunk-UE3IBKCO.mjs";import"../../__chunks__/chunk-H6IZMTJK.mjs";import"../../__chunks__/chunk-B2UIPHJ3.mjs";export{a as NotificationsFeedManager};
2
2
  //# sourceMappingURL=NotificationsFeedManager.mjs.map