From c792cc25497974c475aada4a7db1bc70e4a3a035 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?marcin=20miko=C5=82ajczak?= Date: Thu, 22 Dec 2022 19:58:20 +0100 Subject: [PATCH] Do not include link to profile in ReplyMentionsModal MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: marcin mikołajczak --- app/soapbox/components/account.tsx | 13 ++++++++++--- app/soapbox/features/reply-mentions/account.tsx | 2 +- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/app/soapbox/components/account.tsx b/app/soapbox/components/account.tsx index 5618b8cf8..7ea8f43f9 100644 --- a/app/soapbox/components/account.tsx +++ b/app/soapbox/components/account.tsx @@ -15,14 +15,17 @@ import type { Account as AccountEntity } from 'soapbox/types/entities'; interface IInstanceFavicon { account: AccountEntity, + disabled?: boolean, } -const InstanceFavicon: React.FC = ({ account }) => { +const InstanceFavicon: React.FC = ({ account, disabled }) => { const history = useHistory(); const handleClick: React.MouseEventHandler = (e) => { e.stopPropagation(); + if (disabled) return; + const timelineUrl = `/timeline/${account.domain}`; if (!(e.ctrlKey || e.metaKey)) { history.push(timelineUrl); @@ -32,7 +35,11 @@ const InstanceFavicon: React.FC = ({ account }) => { }; return ( - ); @@ -219,7 +226,7 @@ const Account = ({ @{username} {account.favicon && ( - + )} {(timestamp) ? ( diff --git a/app/soapbox/features/reply-mentions/account.tsx b/app/soapbox/features/reply-mentions/account.tsx index 5facac7a8..db3dbce8f 100644 --- a/app/soapbox/features/reply-mentions/account.tsx +++ b/app/soapbox/features/reply-mentions/account.tsx @@ -52,7 +52,7 @@ const Account: React.FC = ({ composeId, accountId, author }) => { return (
- +
{!author && button}