Skip to content
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

[Bug] Key Presses Affect Document Actions During Japanese Conversion Menu Usage #865

Open
keita06 opened this issue Aug 10, 2024 · 7 comments

Comments

@keita06
Copy link

keita06 commented Aug 10, 2024

Bug Description

When using Japanese input within a document implemented with your library, I encountered an issue where key presses such as the up/down arrow keys or the spacebar, which are intended for navigating the prediction menu, also trigger actions in the document itself. This causes disruptions in the text conversion process, as both the prediction menu and the document are responding to the same key events. This issue does not occur every time, but it happens with high frequency, making it difficult to consistently complete text conversion.

This is my first time submitting an issue, so please let me know if additional information is needed or if there’s anything I should adjust in the report.

2024-08-10.17.42.49.mov

How to Reproduce

  1. Open a document using the library.
  2. Start typing in Japanese using an IME (Input Method Editor).
  3. Observe that when the prediction menu appears, the cursor continues to focus on the document rather than interacting with the prediction menu.

Expected Behavior

When using the up/down arrow keys or the spacebar during Japanese input, I expect the focus to remain on the prediction menu, allowing me to navigate through and select conversion options without affecting the document. The document cursor should not move or trigger any actions during this process, ensuring that text conversion happens smoothly and correctly.

Operating System

macos (Apple M2)

AppFlowy Editor Version(s)

main repository

Screenshots

No response

Additional Context

No response

@keita06
Copy link
Author

keita06 commented Aug 26, 2024

@LucasXu0
When using IME to input Japanese, typically two Roman characters are used to input a single character. However, in AppFlowy, it's possible that the markdown processing is triggered as soon as the first Roman character is input. At this point, the character input is not yet complete and is still in an editing state, which could cause issues within the markdown processing.

@keita06
Copy link
Author

keita06 commented Aug 30, 2024

@LucasXu0
The input issue with Japanese conversion might be caused by enabling "Live Conversion" on MacOS's Japanese input while using Flutter 3.22.
flutter/flutter#149379

Additionally, when using an IME with "Live Conversion" turned off, the full-width space in Japanese text is not interpreted correctly. After typing a full-width space and then typing a word, the full-width space suddenly appears during input.

@LucasXu0
Copy link
Collaborator

LucasXu0 commented Aug 30, 2024

@keita06 Thanks for reporting and testing! I'll do a search about "Live Conversion". By the way, have you tried using Flutter 3.24?

Additionally, you can turn on the log and post it here. That way, I can check the IME output.

editorState.logConfiguration
  ..handler = debugPrint
  ..level = LogLevel.off;

@keita06
Copy link
Author

keita06 commented Aug 30, 2024

@LucasXu0
Since the issue regarding Japanese live conversion hasn't been resolved yet, I haven't upgraded to Flutter 3.24 to test it. If possible, I would like to downgrade to Flutter 3.19 to test it. Is appflowy_editor usable with Flutter 3.19?

@LucasXu0
Copy link
Collaborator

The version 2.4.0 is compatible with Flutter 3.19.

@keita06
Copy link
Author

keita06 commented Aug 30, 2024

Do I need to use Flutter 3.20 or later to use version 3.1.0?

@LucasXu0
Copy link
Collaborator

You can use flutter 3.19.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants