mirror of
https://framagit.org/tykayn/mastodon.git
synced 2023-08-25 08:33:12 +02:00
🐛 fix action bar
Signed-off-by: Baptiste Lemoine <contact@cipherbliss.com>
This commit is contained in:
parent
b872c1c7c0
commit
198d0cf677
@ -29,7 +29,7 @@ class ActionBar extends React.PureComponent {
|
||||
|
||||
handleLogout = () => {
|
||||
this.props.onLogout();
|
||||
}
|
||||
};
|
||||
|
||||
render () {
|
||||
const { intl } = this.props;
|
||||
|
@ -19,6 +19,7 @@ const messages = defineMessages({
|
||||
cannot_reblog : { id: 'status.cannot_reblog', defaultMessage: 'This post cannot be boosted' },
|
||||
favourite : { id: 'status.favourite', defaultMessage: 'Favourite' },
|
||||
bookmark : { id: 'status.bookmark', defaultMessage: 'Bookmark' },
|
||||
more : { id: 'status.more', defaultMessage: 'More' },
|
||||
mute : { id: 'status.mute', defaultMessage: 'Mute @{name}' },
|
||||
muteConversation : { id: 'status.mute_conversation', defaultMessage: 'Mute conversation' },
|
||||
unmuteConversation : { id: 'status.unmute_conversation', defaultMessage: 'Unmute conversation' },
|
||||
@ -304,6 +305,8 @@ class ActionBar extends React.PureComponent {
|
||||
if (status.get('visibility') === 'direct') reblogIcon = 'envelope';
|
||||
else if (status.get('visibility') === 'private') reblogIcon = 'lock';
|
||||
|
||||
let reblog_disabled = (status.get('visibility') === 'direct' || status.get('visibility') === 'private');
|
||||
|
||||
return (
|
||||
<div className='detailed-status__action-bar'>
|
||||
<div className='detailed-status__button'><IconButton
|
||||
@ -312,14 +315,13 @@ class ActionBar extends React.PureComponent {
|
||||
onClick={this.handleReplyClick}
|
||||
/></div >
|
||||
<div className='detailed-status__button'><IconButton
|
||||
disabled={reblog_disabled}
|
||||
disabled={!publicStatus}
|
||||
active={status.get('reblogged')}
|
||||
title={reblog_disabled ? intl.formatMessage(messages.cannot_reblog) : intl.formatMessage(messages.reblog)}
|
||||
title={!publicStatus ? intl.formatMessage(messages.cannot_reblog) : intl.formatMessage(messages.reblog)}
|
||||
icon={reblogIcon}
|
||||
onClick={this.handleReblogClick}
|
||||
/></div >
|
||||
<div className='detailed-status__button'>
|
||||
<IconButton
|
||||
<div className='detailed-status__button'><IconButton
|
||||
className='star-icon'
|
||||
animate
|
||||
active={status.get('favourited')}
|
||||
@ -328,8 +330,7 @@ class ActionBar extends React.PureComponent {
|
||||
onClick={this.handleFavouriteClick}
|
||||
/></div >
|
||||
{shareButton}
|
||||
<div className='detailed-status__button'>
|
||||
<IconButton
|
||||
<div className='detailed-status__button'><IconButton
|
||||
className='bookmark-icon'
|
||||
active={status.get('bookmarked')}
|
||||
title={intl.formatMessage(messages.bookmark)}
|
||||
@ -344,7 +345,7 @@ class ActionBar extends React.PureComponent {
|
||||
status={status}
|
||||
items={menu}
|
||||
direction='left'
|
||||
title='More'
|
||||
title={intl.formatMessage(messages.more)}
|
||||
/>
|
||||
</div >
|
||||
</div >
|
||||
|
@ -1,5 +1,9 @@
|
||||
#!/bin/bash
|
||||
## script must be run with the mastodon user
|
||||
echo "dumping database before update":
|
||||
cd && pg_dump -Fc mastodon -f mastodon-prod-db-$(date +%y-%m-%d).dump
|
||||
echo "dumping database is done ":
|
||||
ls -lArtH
|
||||
cd /home/mastodon/live/
|
||||
echo "ruby version is":
|
||||
ruby -v
|
||||
|
Loading…
Reference in New Issue
Block a user