Fix (again): send message on Enter keypress only when not in input method mode (#848)

This commit is contained in:
Shu Uesugi 2025-03-05 12:55:49 -08:00 committed by GitHub
commit 39729644df
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -246,7 +246,11 @@ function PureMultimodalInput({
rows={2}
autoFocus
onKeyDown={(event) => {
if (event.key === 'Enter' && !event.shiftKey) {
if (
event.key === "Enter" &&
!event.shiftKey &&
!event.nativeEvent.isComposing
) {
event.preventDefault();
if (isLoading) {