From aff5ad1faabc4c680a6ff4e68b3abc301a50e9b4 Mon Sep 17 00:00:00 2001 From: Shashank S Date: Fri, 2 Jul 2021 07:03:11 +0530 Subject: [PATCH] feat: radio button options (#420) --- angular/src/components/password-generator.component.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/angular/src/components/password-generator.component.ts b/angular/src/components/password-generator.component.ts index d3e2849937..6e5a389a95 100644 --- a/angular/src/components/password-generator.component.ts +++ b/angular/src/components/password-generator.component.ts @@ -17,6 +17,7 @@ export class PasswordGeneratorComponent implements OnInit { @Input() showSelect: boolean = false; @Output() onSelected = new EventEmitter(); + passTypeOptions: any[]; options: any = {}; password: string = '-'; showOptions = false; @@ -25,7 +26,12 @@ export class PasswordGeneratorComponent implements OnInit { constructor(protected passwordGenerationService: PasswordGenerationService, protected platformUtilsService: PlatformUtilsService, protected i18nService: I18nService, - private win: Window) { } + private win: Window) { + this.passTypeOptions = [ + { name: i18nService.t('password'), value: 'password' }, + { name: i18nService.t('passphrase'), value: 'passphrase' }, + ]; + } async ngOnInit() { const optionsResponse = await this.passwordGenerationService.getOptions();