Skip to content

Commit 3972964

Browse files
authored
Fix (again): send message on Enter keypress only when not in input method mode (#848)
2 parents a378757 + cec3784 commit 3972964

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

components/multimodal-input.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -246,7 +246,11 @@ function PureMultimodalInput({
246246
rows={2}
247247
autoFocus
248248
onKeyDown={(event) => {
249-
if (event.key === 'Enter' && !event.shiftKey) {
249+
if (
250+
event.key === "Enter" &&
251+
!event.shiftKey &&
252+
!event.nativeEvent.isComposing
253+
) {
250254
event.preventDefault();
251255

252256
if (isLoading) {

0 commit comments

Comments
 (0)