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 correctly handle IME Input in Combobox #6239
base: main
Are you sure you want to change the base?
Conversation
GET_BUILD |
Build successful! π |
## API Changes
unknown top level export { type: 'any' } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR, this is indeed better.
I noticed that the popover keeps opening and closing in the background. I think we could introduce some behavior based on the composition events from useTextfield, onCompositiionStart and onCompositionEnd. Then we could keep the popover closed while composing and reopen it when composition ends.
Possibly closing when composition starts and opening when it ends? I tried it, but I don't know enough about composition to know what feels natural to a user. I'm guessing I'm missing something because the popover didn't always reopen, but maybe I just don't know how to end compositions correctly.
I'm happy for this to be handled separately in a new issue. Just let us know if it's something you'd like to take care of.
This is a good idea. I'll see if I can come up with another issue to address what state would be desirable for users! |
related to nextui-org/nextui#2121
This PR addresses a bug in the combobox component where inputs from an IME were being incorrectly committed before the user completed their text entry.
β Pull Request Checklist:
before
combobox-ime-before.mov
after
combobox-ime-after.mov
π Test Instructions:
Setup for MacOS
Add the Japanese input method
Test Steps
nihon
followed by the enter key. This should result in "γ«γ»γ" or "ζ₯ζ¬".go
, and the combobox should suggest "γ«γ»γγ". Press enter.π§’ Your Project:
https://github.com/nextui-org/nextui