docsearch icon indicating copy to clipboard operation
docsearch copied to clipboard

When selecting characters in Chinese and Japanese IME, the search function may be triggered incorrectly.

Open PhantasWeng opened this issue 8 months ago • 1 comments

Description

In Chinese and Japanese input methods, character selection is done using pinyin and enter key.

For example: to input "你" (ㄋ一ˇ), you would type ㄋ + ㄧ + ˇ + enter to select the character. Currently, pressing enter triggers an incorrect input.

This results in submitting ㄋ一ˇ instead of .

Steps to reproduce

  1. Go to DocSearchModal > input
  2. Keypress on ㄋ一ˇ enter (key mapping to su3 enter)
  3. Expected to be a character selection, but turned into link selection.

Google Chrome 個人資料  OwlPay Documentation 2023-10-31 at 13 22 48

Expected behavior

Expected to be a character selection on first enter keypress.

For example, in chrome url input Google Chrome When selecting characters in Chinese and Japanese IME the search function may be triggered incorrectly  · Issue #2111 · algoliadocsearch 2023-10-31 at 13 30 11

In github text area Google Chrome When selecting characters in Chinese and Japanese IME the search function may be triggered incorrectly  · Issue #2111 · algoliadocsearch 2023-10-31 at 13 31 12

Environment

  • OS: [e.g. macOS]
  • Browser: [e.g. Chrome]
  • DocSearch version: Algolia DocSearch for docusaurus

PhantasWeng avatar Oct 31 '23 05:10 PhantasWeng