import { Component, EventEmitter, Input, Output, } from '@angular/core'; import { CipherType } from 'jslib-common/enums/cipherType'; import { CipherView } from 'jslib-common/models/view/cipherView'; @Component({ selector: 'app-ciphers-list', templateUrl: 'ciphers-list.component.html', }) export class CiphersListComponent { @Output() onSelected = new EventEmitter(); @Output() launchEvent = new EventEmitter(); @Output() onView = new EventEmitter(); @Input() ciphers: CipherView[]; @Input() showView = false; @Input() title: string; cipherType = CipherType; selectCipher(c: CipherView) { this.onSelected.emit(c); } launchCipher(c: CipherView) { this.launchEvent.emit(c); } viewCipher(c: CipherView) { this.onView.emit(c); } }