1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 17:56:25 +00:00

Add to handle space key on search

This commit is contained in:
asmsuechan
2017-10-12 23:15:03 +09:00
parent 93e188d118
commit 49243a8010

View File

@@ -64,8 +64,8 @@ class TopBar extends React.Component {
isConfirmTranslation: false
})
// When the key is translation confirmation (Enter)
if (this.state.isIME && e.keyCode === 13) {
// When the key is translation confirmation (Enter, Space)
if (this.state.isIME && (e.keyCode === 32 || e.keyCode === 13)) {
this.setState({
isConfirmTranslation: true
})