Add hover cards to grouped notifications

Renaud Chaput 2024-06-27 11:23:52 +02:00 committed by Claire
parent d7cec45524
commit 5cdec0eef7
2 changed files with 11 additions and 5 deletions

View File

@ -10,7 +10,11 @@ const AvatarWrapper: React.FC<{ accountId: string }> = ({ accountId }) => {
if (!account) return null;
return (
<Link to={`/@${account.acct}`} title={`@${account.acct}`}>
<Link
to={`/@${account.acct}`}
title={`@${account.acct}`}
data-hover-card-account={account.id}
>
<Avatar account={account} size={28} />
</Link>
);

View File

@ -14,10 +14,12 @@ export const NamesList: React.FC<{ accountIds: string[]; total: number }> = ({
if (!account) return null;
const displayedName = (
<Link to={`/@${account.get('acct')}`} title={`@${account.get('acct')}`}>
<bdi
dangerouslySetInnerHTML={{ __html: account.get('display_name_html') }}
/>
<Link
to={`/@${account.acct}`}
title={`@${account.acct}`}
data-hover-card-account={account.id}
>
<bdi dangerouslySetInnerHTML={{ __html: account.display_name_html }} />
</Link>
);