]> cat aescling's git repositories - mastodon.git/commitdiff
Fix unfollow action button style (#15418)
authorTakeshi Umeda <noel.yoshiba@gmail.com>
Wed, 23 Dec 2020 22:47:50 +0000 (07:47 +0900)
committerGitHub <noreply@github.com>
Wed, 23 Dec 2020 22:47:50 +0000 (23:47 +0100)
app/javascript/mastodon/features/account/components/header.js

index 2b97af4e675e687826038530cd2a453505c6b3e7..c8fd85e1d92e1f6cec26bac1b98c1a19397207ec 100644 (file)
@@ -170,7 +170,7 @@ class Header extends ImmutablePureComponent {
       } else if (account.getIn(['relationship', 'requested'])) {
         actionBtn = <Button className='logo-button' text={intl.formatMessage(messages.cancel_follow_request)} title={intl.formatMessage(messages.requested)} onClick={this.props.onFollow} />;
       } else if (!account.getIn(['relationship', 'blocking'])) {
-        actionBtn = <Button disabled={account.getIn(['relationship', 'blocked_by'])} className={classNames('logo-button', { 'button--destructive': account.getIn(['relationship', 'following']) })} text={intl.formatMessage(account.getIn(['relationship', 'following']) ? messages.unfollow : messages.follow)} onClick={this.props.onFollow} />;
+        actionBtn = <Button disabled={account.getIn(['relationship', 'blocked_by'])} className={classNames('logo-button', { 'button--destructive': account.getIn(['relationship', 'following']) })} style={account.getIn(['relationship', 'following']) && { padding: '0 10px', 'min-width': '88px' }} text={intl.formatMessage(account.getIn(['relationship', 'following']) ? messages.unfollow : messages.follow)} onClick={this.props.onFollow} />;
       } else if (account.getIn(['relationship', 'blocking'])) {
         actionBtn = <Button className='logo-button' text={intl.formatMessage(messages.unblock, { name: account.get('username') })} onClick={this.props.onBlock} />;
       }