Hi there! I wanted to post here to highlight a bug some of our users have encountered where the editor becomes confused about the offset of an atom node and the cursor is drawn in the incorrect position. I am able to reproduce this bug in the ProseMirror dino example using the following steps:
In the third line of text (“Dinosaur nodes can be selected, copied, pasted, dragged, and so on.”), highlight and delete “Dinosaur nodes” but do not delete the space following this text.
Copy and paste a dinosaur node at the beginning of this line.
Move the cursor to the right using the arrow keys; it will get “caught” on the first non-space character. Deleting will remove the first non-space character even though it appears that delete should remove the space. Additionally, the text can only be highlighted to the second-to-last character.
Thanks for the quick reply. That’s interesting! I’m able to reproduce on Chrome Version 97.0.4692.71. It does not appear to be an issue on Safari not Firefox.
I’m still not able to reproduce this—tried with Chrome 96 and 98. Can you give me the precise sequence of keys you press after pasting the dino node? I just pressed the right arrow, and my cursor moved as expected.
Sorry for the delay here. Attached, please find a gif of the bug I’m seeing. In the bottom left corner of the gif, you’ll be able to see a cast of my keystrokes.
Hi there! I wanted to check in here and see if the above screencap was helpful in reproducing the error. I just tested on the dino example again and confirm I still experience this bug.
This is definitely a Chrome bug (it reports the selection as being in the right place, but displays it in another place). Fortunately, it seems to be fixed in version 98 (I was able to reproduce it on macOS with 96 but not 98).