diff --git a/src/components/Dashboard/index.tsx b/src/components/Dashboard/index.tsx
index 62954459a..805351385 100644
--- a/src/components/Dashboard/index.tsx
+++ b/src/components/Dashboard/index.tsx
@@ -3,6 +3,7 @@ import { useEffect, useState } from 'react'
import Icon from '../Global/Icon'
import Sorting from '../Global/Sorting'
import TablePagination from '../Global/TablePagination'
+import AddressLink from '../Global/AddressLink'
import { useAccount } from 'wagmi'
import Loading from '../Global/Loading'
import { useRouter } from 'next/navigation'
@@ -184,7 +185,7 @@ export const Dashboard = () => {
{link.chain} |
{utils.formatDate(new Date(link.date))} |
- {utils.printableAddress(link.address ?? address ?? '')}
+
|
{
+ const [url, setUrl] = useState('')
+ useEffect(() => {
+ if (!address) return
+ if (address.endsWith('.eth')) {
+ utils.resolveFromEnsName(address).then((resolvedAddress) => {
+ if (!resolvedAddress) return
+ setUrl(`https://debank.com/profile/${resolvedAddress}`)
+ })
+ return
+ }
+ setUrl(`https://debank.com/profile/${address}`)
+ }, [address])
+ return url ? (
+
+ {utils.printableAddress(address)}
+
+ ) : (
+ {utils.printableAddress(address)}
+ )
+}
+
+export default AddressLink
diff --git a/src/components/Profile/Components/TableComponent.tsx b/src/components/Profile/Components/TableComponent.tsx
index d7dd17555..dce07f0c5 100644
--- a/src/components/Profile/Components/TableComponent.tsx
+++ b/src/components/Profile/Components/TableComponent.tsx
@@ -3,6 +3,7 @@ import * as utils from '@/utils'
import * as interfaces from '@/interfaces'
import Sorting from '@/components/Global/Sorting'
import Loading from '@/components/Global/Loading'
+import AddressLink from '@/components/Global/AddressLink'
import { OptionsComponent } from './OptionsComponent'
import * as consts from '@/constants'
import { useCallback } from 'react'
@@ -108,7 +109,7 @@ export const TableComponent = ({
{data.dashboardItem.chain} |
{utils.formatDate(new Date(data.dashboardItem.date))} |
- {utils.printableAddress(data.dashboardItem.address ?? '')}
+
|
{
)
}}
/>
- {utils.printableAddress(referral.address)}
+
| |