ProseMirror / prosemirror

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

The selected text in the current editor has been canceled #1338

Closed WuYunlong closed 1 year ago

WuYunlong commented 1 year ago

When I add a hyperlink

The selected text in the current editor has been canceled, and I want to continue to display it as selected.

https://user-images.githubusercontent.com/3301446/203467050-02e66a4f-91c5-4e14-a1b1-a9b697651b77.mp4

marijnh commented 1 year ago

The editor selection is the browser's native selection, and if the cursor is in some text field in a dialog, it's not in the editor, so you won't see a selection range there. You could use a decoration to indicate where the selection is if you really want to, but this isn't something the library is going to do by default.