mirror of
https://github.com/mastodon/mastodon.git
synced 2025-09-05 09:21:11 +00:00
fix: show moved account notice in hover card popup
- Add conditional logic to display moved account notice when account.moved is present - Include link to new account with proper formatting - Hide follow/unfollow buttons for moved accounts to prevent confusion - Add localization key 'account.moved_to_short' for hover card context - Style moved notice to match existing hover card design patterns Fixes #35623
This commit is contained in:
parent
15f6f8a8bc
commit
7268e97900
|
@ -1,4 +1,5 @@
|
|||
import { Map as ImmutableMap } from 'immutable';
|
||||
|
||||
import type { Meta, StoryObj } from '@storybook/react-vite';
|
||||
|
||||
import { accountFactory, accountFactoryState } from '@/testing/factories';
|
||||
|
@ -19,9 +20,16 @@ const meta = {
|
|||
},
|
||||
decorators: [
|
||||
(Story) => (
|
||||
<div style={{ padding: '20px', backgroundColor: '#f5f5f5', minHeight: '300px' }}>
|
||||
<div
|
||||
style={{
|
||||
padding: '20px',
|
||||
backgroundColor: '#f5f5f5',
|
||||
minHeight: '300px',
|
||||
}}
|
||||
>
|
||||
<p style={{ marginBottom: '20px', color: '#666' }}>
|
||||
Hover card examples - demonstrating Issue #35623 fix for moved accounts
|
||||
Hover card examples - demonstrating Issue #35623 fix for moved
|
||||
accounts
|
||||
</p>
|
||||
<Story />
|
||||
</div>
|
||||
|
@ -54,7 +62,7 @@ const regularAccount = accountFactoryState({
|
|||
const movedAccount = accountFactoryState({
|
||||
id: '2',
|
||||
username: 'bob_old',
|
||||
acct: 'bob_old@mastodon.social',
|
||||
acct: 'bob_old@mastodon.social',
|
||||
display_name: 'Bob Smith (Moved)',
|
||||
note: 'I have moved to a new account. Please follow me there!',
|
||||
followers_count: 890,
|
||||
|
|
Loading…
Reference in New Issue
Block a user