fix(ext): prevent submit on composing state
This commit is contained in:
@@ -51,7 +51,7 @@ export default function App() {
|
|||||||
}, [stop])
|
}, [stop])
|
||||||
|
|
||||||
const handleKeyDown = (e: React.KeyboardEvent) => {
|
const handleKeyDown = (e: React.KeyboardEvent) => {
|
||||||
if (e.key === 'Enter' && !e.shiftKey) {
|
if (e.key === 'Enter' && !e.shiftKey && !e.nativeEvent.isComposing) {
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
handleSubmit()
|
handleSubmit()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user