Fix search parameter initialisation for search-typeahead

pull/2507/head
Rigel Kent 2020-02-18 14:33:07 +01:00
parent 757ffdfe90
commit 71e75ef27e
No known key found for this signature in database
GPG Key ID: 5E53E96A494E452F
2 changed files with 4 additions and 4 deletions

View File

@ -35,9 +35,9 @@ export class SearchTypeaheadComponent implements OnInit, OnDestroy {
) {}
ngOnInit () {
const query = this.route.snapshot.queryParams
if (query['search']) this.search = query['search']
this.route.queryParams
.pipe(first(params => params.search !== undefined && params.search !== null))
.subscribe(params => this.search = params.search)
this.serverService.getConfig()
.subscribe(config => this.serverConfig = config)
}

View File

@ -10,7 +10,7 @@
.list-overflow-menu {
position: absolute;
right: 0;
right: 25px;
}
button {