From b1cf50839b9fa64e27fa4eea0035f156cc85fc95 Mon Sep 17 00:00:00 2001 From: katty barroso Date: Tue, 19 Nov 2024 12:38:49 +0100 Subject: [PATCH] Fix links with token address --- .../src/components/PoolOverview/KeyMetrics.tsx | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/centrifuge-app/src/components/PoolOverview/KeyMetrics.tsx b/centrifuge-app/src/components/PoolOverview/KeyMetrics.tsx index 544d01909b..069223ddc3 100644 --- a/centrifuge-app/src/components/PoolOverview/KeyMetrics.tsx +++ b/centrifuge-app/src/components/PoolOverview/KeyMetrics.tsx @@ -285,10 +285,15 @@ const AvailableNetworks = ({ poolId }: { poolId: string }) => { const pool = usePool(poolId) const renderTooltipBody = (networkName: string, tranches: Tranche[], baseUrl: string) => { - const links = tranches.map((tranche) => ({ - text: `View Transactions`, - url: baseUrl, - })) + const links = tranches.map((tranche, index) => { + const tokenAddress = activeDomains?.data?.find((domain) => domain.trancheTokens[tranche.id])?.trancheTokens[ + tranche.id + ] + return { + text: `View Transactions`, + url: `${baseUrl}token/${tokenAddress}`, + } + }) return }