ProseMirror / prosemirror

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

Selected text or block is lost when iOS mobile app is switched #1317

Open xiaweiss opened 2 years ago

xiaweiss commented 2 years ago

The selected text is lost, when the app is switched.

https://user-images.githubusercontent.com/17960084/193402295-3e72af29-ecd1-4af6-98f3-4e4b6d0592e6.mov

marijnh commented 2 years ago

Do plain contenteditable elements behave the same?

xiaweiss commented 2 years ago

Yes

marijnh commented 2 years ago

Then I suppose this is just the browser's behavior, and not something ProseMirror can do much about.

xiaweiss commented 2 years ago

It can trigger editor updates. I record content and selection, then restore it.

Do the mobile safari browser has some events, I can handle it? Thank you.