diff --git a/app/soapbox/features/ui/components/action_button.js b/app/soapbox/features/ui/components/action_button.js index 830ce33a8..47dfb30b1 100644 --- a/app/soapbox/features/ui/components/action_button.js +++ b/app/soapbox/features/ui/components/action_button.js @@ -82,26 +82,42 @@ class ActionButton extends ImmutablePureComponent { render() { const { account, intl, me, small } = this.props; - let actionBtn = null; + const empty = <>>; if (!me) { - actionBtn =
; + // Remote follow + return (); } if (me !== account.get('id')) { if (!account.get('relationship')) { // Wait until the relationship is loaded - // + return empty; } else if (account.getIn(['relationship', 'requested'])) { - actionBtn = ; + // Awaiting acceptance + return ; } else if (!account.getIn(['relationship', 'blocking'])) { - actionBtn = ; + // Follow & Unfollow + return (); } else if (account.getIn(['relationship', 'blocking'])) { - actionBtn = ; + // Unblock + return ; } } else { - actionBtn = ; + // Edit profile + return ; } - return actionBtn; + return empty; } }