diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2021-05-05 23:57:29 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-05-05 23:57:29 +0200 |
commit | 8d75bd002da5011237b537b522a5b6248e99b9d5 (patch) | |
tree | e05b20be0cc32cc9cbea79ffbd71519ad6f7d029 /app/javascript/mastodon/features/follow_recommendations/index.js | |
parent | 6d9ad30bf861b2422c5951f7593a657675fedc24 (diff) |
Add empty state message for follow recommendations in web UI (#16161)
Diffstat (limited to 'app/javascript/mastodon/features/follow_recommendations/index.js')
-rw-r--r-- | app/javascript/mastodon/features/follow_recommendations/index.js | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/app/javascript/mastodon/features/follow_recommendations/index.js b/app/javascript/mastodon/features/follow_recommendations/index.js index 1231a27ea..5b30a206e 100644 --- a/app/javascript/mastodon/features/follow_recommendations/index.js +++ b/app/javascript/mastodon/features/follow_recommendations/index.js @@ -75,10 +75,14 @@ class FollowRecommendations extends ImmutablePureComponent { {!isLoading && ( <React.Fragment> - <div> - {suggestions.map(suggestion => ( + <div className='column-list'> + {suggestions.size > 0 ? suggestions.map(suggestion => ( <Account key={suggestion.get('account')} id={suggestion.get('account')} /> - ))} + )) : ( + <div className='column-list__empty-message'> + <FormattedMessage id='empty_column.follow_recommendations' defaultMessage='Looks like no suggestions could be generated for you. You can try using search to look for people you might know or explore trending hashtags.' /> + </div> + )} </div> <div className='column-actions'> |