2
0

Emoji: Bypass legacy emoji normalization (#36377)

This commit is contained in:
Echo
2025-10-07 17:21:50 +02:00
committed by GitHub
parent c578a0cb74
commit 3c9b828c71
6 changed files with 16 additions and 20 deletions

View File

@@ -2,8 +2,6 @@ import type { ComponentPropsWithoutRef, FC } from 'react';
import classNames from 'classnames';
import { isModernEmojiEnabled } from '@/mastodon/utils/environment';
import { AnimateEmojiProvider } from '../emoji/context';
import { EmojiHTML } from '../emoji/html';
import { Skeleton } from '../skeleton';
@@ -24,11 +22,7 @@ export const DisplayNameWithoutDomain: FC<
{account ? (
<EmojiHTML
className='display-name__html'
htmlString={
isModernEmojiEnabled()
? account.get('display_name')
: account.get('display_name_html')
}
htmlString={account.get('display_name_html')}
as='strong'
extraEmojis={account.get('emojis')}
/>

View File

@@ -1,7 +1,5 @@
import type { ComponentPropsWithoutRef, FC } from 'react';
import { isModernEmojiEnabled } from '@/mastodon/utils/environment';
import { EmojiHTML } from '../emoji/html';
import type { DisplayNameProps } from './index';
@@ -19,11 +17,7 @@ export const DisplayNameSimple: FC<
<EmojiHTML
{...props}
as='span'
htmlString={
isModernEmojiEnabled()
? account.get('display_name')
: account.get('display_name_html')
}
htmlString={account.get('display_name_html')}
extraEmojis={account.get('emojis')}
/>
</bdi>