You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-07 10:46:24 +03:00
Prevent user pills containing only emoji from embiggening
This commit is contained in:
@@ -516,7 +516,10 @@ export function bodyToHtml(content, highlights, opts={}) {
|
||||
contentBodyTrimmed = contentBodyTrimmed.replace(ZWJ_REGEX, '');
|
||||
|
||||
const match = EMOJI_REGEX.exec(contentBodyTrimmed);
|
||||
emojiBody = match && match[0] && match[0].length === contentBodyTrimmed.length;
|
||||
emojiBody = match && match[0] && match[0].length === contentBodyTrimmed.length
|
||||
// Prevent user pills expanding for users with only emoji in
|
||||
// their username
|
||||
&& content.formatted_body == undefined;
|
||||
}
|
||||
|
||||
const className = classNames({
|
||||
|
||||
Reference in New Issue
Block a user