This website works better with JavaScript.
Home
Explore
Help
Sign In
closed-social
/
mastodon
Watch
3
Star
0
Fork
2
Code
Issues
5
Pull Requests
0
Projects
0
Releases
3
Wiki
Activity
Browse Source
Add empty state message for follow recommendations in web UI (
#16161
)
closed-social-v3
Eugen Rochko
3 years ago
committed by
GitHub
parent
6d9ad30bf8
commit
8d75bd002d
No known key found for this signature in database
GPG Key ID:
4AEE18F83AFDEB23
2 changed files
with
23 additions
and
3 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+7
-3
app/javascript/mastodon/features/follow_recommendations/index.js
+16
-0
app/javascript/styles/mastodon/components.scss
+ 7
- 3
app/javascript/mastodon/features/follow_recommendations/index.js
View File
@ -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.'
/
>
<
/
d
i
v
>
)
}
<
/
d
i
v
>
<
div
className
=
'column-actions'
>
+ 16
- 0
app/javascript/styles/mastodon/components.scss
View File
@ -2525,6 +2525,22 @@ a.account__display-name {
}
}
.
column-list
{
margin
:
0
20px
;
border
:
1px
solid
lighten
(
$
ui-base-color
,
8
%
)
;
background
:
darken
(
$
ui-base-color
,
2
%
)
;
border-radius
:
4px
;
&
__empty-message
{
padding
:
40px
;
text-align
:
center
;
font-size
:
16px
;
line-height
:
24px
;
font-weight
:
400
;
color
:
$
darker-text-color
;
}
}
.
compose-panel
{
width
:
285px
;
margin-top
:
10px
;
Write
Preview
Loading…
Cancel
Save