import { Component, Input } from '@angular/core';
import * as i0 from "@angular/core";
import * as i1 from "@seniorsistemas/angular-components/country-phone-picker";
import * as i2 from "@angular/forms";
import * as i3 from "../../../components/field-label/field-label.component";
export class CountryPhonePickerFieldComponent {
    changeDetectorRef;
    field;
    formControl;
    constructor(changeDetectorRef) {
        this.changeDetectorRef = changeDetectorRef;
    }
    ngAfterViewInit() {
        this.changeDetectorRef.detectChanges();
    }
    static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: CountryPhonePickerFieldComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
    static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "18.2.14", type: CountryPhonePickerFieldComponent, selector: "ng-component", inputs: { field: "field", formControl: "formControl" }, ngImport: i0, template: "@if (countryPhonePicker.phoneInput?.nativeElement) {\n    <s-field-label\n        [field]=\"field\"\n        [fieldContainerRef]=\"countryPhonePicker.phoneInput?.nativeElement\"\n    ></s-field-label>\n}\n\n<s-country-phone-picker\n    #countryPhonePicker\n    [formControl]=\"formControl\"\n    [ordination]=\"field.ordination\"\n    [countries]=\"field.countries\"\n    (selected)=\"field.onSelected($event)\"\n    (focusLost)=\"field.onFocusLost ? field.onFocusLost($event): null\"\n>\n</s-country-phone-picker>\n", dependencies: [{ kind: "component", type: i1.CountryPhonePickerComponent, selector: "s-country-phone-picker", inputs: ["countries", "ordination"], outputs: ["selected", "focusLost"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: i3.FieldLabelComponent, selector: "s-field-label", inputs: ["field", "fieldContainerRef"] }] });
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "18.2.14", ngImport: i0, type: CountryPhonePickerFieldComponent, decorators: [{
            type: Component,
            args: [{ template: "@if (countryPhonePicker.phoneInput?.nativeElement) {\n    <s-field-label\n        [field]=\"field\"\n        [fieldContainerRef]=\"countryPhonePicker.phoneInput?.nativeElement\"\n    ></s-field-label>\n}\n\n<s-country-phone-picker\n    #countryPhonePicker\n    [formControl]=\"formControl\"\n    [ordination]=\"field.ordination\"\n    [countries]=\"field.countries\"\n    (selected)=\"field.onSelected($event)\"\n    (focusLost)=\"field.onFocusLost ? field.onFocusLost($event): null\"\n>\n</s-country-phone-picker>\n" }]
        }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { field: [{
                type: Input,
                args: [{ required: true }]
            }], formControl: [{
                type: Input,
                args: [{ required: true }]
            }] } });
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY291bnRyeS1waG9uZS1waWNrZXItZmllbGQuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvYW5ndWxhci1jb21wb25lbnRzL2R5bmFtaWMtZm9ybS9zcmMvbGliL2R5bmFtaWMtZm9ybS9mb3JtLWZpZWxkL2ZpZWxkcy9jb3VudHJ5LXBob25lLXBpY2tlci9jb3VudHJ5LXBob25lLXBpY2tlci1maWVsZC5jb21wb25lbnQudHMiLCIuLi8uLi8uLi8uLi8uLi8uLi8uLi8uLi9wcm9qZWN0cy9hbmd1bGFyLWNvbXBvbmVudHMvZHluYW1pYy1mb3JtL3NyYy9saWIvZHluYW1pYy1mb3JtL2Zvcm0tZmllbGQvZmllbGRzL2NvdW50cnktcGhvbmUtcGlja2VyL2NvdW50cnktcGhvbmUtcGlja2VyLWZpZWxkLmNvbXBvbmVudC5odG1sIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBLE9BQU8sRUFBb0MsU0FBUyxFQUFjLEtBQUssRUFBRSxNQUFNLGVBQWUsQ0FB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