ProseMirror / prosemirror

The ProseMirror WYSIWYM editor
http://prosemirror.net/
MIT License
7.59k stars 335 forks source link

Android Gboard multiline input from keyboard clipboard places selection at wrong place #1389

Closed deep-wonder closed 1 year ago

deep-wonder commented 1 year ago

Steps:

  1. Open https://prosemirror.net/ in chrome
  2. Type a multiline message in the editor (press enter for new lines)
  3. Select all content and Cut/Copy
  4. Use the clipboard (present above the keyboard) to insert the content
  5. Notice cursor is at wrong position, the placement of cursor depends on number of lines.

https://github.com/ProseMirror/prosemirror/assets/99749130/b74420d3-2f1b-4bd9-abc3-b97526692fe8

marijnh commented 1 year ago

This problem appears to be in GBoard, not ProseMirror. If I do something like it in a plain contenteditable element (<div contenteditable=true><p><br></p></div>) I see the cursor in the wrong place as well.