Closed Corb3nik closed 3 months ago
This is a Chrome bug that should be fixed in version 128. If you can arrange to call destroy()
on the editor when it is being removed, that will avoid the issue. Beyond that, there's unfortunately not much the library can do about this, so I'm closing this issue here.
Describe the issue
Hi!
On Google Chrome, when an editor is removed from the DOM, it still captures keystrokes, preventing other input elements from receiving keystrokes.
Steps to Reproduce
The new input tag won't receive any keystrokes.
https://github.com/user-attachments/assets/5751dec7-4a12-45ee-95cf-2a1052175c05
Browser and platform
macOS (14.6) / Google Chrome (Version 127.0.6533.89)
Reproduction link
https://codemirror.net/try/?c=aW1wb3J0IHsgRWRpdG9yVmlldyB9IGZyb20gIkBjb2RlbWlycm9yL3ZpZXciOwoKY29uc3QgdmlldyA9IG5ldyBFZGl0b3JWaWV3KHsKICBkb2M6ICJUeXBlIGhlcmUiLAogIHBhcmVudDogZG9jdW1lbnQuYm9keSwKfSk7CgpzZXRUaW1lb3V0KCgpID0+IHsKICBkb2N1bWVudC53cml0ZSgiPGlucHV0PiIpOwp9LCA1MDAwKTsK