diff --git a/.changeset/shy-balloons-sniff.md b/.changeset/shy-balloons-sniff.md new file mode 100644 index 000000000000..973e1057628c --- /dev/null +++ b/.changeset/shy-balloons-sniff.md @@ -0,0 +1,13 @@ +--- +"@ledgerhq/cryptoassets": minor +"@ledgerhq/types-live": minor +"@ledgerhq/coin-evm": minor +"@ledgerhq/live-currency-format": minor +"ledger-live-desktop": minor +"live-mobile": minor +"@ledgerhq/live-common": minor +"@ledgerhq/web-tools": minor +"@ledgerhq/live-cli": minor +--- + +adding adi currency support diff --git a/apps/cli/src/live-common-setup-base.ts b/apps/cli/src/live-common-setup-base.ts index 84756e3d2ab3..0a379ada41a5 100644 --- a/apps/cli/src/live-common-setup-base.ts +++ b/apps/cli/src/live-common-setup-base.ts @@ -13,6 +13,7 @@ setWalletAPIVersion(WALLET_API_VERSION); setSupportedCurrencies([ "aptos", "aptos_testnet", + "adi", "bitcoin", "ethereum", "bsc", diff --git a/apps/ledger-live-desktop/src/live-common-set-supported-currencies.ts b/apps/ledger-live-desktop/src/live-common-set-supported-currencies.ts index b40a0a47b8a2..d302d0b5eec3 100644 --- a/apps/ledger-live-desktop/src/live-common-set-supported-currencies.ts +++ b/apps/ledger-live-desktop/src/live-common-set-supported-currencies.ts @@ -65,6 +65,7 @@ setSupportedCurrencies([ "near", "aptos", "aptos_testnet", + "adi", "icon", "icon_berlin_testnet", "optimism", diff --git a/apps/ledger-live-desktop/tests/fixtures/wallet-api.ts b/apps/ledger-live-desktop/tests/fixtures/wallet-api.ts index 33ba44146780..d260f0e550ee 100644 --- a/apps/ledger-live-desktop/tests/fixtures/wallet-api.ts +++ b/apps/ledger-live-desktop/tests/fixtures/wallet-api.ts @@ -717,6 +717,15 @@ export const expectedCurrencyList = [ color: "#FFCD29", decimals: 8, }, + { + type: "CryptoCurrency", + id: "adi", + ticker: "ADI", + name: "Adi", + family: "ethereum", + color: "#0066CC", + decimals: 18, + }, { type: "CryptoCurrency", id: "optimism", diff --git a/apps/ledger-live-mobile/src/live-common-setup.ts b/apps/ledger-live-mobile/src/live-common-setup.ts index 46600e39ebf7..742911344f57 100644 --- a/apps/ledger-live-mobile/src/live-common-setup.ts +++ b/apps/ledger-live-mobile/src/live-common-setup.ts @@ -122,6 +122,7 @@ setSupportedCurrencies([ "lukso", "aptos", "aptos_testnet", + "adi", "linea", "linea_sepolia", "blast", diff --git a/apps/ledger-live-mobile/src/mvvm/features/Web3Hub/utils/api/mocks/manifests.ts b/apps/ledger-live-mobile/src/mvvm/features/Web3Hub/utils/api/mocks/manifests.ts index da6992ff194e..6686dbb440e4 100644 --- a/apps/ledger-live-mobile/src/mvvm/features/Web3Hub/utils/api/mocks/manifests.ts +++ b/apps/ledger-live-mobile/src/mvvm/features/Web3Hub/utils/api/mocks/manifests.ts @@ -145,6 +145,7 @@ export const mocks: AppManifest[] = [ "somnia", "zero_gravity", "unichain", + "adi", ], content: { shortDescription: { diff --git a/apps/web-tools/src/live-common-setup.ts b/apps/web-tools/src/live-common-setup.ts index 20b7bbe33c37..255bc3df7bb4 100644 --- a/apps/web-tools/src/live-common-setup.ts +++ b/apps/web-tools/src/live-common-setup.ts @@ -43,6 +43,7 @@ setSupportedCurrencies([ "decred", "digibyte", "algorand", + "adi", "qtum", "bitcoin_gold", "komodo", diff --git a/libs/coin-modules/coin-evm/src/editTransaction/__snapshots__/getFormattedFeeFields.test.ts.snap b/libs/coin-modules/coin-evm/src/editTransaction/__snapshots__/getFormattedFeeFields.test.ts.snap index 49850253be97..fa4680b21b6f 100644 --- a/libs/coin-modules/coin-evm/src/editTransaction/__snapshots__/getFormattedFeeFields.test.ts.snap +++ b/libs/coin-modules/coin-evm/src/editTransaction/__snapshots__/getFormattedFeeFields.test.ts.snap @@ -9,6 +9,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale de-DE should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale de-DE should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale de-DE should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1.050.000 AKA", @@ -720,6 +729,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale en-US should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale en-US should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale en-US should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1,050,000 AKA", @@ -1431,6 +1449,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale es-ES should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale es-ES should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale es-ES should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1.050.000 AKA", @@ -2142,6 +2169,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale fr-FR should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale fr-FR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale fr-FR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1 050 000 AKA", @@ -2853,6 +2889,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale ja-JP should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale ja-JP should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale ja-JP should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1,050,000 AKA", @@ -3564,6 +3609,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale ko-KR should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale ko-KR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale ko-KR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1,050,000 AKA", @@ -4275,6 +4329,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale pt-BR should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale pt-BR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale pt-BR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1.050.000 AKA", @@ -4986,6 +5049,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale ru-RU should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale ru-RU should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale ru-RU should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1 050 000 AKA", @@ -5697,6 +5769,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale tr-TR should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale tr-TR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale tr-TR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1.050.000 AKA", @@ -6408,6 +6489,15 @@ exports[`getFormattedFeeFields with tx type 0 with locale zh-CN should correctly } `; +exports[`getFormattedFeeFields with tx type 0 with locale zh-CN should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000105 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 0 with locale zh-CN should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "1,050,000 AKA", @@ -7119,6 +7209,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale de-DE should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale de-DE should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale de-DE should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420.000 AKA", @@ -7830,6 +7929,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale en-US should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale en-US should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale en-US should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420,000 AKA", @@ -8541,6 +8649,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale es-ES should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale es-ES should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale es-ES should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420.000 AKA", @@ -9252,6 +9369,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale fr-FR should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale fr-FR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale fr-FR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420 000 AKA", @@ -9963,6 +10089,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale ja-JP should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale ja-JP should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale ja-JP should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420,000 AKA", @@ -10674,6 +10809,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale ko-KR should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale ko-KR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale ko-KR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420,000 AKA", @@ -11385,6 +11529,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale pt-BR should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale pt-BR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale pt-BR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420.000 AKA", @@ -12096,6 +12249,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale ru-RU should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale ru-RU should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale ru-RU should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420 000 AKA", @@ -12807,6 +12969,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale tr-TR should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale tr-TR should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0,000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale tr-TR should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420.000 AKA", @@ -13518,6 +13689,15 @@ exports[`getFormattedFeeFields with tx type 2 with locale zh-CN should correctly } `; +exports[`getFormattedFeeFields with tx type 2 with locale zh-CN should correctly format fee fields for Adi unit 1`] = ` +{ + "formattedFeeValue": "0.000042 ADI", + "formattedGasPrice": "0 ADI", + "formattedMaxFeePerGas": "0 ADI", + "formattedMaxPriorityFeePerGas": "0 ADI", +} +`; + exports[`getFormattedFeeFields with tx type 2 with locale zh-CN should correctly format fee fields for Akroma unit 1`] = ` { "formattedFeeValue": "420,000 AKA", diff --git a/libs/coin-modules/coin-evm/src/specs.ts b/libs/coin-modules/coin-evm/src/specs.ts index aa6167e62e28..5ad1f81b4660 100644 --- a/libs/coin-modules/coin-evm/src/specs.ts +++ b/libs/coin-modules/coin-evm/src/specs.ts @@ -62,6 +62,7 @@ const minBalancePerCurrencyId: Partial> = { zero_gravity: 0.01, unichain: 0.001, unichain_sepolia: 0.001, + adi: 0.001, }; /** diff --git a/libs/ledger-live-common/src/__tests__/migration/account-migration.ts b/libs/ledger-live-common/src/__tests__/migration/account-migration.ts index b5b2e586643e..b6d0f5c8c9e5 100644 --- a/libs/ledger-live-common/src/__tests__/migration/account-migration.ts +++ b/libs/ledger-live-common/src/__tests__/migration/account-migration.ts @@ -42,6 +42,7 @@ setSupportedCurrencies([ "digibyte", "algorand", "avalanche_c_chain", + "adi", "qtum", "bitcoin_gold", "komodo", diff --git a/libs/ledger-live-common/src/__tests__/test-helpers/environment.ts b/libs/ledger-live-common/src/__tests__/test-helpers/environment.ts index c46261d31954..36b25523274b 100644 --- a/libs/ledger-live-common/src/__tests__/test-helpers/environment.ts +++ b/libs/ledger-live-common/src/__tests__/test-helpers/environment.ts @@ -117,6 +117,7 @@ setSupportedCurrencies([ "mantra", "aptos", "aptos_testnet", + "adi", "xion", "sui", "zenrock", diff --git a/libs/ledger-live-common/src/families/evm/config.ts b/libs/ledger-live-common/src/families/evm/config.ts index 81f013967abc..5fb8fe1ee3a4 100644 --- a/libs/ledger-live-common/src/families/evm/config.ts +++ b/libs/ledger-live-common/src/families/evm/config.ts @@ -1156,6 +1156,24 @@ const evmConfig: CurrencyLiveConfigDefinition = { showNfts: false, }, }, + config_currency_adi: { + type: "object", + default: { + status: { + type: "active", + features: [{ id: "blockchain_txs", status: "active" }], + }, + node: { + type: "external", + uri: "https://rpc.adifoundation.ai", + }, + explorer: { + type: "blockscout", + uri: "https://explorer.adifoundation.ai/api", + }, + showNfts: false, + }, + }, config_currency_unichain: { type: "object", default: { diff --git a/libs/ledger-live-common/src/featureFlags/defaultFeatures.ts b/libs/ledger-live-common/src/featureFlags/defaultFeatures.ts index e51dbbf832bd..c7a87dbe8c80 100644 --- a/libs/ledger-live-common/src/featureFlags/defaultFeatures.ts +++ b/libs/ledger-live-common/src/featureFlags/defaultFeatures.ts @@ -118,6 +118,7 @@ export const CURRENCY_DEFAULT_FEATURES = { currencyZeroGravity: DEFAULT_FEATURE, currencyConcordium: DEFAULT_FEATURE, currencyConcordiumTestnet: DEFAULT_FEATURE, + currencyAdi: DEFAULT_FEATURE, currencyUnichain: DEFAULT_FEATURE, currencyUnichainSepolia: DEFAULT_FEATURE, }; diff --git a/libs/ledger-live-common/src/modularDrawer/hooks/useCurrenciesUnderFeatureFlag.ts b/libs/ledger-live-common/src/modularDrawer/hooks/useCurrenciesUnderFeatureFlag.ts index 106b0c64c20a..da1c26cf51a6 100644 --- a/libs/ledger-live-common/src/modularDrawer/hooks/useCurrenciesUnderFeatureFlag.ts +++ b/libs/ledger-live-common/src/modularDrawer/hooks/useCurrenciesUnderFeatureFlag.ts @@ -7,6 +7,7 @@ import useEnv from "../../hooks/useEnv"; export function useCurrenciesUnderFeatureFlag() { const mock = useEnv("MOCK"); + const adi = useFeature("currencyAdi"); const aleo = useFeature("currencyAleo"); const aleoTestnet = useFeature("currencyAleoTestnet"); const aptos = useFeature("currencyAptos"); @@ -96,6 +97,7 @@ export function useCurrenciesUnderFeatureFlag() { const featureFlaggedCurrencies = useMemo( (): Partial | null>> => ({ + adi, aleo, aleo_testnet: aleoTestnet, aptos, @@ -184,6 +186,7 @@ export function useCurrenciesUnderFeatureFlag() { unichain_sepolia: unichainSepolia, }), [ + adi, aleo, aleoTestnet, aptos, diff --git a/libs/ledgerjs/packages/cryptoassets/src/abandonseed.ts b/libs/ledgerjs/packages/cryptoassets/src/abandonseed.ts index a5dfc65de557..915d9aa9c783 100644 --- a/libs/ledgerjs/packages/cryptoassets/src/abandonseed.ts +++ b/libs/ledgerjs/packages/cryptoassets/src/abandonseed.ts @@ -21,6 +21,7 @@ const abandonSeedAddresses: Partial> = { avalanche_c_chain_fuji: EVM_DEAD_ADDRESS, aptos: EVM_DEAD_ADDRESS, aptos_testnet: EVM_DEAD_ADDRESS, + adi: EVM_DEAD_ADDRESS, cosmos: "cosmos19rl4cm2hmr8afy4kldpxz3fka4jguq0auqdal4", ripple: "rHsMGQEkVNJmpGWs8XUBoTBiAAbwxZN5v3", stellar: "GDYPMQMYW2JTLPWAUAHIDY3E4VHP5SGTFC5SMA45L7ZPOTHWQ2PHEW3E", diff --git a/libs/ledgerjs/packages/cryptoassets/src/currencies.ts b/libs/ledgerjs/packages/cryptoassets/src/currencies.ts index b182b76c5622..646b68de89f4 100644 --- a/libs/ledgerjs/packages/cryptoassets/src/currencies.ts +++ b/libs/ledgerjs/packages/cryptoassets/src/currencies.ts @@ -148,6 +148,30 @@ export const cryptocurrenciesById: Record = { }, ], }, + adi: { + type: "CryptoCurrency", + id: "adi", + coinType: CoinType.ETH, + name: "Adi", + managerAppName: "Ethereum", + ticker: "ADI", + scheme: "adi", + color: "#0066CC", + family: "evm", + units: [ + { + name: "ADI", + code: "ADI", + magnitude: 18, + }, + ], + ethereumLikeInfo: { + chainId: 36900, + }, + explorerViews: [blockscoutExplorerView("https://explorer.adifoundation.ai")], + keywords: ["adi", "adi chain"], + tokenTypes: ["erc20"], + }, near: { type: "CryptoCurrency", id: "near", diff --git a/libs/ledgerjs/packages/types-live/src/feature.ts b/libs/ledgerjs/packages/types-live/src/feature.ts index d36c8dfc3bc0..7c1f6b364d41 100644 --- a/libs/ledgerjs/packages/types-live/src/feature.ts +++ b/libs/ledgerjs/packages/types-live/src/feature.ts @@ -158,6 +158,7 @@ export type CurrencyFeatures = { currencyZeroGravity: DefaultFeature; currencyConcordium: DefaultFeature; currencyConcordiumTestnet: DefaultFeature; + currencyAdi: DefaultFeature; currencyAleo: DefaultFeature; currencyAleoTestnet: DefaultFeature; currencyUnichain: DefaultFeature; diff --git a/libs/live-currency-format/src/__snapshots__/formatCurrencyUnit.test.ts.snap b/libs/live-currency-format/src/__snapshots__/formatCurrencyUnit.test.ts.snap index 5830bbf1093a..2f4f959f011b 100644 --- a/libs/live-currency-format/src/__snapshots__/formatCurrencyUnit.test.ts.snap +++ b/libs/live-currency-format/src/__snapshots__/formatCurrencyUnit.test.ts.snap @@ -2,6 +2,8 @@ exports[`formatCurrencyUnit with custom options with locale de-DE should correctly format 0G unit (0G) 1`] = `"0,012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale de-DE should correctly format Adi unit (ADI) 1`] = `"0,012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale de-DE should correctly format Aion unit (AION) 1`] = `"123.456.789,00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale de-DE should correctly format Akroma unit (AKA) 1`] = `"123.456.789,00000000- -AKA"`; @@ -404,6 +406,8 @@ exports[`formatCurrencyUnit with custom options with locale de-DE should correct exports[`formatCurrencyUnit with custom options with locale en-US should correctly format 0G unit (0G) 1`] = `"0.012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale en-US should correctly format Adi unit (ADI) 1`] = `"0.012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale en-US should correctly format Aion unit (AION) 1`] = `"123,456,789.00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale en-US should correctly format Akroma unit (AKA) 1`] = `"123,456,789.00000000- -AKA"`; @@ -806,6 +810,8 @@ exports[`formatCurrencyUnit with custom options with locale en-US should correct exports[`formatCurrencyUnit with custom options with locale es-ES should correctly format 0G unit (0G) 1`] = `"0,012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale es-ES should correctly format Adi unit (ADI) 1`] = `"0,012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale es-ES should correctly format Aion unit (AION) 1`] = `"123.456.789,00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale es-ES should correctly format Akroma unit (AKA) 1`] = `"123.456.789,00000000- -AKA"`; @@ -1208,6 +1214,8 @@ exports[`formatCurrencyUnit with custom options with locale es-ES should correct exports[`formatCurrencyUnit with custom options with locale fr-FR should correctly format 0G unit (0G) 1`] = `"0,012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale fr-FR should correctly format Adi unit (ADI) 1`] = `"0,012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale fr-FR should correctly format Aion unit (AION) 1`] = `"123 456 789,00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale fr-FR should correctly format Akroma unit (AKA) 1`] = `"123 456 789,00000000- -AKA"`; @@ -1610,6 +1618,8 @@ exports[`formatCurrencyUnit with custom options with locale fr-FR should correct exports[`formatCurrencyUnit with custom options with locale ja-JP should correctly format 0G unit (0G) 1`] = `"0.012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale ja-JP should correctly format Adi unit (ADI) 1`] = `"0.012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale ja-JP should correctly format Aion unit (AION) 1`] = `"123,456,789.00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale ja-JP should correctly format Akroma unit (AKA) 1`] = `"123,456,789.00000000- -AKA"`; @@ -2012,6 +2022,8 @@ exports[`formatCurrencyUnit with custom options with locale ja-JP should correct exports[`formatCurrencyUnit with custom options with locale ko-KR should correctly format 0G unit (0G) 1`] = `"0.012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale ko-KR should correctly format Adi unit (ADI) 1`] = `"0.012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale ko-KR should correctly format Aion unit (AION) 1`] = `"123,456,789.00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale ko-KR should correctly format Akroma unit (AKA) 1`] = `"123,456,789.00000000- -AKA"`; @@ -2414,6 +2426,8 @@ exports[`formatCurrencyUnit with custom options with locale ko-KR should correct exports[`formatCurrencyUnit with custom options with locale pt-BR should correctly format 0G unit (0G) 1`] = `"0,012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale pt-BR should correctly format Adi unit (ADI) 1`] = `"0,012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale pt-BR should correctly format Aion unit (AION) 1`] = `"123.456.789,00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale pt-BR should correctly format Akroma unit (AKA) 1`] = `"123.456.789,00000000- -AKA"`; @@ -2816,6 +2830,8 @@ exports[`formatCurrencyUnit with custom options with locale pt-BR should correct exports[`formatCurrencyUnit with custom options with locale ru-RU should correctly format 0G unit (0G) 1`] = `"0,012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale ru-RU should correctly format Adi unit (ADI) 1`] = `"0,012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale ru-RU should correctly format Aion unit (AION) 1`] = `"123 456 789,00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale ru-RU should correctly format Akroma unit (AKA) 1`] = `"123 456 789,00000000- -AKA"`; @@ -3218,6 +3234,8 @@ exports[`formatCurrencyUnit with custom options with locale ru-RU should correct exports[`formatCurrencyUnit with custom options with locale tr-TR should correctly format 0G unit (0G) 1`] = `"0,012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale tr-TR should correctly format Adi unit (ADI) 1`] = `"0,012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale tr-TR should correctly format Aion unit (AION) 1`] = `"123.456.789,00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale tr-TR should correctly format Akroma unit (AKA) 1`] = `"123.456.789,00000000- -AKA"`; @@ -3620,6 +3638,8 @@ exports[`formatCurrencyUnit with custom options with locale tr-TR should correct exports[`formatCurrencyUnit with custom options with locale zh-CN should correctly format 0G unit (0G) 1`] = `"0.012345678900000000- -0G"`; +exports[`formatCurrencyUnit with custom options with locale zh-CN should correctly format Adi unit (ADI) 1`] = `"0.012345678900000000- -ADI"`; + exports[`formatCurrencyUnit with custom options with locale zh-CN should correctly format Aion unit (AION) 1`] = `"123,456,789.00000000- -AION"`; exports[`formatCurrencyUnit with custom options with locale zh-CN should correctly format Akroma unit (AKA) 1`] = `"123,456,789.00000000- -AKA"`; @@ -4022,6 +4042,8 @@ exports[`formatCurrencyUnit with custom options with locale zh-CN should correct exports[`formatCurrencyUnit with default options should correctly format 0G unit (0G) 1`] = `"0.0123456"`; +exports[`formatCurrencyUnit with default options should correctly format Adi unit (ADI) 1`] = `"0.0123456"`; + exports[`formatCurrencyUnit with default options should correctly format Aion unit (AION) 1`] = `"123,456,789"`; exports[`formatCurrencyUnit with default options should correctly format Akroma unit (AKA) 1`] = `"123,456,789"`;