mirror of
https://github.com/BoostIo/Boostnote
synced 2025-12-13 17:56:25 +00:00
apply search term on enter key
This commit is contained in:
@@ -74,6 +74,11 @@ class TopBar extends React.Component {
|
|||||||
}
|
}
|
||||||
|
|
||||||
handleKeyDown (e) {
|
handleKeyDown (e) {
|
||||||
|
// Re-apply search field on ENTER key
|
||||||
|
if (e.keyCode === 13) {
|
||||||
|
this.debouncedUpdateKeyword(e.target.value)
|
||||||
|
}
|
||||||
|
|
||||||
// Clear search on ESC
|
// Clear search on ESC
|
||||||
if (e.keyCode === 27) {
|
if (e.keyCode === 27) {
|
||||||
return this.handleSearchClearButton(e)
|
return this.handleSearchClearButton(e)
|
||||||
|
|||||||
Reference in New Issue
Block a user