-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
fix(ComboBox): bring IME support back #4952
Conversation
This change backs out carbon-design-system#3646 partially given moving `inputValue` state syncing code from `handleOnInputValueChange` to `handleOnStateChange` causes in-composition string (of IME) getting lost, because the different rendering sequence yielded by such change causes Downshift to (temporarily) render an older (stale) value to the `<input>`. Fixes carbon-design-system#4947.
Deploy preview for the-carbon-components ready! Built with commit 5c8917f https://deploy-preview-4952--the-carbon-components.netlify.com |
Deploy preview for carbon-components-react ready! Built with commit 5c8917f https://deploy-preview-4952--carbon-components-react.netlify.com |
Deploy preview for carbon-elements failed. Built with commit 5c8917f https://app.netlify.com/sites/carbon-elements/deploys/5e151920875afa0008722547 |
@asudoh real quick, how would you recommend testing IME support? 👀 |
Basically you can just type some Asian characters as "composition text". For what "composition text" is, https://www.w3.org/TR/ime-api/ will be a good resource. For how to type Asian characters as "composition text" in Mac, https://support.apple.com/guide/mac-help/type-language-mac-input-sources-mchlp1406/mac and https://support.apple.com/guide/japanese-input-method/keyboard-shortcuts-jpim10263/mac are good resources for Japanese characters. |
Thanks @asudoh! |
This change backs out carbon-design-system#3646 partially given moving `inputValue` state syncing code from `handleOnInputValueChange` to `handleOnStateChange` causes in-composition string (of IME) getting lost, because the different rendering sequence yielded by such change causes Downshift to (temporarily) render an older (stale) value to the `<input>`. Fixes carbon-design-system#4947.
This change backs out carbon-design-system#3646 partially given moving `inputValue` state syncing code from `handleOnInputValueChange` to `handleOnStateChange` causes in-composition string (of IME) getting lost, because the different rendering sequence yielded by such change causes Downshift to (temporarily) render an older (stale) value to the `<input>`. Fixes carbon-design-system#4947.
This change backs out #3646 partially given moving
inputValue
state syncing code fromhandleOnInputValueChange
tohandleOnStateChange
causes in-composition string (of IME) getting lost, because the different rendering sequence yielded by such change causes Downshift to(temporarily) render an older (stale) value to the
<input>
.Fixes #4947.
Changelog
Changed
inputValue
state syncing code back fromhandleOnStateChange
tohandleOnInputValueChange
.Testing / Reviewing
Testing should make sure combo box is not broken.