-
Notifications
You must be signed in to change notification settings - Fork 395
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
When typing Japanese, pressing the Enter key to confirm completion selects the document. #1304
When typing Japanese, pressing the Enter key to confirm completion selects the document. #1304
Comments
AFAIK, this is the default behavior, not sure if there's a way to change that. |
Hey,
Indeed here two of the input sources are focused, so pressing enter will submit both form. Using the mouse to select the Japanese text shouldn't trigger the search (which is expected), but I don't think there's a fix to that 🤔 |
Thank you for your reply.
Yes, if I select the Japanese text with the mouse the search will not be executed. We can use The |
I think we could check isComposing here: https://github.com/algolia/autocomplete/blob/next/packages/autocomplete-core/src/onKeyDown.ts#L108 |
"composing" is used on Japanese (and other CJK scripts) when typing on a qwerty or similar keyboard, showing something akin to autocomplete on iOS. You confirm a word by pressing enter, which shouldn't commit to a search. Still needs to be tested thoroughly, as it's possible we need to check isComposing earlier to prevent searching for the intermediate romanji characters. Fixes algolia/docsearch#1304 Fixes algolia/docsearch#1043
I did not know about this option! It indeed looks like it should be fixed at the AC level, good catch |
Reopening this issue to let the docsearch team handle updating autocomplete and forwarding |
Description
Pressing Enter when the text input is not finalized will take you to the document.
Steps to reproduce
Live reproduction:
Expected behavior
Environment
The text was updated successfully, but these errors were encountered: