@firestitch/2fa 12.0.4 → 12.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -89,7 +89,7 @@
89
89
  return Fs2FaVerificationMethodsComponent;
90
90
  }());
91
91
  Fs2FaVerificationMethodsComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: Fs2FaVerificationMethodsComponent, deps: [{ token: FS_2FA_VERIFICATION_PROVIDER }, { token: i1.MAT_DIALOG_DATA }, { token: i1__namespace.MatDialogRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
92
- Fs2FaVerificationMethodsComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: Fs2FaVerificationMethodsComponent, selector: "ng-component", ngImport: i0__namespace, template: "<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n", styles: [".method{display:block;margin-bottom:20px}.method .method-header{display:flex;align-items:flex-start}.method .method-header .method-name{margin-left:10px}.method .method-header .method-name .method-title{font-size:14px;font-weight:400}.method .method-header .method-name .method-subtitle{font-size:12px;color:#a3a3a3}.method .method-item{display:block;margin:10px 0 0 35px}\n"], components: [{ type: i1__namespace$1.FsDialogComponent, selector: "fs-dialog", inputs: ["mobileMode"] }, { type: i3__namespace.FsRadioGroupComponent, selector: "fs-radio-group", inputs: ["orientation", "radioPosition", "compareWith", "required", "disabled", "label", "name"] }, { type: i4__namespace.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5__namespace.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i5__namespace$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i1__namespace.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i7__namespace.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i7__namespace.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i7__namespace.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i8__namespace.FsFormDirective, selector: "[fsForm]", inputs: ["wrapperSelector", "messageSelector", "hintSelector", "labelSelector", "autocomplete", "shortcuts", "confirm", "confirmDialog", "confirmDrawer", "confirmBrowser", "confirmTabs", "dirtySubmitButton", "successDelay", "errorDelay", "submit", "tabGroup"], outputs: ["fsForm", "invalid", "valid", "submitted", "reseted", "cleared"] }, { type: i1__namespace.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i9__namespace.ɵa, selector: "[fsSkeleton]", inputs: ["fsSkeletonPattern", "fsSkeleton"] }, { type: i7__namespace.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i7__namespace.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i10__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10__namespace.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i10__namespace.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1__namespace.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i10__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8__namespace.ɵw, selector: "button[type=\"submit\"]", inputs: ["dirtySubmit", "name"] }, { type: i1__namespace.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["type", "mat-dialog-close", "aria-label", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "async": i10__namespace.AsyncPipe, "keyvalue": i10__namespace.KeyValuePipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
92
+ Fs2FaVerificationMethodsComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: Fs2FaVerificationMethodsComponent, selector: "ng-component", ngImport: i0__namespace, template: "<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\" [dirtySubmitButton]=\"false\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n", styles: [".method{display:block;margin-bottom:20px}.method .method-header{display:flex;align-items:flex-start}.method .method-header .method-name{margin-left:10px}.method .method-header .method-name .method-title{font-size:14px;font-weight:400}.method .method-header .method-name .method-subtitle{font-size:12px;color:#a3a3a3}.method .method-item{display:block;margin:10px 0 0 35px}\n"], components: [{ type: i1__namespace$1.FsDialogComponent, selector: "fs-dialog", inputs: ["mobileMode"] }, { type: i3__namespace.FsRadioGroupComponent, selector: "fs-radio-group", inputs: ["orientation", "radioPosition", "compareWith", "required", "disabled", "label", "name"] }, { type: i4__namespace.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5__namespace.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i5__namespace$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i1__namespace.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i7__namespace.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i7__namespace.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i7__namespace.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i8__namespace.FsFormDirective, selector: "[fsForm]", inputs: ["wrapperSelector", "messageSelector", "hintSelector", "labelSelector", "autocomplete", "shortcuts", "confirm", "confirmDialog", "confirmDrawer", "confirmBrowser", "confirmTabs", "dirtySubmitButton", "successDelay", "errorDelay", "submit", "tabGroup"], outputs: ["fsForm", "invalid", "valid", "submitted", "reseted", "cleared"] }, { type: i1__namespace.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i9__namespace.ɵa, selector: "[fsSkeleton]", inputs: ["fsSkeletonPattern", "fsSkeleton"] }, { type: i7__namespace.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i7__namespace.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i10__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10__namespace.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i10__namespace.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1__namespace.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i10__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8__namespace.ɵw, selector: "button[type=\"submit\"]", inputs: ["dirtySubmit", "name"] }, { type: i1__namespace.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["type", "mat-dialog-close", "aria-label", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "async": i10__namespace.AsyncPipe, "keyvalue": i10__namespace.KeyValuePipe }, changeDetection: i0__namespace.ChangeDetectionStrategy.OnPush });
93
93
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0__namespace, type: Fs2FaVerificationMethodsComponent, decorators: [{
94
94
  type: i0.Component,
95
95
  args: [{
@@ -1 +1 @@
1
- {"version":3,"file":"firestitch-2fa.umd.js","sources":["../../src/app/tokens/verification.token.ts","../../src/app/enums/verification-method-type.enum.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.html","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.ts","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.html","../../src/app/components/2fa-verification-code/2fa-verification-code.component.ts","../../src/app/components/2fa-verification-code/2fa-verification-code.component.html","../../src/app/components/2fa-verification/2fa-verification.component.ts","../../src/app/components/2fa-verification/2fa-verification.component.html","../../src/app/fs-2fa.module.ts","../../src/public_api.ts","../../src/firestitch-2fa.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nimport { IFsVerificationProvider } from '../interfaces/verification-provider.interface';\n\nexport const FS_2FA_VERIFICATION_PROVIDER = new InjectionToken<IFsVerificationProvider>(\n 'Provider for Verification service',\n);\n","export enum FsVerificationMethodType {\n Sms = 'sms',\n Email = 'email',\n Authenticator = 'authenticator',\n Code = 'code',\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n Inject,\n} from '@angular/core';\n\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\n\nimport { Observable } from 'rxjs';\nimport { map, shareReplay, tap } from 'rxjs/operators';\n\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { FsVerificationMethodType } from '../../enums/verification-method-type.enum';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n templateUrl: './2fa-verification-methods.component.html',\n styleUrls: [\n './2fa-verification-methods.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FaVerificationMethodsComponent {\n\n public method: IFsVerificationMethod;\n public phone: string;\n public code: string;\n public methods$: Observable<Record<string, IFsVerificationMethod[]>>;\n public readonly verificationMethodType = FsVerificationMethodType;\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n private _verificationProvider: IFsVerificationProvider,\n @Inject(MAT_DIALOG_DATA)\n private _dialogData: any,\n private _dialogRef: MatDialogRef<Fs2FaVerificationMethodsComponent>,\n ) {\n this._setActiveMethod();\n this._initMethods();\n }\n\n public compareWith(o1, o2) {\n return o1 && o2 && o1.id === o2.id\n }\n\n public setVerificationMethod = () => {\n return this._verificationProvider\n .updateVerificationMethod(this.method.id)\n .pipe(\n tap((method: IFsVerificationMethod) => {\n this._dialogRef.close(method);\n })\n );\n };\n\n private _setActiveMethod(): void {\n this.method = this._dialogData?.method;\n }\n\n private _initMethods(): void {\n this.methods$ = this._verificationProvider\n .methods()\n .pipe(\n map((methods) => {\n return methods\n .reduce((acc, method) => {\n if (!acc[method.type]) {\n acc[method.type] = [];\n }\n\n acc[method.type].push(method);\n\n return acc;\n }, {});\n }),\n shareReplay(1),\n );\n }\n}\n","<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Output,\n} from '@angular/core';\n\nimport { FsFormDirective } from '@firestitch/form';\n\n\n@Component({\n selector: 'fs-2fa-verification-otp',\n templateUrl: './2fa-verification-otp.component.html',\n styleUrls: [\n './2fa-verification-otp.component.scss'\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationOTPComponent {\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n constructor(\n public form: FsFormDirective,\n ) {}\n\n public codeChanged(event: string): void {\n this.codeChange.emit(event);\n this.form.dirty();\n }\n\n public codeCompleted(): void {\n this.form.triggerSubmit();\n }\n}\n","<p class=\"description\">\n Enter the verification code generated by your 2 factor authenticator\n app to verify it's you\n</p>\n\n<!--\n<code-input [initialFocusField]=\"0\"\n [codeLength]=\"6\"\n (codeChanged)=\"codeChanged($event)\"\n (codeCompleted)=\"codeCompleted()\">>\n</code-input>\n-->\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Input,\n Output,\n} from '@angular/core';\nimport { ControlContainer, NgForm } from '@angular/forms';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification-code',\n templateUrl: './2fa-verification-code.component.html',\n styleUrls: [\n './2fa-verification-code.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n viewProviders: [\n {\n provide: ControlContainer,\n useExisting: NgForm,\n },\n ],\n})\nexport class Fs2FAVerificationSMSComponent {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n public code: string;\n\n public codeChanged(): void {\n this.codeChange.emit(this.code);\n }\n\n}\n","<p class=\"description\">\n <ng-container *ngIf=\"method.phoneNumber && method.type === 'sms'\">\n A text message with a verification code was just\n sent to <span style=\"white-space: nowrap;\">{{ method.phoneNumber }}</span> to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"method.type === 'email'\">\n A email with a verification code was just sent to {{ method.email }} to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"false\">\n Enter the one time code generated by the app administrator to verify it's you.\n </ng-container>\n</p>\n\n<mat-form-field>\n <mat-label>Code</mat-label>\n <input type=\"text\"\n matInput\n name=\"code\"\n autocomplete=\"one-time-code\"\n [(ngModel)]=\"code\"\n (ngModelChange)=\"codeChanged()\"\n required\n placeholder=\"Enter the code\"\n inputmode=\"numeric\">\n</mat-form-field>\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n Inject,\n Input,\n OnDestroy,\n Output,\n} from '@angular/core';\n\nimport { FsDialog } from '@firestitch/dialog';\n\nimport { filter, takeUntil, tap } from 'rxjs/operators';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\nimport { Fs2FaVerificationMethodsComponent } from '../2fa-verification-methods/2fa-verification-methods.component';\nimport { Subject } from 'rxjs';\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification',\n templateUrl: './2fa-verification.component.html',\n styleUrls: [\n './2fa-verification.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationComponent implements OnDestroy {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public verified = new EventEmitter<unknown>();\n\n @Output()\n public backToSignIn = new EventEmitter<void>();\n\n\n public resendInProgress = false;\n public trustedDevice = false;\n\n private _code: string;\n private _destroy$ = new Subject<void>();\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n public verificationProvider: IFsVerificationProvider,\n private _cdRef: ChangeDetectorRef,\n private _dialog: FsDialog,\n ) {}\n\n public ngOnDestroy(): void {\n this._destroy$.next();\n this._destroy$.complete();\n }\n\n public verify = () => {\n return this.verificationProvider\n .verify(this._code, this.trustedDevice)\n .pipe(\n tap((response) => {\n this.verified.emit(response);\n }),\n );\n };\n\n public codeChanged(code: string): void {\n this._code = code;\n }\n\n public resend(): void {\n this.resendInProgress = true;\n\n this.verificationProvider\n .resend()\n .pipe(\n takeUntil(this._destroy$),\n )\n .subscribe(() => {\n this.resendInProgress = false;\n\n this._cdRef.markForCheck();\n })\n }\n\n public showVerificationMethods(): void {\n this._dialog.open(\n Fs2FaVerificationMethodsComponent,\n {\n data: {\n method: this.method,\n }\n }\n )\n .afterClosed()\n .pipe(\n filter((method) => !!method),\n )\n .subscribe((method) => {\n this.method = method;\n\n this._cdRef.markForCheck();\n });\n }\n\n public toSignIn(): void {\n this.backToSignIn.emit();\n }\n\n}\n","<form fsForm [submit]=\"verify\" [dirtySubmitButton]=\"false\">\n <h2>2-Step Verification</h2>\n\n <div class=\"code-container\">\n <ng-container *ngIf=\"method.type === 'authenticator' else code\">\n <fs-2fa-verification-otp class=\"otp\"></fs-2fa-verification-otp>\n </ng-container>\n\n <ng-template #code>\n <fs-2fa-verification-code\n [method]=\"method\"\n (codeChange)=\"codeChanged($event)\">\n </fs-2fa-verification-code>\n </ng-template>\n </div>\n\n <div class=\"additional\">\n <mat-checkbox\n name=\"trust-device\"\n [(ngModel)]=\"trustedDevice\">\n Trust this device\n </mat-checkbox>\n\n <span matSuffix>\n <a mat-button\n type=\"button\"\n color=\"primary\"\n (click)=\"resend()\"\n [disabled]=\"resendInProgress\"\n class=\"resend-code-btn\">\n <ng-container *ngIf=\"!resendInProgress else sending\">\n Resend Code\n </ng-container>\n <ng-template #sending>\n <mat-spinner [diameter]=\"12\"></mat-spinner> Sending\n </ng-template>\n </a>\n </span>\n </div>\n\n <div class=\"actions\">\n <button mat-raised-button\n color=\"primary\"\n type=\"submit\">\n Verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"showVerificationMethods()\">\n Try other ways to verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"toSignIn()\">\n Back to signin\n </button>\n </div>\n</form>\n","import { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { CommonModule } from '@angular/common';\n\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatRadioModule } from '@angular/material/radio';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\n\nimport { FsFormModule } from '@firestitch/form';\nimport { FsSkeletonModule } from '@firestitch/skeleton';\nimport { FsRadioGroupModule } from '@firestitch/radiogroup';\nimport { FsDialogModule } from '@firestitch/dialog';\n\n// import { CodeInputModule } from 'angular-code-input';\n\nimport { Fs2FAVerificationComponent } from './components/2fa-verification/2fa-verification.component';\nimport { Fs2FAVerificationSMSComponent } from './components/2fa-verification-code/2fa-verification-code.component';\nimport { Fs2FAVerificationOTPComponent } from './components/2fa-verification-otp/2fa-verification-otp.component';\nimport { Fs2FaVerificationMethodsComponent } from './components/2fa-verification-methods/2fa-verification-methods.component';\n\n\n@NgModule({\n imports: [\n CommonModule,\n FormsModule,\n\n MatFormFieldModule,\n MatInputModule,\n MatButtonModule,\n\n FsFormModule,\n FsRadioGroupModule,\n FsDialogModule,\n\n // CodeInputModule,\n MatCheckboxModule,\n MatProgressSpinnerModule,\n FsSkeletonModule,\n FsSkeletonModule,\n MatIconModule,\n MatRadioModule,\n ],\n declarations: [\n Fs2FAVerificationComponent,\n\n Fs2FAVerificationSMSComponent,\n Fs2FAVerificationOTPComponent,\n Fs2FaVerificationMethodsComponent,\n ],\n exports: [\n Fs2FAVerificationComponent,\n ],\n providers: [],\n})\nexport class Fs2FaModule {}\n","/*\n * Public API Surface of fs-2fa\n */\n\nexport { Fs2FaModule } from './app/fs-2fa.module';\n\n// Components\nexport { Fs2FAVerificationComponent } from './app/components/2fa-verification/2fa-verification.component';\n\nexport { IFsVerificationProvider } from './app/interfaces/verification-provider.interface';\nexport { IFsVerificationMethod } from './app/interfaces/verification-method.interface';\n\nexport { FsVerificationMethodType } from './app/enums/verification-method-type.enum';\n\nexport { FS_2FA_VERIFICATION_PROVIDER } from './app/tokens/verification.token';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["InjectionToken","FsVerificationMethodType","tap","map","shareReplay","MAT_DIALOG_DATA","Component","ChangeDetectionStrategy","Inject","EventEmitter","Output","ControlContainer","NgForm","Input","Subject","takeUntil","filter","CommonModule","FormsModule","MatFormFieldModule","MatInputModule","MatButtonModule","FsFormModule","FsRadioGroupModule","FsDialogModule","MatCheckboxModule","MatProgressSpinnerModule","FsSkeletonModule","MatIconModule","MatRadioModule","NgModule"],"mappings":";;;;;;;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;;;;;;;;;;;"}
1
+ {"version":3,"file":"firestitch-2fa.umd.js","sources":["../../src/app/tokens/verification.token.ts","../../src/app/enums/verification-method-type.enum.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.html","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.ts","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.html","../../src/app/components/2fa-verification-code/2fa-verification-code.component.ts","../../src/app/components/2fa-verification-code/2fa-verification-code.component.html","../../src/app/components/2fa-verification/2fa-verification.component.ts","../../src/app/components/2fa-verification/2fa-verification.component.html","../../src/app/fs-2fa.module.ts","../../src/public_api.ts","../../src/firestitch-2fa.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nimport { IFsVerificationProvider } from '../interfaces/verification-provider.interface';\n\nexport const FS_2FA_VERIFICATION_PROVIDER = new InjectionToken<IFsVerificationProvider>(\n 'Provider for Verification service',\n);\n","export enum FsVerificationMethodType {\n Sms = 'sms',\n Email = 'email',\n Authenticator = 'authenticator',\n Code = 'code',\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n Inject,\n} from '@angular/core';\n\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\n\nimport { Observable } from 'rxjs';\nimport { map, shareReplay, tap } from 'rxjs/operators';\n\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { FsVerificationMethodType } from '../../enums/verification-method-type.enum';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n templateUrl: './2fa-verification-methods.component.html',\n styleUrls: [\n './2fa-verification-methods.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FaVerificationMethodsComponent {\n\n public method: IFsVerificationMethod;\n public phone: string;\n public code: string;\n public methods$: Observable<Record<string, IFsVerificationMethod[]>>;\n public readonly verificationMethodType = FsVerificationMethodType;\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n private _verificationProvider: IFsVerificationProvider,\n @Inject(MAT_DIALOG_DATA)\n private _dialogData: any,\n private _dialogRef: MatDialogRef<Fs2FaVerificationMethodsComponent>,\n ) {\n this._setActiveMethod();\n this._initMethods();\n }\n\n public compareWith(o1, o2) {\n return o1 && o2 && o1.id === o2.id\n }\n\n public setVerificationMethod = () => {\n return this._verificationProvider\n .updateVerificationMethod(this.method.id)\n .pipe(\n tap((method: IFsVerificationMethod) => {\n this._dialogRef.close(method);\n })\n );\n };\n\n private _setActiveMethod(): void {\n this.method = this._dialogData?.method;\n }\n\n private _initMethods(): void {\n this.methods$ = this._verificationProvider\n .methods()\n .pipe(\n map((methods) => {\n return methods\n .reduce((acc, method) => {\n if (!acc[method.type]) {\n acc[method.type] = [];\n }\n\n acc[method.type].push(method);\n\n return acc;\n }, {});\n }),\n shareReplay(1),\n );\n }\n}\n","<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\" [dirtySubmitButton]=\"false\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Output,\n} from '@angular/core';\n\nimport { FsFormDirective } from '@firestitch/form';\n\n\n@Component({\n selector: 'fs-2fa-verification-otp',\n templateUrl: './2fa-verification-otp.component.html',\n styleUrls: [\n './2fa-verification-otp.component.scss'\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationOTPComponent {\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n constructor(\n public form: FsFormDirective,\n ) {}\n\n public codeChanged(event: string): void {\n this.codeChange.emit(event);\n this.form.dirty();\n }\n\n public codeCompleted(): void {\n this.form.triggerSubmit();\n }\n}\n","<p class=\"description\">\n Enter the verification code generated by your 2 factor authenticator\n app to verify it's you\n</p>\n\n<!--\n<code-input [initialFocusField]=\"0\"\n [codeLength]=\"6\"\n (codeChanged)=\"codeChanged($event)\"\n (codeCompleted)=\"codeCompleted()\">>\n</code-input>\n-->\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Input,\n Output,\n} from '@angular/core';\nimport { ControlContainer, NgForm } from '@angular/forms';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification-code',\n templateUrl: './2fa-verification-code.component.html',\n styleUrls: [\n './2fa-verification-code.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n viewProviders: [\n {\n provide: ControlContainer,\n useExisting: NgForm,\n },\n ],\n})\nexport class Fs2FAVerificationSMSComponent {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n public code: string;\n\n public codeChanged(): void {\n this.codeChange.emit(this.code);\n }\n\n}\n","<p class=\"description\">\n <ng-container *ngIf=\"method.phoneNumber && method.type === 'sms'\">\n A text message with a verification code was just\n sent to <span style=\"white-space: nowrap;\">{{ method.phoneNumber }}</span> to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"method.type === 'email'\">\n A email with a verification code was just sent to {{ method.email }} to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"false\">\n Enter the one time code generated by the app administrator to verify it's you.\n </ng-container>\n</p>\n\n<mat-form-field>\n <mat-label>Code</mat-label>\n <input type=\"text\"\n matInput\n name=\"code\"\n autocomplete=\"one-time-code\"\n [(ngModel)]=\"code\"\n (ngModelChange)=\"codeChanged()\"\n required\n placeholder=\"Enter the code\"\n inputmode=\"numeric\">\n</mat-form-field>\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n Inject,\n Input,\n OnDestroy,\n Output,\n} from '@angular/core';\n\nimport { FsDialog } from '@firestitch/dialog';\n\nimport { filter, takeUntil, tap } from 'rxjs/operators';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\nimport { Fs2FaVerificationMethodsComponent } from '../2fa-verification-methods/2fa-verification-methods.component';\nimport { Subject } from 'rxjs';\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification',\n templateUrl: './2fa-verification.component.html',\n styleUrls: [\n './2fa-verification.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationComponent implements OnDestroy {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public verified = new EventEmitter<unknown>();\n\n @Output()\n public backToSignIn = new EventEmitter<void>();\n\n\n public resendInProgress = false;\n public trustedDevice = false;\n\n private _code: string;\n private _destroy$ = new Subject<void>();\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n public verificationProvider: IFsVerificationProvider,\n private _cdRef: ChangeDetectorRef,\n private _dialog: FsDialog,\n ) {}\n\n public ngOnDestroy(): void {\n this._destroy$.next();\n this._destroy$.complete();\n }\n\n public verify = () => {\n return this.verificationProvider\n .verify(this._code, this.trustedDevice)\n .pipe(\n tap((response) => {\n this.verified.emit(response);\n }),\n );\n };\n\n public codeChanged(code: string): void {\n this._code = code;\n }\n\n public resend(): void {\n this.resendInProgress = true;\n\n this.verificationProvider\n .resend()\n .pipe(\n takeUntil(this._destroy$),\n )\n .subscribe(() => {\n this.resendInProgress = false;\n\n this._cdRef.markForCheck();\n })\n }\n\n public showVerificationMethods(): void {\n this._dialog.open(\n Fs2FaVerificationMethodsComponent,\n {\n data: {\n method: this.method,\n }\n }\n )\n .afterClosed()\n .pipe(\n filter((method) => !!method),\n )\n .subscribe((method) => {\n this.method = method;\n\n this._cdRef.markForCheck();\n });\n }\n\n public toSignIn(): void {\n this.backToSignIn.emit();\n }\n\n}\n","<form fsForm [submit]=\"verify\" [dirtySubmitButton]=\"false\">\n <h2>2-Step Verification</h2>\n\n <div class=\"code-container\">\n <ng-container *ngIf=\"method.type === 'authenticator' else code\">\n <fs-2fa-verification-otp class=\"otp\"></fs-2fa-verification-otp>\n </ng-container>\n\n <ng-template #code>\n <fs-2fa-verification-code\n [method]=\"method\"\n (codeChange)=\"codeChanged($event)\">\n </fs-2fa-verification-code>\n </ng-template>\n </div>\n\n <div class=\"additional\">\n <mat-checkbox\n name=\"trust-device\"\n [(ngModel)]=\"trustedDevice\">\n Trust this device\n </mat-checkbox>\n\n <span matSuffix>\n <a mat-button\n type=\"button\"\n color=\"primary\"\n (click)=\"resend()\"\n [disabled]=\"resendInProgress\"\n class=\"resend-code-btn\">\n <ng-container *ngIf=\"!resendInProgress else sending\">\n Resend Code\n </ng-container>\n <ng-template #sending>\n <mat-spinner [diameter]=\"12\"></mat-spinner> Sending\n </ng-template>\n </a>\n </span>\n </div>\n\n <div class=\"actions\">\n <button mat-raised-button\n color=\"primary\"\n type=\"submit\">\n Verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"showVerificationMethods()\">\n Try other ways to verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"toSignIn()\">\n Back to signin\n </button>\n </div>\n</form>\n","import { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { CommonModule } from '@angular/common';\n\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatRadioModule } from '@angular/material/radio';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\n\nimport { FsFormModule } from '@firestitch/form';\nimport { FsSkeletonModule } from '@firestitch/skeleton';\nimport { FsRadioGroupModule } from '@firestitch/radiogroup';\nimport { FsDialogModule } from '@firestitch/dialog';\n\n// import { CodeInputModule } from 'angular-code-input';\n\nimport { Fs2FAVerificationComponent } from './components/2fa-verification/2fa-verification.component';\nimport { Fs2FAVerificationSMSComponent } from './components/2fa-verification-code/2fa-verification-code.component';\nimport { Fs2FAVerificationOTPComponent } from './components/2fa-verification-otp/2fa-verification-otp.component';\nimport { Fs2FaVerificationMethodsComponent } from './components/2fa-verification-methods/2fa-verification-methods.component';\n\n\n@NgModule({\n imports: [\n CommonModule,\n FormsModule,\n\n MatFormFieldModule,\n MatInputModule,\n MatButtonModule,\n\n FsFormModule,\n FsRadioGroupModule,\n FsDialogModule,\n\n // CodeInputModule,\n MatCheckboxModule,\n MatProgressSpinnerModule,\n FsSkeletonModule,\n FsSkeletonModule,\n MatIconModule,\n MatRadioModule,\n ],\n declarations: [\n Fs2FAVerificationComponent,\n\n Fs2FAVerificationSMSComponent,\n Fs2FAVerificationOTPComponent,\n Fs2FaVerificationMethodsComponent,\n ],\n exports: [\n Fs2FAVerificationComponent,\n ],\n providers: [],\n})\nexport class Fs2FaModule {}\n","/*\n * Public API Surface of fs-2fa\n */\n\nexport { Fs2FaModule } from './app/fs-2fa.module';\n\n// Components\nexport { Fs2FAVerificationComponent } from './app/components/2fa-verification/2fa-verification.component';\n\nexport { IFsVerificationProvider } from './app/interfaces/verification-provider.interface';\nexport { IFsVerificationMethod } from './app/interfaces/verification-method.interface';\n\nexport { FsVerificationMethodType } from './app/enums/verification-method-type.enum';\n\nexport { FS_2FA_VERIFICATION_PROVIDER } from './app/tokens/verification.token';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["InjectionToken","FsVerificationMethodType","tap","map","shareReplay","MAT_DIALOG_DATA","Component","ChangeDetectionStrategy","Inject","EventEmitter","Output","ControlContainer","NgForm","Input","Subject","takeUntil","filter","CommonModule","FormsModule","MatFormFieldModule","MatInputModule","MatButtonModule","FsFormModule","FsRadioGroupModule","FsDialogModule","MatCheckboxModule","MatProgressSpinnerModule","FsSkeletonModule","MatIconModule","MatRadioModule","NgModule"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAIa,4BAA4B,GAAG,IAAIA,iBAAc,CAC5D,mCAAmC;;ACLzBC;IAAZ,WAAY,wBAAwB;QAClC,uCAAW,CAAA;QACX,2CAAe,CAAA;QACf,2DAA+B,CAAA;QAC/B,y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EoBT;;;;mIAAa,WAAW;oIAAX,WAAW,iBAXpB,0BAA0B;YAE1B,6BAA6B;YAC7B,6BAA6B;YAC7B,iCAAiC,aAxBjCO,gBAAY;YACZC,cAAW;YAEXC,uBAAkB;YAClBC,mBAAc;YACdC,oBAAe;YAEfC,eAAY;YACZC,qBAAkB;YAClBC,mBAAc;;YAGdC,sBAAiB;YACjBC,2BAAwB;YACxBC,mBAAgB;YAChBA,mBAAgB;YAChBC,gBAAa;YACbC,iBAAc,aAUd,0BAA0B;oIAIjB,WAAW,aAFX,EAAE,YA9BJ;gBACPZ,gBAAY;gBACZC,cAAW;gBAEXC,uBAAkB;gBAClBC,mBAAc;gBACdC,oBAAe;gBAEfC,eAAY;gBACZC,qBAAkB;gBAClBC,mBAAc;;gBAGdC,sBAAiB;gBACjBC,2BAAwB;gBACxBC,mBAAgB;gBAChBA,mBAAgB;gBAChBC,gBAAa;gBACbC,iBAAc;aACf;sHAaU,WAAW;sBAjCvBC,WAAQ;uBAAC;wBACR,OAAO,EAAE;4BACPb,gBAAY;4BACZC,cAAW;4BAEXC,uBAAkB;4BAClBC,mBAAc;4BACdC,oBAAe;4BAEfC,eAAY;4BACZC,qBAAkB;4BAClBC,mBAAc;;4BAGdC,sBAAiB;4BACjBC,2BAAwB;4BACxBC,mBAAgB;4BAChBA,mBAAgB;4BAChBC,gBAAa;4BACbC,iBAAc;yBACf;wBACD,YAAY,EAAE;4BACZ,0BAA0B;4BAE1B,6BAA6B;4BAC7B,6BAA6B;4BAC7B,iCAAiC;yBAClC;wBACD,OAAO,EAAE;4BACP,0BAA0B;yBAC3B;wBACD,SAAS,EAAE,EAAE;qBACd;;;ICzDD;;;;ICAA;;;;;;;;;;;;;;"}
@@ -53,7 +53,7 @@ export class Fs2FaVerificationMethodsComponent {
53
53
  }
54
54
  }
55
55
  Fs2FaVerificationMethodsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: Fs2FaVerificationMethodsComponent, deps: [{ token: FS_2FA_VERIFICATION_PROVIDER }, { token: MAT_DIALOG_DATA }, { token: i1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
56
- Fs2FaVerificationMethodsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: Fs2FaVerificationMethodsComponent, selector: "ng-component", ngImport: i0, template: "<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n", styles: [".method{display:block;margin-bottom:20px}.method .method-header{display:flex;align-items:flex-start}.method .method-header .method-name{margin-left:10px}.method .method-header .method-name .method-title{font-size:14px;font-weight:400}.method .method-header .method-name .method-subtitle{font-size:12px;color:#a3a3a3}.method .method-item{display:block;margin:10px 0 0 35px}\n"], components: [{ type: i2.FsDialogComponent, selector: "fs-dialog", inputs: ["mobileMode"] }, { type: i3.FsRadioGroupComponent, selector: "fs-radio-group", inputs: ["orientation", "radioPosition", "compareWith", "required", "disabled", "label", "name"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i6.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i7.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i7.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i7.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i8.FsFormDirective, selector: "[fsForm]", inputs: ["wrapperSelector", "messageSelector", "hintSelector", "labelSelector", "autocomplete", "shortcuts", "confirm", "confirmDialog", "confirmDrawer", "confirmBrowser", "confirmTabs", "dirtySubmitButton", "successDelay", "errorDelay", "submit", "tabGroup"], outputs: ["fsForm", "invalid", "valid", "submitted", "reseted", "cleared"] }, { type: i1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i9.ɵa, selector: "[fsSkeleton]", inputs: ["fsSkeletonPattern", "fsSkeleton"] }, { type: i7.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i7.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i10.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.ɵw, selector: "button[type=\"submit\"]", inputs: ["dirtySubmit", "name"] }, { type: i1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["type", "mat-dialog-close", "aria-label", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "async": i10.AsyncPipe, "keyvalue": i10.KeyValuePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
56
+ Fs2FaVerificationMethodsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: Fs2FaVerificationMethodsComponent, selector: "ng-component", ngImport: i0, template: "<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\" [dirtySubmitButton]=\"false\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n", styles: [".method{display:block;margin-bottom:20px}.method .method-header{display:flex;align-items:flex-start}.method .method-header .method-name{margin-left:10px}.method .method-header .method-name .method-title{font-size:14px;font-weight:400}.method .method-header .method-name .method-subtitle{font-size:12px;color:#a3a3a3}.method .method-item{display:block;margin:10px 0 0 35px}\n"], components: [{ type: i2.FsDialogComponent, selector: "fs-dialog", inputs: ["mobileMode"] }, { type: i3.FsRadioGroupComponent, selector: "fs-radio-group", inputs: ["orientation", "radioPosition", "compareWith", "required", "disabled", "label", "name"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i6.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i7.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i7.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i7.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i8.FsFormDirective, selector: "[fsForm]", inputs: ["wrapperSelector", "messageSelector", "hintSelector", "labelSelector", "autocomplete", "shortcuts", "confirm", "confirmDialog", "confirmDrawer", "confirmBrowser", "confirmTabs", "dirtySubmitButton", "successDelay", "errorDelay", "submit", "tabGroup"], outputs: ["fsForm", "invalid", "valid", "submitted", "reseted", "cleared"] }, { type: i1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i9.ɵa, selector: "[fsSkeleton]", inputs: ["fsSkeletonPattern", "fsSkeleton"] }, { type: i7.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i7.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i10.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.ɵw, selector: "button[type=\"submit\"]", inputs: ["dirtySubmit", "name"] }, { type: i1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["type", "mat-dialog-close", "aria-label", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "async": i10.AsyncPipe, "keyvalue": i10.KeyValuePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
57
57
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: Fs2FaVerificationMethodsComponent, decorators: [{
58
58
  type: Component,
59
59
  args: [{
@@ -70,4 +70,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImpo
70
70
  type: Inject,
71
71
  args: [MAT_DIALOG_DATA]
72
72
  }] }, { type: i1.MatDialogRef }]; } });
73
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMmZhLXZlcmlmaWNhdGlvbi1tZXRob2RzLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3NyYy9hcHAvY29tcG9u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7XG4gICAgICAgICAgICAgIGlmICghYWNjW21ldGhvZC50eXBlXSkge1xuICAgICAgICAgICAgICAgIGFjY1ttZXRob2QudHlwZV0gPSBbXTtcbiAgICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICAgIGFjY1ttZXRob2QudHlwZV0ucHVzaChtZXRob2QpO1xuXG4gICAgICAgICAgICAgIHJldHVybiBhY2M7XG4gICAgICAgICAgICB9LCB7fSk7XG4gICAgICAgIH0pLFxuICAgICAgICBzaGFyZVJlcGxheSgxKSxcbiAgICAgICk7XG4gIH1cbn1cbiIsIjxmcy1kaWFsb2c+XG4gIDxoMSBtYXQtZGlhbG9nLXRpdGxlPlxuICAgIFZlcmlmaWNhdGlvbiBNZXRob2RzXG4gIDwvaDE+XG4gIDxmb3JtIGZzRm9ybSBbc3VibWl0XT1cInNldFZlcmlmaWNhdGlvbk1ldGhvZFwiPlxuICAgIDxtYXQtZGlhbG9nLWNvbnRlbnQ+XG4gICAgICA8bmctY29udGFpbmVyICpmc1NrZWxldG9uPVwibWV0aG9kcyQgfCBhc3luYyBhcyBtZXRob2RzXCI+XG4gICAgICAgIDxmcy1yYWRpby1ncm91cCBbKG5nTW9kZWwpXT1cIm1ldGhvZFwiIG5hbWU9XCJtZXRob2RcIiBbY29tcGFyZVdpdGhdPVwiY29tcGFyZVdpdGhcIj5cbiAgICAgICAgICA8bmctY29udGFpbmVyICpuZ0Zvcj1cImxldCBtZXRob2RNYXAgb2YgbWV0aG9kcyB8IGtleXZhbHVlXCI+XG4gICAgICAgICAgICA8ZGl2IGNsYXNzPVwibWV0aG9kXCI+XG4gICAgICAgICAgICAgIDxuZy1jb250YWluZXIgW25nU3dpdGNoXT1cIm1ldGhvZE1hcC5rZXlcIj5cbiAgICAgICAgICAgICAgICA8bmctY29udGFpbmVyICpuZ1N3aXRjaENhc2U9XCJ2ZXJpZmljYXRpb25NZXRob2RUeXBlLlNtc1wiPlxuICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1oZWFkZXJcIj5cbiAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1pY29uXCI+XG4gICAgICAgICAgICAgICAgICAgICAgPG1hdC1pY29uPlxuICAgICAgICAgICAgICAgICAgICAgICAgc21hcnRwaG9uZVxuICAgICAgICAgICAgICAgICAgICAgIDwvbWF0LWljb24+XG4gICAgICAgICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwibWV0aG9kLW5hbWVcIj5cbiAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwibWV0aG9kLXRpdGxlXCI+VGV4dCBNZXNzYWdlPC9kaXY+XG4gICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1zdWJ0aXRsZVwiPlxuICAgICAgICAgICAgICAgICAgICAgICAgVmVyaWZpY2F0aW9uIGNvZGUgc2VuZCB0byBvbmUgb2YgZm9sbG93aW5nIG1vYmlsZSBudW1iZXJcbiAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgICAgICA8L25nLWNvbnRhaW5lcj5cblxuICAgICAgICAgICAgICAgIDxuZy1jb250YWluZXIgKm5nU3dpdGNoQ2FzZT1cInZlcmlmaWNhdGlvbk1ldGhvZFR5cGUuRW1haWxcIj5cbiAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJtZXRob2QtaGVhZGVyXCI+XG4gICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJtZXRob2QtaWNvblwiPlxuICAgICAgICAgICAgICAgICAgICAgIDxtYXQtaWNvbj5cbiAgICAgICAgICAgICAgICAgICAgICAgIG1haWxcbiAgICAgICAgICAgICAgICAgICAgICA8L21hdC1pY29uPlxuICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1uYW1lXCI+XG4gICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC10aXRsZVwiPkVtYWlsPC9kaXY+XG4gICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1zdWJ0aXRsZVwiPlxuICAgICAgICAgICAgICAgICAgICAgICAgVmVyaWZpY2F0aW9uIGNvZGUgc2VuZCB0byBvbmUgb2YgZm9sbG93aW5nIGVtYWlsXG4gICAgICAgICAgICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgICAgICAgPC9uZy1jb250YWluZXI+XG4gICAgICAgICAgICAgIDwvbmctY29udGFpbmVyPlxuXG4gICAgICAgICAgICAgIDxuZy1jb250YWluZXIgW25nU3dpdGNoXT1cIm1ldGhvZE1hcC5rZXlcIj5cbiAgICAgICAgICAgICAgICA8bmctY29udGFpbmVyICpuZ1N3aXRjaENhc2U9XCJ2ZXJpZmljYXRpb25NZXRob2RUeXBlLlNtc1wiPlxuICAgICAgICAgICAgICAgICAgPG1hdC1yYWRpby1idXR0b24gY2xhc3M9XCJtZXRob2QtaXRlbVwiICpuZ0Zvcj1cImxldCBtZXRob2Qgb2YgbWV0aG9kTWFwLnZhbHVlXCIgW3ZhbHVlXT1cIm1ldGhvZFwiPlxuICAgICAgICAgICAgICAgICAgICB7eyBtZXRob2QucGhvbmVOdW1iZXIgfX1cbiAgICAgICAgICAgICAgICAgIDwvbWF0LXJhZGlvLWJ1dHRvbj5cbiAgICAgICAgICAgICAgICA8L25nLWNvbnRhaW5lcj5cblxuICAgICAgICAgICAgICAgIDxuZy1jb250YWluZXIgKm5nU3dpdGNoQ2FzZT1cInZlcmlmaWNhdGlvbk1ldGhvZFR5cGUuRW1haWxcIj5cbiAgICAgICAgICAgICAgICAgIDxtYXQtcmFkaW8tYnV0dG9uIGNsYXNzPVwibWV0aG9kLWl0ZW1cIiAqbmdGb3I9XCJsZXQgbWV0aG9kIG9mIG1ldGhvZE1hcC52YWx1ZVwiIFt2YWx1ZV09XCJtZXRob2RcIj5cbiAgICAgICAgICAgICAgICAgICAge3sgbWV0aG9kLmVtYWlsIH19XG4gICAgICAgICAgICAgICAgICA8L21hdC1yYWRpby1idXR0b24+XG4gICAgICAgICAgICAgICAgPC9uZy1jb250YWluZXI+XG4gICAgICAgICAgICAgIDwvbmctY29udGFpbmVyPlxuICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgPC9uZy1jb250YWluZXI+XG4gICAgICAgIDwvZnMtcmFkaW8tZ3JvdXA+XG4gICAgICA8L25nLWNvbnRhaW5lcj5cbiAgICA8L21hdC1kaWFsb2ctY29udGVudD5cbiAgICA8bWF0LWRpYWxvZy1hY3Rpb25zPlxuICAgICAgPGRpdiBjbGFzcz1cImFjdGlvbnNcIj5cbiAgICAgICAgPG5nLWNvbnRhaW5lciAqbmdJZj1cIm1ldGhvZHMkIHwgYXN5bmNcIj5cbiAgICAgICAgICA8YnV0dG9uIG1hdC1idXR0b24gdHlwZT1cInN1Ym1pdFwiIGNvbG9yPVwicHJpbWFyeVwiPk5leHQ8L2J1dHRvbj5cbiAgICAgICAgPC9uZy1jb250YWluZXI+XG4gICAgICAgIDxidXR0b24gbWF0LWJ1dHRvbiB0eXBlPVwiYnV0dG9uXCIgW21hdC1kaWFsb2ctY2xvc2VdPVwibnVsbFwiPkNhbmNlbDwvYnV0dG9uPlxuICAgICAgPC9kaXY+XG4gICAgPC9tYXQtZGlhbG9nLWFjdGlvbnM+XG4gIDwvZm9ybT5cbjwvZnMtZGlhbG9nPlxuIl19
73
+ //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMmZhLXZlcmlmaWNhdGlvbi1tZXRob2RzLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOi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ICpuZ1N3aXRjaENhc2U9XCJ2ZXJpZmljYXRpb25NZXRob2RUeXBlLlNtc1wiPlxuICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1oZWFkZXJcIj5cbiAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1pY29uXCI+XG4gICAgICAgICAgICAgICAgICAgICAgPG1hdC1pY29uPlxuICAgICAgICAgICAgICAgICAgICAgICAgc21hcnRwaG9uZVxuICAgICAgICAgICAgICAgICAgICAgIDwvbWF0LWljb24+XG4gICAgICAgICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwibWV0aG9kLW5hbWVcIj5cbiAgICAgICAgICAgICAgICAgICAgICA8ZGl2IGNsYXNzPVwibWV0aG9kLXRpdGxlXCI+VGV4dCBNZXNzYWdlPC9kaXY+XG4gICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1zdWJ0aXRsZVwiPlxuICAgICAgICAgICAgICAgICAgICAgICAgVmVyaWZpY2F0aW9uIGNvZGUgc2VuZCB0byBvbmUgb2YgZm9sbG93aW5nIG1vYmlsZSBudW1iZXJcbiAgICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgICAgICA8L25nLWNvbnRhaW5lcj5cblxuICAgICAgICAgICAgICAgIDxuZy1jb250YWluZXIgKm5nU3dpdGNoQ2FzZT1cInZlcmlmaWNhdGlvbk1ldGhvZFR5cGUuRW1haWxcIj5cbiAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJtZXRob2QtaGVhZGVyXCI+XG4gICAgICAgICAgICAgICAgICAgIDxkaXYgY2xhc3M9XCJtZXRob2QtaWNvblwiPlxuICAgICAgICAgICAgICAgICAgICAgIDxtYXQtaWNvbj5cbiAgICAgICAgICAgICAgICAgICAgICAgIG1haWxcbiAgICAgICAgICAgICAgICAgICAgICA8L21hdC1pY29uPlxuICAgICAgICAgICAgICAgICAgICA8L2Rpdj5cbiAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1uYW1lXCI+XG4gICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC10aXRsZVwiPkVtYWlsPC9kaXY+XG4gICAgICAgICAgICAgICAgICAgICAgPGRpdiBjbGFzcz1cIm1ldGhvZC1zdWJ0aXRsZVwiPlxuICAgICAgICAgICAgICAgICAgICAgICAgVmVyaWZpY2F0aW9uIGNvZGUgc2VuZCB0byBvbmUgb2YgZm9sbG93aW5nIGVtYWlsXG4gICAgICAgICAgICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgICAgICAgICAgIDwvZGl2PlxuICAgICAgICAgICAgICAgICAgPC9kaXY+XG4gICAgICAgICAgICAgICAgPC9uZy1jb250YWluZXI+XG4gICAgICAgICAgICAgIDwvbmctY29udGFpbmVyPlxuXG4gICAgICAgICAgICAgIDxuZy1jb250YWluZXIgW25nU3dpdGNoXT1cIm1ldGhvZE1hcC5rZXlcIj5cbiAgICAgICAgICAgICAgICA8bmctY29udGFpbmVyICpuZ1N3aXRjaENhc2U9XCJ2ZXJpZmljYXRpb25NZXRob2RUeXBlLlNtc1wiPlxuICAgICAgICAgICAgICAgICAgPG1hdC1yYWRpby1idXR0b24gY2xhc3M9XCJtZXRob2QtaXRlbVwiICpuZ0Zvcj1cImxldCBtZXRob2Qgb2YgbWV0aG9kTWFwLnZhbHVlXCIgW3ZhbHVlXT1cIm1ldGhvZFwiPlxuICAgICAgICAgICAgICAgICAgICB7eyBtZXRob2QucGhvbmVOdW1iZXIgfX1cbiAgICAgICAgICAgICAgICAgIDwvbWF0LXJhZGlvLWJ1dHRvbj5cbiAgICAgICAgICAgICAgICA8L25nLWNvbnRhaW5lcj5cblxuICAgICAgICAgICAgICAg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2FaVerificationMethodsComponent {
80
80
  }
81
81
  }
82
82
  Fs2FaVerificationMethodsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: Fs2FaVerificationMethodsComponent, deps: [{ token: FS_2FA_VERIFICATION_PROVIDER }, { token: MAT_DIALOG_DATA }, { token: i1.MatDialogRef }], target: i0.ɵɵFactoryTarget.Component });
83
- Fs2FaVerificationMethodsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: Fs2FaVerificationMethodsComponent, selector: "ng-component", ngImport: i0, template: "<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n", styles: [".method{display:block;margin-bottom:20px}.method .method-header{display:flex;align-items:flex-start}.method .method-header .method-name{margin-left:10px}.method .method-header .method-name .method-title{font-size:14px;font-weight:400}.method .method-header .method-name .method-subtitle{font-size:12px;color:#a3a3a3}.method .method-item{display:block;margin:10px 0 0 35px}\n"], components: [{ type: i1$1.FsDialogComponent, selector: "fs-dialog", inputs: ["mobileMode"] }, { type: i3.FsRadioGroupComponent, selector: "fs-radio-group", inputs: ["orientation", "radioPosition", "compareWith", "required", "disabled", "label", "name"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i5$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i7.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i7.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i7.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i8.FsFormDirective, selector: "[fsForm]", inputs: ["wrapperSelector", "messageSelector", "hintSelector", "labelSelector", "autocomplete", "shortcuts", "confirm", "confirmDialog", "confirmDrawer", "confirmBrowser", "confirmTabs", "dirtySubmitButton", "successDelay", "errorDelay", "submit", "tabGroup"], outputs: ["fsForm", "invalid", "valid", "submitted", "reseted", "cleared"] }, { type: i1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i9.ɵa, selector: "[fsSkeleton]", inputs: ["fsSkeletonPattern", "fsSkeleton"] }, { type: i7.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i7.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i10.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.ɵw, selector: "button[type=\"submit\"]", inputs: ["dirtySubmit", "name"] }, { type: i1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["type", "mat-dialog-close", "aria-label", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "async": i10.AsyncPipe, "keyvalue": i10.KeyValuePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
83
+ Fs2FaVerificationMethodsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.16", type: Fs2FaVerificationMethodsComponent, selector: "ng-component", ngImport: i0, template: "<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\" [dirtySubmitButton]=\"false\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n", styles: [".method{display:block;margin-bottom:20px}.method .method-header{display:flex;align-items:flex-start}.method .method-header .method-name{margin-left:10px}.method .method-header .method-name .method-title{font-size:14px;font-weight:400}.method .method-header .method-name .method-subtitle{font-size:12px;color:#a3a3a3}.method .method-item{display:block;margin:10px 0 0 35px}\n"], components: [{ type: i1$1.FsDialogComponent, selector: "fs-dialog", inputs: ["mobileMode"] }, { type: i3.FsRadioGroupComponent, selector: "fs-radio-group", inputs: ["orientation", "radioPosition", "compareWith", "required", "disabled", "label", "name"] }, { type: i4.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { type: i5.MatRadioButton, selector: "mat-radio-button", inputs: ["disableRipple", "tabIndex"], exportAs: ["matRadioButton"] }, { type: i5$1.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }], directives: [{ type: i1.MatDialogTitle, selector: "[mat-dialog-title], [matDialogTitle]", inputs: ["id"], exportAs: ["matDialogTitle"] }, { type: i7.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i7.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i7.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i8.FsFormDirective, selector: "[fsForm]", inputs: ["wrapperSelector", "messageSelector", "hintSelector", "labelSelector", "autocomplete", "shortcuts", "confirm", "confirmDialog", "confirmDrawer", "confirmBrowser", "confirmTabs", "dirtySubmitButton", "successDelay", "errorDelay", "submit", "tabGroup"], outputs: ["fsForm", "invalid", "valid", "submitted", "reseted", "cleared"] }, { type: i1.MatDialogContent, selector: "[mat-dialog-content], mat-dialog-content, [matDialogContent]" }, { type: i9.ɵa, selector: "[fsSkeleton]", inputs: ["fsSkeletonPattern", "fsSkeleton"] }, { type: i7.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i7.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { type: i10.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { type: i1.MatDialogActions, selector: "[mat-dialog-actions], mat-dialog-actions, [matDialogActions]" }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i8.ɵw, selector: "button[type=\"submit\"]", inputs: ["dirtySubmit", "name"] }, { type: i1.MatDialogClose, selector: "[mat-dialog-close], [matDialogClose]", inputs: ["type", "mat-dialog-close", "aria-label", "matDialogClose"], exportAs: ["matDialogClose"] }], pipes: { "async": i10.AsyncPipe, "keyvalue": i10.KeyValuePipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
84
84
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.16", ngImport: i0, type: Fs2FaVerificationMethodsComponent, decorators: [{
85
85
  type: Component,
86
86
  args: [{
@@ -1 +1 @@
1
- {"version":3,"file":"firestitch-2fa.js","sources":["../../src/app/tokens/verification.token.ts","../../src/app/enums/verification-method-type.enum.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.html","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.ts","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.html","../../src/app/components/2fa-verification-code/2fa-verification-code.component.ts","../../src/app/components/2fa-verification-code/2fa-verification-code.component.html","../../src/app/components/2fa-verification/2fa-verification.component.ts","../../src/app/components/2fa-verification/2fa-verification.component.html","../../src/app/fs-2fa.module.ts","../../src/public_api.ts","../../src/firestitch-2fa.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nimport { IFsVerificationProvider } from '../interfaces/verification-provider.interface';\n\nexport const FS_2FA_VERIFICATION_PROVIDER = new InjectionToken<IFsVerificationProvider>(\n 'Provider for Verification service',\n);\n","export enum FsVerificationMethodType {\n Sms = 'sms',\n Email = 'email',\n Authenticator = 'authenticator',\n Code = 'code',\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n Inject,\n} from '@angular/core';\n\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\n\nimport { Observable } from 'rxjs';\nimport { map, shareReplay, tap } from 'rxjs/operators';\n\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { FsVerificationMethodType } from '../../enums/verification-method-type.enum';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n templateUrl: './2fa-verification-methods.component.html',\n styleUrls: [\n './2fa-verification-methods.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FaVerificationMethodsComponent {\n\n public method: IFsVerificationMethod;\n public phone: string;\n public code: string;\n public methods$: Observable<Record<string, IFsVerificationMethod[]>>;\n public readonly verificationMethodType = FsVerificationMethodType;\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n private _verificationProvider: IFsVerificationProvider,\n @Inject(MAT_DIALOG_DATA)\n private _dialogData: any,\n private _dialogRef: MatDialogRef<Fs2FaVerificationMethodsComponent>,\n ) {\n this._setActiveMethod();\n this._initMethods();\n }\n\n public compareWith(o1, o2) {\n return o1 && o2 && o1.id === o2.id\n }\n\n public setVerificationMethod = () => {\n return this._verificationProvider\n .updateVerificationMethod(this.method.id)\n .pipe(\n tap((method: IFsVerificationMethod) => {\n this._dialogRef.close(method);\n })\n );\n };\n\n private _setActiveMethod(): void {\n this.method = this._dialogData?.method;\n }\n\n private _initMethods(): void {\n this.methods$ = this._verificationProvider\n .methods()\n .pipe(\n map((methods) => {\n return methods\n .reduce((acc, method) => {\n if (!acc[method.type]) {\n acc[method.type] = [];\n }\n\n acc[method.type].push(method);\n\n return acc;\n }, {});\n }),\n shareReplay(1),\n );\n }\n}\n","<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Output,\n} from '@angular/core';\n\nimport { FsFormDirective } from '@firestitch/form';\n\n\n@Component({\n selector: 'fs-2fa-verification-otp',\n templateUrl: './2fa-verification-otp.component.html',\n styleUrls: [\n './2fa-verification-otp.component.scss'\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationOTPComponent {\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n constructor(\n public form: FsFormDirective,\n ) {}\n\n public codeChanged(event: string): void {\n this.codeChange.emit(event);\n this.form.dirty();\n }\n\n public codeCompleted(): void {\n this.form.triggerSubmit();\n }\n}\n","<p class=\"description\">\n Enter the verification code generated by your 2 factor authenticator\n app to verify it's you\n</p>\n\n<!--\n<code-input [initialFocusField]=\"0\"\n [codeLength]=\"6\"\n (codeChanged)=\"codeChanged($event)\"\n (codeCompleted)=\"codeCompleted()\">>\n</code-input>\n-->\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Input,\n Output,\n} from '@angular/core';\nimport { ControlContainer, NgForm } from '@angular/forms';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification-code',\n templateUrl: './2fa-verification-code.component.html',\n styleUrls: [\n './2fa-verification-code.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n viewProviders: [\n {\n provide: ControlContainer,\n useExisting: NgForm,\n },\n ],\n})\nexport class Fs2FAVerificationSMSComponent {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n public code: string;\n\n public codeChanged(): void {\n this.codeChange.emit(this.code);\n }\n\n}\n","<p class=\"description\">\n <ng-container *ngIf=\"method.phoneNumber && method.type === 'sms'\">\n A text message with a verification code was just\n sent to <span style=\"white-space: nowrap;\">{{ method.phoneNumber }}</span> to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"method.type === 'email'\">\n A email with a verification code was just sent to {{ method.email }} to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"false\">\n Enter the one time code generated by the app administrator to verify it's you.\n </ng-container>\n</p>\n\n<mat-form-field>\n <mat-label>Code</mat-label>\n <input type=\"text\"\n matInput\n name=\"code\"\n autocomplete=\"one-time-code\"\n [(ngModel)]=\"code\"\n (ngModelChange)=\"codeChanged()\"\n required\n placeholder=\"Enter the code\"\n inputmode=\"numeric\">\n</mat-form-field>\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n Inject,\n Input,\n OnDestroy,\n Output,\n} from '@angular/core';\n\nimport { FsDialog } from '@firestitch/dialog';\n\nimport { filter, takeUntil, tap } from 'rxjs/operators';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\nimport { Fs2FaVerificationMethodsComponent } from '../2fa-verification-methods/2fa-verification-methods.component';\nimport { Subject } from 'rxjs';\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification',\n templateUrl: './2fa-verification.component.html',\n styleUrls: [\n './2fa-verification.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationComponent implements OnDestroy {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public verified = new EventEmitter<unknown>();\n\n @Output()\n public backToSignIn = new EventEmitter<void>();\n\n\n public resendInProgress = false;\n public trustedDevice = false;\n\n private _code: string;\n private _destroy$ = new Subject<void>();\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n public verificationProvider: IFsVerificationProvider,\n private _cdRef: ChangeDetectorRef,\n private _dialog: FsDialog,\n ) {}\n\n public ngOnDestroy(): void {\n this._destroy$.next();\n this._destroy$.complete();\n }\n\n public verify = () => {\n return this.verificationProvider\n .verify(this._code, this.trustedDevice)\n .pipe(\n tap((response) => {\n this.verified.emit(response);\n }),\n );\n };\n\n public codeChanged(code: string): void {\n this._code = code;\n }\n\n public resend(): void {\n this.resendInProgress = true;\n\n this.verificationProvider\n .resend()\n .pipe(\n takeUntil(this._destroy$),\n )\n .subscribe(() => {\n this.resendInProgress = false;\n\n this._cdRef.markForCheck();\n })\n }\n\n public showVerificationMethods(): void {\n this._dialog.open(\n Fs2FaVerificationMethodsComponent,\n {\n data: {\n method: this.method,\n }\n }\n )\n .afterClosed()\n .pipe(\n filter((method) => !!method),\n )\n .subscribe((method) => {\n this.method = method;\n\n this._cdRef.markForCheck();\n });\n }\n\n public toSignIn(): void {\n this.backToSignIn.emit();\n }\n\n}\n","<form fsForm [submit]=\"verify\" [dirtySubmitButton]=\"false\">\n <h2>2-Step Verification</h2>\n\n <div class=\"code-container\">\n <ng-container *ngIf=\"method.type === 'authenticator' else code\">\n <fs-2fa-verification-otp class=\"otp\"></fs-2fa-verification-otp>\n </ng-container>\n\n <ng-template #code>\n <fs-2fa-verification-code\n [method]=\"method\"\n (codeChange)=\"codeChanged($event)\">\n </fs-2fa-verification-code>\n </ng-template>\n </div>\n\n <div class=\"additional\">\n <mat-checkbox\n name=\"trust-device\"\n [(ngModel)]=\"trustedDevice\">\n Trust this device\n </mat-checkbox>\n\n <span matSuffix>\n <a mat-button\n type=\"button\"\n color=\"primary\"\n (click)=\"resend()\"\n [disabled]=\"resendInProgress\"\n class=\"resend-code-btn\">\n <ng-container *ngIf=\"!resendInProgress else sending\">\n Resend Code\n </ng-container>\n <ng-template #sending>\n <mat-spinner [diameter]=\"12\"></mat-spinner> Sending\n </ng-template>\n </a>\n </span>\n </div>\n\n <div class=\"actions\">\n <button mat-raised-button\n color=\"primary\"\n type=\"submit\">\n Verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"showVerificationMethods()\">\n Try other ways to verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"toSignIn()\">\n Back to signin\n </button>\n </div>\n</form>\n","import { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { CommonModule } from '@angular/common';\n\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatRadioModule } from '@angular/material/radio';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\n\nimport { FsFormModule } from '@firestitch/form';\nimport { FsSkeletonModule } from '@firestitch/skeleton';\nimport { FsRadioGroupModule } from '@firestitch/radiogroup';\nimport { FsDialogModule } from '@firestitch/dialog';\n\n// import { CodeInputModule } from 'angular-code-input';\n\nimport { Fs2FAVerificationComponent } from './components/2fa-verification/2fa-verification.component';\nimport { Fs2FAVerificationSMSComponent } from './components/2fa-verification-code/2fa-verification-code.component';\nimport { Fs2FAVerificationOTPComponent } from './components/2fa-verification-otp/2fa-verification-otp.component';\nimport { Fs2FaVerificationMethodsComponent } from './components/2fa-verification-methods/2fa-verification-methods.component';\n\n\n@NgModule({\n imports: [\n CommonModule,\n FormsModule,\n\n MatFormFieldModule,\n MatInputModule,\n MatButtonModule,\n\n FsFormModule,\n FsRadioGroupModule,\n FsDialogModule,\n\n // CodeInputModule,\n MatCheckboxModule,\n MatProgressSpinnerModule,\n FsSkeletonModule,\n FsSkeletonModule,\n MatIconModule,\n MatRadioModule,\n ],\n declarations: [\n Fs2FAVerificationComponent,\n\n Fs2FAVerificationSMSComponent,\n Fs2FAVerificationOTPComponent,\n Fs2FaVerificationMethodsComponent,\n ],\n exports: [\n Fs2FAVerificationComponent,\n ],\n providers: [],\n})\nexport class Fs2FaModule {}\n","/*\n * Public API Surface of fs-2fa\n */\n\nexport { Fs2FaModule } from './app/fs-2fa.module';\n\n// Components\nexport { Fs2FAVerificationComponent } from './app/components/2fa-verification/2fa-verification.component';\n\nexport { IFsVerificationProvider } from './app/interfaces/verification-provider.interface';\nexport { IFsVerificationMethod } from './app/interfaces/verification-method.interface';\n\nexport { FsVerificationMethodType } from './app/enums/verification-method-type.enum';\n\nexport { FS_2FA_VERIFICATION_PROVIDER } from './app/tokens/verification.token';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAIa,4BAA4B,GAAG,IAAI,cAAc,CAC5D,mCAAmC;;ICLzB;AAAZ,WAAY,wBAAwB;IAClC,uCAAW,CAAA;IACX,2CAAe,CAAA;IACf,2DAA+B,CAAA;IAC/B,yCAAa,CAAA;AACf,CAAC,EALW,wBAAwB,KAAxB,wBAAwB;;MCwBvB,iCAAiC;IAQ5C,YAEU,qBAA8C,EAE9C,WAAgB,EAChB,UAA2D;QAH3D,0BAAqB,GAArB,qBAAqB,CAAyB;QAE9C,gBAAW,GAAX,WAAW,CAAK;QAChB,eAAU,GAAV,UAAU,CAAiD;QAPrD,2BAAsB,GAAG,wBAAwB,CAAC;QAiB3D,0BAAqB,GAAG;YAC7B,OAAO,IAAI,CAAC,qBAAqB;iBAC9B,wBAAwB,CAAC,IAAI,CAAC,MAAM,CAAC,EAAE,CAAC;iBACxC,IAAI,CACH,GAAG,CAAC,CAAC,MAA6B;gBAChC,IAAI,CAAC,UAAU,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;aAC/B,CAAC,CACH,CAAC;SACL,CAAC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iBAAiB;wBACjB,wBAAwB;wBACxB,gBAAgB;wBAChB,gBAAgB;wBAChB,aAAa;wBACb,cAAc;qBACf;oBACD,YAAY,EAAE;wBACZ,0BAA0B;wBAE1B,6BAA6B;wBAC7B,6BAA6B;wBAC7B,iCAAiC;qBAClC;oBACD,OAAO,EAAE;wBACP,0BAA0B;qBAC3B;oBACD,SAAS,EAAE,EAAE;iBACd;;;ACzDD;;;;ACAA;;;;;;"}
1
+ {"version":3,"file":"firestitch-2fa.js","sources":["../../src/app/tokens/verification.token.ts","../../src/app/enums/verification-method-type.enum.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.ts","../../src/app/components/2fa-verification-methods/2fa-verification-methods.component.html","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.ts","../../src/app/components/2fa-verification-otp/2fa-verification-otp.component.html","../../src/app/components/2fa-verification-code/2fa-verification-code.component.ts","../../src/app/components/2fa-verification-code/2fa-verification-code.component.html","../../src/app/components/2fa-verification/2fa-verification.component.ts","../../src/app/components/2fa-verification/2fa-verification.component.html","../../src/app/fs-2fa.module.ts","../../src/public_api.ts","../../src/firestitch-2fa.ts"],"sourcesContent":["import { InjectionToken } from '@angular/core';\n\nimport { IFsVerificationProvider } from '../interfaces/verification-provider.interface';\n\nexport const FS_2FA_VERIFICATION_PROVIDER = new InjectionToken<IFsVerificationProvider>(\n 'Provider for Verification service',\n);\n","export enum FsVerificationMethodType {\n Sms = 'sms',\n Email = 'email',\n Authenticator = 'authenticator',\n Code = 'code',\n}\n","import {\n ChangeDetectionStrategy,\n Component,\n Inject,\n} from '@angular/core';\n\nimport { MAT_DIALOG_DATA, MatDialogRef } from '@angular/material/dialog';\n\nimport { Observable } from 'rxjs';\nimport { map, shareReplay, tap } from 'rxjs/operators';\n\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { FsVerificationMethodType } from '../../enums/verification-method-type.enum';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n templateUrl: './2fa-verification-methods.component.html',\n styleUrls: [\n './2fa-verification-methods.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FaVerificationMethodsComponent {\n\n public method: IFsVerificationMethod;\n public phone: string;\n public code: string;\n public methods$: Observable<Record<string, IFsVerificationMethod[]>>;\n public readonly verificationMethodType = FsVerificationMethodType;\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n private _verificationProvider: IFsVerificationProvider,\n @Inject(MAT_DIALOG_DATA)\n private _dialogData: any,\n private _dialogRef: MatDialogRef<Fs2FaVerificationMethodsComponent>,\n ) {\n this._setActiveMethod();\n this._initMethods();\n }\n\n public compareWith(o1, o2) {\n return o1 && o2 && o1.id === o2.id\n }\n\n public setVerificationMethod = () => {\n return this._verificationProvider\n .updateVerificationMethod(this.method.id)\n .pipe(\n tap((method: IFsVerificationMethod) => {\n this._dialogRef.close(method);\n })\n );\n };\n\n private _setActiveMethod(): void {\n this.method = this._dialogData?.method;\n }\n\n private _initMethods(): void {\n this.methods$ = this._verificationProvider\n .methods()\n .pipe(\n map((methods) => {\n return methods\n .reduce((acc, method) => {\n if (!acc[method.type]) {\n acc[method.type] = [];\n }\n\n acc[method.type].push(method);\n\n return acc;\n }, {});\n }),\n shareReplay(1),\n );\n }\n}\n","<fs-dialog>\n <h1 mat-dialog-title>\n Verification Methods\n </h1>\n <form fsForm [submit]=\"setVerificationMethod\" [dirtySubmitButton]=\"false\">\n <mat-dialog-content>\n <ng-container *fsSkeleton=\"methods$ | async as methods\">\n <fs-radio-group [(ngModel)]=\"method\" name=\"method\" [compareWith]=\"compareWith\">\n <ng-container *ngFor=\"let methodMap of methods | keyvalue\">\n <div class=\"method\">\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n smartphone\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Text Message</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following mobile number\n </div>\n </div>\n </div>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <div class=\"method-header\">\n <div class=\"method-icon\">\n <mat-icon>\n mail\n </mat-icon>\n </div>\n <div class=\"method-name\">\n <div class=\"method-title\">Email</div>\n <div class=\"method-subtitle\">\n Verification code send to one of following email\n </div>\n </div>\n </div>\n </ng-container>\n </ng-container>\n\n <ng-container [ngSwitch]=\"methodMap.key\">\n <ng-container *ngSwitchCase=\"verificationMethodType.Sms\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.phoneNumber }}\n </mat-radio-button>\n </ng-container>\n\n <ng-container *ngSwitchCase=\"verificationMethodType.Email\">\n <mat-radio-button class=\"method-item\" *ngFor=\"let method of methodMap.value\" [value]=\"method\">\n {{ method.email }}\n </mat-radio-button>\n </ng-container>\n </ng-container>\n </div>\n </ng-container>\n </fs-radio-group>\n </ng-container>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div class=\"actions\">\n <ng-container *ngIf=\"methods$ | async\">\n <button mat-button type=\"submit\" color=\"primary\">Next</button>\n </ng-container>\n <button mat-button type=\"button\" [mat-dialog-close]=\"null\">Cancel</button>\n </div>\n </mat-dialog-actions>\n </form>\n</fs-dialog>\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Output,\n} from '@angular/core';\n\nimport { FsFormDirective } from '@firestitch/form';\n\n\n@Component({\n selector: 'fs-2fa-verification-otp',\n templateUrl: './2fa-verification-otp.component.html',\n styleUrls: [\n './2fa-verification-otp.component.scss'\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationOTPComponent {\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n constructor(\n public form: FsFormDirective,\n ) {}\n\n public codeChanged(event: string): void {\n this.codeChange.emit(event);\n this.form.dirty();\n }\n\n public codeCompleted(): void {\n this.form.triggerSubmit();\n }\n}\n","<p class=\"description\">\n Enter the verification code generated by your 2 factor authenticator\n app to verify it's you\n</p>\n\n<!--\n<code-input [initialFocusField]=\"0\"\n [codeLength]=\"6\"\n (codeChanged)=\"codeChanged($event)\"\n (codeCompleted)=\"codeCompleted()\">>\n</code-input>\n-->\n","import {\n ChangeDetectionStrategy,\n Component,\n EventEmitter,\n Input,\n Output,\n} from '@angular/core';\nimport { ControlContainer, NgForm } from '@angular/forms';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification-code',\n templateUrl: './2fa-verification-code.component.html',\n styleUrls: [\n './2fa-verification-code.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n viewProviders: [\n {\n provide: ControlContainer,\n useExisting: NgForm,\n },\n ],\n})\nexport class Fs2FAVerificationSMSComponent {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public codeChange = new EventEmitter<string>();\n\n public code: string;\n\n public codeChanged(): void {\n this.codeChange.emit(this.code);\n }\n\n}\n","<p class=\"description\">\n <ng-container *ngIf=\"method.phoneNumber && method.type === 'sms'\">\n A text message with a verification code was just\n sent to <span style=\"white-space: nowrap;\">{{ method.phoneNumber }}</span> to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"method.type === 'email'\">\n A email with a verification code was just sent to {{ method.email }} to verify it's you.\n </ng-container>\n\n <ng-container *ngIf=\"false\">\n Enter the one time code generated by the app administrator to verify it's you.\n </ng-container>\n</p>\n\n<mat-form-field>\n <mat-label>Code</mat-label>\n <input type=\"text\"\n matInput\n name=\"code\"\n autocomplete=\"one-time-code\"\n [(ngModel)]=\"code\"\n (ngModelChange)=\"codeChanged()\"\n required\n placeholder=\"Enter the code\"\n inputmode=\"numeric\">\n</mat-form-field>\n","import {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n EventEmitter,\n Inject,\n Input,\n OnDestroy,\n Output,\n} from '@angular/core';\n\nimport { FsDialog } from '@firestitch/dialog';\n\nimport { filter, takeUntil, tap } from 'rxjs/operators';\n\nimport { IFsVerificationMethod } from '../../interfaces/verification-method.interface';\nimport { Fs2FaVerificationMethodsComponent } from '../2fa-verification-methods/2fa-verification-methods.component';\nimport { Subject } from 'rxjs';\nimport { FS_2FA_VERIFICATION_PROVIDER } from '../../tokens/verification.token';\nimport { IFsVerificationProvider } from '../../interfaces/verification-provider.interface';\n\n\n@Component({\n selector: 'fs-2fa-verification',\n templateUrl: './2fa-verification.component.html',\n styleUrls: [\n './2fa-verification.component.scss',\n ],\n changeDetection: ChangeDetectionStrategy.OnPush,\n})\nexport class Fs2FAVerificationComponent implements OnDestroy {\n\n @Input()\n public method: IFsVerificationMethod;\n\n @Output()\n public verified = new EventEmitter<unknown>();\n\n @Output()\n public backToSignIn = new EventEmitter<void>();\n\n\n public resendInProgress = false;\n public trustedDevice = false;\n\n private _code: string;\n private _destroy$ = new Subject<void>();\n\n constructor(\n @Inject(FS_2FA_VERIFICATION_PROVIDER)\n public verificationProvider: IFsVerificationProvider,\n private _cdRef: ChangeDetectorRef,\n private _dialog: FsDialog,\n ) {}\n\n public ngOnDestroy(): void {\n this._destroy$.next();\n this._destroy$.complete();\n }\n\n public verify = () => {\n return this.verificationProvider\n .verify(this._code, this.trustedDevice)\n .pipe(\n tap((response) => {\n this.verified.emit(response);\n }),\n );\n };\n\n public codeChanged(code: string): void {\n this._code = code;\n }\n\n public resend(): void {\n this.resendInProgress = true;\n\n this.verificationProvider\n .resend()\n .pipe(\n takeUntil(this._destroy$),\n )\n .subscribe(() => {\n this.resendInProgress = false;\n\n this._cdRef.markForCheck();\n })\n }\n\n public showVerificationMethods(): void {\n this._dialog.open(\n Fs2FaVerificationMethodsComponent,\n {\n data: {\n method: this.method,\n }\n }\n )\n .afterClosed()\n .pipe(\n filter((method) => !!method),\n )\n .subscribe((method) => {\n this.method = method;\n\n this._cdRef.markForCheck();\n });\n }\n\n public toSignIn(): void {\n this.backToSignIn.emit();\n }\n\n}\n","<form fsForm [submit]=\"verify\" [dirtySubmitButton]=\"false\">\n <h2>2-Step Verification</h2>\n\n <div class=\"code-container\">\n <ng-container *ngIf=\"method.type === 'authenticator' else code\">\n <fs-2fa-verification-otp class=\"otp\"></fs-2fa-verification-otp>\n </ng-container>\n\n <ng-template #code>\n <fs-2fa-verification-code\n [method]=\"method\"\n (codeChange)=\"codeChanged($event)\">\n </fs-2fa-verification-code>\n </ng-template>\n </div>\n\n <div class=\"additional\">\n <mat-checkbox\n name=\"trust-device\"\n [(ngModel)]=\"trustedDevice\">\n Trust this device\n </mat-checkbox>\n\n <span matSuffix>\n <a mat-button\n type=\"button\"\n color=\"primary\"\n (click)=\"resend()\"\n [disabled]=\"resendInProgress\"\n class=\"resend-code-btn\">\n <ng-container *ngIf=\"!resendInProgress else sending\">\n Resend Code\n </ng-container>\n <ng-template #sending>\n <mat-spinner [diameter]=\"12\"></mat-spinner> Sending\n </ng-template>\n </a>\n </span>\n </div>\n\n <div class=\"actions\">\n <button mat-raised-button\n color=\"primary\"\n type=\"submit\">\n Verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"showVerificationMethods()\">\n Try other ways to verify\n </button>\n\n <button mat-button type=\"button\" (click)=\"toSignIn()\">\n Back to signin\n </button>\n </div>\n</form>\n","import { NgModule } from '@angular/core';\nimport { FormsModule } from '@angular/forms';\nimport { CommonModule } from '@angular/common';\n\nimport { MatIconModule } from '@angular/material/icon';\nimport { MatRadioModule } from '@angular/material/radio';\nimport { MatButtonModule } from '@angular/material/button';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { MatCheckboxModule } from '@angular/material/checkbox';\nimport { MatProgressSpinnerModule } from '@angular/material/progress-spinner';\n\nimport { FsFormModule } from '@firestitch/form';\nimport { FsSkeletonModule } from '@firestitch/skeleton';\nimport { FsRadioGroupModule } from '@firestitch/radiogroup';\nimport { FsDialogModule } from '@firestitch/dialog';\n\n// import { CodeInputModule } from 'angular-code-input';\n\nimport { Fs2FAVerificationComponent } from './components/2fa-verification/2fa-verification.component';\nimport { Fs2FAVerificationSMSComponent } from './components/2fa-verification-code/2fa-verification-code.component';\nimport { Fs2FAVerificationOTPComponent } from './components/2fa-verification-otp/2fa-verification-otp.component';\nimport { Fs2FaVerificationMethodsComponent } from './components/2fa-verification-methods/2fa-verification-methods.component';\n\n\n@NgModule({\n imports: [\n CommonModule,\n FormsModule,\n\n MatFormFieldModule,\n MatInputModule,\n MatButtonModule,\n\n FsFormModule,\n FsRadioGroupModule,\n FsDialogModule,\n\n // CodeInputModule,\n MatCheckboxModule,\n MatProgressSpinnerModule,\n FsSkeletonModule,\n FsSkeletonModule,\n MatIconModule,\n MatRadioModule,\n ],\n declarations: [\n Fs2FAVerificationComponent,\n\n Fs2FAVerificationSMSComponent,\n Fs2FAVerificationOTPComponent,\n Fs2FaVerificationMethodsComponent,\n ],\n exports: [\n Fs2FAVerificationComponent,\n ],\n providers: [],\n})\nexport class Fs2FaModule {}\n","/*\n * Public API Surface of fs-2fa\n */\n\nexport { Fs2FaModule } from './app/fs-2fa.module';\n\n// Components\nexport { Fs2FAVerificationComponent } from './app/components/2fa-verification/2fa-verification.component';\n\nexport { IFsVerificationProvider } from './app/interfaces/verification-provider.interface';\nexport { IFsVerificationMethod } from './app/interfaces/verification-method.interface';\n\nexport { FsVerificationMethodType } from './app/enums/verification-method-type.enum';\n\nexport { FS_2FA_VERIFICATION_PROVIDER } from './app/tokens/verification.token';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAIa,4BAA4B,GAAG,IAAI,cAAc,CAC5D,mCAAmC;;ICLzB;AAAZ,WAAY,wBAAwB;IAClC,uCAAW,CAAA;IACX,2CAAe,CAAA;IACf,2DAA+B,CAAA;IAC/B,yCAAa,CAAA;AACf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,cAAc;;QAGd,iBAAiB;QACjB,wBAAwB;QACxB,gBAAgB;QAChB,gBAAgB;QAChB,aAAa;QACb,cAAc,aAUd,0BAA0B;0GAIjB,WAAW,aAFX,EAAE,YA9BJ;YACP,YAAY;YACZ,WAAW;YAEX,kBAAkB;YAClB,cAAc;YACd,eAAe;YAEf,YAAY;YACZ,kBAAkB;YAClB,cAAc;;YAGd,iBAAiB;YACjB,wBAAwB;YACxB,gBAAgB;YAChB,gBAAgB;YAChB,aAAa;YACb,cAAc;SACf;4FAaU,WAAW;kBAjCvB,QAAQ;mBAAC;oBACR,OAAO,EAAE;wBACP,YAAY;wBACZ,WAAW;wBAEX,kBAAkB;wBAClB,cAAc;wBACd,eAAe;wBAEf,YAAY;wBACZ,kBAAkB;wBAClB,cAAc;;wBAGd,iBAAiB;wBACjB,wBAAwB;wBACxB,gBAAgB;wBAChB,gBAAgB;wBAChB,aAAa;wBACb,cAAc;qBACf;oBACD,YAAY,EAAE;wBACZ,0BAA0B;wBAE1B,6BAA6B;wBAC7B,6BAA6B;wBAC7B,iCAAiC;qBAClC;oBACD,OAAO,EAAE;wBACP,0BAA0B;qBAC3B;oBACD,SAAS,EAAE,EAAE;iBACd;;;ACzDD;;;;ACAA;;;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@firestitch/2fa",
3
- "version": "12.0.4",
3
+ "version": "12.0.5",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/Firestitch/ngx-2fa"