Skip to content

Cursor positioning lost after pasting a link onto text selection following CTRL + SHIFT selection #11178

@mrwweb

Description

@mrwweb

Describe the bug
When selecting text, I expect the right arrow key to take me to the end of the selection. After pasting a link on top of a text selection made with CTRL + SHIFT, the right arrow key deselects text and the text cursor is placed at the start of the selection.

To Reproduce
Steps to reproduce the behavior:

  1. Type out anchor text
  2. Use CTRL + SHIFT to select the text (selecting text in either direction triggers the bug)
  3. Paste a link onto the selection that is on the clipboard already
  4. Hit right arrow key
  5. Text is deselected and the cursor is positioned at the beginning of the selection

Expected behavior
Cursor goes to the end of the selection

Screenshots
link-selection-bug

Desktop (please complete the following information):

  • Win 10
  • Firefox 63
  • WP 5.0-beta1-43823, Twenty Nineteen, no plugins

Metadata

Metadata

Assignees

Labels

[Feature] Rich TextRelated to the Rich Text component that allows developers to render a contenteditable[Feature] Writing FlowBlock selection, navigation, splitting, merging, deletion...[Type] BugAn existing feature does not function as intended

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions