import { __decorate } from "tslib";
import { Component, ChangeDetectionStrategy } from '@angular/core';
import { MatFormFieldModule } from '@angular/material/form-field';
import { MatInputModule } from '@angular/material/input';
import { MatDatepickerModule } from '@angular/material/datepicker';
import { MatNativeDateModule } from '@angular/material/core';
import { ReactiveFormsModule } from '@angular/forms';
import { LayoutEditorMetadata } from '@anglr/dynamic/layout-editor';
import { CastPipesModule, HostDisplayBlockStyle } from '@anglr/common';
import { FormPipesModule } from '@anglr/common/forms';
import { FormComponentBase, FormComponentControlSAPipe } from '@anglr/dynamic/form';
import { RelationsEditorMetadata } from '@anglr/dynamic/relations-editor';
import { MaterialDatepickerLayoutMetadataLoader, MaterialDatepickerRelationsMetadataLoader } from './datepicker.metadata';
import * as i0 from "@angular/core";
import * as i1 from "@angular/forms";
import * as i2 from "@anglr/common/forms";
import * as i3 from "@anglr/common";
import * as i4 from "@angular/material/form-field";
import * as i5 from "@angular/material/input";
import * as i6 from "@angular/material/datepicker";
/**
 * Component used for displaying material datepicker
 */
let MaterialDatepickerSAComponent = class MaterialDatepickerSAComponent extends FormComponentBase {
};
MaterialDatepickerSAComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.0.4", ngImport: i0, type: MaterialDatepickerSAComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
MaterialDatepickerSAComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.0.4", type: MaterialDatepickerSAComponent, isStandalone: true, selector: "material-datepicker", usesInheritance: true, ngImport: i0, template: "<mat-form-field [appearance]=\"options?.appearance|asRequired\">\n    <mat-label>{{options?.label}}</mat-label>\n    <input matInput [matDatepicker]=\"picker\" [formControl]=\"control|asFormControl|asRequired\">\n    <mat-hint>{{options?.hint}}</mat-hint>\n    \n    <mat-datepicker-toggle matSuffix [for]=\"picker\"></mat-datepicker-toggle>\n    <mat-datepicker #picker></mat-datepicker>\n</mat-form-field>", styles: [":host{display: block;}"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.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: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "ngmodule", type: FormPipesModule }, { kind: "pipe", type: i2.AsFormControlPipe, name: "asFormControl" }, { kind: "ngmodule", type: CastPipesModule }, { kind: "pipe", type: i3.AsRequiredTypePipe, name: "asRequired" }, { kind: "ngmodule", type: MatFormFieldModule }, { kind: "component", type: i4.MatFormField, selector: "mat-form-field", inputs: ["hideRequiredMarker", "color", "floatLabel", "appearance", "subscriptSizing", "hintLabel"], exportAs: ["matFormField"] }, { kind: "directive", type: i4.MatLabel, selector: "mat-label" }, { kind: "directive", type: i4.MatHint, selector: "mat-hint", inputs: ["align", "id"] }, { kind: "directive", type: i4.MatSuffix, selector: "[matSuffix], [matIconSuffix], [matTextSuffix]", inputs: ["matTextSuffix"] }, { kind: "ngmodule", type: MatInputModule }, { kind: "directive", type: i5.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl],      input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { kind: "ngmodule", type: MatDatepickerModule }, { kind: "component", type: i6.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }, { kind: "directive", type: i6.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { kind: "component", type: i6.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { kind: "ngmodule", type: MatNativeDateModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
MaterialDatepickerSAComponent = __decorate([
    RelationsEditorMetadata(MaterialDatepickerRelationsMetadataLoader),
    LayoutEditorMetadata(MaterialDatepickerLayoutMetadataLoader)
], MaterialDatepickerSAComponent);
export { MaterialDatepickerSAComponent };
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.4", ngImport: i0, type: MaterialDatepickerSAComponent, decorators: [{
            type: Component,
            args: [{ selector: 'material-datepicker', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [
                        ReactiveFormsModule,
                        FormPipesModule,
                        CastPipesModule,
                        FormComponentControlSAPipe,
                        MatFormFieldModule,
                        MatInputModule,
                        MatDatepickerModule,
                        MatNativeDateModule,
                    ], template: "<mat-form-field [appearance]=\"options?.appearance|asRequired\">\n    <mat-label>{{options?.label}}</mat-label>\n    <input matInput [matDatepicker]=\"picker\" [formControl]=\"control|asFormControl|asRequired\">\n    <mat-hint>{{options?.hint}}</mat-hint>\n    \n    <mat-datepicker-toggle matSuffix [for]=\"picker\"></mat-datepicker-toggle>\n    <mat-datepicker #picker></mat-datepicker>\n</mat-form-field>", styles: [":host{display: block;}"] }]
        }] });
//# sourceMappingURL=datepicker.component.js.map