Merge branch 'follow-button-fix' into 'develop'

Notification: treat follow differently from follow_request

Closes #1055

See merge request soapbox-pub/soapbox-fe!1694
react-query-api
Alex Gleason 2022-07-30 23:50:58 +00:00
commit 30ec3dbd9f
1 zmienionych plików z 8 dodań i 8 usunięć

Wyświetl plik

@ -270,6 +270,14 @@ const Notification: React.FC<INotificaton> = (props) => {
const renderContent = () => {
switch (type) {
case 'follow':
case 'user_approved':
return account && typeof account === 'object' ? (
<AccountContainer
id={account.id}
hidden={hidden}
avatarSize={48}
/>
) : null;
case 'follow_request':
return account && typeof account === 'object' ? (
<AccountContainer
@ -279,14 +287,6 @@ const Notification: React.FC<INotificaton> = (props) => {
actionType='follow_request'
/>
) : null;
case 'user_approved':
return account && typeof account === 'object' ? (
<AccountContainer
id={account.id}
hidden={hidden}
avatarSize={48}
/>
) : null;
case 'move':
return account && typeof account === 'object' && notification.target && typeof notification.target === 'object' ? (
<AccountContainer