2018-04-05 17:11:32 +02:00
|
|
|
import { Component } from '@angular/core';
|
2018-01-24 04:21:14 +01:00
|
|
|
|
2021-06-07 19:26:36 +02:00
|
|
|
import { CiphersComponent as BaseCiphersComponent } from 'jslib-angular/components/ciphers.component';
|
2021-12-15 23:32:00 +01:00
|
|
|
import { SearchService } from 'jslib-common/abstractions/search.service';
|
2018-02-08 16:37:54 +01:00
|
|
|
|
2021-08-11 05:00:04 +02:00
|
|
|
import { CipherView } from 'jslib-common/models/view/cipherView';
|
|
|
|
|
2021-12-15 23:32:00 +01:00
|
|
|
import { SearchBarService } from '../layout/search/search-bar.service';
|
|
|
|
|
2018-01-24 04:21:14 +01:00
|
|
|
@Component({
|
|
|
|
selector: 'app-vault-ciphers',
|
2018-04-06 18:25:22 +02:00
|
|
|
templateUrl: 'ciphers.component.html',
|
2018-01-24 04:21:14 +01:00
|
|
|
})
|
2018-04-05 17:11:32 +02:00
|
|
|
export class CiphersComponent extends BaseCiphersComponent {
|
2021-12-15 23:32:00 +01:00
|
|
|
|
|
|
|
constructor(searchService: SearchService, searchBarService: SearchBarService) {
|
|
|
|
super(searchService);
|
|
|
|
|
|
|
|
searchBarService.searchText.subscribe(searchText => {
|
|
|
|
this.searchText = searchText;
|
|
|
|
this.search(200);
|
|
|
|
});
|
|
|
|
}
|
|
|
|
|
2021-08-11 05:00:04 +02:00
|
|
|
trackByFn(index: number, c: CipherView) {
|
|
|
|
return c.id;
|
2018-02-16 19:59:46 +01:00
|
|
|
}
|
2018-01-24 04:21:14 +01:00
|
|
|
}
|