import { ChangeDetectionStrategy, Component, forwardRef } from '@angular/core';
import { CommonModule } from '@angular/common';
import { NG_VALUE_ACCESSOR } from '@angular/forms';
import { RadioGroupBaseComponent } from './radio-group.base.component';
import { RadioComponent } from '@ironsource/fusion-ui/components/radio/v4';
import * as i0 from "@angular/core";
import * as i1 from "@angular/common";
function RadioGroupComponent_fusion_radio_1_Template(rf, ctx) { if (rf & 1) {
    const _r3 = i0.ɵɵgetCurrentView();
    i0.ɵɵelementStart(0, "fusion-radio", 2);
    i0.ɵɵlistener("changed", function RadioGroupComponent_fusion_radio_1_Template_fusion_radio_changed_0_listener($event) { const restoredCtx = i0.ɵɵrestoreView(_r3); const option_r1 = restoredCtx.$implicit; const ctx_r2 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r2.setSelected($event, option_r1)); });
    i0.ɵɵelementEnd();
} if (rf & 2) {
    const option_r1 = ctx.$implicit;
    const ctx_r0 = i0.ɵɵnextContext();
    i0.ɵɵproperty("name", ctx_r0.name)("value", option_r1.id)("label", option_r1.label)("selected", ctx_r0.isSelected(option_r1))("disabled", ctx_r0.disabled || option_r1.disabled);
} }
export class RadioGroupComponent extends RadioGroupBaseComponent {
    static { this.ɵfac = /*@__PURE__*/ (() => { let ɵRadioGroupComponent_BaseFactory; return function RadioGroupComponent_Factory(t) { return (ɵRadioGroupComponent_BaseFactory || (ɵRadioGroupComponent_BaseFactory = i0.ɵɵgetInheritedFactory(RadioGroupComponent)))(t || RadioGroupComponent); }; })(); }
    static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: RadioGroupComponent, selectors: [["fusion-radio-group"]], hostAttrs: [1, "fusion-v4"], standalone: true, features: [i0.ɵɵProvidersFeature([
                {
                    provide: NG_VALUE_ACCESSOR,
                    useExisting: forwardRef(() => RadioGroupComponent),
                    multi: true
                }
            ]), i0.ɵɵInheritDefinitionFeature, i0.ɵɵStandaloneFeature], decls: 2, vars: 4, consts: [[1, "fu-radio-group-wrapper"], [3, "name", "value", "label", "selected", "disabled", "changed", 4, "ngFor", "ngForOf"], [3, "name", "value", "label", "selected", "disabled", "changed"]], template: function RadioGroupComponent_Template(rf, ctx) { if (rf & 1) {
            i0.ɵɵelementStart(0, "div", 0);
            i0.ɵɵtemplate(1, RadioGroupComponent_fusion_radio_1_Template, 1, 5, "fusion-radio", 1);
            i0.ɵɵelementEnd();
        } if (rf & 2) {
            i0.ɵɵclassProp("fu-direction-row", ctx.inline);
            i0.ɵɵattribute("id", ctx.id);
            i0.ɵɵadvance();
            i0.ɵɵproperty("ngForOf", ctx.options);
        } }, dependencies: [CommonModule, i1.NgForOf, RadioComponent], styles: [".fusion-v4[_ngcontent-%COMP%]{--spacing-tockenset: 0px;--spacing-25: 2px;--spacing-50: 4px;--spacing-75: 6px;--spacing-100: 8px;--spacing-125: 10px;--spacing-150: 12px;--spacing-200: 16px;--spacing-250: 20px;--spacing-300: 24px;--spacing-400: 32px;--spacing-500: 40px;--spacing-600: 48px;--spacing-700: 56px;--spacing-800: 64px;--spacing-900: 72px;--spacing-1000: 80px}[_nghost-%COMP%]   .fu-radio-group-wrapper[_ngcontent-%COMP%]{display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-start;gap:var(--spacing-100, 8px)}[_nghost-%COMP%]   .fu-radio-group-wrapper.fu-direction-row[_ngcontent-%COMP%]{flex-direction:row;align-items:center}"], changeDetection: 0 }); }
}
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(RadioGroupComponent, [{
        type: Component,
        args: [{ selector: 'fusion-radio-group', standalone: true, imports: [CommonModule, RadioComponent], changeDetection: ChangeDetectionStrategy.OnPush, host: { class: 'fusion-v4' }, providers: [
                    {
                        provide: NG_VALUE_ACCESSOR,
                        useExisting: forwardRef(() => RadioGroupComponent),
                        multi: true
                    }
                ], template: "<div class=\"fu-radio-group-wrapper\" [attr.id]=\"id\" [class.fu-direction-row]=\"inline\">\n    <fusion-radio\n        *ngFor=\"let option of options\"\n        [name]=\"name\"\n        [value]=\"option.id\"\n        [label]=\"option.label\"\n        [selected]=\"isSelected(option)\"\n        [disabled]=\"disabled || option.disabled\"\n        (changed)=\"setSelected($event, option)\"\n    ></fusion-radio>\n</div>\n\n", styles: [".fusion-v4{--spacing-tockenset: 0px;--spacing-25: 2px;--spacing-50: 4px;--spacing-75: 6px;--spacing-100: 8px;--spacing-125: 10px;--spacing-150: 12px;--spacing-200: 16px;--spacing-250: 20px;--spacing-300: 24px;--spacing-400: 32px;--spacing-500: 40px;--spacing-600: 48px;--spacing-700: 56px;--spacing-800: 64px;--spacing-900: 72px;--spacing-1000: 80px}:host .fu-radio-group-wrapper{display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-start;gap:var(--spacing-100, 8px)}:host .fu-radio-group-wrapper.fu-direction-row{flex-direction:row;align-items:center}\n"] }]
    }], null, null); })();
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(RadioGroupComponent, { className: "RadioGroupComponent", filePath: "radio-group.component.ts", lineNumber: 23 }); })();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmFkaW8tZ3JvdXAuY29tcG9uZW50LmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvZnVzaW9uLXVpL2NvbXBvbmVudHMvcmFkaW8tZ3JvdXAvdjQvcmFkaW8tZ3JvdXAuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvZnVzaW9uLXVpL2NvbXBvbmVudHMvcmFkaW8tZ3JvdXAvdjQvcmFkaW8tZ3JvdXAuY29tcG9uZW50Lmh0bWwiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUEsT0FBTyxFQUFDLHVCQUF1QixFQUFFLFNBQVMsRUFBRSxVQUFVLEVBQUMsTUFBTSxlQUFlLENBQUM7QUFDN0UsT0FBTyxFQUFDLFlBQ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