diff --git a/src/core/setup.ts b/src/core/setup.ts index bb211cc23..4947167a4 100644 --- a/src/core/setup.ts +++ b/src/core/setup.ts @@ -14,6 +14,7 @@ import { chainTypesById, ChainTypesByIdType, } from 'shared/constants/chainConstants' +import { USDRIF_TESTNET } from 'src/screens/home/TokenImage' import { getWalletSetting } from './config' @@ -91,15 +92,7 @@ const defaultTestnetTokens: ITokenWithoutLogo[] = Object.keys(testnetContracts) } }) export const getDefaultTokens = (chainId: ChainTypesByIdType) => { - const usdRifTestnet = { - decimals: 18, - name: 'RIF US Dollar', - symbol: 'USDRIF', - contractAddress: '0x8dbf326e12a9ff37ed6ddf75ada548c2640a6482', - balance: '0x00', - usdBalance: 0, - } as ITokenWithoutLogo return chainTypesById[chainId] === ChainTypeEnum.MAINNET ? defaultMainnetTokens - : [...defaultTestnetTokens, usdRifTestnet] + : [...defaultTestnetTokens, USDRIF_TESTNET] } diff --git a/src/screens/home/TokenImage.tsx b/src/screens/home/TokenImage.tsx index ec447344a..ec7ab9368 100644 --- a/src/screens/home/TokenImage.tsx +++ b/src/screens/home/TokenImage.tsx @@ -10,6 +10,7 @@ import { import { FrownFaceIcon } from 'components/icons' import { sharedColors } from 'shared/constants' +import { ITokenWithoutLogo } from 'src/redux/slices/balancesSlice/types' interface Props { symbol: string @@ -278,3 +279,12 @@ export const getIconSource = ( return undefined } } + +export const USDRIF_TESTNET = { + decimals: 18, + name: 'RIF US Dollar', + symbol: 'USDRIF', + contractAddress: '0x8dbf326e12a9ff37ed6ddf75ada548c2640a6482', + balance: '0x00', + usdBalance: 0, +} as ITokenWithoutLogo