Skip to content

Commit b3bf329

Browse files
committed
feat: add link to user profile in song card widget
1 parent c44287a commit b3bf329

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

web/src/modules/browse/components/SongCard.tsx

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,16 @@ const SongDataDisplay = ({ song }: { song: SongPreviewDtoType | null }) => {
4848
{!song ? (
4949
<Skeleton />
5050
) : (
51-
`${song.uploader.username}${formatTimeAgo(
52-
new Date(song.createdAt),
53-
)}`
51+
<>
52+
<Link
53+
href={`/user/${song.uploader.username}`}
54+
className='hover:underline'
55+
>
56+
{song.uploader.username}
57+
</Link>
58+
{' • '}
59+
{formatTimeAgo(new Date(song.createdAt))}
60+
</>
5461
)}
5562
</p>
5663
{/* Play icon & count */}

0 commit comments

Comments
 (0)