mirror of
https://github.com/langgenius/dify.git
synced 2026-04-27 05:58:14 +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.