From 1d5f3fbd80f25ada64a765002fc20fc1cfe23925 Mon Sep 17 00:00:00 2001 From: Ilja Date: Fri, 4 Mar 2022 14:24:12 +0200 Subject: [PATCH] Fix account display in session page --- wallets/react-wallet-v2/src/pages/session.tsx | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/wallets/react-wallet-v2/src/pages/session.tsx b/wallets/react-wallet-v2/src/pages/session.tsx index deeb2b8..10a241d 100644 --- a/wallets/react-wallet-v2/src/pages/session.tsx +++ b/wallets/react-wallet-v2/src/pages/session.tsx @@ -1,6 +1,8 @@ import AccountSelectCard from '@/components/AccountSelectCard' import PageHeader from '@/components/PageHeader' import ProjectInfoCard from '@/components/ProjectInfoCard' +import { COSMOS_MAINNET_CHAINS, TCosmosChain } from '@/data/COSMOSData' +import { EIP155_CHAINS, TEIP155Chain } from '@/data/EIP155Data' import { cosmosAddresses } from '@/utils/CosmosWalletUtil' import { eip155Addresses } from '@/utils/EIP155WalletUtil' import { isCosmosChain, isEIP155Chain } from '@/utils/HelperUtil' @@ -74,15 +76,15 @@ export default function SessionPage() { - - {chains.map(chain => { if (isEIP155Chain(chain)) { return ( + + - EIP155 Accounts + {`${EIP155_CHAINS[chain as TEIP155Chain].name} Accounts`} {eip155Addresses.map((address, index) => { const fullAddress = `${chain}:${address}` const selected = accounts.includes(fullAddress) @@ -106,11 +108,11 @@ export default function SessionPage() { } else if (isCosmosChain(chain)) { return ( - + - Cosmos Accounts + {`${COSMOS_MAINNET_CHAINS[chain as TCosmosChain].name} Accounts`} {cosmosAddresses.map((address, index) => { const fullAddress = `${chain}:${address}` const selected = accounts.includes(fullAddress)