@ledgerhq/live-common 34.52.0 → 34.53.0-nightly.20251107095716
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/DataModel.d.ts +2 -2
- package/lib/DataModel.d.ts.map +1 -1
- package/lib/DataModel.js +2 -2
- package/lib/DataModel.js.map +1 -1
- package/lib/__tests__/test-helpers/bridge.d.ts.map +1 -1
- package/lib/__tests__/test-helpers/bridge.js +103 -47
- package/lib/__tests__/test-helpers/bridge.js.map +1 -1
- package/lib/__tests__/test-helpers/setup.d.ts.map +1 -1
- package/lib/__tests__/test-helpers/setup.js +6 -5
- package/lib/__tests__/test-helpers/setup.js.map +1 -1
- package/lib/account/serialization.d.ts +1 -1
- package/lib/account/serialization.d.ts.map +1 -1
- package/lib/account/serialization.js +2 -2
- package/lib/account/serialization.js.map +1 -1
- package/lib/api/ofacGeoBlockApi.d.ts +4 -0
- package/lib/api/ofacGeoBlockApi.d.ts.map +1 -0
- package/lib/api/ofacGeoBlockApi.js +21 -0
- package/lib/api/ofacGeoBlockApi.js.map +1 -0
- package/lib/apps/config.d.ts.map +1 -1
- package/lib/apps/config.js +1 -0
- package/lib/apps/config.js.map +1 -1
- package/lib/bot/engine.d.ts +5 -5
- package/lib/bot/engine.d.ts.map +1 -1
- package/lib/bot/engine.js.map +1 -1
- package/lib/bridge/crypto-assets/index.d.ts.map +1 -1
- package/lib/bridge/crypto-assets/index.js +2 -2
- package/lib/bridge/crypto-assets/index.js.map +1 -1
- package/lib/bridge/generic-alpaca/alpaca/network/network-alpaca.d.ts +2 -2
- package/lib/bridge/generic-alpaca/createTransaction.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/createTransaction.js +6 -1
- package/lib/bridge/generic-alpaca/createTransaction.js.map +1 -1
- package/lib/bridge/generic-alpaca/getTransactionStatus.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/getTransactionStatus.js +1 -0
- package/lib/bridge/generic-alpaca/getTransactionStatus.js.map +1 -1
- package/lib/bridge/generic-alpaca/prepareTransaction.d.ts +2 -2
- package/lib/bridge/generic-alpaca/prepareTransaction.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/prepareTransaction.js +30 -26
- package/lib/bridge/generic-alpaca/prepareTransaction.js.map +1 -1
- package/lib/bridge/generic-alpaca/signOperation.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/signOperation.js +6 -4
- package/lib/bridge/generic-alpaca/signOperation.js.map +1 -1
- package/lib/bridge/generic-alpaca/signer/Eth.d.ts +2 -1
- package/lib/bridge/generic-alpaca/signer/Eth.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/signer/Eth.js +2 -1
- package/lib/bridge/generic-alpaca/signer/Eth.js.map +1 -1
- package/lib/bridge/generic-alpaca/types.d.ts +61 -2
- package/lib/bridge/generic-alpaca/types.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/utils.d.ts +1 -1
- package/lib/bridge/generic-alpaca/utils.d.ts.map +1 -1
- package/lib/bridge/generic-alpaca/utils.js +121 -7
- package/lib/bridge/generic-alpaca/utils.js.map +1 -1
- package/lib/bridge/index.d.ts +1 -1
- package/lib/bridge/index.d.ts.map +1 -1
- package/lib/bridge/index.js +2 -2
- package/lib/bridge/index.js.map +1 -1
- package/lib/currencies/index.d.ts +1 -1
- package/lib/currencies/index.d.ts.map +1 -1
- package/lib/currencies/index.js +1 -4
- package/lib/currencies/index.js.map +1 -1
- package/lib/dada-client/__mocks__/assets.mock.d.ts +383 -0
- package/lib/dada-client/__mocks__/assets.mock.d.ts.map +1 -0
- package/lib/dada-client/__mocks__/assets.mock.js +260 -0
- package/lib/dada-client/__mocks__/assets.mock.js.map +1 -0
- package/lib/dada-client/hooks/useAssetsData.d.ts +2 -1
- package/lib/dada-client/hooks/useAssetsData.d.ts.map +1 -1
- package/lib/dada-client/hooks/useAssetsData.js +2 -2
- package/lib/dada-client/hooks/useAssetsData.js.map +1 -1
- package/lib/dada-client/hooks/useLazyLedgerCurrency.d.ts +13 -0
- package/lib/dada-client/hooks/useLazyLedgerCurrency.d.ts.map +1 -0
- package/lib/dada-client/hooks/useLazyLedgerCurrency.js +34 -0
- package/lib/dada-client/hooks/useLazyLedgerCurrency.js.map +1 -0
- package/lib/dada-client/index.d.ts +2 -0
- package/lib/dada-client/index.d.ts.map +1 -0
- package/lib/dada-client/index.js +18 -0
- package/lib/dada-client/index.js.map +1 -0
- package/lib/dada-client/state-manager/api.js +1 -1
- package/lib/dada-client/state-manager/api.js.map +1 -1
- package/lib/dada-client/utils/currencySelection.d.ts +10 -0
- package/lib/dada-client/utils/currencySelection.d.ts.map +1 -0
- package/lib/dada-client/utils/currencySelection.js +34 -0
- package/lib/dada-client/utils/currencySelection.js.map +1 -0
- package/lib/deposit/helper.d.ts +1 -1
- package/lib/deposit/helper.d.ts.map +1 -1
- package/lib/deposit/helper.js +3 -2
- package/lib/deposit/helper.js.map +1 -1
- package/lib/e2e/data/deviceLabelsData.d.ts.map +1 -1
- package/lib/e2e/data/deviceLabelsData.js +2 -1
- package/lib/e2e/data/deviceLabelsData.js.map +1 -1
- package/lib/e2e/enum/DeviceLabels.d.ts +5 -1
- package/lib/e2e/enum/DeviceLabels.d.ts.map +1 -1
- package/lib/e2e/enum/DeviceLabels.js +4 -0
- package/lib/e2e/enum/DeviceLabels.js.map +1 -1
- package/lib/e2e/index.d.ts +4 -8
- package/lib/e2e/index.d.ts.map +1 -1
- package/lib/e2e/speculos.d.ts +1 -1
- package/lib/e2e/speculos.d.ts.map +1 -1
- package/lib/e2e/speculos.js +24 -5
- package/lib/e2e/speculos.js.map +1 -1
- package/lib/e2e/speculosAppVersion.d.ts.map +1 -1
- package/lib/e2e/speculosAppVersion.js +1 -0
- package/lib/e2e/speculosAppVersion.js.map +1 -1
- package/lib/families/cosmos/datasets/coreum.d.ts.map +1 -1
- package/lib/families/cosmos/datasets/coreum.js +2 -1
- package/lib/families/cosmos/datasets/coreum.js.map +1 -1
- package/lib/families/near/config.d.ts.map +1 -1
- package/lib/families/near/config.js +1 -0
- package/lib/families/near/config.js.map +1 -1
- package/lib/families/solana/setup.d.ts +1 -1
- package/lib/families/tron/data.mock.d.ts +4 -4
- package/lib/families/tron/data.mock.d.ts.map +1 -1
- package/lib/families/tron/data.mock.js +27 -13
- package/lib/families/tron/data.mock.js.map +1 -1
- package/lib/featureFlags/defaultFeatures.d.ts.map +1 -1
- package/lib/featureFlags/defaultFeatures.js +3 -4
- package/lib/featureFlags/defaultFeatures.js.map +1 -1
- package/lib/featureFlags/stakePrograms/index.d.ts +1 -0
- package/lib/featureFlags/stakePrograms/index.d.ts.map +1 -1
- package/lib/featureFlags/stakePrograms/index.js +13 -1
- package/lib/featureFlags/stakePrograms/index.js.map +1 -1
- package/lib/featureFlags/useFeature.d.ts +1 -1
- package/lib/featureFlags/useFeature.d.ts.map +1 -1
- package/lib/generated/cli-transaction.d.ts +1 -1
- package/lib/generated/transaction.d.ts +1 -1
- package/lib/hw/actions/implementations.d.ts.map +1 -1
- package/lib/hw/actions/implementations.js +13 -7
- package/lib/hw/actions/implementations.js.map +1 -1
- package/lib/hw/connectAppEventMapper.d.ts.map +1 -1
- package/lib/hw/connectAppEventMapper.js +2 -2
- package/lib/hw/connectAppEventMapper.js.map +1 -1
- package/lib/market/hooks/useLargeMoverCurrencies.d.ts +1 -1
- package/lib/market/hooks/useMarketDataProvider.d.ts +2 -2
- package/lib/market/hooks/useMarketDataProvider.d.ts.map +1 -1
- package/lib/market/hooks/useMarketDataProvider.js +4 -7
- package/lib/market/hooks/useMarketDataProvider.js.map +1 -1
- package/lib/market/utils/currencyFormatter.d.ts +3 -4
- package/lib/market/utils/currencyFormatter.d.ts.map +1 -1
- package/lib/market/utils/currencyFormatter.js +3 -6
- package/lib/market/utils/currencyFormatter.js.map +1 -1
- package/lib/market/utils/queryKeys.d.ts +0 -1
- package/lib/market/utils/queryKeys.d.ts.map +1 -1
- package/lib/market/utils/queryKeys.js +0 -1
- package/lib/market/utils/queryKeys.js.map +1 -1
- package/lib/market/utils/types.d.ts +6 -8
- package/lib/market/utils/types.d.ts.map +1 -1
- package/lib/market/utils/types.js.map +1 -1
- package/lib/mock/fixtures/cryptoCurrencies.d.ts.map +1 -1
- package/lib/mock/fixtures/cryptoCurrencies.js +10 -1
- package/lib/mock/fixtures/cryptoCurrencies.js.map +1 -1
- package/lib/modularDrawer/__mocks__/currencies.mock.d.ts +1 -1
- package/lib/modularDrawer/__mocks__/currencies.mock.d.ts.map +1 -1
- package/lib/modularDrawer/__mocks__/currencies.mock.js +1 -1
- package/lib/modularDrawer/__mocks__/currencies.mock.js.map +1 -1
- package/lib/modularDrawer/utils/currencyUtils.d.ts +3 -3
- package/lib/modularDrawer/utils/currencyUtils.d.ts.map +1 -1
- package/lib/modularDrawer/utils/currencyUtils.js +8 -8
- package/lib/modularDrawer/utils/currencyUtils.js.map +1 -1
- package/lib/postOnboarding/hooks/usePostOnboardingHubState.d.ts.map +1 -1
- package/lib/postOnboarding/hooks/usePostOnboardingHubState.js +13 -4
- package/lib/postOnboarding/hooks/usePostOnboardingHubState.js.map +1 -1
- package/lib/postOnboarding/mock.d.ts +1 -0
- package/lib/postOnboarding/mock.d.ts.map +1 -1
- package/lib/postOnboarding/mock.js +3 -1
- package/lib/postOnboarding/mock.js.map +1 -1
- package/lib/postOnboarding/reducer.d.ts +16 -14
- package/lib/postOnboarding/reducer.d.ts.map +1 -1
- package/lib/transaction/index.d.ts +1 -1
- package/lib/transaction/index.d.ts.map +1 -1
- package/lib/transaction/index.js +2 -2
- package/lib/transaction/index.js.map +1 -1
- package/lib/utils/addressUtils.d.ts +15 -0
- package/lib/utils/addressUtils.d.ts.map +1 -0
- package/lib/utils/addressUtils.js +39 -0
- package/lib/utils/addressUtils.js.map +1 -0
- package/lib/wallet-api/ACRE/server.d.ts.map +1 -1
- package/lib/wallet-api/ACRE/server.js +19 -15
- package/lib/wallet-api/ACRE/server.js.map +1 -1
- package/lib/wallet-api/Exchange/server.d.ts.map +1 -1
- package/lib/wallet-api/Exchange/server.js +8 -5
- package/lib/wallet-api/Exchange/server.js.map +1 -1
- package/lib/wallet-api/logic.d.ts.map +1 -1
- package/lib/wallet-api/logic.js +29 -29
- package/lib/wallet-api/logic.js.map +1 -1
- package/lib/wallet-api/react.d.ts.map +1 -1
- package/lib/wallet-api/react.js +37 -29
- package/lib/wallet-api/react.js.map +1 -1
- package/lib/wallet-api/useDappLogic.d.ts.map +1 -1
- package/lib/wallet-api/useDappLogic.js +76 -60
- package/lib/wallet-api/useDappLogic.js.map +1 -1
- package/lib-es/DataModel.d.ts +2 -2
- package/lib-es/DataModel.d.ts.map +1 -1
- package/lib-es/DataModel.js +2 -2
- package/lib-es/DataModel.js.map +1 -1
- package/lib-es/__tests__/test-helpers/bridge.d.ts.map +1 -1
- package/lib-es/__tests__/test-helpers/bridge.js +103 -47
- package/lib-es/__tests__/test-helpers/bridge.js.map +1 -1
- package/lib-es/__tests__/test-helpers/setup.d.ts.map +1 -1
- package/lib-es/__tests__/test-helpers/setup.js +6 -5
- package/lib-es/__tests__/test-helpers/setup.js.map +1 -1
- package/lib-es/account/serialization.d.ts +1 -1
- package/lib-es/account/serialization.d.ts.map +1 -1
- package/lib-es/account/serialization.js +2 -2
- package/lib-es/account/serialization.js.map +1 -1
- package/lib-es/api/ofacGeoBlockApi.d.ts +4 -0
- package/lib-es/api/ofacGeoBlockApi.d.ts.map +1 -0
- package/lib-es/api/ofacGeoBlockApi.js +18 -0
- package/lib-es/api/ofacGeoBlockApi.js.map +1 -0
- package/lib-es/apps/config.d.ts.map +1 -1
- package/lib-es/apps/config.js +1 -0
- package/lib-es/apps/config.js.map +1 -1
- package/lib-es/bot/engine.d.ts +5 -5
- package/lib-es/bot/engine.d.ts.map +1 -1
- package/lib-es/bot/engine.js.map +1 -1
- package/lib-es/bridge/crypto-assets/index.d.ts.map +1 -1
- package/lib-es/bridge/crypto-assets/index.js +1 -1
- package/lib-es/bridge/crypto-assets/index.js.map +1 -1
- package/lib-es/bridge/generic-alpaca/alpaca/network/network-alpaca.d.ts +2 -2
- package/lib-es/bridge/generic-alpaca/createTransaction.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/createTransaction.js +6 -1
- package/lib-es/bridge/generic-alpaca/createTransaction.js.map +1 -1
- package/lib-es/bridge/generic-alpaca/getTransactionStatus.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/getTransactionStatus.js +1 -0
- package/lib-es/bridge/generic-alpaca/getTransactionStatus.js.map +1 -1
- package/lib-es/bridge/generic-alpaca/prepareTransaction.d.ts +2 -2
- package/lib-es/bridge/generic-alpaca/prepareTransaction.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/prepareTransaction.js +30 -26
- package/lib-es/bridge/generic-alpaca/prepareTransaction.js.map +1 -1
- package/lib-es/bridge/generic-alpaca/signOperation.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/signOperation.js +6 -4
- package/lib-es/bridge/generic-alpaca/signOperation.js.map +1 -1
- package/lib-es/bridge/generic-alpaca/signer/Eth.d.ts +2 -1
- package/lib-es/bridge/generic-alpaca/signer/Eth.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/signer/Eth.js +2 -1
- package/lib-es/bridge/generic-alpaca/signer/Eth.js.map +1 -1
- package/lib-es/bridge/generic-alpaca/types.d.ts +61 -2
- package/lib-es/bridge/generic-alpaca/types.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/utils.d.ts +1 -1
- package/lib-es/bridge/generic-alpaca/utils.d.ts.map +1 -1
- package/lib-es/bridge/generic-alpaca/utils.js +121 -7
- package/lib-es/bridge/generic-alpaca/utils.js.map +1 -1
- package/lib-es/bridge/index.d.ts +1 -1
- package/lib-es/bridge/index.d.ts.map +1 -1
- package/lib-es/bridge/index.js +2 -2
- package/lib-es/bridge/index.js.map +1 -1
- package/lib-es/currencies/index.d.ts +1 -1
- package/lib-es/currencies/index.d.ts.map +1 -1
- package/lib-es/currencies/index.js +1 -1
- package/lib-es/currencies/index.js.map +1 -1
- package/lib-es/dada-client/__mocks__/assets.mock.d.ts +383 -0
- package/lib-es/dada-client/__mocks__/assets.mock.d.ts.map +1 -0
- package/lib-es/dada-client/__mocks__/assets.mock.js +257 -0
- package/lib-es/dada-client/__mocks__/assets.mock.js.map +1 -0
- package/lib-es/dada-client/hooks/useAssetsData.d.ts +2 -1
- package/lib-es/dada-client/hooks/useAssetsData.d.ts.map +1 -1
- package/lib-es/dada-client/hooks/useAssetsData.js +2 -2
- package/lib-es/dada-client/hooks/useAssetsData.js.map +1 -1
- package/lib-es/dada-client/hooks/useLazyLedgerCurrency.d.ts +13 -0
- package/lib-es/dada-client/hooks/useLazyLedgerCurrency.d.ts.map +1 -0
- package/lib-es/dada-client/hooks/useLazyLedgerCurrency.js +27 -0
- package/lib-es/dada-client/hooks/useLazyLedgerCurrency.js.map +1 -0
- package/lib-es/dada-client/index.d.ts +2 -0
- package/lib-es/dada-client/index.d.ts.map +1 -0
- package/lib-es/dada-client/index.js +2 -0
- package/lib-es/dada-client/index.js.map +1 -0
- package/lib-es/dada-client/state-manager/api.js +1 -1
- package/lib-es/dada-client/state-manager/api.js.map +1 -1
- package/lib-es/dada-client/utils/currencySelection.d.ts +10 -0
- package/lib-es/dada-client/utils/currencySelection.d.ts.map +1 -0
- package/lib-es/dada-client/utils/currencySelection.js +30 -0
- package/lib-es/dada-client/utils/currencySelection.js.map +1 -0
- package/lib-es/deposit/helper.d.ts +1 -1
- package/lib-es/deposit/helper.d.ts.map +1 -1
- package/lib-es/deposit/helper.js +4 -3
- package/lib-es/deposit/helper.js.map +1 -1
- package/lib-es/e2e/data/deviceLabelsData.d.ts.map +1 -1
- package/lib-es/e2e/data/deviceLabelsData.js +2 -1
- package/lib-es/e2e/data/deviceLabelsData.js.map +1 -1
- package/lib-es/e2e/enum/DeviceLabels.d.ts +5 -1
- package/lib-es/e2e/enum/DeviceLabels.d.ts.map +1 -1
- package/lib-es/e2e/enum/DeviceLabels.js +4 -0
- package/lib-es/e2e/enum/DeviceLabels.js.map +1 -1
- package/lib-es/e2e/index.d.ts +4 -8
- package/lib-es/e2e/index.d.ts.map +1 -1
- package/lib-es/e2e/speculos.d.ts +1 -1
- package/lib-es/e2e/speculos.d.ts.map +1 -1
- package/lib-es/e2e/speculos.js +24 -5
- package/lib-es/e2e/speculos.js.map +1 -1
- package/lib-es/e2e/speculosAppVersion.d.ts.map +1 -1
- package/lib-es/e2e/speculosAppVersion.js +1 -0
- package/lib-es/e2e/speculosAppVersion.js.map +1 -1
- package/lib-es/families/cosmos/datasets/coreum.d.ts.map +1 -1
- package/lib-es/families/cosmos/datasets/coreum.js +2 -1
- package/lib-es/families/cosmos/datasets/coreum.js.map +1 -1
- package/lib-es/families/near/config.d.ts.map +1 -1
- package/lib-es/families/near/config.js +1 -0
- package/lib-es/families/near/config.js.map +1 -1
- package/lib-es/families/solana/setup.d.ts +1 -1
- package/lib-es/families/tron/data.mock.d.ts +4 -4
- package/lib-es/families/tron/data.mock.d.ts.map +1 -1
- package/lib-es/families/tron/data.mock.js +22 -12
- package/lib-es/families/tron/data.mock.js.map +1 -1
- package/lib-es/featureFlags/defaultFeatures.d.ts.map +1 -1
- package/lib-es/featureFlags/defaultFeatures.js +3 -4
- package/lib-es/featureFlags/defaultFeatures.js.map +1 -1
- package/lib-es/featureFlags/stakePrograms/index.d.ts +1 -0
- package/lib-es/featureFlags/stakePrograms/index.d.ts.map +1 -1
- package/lib-es/featureFlags/stakePrograms/index.js +11 -0
- package/lib-es/featureFlags/stakePrograms/index.js.map +1 -1
- package/lib-es/featureFlags/useFeature.d.ts +1 -1
- package/lib-es/featureFlags/useFeature.d.ts.map +1 -1
- package/lib-es/generated/cli-transaction.d.ts +1 -1
- package/lib-es/generated/transaction.d.ts +1 -1
- package/lib-es/hw/actions/implementations.d.ts.map +1 -1
- package/lib-es/hw/actions/implementations.js +15 -9
- package/lib-es/hw/actions/implementations.js.map +1 -1
- package/lib-es/hw/connectAppEventMapper.d.ts.map +1 -1
- package/lib-es/hw/connectAppEventMapper.js +3 -3
- package/lib-es/hw/connectAppEventMapper.js.map +1 -1
- package/lib-es/market/hooks/useLargeMoverCurrencies.d.ts +1 -1
- package/lib-es/market/hooks/useMarketDataProvider.d.ts +2 -2
- package/lib-es/market/hooks/useMarketDataProvider.d.ts.map +1 -1
- package/lib-es/market/hooks/useMarketDataProvider.js +2 -5
- package/lib-es/market/hooks/useMarketDataProvider.js.map +1 -1
- package/lib-es/market/utils/currencyFormatter.d.ts +3 -4
- package/lib-es/market/utils/currencyFormatter.d.ts.map +1 -1
- package/lib-es/market/utils/currencyFormatter.js +3 -6
- package/lib-es/market/utils/currencyFormatter.js.map +1 -1
- package/lib-es/market/utils/queryKeys.d.ts +0 -1
- package/lib-es/market/utils/queryKeys.d.ts.map +1 -1
- package/lib-es/market/utils/queryKeys.js +0 -1
- package/lib-es/market/utils/queryKeys.js.map +1 -1
- package/lib-es/market/utils/types.d.ts +6 -8
- package/lib-es/market/utils/types.d.ts.map +1 -1
- package/lib-es/market/utils/types.js.map +1 -1
- package/lib-es/mock/fixtures/cryptoCurrencies.d.ts.map +1 -1
- package/lib-es/mock/fixtures/cryptoCurrencies.js +11 -2
- package/lib-es/mock/fixtures/cryptoCurrencies.js.map +1 -1
- package/lib-es/modularDrawer/__mocks__/currencies.mock.d.ts +1 -1
- package/lib-es/modularDrawer/__mocks__/currencies.mock.d.ts.map +1 -1
- package/lib-es/modularDrawer/__mocks__/currencies.mock.js +1 -1
- package/lib-es/modularDrawer/__mocks__/currencies.mock.js.map +1 -1
- package/lib-es/modularDrawer/utils/currencyUtils.d.ts +3 -3
- package/lib-es/modularDrawer/utils/currencyUtils.d.ts.map +1 -1
- package/lib-es/modularDrawer/utils/currencyUtils.js +8 -8
- package/lib-es/modularDrawer/utils/currencyUtils.js.map +1 -1
- package/lib-es/postOnboarding/hooks/usePostOnboardingHubState.d.ts.map +1 -1
- package/lib-es/postOnboarding/hooks/usePostOnboardingHubState.js +13 -4
- package/lib-es/postOnboarding/hooks/usePostOnboardingHubState.js.map +1 -1
- package/lib-es/postOnboarding/mock.d.ts +1 -0
- package/lib-es/postOnboarding/mock.d.ts.map +1 -1
- package/lib-es/postOnboarding/mock.js +2 -0
- package/lib-es/postOnboarding/mock.js.map +1 -1
- package/lib-es/postOnboarding/reducer.d.ts +16 -14
- package/lib-es/postOnboarding/reducer.d.ts.map +1 -1
- package/lib-es/transaction/index.d.ts +1 -1
- package/lib-es/transaction/index.d.ts.map +1 -1
- package/lib-es/transaction/index.js +2 -2
- package/lib-es/transaction/index.js.map +1 -1
- package/lib-es/utils/addressUtils.d.ts +15 -0
- package/lib-es/utils/addressUtils.d.ts.map +1 -0
- package/lib-es/utils/addressUtils.js +35 -0
- package/lib-es/utils/addressUtils.js.map +1 -0
- package/lib-es/wallet-api/ACRE/server.d.ts.map +1 -1
- package/lib-es/wallet-api/ACRE/server.js +19 -15
- package/lib-es/wallet-api/ACRE/server.js.map +1 -1
- package/lib-es/wallet-api/Exchange/server.d.ts.map +1 -1
- package/lib-es/wallet-api/Exchange/server.js +9 -6
- package/lib-es/wallet-api/Exchange/server.js.map +1 -1
- package/lib-es/wallet-api/logic.d.ts.map +1 -1
- package/lib-es/wallet-api/logic.js +26 -26
- package/lib-es/wallet-api/logic.js.map +1 -1
- package/lib-es/wallet-api/react.d.ts.map +1 -1
- package/lib-es/wallet-api/react.js +38 -30
- package/lib-es/wallet-api/react.js.map +1 -1
- package/lib-es/wallet-api/useDappLogic.d.ts.map +1 -1
- package/lib-es/wallet-api/useDappLogic.js +74 -58
- package/lib-es/wallet-api/useDappLogic.js.map +1 -1
- package/package.json +56 -52
- package/src/DataModel.test.ts +74 -24
- package/src/DataModel.ts +4 -4
- package/src/__tests__/accounts/groupPerDay.ts +182 -177
- package/src/__tests__/csvExport.ts +3 -0
- package/src/__tests__/migration/account-migration.ts +2 -2
- package/src/__tests__/test-helpers/bridge.ts +426 -358
- package/src/__tests__/test-helpers/setup.ts +7 -6
- package/src/account/serialization.test.ts +6 -6
- package/src/account/serialization.ts +2 -2
- package/src/api/ofacGeoBlockApi.ts +19 -0
- package/src/apps/config.ts +1 -0
- package/src/bot/engine.ts +5 -5
- package/src/bridge/cache.test.ts +2 -0
- package/src/bridge/crypto-assets/index.test.ts +3 -9
- package/src/bridge/crypto-assets/index.ts +1 -1
- package/src/bridge/generic-alpaca/alpaca/network/network-alpaca.ts +3 -3
- package/src/bridge/generic-alpaca/createTransaction.ts +6 -1
- package/src/bridge/generic-alpaca/getTransactionStatus.ts +1 -0
- package/src/bridge/generic-alpaca/prepareTransaction.ts +36 -41
- package/src/bridge/generic-alpaca/signOperation.ts +10 -4
- package/src/bridge/generic-alpaca/signer/Eth.ts +4 -2
- package/src/bridge/generic-alpaca/tests/prepareTransaction.test.ts +29 -76
- package/src/bridge/generic-alpaca/tests/signOperation.test.ts +10 -2
- package/src/bridge/generic-alpaca/types.ts +80 -2
- package/src/bridge/generic-alpaca/utils.test.ts +58 -2
- package/src/bridge/generic-alpaca/utils.ts +151 -10
- package/src/bridge/index.ts +2 -2
- package/src/bridge/useBridgeTransaction.test.ts +9 -6
- package/src/currencies/cryptoIcons.test.ts +10 -5
- package/src/currencies/index.ts +0 -3
- package/src/currencies/sortByMarketcap.test.ts +4 -1
- package/src/dada-client/README.md +38 -0
- package/src/dada-client/__mocks__/assets.mock.ts +264 -0
- package/src/dada-client/hooks/__tests__/useLazyLedgerCurrency.test.ts +155 -0
- package/src/dada-client/hooks/useAssetsData.ts +14 -9
- package/src/dada-client/hooks/useLazyLedgerCurrency.ts +46 -0
- package/src/dada-client/index.ts +1 -0
- package/src/dada-client/state-manager/api.ts +1 -1
- package/src/dada-client/utils/__test__/currencySelection.test.ts +16 -0
- package/src/dada-client/utils/currencySelection.ts +33 -0
- package/src/deposit/deposit.integration.test.ts +15 -0
- package/src/deposit/deposit.test.ts +60 -40
- package/src/deposit/helper.ts +4 -8
- package/src/domain/getTokensWithFunds.test.ts +4 -0
- package/src/e2e/data/deviceLabelsData.ts +2 -1
- package/src/e2e/enum/DeviceLabels.ts +4 -0
- package/src/e2e/speculos.ts +26 -6
- package/src/e2e/speculosAppVersion.ts +1 -0
- package/src/families/aptos/__snapshots__/bridge.integration.test.ts.snap +12 -12
- package/src/families/bitcoin/__snapshots__/bridge.integration.test.ts.snap +1482 -843
- package/src/families/bitcoin/satstack.test.ts +33 -20
- package/src/families/cosmos/datasets/__snapshots__/babylon.integration.test.ts.snap +1 -1
- package/src/families/cosmos/datasets/__snapshots__/coreum.integration.test.ts.snap +4 -4
- package/src/families/cosmos/datasets/__snapshots__/cosmos.integration.test.ts.snap +251 -209
- package/src/families/cosmos/datasets/coreum.ts +2 -1
- package/src/families/hedera/__snapshots__/bridge.integration.test.ts.snap +675 -37
- package/src/families/multiversx/__snapshots__/bridge.integration.test.ts.snap +3 -3
- package/src/families/near/config.ts +1 -0
- package/src/families/polkadot/__snapshots__/bridge.integration.test.ts.snap +34 -34
- package/src/families/solana/__snapshots__/bridge.integration.test.ts.snap +3 -3
- package/src/families/stacks/__snapshots__/bridge.integration.test.ts.snap +10 -10
- package/src/families/stellar/__snapshots__/bridge.integration.test.ts.snap +1183 -625
- package/src/families/sui/__snapshots__/bridge.integration.test.ts.snap +428 -0
- package/src/families/tron/data.mock.ts +32 -16
- package/src/families/tron/react.test.ts +16 -4
- package/src/featureFlags/defaultFeatures.ts +3 -4
- package/src/featureFlags/stakePrograms/index.ts +14 -0
- package/src/hw/actions/implementations.ts +22 -11
- package/src/hw/connectAppEventMapper.ts +2 -4
- package/src/market/hooks/useMarketDataProvider.ts +4 -8
- package/src/market/utils/currencyFormatter.ts +4 -18
- package/src/market/utils/queryKeys.ts +0 -1
- package/src/market/utils/types.ts +6 -8
- package/src/mock/fixtures/cryptoCurrencies.ts +11 -2
- package/src/modularDrawer/__mocks__/currencies.mock.ts +1 -1
- package/src/modularDrawer/utils/__tests__/currencyUtils.test.ts +10 -10
- package/src/modularDrawer/utils/currencyUtils.ts +11 -10
- package/src/platform/serializers.test.ts +2 -2
- package/src/postOnboarding/hooks/usePostOnboardingHubState.test.ts +30 -3
- package/src/postOnboarding/hooks/usePostOnboardingHubState.ts +20 -6
- package/src/postOnboarding/mock.ts +2 -0
- package/src/transaction/index.ts +2 -2
- package/src/utils/__tests__/addressUtils.test.ts +229 -0
- package/src/utils/__tests__/getAccountTuplesForCurrency.test.ts +15 -4
- package/src/utils/addressUtils.ts +40 -0
- package/src/wallet-api/ACRE/server.test.ts +11 -8
- package/src/wallet-api/ACRE/server.ts +25 -22
- package/src/wallet-api/Exchange/server.ts +11 -8
- package/src/wallet-api/logic.test.ts +4 -0
- package/src/wallet-api/logic.ts +28 -32
- package/src/wallet-api/react.ts +37 -34
- package/src/wallet-api/useDappLogic.ts +103 -82
- package/lib/hooks/useOFACGeoBlockCheck.d.ts +0 -8
- package/lib/hooks/useOFACGeoBlockCheck.d.ts.map +0 -1
- package/lib/hooks/useOFACGeoBlockCheck.js +0 -32
- package/lib/hooks/useOFACGeoBlockCheck.js.map +0 -1
- package/lib-es/hooks/useOFACGeoBlockCheck.d.ts +0 -8
- package/lib-es/hooks/useOFACGeoBlockCheck.d.ts.map +0 -1
- package/lib-es/hooks/useOFACGeoBlockCheck.js +0 -28
- package/lib-es/hooks/useOFACGeoBlockCheck.js.map +0 -1
- package/src/hooks/useOFACGeoBlockCheck.ts +0 -37
|
@@ -0,0 +1,428 @@
|
|
|
1
|
+
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
+
|
|
3
|
+
exports[`sui currency bridge scanAccounts sui seed 1 1`] = `
|
|
4
|
+
[
|
|
5
|
+
{
|
|
6
|
+
"balance": "102696240",
|
|
7
|
+
"currencyId": "sui",
|
|
8
|
+
"derivationMode": "sui",
|
|
9
|
+
"freshAddress": "0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
10
|
+
"freshAddressPath": "44'/784'/0'/0'/0'",
|
|
11
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
12
|
+
"index": 0,
|
|
13
|
+
"operationsCount": 21,
|
|
14
|
+
"pendingOperations": [],
|
|
15
|
+
"seedIdentifier": "e5fb8c817b97e9e9aec677b9e822e8a60c7471624f36b701c94560b88195a8e7",
|
|
16
|
+
"spendableBalance": "102696240",
|
|
17
|
+
"subAccounts": [],
|
|
18
|
+
"suiResources": {},
|
|
19
|
+
"swapHistory": [],
|
|
20
|
+
"syncHash": "6p9XjoTwZ81o9xTkodgswDbETbrN5Lkv1b2shBN4p99s",
|
|
21
|
+
"used": true,
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
"balance": "0",
|
|
25
|
+
"currencyId": "sui",
|
|
26
|
+
"derivationMode": "sui",
|
|
27
|
+
"freshAddress": "0xba7080172a6d957b9ed2e3eb643529860be963cf4af896fb84f1cde00f46b561",
|
|
28
|
+
"freshAddressPath": "44'/784'/1'/0'/0'",
|
|
29
|
+
"id": "js:2:sui:0xba7080172a6d957b9ed2e3eb643529860be963cf4af896fb84f1cde00f46b561:sui",
|
|
30
|
+
"index": 1,
|
|
31
|
+
"operationsCount": 0,
|
|
32
|
+
"pendingOperations": [],
|
|
33
|
+
"seedIdentifier": "e5fb8c817b97e9e9aec677b9e822e8a60c7471624f36b701c94560b88195a8e7",
|
|
34
|
+
"spendableBalance": "0",
|
|
35
|
+
"subAccounts": [],
|
|
36
|
+
"suiResources": {},
|
|
37
|
+
"swapHistory": [],
|
|
38
|
+
"syncHash": undefined,
|
|
39
|
+
"used": false,
|
|
40
|
+
},
|
|
41
|
+
]
|
|
42
|
+
`;
|
|
43
|
+
|
|
44
|
+
exports[`sui currency bridge scanAccounts sui seed 1 2`] = `
|
|
45
|
+
[
|
|
46
|
+
[
|
|
47
|
+
{
|
|
48
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
49
|
+
"blockHash": "2A4xTFFpdUYtW92GBSSLALJYymGjEViAiKcyUdUV7u9F",
|
|
50
|
+
"blockHeight": 5,
|
|
51
|
+
"extra": {},
|
|
52
|
+
"fee": "759760",
|
|
53
|
+
"hasFailed": false,
|
|
54
|
+
"hash": "2A4xTFFpdUYtW92GBSSLALJYymGjEViAiKcyUdUV7u9F",
|
|
55
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-2A4xTFFpdUYtW92GBSSLALJYymGjEViAiKcyUdUV7u9F-IN",
|
|
56
|
+
"recipients": [
|
|
57
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
58
|
+
],
|
|
59
|
+
"senders": [
|
|
60
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
61
|
+
],
|
|
62
|
+
"type": "IN",
|
|
63
|
+
"value": "19745060210",
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
67
|
+
"blockHash": "2U4dyfZTn5FwQJPWt5DKhGsbVewFtbAA43obHdFgyd1W",
|
|
68
|
+
"blockHeight": 5,
|
|
69
|
+
"extra": {},
|
|
70
|
+
"fee": "759760",
|
|
71
|
+
"hasFailed": false,
|
|
72
|
+
"hash": "2U4dyfZTn5FwQJPWt5DKhGsbVewFtbAA43obHdFgyd1W",
|
|
73
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-2U4dyfZTn5FwQJPWt5DKhGsbVewFtbAA43obHdFgyd1W-OUT",
|
|
74
|
+
"recipients": [
|
|
75
|
+
"0x294f9f370f4ed53d53702b8de1b4f0d73980806d7148ad64edc0be80192f5107",
|
|
76
|
+
],
|
|
77
|
+
"senders": [
|
|
78
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
79
|
+
],
|
|
80
|
+
"type": "OUT",
|
|
81
|
+
"value": "18402932460",
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
85
|
+
"blockHash": "3ZE1Kfo9zohdyRLA5fzcoULeYEhnYJXiEpudGrvGe3w5",
|
|
86
|
+
"blockHeight": 5,
|
|
87
|
+
"extra": {},
|
|
88
|
+
"fee": "-217360",
|
|
89
|
+
"hasFailed": false,
|
|
90
|
+
"hash": "3ZE1Kfo9zohdyRLA5fzcoULeYEhnYJXiEpudGrvGe3w5",
|
|
91
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-3ZE1Kfo9zohdyRLA5fzcoULeYEhnYJXiEpudGrvGe3w5-IN",
|
|
92
|
+
"recipients": [
|
|
93
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
94
|
+
],
|
|
95
|
+
"senders": [
|
|
96
|
+
"0x6e143fe0a8ca010a86580dafac44298e5b1b7d73efc345356a59a15f0d7824f0",
|
|
97
|
+
],
|
|
98
|
+
"type": "IN",
|
|
99
|
+
"value": "21600000000",
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
103
|
+
"blockHash": "4ykxTJUrTEJswRZWafgN4m3GgeXavfPNJuBzn8p93bHo",
|
|
104
|
+
"blockHeight": 5,
|
|
105
|
+
"extra": {},
|
|
106
|
+
"fee": "759760",
|
|
107
|
+
"hasFailed": false,
|
|
108
|
+
"hash": "4ykxTJUrTEJswRZWafgN4m3GgeXavfPNJuBzn8p93bHo",
|
|
109
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-4ykxTJUrTEJswRZWafgN4m3GgeXavfPNJuBzn8p93bHo-OUT",
|
|
110
|
+
"recipients": [
|
|
111
|
+
"0x9b3a01bb3b8c86bdeab6afc28b19390fab898131d40696bcee643db14d51b156",
|
|
112
|
+
],
|
|
113
|
+
"senders": [
|
|
114
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
115
|
+
],
|
|
116
|
+
"type": "OUT",
|
|
117
|
+
"value": "20195822240",
|
|
118
|
+
},
|
|
119
|
+
{
|
|
120
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
121
|
+
"blockHash": "6p9XjoTwZ81o9xTkodgswDbETbrN5Lkv1b2shBN4p99s",
|
|
122
|
+
"blockHeight": 5,
|
|
123
|
+
"extra": {},
|
|
124
|
+
"fee": "759760",
|
|
125
|
+
"hasFailed": false,
|
|
126
|
+
"hash": "6p9XjoTwZ81o9xTkodgswDbETbrN5Lkv1b2shBN4p99s",
|
|
127
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-6p9XjoTwZ81o9xTkodgswDbETbrN5Lkv1b2shBN4p99s-IN",
|
|
128
|
+
"recipients": [
|
|
129
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
130
|
+
],
|
|
131
|
+
"senders": [
|
|
132
|
+
"0x9b3a01bb3b8c86bdeab6afc28b19390fab898131d40696bcee643db14d51b156",
|
|
133
|
+
],
|
|
134
|
+
"type": "IN",
|
|
135
|
+
"value": "100000000",
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
139
|
+
"blockHash": "7bsW7Aj5S6iQi9RxSdjaCPkwZcBbuUAfGAXFb5Ydn5Ag",
|
|
140
|
+
"blockHeight": 5,
|
|
141
|
+
"extra": {},
|
|
142
|
+
"fee": "759760",
|
|
143
|
+
"hasFailed": false,
|
|
144
|
+
"hash": "7bsW7Aj5S6iQi9RxSdjaCPkwZcBbuUAfGAXFb5Ydn5Ag",
|
|
145
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-7bsW7Aj5S6iQi9RxSdjaCPkwZcBbuUAfGAXFb5Ydn5Ag-OUT",
|
|
146
|
+
"recipients": [
|
|
147
|
+
"0x0bb481f4ad94c24ec7e9ac4c04a55c12fcc64fd0009c7e4db49471defba84c86",
|
|
148
|
+
],
|
|
149
|
+
"senders": [
|
|
150
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
151
|
+
],
|
|
152
|
+
"type": "OUT",
|
|
153
|
+
"value": "21553456960",
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
157
|
+
"blockHash": "7pQVzNm9eCK974n4bzLnVte2Rc8EmMUb9ehvfpsa3unC",
|
|
158
|
+
"blockHeight": 5,
|
|
159
|
+
"extra": {},
|
|
160
|
+
"fee": "1737880",
|
|
161
|
+
"hasFailed": false,
|
|
162
|
+
"hash": "7pQVzNm9eCK974n4bzLnVte2Rc8EmMUb9ehvfpsa3unC",
|
|
163
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-7pQVzNm9eCK974n4bzLnVte2Rc8EmMUb9ehvfpsa3unC-IN",
|
|
164
|
+
"recipients": [
|
|
165
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
166
|
+
],
|
|
167
|
+
"senders": [
|
|
168
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
169
|
+
],
|
|
170
|
+
"type": "IN",
|
|
171
|
+
"value": "13918448260",
|
|
172
|
+
},
|
|
173
|
+
{
|
|
174
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
175
|
+
"blockHash": "7YAS8kkE3piqopdWeQwHmAp3MRgumS8KuqFxvxQpt8oX",
|
|
176
|
+
"blockHeight": 5,
|
|
177
|
+
"extra": {},
|
|
178
|
+
"fee": "759760",
|
|
179
|
+
"hasFailed": false,
|
|
180
|
+
"hash": "7YAS8kkE3piqopdWeQwHmAp3MRgumS8KuqFxvxQpt8oX",
|
|
181
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-7YAS8kkE3piqopdWeQwHmAp3MRgumS8KuqFxvxQpt8oX-IN",
|
|
182
|
+
"recipients": [
|
|
183
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
184
|
+
],
|
|
185
|
+
"senders": [
|
|
186
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
187
|
+
],
|
|
188
|
+
"type": "IN",
|
|
189
|
+
"value": "18402932390",
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
193
|
+
"blockHash": "9FZcUokehQA93FZo8pjHyqCFzTFjaMF7ZNE6Sa1ZPXDW",
|
|
194
|
+
"blockHeight": 5,
|
|
195
|
+
"extra": {},
|
|
196
|
+
"fee": "760760",
|
|
197
|
+
"hasFailed": false,
|
|
198
|
+
"hash": "9FZcUokehQA93FZo8pjHyqCFzTFjaMF7ZNE6Sa1ZPXDW",
|
|
199
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-9FZcUokehQA93FZo8pjHyqCFzTFjaMF7ZNE6Sa1ZPXDW-OUT",
|
|
200
|
+
"recipients": [
|
|
201
|
+
"0x6e143fe0a8ca010a86580dafac44298e5b1b7d73efc345356a59a15f0d7824f0",
|
|
202
|
+
],
|
|
203
|
+
"senders": [
|
|
204
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
205
|
+
],
|
|
206
|
+
"type": "OUT",
|
|
207
|
+
"value": "21538185960",
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
211
|
+
"blockHash": "Bgdvga7F6755F6yiTN4mSHwTpHTTDrBN5rLzChzvfbUB",
|
|
212
|
+
"blockHeight": 5,
|
|
213
|
+
"extra": {},
|
|
214
|
+
"fee": "-7065200",
|
|
215
|
+
"hasFailed": false,
|
|
216
|
+
"hash": "Bgdvga7F6755F6yiTN4mSHwTpHTTDrBN5rLzChzvfbUB",
|
|
217
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-Bgdvga7F6755F6yiTN4mSHwTpHTTDrBN5rLzChzvfbUB-IN",
|
|
218
|
+
"recipients": [
|
|
219
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
220
|
+
],
|
|
221
|
+
"senders": [
|
|
222
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
223
|
+
],
|
|
224
|
+
"type": "IN",
|
|
225
|
+
"value": "19566792820",
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
229
|
+
"blockHash": "Bs7jiagEu69RpZt7By8PgNasLZhMfPbuD79yRTqrszag",
|
|
230
|
+
"blockHeight": 5,
|
|
231
|
+
"extra": {},
|
|
232
|
+
"fee": "759760",
|
|
233
|
+
"hasFailed": false,
|
|
234
|
+
"hash": "Bs7jiagEu69RpZt7By8PgNasLZhMfPbuD79yRTqrszag",
|
|
235
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-Bs7jiagEu69RpZt7By8PgNasLZhMfPbuD79yRTqrszag-OUT",
|
|
236
|
+
"recipients": [
|
|
237
|
+
"0xa1c80990a70a9674556a97838fa3d5814cd1f064c778be019804b19d9f01c8ec",
|
|
238
|
+
],
|
|
239
|
+
"senders": [
|
|
240
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
241
|
+
],
|
|
242
|
+
"type": "OUT",
|
|
243
|
+
"value": "24275847660",
|
|
244
|
+
},
|
|
245
|
+
{
|
|
246
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
247
|
+
"blockHash": "Cj6ghzCygwqpwpcxeG2TNKdtXkFAEd6VSVmnMcaqnA25",
|
|
248
|
+
"blockHeight": 5,
|
|
249
|
+
"extra": {},
|
|
250
|
+
"fee": "1737880",
|
|
251
|
+
"hasFailed": false,
|
|
252
|
+
"hash": "Cj6ghzCygwqpwpcxeG2TNKdtXkFAEd6VSVmnMcaqnA25",
|
|
253
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-Cj6ghzCygwqpwpcxeG2TNKdtXkFAEd6VSVmnMcaqnA25-IN",
|
|
254
|
+
"recipients": [
|
|
255
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
256
|
+
],
|
|
257
|
+
"senders": [
|
|
258
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
259
|
+
],
|
|
260
|
+
"type": "IN",
|
|
261
|
+
"value": "16941487270",
|
|
262
|
+
},
|
|
263
|
+
{
|
|
264
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
265
|
+
"blockHash": "CqPV2f1f1fbNC1LHbbZxJTNYHPZrzn1KycB6rCFpMpjX",
|
|
266
|
+
"blockHeight": 5,
|
|
267
|
+
"extra": {},
|
|
268
|
+
"fee": "1738880",
|
|
269
|
+
"hasFailed": false,
|
|
270
|
+
"hash": "CqPV2f1f1fbNC1LHbbZxJTNYHPZrzn1KycB6rCFpMpjX",
|
|
271
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-CqPV2f1f1fbNC1LHbbZxJTNYHPZrzn1KycB6rCFpMpjX-OUT",
|
|
272
|
+
"recipients": [
|
|
273
|
+
"0x680dbfb4bd33c276b0192126fc79ddddfbb551e83ddf76405409209ceae30717",
|
|
274
|
+
],
|
|
275
|
+
"senders": [
|
|
276
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
277
|
+
],
|
|
278
|
+
"type": "OUT",
|
|
279
|
+
"value": "9001738880",
|
|
280
|
+
},
|
|
281
|
+
{
|
|
282
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
283
|
+
"blockHash": "DhXKA85ru8y2kAXpaEbzhMJD2nrzKNBw4Lfxq2EmGxqt",
|
|
284
|
+
"blockHeight": 5,
|
|
285
|
+
"extra": {},
|
|
286
|
+
"fee": "759760",
|
|
287
|
+
"hasFailed": false,
|
|
288
|
+
"hash": "DhXKA85ru8y2kAXpaEbzhMJD2nrzKNBw4Lfxq2EmGxqt",
|
|
289
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-DhXKA85ru8y2kAXpaEbzhMJD2nrzKNBw4Lfxq2EmGxqt-OUT",
|
|
290
|
+
"recipients": [
|
|
291
|
+
"0xdb3b3f123377fd6e4d93d5f1b3dfb9b004589ee5aeabfd54c382b11fedec2f57",
|
|
292
|
+
],
|
|
293
|
+
"senders": [
|
|
294
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
295
|
+
],
|
|
296
|
+
"type": "OUT",
|
|
297
|
+
"value": "9000759760",
|
|
298
|
+
},
|
|
299
|
+
{
|
|
300
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
301
|
+
"blockHash": "EF1ro2sgEzo8LnPhWncV4pcUxKEbfkpTLekBowDZ5PCm",
|
|
302
|
+
"blockHeight": 5,
|
|
303
|
+
"extra": {},
|
|
304
|
+
"fee": "759760",
|
|
305
|
+
"hasFailed": false,
|
|
306
|
+
"hash": "EF1ro2sgEzo8LnPhWncV4pcUxKEbfkpTLekBowDZ5PCm",
|
|
307
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-EF1ro2sgEzo8LnPhWncV4pcUxKEbfkpTLekBowDZ5PCm-OUT",
|
|
308
|
+
"recipients": [
|
|
309
|
+
"0xbc597145c42d720c5203425c3bb1195b5ade319d30f8a58a07c94090709ed5fb",
|
|
310
|
+
],
|
|
311
|
+
"senders": [
|
|
312
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
313
|
+
],
|
|
314
|
+
"type": "OUT",
|
|
315
|
+
"value": "21859175760",
|
|
316
|
+
},
|
|
317
|
+
{
|
|
318
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
319
|
+
"blockHash": "EhsMAo4u2GSg5y6TEAx1vnUPibzBpUWJb4yQcrFJC4Ux",
|
|
320
|
+
"blockHeight": 5,
|
|
321
|
+
"extra": {},
|
|
322
|
+
"fee": "760760",
|
|
323
|
+
"hasFailed": false,
|
|
324
|
+
"hash": "EhsMAo4u2GSg5y6TEAx1vnUPibzBpUWJb4yQcrFJC4Ux",
|
|
325
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-EhsMAo4u2GSg5y6TEAx1vnUPibzBpUWJb4yQcrFJC4Ux-IN",
|
|
326
|
+
"recipients": [
|
|
327
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
328
|
+
],
|
|
329
|
+
"senders": [
|
|
330
|
+
"0x9b3a01bb3b8c86bdeab6afc28b19390fab898131d40696bcee643db14d51b156",
|
|
331
|
+
],
|
|
332
|
+
"type": "IN",
|
|
333
|
+
"value": "15000000000",
|
|
334
|
+
},
|
|
335
|
+
{
|
|
336
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
337
|
+
"blockHash": "FQ4Wj6ToRG7GgvCSs98L9YTUQN6pzGZLi2y49SUTFbNs",
|
|
338
|
+
"blockHeight": 5,
|
|
339
|
+
"extra": {},
|
|
340
|
+
"fee": "-218360",
|
|
341
|
+
"hasFailed": false,
|
|
342
|
+
"hash": "FQ4Wj6ToRG7GgvCSs98L9YTUQN6pzGZLi2y49SUTFbNs",
|
|
343
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-FQ4Wj6ToRG7GgvCSs98L9YTUQN6pzGZLi2y49SUTFbNs-IN",
|
|
344
|
+
"recipients": [
|
|
345
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
346
|
+
],
|
|
347
|
+
"senders": [
|
|
348
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
349
|
+
],
|
|
350
|
+
"type": "IN",
|
|
351
|
+
"value": "24275847710",
|
|
352
|
+
},
|
|
353
|
+
{
|
|
354
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
355
|
+
"blockHash": "FWftMWxSbk5ZfpVpAW3bPmP2wZjHG6Ei3XD6dBC16bJ1",
|
|
356
|
+
"blockHeight": 5,
|
|
357
|
+
"extra": {},
|
|
358
|
+
"fee": "759760",
|
|
359
|
+
"hasFailed": false,
|
|
360
|
+
"hash": "FWftMWxSbk5ZfpVpAW3bPmP2wZjHG6Ei3XD6dBC16bJ1",
|
|
361
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-FWftMWxSbk5ZfpVpAW3bPmP2wZjHG6Ei3XD6dBC16bJ1-OUT",
|
|
362
|
+
"recipients": [
|
|
363
|
+
"0x02600aefb4cc6df7051058f0c77d39f19927c16c083b293b8bc8383f1ff868ab",
|
|
364
|
+
],
|
|
365
|
+
"senders": [
|
|
366
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
367
|
+
],
|
|
368
|
+
"type": "OUT",
|
|
369
|
+
"value": "19745060160",
|
|
370
|
+
},
|
|
371
|
+
{
|
|
372
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
373
|
+
"blockHash": "FwkKBfz8vqKLrPNjqWUz26PamUehgMKkFkYaoEMxuCsz",
|
|
374
|
+
"blockHeight": 5,
|
|
375
|
+
"extra": {},
|
|
376
|
+
"fee": "1738880",
|
|
377
|
+
"hasFailed": false,
|
|
378
|
+
"hash": "FwkKBfz8vqKLrPNjqWUz26PamUehgMKkFkYaoEMxuCsz",
|
|
379
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-FwkKBfz8vqKLrPNjqWUz26PamUehgMKkFkYaoEMxuCsz-IN",
|
|
380
|
+
"recipients": [
|
|
381
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
382
|
+
],
|
|
383
|
+
"senders": [
|
|
384
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
385
|
+
],
|
|
386
|
+
"type": "IN",
|
|
387
|
+
"value": "15542622080",
|
|
388
|
+
},
|
|
389
|
+
{
|
|
390
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
391
|
+
"blockHash": "GSDowHDQQ7tyQhwbqBhW6awKFxwjirhWkUBbWWyDdiWY",
|
|
392
|
+
"blockHeight": 5,
|
|
393
|
+
"extra": {},
|
|
394
|
+
"fee": "759760",
|
|
395
|
+
"hasFailed": false,
|
|
396
|
+
"hash": "GSDowHDQQ7tyQhwbqBhW6awKFxwjirhWkUBbWWyDdiWY",
|
|
397
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-GSDowHDQQ7tyQhwbqBhW6awKFxwjirhWkUBbWWyDdiWY-IN",
|
|
398
|
+
"recipients": [
|
|
399
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
400
|
+
],
|
|
401
|
+
"senders": [
|
|
402
|
+
"0x861284f9839a0334f8bbdbc4d9b254769ca74a5139636de9785ab2b7814dca9c",
|
|
403
|
+
],
|
|
404
|
+
"type": "IN",
|
|
405
|
+
"value": "22583245100",
|
|
406
|
+
},
|
|
407
|
+
{
|
|
408
|
+
"accountId": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui",
|
|
409
|
+
"blockHash": "XWS3cmmihyiReNHY6k24ucti8YzKdMQAAzPJbnLx9x6",
|
|
410
|
+
"blockHeight": 5,
|
|
411
|
+
"extra": {},
|
|
412
|
+
"fee": "759760",
|
|
413
|
+
"hasFailed": false,
|
|
414
|
+
"hash": "XWS3cmmihyiReNHY6k24ucti8YzKdMQAAzPJbnLx9x6",
|
|
415
|
+
"id": "js:2:sui:0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435:sui-XWS3cmmihyiReNHY6k24ucti8YzKdMQAAzPJbnLx9x6-OUT",
|
|
416
|
+
"recipients": [
|
|
417
|
+
"0xb194c1eeab00f044e5c64df4423795f2cc8a6cf804cb9280590711096660c3d4",
|
|
418
|
+
],
|
|
419
|
+
"senders": [
|
|
420
|
+
"0x117527fdcf2f5f6e82fa499c0398def2643550d63f7e8311245d75f4635f0435",
|
|
421
|
+
],
|
|
422
|
+
"type": "OUT",
|
|
423
|
+
"value": "22000759760",
|
|
424
|
+
},
|
|
425
|
+
],
|
|
426
|
+
[],
|
|
427
|
+
]
|
|
428
|
+
`;
|
|
@@ -11,12 +11,13 @@ export const __LAST_VOTING_DATE__ = new Date(Date.now() - 6 * 60 * 60 * 1000);
|
|
|
11
11
|
setCryptoAssetsStoreForCoinFramework({
|
|
12
12
|
findTokenById: (_: string) => undefined,
|
|
13
13
|
findTokenByAddressInCurrency: (_: string, __: string) => undefined,
|
|
14
|
+
getTokensSyncHash: (_: string) => Promise.resolve("test_hash"),
|
|
14
15
|
} as unknown as CryptoAssetsStore);
|
|
15
16
|
|
|
16
|
-
|
|
17
|
+
const mockAccountRaw = {
|
|
17
18
|
id: "js:2:tron:TRON_ID:",
|
|
18
19
|
seedIdentifier: "TRON_ID",
|
|
19
|
-
derivationMode: "",
|
|
20
|
+
derivationMode: "" as any,
|
|
20
21
|
index: 0,
|
|
21
22
|
freshAddress: "TRON_ID",
|
|
22
23
|
freshAddressPath: "44'/195'/0'/0/0",
|
|
@@ -239,7 +240,6 @@ export const mockAccount = fromAccountRaw({
|
|
|
239
240
|
currencyId: "tron",
|
|
240
241
|
lastSyncDate: "2020-03-18T09:22:46.747Z",
|
|
241
242
|
subAccounts: [],
|
|
242
|
-
// @ts-expect-error wat
|
|
243
243
|
tronResources: {
|
|
244
244
|
frozen: { bandwidth: null, energy: null },
|
|
245
245
|
legacyFrozen: {
|
|
@@ -279,11 +279,17 @@ export const mockAccount = fromAccountRaw({
|
|
|
279
279
|
lastWithdrawnRewardDate: __NEXT_REWARD_DATE__.toISOString(),
|
|
280
280
|
lastVotedDate: __LAST_VOTING_DATE__.toISOString(),
|
|
281
281
|
},
|
|
282
|
-
}
|
|
283
|
-
|
|
282
|
+
};
|
|
283
|
+
|
|
284
|
+
// Async function to create mock accounts
|
|
285
|
+
export async function createMockAccount(): Promise<TronAccount> {
|
|
286
|
+
return (await fromAccountRaw(mockAccountRaw as any)) as TronAccount;
|
|
287
|
+
}
|
|
288
|
+
|
|
289
|
+
const mockAccountNoRewardRaw = {
|
|
284
290
|
id: "js:2:tron:TRON_ID:",
|
|
285
291
|
seedIdentifier: "TRON_ID",
|
|
286
|
-
derivationMode: "",
|
|
292
|
+
derivationMode: "" as any,
|
|
287
293
|
index: 0,
|
|
288
294
|
freshAddress: "TRON_ID",
|
|
289
295
|
freshAddressPath: "44'/195'/0'/0/0",
|
|
@@ -461,7 +467,6 @@ export const mockAccountNoReward = fromAccountRaw({
|
|
|
461
467
|
currencyId: "tron",
|
|
462
468
|
lastSyncDate: "2020-03-18T09:22:46.747Z",
|
|
463
469
|
subAccounts: [],
|
|
464
|
-
// @ts-expect-error wat
|
|
465
470
|
tronResources: {
|
|
466
471
|
frozen: { bandwidth: null, energy: null },
|
|
467
472
|
unFrozen: {
|
|
@@ -502,11 +507,16 @@ export const mockAccountNoReward = fromAccountRaw({
|
|
|
502
507
|
lastWithdrawnRewardDate: null,
|
|
503
508
|
lastVotedDate: "2020-03-09T08:44:39.000Z",
|
|
504
509
|
},
|
|
505
|
-
}
|
|
506
|
-
|
|
510
|
+
};
|
|
511
|
+
|
|
512
|
+
export async function createMockAccountNoReward(): Promise<TronAccount> {
|
|
513
|
+
return (await fromAccountRaw(mockAccountNoRewardRaw as any)) as TronAccount;
|
|
514
|
+
}
|
|
515
|
+
|
|
516
|
+
const mockAccountNoVoteRaw = {
|
|
507
517
|
id: "js:2:tron:TRON_ID:",
|
|
508
518
|
seedIdentifier: "TRON_ID",
|
|
509
|
-
derivationMode: "",
|
|
519
|
+
derivationMode: "" as any,
|
|
510
520
|
index: 0,
|
|
511
521
|
freshAddress: "TRON_ID",
|
|
512
522
|
freshAddressPath: "44'/195'/0'/0/0",
|
|
@@ -632,7 +642,6 @@ export const mockAccountNoVote = fromAccountRaw({
|
|
|
632
642
|
currencyId: "tron",
|
|
633
643
|
lastSyncDate: "2020-03-18T09:22:46.747Z",
|
|
634
644
|
subAccounts: [],
|
|
635
|
-
// @ts-expect-error wat
|
|
636
645
|
tronResources: {
|
|
637
646
|
frozen: {
|
|
638
647
|
bandwidth: null,
|
|
@@ -675,21 +684,24 @@ export const mockAccountNoVote = fromAccountRaw({
|
|
|
675
684
|
lastWithdrawnRewardDate: null,
|
|
676
685
|
lastVotedDate: null,
|
|
677
686
|
},
|
|
678
|
-
}
|
|
687
|
+
};
|
|
688
|
+
|
|
689
|
+
export async function createMockAccountNoVote(): Promise<TronAccount> {
|
|
690
|
+
return (await fromAccountRaw(mockAccountNoVoteRaw as any)) as TronAccount;
|
|
691
|
+
}
|
|
679
692
|
|
|
680
|
-
|
|
693
|
+
const mockAccountV2Raw = {
|
|
681
694
|
id: "js:2:tron:TRON_ID:",
|
|
682
695
|
balance: "859005207",
|
|
683
696
|
spendableBalance: "252128207",
|
|
684
697
|
seedIdentifier: "TRON_ID",
|
|
685
|
-
derivationMode: "",
|
|
698
|
+
derivationMode: "" as any,
|
|
686
699
|
index: 0,
|
|
687
700
|
freshAddress: "TRON_ID",
|
|
688
701
|
freshAddressPath: "44'/195'/0'/0/0",
|
|
689
702
|
subAccounts: [],
|
|
690
703
|
name: "Tron 2",
|
|
691
704
|
pendingOperations: [],
|
|
692
|
-
// @ts-expect-error wat
|
|
693
705
|
tronResources: {
|
|
694
706
|
energy: "417",
|
|
695
707
|
bandwidth: { freeUsed: "0", freeLimit: "600", gainedUsed: "0", gainedLimit: "584" },
|
|
@@ -2216,4 +2228,8 @@ export const mockAccountV2 = fromAccountRaw({
|
|
|
2216
2228
|
hasFailed: false,
|
|
2217
2229
|
},
|
|
2218
2230
|
],
|
|
2219
|
-
}
|
|
2231
|
+
};
|
|
2232
|
+
|
|
2233
|
+
export async function createMockAccountV2(): Promise<TronAccount> {
|
|
2234
|
+
return (await fromAccountRaw(mockAccountV2Raw as any)) as TronAccount;
|
|
2235
|
+
}
|
|
@@ -16,10 +16,10 @@ import {
|
|
|
16
16
|
import {
|
|
17
17
|
__NEXT_REWARD_DATE__,
|
|
18
18
|
__LAST_VOTING_DATE__,
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
createMockAccount,
|
|
20
|
+
createMockAccountNoReward,
|
|
21
|
+
createMockAccountNoVote,
|
|
22
|
+
createMockAccountV2,
|
|
23
23
|
} from "./data.mock";
|
|
24
24
|
import superRepresentatives from "@ledgerhq/coin-tron/network/superRepresentativesData.mock";
|
|
25
25
|
|
|
@@ -44,6 +44,18 @@ jest.mock("@ledgerhq/coin-tron/logic/utils", () => {
|
|
|
44
44
|
};
|
|
45
45
|
});
|
|
46
46
|
|
|
47
|
+
let mockAccount: Awaited<ReturnType<typeof createMockAccount>>;
|
|
48
|
+
let mockAccountNoReward: Awaited<ReturnType<typeof createMockAccountNoReward>>;
|
|
49
|
+
let mockAccountNoVote: Awaited<ReturnType<typeof createMockAccountNoVote>>;
|
|
50
|
+
let mockAccountV2: Awaited<ReturnType<typeof createMockAccountV2>>;
|
|
51
|
+
|
|
52
|
+
beforeAll(async () => {
|
|
53
|
+
mockAccount = await createMockAccount();
|
|
54
|
+
mockAccountNoReward = await createMockAccountNoReward();
|
|
55
|
+
mockAccountNoVote = await createMockAccountNoVote();
|
|
56
|
+
mockAccountV2 = await createMockAccountV2();
|
|
57
|
+
});
|
|
58
|
+
|
|
47
59
|
test("Tron SuperRepresentatives hook - useTronSuperRepresentatives - Expect super representatives list", async () => {
|
|
48
60
|
const { result } = renderHook(() => useTronSuperRepresentatives());
|
|
49
61
|
await act(async () => {
|
|
@@ -113,6 +113,7 @@ export const CURRENCY_DEFAULT_FEATURES = {
|
|
|
113
113
|
*/
|
|
114
114
|
export const DEFAULT_FEATURES: Features = {
|
|
115
115
|
...CURRENCY_DEFAULT_FEATURES,
|
|
116
|
+
nanoOnboardingFundWallet: DEFAULT_FEATURE,
|
|
116
117
|
welcomeScreenVideoCarousel: DEFAULT_FEATURE,
|
|
117
118
|
portfolioExchangeBanner: DEFAULT_FEATURE,
|
|
118
119
|
postOnboardingAssetsTransfer: DEFAULT_FEATURE,
|
|
@@ -531,7 +532,6 @@ export const DEFAULT_FEATURES: Features = {
|
|
|
531
532
|
},
|
|
532
533
|
enableAppsBackup: DEFAULT_FEATURE,
|
|
533
534
|
web3hub: DEFAULT_FEATURE,
|
|
534
|
-
llmMarketQuickActions: DEFAULT_FEATURE,
|
|
535
535
|
llmMemoTag: DEFAULT_FEATURE,
|
|
536
536
|
lldMemoTag: DEFAULT_FEATURE,
|
|
537
537
|
ldmkTransport: {
|
|
@@ -552,7 +552,6 @@ export const DEFAULT_FEATURES: Features = {
|
|
|
552
552
|
},
|
|
553
553
|
},
|
|
554
554
|
llmRebornLP: { ...DEFAULT_FEATURE, params: { variant: ABTestingVariants.variantA } },
|
|
555
|
-
llmRebornFlex: DEFAULT_FEATURE,
|
|
556
555
|
llmAccountListUI: DEFAULT_FEATURE,
|
|
557
556
|
llmLedgerSyncEntryPoints: {
|
|
558
557
|
...DEFAULT_FEATURE,
|
|
@@ -569,6 +568,7 @@ export const DEFAULT_FEATURES: Features = {
|
|
|
569
568
|
accounts: true,
|
|
570
569
|
settings: true,
|
|
571
570
|
onboarding: true,
|
|
571
|
+
postOnboarding: true,
|
|
572
572
|
},
|
|
573
573
|
},
|
|
574
574
|
lldNanoSUpsellBanners: {
|
|
@@ -657,8 +657,6 @@ export const DEFAULT_FEATURES: Features = {
|
|
|
657
657
|
},
|
|
658
658
|
ldmkConnectApp: DEFAULT_FEATURE,
|
|
659
659
|
lldNetworkBasedAddAccount: DEFAULT_FEATURE,
|
|
660
|
-
llmOfacGeoBlocking: DEFAULT_FEATURE,
|
|
661
|
-
lldOfacGeoBlocking: DEFAULT_FEATURE,
|
|
662
660
|
llmDatadog: {
|
|
663
661
|
...DEFAULT_FEATURE,
|
|
664
662
|
params: {
|
|
@@ -693,6 +691,7 @@ export const DEFAULT_FEATURES: Features = {
|
|
|
693
691
|
llmSyncOnboardingIncr1: DEFAULT_FEATURE,
|
|
694
692
|
lldSyncOnboardingIncr1: DEFAULT_FEATURE,
|
|
695
693
|
noah: DEFAULT_FEATURE,
|
|
694
|
+
newSendFlow: DEFAULT_FEATURE,
|
|
696
695
|
};
|
|
697
696
|
|
|
698
697
|
// Firebase SDK treat JSON values as strings
|
|
@@ -28,3 +28,17 @@ export const getStablecoinYieldSetting = (
|
|
|
28
28
|
|
|
29
29
|
return !usdtProvider ? "inactive" : usdtProvider === "earn" ? "api" : "dapp";
|
|
30
30
|
};
|
|
31
|
+
|
|
32
|
+
export const getBitcoinYieldSetting = (stakePrograms: Feature_StakePrograms | null): string => {
|
|
33
|
+
/** Check if Bitcoin has "earn" provider configured in redirects. */
|
|
34
|
+
const bitcoinProvider =
|
|
35
|
+
!stakePrograms?.enabled || !stakePrograms?.params?.redirects
|
|
36
|
+
? undefined
|
|
37
|
+
: stakePrograms?.params?.redirects["bitcoin"]?.platform;
|
|
38
|
+
|
|
39
|
+
return !bitcoinProvider
|
|
40
|
+
? "inactive"
|
|
41
|
+
: bitcoinProvider === "earn"
|
|
42
|
+
? "deposit_screen"
|
|
43
|
+
: bitcoinProvider;
|
|
44
|
+
};
|