1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-17 16:53:34 +00:00

set generated password from add/edit

This commit is contained in:
Kyle Spearrin
2018-01-29 16:33:38 -05:00
parent ce84e8e428
commit 40c5cfa10b
5 changed files with 30 additions and 2 deletions

View File

@@ -20,6 +20,7 @@ import { UtilsService } from 'jslib/abstractions/utils.service';
})
export class PasswordGeneratorComponent implements OnInit {
@Input() showSelect: boolean = false;
@Output() onSelected = new EventEmitter<string>();
options: any = {};
password: string = '-';
@@ -83,4 +84,9 @@ export class PasswordGeneratorComponent implements OnInit {
this.analytics.eventTrack.next({ action: 'Copied Generated Password' });
this.utilsService.copyToClipboard(this.password, window.document);
}
select() {
this.analytics.eventTrack.next({ action: 'Selected Generated Password' });
this.onSelected.emit(this.password);
}
}