Renaming the Follow button to "Follow back" when followed by user (#5281)
* Renaming the follow button to follow back when followed by user * Fixing conditions and reusing existing translationzio/stable^2^2
parent
e0d9e75407
commit
86abeb80b9
|
@ -219,6 +219,8 @@ let ProfileHeaderStandard = ({
|
||||||
<ButtonText>
|
<ButtonText>
|
||||||
{profile.viewer?.following ? (
|
{profile.viewer?.following ? (
|
||||||
<Trans>Following</Trans>
|
<Trans>Following</Trans>
|
||||||
|
) : profile.viewer?.followedBy ? (
|
||||||
|
<Trans>Follow Back</Trans>
|
||||||
) : (
|
) : (
|
||||||
<Trans>Follow</Trans>
|
<Trans>Follow</Trans>
|
||||||
)}
|
)}
|
||||||
|
|
|
@ -61,7 +61,7 @@ export function FollowButton({
|
||||||
label={_(msg({message: 'Unfollow', context: 'action'}))}
|
label={_(msg({message: 'Unfollow', context: 'action'}))}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
} else {
|
} else if (!profile.viewer.followedBy) {
|
||||||
return (
|
return (
|
||||||
<Button
|
<Button
|
||||||
type={unfollowedType}
|
type={unfollowedType}
|
||||||
|
@ -70,5 +70,14 @@ export function FollowButton({
|
||||||
label={_(msg({message: 'Follow', context: 'action'}))}
|
label={_(msg({message: 'Follow', context: 'action'}))}
|
||||||
/>
|
/>
|
||||||
)
|
)
|
||||||
|
} else {
|
||||||
|
return (
|
||||||
|
<Button
|
||||||
|
type={unfollowedType}
|
||||||
|
labelStyle={labelStyle}
|
||||||
|
onPress={onPressFollow}
|
||||||
|
label={_(msg({message: 'Follow Back', context: 'action'}))}
|
||||||
|
/>
|
||||||
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue