import * as i0 from '@angular/core';
import { EventEmitter, Component, Input, Output, Optional, Inject, Self, ViewChild, NgModule } from '@angular/core';
import * as i2$1 from '@angular/forms';
import { FormControl, Validators, FormsModule, ReactiveFormsModule } from '@angular/forms';
import { first, Subject, BehaviorSubject } from 'rxjs';
import * as i6 from '@aztrix/helpers';
import { CustomValidators, HelperPipesModule } from '@aztrix/helpers';
import * as i1 from '@aztrix/components/overlay';
import * as i2 from '@angular/common';
import { CommonModule } from '@angular/common';
import * as i4 from '@aztrix/components/button';
import { ButtonModule } from '@aztrix/components/button';
import * as i4$1 from '@aztrix/components/value-edit';
import { ValueEditModule } from '@aztrix/components/value-edit';
import * as i5 from '@aztrix/components/login-value-form-error';
import { LoginValueFormErrorModule } from '@aztrix/components/login-value-form-error';
import * as i5$1 from '@angular/material/legacy-form-field';
import { MatLegacyFormFieldModule } from '@angular/material/legacy-form-field';
import { coerceBooleanProperty } from '@angular/cdk/coercion';
import * as i4$2 from '@angular/material/form-field';
import { MAT_FORM_FIELD, MatFormFieldControl } from '@angular/material/form-field';
import * as i1$1 from '@angular/cdk/a11y';
import * as i3 from '@angular/material/legacy-input';
import { MatLegacyInputModule } from '@angular/material/legacy-input';

class RetryVerificationComponent {
    constructor(_overlay) {
        this._overlay = _overlay;
        this.form = new FormControl('', [CustomValidators.validateLoginValue()]);
        this.verificationValueChanges = new EventEmitter();
        this._mobileForm = new FormControl();
        this._emailForm = new FormControl();
    }
    ngOnInit() {
        this._mobileForm.valueChanges.subscribe((value) => {
            this.form.setValue(value);
        });
        this._emailForm.valueChanges.subscribe((value) => {
            this.form.setValue(value);
        });
    }
    resendVerification() {
        this.retryVerification(this.form.value)
            .pipe(first())
            .subscribe(() => {
            this.verificationValueChanges.next(this.form.value);
            this._overlay.closeModal();
        });
    }
}
RetryVerificationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: RetryVerificationComponent, deps: [{ token: i1.OverlayService }], target: i0.ɵɵFactoryTarget.Component });
RetryVerificationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.5", type: RetryVerificationComponent, selector: "ax-retry-verification", inputs: { form: "form", verificationType: "verificationType", retryVerification: "retryVerification" }, outputs: { verificationValueChanges: "verificationValueChanges" }, ngImport: i0, template: "<ax-value-edit\n  [form]=\"form\"\n  [autofocus]=\"false\"\n  [required]=\"true\"\n  [hint]=\"\n    'proposal.agreement.verification.property'\n      | translate: {propertyType: verificationType | propertyTypeLabel}\n  \"\n  [type]=\"verificationType.includes('MOBILE') ? 'PHONE' : verificationType\"\n  [label]=\"verificationType | propertyTypeLabel\"\n  [errorsTemplate]=\"errorsTemplate\"\n></ax-value-edit>\n<div class=\"h-button-wrapper\">\n  <button [disabled]=\"form.invalid\" axButton filled (click)=\"resendVerification()\" color=\"primary\">\n    {{ 'agreement.verification.send' | translate }}\n  </button>\n</div>\n\n<ng-template #errorsTemplate>\n  <ax-login-value-form-error\n    *ngIf=\"form.touched\"\n    [form]=\"form\"\n    [propertyType]=\"verificationType\"\n  ></ax-login-value-form-error>\n</ng-template>\n", styles: [":host{padding:1rem;display:block}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i4.ButtonDirective, selector: "[axButton]", inputs: ["color", "labelHideMobile", "smallButton", "bigButton", "fullWidth", "filled", "outline", "icon-button", "hoverLabel", "hover", "lowercase", "disabled"] }, { kind: "component", type: i4$1.ValueEditComponent, selector: "ax-value-edit", inputs: ["type", "numberConfig"] }, { kind: "component", type: i5.LoginValueFormErrorComponent, selector: "ax-login-value-form-error", inputs: ["form", "propertyType"] }, { kind: "pipe", type: i6.PropertyTypeLabelPipe, name: "propertyTypeLabel" }, { kind: "pipe", type: i6.TranslatePipe, name: "translate" }] });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: RetryVerificationComponent, decorators: [{
            type: Component,
            args: [{ selector: 'ax-retry-verification', template: "<ax-value-edit\n  [form]=\"form\"\n  [autofocus]=\"false\"\n  [required]=\"true\"\n  [hint]=\"\n    'proposal.agreement.verification.property'\n      | translate: {propertyType: verificationType | propertyTypeLabel}\n  \"\n  [type]=\"verificationType.includes('MOBILE') ? 'PHONE' : verificationType\"\n  [label]=\"verificationType | propertyTypeLabel\"\n  [errorsTemplate]=\"errorsTemplate\"\n></ax-value-edit>\n<div class=\"h-button-wrapper\">\n  <button [disabled]=\"form.invalid\" axButton filled (click)=\"resendVerification()\" color=\"primary\">\n    {{ 'agreement.verification.send' | translate }}\n  </button>\n</div>\n\n<ng-template #errorsTemplate>\n  <ax-login-value-form-error\n    *ngIf=\"form.touched\"\n    [form]=\"form\"\n    [propertyType]=\"verificationType\"\n  ></ax-login-value-form-error>\n</ng-template>\n", styles: [":host{padding:1rem;display:block}\n"] }]
        }], ctorParameters: function () { return [{ type: i1.OverlayService }]; }, propDecorators: { form: [{
                type: Input
            }], verificationType: [{
                type: Input
            }], retryVerification: [{
                type: Input
            }], verificationValueChanges: [{
                type: Output
            }] } });

class OtpInputComponent {
    constructor(_focusMonitor, _elementRef, _formField, ngControl) {
        this._focusMonitor = _focusMonitor;
        this._elementRef = _elementRef;
        this._formField = _formField;
        this.ngControl = ngControl;
        this._required = false;
        this._disabled = false;
        this.form = new FormControl({ value: undefined, disabled: false }, [
            Validators.required,
            Validators.minLength(5),
            Validators.maxLength(6),
        ]);
        this.stateChanges = new Subject();
        this.focused = false;
        this.touched = false;
        this.controlType = 'otp-input';
        this.id = `otp-input-${OtpInputComponent.nextId++}`;
        // eslint-disable-next-line @typescript-eslint/no-empty-function
        this.onChange = (_) => { };
        // eslint-disable-next-line @typescript-eslint/no-empty-function
        this.onTouched = () => { };
        if (this.ngControl != null) {
            this.ngControl.valueAccessor = this;
        }
    }
    get empty() {
        var _a;
        return !((_a = this.form.value) === null || _a === void 0 ? void 0 : _a.length);
    }
    get shouldLabelFloat() {
        return this.focused || !this.empty;
    }
    get placeholder() {
        return this._placeholder;
    }
    set placeholder(value) {
        this._placeholder = value;
        this.stateChanges.next();
    }
    get required() {
        return this._required;
    }
    set required(value) {
        this._required = coerceBooleanProperty(value);
        this.stateChanges.next();
    }
    get disabled() {
        return this._disabled;
    }
    set disabled(value) {
        this._disabled = coerceBooleanProperty(value);
        this._disabled ? this.form.disable() : this.form.enable();
        this.stateChanges.next();
    }
    get value() {
        return this.form.value;
    }
    set value(value) {
        if (!value) {
            value = '';
        }
        const chars = [...value.toUpperCase()]
            .filter((char) => {
            const code = char.charCodeAt(0);
            return code > 47 && code < 91;
        })
            .slice(0, 6);
        this.form.setValue(chars.join(''));
        this.stateChanges.next();
    }
    get errorState() {
        return this.form.invalid && this.touched;
    }
    ngOnDestroy() {
        this.stateChanges.complete();
        this._focusMonitor.stopMonitoring(this._elementRef);
    }
    onFocusIn() {
        if (!this.focused) {
            this.focused = true;
            this.stateChanges.next();
        }
    }
    onFocusOut(event) {
        if (!this._elementRef.nativeElement.contains(event.relatedTarget)) {
            this.touched = true;
            this.focused = false;
            this.onTouched();
            this.stateChanges.next();
        }
    }
    setDescribedByIds(ids) {
        this._elementRef.nativeElement.setAttribute('aria-describedby', ids.join(' '));
    }
    onContainerClick() {
        this._focusMonitor.focusVia(this.input, 'program');
    }
    writeValue(value) {
        this.value = value;
    }
    registerOnChange(fn) {
        this.onChange = fn;
    }
    registerOnTouched(fn) {
        this.onTouched = fn;
    }
    setDisabledState(isDisabled) {
        this.disabled = isDisabled;
    }
    _handleInput(control) {
        const caretPosition = this.input.nativeElement.selectionStart;
        control.setValue(control.value.toUpperCase());
        this.writeValue(this.value);
        this.onChange(this.value);
        this.input.nativeElement.setSelectionRange(caretPosition, caretPosition);
    }
    paste(event) {
        var _a;
        event.preventDefault();
        if (event.clipboardData) {
            this.value = (_a = event.clipboardData.getData('text')) === null || _a === void 0 ? void 0 : _a.toUpperCase();
        }
        else {
            navigator.clipboard.readText().then((text) => (this.value = text.toUpperCase()));
        }
        this.onChange(this.value);
    }
}
OtpInputComponent.nextId = 0;
OtpInputComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: OtpInputComponent, deps: [{ token: i1$1.FocusMonitor }, { token: i0.ElementRef }, { token: MAT_FORM_FIELD, optional: true }, { token: i2$1.NgControl, optional: true, self: true }], target: i0.ɵɵFactoryTarget.Component });
OtpInputComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.5", type: OtpInputComponent, selector: "ax-otp-input", inputs: { userAriaDescribedBy: ["aria-describedby", "userAriaDescribedBy"], placeholder: "placeholder", required: "required", disabled: "disabled", value: "value" }, providers: [{ provide: MatFormFieldControl, useExisting: OtpInputComponent }], viewQueries: [{ propertyName: "input", first: true, predicate: ["input"], descendants: true }], ngImport: i0, template: "<input\n  class=\"otp-input\"\n  size=\"6\"\n  maxLength=\"6\"\n  matInput\n  [formControl]=\"form\"\n  (input)=\"_handleInput(form)\"\n  (focusin)=\"onFocusIn()\"\n  (focusout)=\"onFocusOut($event)\"\n  (paste)=\"paste($event)\"\n  #input\n/>\n", styles: [".otp-input{font-size:2rem;letter-spacing:1.2rem;text-align:center;width:calc(100% - .6rem);min-width:280px}\n"], dependencies: [{ kind: "directive", type: i2$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i3.MatLegacyInput, selector: "input[matInput], textarea[matInput], select[matNativeControl],      input[matNativeControl], textarea[matNativeControl]", exportAs: ["matInput"] }] });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: OtpInputComponent, decorators: [{
            type: Component,
            args: [{ selector: 'ax-otp-input', providers: [{ provide: MatFormFieldControl, useExisting: OtpInputComponent }], template: "<input\n  class=\"otp-input\"\n  size=\"6\"\n  maxLength=\"6\"\n  matInput\n  [formControl]=\"form\"\n  (input)=\"_handleInput(form)\"\n  (focusin)=\"onFocusIn()\"\n  (focusout)=\"onFocusOut($event)\"\n  (paste)=\"paste($event)\"\n  #input\n/>\n", styles: [".otp-input{font-size:2rem;letter-spacing:1.2rem;text-align:center;width:calc(100% - .6rem);min-width:280px}\n"] }]
        }], ctorParameters: function () {
        return [{ type: i1$1.FocusMonitor }, { type: i0.ElementRef }, { type: i4$2.MatFormField, decorators: [{
                        type: Optional
                    }, {
                        type: Inject,
                        args: [MAT_FORM_FIELD]
                    }] }, { type: i2$1.NgControl, decorators: [{
                        type: Optional
                    }, {
                        type: Self
                    }] }];
    }, propDecorators: { userAriaDescribedBy: [{
                type: Input,
                args: ['aria-describedby']
            }], input: [{
                type: ViewChild,
                args: ['input']
            }], placeholder: [{
                type: Input
            }], required: [{
                type: Input
            }], disabled: [{
                type: Input
            }], value: [{
                type: Input
            }] } });

class OtpVerificationComponent {
    constructor(_overlay, _elementRef, _changeDetection) {
        this._overlay = _overlay;
        this._elementRef = _elementRef;
        this._changeDetection = _changeDetection;
        this.verified = false;
        this.verificationValue = '';
        this.canChangeValue = true;
        this.resendSuccess = false;
        this.verificationValueChanges = new EventEmitter();
        this.verificationComplete = new EventEmitter();
        this.codeForm = new FormControl({ value: undefined, disabled: false }, [Validators.required]);
        this.loading$ = new BehaviorSubject(false);
        this.error$ = new BehaviorSubject(null);
    }
    verifyOTP() {
        var _a;
        if ((_a = this.codeForm) === null || _a === void 0 ? void 0 : _a.errors) {
            return;
        }
        this.loading$.next(true);
        this.error$.next(null);
        this.verification(this.codeForm.value, this.verificationValue)
            .pipe(first())
            .subscribe({
            next: () => {
                this.verified = true;
                this.loading$.next(false);
                this.verificationComplete.next(this.verificationValue);
            },
            error: (response) => {
                this.codeForm.reset();
                this.error$.next(typeof response.error === 'string' ? response.error : true);
                this.loading$.next(false);
            },
        });
    }
    retryOTP() {
        if (this.canChangeValue) {
            this._overlay.createModal(RetryVerificationComponent, {
                title: 'agreement.verification.retry',
                init: (modal) => {
                    modal.verificationType = this.verificationType;
                    modal.retryVerification = this.retryVerification;
                    modal.verificationValueChanges.pipe(first()).subscribe((verificationValue) => {
                        this.verificationValue = verificationValue;
                        this.verificationValueChanges.next(this.verificationValue);
                        this.error$.next(null);
                    });
                },
            }, this._elementRef);
        }
        else {
            this.retryVerification(this.verificationValue)
                .pipe(first())
                .subscribe(() => {
                this.verificationValueChanges.next(this.verificationValue);
                this.resendSuccess = true;
                setTimeout(() => {
                    this.resendSuccess = false;
                    this._changeDetection.detectChanges();
                }, 10000);
            });
        }
    }
}
OtpVerificationComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: OtpVerificationComponent, deps: [{ token: i1.OverlayService }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
OtpVerificationComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.1.5", type: OtpVerificationComponent, selector: "ax-otp-verification", inputs: { verified: "verified", verificationValue: "verificationValue", verificationType: "verificationType", canChangeValue: "canChangeValue", verification: "verification", retryVerification: "retryVerification" }, outputs: { verificationValueChanges: "verificationValueChanges", verificationComplete: "verificationComplete" }, ngImport: i0, template: "<ng-container *ngIf=\"!verified\">\n  <ng-container\n    *ngIf=\"\n      (error$ | async) === null ||\n      (error$ | async) === 'INVALID_VERIFICATION_CODE' ||\n      (error$ | async) === 'INVALID_TOKEN' ||\n      (error$ | async) === true\n    \"\n  >\n    <mat-form-field class=\"otp-form-field c-input\" appearance=\"outline\">\n      <mat-label>{{ 'label.enter.code' | translate }}</mat-label>\n      <ax-otp-input matInput [formControl]=\"codeForm\"></ax-otp-input>\n    </mat-form-field>\n\n    <ng-content></ng-content>\n\n    <ax-button\n      class=\"verify\"\n      filled\n      color=\"accent\"\n      [loading]=\"loading$ | async\"\n      (click)=\"verifyOTP()\"\n    >\n      {{ 'label.verify' | translate }}\n    </ax-button>\n  </ng-container>\n\n  <div class=\"resend\" *ngIf=\"(error$ | async) === null\">\n    <span>{{ 'agreement.verification.code.resend' | translate }}</span>\n    <a axButton class=\"resend-link\" (click)=\"retryOTP()\" [disabled]=\"resendSuccess\">\n      <span *ngIf=\"!resendSuccess\">{{\n        'property.verification.modal.mobile.resend' | translate\n      }}</span>\n      <span *ngIf=\"resendSuccess\">{{\n        'agreement.verification.code.resend.success' | translate\n      }}</span>\n    </a>\n  </div>\n\n  <div class=\"error-message\" *ngIf=\"(error$ | async) !== null\">\n    <ng-container [ngSwitch]=\"error$ | async\">\n      <span class=\"error\" *ngSwitchCase=\"'INVALID_VERIFICATION_CODE'\">{{\n        'agreement.verification.code.error.incorrect' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'INVALID_TOKEN'\">{{\n        'agreement.verification.code.error.incorrect' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'TOO_MANY_VERIFICATION_ATTEMPTS'\">{{\n        'agreement.verification.code.error.too-many-attempts' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'VERIFICATION_CODE_EXPIRED'\">{{\n        'agreement.verification.code.error.expired' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'LOGIN_NOT_REGISTERED'\">{{\n        'error.login.invalid.login' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchDefault>{{\n        'error.SOMETHING_WENT_WRONG.message' | translate\n      }}</span>\n    </ng-container>\n    <button axButton filled class=\"resend-button\" (click)=\"retryOTP()\">\n      {{ 'property.verification.modal.mobile.resend' | translate }}\n    </button>\n  </div>\n</ng-container>\n", styles: [":host{display:flex;flex-direction:column;align-items:stretch;padding-top:1rem}.error-message{padding:1rem}.error{color:var(--warn-color-500);padding:0 .75rem}.resend-button{margin:0 .75rem}.verify ::ng-deep .ax-button{width:100%}.resend{display:flex;align-items:center;flex-direction:column;text-align:center;padding:.25rem 1rem;max-width:300px;margin:0 auto}a.ax-button.resend-link{text-transform:none;background-color:transparent;text-decoration:underline}\n"], dependencies: [{ kind: "directive", type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i2.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i2.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2.NgSwitchDefault, selector: "[ngSwitchDefault]" }, { kind: "directive", type: i2$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2$1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.ButtonDirective, selector: "[axButton]", inputs: ["color", "labelHideMobile", "smallButton", "bigButton", "fullWidth", "filled", "outline", "icon-button", "hoverLabel", "hover", "lowercase", "disabled"] }, { kind: "component", type: i4.ButtonComponent, selector: "ax-button" }, { kind: "component", type: i5$1.MatLegacyFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i5$1.MatLegacyLabel, selector: "mat-label" }, { kind: "component", type: OtpInputComponent, selector: "ax-otp-input", inputs: ["aria-describedby", "placeholder", "required", "disabled", "value"] }, { kind: "pipe", type: i2.AsyncPipe, name: "async" }, { kind: "pipe", type: i6.TranslatePipe, name: "translate" }] });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: OtpVerificationComponent, decorators: [{
            type: Component,
            args: [{ selector: 'ax-otp-verification', template: "<ng-container *ngIf=\"!verified\">\n  <ng-container\n    *ngIf=\"\n      (error$ | async) === null ||\n      (error$ | async) === 'INVALID_VERIFICATION_CODE' ||\n      (error$ | async) === 'INVALID_TOKEN' ||\n      (error$ | async) === true\n    \"\n  >\n    <mat-form-field class=\"otp-form-field c-input\" appearance=\"outline\">\n      <mat-label>{{ 'label.enter.code' | translate }}</mat-label>\n      <ax-otp-input matInput [formControl]=\"codeForm\"></ax-otp-input>\n    </mat-form-field>\n\n    <ng-content></ng-content>\n\n    <ax-button\n      class=\"verify\"\n      filled\n      color=\"accent\"\n      [loading]=\"loading$ | async\"\n      (click)=\"verifyOTP()\"\n    >\n      {{ 'label.verify' | translate }}\n    </ax-button>\n  </ng-container>\n\n  <div class=\"resend\" *ngIf=\"(error$ | async) === null\">\n    <span>{{ 'agreement.verification.code.resend' | translate }}</span>\n    <a axButton class=\"resend-link\" (click)=\"retryOTP()\" [disabled]=\"resendSuccess\">\n      <span *ngIf=\"!resendSuccess\">{{\n        'property.verification.modal.mobile.resend' | translate\n      }}</span>\n      <span *ngIf=\"resendSuccess\">{{\n        'agreement.verification.code.resend.success' | translate\n      }}</span>\n    </a>\n  </div>\n\n  <div class=\"error-message\" *ngIf=\"(error$ | async) !== null\">\n    <ng-container [ngSwitch]=\"error$ | async\">\n      <span class=\"error\" *ngSwitchCase=\"'INVALID_VERIFICATION_CODE'\">{{\n        'agreement.verification.code.error.incorrect' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'INVALID_TOKEN'\">{{\n        'agreement.verification.code.error.incorrect' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'TOO_MANY_VERIFICATION_ATTEMPTS'\">{{\n        'agreement.verification.code.error.too-many-attempts' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'VERIFICATION_CODE_EXPIRED'\">{{\n        'agreement.verification.code.error.expired' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchCase=\"'LOGIN_NOT_REGISTERED'\">{{\n        'error.login.invalid.login' | translate\n      }}</span>\n      <span class=\"error\" *ngSwitchDefault>{{\n        'error.SOMETHING_WENT_WRONG.message' | translate\n      }}</span>\n    </ng-container>\n    <button axButton filled class=\"resend-button\" (click)=\"retryOTP()\">\n      {{ 'property.verification.modal.mobile.resend' | translate }}\n    </button>\n  </div>\n</ng-container>\n", styles: [":host{display:flex;flex-direction:column;align-items:stretch;padding-top:1rem}.error-message{padding:1rem}.error{color:var(--warn-color-500);padding:0 .75rem}.resend-button{margin:0 .75rem}.verify ::ng-deep .ax-button{width:100%}.resend{display:flex;align-items:center;flex-direction:column;text-align:center;padding:.25rem 1rem;max-width:300px;margin:0 auto}a.ax-button.resend-link{text-transform:none;background-color:transparent;text-decoration:underline}\n"] }]
        }], ctorParameters: function () { return [{ type: i1.OverlayService }, { type: i0.ElementRef }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { verified: [{
                type: Input
            }], verificationValue: [{
                type: Input
            }], verificationType: [{
                type: Input
            }], canChangeValue: [{
                type: Input
            }], verification: [{
                type: Input
            }], retryVerification: [{
                type: Input
            }], verificationValueChanges: [{
                type: Output
            }], verificationComplete: [{
                type: Output
            }] } });

class OtpVerificationModule {
}
OtpVerificationModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: OtpVerificationModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
OtpVerificationModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.1.5", ngImport: i0, type: OtpVerificationModule, declarations: [OtpVerificationComponent, RetryVerificationComponent, OtpInputComponent], imports: [CommonModule,
        FormsModule,
        ReactiveFormsModule,
        HelperPipesModule,
        ButtonModule,
        ValueEditModule,
        MatLegacyFormFieldModule,
        MatLegacyInputModule,
        LoginValueFormErrorModule], exports: [OtpVerificationComponent, RetryVerificationComponent] });
OtpVerificationModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: OtpVerificationModule, imports: [CommonModule,
        FormsModule,
        ReactiveFormsModule,
        HelperPipesModule,
        ButtonModule,
        ValueEditModule,
        MatLegacyFormFieldModule,
        MatLegacyInputModule,
        LoginValueFormErrorModule] });
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.1.5", ngImport: i0, type: OtpVerificationModule, decorators: [{
            type: NgModule,
            args: [{
                    declarations: [OtpVerificationComponent, RetryVerificationComponent, OtpInputComponent],
                    imports: [
                        CommonModule,
                        FormsModule,
                        ReactiveFormsModule,
                        HelperPipesModule,
                        ButtonModule,
                        ValueEditModule,
                        MatLegacyFormFieldModule,
                        MatLegacyInputModule,
                        LoginValueFormErrorModule,
                    ],
                    exports: [OtpVerificationComponent, RetryVerificationComponent],
                }]
        }] });

/**
 * Generated bundle index. Do not edit.
 */

export { OtpVerificationComponent, OtpVerificationModule, RetryVerificationComponent };
//# sourceMappingURL=aztrix-components-otp-verification.mjs.map
//# sourceMappingURL=aztrix-components-otp-verification.mjs.map
