sforkowany z mirror/soapbox
Merge branch 'status-menu' into 'develop'
Don't show 'Bookmark' item menu if not authenticated See merge request soapbox-pub/soapbox-fe!1033improve-ci
commit
06214272a8
|
@ -342,6 +342,10 @@ class StatusActionBar extends ImmutablePureComponent {
|
||||||
// });
|
// });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!me) {
|
||||||
|
return menu;
|
||||||
|
}
|
||||||
|
|
||||||
if (features.bookmarks) {
|
if (features.bookmarks) {
|
||||||
menu.push({
|
menu.push({
|
||||||
text: intl.formatMessage(status.get('bookmarked') ? messages.unbookmark : messages.bookmark),
|
text: intl.formatMessage(status.get('bookmarked') ? messages.unbookmark : messages.bookmark),
|
||||||
|
@ -350,10 +354,6 @@ class StatusActionBar extends ImmutablePureComponent {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!me) {
|
|
||||||
return menu;
|
|
||||||
}
|
|
||||||
|
|
||||||
menu.push(null);
|
menu.push(null);
|
||||||
|
|
||||||
if (ownAccount || withDismiss) {
|
if (ownAccount || withDismiss) {
|
||||||
|
|
|
@ -345,15 +345,15 @@ class ActionBar extends React.PureComponent {
|
||||||
// });
|
// });
|
||||||
}
|
}
|
||||||
|
|
||||||
if (features.bookmarks) {
|
|
||||||
menu.push({
|
|
||||||
text: intl.formatMessage(status.get('bookmarked') ? messages.unbookmark : messages.bookmark),
|
|
||||||
action: this.handleBookmarkClick,
|
|
||||||
icon: require(status.get('bookmarked') ? '@tabler/icons/icons/bookmark-off.svg' : '@tabler/icons/icons/bookmark.svg'),
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
if (me) {
|
if (me) {
|
||||||
|
if (features.bookmarks) {
|
||||||
|
menu.push({
|
||||||
|
text: intl.formatMessage(status.get('bookmarked') ? messages.unbookmark : messages.bookmark),
|
||||||
|
action: this.handleBookmarkClick,
|
||||||
|
icon: require(status.get('bookmarked') ? '@tabler/icons/icons/bookmark-off.svg' : '@tabler/icons/icons/bookmark.svg'),
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
menu.push(null);
|
menu.push(null);
|
||||||
|
|
||||||
if (ownAccount) {
|
if (ownAccount) {
|
||||||
|
|
Ładowanie…
Reference in New Issue