From 2b8aac9569db38ef5a5618e23ba692654fab8d6e Mon Sep 17 00:00:00 2001 From: JD Francis Date: Thu, 16 Jan 2025 15:14:30 -0600 Subject: [PATCH] Fix solscan link for transfer received --- packages/common/src/utils/linking.ts | 4 ++++ .../components/TransactionDetailsContent.tsx | 7 ++++++- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/common/src/utils/linking.ts b/packages/common/src/utils/linking.ts index 1ec21c7b720..7f6eefeefba 100644 --- a/packages/common/src/utils/linking.ts +++ b/packages/common/src/utils/linking.ts @@ -25,3 +25,7 @@ export const isAllowedExternalLink = (link: string) => { export const makeSolanaTransactionLink = (signature: string) => { return `https://solscan.io/tx/${signature}` } + +export const makeSolanaAccountLink = (account: string) => { + return `https://solscan.io/account/${account}` +} diff --git a/packages/web/src/components/transaction-details-modal/components/TransactionDetailsContent.tsx b/packages/web/src/components/transaction-details-modal/components/TransactionDetailsContent.tsx index d4df39eb8ef..55c27630df5 100644 --- a/packages/web/src/components/transaction-details-modal/components/TransactionDetailsContent.tsx +++ b/packages/web/src/components/transaction-details-modal/components/TransactionDetailsContent.tsx @@ -9,6 +9,7 @@ import { formatAudio, formatCapitalizeString, isNullOrUndefined, + makeSolanaAccountLink, makeSolanaTransactionLink, route } from '@audius/common/utils' @@ -163,7 +164,11 @@ const dateAndMetadataBlocks = (transactionDetails: TransactionDetails) => { header={