mirror of
https://github.com/langgenius/dify.git
synced 2026-08-03 11:46:37 +08:00
The base Input component lacked IME composition detection, causing Enter key presses during CJK input method candidate selection to mistakenly trigger form submissions. Add an `onPressEnter` prop with built-in IME safety using compositionStart/End tracking and nativeEvent.isComposing checks (with Safari 50ms delay workaround). Migrate all 5 call sites from manual onKeyDown Enter detection to onPressEnter. |
||
|---|---|---|
| .. | ||
| index.spec.tsx | ||
| index.stories.tsx | ||
| index.tsx | ||