@ledgerhq/live-common 34.42.0-nightly.3 → 34.42.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/__tests__/migration/account-migration.js +0 -3
- package/lib/__tests__/migration/account-migration.js.map +1 -1
- package/lib/__tests__/test-helpers/environment.js +0 -3
- package/lib/__tests__/test-helpers/environment.js.map +1 -1
- package/lib/bridge/generic-alpaca/alpaca/network/network-alpaca.d.ts +1 -3
- package/lib/bridge/generic-alpaca/alpaca/network/network-alpaca.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/alpaca/network/network-alpaca.js +0 -6
- package/lib/bridge/generic-alpaca/alpaca/network/network-alpaca.js.map +1 -1
- package/lib/bridge/impl.d.ts +0 -2
- package/lib/bridge/impl.d.ts.map +1 -1
- package/lib/bridge/impl.js +1 -8
- package/lib/bridge/impl.js.map +1 -1
- package/lib/bridge/useBridgeTransaction.test.js +1 -1
- package/lib/bridge/useBridgeTransaction.test.js.map +1 -1
- package/lib/e2e/index.d.ts +0 -6
- package/lib/e2e/index.d.ts.map +1 -1
- package/lib/e2e/speculos.d.ts.map +1 -1
- package/lib/e2e/speculos.js +2 -5
- package/lib/e2e/speculos.js.map +1 -1
- package/lib/families/evm/config.d.ts.map +1 -1
- package/lib/families/evm/config.js +0 -51
- package/lib/families/evm/config.js.map +1 -1
- package/lib/families/evm/walletApiAdapter.js +1 -1
- package/lib/featureFlags/defaultFeatures.d.ts +0 -3
- package/lib/featureFlags/defaultFeatures.d.ts.map +1 -1
- package/lib/featureFlags/defaultFeatures.js +0 -3
- package/lib/featureFlags/defaultFeatures.js.map +1 -1
- package/lib/modularDrawer/utils/index.d.ts +1 -2
- package/lib/modularDrawer/utils/index.d.ts.map +1 -1
- package/lib/modularDrawer/utils/index.js +1 -3
- package/lib/modularDrawer/utils/index.js.map +1 -1
- package/lib/wallet-api/Exchange/server.d.ts.map +1 -1
- package/lib/wallet-api/Exchange/server.js +6 -6
- package/lib/wallet-api/Exchange/server.js.map +1 -1
- package/lib-es/__tests__/migration/account-migration.js +0 -3
- package/lib-es/__tests__/migration/account-migration.js.map +1 -1
- package/lib-es/__tests__/test-helpers/environment.js +0 -3
- package/lib-es/__tests__/test-helpers/environment.js.map +1 -1
- package/lib-es/bridge/generic-alpaca/alpaca/network/network-alpaca.d.ts +1 -3
- package/lib-es/bridge/generic-alpaca/alpaca/network/network-alpaca.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/alpaca/network/network-alpaca.js +0 -6
- package/lib-es/bridge/generic-alpaca/alpaca/network/network-alpaca.js.map +1 -1
- package/lib-es/bridge/impl.d.ts +0 -2
- package/lib-es/bridge/impl.d.ts.map +1 -1
- package/lib-es/bridge/impl.js +0 -6
- package/lib-es/bridge/impl.js.map +1 -1
- package/lib-es/bridge/useBridgeTransaction.test.js +1 -1
- package/lib-es/bridge/useBridgeTransaction.test.js.map +1 -1
- package/lib-es/e2e/index.d.ts +0 -6
- package/lib-es/e2e/index.d.ts.map +1 -1
- package/lib-es/e2e/speculos.d.ts.map +1 -1
- package/lib-es/e2e/speculos.js +2 -5
- package/lib-es/e2e/speculos.js.map +1 -1
- package/lib-es/families/evm/config.d.ts.map +1 -1
- package/lib-es/families/evm/config.js +0 -51
- package/lib-es/families/evm/config.js.map +1 -1
- package/lib-es/families/evm/walletApiAdapter.js +1 -1
- package/lib-es/featureFlags/defaultFeatures.d.ts +0 -3
- package/lib-es/featureFlags/defaultFeatures.d.ts.map +1 -1
- package/lib-es/featureFlags/defaultFeatures.js +0 -3
- package/lib-es/featureFlags/defaultFeatures.js.map +1 -1
- package/lib-es/modularDrawer/utils/index.d.ts +1 -2
- package/lib-es/modularDrawer/utils/index.d.ts.map +1 -1
- package/lib-es/modularDrawer/utils/index.js +1 -2
- package/lib-es/modularDrawer/utils/index.js.map +1 -1
- package/lib-es/wallet-api/Exchange/server.d.ts.map +1 -1
- package/lib-es/wallet-api/Exchange/server.js +6 -6
- package/lib-es/wallet-api/Exchange/server.js.map +1 -1
- package/package.json +64 -64
- package/src/__tests__/migration/account-migration.ts +0 -3
- package/src/__tests__/test-helpers/environment.ts +0 -3
- package/src/bridge/generic-alpaca/alpaca/network/network-alpaca.ts +1 -8
- package/src/bridge/impl.ts +0 -8
- package/src/bridge/useBridgeTransaction.test.ts +1 -1
- package/src/e2e/speculos.ts +2 -5
- package/src/families/evm/config.ts +0 -51
- package/src/families/evm/walletApiAdapter.ts +1 -1
- package/src/featureFlags/defaultFeatures.ts +0 -3
- package/src/modularDrawer/utils/index.ts +1 -2
- package/src/wallet-api/Exchange/server.ts +6 -7
- package/lib/bridge/crypto-assets/index.d.ts +0 -4
- package/lib/bridge/crypto-assets/index.d.ts.map +0 -1
- package/lib/bridge/crypto-assets/index.js +0 -52
- package/lib/bridge/crypto-assets/index.js.map +0 -1
- package/lib/bridge/crypto-assets/index.test.d.ts +0 -2
- package/lib/bridge/crypto-assets/index.test.d.ts.map +0 -1
- package/lib/bridge/crypto-assets/index.test.js +0 -85
- package/lib/bridge/crypto-assets/index.test.js.map +0 -1
- package/lib/e2e/families/osmosis.d.ts +0 -3
- package/lib/e2e/families/osmosis.d.ts.map +0 -1
- package/lib/e2e/families/osmosis.js +0 -19
- package/lib/e2e/families/osmosis.js.map +0 -1
- package/lib/modularDrawer/__mocks__/currencies.mock.d.ts +0 -17
- package/lib/modularDrawer/__mocks__/currencies.mock.d.ts.map +0 -1
- package/lib/modularDrawer/__mocks__/currencies.mock.js +0 -60
- package/lib/modularDrawer/__mocks__/currencies.mock.js.map +0 -1
- package/lib/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.d.ts +0 -22
- package/lib/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.d.ts.map +0 -1
- package/lib/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.js +0 -41
- package/lib/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.js.map +0 -1
- package/lib/modularDrawer/utils/__tests__/haveOneCommonProvider.test.d.ts +0 -2
- package/lib/modularDrawer/utils/__tests__/haveOneCommonProvider.test.d.ts.map +0 -1
- package/lib/modularDrawer/utils/__tests__/haveOneCommonProvider.test.js +0 -28
- package/lib/modularDrawer/utils/__tests__/haveOneCommonProvider.test.js.map +0 -1
- package/lib/modularDrawer/utils/haveOneCommonProvider.d.ts +0 -11
- package/lib/modularDrawer/utils/haveOneCommonProvider.d.ts.map +0 -1
- package/lib/modularDrawer/utils/haveOneCommonProvider.js +0 -29
- package/lib/modularDrawer/utils/haveOneCommonProvider.js.map +0 -1
- package/lib-es/bridge/crypto-assets/index.d.ts +0 -4
- package/lib-es/bridge/crypto-assets/index.d.ts.map +0 -1
- package/lib-es/bridge/crypto-assets/index.js +0 -24
- package/lib-es/bridge/crypto-assets/index.js.map +0 -1
- package/lib-es/bridge/crypto-assets/index.test.d.ts +0 -2
- package/lib-es/bridge/crypto-assets/index.test.d.ts.map +0 -1
- package/lib-es/bridge/crypto-assets/index.test.js +0 -60
- package/lib-es/bridge/crypto-assets/index.test.js.map +0 -1
- package/lib-es/e2e/families/osmosis.d.ts +0 -3
- package/lib-es/e2e/families/osmosis.d.ts.map +0 -1
- package/lib-es/e2e/families/osmosis.js +0 -12
- package/lib-es/e2e/families/osmosis.js.map +0 -1
- package/lib-es/modularDrawer/__mocks__/currencies.mock.d.ts +0 -17
- package/lib-es/modularDrawer/__mocks__/currencies.mock.d.ts.map +0 -1
- package/lib-es/modularDrawer/__mocks__/currencies.mock.js +0 -55
- package/lib-es/modularDrawer/__mocks__/currencies.mock.js.map +0 -1
- package/lib-es/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.d.ts +0 -22
- package/lib-es/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.d.ts.map +0 -1
- package/lib-es/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.js +0 -38
- package/lib-es/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.js.map +0 -1
- package/lib-es/modularDrawer/utils/__tests__/haveOneCommonProvider.test.d.ts +0 -2
- package/lib-es/modularDrawer/utils/__tests__/haveOneCommonProvider.test.d.ts.map +0 -1
- package/lib-es/modularDrawer/utils/__tests__/haveOneCommonProvider.test.js +0 -26
- package/lib-es/modularDrawer/utils/__tests__/haveOneCommonProvider.test.js.map +0 -1
- package/lib-es/modularDrawer/utils/haveOneCommonProvider.d.ts +0 -11
- package/lib-es/modularDrawer/utils/haveOneCommonProvider.d.ts.map +0 -1
- package/lib-es/modularDrawer/utils/haveOneCommonProvider.js +0 -25
- package/lib-es/modularDrawer/utils/haveOneCommonProvider.js.map +0 -1
- package/src/bridge/crypto-assets/index.test.ts +0 -71
- package/src/bridge/crypto-assets/index.ts +0 -30
- package/src/e2e/families/osmosis.ts +0 -13
- package/src/modularDrawer/__mocks__/currencies.mock.ts +0 -62
- package/src/modularDrawer/__mocks__/useGroupedCurrenciesByProvider.mock.ts +0 -49
- package/src/modularDrawer/utils/__tests__/haveOneCommonProvider.test.ts +0 -34
- package/src/modularDrawer/utils/haveOneCommonProvider.ts +0 -31
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@ledgerhq/live-common",
|
3
3
|
"description": "Common ground for the Ledger Live apps",
|
4
|
-
"version": "34.42.0
|
4
|
+
"version": "34.42.0",
|
5
5
|
"repository": {
|
6
6
|
"type": "git",
|
7
7
|
"url": "https://github.com/LedgerHQ/ledger-live.git"
|
@@ -162,72 +162,72 @@
|
|
162
162
|
"xstate": "^5.19.2",
|
163
163
|
"yargs": "^17.0.0",
|
164
164
|
"zod": "^3.22.4",
|
165
|
-
"@ledgerhq/coin-algorand": "^0.9.14
|
166
|
-
"@ledgerhq/coin-aptos": "^2.6.0
|
167
|
-
"@ledgerhq/coin-bitcoin": "^0.
|
168
|
-
"@ledgerhq/coin-cardano": "^0.
|
169
|
-
"@ledgerhq/coin-casper": "^2.0.5
|
170
|
-
"@ledgerhq/coin-celo": "^1.1.12
|
171
|
-
"@ledgerhq/coin-cosmos": "^0.16.3
|
172
|
-
"@ledgerhq/coin-evm": "^2.24.0
|
173
|
-
"@ledgerhq/coin-filecoin": "^1.9.14
|
174
|
-
"@ledgerhq/coin-framework": "^5.7.0
|
175
|
-
"@ledgerhq/coin-hedera": "^1.
|
176
|
-
"@ledgerhq/coin-icon": "^0.11.1
|
177
|
-
"@ledgerhq/coin-internet_computer": "^1.7.14
|
178
|
-
"@ledgerhq/coin-mina": "^1.1.13
|
179
|
-
"@ledgerhq/coin-multiversx": "^0.4.14
|
180
|
-
"@ledgerhq/coin-near": "^0.11.14
|
181
|
-
"@ledgerhq/coin-polkadot": "^6.4.0
|
182
|
-
"@ledgerhq/coin-solana": "^0.28.0
|
183
|
-
"@ledgerhq/coin-stacks": "^0.8.14
|
184
|
-
"@ledgerhq/coin-stellar": "^5.
|
185
|
-
"@ledgerhq/coin-sui": "^0.7.0
|
186
|
-
"@ledgerhq/coin-tezos": "^5.
|
187
|
-
"@ledgerhq/coin-ton": "^0.13.3
|
188
|
-
"@ledgerhq/coin-tron": "^4.
|
189
|
-
"@ledgerhq/coin-vechain": "^2.7.14
|
190
|
-
"@ledgerhq/coin-xrp": "^6.
|
165
|
+
"@ledgerhq/coin-algorand": "^0.9.14",
|
166
|
+
"@ledgerhq/coin-aptos": "^2.6.0",
|
167
|
+
"@ledgerhq/coin-bitcoin": "^0.18.0",
|
168
|
+
"@ledgerhq/coin-cardano": "^0.10.0",
|
169
|
+
"@ledgerhq/coin-casper": "^2.0.5",
|
170
|
+
"@ledgerhq/coin-celo": "^1.1.12",
|
171
|
+
"@ledgerhq/coin-cosmos": "^0.16.3",
|
172
|
+
"@ledgerhq/coin-evm": "^2.24.0",
|
173
|
+
"@ledgerhq/coin-filecoin": "^1.9.14",
|
174
|
+
"@ledgerhq/coin-framework": "^5.7.0",
|
175
|
+
"@ledgerhq/coin-hedera": "^1.9.0",
|
176
|
+
"@ledgerhq/coin-icon": "^0.11.1",
|
177
|
+
"@ledgerhq/coin-internet_computer": "^1.7.14",
|
178
|
+
"@ledgerhq/coin-mina": "^1.1.13",
|
179
|
+
"@ledgerhq/coin-multiversx": "^0.4.14",
|
180
|
+
"@ledgerhq/coin-near": "^0.11.14",
|
181
|
+
"@ledgerhq/coin-polkadot": "^6.4.0",
|
182
|
+
"@ledgerhq/coin-solana": "^0.28.0",
|
183
|
+
"@ledgerhq/coin-stacks": "^0.8.14",
|
184
|
+
"@ledgerhq/coin-stellar": "^5.3.2",
|
185
|
+
"@ledgerhq/coin-sui": "^0.7.0",
|
186
|
+
"@ledgerhq/coin-tezos": "^5.6.1",
|
187
|
+
"@ledgerhq/coin-ton": "^0.13.3",
|
188
|
+
"@ledgerhq/coin-tron": "^4.4.2",
|
189
|
+
"@ledgerhq/coin-vechain": "^2.7.14",
|
190
|
+
"@ledgerhq/coin-xrp": "^6.4.1",
|
191
191
|
"@ledgerhq/crypto-icons-ui": "^1.16.0",
|
192
|
-
"@ledgerhq/cryptoassets": "^13.22.0
|
193
|
-
"@ledgerhq/device-core": "^0.5.3
|
194
|
-
"@ledgerhq/devices": "8.4.8
|
195
|
-
"@ledgerhq/errors": "^6.23.0
|
196
|
-
"@ledgerhq/hw-app-
|
197
|
-
"@ledgerhq/hw-app-
|
198
|
-
"@ledgerhq/hw-app-btc": "^10.10.0
|
199
|
-
"@ledgerhq/hw-app-celo": "^6.33.10
|
200
|
-
"@ledgerhq/hw-app-cosmos": "^6.32.4
|
201
|
-
"@ledgerhq/hw-app-eth": "^6.45.12
|
202
|
-
"@ledgerhq/hw-app-exchange": "^0.10.4
|
203
|
-
"@ledgerhq/hw-app-hedera": "^1.2.4
|
204
|
-
"@ledgerhq/hw-app-icon": "^1.3.4
|
205
|
-
"@ledgerhq/hw-app-multiversx": "^6.24.4
|
206
|
-
"@ledgerhq/hw-app-near": "^6.31.4
|
207
|
-
"@ledgerhq/hw-app-polkadot": "^6.34.4
|
208
|
-
"@ledgerhq/hw-app-str": "^7.2.4
|
192
|
+
"@ledgerhq/cryptoassets": "^13.22.0",
|
193
|
+
"@ledgerhq/device-core": "^0.5.3",
|
194
|
+
"@ledgerhq/devices": "8.4.8",
|
195
|
+
"@ledgerhq/errors": "^6.23.0",
|
196
|
+
"@ledgerhq/hw-app-algorand": "^6.31.4",
|
197
|
+
"@ledgerhq/hw-app-aptos": "^6.34.4",
|
198
|
+
"@ledgerhq/hw-app-btc": "^10.10.0",
|
199
|
+
"@ledgerhq/hw-app-celo": "^6.33.10",
|
200
|
+
"@ledgerhq/hw-app-cosmos": "^6.32.4",
|
201
|
+
"@ledgerhq/hw-app-eth": "^6.45.12",
|
202
|
+
"@ledgerhq/hw-app-exchange": "^0.10.4",
|
203
|
+
"@ledgerhq/hw-app-hedera": "^1.2.4",
|
204
|
+
"@ledgerhq/hw-app-icon": "^1.3.4",
|
205
|
+
"@ledgerhq/hw-app-multiversx": "^6.24.4",
|
206
|
+
"@ledgerhq/hw-app-near": "^6.31.4",
|
207
|
+
"@ledgerhq/hw-app-polkadot": "^6.34.4",
|
208
|
+
"@ledgerhq/hw-app-str": "^7.2.4",
|
209
209
|
"@ledgerhq/hw-app-sui": "^1.2.0",
|
210
|
-
"@ledgerhq/hw-app-tezos": "^6.31.4
|
211
|
-
"@ledgerhq/hw-app-trx": "^6.31.4
|
212
|
-
"@ledgerhq/hw-app-vet": "^0.5.10
|
213
|
-
"@ledgerhq/hw-app-xrp": "^6.32.2
|
214
|
-
"@ledgerhq/hw-transport": "^6.31.8
|
215
|
-
"@ledgerhq/hw-transport-mocker": "^6.29.8
|
216
|
-
"@ledgerhq/ledger-cal-service": "^1.2.1
|
210
|
+
"@ledgerhq/hw-app-tezos": "^6.31.4",
|
211
|
+
"@ledgerhq/hw-app-trx": "^6.31.4",
|
212
|
+
"@ledgerhq/hw-app-vet": "^0.5.10",
|
213
|
+
"@ledgerhq/hw-app-xrp": "^6.32.2",
|
214
|
+
"@ledgerhq/hw-transport": "^6.31.8",
|
215
|
+
"@ledgerhq/hw-transport-mocker": "^6.29.8",
|
216
|
+
"@ledgerhq/ledger-cal-service": "^1.2.1",
|
217
217
|
"@ledgerhq/live-config": "^3.1.0",
|
218
|
-
"@ledgerhq/live-countervalues": "^0.5.14
|
219
|
-
"@ledgerhq/live-countervalues-react": "^0.2.43
|
220
|
-
"@ledgerhq/live-dmk-shared": "^0.11.
|
221
|
-
"@ledgerhq/live-env": "^2.12.0
|
218
|
+
"@ledgerhq/live-countervalues": "^0.5.14",
|
219
|
+
"@ledgerhq/live-countervalues-react": "^0.2.43",
|
220
|
+
"@ledgerhq/live-dmk-shared": "^0.11.1",
|
221
|
+
"@ledgerhq/live-env": "^2.12.0",
|
222
222
|
"@ledgerhq/live-hooks": "0.1.0",
|
223
|
-
"@ledgerhq/live-network": "^2.0.13
|
224
|
-
"@ledgerhq/live-nft": "^0.8.14
|
223
|
+
"@ledgerhq/live-network": "^2.0.13",
|
224
|
+
"@ledgerhq/live-nft": "^0.8.14",
|
225
225
|
"@ledgerhq/live-promise": "^0.1.1",
|
226
|
-
"@ledgerhq/live-signer-evm": "^0.
|
227
|
-
"@ledgerhq/live-signer-solana": "^0.4.2
|
228
|
-
"@ledgerhq/live-wallet": "^0.11.5
|
226
|
+
"@ledgerhq/live-signer-evm": "^0.6.0",
|
227
|
+
"@ledgerhq/live-signer-solana": "^0.4.2",
|
228
|
+
"@ledgerhq/live-wallet": "^0.11.5",
|
229
229
|
"@ledgerhq/logs": "^6.13.0",
|
230
|
-
"@ledgerhq/speculos-transport": "^0.2.6
|
230
|
+
"@ledgerhq/speculos-transport": "^0.2.6",
|
231
231
|
"@ledgerhq/wallet-api-acre-module": "^0.5.0",
|
232
232
|
"@ledgerhq/wallet-api-exchange-module": "^0.14.0"
|
233
233
|
},
|
@@ -277,10 +277,10 @@
|
|
277
277
|
"undici": "6.19.2",
|
278
278
|
"uuid": "^8.3.2",
|
279
279
|
"ws": "7",
|
280
|
-
"@ledgerhq/device-react": "^0.2.38
|
281
|
-
"@ledgerhq/types-cryptoassets": "^7.
|
280
|
+
"@ledgerhq/device-react": "^0.2.38",
|
281
|
+
"@ledgerhq/types-cryptoassets": "^7.23.0",
|
282
282
|
"@ledgerhq/types-devices": "^6.25.3",
|
283
|
-
"@ledgerhq/types-live": "^6.78.0
|
283
|
+
"@ledgerhq/types-live": "^6.78.0"
|
284
284
|
},
|
285
285
|
"scripts": {
|
286
286
|
"build": "zx ./scripts/build-ts.mjs",
|
@@ -1,7 +1,6 @@
|
|
1
|
-
import {
|
1
|
+
import type {
|
2
2
|
Account,
|
3
3
|
Balance,
|
4
|
-
Block,
|
5
4
|
BlockInfo,
|
6
5
|
Operation,
|
7
6
|
FeeEstimation,
|
@@ -191,10 +190,4 @@ export const getNetworkAlpacaApi = (networkFamily: string) =>
|
|
191
190
|
listOperations: buildListOperations(networkFamily),
|
192
191
|
lastBlock: buildLastBlock(networkFamily),
|
193
192
|
craftTransaction: buildCraftTransaction(networkFamily),
|
194
|
-
getBlock(_height): Promise<Block<any>> {
|
195
|
-
throw new Error("getBlock is not supported");
|
196
|
-
},
|
197
|
-
getBlockInfo(_height: number): Promise<BlockInfo> {
|
198
|
-
throw new Error("getBlockInfo is not supported");
|
199
|
-
},
|
200
193
|
}) satisfies Api<any>;
|
package/src/bridge/impl.ts
CHANGED
@@ -20,9 +20,6 @@ import {
|
|
20
20
|
import { getAlpacaAccountBridge } from "./generic-alpaca/accountBridge";
|
21
21
|
import { getAlpacaCurrencyBridge } from "./generic-alpaca/currencyBridge";
|
22
22
|
import { AddressesSanctionedError } from "@ledgerhq/coin-framework/sanction/errors";
|
23
|
-
import { CryptoAssetsStore } from "@ledgerhq/coin-framework/crypto-assets/type";
|
24
|
-
import { setCryptoAssetsStore as setCryptoAssetsStoreForCoinFramework } from "@ledgerhq/coin-framework/crypto-assets/index";
|
25
|
-
import { getCryptoAssetsStore, setCryptoAssetsStore } from "./crypto-assets";
|
26
23
|
|
27
24
|
const alpacaized = {
|
28
25
|
xrp: true,
|
@@ -103,11 +100,6 @@ export function getAccountBridgeByFamily(family: string, accountId?: string): Ac
|
|
103
100
|
return wrapAccountBridge(jsBridge.accountBridge);
|
104
101
|
}
|
105
102
|
|
106
|
-
export function setup(store: CryptoAssetsStore) {
|
107
|
-
setCryptoAssetsStore(store);
|
108
|
-
setCryptoAssetsStoreForCoinFramework(getCryptoAssetsStore());
|
109
|
-
}
|
110
|
-
|
111
103
|
function wrapAccountBridge<T extends TransactionCommon>(
|
112
104
|
bridge: AccountBridge<T>,
|
113
105
|
): AccountBridge<T> {
|
@@ -11,7 +11,7 @@ import useBridgeTransaction, {
|
|
11
11
|
getGlobalOnBridgeError,
|
12
12
|
} from "./useBridgeTransaction";
|
13
13
|
import { setSupportedCurrencies } from "../currencies";
|
14
|
-
import { LiveConfig } from "@ledgerhq/live-config/LiveConfig";
|
14
|
+
import { LiveConfig } from "@ledgerhq/live-config/lib/LiveConfig";
|
15
15
|
|
16
16
|
const BTC = getCryptoCurrencyById("bitcoin");
|
17
17
|
|
package/src/e2e/speculos.ts
CHANGED
@@ -38,7 +38,6 @@ import { delegateMultiversX } from "./families/multiversX";
|
|
38
38
|
import { NFTTransaction, Transaction } from "./models/Transaction";
|
39
39
|
import { Delegate } from "./models/Delegate";
|
40
40
|
import { Swap } from "./models/Swap";
|
41
|
-
import { delegateOsmosis } from "./families/osmosis";
|
42
41
|
|
43
42
|
const isSpeculosRemote = process.env.REMOTE_SPECULOS === "true";
|
44
43
|
|
@@ -415,7 +414,7 @@ interface ResponseData {
|
|
415
414
|
events: Event[];
|
416
415
|
}
|
417
416
|
|
418
|
-
export async function waitFor(text: string, maxAttempts =
|
417
|
+
export async function waitFor(text: string, maxAttempts = 10): Promise<string[]> {
|
419
418
|
const port = getEnv("SPECULOS_API_PORT");
|
420
419
|
const address = process.env.SPECULOS_ADDRESS || "http://127.0.0.1";
|
421
420
|
const url = `${address}:${port}/events?stream=false¤tscreenonly=true`;
|
@@ -657,10 +656,8 @@ export async function signDelegationTransaction(delegatingAccount: Delegate) {
|
|
657
656
|
break;
|
658
657
|
case Account.ATOM_1.currency.name:
|
659
658
|
case Account.INJ_1.currency.name:
|
660
|
-
await delegateCosmos(delegatingAccount);
|
661
|
-
break;
|
662
659
|
case Account.OSMO_1.currency.name:
|
663
|
-
await
|
660
|
+
await delegateCosmos(delegatingAccount);
|
664
661
|
break;
|
665
662
|
case Account.MULTIVERS_X_1.currency.name:
|
666
663
|
await delegateMultiversX();
|
@@ -612,57 +612,6 @@ const evmConfig: CurrencyLiveConfigDefinition = {
|
|
612
612
|
showNfts: false,
|
613
613
|
},
|
614
614
|
},
|
615
|
-
config_currency_sei_network_evm: {
|
616
|
-
type: "object",
|
617
|
-
default: {
|
618
|
-
status: {
|
619
|
-
type: "active",
|
620
|
-
},
|
621
|
-
node: {
|
622
|
-
type: "external",
|
623
|
-
uri: "https://sei-evm-rpc.publicnode.com",
|
624
|
-
},
|
625
|
-
explorer: {
|
626
|
-
type: "etherscan",
|
627
|
-
uri: "https://proxyetherscan.api.live.ledger.com/v2/api/1329",
|
628
|
-
},
|
629
|
-
showNfts: false,
|
630
|
-
},
|
631
|
-
},
|
632
|
-
config_currency_berachain: {
|
633
|
-
type: "object",
|
634
|
-
default: {
|
635
|
-
status: {
|
636
|
-
type: "active",
|
637
|
-
},
|
638
|
-
node: {
|
639
|
-
type: "external",
|
640
|
-
uri: "https://rpc.berachain.com",
|
641
|
-
},
|
642
|
-
explorer: {
|
643
|
-
type: "etherscan",
|
644
|
-
uri: "https://proxyetherscan.api.live.ledger.com/v2/api/80094",
|
645
|
-
},
|
646
|
-
showNfts: false,
|
647
|
-
},
|
648
|
-
},
|
649
|
-
config_currency_hyperevm: {
|
650
|
-
type: "object",
|
651
|
-
default: {
|
652
|
-
status: {
|
653
|
-
type: "active",
|
654
|
-
},
|
655
|
-
node: {
|
656
|
-
type: "external",
|
657
|
-
uri: "https://rpc.hypurrscan.io",
|
658
|
-
},
|
659
|
-
explorer: {
|
660
|
-
type: "etherscan",
|
661
|
-
uri: "https://proxyetherscan.api.live.ledger.com/v2/api/999",
|
662
|
-
},
|
663
|
-
showNfts: false,
|
664
|
-
},
|
665
|
-
},
|
666
615
|
config_currency_polygon_zk_evm: {
|
667
616
|
type: "object",
|
668
617
|
default: {
|
@@ -48,7 +48,7 @@ const convertToLiveTransaction: ConvertToLiveTransaction<
|
|
48
48
|
|
49
49
|
/**
|
50
50
|
* We explicitly set unrelated type specific fields to undefined to avoid transaction
|
51
|
-
* type assertion errors during the `prepareTransaction` logic (libs/coin-
|
51
|
+
* type assertion errors during the `prepareTransaction` logic (libs/coin-evm/src/prepareTransaction.ts)
|
52
52
|
* when performing an `updateTransaction` with a newly created tx
|
53
53
|
* Which is what happen in this case (in apps/ledger-live-desktop/src/renderer/modals/SignTransaction/Body.tsx):
|
54
54
|
// `createTransaction` will create a type 2 tx by default with `maxFeePerGas` and `maxPriorityFeePerGas` set to 0
|
@@ -92,9 +92,6 @@ export const CURRENCY_DEFAULT_FEATURES = {
|
|
92
92
|
currencySui: DEFAULT_FEATURE,
|
93
93
|
currencyMina: DEFAULT_FEATURE,
|
94
94
|
currencyBabylon: DEFAULT_FEATURE,
|
95
|
-
currencySeiNetworkEvm: DEFAULT_FEATURE,
|
96
|
-
currencyBerachain: DEFAULT_FEATURE,
|
97
|
-
currencyHyperevm: DEFAULT_FEATURE,
|
98
95
|
};
|
99
96
|
|
100
97
|
/**
|
@@ -1,6 +1,5 @@
|
|
1
1
|
import { CryptoOrTokenCurrency } from "@ledgerhq/types-cryptoassets";
|
2
2
|
import { CurrenciesByProviderId } from "../../deposit/type";
|
3
|
-
import { haveOneCommonProvider } from "./haveOneCommonProvider";
|
4
3
|
|
5
4
|
function isCorrespondingCurrency(
|
6
5
|
elem: CryptoOrTokenCurrency,
|
@@ -27,4 +26,4 @@ const getEffectiveCurrency = (
|
|
27
26
|
return provider.currenciesByNetwork.find(elem => currencyIds.includes(elem.id)) ?? currency;
|
28
27
|
};
|
29
28
|
|
30
|
-
export { isCorrespondingCurrency, getEffectiveCurrency
|
29
|
+
export { isCorrespondingCurrency, getEffectiveCurrency };
|
@@ -51,7 +51,6 @@ import { getSwapStepFromError } from "../../exchange/error";
|
|
51
51
|
import { postSwapCancelled } from "../../exchange/swap";
|
52
52
|
import { DeviceModelId } from "@ledgerhq/types-devices";
|
53
53
|
import { setBroadcastTransaction } from "../../exchange/swap/setBroadcastTransaction";
|
54
|
-
import { FAMILIES_MAPPING_LL_TO_WAPI } from "../constants";
|
55
54
|
|
56
55
|
export { ExchangeType };
|
57
56
|
|
@@ -486,9 +485,7 @@ export const handlers = ({
|
|
486
485
|
});
|
487
486
|
|
488
487
|
const mainFromAccount = getMainAccount(fromAccount, fromParentAccount);
|
489
|
-
const mainFromAccountFamily =
|
490
|
-
FAMILIES_MAPPING_LL_TO_WAPI[mainFromAccount.currency.family] ||
|
491
|
-
mainFromAccount.currency.family;
|
488
|
+
const mainFromAccountFamily = mainFromAccount.currency.family;
|
492
489
|
|
493
490
|
if (transaction.family !== mainFromAccountFamily) {
|
494
491
|
return Promise.reject(
|
@@ -744,7 +741,9 @@ async function getStrategy(
|
|
744
741
|
customErrorType?: any,
|
745
742
|
): Promise<Transaction> {
|
746
743
|
const family =
|
747
|
-
currency.type === "TokenCurrency"
|
744
|
+
currency.type === "TokenCurrency"
|
745
|
+
? (currency.parentCurrency?.family as Transaction["family"])
|
746
|
+
: (currency.family as Transaction["family"]);
|
748
747
|
|
749
748
|
if (!family) {
|
750
749
|
throw new Error(`TokenCurrency missing parentCurrency family: ${currency.id}`);
|
@@ -756,7 +755,7 @@ async function getStrategy(
|
|
756
755
|
}
|
757
756
|
|
758
757
|
// Normalize family key for strategy lookup
|
759
|
-
const familyKey =
|
758
|
+
const familyKey = family === "evm" ? "ethereum" : family;
|
760
759
|
const strategy = transactionStrategy?.[familyKey];
|
761
760
|
|
762
761
|
if (!strategy) {
|
@@ -765,7 +764,7 @@ async function getStrategy(
|
|
765
764
|
|
766
765
|
try {
|
767
766
|
return await strategy({
|
768
|
-
family
|
767
|
+
family,
|
769
768
|
amount,
|
770
769
|
recipient,
|
771
770
|
customFeeConfig: customFeeConfig || {},
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/bridge/crypto-assets/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,iBAAiB,EAAE,MAAM,6CAA6C,CAAC;AAKhF,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,iBAAiB,QAE5D;AAUD,wBAAgB,oBAAoB,IAAI,iBAAiB,CAWxD"}
|
@@ -1,52 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
-
if (k2 === undefined) k2 = k;
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
-
}
|
8
|
-
Object.defineProperty(o, k2, desc);
|
9
|
-
}) : (function(o, m, k, k2) {
|
10
|
-
if (k2 === undefined) k2 = k;
|
11
|
-
o[k2] = m[k];
|
12
|
-
}));
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
15
|
-
}) : function(o, v) {
|
16
|
-
o["default"] = v;
|
17
|
-
});
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
19
|
-
if (mod && mod.__esModule) return mod;
|
20
|
-
var result = {};
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
22
|
-
__setModuleDefault(result, mod);
|
23
|
-
return result;
|
24
|
-
};
|
25
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
26
|
-
exports.getCryptoAssetsStore = exports.setCryptoAssetsStore = void 0;
|
27
|
-
const LiveConfig_1 = require("@ledgerhq/live-config/LiveConfig");
|
28
|
-
const legacy = __importStar(require("@ledgerhq/cryptoassets/tokens"));
|
29
|
-
let cryptoAssetsStore = undefined;
|
30
|
-
function setCryptoAssetsStore(store) {
|
31
|
-
cryptoAssetsStore = store;
|
32
|
-
}
|
33
|
-
exports.setCryptoAssetsStore = setCryptoAssetsStore;
|
34
|
-
const legacyStore = {
|
35
|
-
findTokenByAddress: legacy.findTokenByAddress,
|
36
|
-
getTokenById: legacy.getTokenById,
|
37
|
-
findTokenById: legacy.findTokenById,
|
38
|
-
findTokenByAddressInCurrency: legacy.findTokenByAddressInCurrency,
|
39
|
-
findTokenByTicker: legacy.findTokenByTicker,
|
40
|
-
};
|
41
|
-
function getCryptoAssetsStore() {
|
42
|
-
const featureEnabled = LiveConfig_1.LiveConfig.getValueByKey("feature_cal_lazy_loading");
|
43
|
-
if (!featureEnabled) {
|
44
|
-
return legacyStore;
|
45
|
-
}
|
46
|
-
if (!cryptoAssetsStore) {
|
47
|
-
throw new Error("CryptoAssetsStore is not set. Please call setCryptoAssetsStore first.");
|
48
|
-
}
|
49
|
-
return cryptoAssetsStore;
|
50
|
-
}
|
51
|
-
exports.getCryptoAssetsStore = getCryptoAssetsStore;
|
52
|
-
//# sourceMappingURL=index.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/bridge/crypto-assets/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iEAA8D;AAE9D,sEAAwD;AAExD,IAAI,iBAAiB,GAAkC,SAAS,CAAC;AAEjE,SAAgB,oBAAoB,CAAC,KAAwB;IAC3D,iBAAiB,GAAG,KAAK,CAAC;AAC5B,CAAC;AAFD,oDAEC;AAED,MAAM,WAAW,GAAsB;IACrC,kBAAkB,EAAE,MAAM,CAAC,kBAAkB;IAC7C,YAAY,EAAE,MAAM,CAAC,YAAY;IACjC,aAAa,EAAE,MAAM,CAAC,aAAa;IACnC,4BAA4B,EAAE,MAAM,CAAC,4BAA4B;IACjE,iBAAiB,EAAE,MAAM,CAAC,iBAAiB;CAC5C,CAAC;AAEF,SAAgB,oBAAoB;IAClC,MAAM,cAAc,GAAG,uBAAU,CAAC,aAAa,CAAC,0BAA0B,CAAC,CAAC;IAC5E,IAAI,CAAC,cAAc,EAAE;QACnB,OAAO,WAAW,CAAC;KACpB;IAED,IAAI,CAAC,iBAAiB,EAAE;QACtB,MAAM,IAAI,KAAK,CAAC,uEAAuE,CAAC,CAAC;KAC1F;IAED,OAAO,iBAAiB,CAAC;AAC3B,CAAC;AAXD,oDAWC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.test.d.ts","sourceRoot":"","sources":["../../../src/bridge/crypto-assets/index.test.ts"],"names":[],"mappings":""}
|
@@ -1,85 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
3
|
-
if (k2 === undefined) k2 = k;
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
7
|
-
}
|
8
|
-
Object.defineProperty(o, k2, desc);
|
9
|
-
}) : (function(o, m, k, k2) {
|
10
|
-
if (k2 === undefined) k2 = k;
|
11
|
-
o[k2] = m[k];
|
12
|
-
}));
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
15
|
-
}) : function(o, v) {
|
16
|
-
o["default"] = v;
|
17
|
-
});
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
19
|
-
if (mod && mod.__esModule) return mod;
|
20
|
-
var result = {};
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
22
|
-
__setModuleDefault(result, mod);
|
23
|
-
return result;
|
24
|
-
};
|
25
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
26
|
-
const LiveConfig_1 = require("@ledgerhq/live-config/LiveConfig");
|
27
|
-
const _1 = require(".");
|
28
|
-
const legacy = __importStar(require("@ledgerhq/cryptoassets/tokens"));
|
29
|
-
describe("Testing CryptoAssetStore", () => {
|
30
|
-
it("should return the default methods from cryptoassets libs when feature flag does not exists", () => {
|
31
|
-
LiveConfig_1.LiveConfig.setConfig({
|
32
|
-
some_other_feature: {
|
33
|
-
type: "boolean",
|
34
|
-
default: true,
|
35
|
-
},
|
36
|
-
});
|
37
|
-
const store = (0, _1.getCryptoAssetsStore)();
|
38
|
-
expect(store).toEqual({
|
39
|
-
findTokenByAddress: legacy.findTokenByAddress,
|
40
|
-
getTokenById: legacy.getTokenById,
|
41
|
-
findTokenById: legacy.findTokenById,
|
42
|
-
findTokenByAddressInCurrency: legacy.findTokenByAddressInCurrency,
|
43
|
-
findTokenByTicker: legacy.findTokenByTicker,
|
44
|
-
});
|
45
|
-
});
|
46
|
-
it("should return the default methods from cryptoassets libs when feature flag is disabled", () => {
|
47
|
-
LiveConfig_1.LiveConfig.setConfig({
|
48
|
-
feature_cal_lazy_loading: {
|
49
|
-
type: "boolean",
|
50
|
-
default: false,
|
51
|
-
},
|
52
|
-
});
|
53
|
-
const store = (0, _1.getCryptoAssetsStore)();
|
54
|
-
expect(store).toEqual({
|
55
|
-
findTokenByAddress: legacy.findTokenByAddress,
|
56
|
-
getTokenById: legacy.getTokenById,
|
57
|
-
findTokenById: legacy.findTokenById,
|
58
|
-
findTokenByAddressInCurrency: legacy.findTokenByAddressInCurrency,
|
59
|
-
findTokenByTicker: legacy.findTokenByTicker,
|
60
|
-
});
|
61
|
-
});
|
62
|
-
it("should throw an error when no store is set and feature flag is enabled", () => {
|
63
|
-
LiveConfig_1.LiveConfig.setConfig({
|
64
|
-
feature_cal_lazy_loading: {
|
65
|
-
type: "boolean",
|
66
|
-
default: true,
|
67
|
-
},
|
68
|
-
});
|
69
|
-
expect(() => (0, _1.getCryptoAssetsStore)()).toThrow("CryptoAssetsStore is not set. Please call setCryptoAssetsStore first.");
|
70
|
-
});
|
71
|
-
it("should throw return the new store when feature flag is enabled", () => {
|
72
|
-
LiveConfig_1.LiveConfig.setConfig({
|
73
|
-
feature_cal_lazy_loading: {
|
74
|
-
type: "boolean",
|
75
|
-
default: true,
|
76
|
-
},
|
77
|
-
});
|
78
|
-
// eslint-disable-next-line @typescript-eslint/consistent-type-assertions
|
79
|
-
const newStore = {};
|
80
|
-
(0, _1.setCryptoAssetsStore)(newStore);
|
81
|
-
const store = (0, _1.getCryptoAssetsStore)();
|
82
|
-
expect(store).toBe(newStore);
|
83
|
-
});
|
84
|
-
});
|
85
|
-
//# sourceMappingURL=index.test.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"index.test.js","sourceRoot":"","sources":["../../../src/bridge/crypto-assets/index.test.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAAA,iEAA8D;AAC9D,wBAA+D;AAC/D,sEAAwD;AAGxD,QAAQ,CAAC,0BAA0B,EAAE,GAAG,EAAE;IACxC,EAAE,CAAC,4FAA4F,EAAE,GAAG,EAAE;QACpG,uBAAU,CAAC,SAAS,CAAC;YACnB,kBAAkB,EAAE;gBAClB,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE,IAAI;aACd;SACF,CAAC,CAAC;QAEH,MAAM,KAAK,GAAG,IAAA,uBAAoB,GAAE,CAAC;QACrC,MAAM,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC;YACpB,kBAAkB,EAAE,MAAM,CAAC,kBAAkB;YAC7C,YAAY,EAAE,MAAM,CAAC,YAAY;YACjC,aAAa,EAAE,MAAM,CAAC,aAAa;YACnC,4BAA4B,EAAE,MAAM,CAAC,4BAA4B;YACjE,iBAAiB,EAAE,MAAM,CAAC,iBAAiB;SAC5C,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,wFAAwF,EAAE,GAAG,EAAE;QAChG,uBAAU,CAAC,SAAS,CAAC;YACnB,wBAAwB,EAAE;gBACxB,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE,KAAK;aACf;SACF,CAAC,CAAC;QAEH,MAAM,KAAK,GAAG,IAAA,uBAAoB,GAAE,CAAC;QACrC,MAAM,CAAC,KAAK,CAAC,CAAC,OAAO,CAAC;YACpB,kBAAkB,EAAE,MAAM,CAAC,kBAAkB;YAC7C,YAAY,EAAE,MAAM,CAAC,YAAY;YACjC,aAAa,EAAE,MAAM,CAAC,aAAa;YACnC,4BAA4B,EAAE,MAAM,CAAC,4BAA4B;YACjE,iBAAiB,EAAE,MAAM,CAAC,iBAAiB;SAC5C,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,wEAAwE,EAAE,GAAG,EAAE;QAChF,uBAAU,CAAC,SAAS,CAAC;YACnB,wBAAwB,EAAE;gBACxB,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE,IAAI;aACd;SACF,CAAC,CAAC;QAEH,MAAM,CAAC,GAAG,EAAE,CAAC,IAAA,uBAAoB,GAAE,CAAC,CAAC,OAAO,CAC1C,uEAAuE,CACxE,CAAC;IACJ,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,gEAAgE,EAAE,GAAG,EAAE;QACxE,uBAAU,CAAC,SAAS,CAAC;YACnB,wBAAwB,EAAE;gBACxB,IAAI,EAAE,SAAS;gBACf,OAAO,EAAE,IAAI;aACd;SACF,CAAC,CAAC;QAEH,yEAAyE;QACzE,MAAM,QAAQ,GAAG,EAAkC,CAAC;QACpD,IAAA,uBAAoB,EAAC,QAAQ,CAAC,CAAC;QAE/B,MAAM,KAAK,GAAG,IAAA,uBAAoB,GAAE,CAAC;QACrC,MAAM,CAAC,KAAK,CAAC,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IAC/B,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"osmosis.d.ts","sourceRoot":"","sources":["../../../src/e2e/families/osmosis.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAK9C,wBAAsB,eAAe,CAAC,iBAAiB,EAAE,QAAQ,iBAOhE"}
|
@@ -1,19 +0,0 @@
|
|
1
|
-
"use strict";
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
4
|
-
};
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
6
|
-
exports.delegateOsmosis = void 0;
|
7
|
-
const speculos_1 = require("../speculos");
|
8
|
-
const DeviceLabels_1 = require("../enum/DeviceLabels");
|
9
|
-
const expect_1 = __importDefault(require("expect"));
|
10
|
-
async function delegateOsmosis(delegatingAccount) {
|
11
|
-
await (0, speculos_1.waitFor)(DeviceLabels_1.DeviceLabels.PLEASE_REVIEW);
|
12
|
-
const events = await (0, speculos_1.pressUntilTextFound)(DeviceLabels_1.DeviceLabels.CAPS_APPROVE);
|
13
|
-
const amountInUosmo = (Number(delegatingAccount.amount) * 1_000_000).toString();
|
14
|
-
const isAmountCorrect = (0, speculos_1.containsSubstringInEvent)(amountInUosmo, events);
|
15
|
-
(0, expect_1.default)(isAmountCorrect).toBeTruthy();
|
16
|
-
await (0, speculos_1.pressBoth)();
|
17
|
-
}
|
18
|
-
exports.delegateOsmosis = delegateOsmosis;
|
19
|
-
//# sourceMappingURL=osmosis.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"osmosis.js","sourceRoot":"","sources":["../../../src/e2e/families/osmosis.ts"],"names":[],"mappings":";;;;;;AACA,0CAAgG;AAChG,uDAAoD;AACpD,oDAA4B;AAErB,KAAK,UAAU,eAAe,CAAC,iBAA2B;IAC/D,MAAM,IAAA,kBAAO,EAAC,2BAAY,CAAC,aAAa,CAAC,CAAC;IAC1C,MAAM,MAAM,GAAG,MAAM,IAAA,8BAAmB,EAAC,2BAAY,CAAC,YAAY,CAAC,CAAC;IACpE,MAAM,aAAa,GAAG,CAAC,MAAM,CAAC,iBAAiB,CAAC,MAAM,CAAC,GAAG,SAAS,CAAC,CAAC,QAAQ,EAAE,CAAC;IAChF,MAAM,eAAe,GAAG,IAAA,mCAAwB,EAAC,aAAa,EAAE,MAAM,CAAC,CAAC;IACxE,IAAA,gBAAM,EAAC,eAAe,CAAC,CAAC,UAAU,EAAE,CAAC;IACrC,MAAM,IAAA,oBAAS,GAAE,CAAC;AACpB,CAAC;AAPD,0CAOC"}
|
@@ -1,17 +0,0 @@
|
|
1
|
-
import { TokenCurrency } from "@ledgerhq/types-cryptoassets";
|
2
|
-
export declare const mockBtcCryptoCurrency: import("@ledgerhq/types-cryptoassets").CryptoCurrency;
|
3
|
-
export declare const mockEthCryptoCurrency: import("@ledgerhq/types-cryptoassets").CryptoCurrency;
|
4
|
-
export declare const mockArbitrumCryptoCurrency: import("@ledgerhq/types-cryptoassets").CryptoCurrency;
|
5
|
-
export declare const mockBaseCryptoCurrency: import("@ledgerhq/types-cryptoassets").CryptoCurrency;
|
6
|
-
export declare const mockScrollCryptoCurrency: import("@ledgerhq/types-cryptoassets").CryptoCurrency;
|
7
|
-
export declare const mockInjectiveCryptoCurrency: import("@ledgerhq/types-cryptoassets").CryptoCurrency;
|
8
|
-
export declare const arbitrumToken: TokenCurrency;
|
9
|
-
export declare const usdcToken: TokenCurrency;
|
10
|
-
export declare const findCryptoCurrencyById: (id: string) => import("@ledgerhq/types-cryptoassets").CryptoCurrency | undefined;
|
11
|
-
export declare const getTokenOrCryptoCurrencyById: (id: string) => import("@ledgerhq/types-cryptoassets").CryptoCurrency | TokenCurrency | undefined;
|
12
|
-
export declare const mockCurrenciesByProvider: {
|
13
|
-
providerId: string;
|
14
|
-
currenciesByNetwork: import("@ledgerhq/types-cryptoassets").CryptoCurrency[];
|
15
|
-
}[];
|
16
|
-
export declare const mockCurrencyIds: string[];
|
17
|
-
//# sourceMappingURL=currencies.mock.d.ts.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"currencies.mock.d.ts","sourceRoot":"","sources":["../../../src/modularDrawer/__mocks__/currencies.mock.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,8BAA8B,CAAC;AAE7D,eAAO,MAAM,qBAAqB,uDAAmC,CAAC;AACtE,eAAO,MAAM,qBAAqB,uDAAoC,CAAC;AACvE,eAAO,MAAM,0BAA0B,uDAAoC,CAAC;AAC5E,eAAO,MAAM,sBAAsB,uDAAgC,CAAC;AACpE,eAAO,MAAM,wBAAwB,uDAAkC,CAAC;AACxE,eAAO,MAAM,2BAA2B,uDAAqC,CAAC;AAE9E,eAAO,MAAM,aAAa,EAAE,aAe3B,CAAC;AACF,eAAO,MAAM,SAAS,EAAE,aAevB,CAAC;AAEF,eAAO,MAAM,sBAAsB,OAAQ,MAAM,sEACkD,CAAC;AACpG,eAAO,MAAM,4BAA4B,OAAQ,MAAM,sFAO7B,CAAC;AAE3B,eAAO,MAAM,wBAAwB;;;GAKpC,CAAC;AAEF,eAAO,MAAM,eAAe,UAA8C,CAAC"}
|