1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-13 23:03:32 +00:00
Files
browser/src/popup/components/ciphers-list.component.ts
Kyle Spearrin 78058c3591 lint fixes
2018-04-10 23:49:46 -04:00

48 lines
1.2 KiB
TypeScript

import {
Component,
EventEmitter,
Input,
Output,
} from '@angular/core';
import { ToasterService } from 'angular2-toaster';
import { Angulartics2 } from 'angulartics2';
import { BrowserApi } from '../../browser/browserApi';
import { CipherType } from 'jslib/enums/cipherType';
import { CipherView } from 'jslib/models/view/cipherView';
import { I18nService } from 'jslib/abstractions/i18n.service';
import { PlatformUtilsService } from 'jslib/abstractions/platformUtils.service';
import { PopupUtilsService } from '../services/popup-utils.service';
@Component({
selector: 'app-ciphers-list',
templateUrl: 'ciphers-list.component.html',
})
export class CiphersListComponent {
@Output() onSelected = new EventEmitter<CipherView>();
@Output() onDoubleSelected = new EventEmitter<CipherView>();
@Output() onView = new EventEmitter<CipherView>();
@Input() ciphers: CipherView[];
@Input() showView = false;
@Input() title: string;
cipherType = CipherType;
selectCipher(c: CipherView) {
this.onSelected.emit(c);
}
doubleSelectCipher(c: CipherView) {
this.onDoubleSelected.emit(c);
}
viewCipher(c: CipherView) {
this.onView.emit(c);
}
}