@ledgerhq/coin-evm 2.28.0-nightly.3 → 2.28.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/.eslintrc.js +0 -1
- package/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +20 -32
- package/{lib-es/__fixtures__/ethereum-erc20-weth.json → lib/__fixtures__/ethereum-erc20-usd_tether__erc20_.json} +8 -8
- package/lib/__fixtures__/{optimism-erc20-usd_coin.json → scroll_sepolia-erc20-new_token_mock.json} +20 -21
- package/lib/__tests__/fixtures/accounts.fixtures.d.ts +1 -1
- package/lib/__tests__/fixtures/accounts.fixtures.d.ts.map +1 -1
- package/lib/__tests__/fixtures/accounts.fixtures.js +19 -2
- package/lib/__tests__/fixtures/accounts.fixtures.js.map +1 -1
- package/lib/__tests__/fixtures/common.fixtures.d.ts +0 -1
- package/lib/__tests__/fixtures/common.fixtures.d.ts.map +1 -1
- package/lib/__tests__/fixtures/common.fixtures.js +0 -1
- package/lib/__tests__/fixtures/common.fixtures.js.map +1 -1
- package/lib/__tests__/fixtures/prepareTransaction.fixtures.d.ts.map +1 -1
- package/lib/__tests__/fixtures/prepareTransaction.fixtures.js +2 -3
- package/lib/__tests__/fixtures/prepareTransaction.fixtures.js.map +1 -1
- package/lib/__tests__/fixtures/synchronization.fixtures.d.ts +1 -1
- package/lib/__tests__/fixtures/synchronization.fixtures.d.ts.map +1 -1
- package/lib/__tests__/fixtures/synchronization.fixtures.js +18 -3
- package/lib/__tests__/fixtures/synchronization.fixtures.js.map +1 -1
- package/lib/__tests__/fixtures/transaction.fixtures.d.ts +2 -2
- package/lib/__tests__/fixtures/transaction.fixtures.d.ts.map +1 -1
- package/lib/__tests__/fixtures/transaction.fixtures.js +2 -3
- package/lib/__tests__/fixtures/transaction.fixtures.js.map +1 -1
- package/lib/__tests__/unit/accounts.unit.test.js +27 -0
- package/lib/__tests__/unit/accounts.unit.test.js.map +1 -1
- package/lib/__tests__/unit/adapters/etherscan.unit.test.js +7 -72
- package/lib/__tests__/unit/adapters/etherscan.unit.test.js.map +1 -1
- package/lib/__tests__/unit/adapters/ledger.unit.test.js +2 -15
- package/lib/__tests__/unit/adapters/ledger.unit.test.js.map +1 -1
- package/lib/__tests__/unit/api/explorer/etherscan.unit.test.js +0 -8
- package/lib/__tests__/unit/api/explorer/etherscan.unit.test.js.map +1 -1
- package/lib/__tests__/unit/api/explorer/ledger.unit.test.js +0 -12
- package/lib/__tests__/unit/api/explorer/ledger.unit.test.js.map +1 -1
- package/lib/__tests__/unit/broadcast.unit.test.js +1 -3
- package/lib/__tests__/unit/broadcast.unit.test.js.map +1 -1
- package/lib/__tests__/unit/buildOptimisticOperation.unit.test.js +1 -3
- package/lib/__tests__/unit/buildOptimisticOperation.unit.test.js.map +1 -1
- package/lib/__tests__/unit/deviceTransactionConfig.unit.test.d.ts +1 -1
- package/lib/__tests__/unit/deviceTransactionConfig.unit.test.d.ts.map +1 -1
- package/lib/__tests__/unit/deviceTransactionConfig.unit.test.js +0 -1
- package/lib/__tests__/unit/deviceTransactionConfig.unit.test.js.map +1 -1
- package/lib/__tests__/unit/estimateMaxSpendable.unit.test.js +1 -3
- package/lib/__tests__/unit/estimateMaxSpendable.unit.test.js.map +1 -1
- package/lib/__tests__/unit/getTransactionStatus.unit.test.js +1 -3
- package/lib/__tests__/unit/getTransactionStatus.unit.test.js.map +1 -1
- package/lib/__tests__/unit/logic.unit.test.js +18 -22
- package/lib/__tests__/unit/logic.unit.test.js.map +1 -1
- package/lib/__tests__/unit/operation.test.js +2 -6
- package/lib/__tests__/unit/operation.test.js.map +1 -1
- package/lib/__tests__/unit/prepareTransaction.unit.test.js +17 -4
- package/lib/__tests__/unit/prepareTransaction.unit.test.js.map +1 -1
- package/lib/adapters/etherscan.d.ts.map +1 -1
- package/lib/adapters/etherscan.js +2 -2
- package/lib/adapters/etherscan.js.map +1 -1
- package/lib/adapters/ledger.d.ts.map +1 -1
- package/lib/adapters/ledger.js +2 -2
- package/lib/adapters/ledger.js.map +1 -1
- package/lib/api/index.d.ts.map +1 -1
- package/lib/api/index.js +4 -2
- package/lib/api/index.js.map +1 -1
- package/lib/bridge/js.d.ts +1 -2
- package/lib/bridge/js.d.ts.map +1 -1
- package/lib/bridge/js.js +1 -3
- package/lib/bridge/js.js.map +1 -1
- package/lib/bridge/preload.d.ts +0 -1
- package/lib/bridge/preload.d.ts.map +1 -1
- package/lib/bridge/preload.js +1 -10
- package/lib/bridge/preload.js.map +1 -1
- package/lib/deviceTransactionConfig.d.ts.map +1 -1
- package/lib/deviceTransactionConfig.js +2 -2
- package/lib/deviceTransactionConfig.js.map +1 -1
- package/lib/logic/common.d.ts +0 -18
- package/lib/logic/common.d.ts.map +1 -1
- package/lib/logic/common.js +1 -35
- package/lib/logic/common.js.map +1 -1
- package/lib/logic/estimateFees.d.ts +1 -1
- package/lib/logic/estimateFees.d.ts.map +1 -1
- package/lib/logic/estimateFees.js +12 -25
- package/lib/logic/estimateFees.js.map +1 -1
- package/lib/logic/estimateFees.test.js +41 -93
- package/lib/logic/estimateFees.test.js.map +1 -1
- package/lib/logic/index.d.ts +0 -1
- package/lib/logic/index.d.ts.map +1 -1
- package/lib/logic/index.js +0 -1
- package/lib/logic/index.js.map +1 -1
- package/lib/types/transaction.d.ts +0 -9
- package/lib/types/transaction.d.ts.map +1 -1
- package/{lib/__fixtures__/ethereum-erc20-weth.json → lib-es/__fixtures__/ethereum-erc20-usd_tether__erc20_.json} +8 -8
- package/lib-es/__fixtures__/{optimism-erc20-usd_coin.json → scroll_sepolia-erc20-new_token_mock.json} +20 -21
- package/lib-es/__tests__/fixtures/accounts.fixtures.d.ts +1 -1
- package/lib-es/__tests__/fixtures/accounts.fixtures.d.ts.map +1 -1
- package/lib-es/__tests__/fixtures/accounts.fixtures.js +18 -1
- package/lib-es/__tests__/fixtures/accounts.fixtures.js.map +1 -1
- package/lib-es/__tests__/fixtures/common.fixtures.d.ts +0 -1
- package/lib-es/__tests__/fixtures/common.fixtures.d.ts.map +1 -1
- package/lib-es/__tests__/fixtures/common.fixtures.js +0 -1
- package/lib-es/__tests__/fixtures/common.fixtures.js.map +1 -1
- package/lib-es/__tests__/fixtures/prepareTransaction.fixtures.d.ts.map +1 -1
- package/lib-es/__tests__/fixtures/prepareTransaction.fixtures.js +2 -3
- package/lib-es/__tests__/fixtures/prepareTransaction.fixtures.js.map +1 -1
- package/lib-es/__tests__/fixtures/synchronization.fixtures.d.ts +1 -1
- package/lib-es/__tests__/fixtures/synchronization.fixtures.d.ts.map +1 -1
- package/lib-es/__tests__/fixtures/synchronization.fixtures.js +18 -3
- package/lib-es/__tests__/fixtures/synchronization.fixtures.js.map +1 -1
- package/lib-es/__tests__/fixtures/transaction.fixtures.d.ts +2 -2
- package/lib-es/__tests__/fixtures/transaction.fixtures.d.ts.map +1 -1
- package/lib-es/__tests__/fixtures/transaction.fixtures.js +2 -3
- package/lib-es/__tests__/fixtures/transaction.fixtures.js.map +1 -1
- package/lib-es/__tests__/unit/accounts.unit.test.js +27 -0
- package/lib-es/__tests__/unit/accounts.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/adapters/etherscan.unit.test.js +7 -72
- package/lib-es/__tests__/unit/adapters/etherscan.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/adapters/ledger.unit.test.js +2 -15
- package/lib-es/__tests__/unit/adapters/ledger.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/api/explorer/etherscan.unit.test.js +0 -8
- package/lib-es/__tests__/unit/api/explorer/etherscan.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/api/explorer/ledger.unit.test.js +0 -12
- package/lib-es/__tests__/unit/api/explorer/ledger.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/broadcast.unit.test.js +2 -4
- package/lib-es/__tests__/unit/broadcast.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/buildOptimisticOperation.unit.test.js +2 -4
- package/lib-es/__tests__/unit/buildOptimisticOperation.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.d.ts +1 -1
- package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.d.ts.map +1 -1
- package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.js +0 -1
- package/lib-es/__tests__/unit/deviceTransactionConfig.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/estimateMaxSpendable.unit.test.js +2 -4
- package/lib-es/__tests__/unit/estimateMaxSpendable.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/getTransactionStatus.unit.test.js +2 -4
- package/lib-es/__tests__/unit/getTransactionStatus.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/logic.unit.test.js +19 -23
- package/lib-es/__tests__/unit/logic.unit.test.js.map +1 -1
- package/lib-es/__tests__/unit/operation.test.js +3 -7
- package/lib-es/__tests__/unit/operation.test.js.map +1 -1
- package/lib-es/__tests__/unit/prepareTransaction.unit.test.js +17 -4
- package/lib-es/__tests__/unit/prepareTransaction.unit.test.js.map +1 -1
- package/lib-es/adapters/etherscan.d.ts.map +1 -1
- package/lib-es/adapters/etherscan.js +2 -2
- package/lib-es/adapters/etherscan.js.map +1 -1
- package/lib-es/adapters/ledger.d.ts.map +1 -1
- package/lib-es/adapters/ledger.js +2 -2
- package/lib-es/adapters/ledger.js.map +1 -1
- package/lib-es/api/index.d.ts.map +1 -1
- package/lib-es/api/index.js +5 -3
- package/lib-es/api/index.js.map +1 -1
- package/lib-es/bridge/js.d.ts +1 -2
- package/lib-es/bridge/js.d.ts.map +1 -1
- package/lib-es/bridge/js.js +1 -3
- package/lib-es/bridge/js.js.map +1 -1
- package/lib-es/bridge/preload.d.ts +0 -1
- package/lib-es/bridge/preload.d.ts.map +1 -1
- package/lib-es/bridge/preload.js +0 -8
- package/lib-es/bridge/preload.js.map +1 -1
- package/lib-es/deviceTransactionConfig.d.ts.map +1 -1
- package/lib-es/deviceTransactionConfig.js +2 -2
- package/lib-es/deviceTransactionConfig.js.map +1 -1
- package/lib-es/logic/common.d.ts +0 -18
- package/lib-es/logic/common.d.ts.map +1 -1
- package/lib-es/logic/common.js +0 -30
- package/lib-es/logic/common.js.map +1 -1
- package/lib-es/logic/estimateFees.d.ts +1 -1
- package/lib-es/logic/estimateFees.d.ts.map +1 -1
- package/lib-es/logic/estimateFees.js +12 -25
- package/lib-es/logic/estimateFees.js.map +1 -1
- package/lib-es/logic/estimateFees.test.js +41 -93
- package/lib-es/logic/estimateFees.test.js.map +1 -1
- package/lib-es/logic/index.d.ts +0 -1
- package/lib-es/logic/index.d.ts.map +1 -1
- package/lib-es/logic/index.js +0 -1
- package/lib-es/logic/index.js.map +1 -1
- package/lib-es/types/transaction.d.ts +0 -9
- package/lib-es/types/transaction.d.ts.map +1 -1
- package/package.json +13 -13
- package/src/__tests__/fixtures/accounts.fixtures.ts +23 -1
- package/src/__tests__/fixtures/common.fixtures.ts +0 -1
- package/src/__tests__/fixtures/prepareTransaction.fixtures.ts +4 -4
- package/src/__tests__/fixtures/synchronization.fixtures.ts +20 -3
- package/src/__tests__/fixtures/transaction.fixtures.ts +3 -4
- package/src/__tests__/unit/accounts.unit.test.ts +36 -0
- package/src/__tests__/unit/adapters/etherscan.unit.test.ts +7 -87
- package/src/__tests__/unit/adapters/ledger.unit.test.ts +2 -20
- package/src/__tests__/unit/api/explorer/etherscan.unit.test.ts +0 -12
- package/src/__tests__/unit/api/explorer/ledger.unit.test.ts +0 -16
- package/src/__tests__/unit/broadcast.unit.test.ts +3 -5
- package/src/__tests__/unit/buildOptimisticOperation.unit.test.ts +2 -5
- package/src/__tests__/unit/deviceTransactionConfig.unit.test.ts +0 -1
- package/src/__tests__/unit/estimateMaxSpendable.unit.test.ts +3 -5
- package/src/__tests__/unit/getTransactionStatus.unit.test.ts +2 -5
- package/src/__tests__/unit/logic.unit.test.ts +29 -41
- package/src/__tests__/unit/operation.test.ts +5 -9
- package/src/__tests__/unit/prepareTransaction.unit.test.ts +18 -4
- package/src/adapters/etherscan.ts +2 -5
- package/src/adapters/ledger.ts +2 -5
- package/src/api/index.ts +5 -4
- package/src/bridge/js.ts +0 -4
- package/src/bridge/preload.ts +0 -8
- package/src/deviceTransactionConfig.ts +2 -3
- package/src/logic/common.ts +0 -52
- package/src/logic/estimateFees.test.ts +57 -98
- package/src/logic/estimateFees.ts +18 -28
- package/src/logic/index.ts +0 -1
- package/src/types/transaction.ts +0 -12
- package/lib/__fixtures__/cardano-native-8654e8b350e298c80d2451beb5ed80fc9eee9f38ce6b039fb8706bc34c4f4253544552.json +0 -52
- package/lib/__fixtures__/ethereum-erc20-usd__coin-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-IN-i0.json +0 -20
- package/lib/__fixtures__/ethereum-erc20-usd__coin-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-OUT-i0.json +0 -19
- package/lib/__tests__/fixtures/cryptoAssetsStore.fixtures.d.ts +0 -2
- package/lib/__tests__/fixtures/cryptoAssetsStore.fixtures.d.ts.map +0 -1
- package/lib/__tests__/fixtures/cryptoAssetsStore.fixtures.js +0 -44
- package/lib/__tests__/fixtures/cryptoAssetsStore.fixtures.js.map +0 -1
- package/lib/cryptoAssetsStore.d.ts +0 -5
- package/lib/cryptoAssetsStore.d.ts.map +0 -1
- package/lib/cryptoAssetsStore.js +0 -17
- package/lib/cryptoAssetsStore.js.map +0 -1
- package/lib/cryptoAssetsStore.test.d.ts +0 -2
- package/lib/cryptoAssetsStore.test.d.ts.map +0 -1
- package/lib/cryptoAssetsStore.test.js +0 -15
- package/lib/cryptoAssetsStore.test.js.map +0 -1
- package/lib/logic/validateIntent.d.ts +0 -4
- package/lib/logic/validateIntent.d.ts.map +0 -1
- package/lib/logic/validateIntent.js +0 -192
- package/lib/logic/validateIntent.js.map +0 -1
- package/lib/logic/validateIntent.test.d.ts +0 -2
- package/lib/logic/validateIntent.test.d.ts.map +0 -1
- package/lib/logic/validateIntent.test.js +0 -485
- package/lib/logic/validateIntent.test.js.map +0 -1
- package/lib-es/__fixtures__/cardano-native-8654e8b350e298c80d2451beb5ed80fc9eee9f38ce6b039fb8706bc34c4f4253544552.json +0 -52
- package/lib-es/__fixtures__/ethereum-erc20-usd__coin-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-IN-i0.json +0 -20
- package/lib-es/__fixtures__/ethereum-erc20-usd__coin-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-OUT-i0.json +0 -19
- package/lib-es/__tests__/fixtures/cryptoAssetsStore.fixtures.d.ts +0 -2
- package/lib-es/__tests__/fixtures/cryptoAssetsStore.fixtures.d.ts.map +0 -1
- package/lib-es/__tests__/fixtures/cryptoAssetsStore.fixtures.js +0 -19
- package/lib-es/__tests__/fixtures/cryptoAssetsStore.fixtures.js.map +0 -1
- package/lib-es/cryptoAssetsStore.d.ts +0 -5
- package/lib-es/cryptoAssetsStore.d.ts.map +0 -1
- package/lib-es/cryptoAssetsStore.js +0 -12
- package/lib-es/cryptoAssetsStore.js.map +0 -1
- package/lib-es/cryptoAssetsStore.test.d.ts +0 -2
- package/lib-es/cryptoAssetsStore.test.d.ts.map +0 -1
- package/lib-es/cryptoAssetsStore.test.js +0 -13
- package/lib-es/cryptoAssetsStore.test.js.map +0 -1
- package/lib-es/logic/validateIntent.d.ts +0 -4
- package/lib-es/logic/validateIntent.d.ts.map +0 -1
- package/lib-es/logic/validateIntent.js +0 -185
- package/lib-es/logic/validateIntent.js.map +0 -1
- package/lib-es/logic/validateIntent.test.d.ts +0 -2
- package/lib-es/logic/validateIntent.test.d.ts.map +0 -1
- package/lib-es/logic/validateIntent.test.js +0 -480
- package/lib-es/logic/validateIntent.test.js.map +0 -1
- package/src/__fixtures__/cardano-native-8654e8b350e298c80d2451beb5ed80fc9eee9f38ce6b039fb8706bc34c4f4253544552.json +0 -52
- package/src/__fixtures__/ethereum-erc20-usd__coin-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-IN-i0.json +0 -20
- package/src/__fixtures__/ethereum-erc20-usd__coin-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-OUT-i0.json +0 -19
- package/src/__fixtures__/ethereum-erc20-usd__coin-0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48.json +0 -73
- package/src/__fixtures__/ethereum-erc20-weth.json +0 -73
- package/src/__fixtures__/optimism-erc20-usd_coin.json +0 -69
- package/src/__tests__/fixtures/cryptoAssetsStore.fixtures.ts +0 -24
- package/src/cryptoAssetsStore.test.ts +0 -19
- package/src/cryptoAssetsStore.ts +0 -16
- package/src/logic/validateIntent.test.ts +0 -659
- package/src/logic/validateIntent.ts +0 -274
|
@@ -1,480 +0,0 @@
|
|
|
1
|
-
import { AmountRequired, ETHAddressNonEIP, FeeNotLoaded, GasLessThanEstimate, InvalidAddress, MaxFeeTooLow, NotEnoughBalance, NotEnoughGas, PriorityFeeHigherThanMaxFee, PriorityFeeTooHigh, PriorityFeeTooLow, RecipientRequired, } from "@ledgerhq/errors";
|
|
2
|
-
import BigNumber from "bignumber.js";
|
|
3
|
-
import { setCoinConfig } from "../config";
|
|
4
|
-
import ledgerNode from "../network/node/ledger";
|
|
5
|
-
import ledgerExplorer from "../network/explorer/ledger";
|
|
6
|
-
import ledgerGasTracker from "../network/gasTracker/ledger";
|
|
7
|
-
import { validateIntent } from "./validateIntent";
|
|
8
|
-
function legacyIntent(intent) {
|
|
9
|
-
return {
|
|
10
|
-
type: "send-legacy",
|
|
11
|
-
sender: "",
|
|
12
|
-
recipient: "",
|
|
13
|
-
amount: 0n,
|
|
14
|
-
asset: { type: "native" },
|
|
15
|
-
...intent,
|
|
16
|
-
};
|
|
17
|
-
}
|
|
18
|
-
function eip1559Intent(intent) {
|
|
19
|
-
return {
|
|
20
|
-
type: "send-eip1559",
|
|
21
|
-
sender: "",
|
|
22
|
-
recipient: "",
|
|
23
|
-
amount: 0n,
|
|
24
|
-
asset: { type: "native" },
|
|
25
|
-
...intent,
|
|
26
|
-
};
|
|
27
|
-
}
|
|
28
|
-
describe("validateIntent", () => {
|
|
29
|
-
beforeEach(() => {
|
|
30
|
-
setCoinConfig(() => ({
|
|
31
|
-
info: {
|
|
32
|
-
node: { type: "ledger" },
|
|
33
|
-
explorer: { type: "ledger" },
|
|
34
|
-
gasTracker: { type: "ledger", explorerId: "eth" },
|
|
35
|
-
},
|
|
36
|
-
}));
|
|
37
|
-
jest.spyOn(ledgerNode, "getGasEstimation").mockResolvedValue(new BigNumber(0));
|
|
38
|
-
jest.spyOn(ledgerNode, "getFeeData").mockResolvedValue({
|
|
39
|
-
maxFeePerGas: null,
|
|
40
|
-
maxPriorityFeePerGas: null,
|
|
41
|
-
gasPrice: null,
|
|
42
|
-
nextBaseFee: null,
|
|
43
|
-
});
|
|
44
|
-
jest.spyOn(ledgerExplorer, "getLastOperations").mockResolvedValue({
|
|
45
|
-
lastCoinOperations: [],
|
|
46
|
-
lastInternalOperations: [],
|
|
47
|
-
lastNftOperations: [],
|
|
48
|
-
lastTokenOperations: [],
|
|
49
|
-
});
|
|
50
|
-
jest.spyOn(ledgerNode, "getCoinBalance").mockResolvedValue(new BigNumber(50));
|
|
51
|
-
jest.spyOn(ledgerGasTracker, "getGasOptions").mockResolvedValue({
|
|
52
|
-
slow: {
|
|
53
|
-
maxFeePerGas: null,
|
|
54
|
-
maxPriorityFeePerGas: null,
|
|
55
|
-
gasPrice: null,
|
|
56
|
-
nextBaseFee: null,
|
|
57
|
-
},
|
|
58
|
-
medium: {
|
|
59
|
-
maxFeePerGas: null,
|
|
60
|
-
maxPriorityFeePerGas: null,
|
|
61
|
-
gasPrice: null,
|
|
62
|
-
nextBaseFee: null,
|
|
63
|
-
},
|
|
64
|
-
fast: {
|
|
65
|
-
maxFeePerGas: null,
|
|
66
|
-
maxPriorityFeePerGas: null,
|
|
67
|
-
gasPrice: null,
|
|
68
|
-
nextBaseFee: null,
|
|
69
|
-
},
|
|
70
|
-
});
|
|
71
|
-
});
|
|
72
|
-
afterEach(() => {
|
|
73
|
-
jest.restoreAllMocks();
|
|
74
|
-
});
|
|
75
|
-
describe("recipient", () => {
|
|
76
|
-
it("detects the missing recipient with an error", async () => {
|
|
77
|
-
const res = await validateIntent({}, eip1559Intent({ amount: 1n, recipient: "" }));
|
|
78
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
79
|
-
recipient: new RecipientRequired(),
|
|
80
|
-
}));
|
|
81
|
-
});
|
|
82
|
-
it("detects the incorrect recipient not being an eth address with an error", async () => {
|
|
83
|
-
const res = await validateIntent({ name: "Ethereum" }, eip1559Intent({ amount: 1n, recipient: "invalid-address" }));
|
|
84
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
85
|
-
recipient: new InvalidAddress("", {
|
|
86
|
-
currencyName: "Ethereum",
|
|
87
|
-
}),
|
|
88
|
-
}));
|
|
89
|
-
});
|
|
90
|
-
it("detects the recipient being an ICAP with an error", async () => {
|
|
91
|
-
const res = await validateIntent({ name: "Ethereum" }, eip1559Intent({
|
|
92
|
-
amount: 1n,
|
|
93
|
-
recipient: "XE89MW3Y75UITCQ4F53YDKR25UFLB1640YM", // ICAP version of recipient address
|
|
94
|
-
}));
|
|
95
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
96
|
-
recipient: new InvalidAddress("", {
|
|
97
|
-
currencyName: "Ethereum",
|
|
98
|
-
}),
|
|
99
|
-
}));
|
|
100
|
-
});
|
|
101
|
-
it("detects the recipient not being an EIP55 address with a warning", async () => {
|
|
102
|
-
const res = await validateIntent({ name: "Ethereum" }, eip1559Intent({ amount: 1n, recipient: "0xe2ca7390e76c5a992749bb622087310d2e63ca29" }));
|
|
103
|
-
expect(res.warnings).toEqual(expect.objectContaining({
|
|
104
|
-
recipient: new ETHAddressNonEIP(),
|
|
105
|
-
}));
|
|
106
|
-
});
|
|
107
|
-
});
|
|
108
|
-
describe("amount", () => {
|
|
109
|
-
it("detects an intent for native asset sending without amount with an error", async () => {
|
|
110
|
-
const res = await validateIntent({}, eip1559Intent({
|
|
111
|
-
amount: 0n,
|
|
112
|
-
asset: { type: "native" },
|
|
113
|
-
}));
|
|
114
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
115
|
-
amount: new AmountRequired(),
|
|
116
|
-
}));
|
|
117
|
-
});
|
|
118
|
-
it("detects an intent for token asset sending without amount with an error", async () => {
|
|
119
|
-
const res = await validateIntent({}, eip1559Intent({
|
|
120
|
-
recipient: "0xe2ca7390e76c5A992749bB622087310d2e63ca29",
|
|
121
|
-
amount: 0n,
|
|
122
|
-
asset: { type: "erc20" },
|
|
123
|
-
}));
|
|
124
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
125
|
-
amount: new AmountRequired(),
|
|
126
|
-
}));
|
|
127
|
-
});
|
|
128
|
-
it("detects native asset sending intent with an error", async () => {
|
|
129
|
-
jest.spyOn(ledgerNode, "getCoinBalance").mockResolvedValue(new BigNumber(10));
|
|
130
|
-
const res = await validateIntent({}, eip1559Intent({
|
|
131
|
-
amount: 20n,
|
|
132
|
-
asset: { type: "native" },
|
|
133
|
-
}));
|
|
134
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
135
|
-
amount: new NotEnoughBalance(),
|
|
136
|
-
}));
|
|
137
|
-
});
|
|
138
|
-
it("detects token asset sending intent with an error", async () => {
|
|
139
|
-
jest.spyOn(ledgerExplorer, "getLastOperations").mockResolvedValue({
|
|
140
|
-
lastCoinOperations: [],
|
|
141
|
-
lastInternalOperations: [],
|
|
142
|
-
lastNftOperations: [],
|
|
143
|
-
lastTokenOperations: [{ contract: "contract-address" }],
|
|
144
|
-
});
|
|
145
|
-
const getTokenBalance = jest
|
|
146
|
-
.spyOn(ledgerNode, "getTokenBalance")
|
|
147
|
-
.mockResolvedValue(new BigNumber(10));
|
|
148
|
-
const res = await validateIntent({}, eip1559Intent({
|
|
149
|
-
sender: "sender-address",
|
|
150
|
-
recipient: "0xe2ca7390e76c5A992749bB622087310d2e63ca29",
|
|
151
|
-
amount: 20n,
|
|
152
|
-
asset: { type: "erc20", assetReference: "contract-adress" },
|
|
153
|
-
}));
|
|
154
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
155
|
-
amount: new NotEnoughBalance(),
|
|
156
|
-
}));
|
|
157
|
-
expect(getTokenBalance).toHaveBeenCalledWith({}, "sender-address", "contract-address");
|
|
158
|
-
});
|
|
159
|
-
});
|
|
160
|
-
describe("gas", () => {
|
|
161
|
-
describe("common", () => {
|
|
162
|
-
describe.each([
|
|
163
|
-
["a legacy intent", legacyIntent],
|
|
164
|
-
["an eip1559 intent", eip1559Intent],
|
|
165
|
-
])("for %s", (_s, createIntent) => {
|
|
166
|
-
it("detects missing fees with an error", async () => {
|
|
167
|
-
const res = await validateIntent({}, createIntent({}), { value: 0n });
|
|
168
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
169
|
-
gasPrice: new FeeNotLoaded(),
|
|
170
|
-
}));
|
|
171
|
-
});
|
|
172
|
-
it("detects a missing gasLimit with an error", async () => {
|
|
173
|
-
const res = await validateIntent({}, createIntent({}), {
|
|
174
|
-
value: 0n,
|
|
175
|
-
parameters: { gasLimit: undefined },
|
|
176
|
-
});
|
|
177
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
178
|
-
gasLimit: new FeeNotLoaded(),
|
|
179
|
-
}));
|
|
180
|
-
});
|
|
181
|
-
it("detects a gasLimit = 0 with an error", async () => {
|
|
182
|
-
const res = await validateIntent({}, createIntent({}), {
|
|
183
|
-
value: 0n,
|
|
184
|
-
parameters: { gasLimit: 0n },
|
|
185
|
-
});
|
|
186
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
187
|
-
gasLimit: new FeeNotLoaded(),
|
|
188
|
-
}));
|
|
189
|
-
});
|
|
190
|
-
it("detects a customGasLimit = 0 with an error", async () => {
|
|
191
|
-
const res = await validateIntent({}, createIntent({}), {
|
|
192
|
-
value: 0n,
|
|
193
|
-
parameters: { customGasLimit: 0n },
|
|
194
|
-
});
|
|
195
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
196
|
-
gasLimit: new FeeNotLoaded(),
|
|
197
|
-
}));
|
|
198
|
-
});
|
|
199
|
-
it("if the recipient has been set, detects fees being too high for the account balance with an error", async () => {
|
|
200
|
-
jest.spyOn(ledgerNode, "getCoinBalance").mockResolvedValue(new BigNumber(10));
|
|
201
|
-
const notEnoughBalanceRes = await validateIntent({ units: [{ code: "ETH", name: "ETH", magnitude: 18 }] }, createIntent({ recipient: "recipient-address" }), {
|
|
202
|
-
value: 11n,
|
|
203
|
-
parameters: { gasPrice: 1n, maxFeePerGas: 1n, maxPriorityFeePerGas: 1n },
|
|
204
|
-
});
|
|
205
|
-
const enoughBalanceRes = await validateIntent({ units: [{ code: "ETH", name: "ETH", magnitude: 18 }] }, createIntent({ recipient: "recipient-address" }), {
|
|
206
|
-
value: 9n,
|
|
207
|
-
parameters: { gasPrice: 1n, maxFeePerGas: 1n, maxPriorityFeePerGas: 1n },
|
|
208
|
-
});
|
|
209
|
-
expect(notEnoughBalanceRes.errors).toEqual(expect.objectContaining({
|
|
210
|
-
gasPrice: new NotEnoughGas(),
|
|
211
|
-
}));
|
|
212
|
-
expect(enoughBalanceRes.errors).not.toEqual(expect.objectContaining({
|
|
213
|
-
gasPrice: new NotEnoughGas(),
|
|
214
|
-
}));
|
|
215
|
-
});
|
|
216
|
-
it("if the recipient has not been set, does not detect gas being too high", async () => {
|
|
217
|
-
jest.spyOn(ledgerNode, "getCoinBalance").mockResolvedValue(new BigNumber(10));
|
|
218
|
-
const notEnoughBalanceRes = await validateIntent({ units: [{ code: "ETH", name: "ETH", magnitude: 18 }] }, createIntent({ recipient: "" }), {
|
|
219
|
-
value: 11n,
|
|
220
|
-
parameters: { gasPrice: 1n, maxFeePerGas: 1n, maxPriorityFeePerGas: 1n },
|
|
221
|
-
});
|
|
222
|
-
const enoughBalanceRes = await validateIntent({ units: [{ code: "ETH", name: "ETH", magnitude: 18 }] }, createIntent({ recipient: "" }), {
|
|
223
|
-
value: 9n,
|
|
224
|
-
parameters: { gasPrice: 1n, maxFeePerGas: 1n, maxPriorityFeePerGas: 1n },
|
|
225
|
-
});
|
|
226
|
-
expect(notEnoughBalanceRes.errors).not.toEqual(expect.objectContaining({
|
|
227
|
-
gasPrice: new NotEnoughGas(),
|
|
228
|
-
}));
|
|
229
|
-
expect(enoughBalanceRes.errors).not.toEqual(expect.objectContaining({
|
|
230
|
-
gasPrice: new NotEnoughGas(),
|
|
231
|
-
}));
|
|
232
|
-
});
|
|
233
|
-
it("detects gas limit being too low in a tx with an error", async () => {
|
|
234
|
-
const res = await validateIntent({}, createIntent({}), {
|
|
235
|
-
value: 0n,
|
|
236
|
-
parameters: { gasLimit: 20000n }, // min should be 21000
|
|
237
|
-
});
|
|
238
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
239
|
-
gasLimit: new GasLessThanEstimate(),
|
|
240
|
-
}));
|
|
241
|
-
});
|
|
242
|
-
it("detects custom gas limit being too low in a tx with an error", async () => {
|
|
243
|
-
const res = await validateIntent({}, createIntent({}), {
|
|
244
|
-
value: 0n,
|
|
245
|
-
parameters: { customGasLimit: 20000n }, // min should be 21000
|
|
246
|
-
});
|
|
247
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
248
|
-
gasLimit: new GasLessThanEstimate(),
|
|
249
|
-
}));
|
|
250
|
-
});
|
|
251
|
-
it("detects customGasLimit being lower than gasLimit with a warning", async () => {
|
|
252
|
-
const res = await validateIntent({}, createIntent({}), {
|
|
253
|
-
value: 0n,
|
|
254
|
-
parameters: {
|
|
255
|
-
gasLimit: 22000n,
|
|
256
|
-
customGasLimit: 21000n,
|
|
257
|
-
},
|
|
258
|
-
});
|
|
259
|
-
expect(res.warnings).toEqual(expect.objectContaining({
|
|
260
|
-
gasLimit: new GasLessThanEstimate(),
|
|
261
|
-
}));
|
|
262
|
-
});
|
|
263
|
-
});
|
|
264
|
-
});
|
|
265
|
-
describe("eip1559 specific", () => {
|
|
266
|
-
it("detects a maxPriorityFeePerGas = 0 with an error", async () => {
|
|
267
|
-
const res = await validateIntent({}, eip1559Intent({}), {
|
|
268
|
-
value: 0n,
|
|
269
|
-
parameters: { maxPriorityFeePerGas: 0n, maxFeePerGas: 2n },
|
|
270
|
-
});
|
|
271
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
272
|
-
maxPriorityFee: new PriorityFeeTooLow(),
|
|
273
|
-
}));
|
|
274
|
-
});
|
|
275
|
-
it("detects maxFeePerGas being greater than max gasOptions maxFeePerGas with an error", async () => {
|
|
276
|
-
const res = await validateIntent({}, eip1559Intent({}), {
|
|
277
|
-
value: 0n,
|
|
278
|
-
parameters: { maxPriorityFeePerGas: 6n, maxFeePerGas: 5n },
|
|
279
|
-
});
|
|
280
|
-
expect(res.errors).toEqual(expect.objectContaining({
|
|
281
|
-
maxPriorityFee: new PriorityFeeHigherThanMaxFee(),
|
|
282
|
-
}));
|
|
283
|
-
});
|
|
284
|
-
it("detects maxPriorityFeePerGas being greater than max gasOptions maxPriorityFeePerGas with a warning", async () => {
|
|
285
|
-
jest.spyOn(ledgerGasTracker, "getGasOptions").mockResolvedValue({
|
|
286
|
-
slow: {
|
|
287
|
-
maxFeePerGas: null,
|
|
288
|
-
maxPriorityFeePerGas: null,
|
|
289
|
-
gasPrice: null,
|
|
290
|
-
nextBaseFee: null,
|
|
291
|
-
},
|
|
292
|
-
medium: {
|
|
293
|
-
maxFeePerGas: null,
|
|
294
|
-
maxPriorityFeePerGas: null,
|
|
295
|
-
gasPrice: null,
|
|
296
|
-
nextBaseFee: null,
|
|
297
|
-
},
|
|
298
|
-
fast: {
|
|
299
|
-
maxFeePerGas: null,
|
|
300
|
-
maxPriorityFeePerGas: BigNumber(3),
|
|
301
|
-
gasPrice: null,
|
|
302
|
-
nextBaseFee: null,
|
|
303
|
-
},
|
|
304
|
-
});
|
|
305
|
-
const res = await validateIntent({}, eip1559Intent({}), {
|
|
306
|
-
value: 0n,
|
|
307
|
-
parameters: { maxPriorityFeePerGas: 4n, maxFeePerGas: 5n },
|
|
308
|
-
});
|
|
309
|
-
expect(res.warnings).toEqual(expect.objectContaining({
|
|
310
|
-
maxPriorityFee: new PriorityFeeTooHigh(),
|
|
311
|
-
}));
|
|
312
|
-
});
|
|
313
|
-
it("detects maxPriorityFeePerGas being lower than min gasOptions maxPriorityFeePerGas with a warning", async () => {
|
|
314
|
-
jest.spyOn(ledgerGasTracker, "getGasOptions").mockResolvedValue({
|
|
315
|
-
slow: {
|
|
316
|
-
maxFeePerGas: null,
|
|
317
|
-
maxPriorityFeePerGas: BigNumber(3),
|
|
318
|
-
gasPrice: null,
|
|
319
|
-
nextBaseFee: null,
|
|
320
|
-
},
|
|
321
|
-
medium: {
|
|
322
|
-
maxFeePerGas: null,
|
|
323
|
-
maxPriorityFeePerGas: null,
|
|
324
|
-
gasPrice: null,
|
|
325
|
-
nextBaseFee: null,
|
|
326
|
-
},
|
|
327
|
-
fast: {
|
|
328
|
-
maxFeePerGas: null,
|
|
329
|
-
maxPriorityFeePerGas: null,
|
|
330
|
-
gasPrice: null,
|
|
331
|
-
nextBaseFee: null,
|
|
332
|
-
},
|
|
333
|
-
});
|
|
334
|
-
const res = await validateIntent({}, eip1559Intent({}), {
|
|
335
|
-
value: 0n,
|
|
336
|
-
parameters: { maxPriorityFeePerGas: 1n, maxFeePerGas: 5n },
|
|
337
|
-
});
|
|
338
|
-
expect(res.warnings).toEqual(expect.objectContaining({
|
|
339
|
-
maxPriorityFee: new PriorityFeeTooLow(),
|
|
340
|
-
}));
|
|
341
|
-
});
|
|
342
|
-
it("detects maxFeePerGas being lower than recommanded next base fee with a warning", async () => {
|
|
343
|
-
jest.spyOn(ledgerGasTracker, "getGasOptions").mockResolvedValue({
|
|
344
|
-
slow: {
|
|
345
|
-
maxFeePerGas: null,
|
|
346
|
-
maxPriorityFeePerGas: null,
|
|
347
|
-
gasPrice: null,
|
|
348
|
-
nextBaseFee: null,
|
|
349
|
-
},
|
|
350
|
-
medium: {
|
|
351
|
-
maxFeePerGas: null,
|
|
352
|
-
maxPriorityFeePerGas: null,
|
|
353
|
-
gasPrice: null,
|
|
354
|
-
nextBaseFee: BigNumber(6),
|
|
355
|
-
},
|
|
356
|
-
fast: {
|
|
357
|
-
maxFeePerGas: null,
|
|
358
|
-
maxPriorityFeePerGas: null,
|
|
359
|
-
gasPrice: null,
|
|
360
|
-
nextBaseFee: null,
|
|
361
|
-
},
|
|
362
|
-
});
|
|
363
|
-
const res = await validateIntent({}, eip1559Intent({}), {
|
|
364
|
-
value: 0n,
|
|
365
|
-
parameters: { maxPriorityFeePerGas: 1n, maxFeePerGas: 5n },
|
|
366
|
-
});
|
|
367
|
-
expect(res.warnings).toEqual(expect.objectContaining({
|
|
368
|
-
maxFee: new MaxFeeTooLow(),
|
|
369
|
-
}));
|
|
370
|
-
});
|
|
371
|
-
});
|
|
372
|
-
});
|
|
373
|
-
describe("valid intent", () => {
|
|
374
|
-
it("does not return any error of warning for a valid legacy intent", async () => {
|
|
375
|
-
const res = await validateIntent({}, legacyIntent({ amount: 2n, recipient: "0xe2ca7390e76c5A992749bB622087310d2e63ca29" }), {
|
|
376
|
-
value: 4n,
|
|
377
|
-
parameters: { gasLimit: 21000n, gasPrice: 10n },
|
|
378
|
-
});
|
|
379
|
-
expect(res).toEqual({
|
|
380
|
-
estimatedFees: 4n,
|
|
381
|
-
totalSpent: 6n,
|
|
382
|
-
amount: 2n,
|
|
383
|
-
errors: {},
|
|
384
|
-
warnings: {},
|
|
385
|
-
});
|
|
386
|
-
});
|
|
387
|
-
it("does not return any error of warning for a valid eip1559 intent", async () => {
|
|
388
|
-
jest.spyOn(ledgerGasTracker, "getGasOptions").mockResolvedValue({
|
|
389
|
-
slow: {
|
|
390
|
-
maxFeePerGas: null,
|
|
391
|
-
maxPriorityFeePerGas: BigNumber(2),
|
|
392
|
-
gasPrice: null,
|
|
393
|
-
nextBaseFee: null,
|
|
394
|
-
},
|
|
395
|
-
medium: {
|
|
396
|
-
maxFeePerGas: null,
|
|
397
|
-
maxPriorityFeePerGas: null,
|
|
398
|
-
gasPrice: null,
|
|
399
|
-
nextBaseFee: BigNumber(4),
|
|
400
|
-
},
|
|
401
|
-
fast: {
|
|
402
|
-
maxFeePerGas: null,
|
|
403
|
-
maxPriorityFeePerGas: BigNumber(6),
|
|
404
|
-
gasPrice: null,
|
|
405
|
-
nextBaseFee: null,
|
|
406
|
-
},
|
|
407
|
-
});
|
|
408
|
-
const res = await validateIntent({}, eip1559Intent({ amount: 2n, recipient: "0xe2ca7390e76c5A992749bB622087310d2e63ca29" }), {
|
|
409
|
-
value: 4n,
|
|
410
|
-
parameters: { gasLimit: 21000n, maxPriorityFeePerGas: 3n, maxFeePerGas: 5n },
|
|
411
|
-
});
|
|
412
|
-
expect(res).toEqual({
|
|
413
|
-
estimatedFees: 4n,
|
|
414
|
-
totalSpent: 6n,
|
|
415
|
-
amount: 2n,
|
|
416
|
-
errors: {},
|
|
417
|
-
warnings: {},
|
|
418
|
-
});
|
|
419
|
-
});
|
|
420
|
-
it("does not call the gas tracker if unnecessary", async () => {
|
|
421
|
-
const getGasOptions = jest.spyOn(ledgerGasTracker, "getGasOptions").mockResolvedValue({
|
|
422
|
-
slow: {
|
|
423
|
-
maxFeePerGas: null,
|
|
424
|
-
maxPriorityFeePerGas: null,
|
|
425
|
-
gasPrice: null,
|
|
426
|
-
nextBaseFee: null,
|
|
427
|
-
},
|
|
428
|
-
medium: {
|
|
429
|
-
maxFeePerGas: null,
|
|
430
|
-
maxPriorityFeePerGas: null,
|
|
431
|
-
gasPrice: null,
|
|
432
|
-
nextBaseFee: null,
|
|
433
|
-
},
|
|
434
|
-
fast: {
|
|
435
|
-
maxFeePerGas: null,
|
|
436
|
-
maxPriorityFeePerGas: null,
|
|
437
|
-
gasPrice: null,
|
|
438
|
-
nextBaseFee: null,
|
|
439
|
-
},
|
|
440
|
-
});
|
|
441
|
-
const res = await validateIntent({}, eip1559Intent({ amount: 2n, recipient: "0xe2ca7390e76c5A992749bB622087310d2e63ca29" }), {
|
|
442
|
-
value: 4n,
|
|
443
|
-
parameters: {
|
|
444
|
-
gasLimit: 21000n,
|
|
445
|
-
maxPriorityFeePerGas: 3n,
|
|
446
|
-
maxFeePerGas: 5n,
|
|
447
|
-
gasOptions: {
|
|
448
|
-
slow: {
|
|
449
|
-
maxFeePerGas: null,
|
|
450
|
-
maxPriorityFeePerGas: 2n,
|
|
451
|
-
gasPrice: null,
|
|
452
|
-
nextBaseFee: null,
|
|
453
|
-
},
|
|
454
|
-
medium: {
|
|
455
|
-
maxFeePerGas: null,
|
|
456
|
-
maxPriorityFeePerGas: null,
|
|
457
|
-
gasPrice: null,
|
|
458
|
-
nextBaseFee: 4n,
|
|
459
|
-
},
|
|
460
|
-
fast: {
|
|
461
|
-
maxFeePerGas: null,
|
|
462
|
-
maxPriorityFeePerGas: 6n,
|
|
463
|
-
gasPrice: null,
|
|
464
|
-
nextBaseFee: null,
|
|
465
|
-
},
|
|
466
|
-
},
|
|
467
|
-
},
|
|
468
|
-
});
|
|
469
|
-
expect(res).toEqual({
|
|
470
|
-
estimatedFees: 4n,
|
|
471
|
-
totalSpent: 6n,
|
|
472
|
-
amount: 2n,
|
|
473
|
-
errors: {},
|
|
474
|
-
warnings: {},
|
|
475
|
-
});
|
|
476
|
-
expect(getGasOptions).not.toHaveBeenCalled();
|
|
477
|
-
});
|
|
478
|
-
});
|
|
479
|
-
});
|
|
480
|
-
//# sourceMappingURL=validateIntent.test.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"validateIntent.test.js","sourceRoot":"","sources":["../../src/logic/validateIntent.test.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EACd,gBAAgB,EAChB,YAAY,EACZ,mBAAmB,EACnB,cAAc,EACd,YAAY,EACZ,gBAAgB,EAChB,YAAY,EACZ,2BAA2B,EAC3B,kBAAkB,EAClB,iBAAiB,EACjB,iBAAiB,GAClB,MAAM,kBAAkB,CAAC;AAE1B,OAA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AAE,IAAI;4BACd,WAAW,EAAE,EAAE;yBAChB;wBACD,IAAI,EAAE;4BACJ,YAAY,EAAE,IAAI;4BAClB,oBAAoB,EAAE,EAAE;4BACxB,QAAQ,EAAE,IAAI;4BACd,WAAW,EAAE,IAAI;yBAClB;qBACF;iBACF;aACF,CACF,CAAC;YAEF,MAAM,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC;gBAClB,aAAa,EAAE,EAAE;gBACjB,UAAU,EAAE,EAAE;gBACd,MAAM,EAAE,EAAE;gBACV,MAAM,EAAE,EAAE;gBACV,QAAQ,EAAE,EAAE;aACb,CAAC,CAAC;YACH,MAAM,CAAC,aAAa,CAAC,CAAC,GAAG,CAAC,gBAAgB,EAAE,CAAC;QAC/C,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"type": "TokenCurrency",
|
|
3
|
-
"id": "cardano/native/8654e8b350e298c80d2451beb5ed80fc9eee9f38ce6b039fb8706bc34c4f4253544552",
|
|
4
|
-
"contractAddress": "8654e8b350e298c80d2451beb5ed80fc9eee9f38ce6b039fb8706bc34c4f4253544552",
|
|
5
|
-
"parentCurrency": {
|
|
6
|
-
"type": "CryptoCurrency",
|
|
7
|
-
"id": "cardano",
|
|
8
|
-
"coinType": 1815,
|
|
9
|
-
"name": "Cardano",
|
|
10
|
-
"managerAppName": "Cardano ADA",
|
|
11
|
-
"ticker": "ADA",
|
|
12
|
-
"scheme": "cardano",
|
|
13
|
-
"color": "#0A1D2C",
|
|
14
|
-
"family": "cardano",
|
|
15
|
-
"blockAvgTime": 20,
|
|
16
|
-
"units": [
|
|
17
|
-
{
|
|
18
|
-
"name": "ada",
|
|
19
|
-
"code": "ADA",
|
|
20
|
-
"magnitude": 6
|
|
21
|
-
},
|
|
22
|
-
{
|
|
23
|
-
"name": "Lovelace",
|
|
24
|
-
"code": "Lovelace",
|
|
25
|
-
"magnitude": 0
|
|
26
|
-
}
|
|
27
|
-
],
|
|
28
|
-
"explorerViews": [
|
|
29
|
-
{
|
|
30
|
-
"tx": "https://cardanoscan.io/transaction/$hash",
|
|
31
|
-
"address": "https://cardanoscan.io/address/$address",
|
|
32
|
-
"stakePool": "https://cardanoscan.io/pool/$poolId"
|
|
33
|
-
}
|
|
34
|
-
],
|
|
35
|
-
"keywords": [
|
|
36
|
-
"ada",
|
|
37
|
-
"cardano"
|
|
38
|
-
]
|
|
39
|
-
},
|
|
40
|
-
"tokenType": "native",
|
|
41
|
-
"name": "LOBSTER",
|
|
42
|
-
"ticker": "$LOBSTER",
|
|
43
|
-
"delisted": false,
|
|
44
|
-
"disableCountervalue": false,
|
|
45
|
-
"units": [
|
|
46
|
-
{
|
|
47
|
-
"name": "LOBSTER",
|
|
48
|
-
"code": "$LOBSTER",
|
|
49
|
-
"magnitude": 0
|
|
50
|
-
}
|
|
51
|
-
]
|
|
52
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"accountId": "js:2:ethereum:0x6cbcd73cd8e8a42844662f0a0e76d7f79afd933d:+ethereum%2Ferc20%2Fusd~!underscore!~~!underscore!~coin",
|
|
3
|
-
"blockHash": "0x58ee7556044cd139e569c87c173a6dedbfbeb9ada6693ee6090fd510acee9c21",
|
|
4
|
-
"blockHeight": 16240731,
|
|
5
|
-
"contract": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
|
|
6
|
-
"date": "2022-12-22T14:06:23.000Z",
|
|
7
|
-
"extra": {},
|
|
8
|
-
"fee": "1595338583295225",
|
|
9
|
-
"hash": "0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf",
|
|
10
|
-
"id": "js:2:ethereum:0x6cbcd73cd8e8a42844662f0a0e76d7f79afd933d:+js%3A2%3Aethereum%3A0x6cbcd73cd8e8a42844662f0a0e76d7f79afd933d%3A%2Bethereum%252Ferc20%252Fusd~!underscore!~~!underscore!~coin~!dash!~0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf~!dash!~OUT~!dash!~i0-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-IN-i0",
|
|
11
|
-
"recipients": [
|
|
12
|
-
"0xC2907EFccE4011C491BbedA8A0fA63BA7aab596C"
|
|
13
|
-
],
|
|
14
|
-
"senders": [
|
|
15
|
-
"0x6cBCD73CD8e8a42844662f0A0e76D7F79Afd933d"
|
|
16
|
-
],
|
|
17
|
-
"transactionSequenceNumber": 53,
|
|
18
|
-
"type": "OUT",
|
|
19
|
-
"value": "2000000"
|
|
20
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"accountId": "js:2:ethereum:0x6cbcd73cd8e8a42844662f0a0e76d7f79afd933d:+js%3A2%3Aethereum%3A0x6cbcd73cd8e8a42844662f0a0e76d7f79afd933d%3A%2Bethereum%252Ferc20%252Fusd~!underscore!~~!underscore!~coin~!dash!~0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf~!dash!~OUT~!dash!~i0",
|
|
3
|
-
"blockHash": "0x58ee7556044cd139e569c87c173a6dedbfbeb9ada6693ee6090fd510acee9c21",
|
|
4
|
-
"blockHeight": 16240731,
|
|
5
|
-
"date": "2022-12-22T14:06:23.000Z",
|
|
6
|
-
"extra": {},
|
|
7
|
-
"fee": "1595338583295225",
|
|
8
|
-
"hash": "0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf",
|
|
9
|
-
"id": "js:2:ethereum:0x6cbcd73cd8e8a42844662f0a0e76d7f79afd933d:+js%3A2%3Aethereum%3A0x6cbcd73cd8e8a42844662f0a0e76d7f79afd933d%3A%2Bethereum%252Ferc20%252Fusd~!underscore!~~!underscore!~coin~!dash!~0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf~!dash!~OUT~!dash!~i0-0x02b972f304dc24c9bc362e6435c4ad654241f9af916689a4790145c9bcbdf4cf-OUT-i0",
|
|
10
|
-
"recipients": [
|
|
11
|
-
"0xC2907EFccE4011C491BbedA8A0fA63BA7aab596C"
|
|
12
|
-
],
|
|
13
|
-
"senders": [
|
|
14
|
-
"0x6cBCD73CD8e8a42844662f0A0e76D7F79Afd933d"
|
|
15
|
-
],
|
|
16
|
-
"transactionSequenceNumber": 53,
|
|
17
|
-
"type": "OUT",
|
|
18
|
-
"value": "2000000"
|
|
19
|
-
}
|