import { __decorate } from "tslib";
import { Component, ChangeDetectionStrategy } from '@angular/core';
import { CommonModule } from '@angular/common';
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 { RadioLayoutMetadataLoader, RadioRelationsMetadataLoader } from './radio.metadata';
import * as i0 from "@angular/core";
import * as i1 from "@angular/common";
import * as i2 from "@anglr/common/forms";
import * as i3 from "@anglr/common";
import * as i4 from "@angular/forms";
/**
 * Component used for displaying radio
 */
let RadioSAComponent = class RadioSAComponent extends FormComponentBase {
};
RadioSAComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.0.4", ngImport: i0, type: RadioSAComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
RadioSAComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.0.4", type: RadioSAComponent, isStandalone: true, selector: "form-radio", usesInheritance: true, ngImport: i0, template: "<label *ngFor=\"let option of options?.options; index as index\"><input type=\"radio\" [formControl]=\"control|asFormControl|asRequired\" [value]=\"option.code\"/> {{option.text}}</label>", styles: [":host{display: block;}"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { 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: ReactiveFormsModule }, { kind: "directive", type: i4.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: i4.RadioControlValueAccessor, selector: "input[type=radio][formControlName],input[type=radio][formControl],input[type=radio][ngModel]", inputs: ["name", "formControlName", "value"] }, { kind: "directive", type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i4.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
RadioSAComponent = __decorate([
    RelationsEditorMetadata(RadioRelationsMetadataLoader),
    LayoutEditorMetadata(RadioLayoutMetadataLoader)
], RadioSAComponent);
export { RadioSAComponent };
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.0.4", ngImport: i0, type: RadioSAComponent, decorators: [{
            type: Component,
            args: [{ selector: 'form-radio', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, imports: [
                        CommonModule,
                        FormPipesModule,
                        CastPipesModule,
                        FormComponentControlSAPipe,
                        ReactiveFormsModule,
                    ], template: "<label *ngFor=\"let option of options?.options; index as index\"><input type=\"radio\" [formControl]=\"control|asFormControl|asRequired\" [value]=\"option.code\"/> {{option.text}}</label>", styles: [":host{display: block;}"] }]
        }] });
//# sourceMappingURL=radio.component.js.map