Skip to content

Commit

Permalink
Merge pull request #42016 from bernhardoj/fix/41798-copying-mention-t…
Browse files Browse the repository at this point in the history
…urns-to-link-when-pasted

Fix manually copied and pasted user mention turns into user profile hyperlink
  • Loading branch information
luacmartins authored May 14, 2024
2 parents 0a373be + 4e48516 commit 1117462
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ function MentionUserRenderer({style, tnode, TDefaultRenderer, currentUserPersona
{...defaultRendererProps}
style={[styles.link, styleWithoutColor, StyleUtils.getMentionStyle(isOurMention), {color: StyleUtils.getMentionTextColor(isOurMention)}]}
role={CONST.ROLE.LINK}
testID="span"
testID="mention-user"
href={`/${navigationRoute}`}
>
{htmlAttribAccountID ? `@${mentionDisplayText}` : <TNodeChildrenRenderer tnode={tnodeClone} />}
Expand Down
2 changes: 1 addition & 1 deletion src/libs/SelectionScraper/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import {parseDocument} from 'htmlparser2';
import CONST from '@src/CONST';
import type GetCurrentSelection from './types';

const markdownElements = ['h1', 'strong', 'em', 'del', 'blockquote', 'q', 'code', 'pre', 'a', 'br', 'li', 'ul', 'ol', 'b', 'i', 's'];
const markdownElements = ['h1', 'strong', 'em', 'del', 'blockquote', 'q', 'code', 'pre', 'a', 'br', 'li', 'ul', 'ol', 'b', 'i', 's', 'mention-user'];
const tagAttribute = 'data-testid';

/**
Expand Down

0 comments on commit 1117462

Please sign in to comment.