From 58799bb2317ea0a2f32d8e0582e9a6b380a8c46d Mon Sep 17 00:00:00 2001 From: Dexter Edwards Date: Wed, 6 Jul 2022 16:59:06 +0100 Subject: [PATCH] fix: etherscan links not opening in new tabs sometimes (#713) --- apps/token/src/routes/contracts/index.tsx | 2 ++ apps/token/src/routes/home/token-details/token-details.tsx | 2 ++ libs/web3/src/lib/transaction-dialog/dialog-rows.tsx | 2 ++ 3 files changed, 6 insertions(+) diff --git a/apps/token/src/routes/contracts/index.tsx b/apps/token/src/routes/contracts/index.tsx index 54a62e39d..11e76ba76 100644 --- a/apps/token/src/routes/contracts/index.tsx +++ b/apps/token/src/routes/contracts/index.tsx @@ -42,6 +42,7 @@ const Contracts = () => { {contract.address} @@ -57,6 +58,7 @@ const Contracts = () => { {value} diff --git a/apps/token/src/routes/home/token-details/token-details.tsx b/apps/token/src/routes/home/token-details/token-details.tsx index 3a10f0a10..6c6e6d46c 100644 --- a/apps/token/src/routes/home/token-details/token-details.tsx +++ b/apps/token/src/routes/home/token-details/token-details.tsx @@ -50,6 +50,7 @@ export const TokenDetails = ({ title={t('View on Etherscan (opens in a new tab)')} className="font-mono text-white text-right" href={`${ETHERSCAN_URL}/address/${token.address}`} + target="_blank" > {token.address} @@ -61,6 +62,7 @@ export const TokenDetails = ({ title={t('View on Etherscan (opens in a new tab)')} className="font-mono text-white text-right" href={`${ETHERSCAN_URL}/address/${config.token_vesting_contract.address}`} + target="_blank" > {config.token_vesting_contract.address} diff --git a/libs/web3/src/lib/transaction-dialog/dialog-rows.tsx b/libs/web3/src/lib/transaction-dialog/dialog-rows.tsx index 31548a0ba..d46098f1b 100644 --- a/libs/web3/src/lib/transaction-dialog/dialog-rows.tsx +++ b/libs/web3/src/lib/transaction-dialog/dialog-rows.tsx @@ -46,6 +46,7 @@ export const TxRow = ({ href={`${ETHERSCAN_URL}/tx/${txHash}`} title={t('View transaction on Etherscan')} className="text-vega-pink dark:text-vega-yellow" + target="_blank" > {t('View on Etherscan')} @@ -65,6 +66,7 @@ export const TxRow = ({ href={`${ETHERSCAN_URL}/tx/${txHash}`} title={t('View on Etherscan')} className="text-vega-pink dark:text-vega-yellow" + target="_blank" > {t('View transaction on Etherscan')}