Skip to content

Prevent Enter from double-submitting during IME composition#196

Open
leonidasbarkas98-cpu wants to merge 1 commit into
andrepimenta:mainfrom
leonidasbarkas98-cpu:fix/ime-double-submit
Open

Prevent Enter from double-submitting during IME composition#196
leonidasbarkas98-cpu wants to merge 1 commit into
andrepimenta:mainfrom
leonidasbarkas98-cpu:fix/ime-double-submit

Conversation

@leonidasbarkas98-cpu

Copy link
Copy Markdown

When composing text with an IME (Korean/Japanese/Chinese), confirming the composition with Enter also triggered the send handler, so the message was submitted twice (or submitted half-composed). The Enter handler now checks isComposing / keyCode 229 and ignores composition-confirming Enter presses.

Same idea as PR #146, rebased onto current main (2.2.0).

Fixes #130
Fixes #132

🤖 Generated with Claude Code

Tracks compositionstart/compositionend on the chat input and skips
the Enter-to-send handling while composing (or when e.isComposing is
still true), so confirming a CJK IME candidate no longer also sends
the message (Gitea issue andrepimenta#2; upstream andrepimenta#146).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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

Successfully merging this pull request may close these issues.

Korean input causes duplicated last character request and double response A prompt written in Korean is entered twice sometimes

1 participant