-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
editor will crash when input Chinese in the end of link element #4060
Comments
This only happens in chrome, imo. For now, I only figured out some ugly workaround for this, no idea whether introduce other side effect. The idea is to document.execCommand("undo") to remove the first unexpected input by ime, in custom onCompositionEnd. |
Hi, Any update on this? |
Thank you ! |
Do you want to request a feature or report a bug?
bug
What's the current behavior?
Chrome GIF
Chrome behavior
input Chinese at end of link element, character will input twice, then move focus to left, the editor crush
![Kapture 2021-01-28 at 12 05 09_Chrome](https://user-images.githubusercontent.com/16861647/106089562-25df9b80-6163-11eb-953b-b99171b6f3e4.gif)
Safari GIF
Safari behavior
input Chinese at end of link element, then move focus to left, the editor crush
![Kapture 2021-01-28 at 12 11 09_Safari](https://user-images.githubusercontent.com/16861647/106089564-28da8c00-6163-11eb-9fe0-7ee6ce8e749b.gif)
Firefox GIF
Firefox behavior
input Chinese at end of link element, then move focus to link element, then came back, input Chinese, the editor crush
![Kapture 2021-01-28 at 12 15 07_Firefox](https://user-images.githubusercontent.com/16861647/106089566-29732280-6163-11eb-8105-1b51f2399155.gif)
Slate: 0.XX.X (https://www.slatejs.org/examples/links)
Browser: Chrome / Safari / Firefox
OS: Mac
What's the expected behavior?
input Chinese with no errors
The text was updated successfully, but these errors were encountered: