diff options
Diffstat (limited to 'client/src/app/header/search-typeahead.component.ts')
-rw-r--r-- | client/src/app/header/search-typeahead.component.ts | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/client/src/app/header/search-typeahead.component.ts b/client/src/app/header/search-typeahead.component.ts index 396a875c8..d0350368d 100644 --- a/client/src/app/header/search-typeahead.component.ts +++ b/client/src/app/header/search-typeahead.component.ts | |||
@@ -134,7 +134,7 @@ export class SearchTypeaheadComponent implements OnInit, OnDestroy { | |||
134 | ) | 134 | ) |
135 | } | 135 | } |
136 | 136 | ||
137 | handleKeyUp (event: KeyboardEvent) { | 137 | handleKey (event: KeyboardEvent) { |
138 | event.stopImmediatePropagation() | 138 | event.stopImmediatePropagation() |
139 | if (!this.keyboardEventsManager) return | 139 | if (!this.keyboardEventsManager) return |
140 | 140 | ||
@@ -143,14 +143,11 @@ export class SearchTypeaheadComponent implements OnInit, OnDestroy { | |||
143 | case 'ArrowUp': | 143 | case 'ArrowUp': |
144 | this.keyboardEventsManager.onKeydown(event) | 144 | this.keyboardEventsManager.onKeydown(event) |
145 | break | 145 | break |
146 | case 'Enter': | ||
147 | this.newSearch = false | ||
148 | this.doSearch() | ||
149 | break | ||
150 | } | 146 | } |
151 | } | 147 | } |
152 | 148 | ||
153 | doSearch () { | 149 | doSearch () { |
150 | this.newSearch = false | ||
154 | const queryParams: Params = {} | 151 | const queryParams: Params = {} |
155 | 152 | ||
156 | if (window.location.pathname === '/search' && this.route.snapshot.queryParams) { | 153 | if (window.location.pathname === '/search' && this.route.snapshot.queryParams) { |