mirror of
https://github.com/mastodon/mastodon.git
synced 2026-05-09 12:31:42 -05:00
Show "Follow" button next to accounts in a collection when logged out (#38933)
This commit is contained in:
parent
f24f98ce40
commit
60a437e045
|
|
@ -138,12 +138,16 @@ export const CollectionAccountsList: React.FC<{
|
|||
|
||||
const renderAccountItemButton = useCallback(
|
||||
({ relationship, accountId }: RenderButtonOptions) => {
|
||||
if (!me || !relationship) {
|
||||
// Show follow button when logged out (it will trigger the remote interaction modal)
|
||||
return <AccountListItemFollowButton accountId={accountId} />;
|
||||
}
|
||||
|
||||
// When viewing your own collection, only show the Follow button
|
||||
// for accounts you're not following anymore.
|
||||
const withoutButton =
|
||||
!relationship ||
|
||||
(collectionOwnerId === me &&
|
||||
(relationship.following || relationship.requested));
|
||||
collectionOwnerId === me &&
|
||||
(relationship.following || relationship.requested);
|
||||
|
||||
if (withoutButton) return null;
|
||||
|
||||
|
|
|
|||
|
|
@ -483,11 +483,19 @@ const InteractionModal: React.FC<{
|
|||
/>
|
||||
</h3>
|
||||
<p>
|
||||
<FormattedMessage
|
||||
id='interaction_modal.action'
|
||||
defaultMessage="To interact with {name}'s post, you need to sign into your account on whatever Mastodon server you use."
|
||||
values={{ name }}
|
||||
/>
|
||||
{intent === 'follow' ? (
|
||||
<FormattedMessage
|
||||
id='interaction_modal.action_follow'
|
||||
defaultMessage='To follow {name}, you need to sign into your account on whatever Mastodon server you use.'
|
||||
values={{ name }}
|
||||
/>
|
||||
) : (
|
||||
<FormattedMessage
|
||||
id='interaction_modal.action'
|
||||
defaultMessage="To interact with {name}'s post, you need to sign into your account on whatever Mastodon server you use."
|
||||
values={{ name }}
|
||||
/>
|
||||
)}
|
||||
</p>
|
||||
</div>
|
||||
|
||||
|
|
|
|||
|
|
@ -796,6 +796,7 @@
|
|||
"info_button.label": "Help",
|
||||
"info_button.what_is_alt_text": "<h1>What is alt text?</h1> <p>Alt text provides image descriptions for people with vision impairments, low-bandwidth connections, or those seeking extra context.</p> <p>You can improve accessibility and understanding for everyone by writing clear, concise, and objective alt text.</p> <ul> <li>Capture important elements</li> <li>Summarize text in images</li> <li>Use regular sentence structure</li> <li>Avoid redundant information</li> <li>Focus on trends and key findings in complex visuals (like diagrams or maps)</li> </ul>",
|
||||
"interaction_modal.action": "To interact with {name}'s post, you need to sign into your account on whatever Mastodon server you use.",
|
||||
"interaction_modal.action_follow": "To follow {name}, you need to sign into your account on whatever Mastodon server you use.",
|
||||
"interaction_modal.go": "Go",
|
||||
"interaction_modal.no_account_yet": "Don't have an account yet?",
|
||||
"interaction_modal.on_another_server": "On a different server",
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user