Skip to content

Fix issue in RTE related to adding text before a mention

Himanshu Kapoor requested to merge 472988-rte-bug into master

What does this MR do and why?

Fix issue in RTE related to adding text before a mention. This was a regression from !158367 (diffs).

If you start the input by tagging ( @somebody) someone, and then relocate the cursor to before the @, you could type to insert text, but couldn't delete or otherwise interact with it (backspace and left arrow keys don't respond). When switching to plain-text, anything typed before the @ disappeared. This commit fixes the issue.

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After
Screen Recording 2024-07-17 at 12.48.55.mov Screen Recording 2024-07-17 at 12.47.58.mov

How to set up and validate locally

  1. In an issue comment, switch to rich text editor.
  2. Mention a user.
  3. Move cursor to before the mention.
  4. Type something.
  5. Switch to plain text editor.
  6. The text before the mention should not disappear.

Related to #472988 (closed)

Edited by Himanshu Kapoor

Merge request reports

Loading