import { ChangeDetectionStrategy, Component } from '@angular/core';
import { LoaderBaseComponent } from '@ironsource/fusion-ui/components/loader/common/base';
import * as i0 from "@angular/core";
import * as i1 from "@angular/common";
import * as i2 from "@ironsource/fusion-ui/components/icon/v1";
function LoaderComponent_div_0_ng_container_1_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementContainer(0, 4, 5);
} if (rf & 2) {
    const ctx_r1 = i0.ɵɵnextContext(2);
    i0.ɵɵproperty("ngComponentOutlet", ctx_r1.componentType);
} }
function LoaderComponent_div_0_ng_container_2_fusion_icon_1_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelement(0, "fusion-icon", 9);
} if (rf & 2) {
    const ctx_r4 = i0.ɵɵnextContext(3);
    i0.ɵɵproperty("name", ctx_r4.loaderIconName);
} }
function LoaderComponent_div_0_ng_container_2_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementContainerStart(0);
    i0.ɵɵtemplate(1, LoaderComponent_div_0_ng_container_2_fusion_icon_1_Template, 1, 1, "fusion-icon", 6);
    i0.ɵɵelementStart(2, "span", 7, 8);
    i0.ɵɵprojection(4);
    i0.ɵɵelementEnd();
    i0.ɵɵelementContainerEnd();
} if (rf & 2) {
    const ctx_r2 = i0.ɵɵnextContext(2);
    i0.ɵɵadvance();
    i0.ɵɵproperty("ngIf", ctx_r2.loaderIconName);
} }
const _c0 = (a0, a1, a2) => [a0, a1, a2];
function LoaderComponent_div_0_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementStart(0, "div", 1);
    i0.ɵɵtemplate(1, LoaderComponent_div_0_ng_container_1_Template, 2, 1, "ng-container", 2)(2, LoaderComponent_div_0_ng_container_2_Template, 5, 1, "ng-container", 3);
    i0.ɵɵelementEnd();
} if (rf & 2) {
    const ctx_r0 = i0.ɵɵnextContext();
    i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction3(3, _c0, ctx_r0.size, ctx_r0.color, ctx_r0.loaderPosition));
    i0.ɵɵadvance();
    i0.ɵɵproperty("ngIf", ctx_r0.componentType);
    i0.ɵɵadvance();
    i0.ɵɵproperty("ngIf", !ctx_r0.componentType);
} }
const _c1 = ["*"];
export class LoaderComponent extends LoaderBaseComponent {
    ngOnInit() {
        this.loaderIconName =
            this.size === 'inline' ? { iconName: 'loading-rotate', iconVersion: 'v2' } : { iconName: 'loader-dots-v4', iconVersion: 'v2' };
    }
    static { this.ɵfac = /*@__PURE__*/ (() => { let ɵLoaderComponent_BaseFactory; return function LoaderComponent_Factory(t) { return (ɵLoaderComponent_BaseFactory || (ɵLoaderComponent_BaseFactory = i0.ɵɵgetInheritedFactory(LoaderComponent)))(t || LoaderComponent); }; })(); }
    static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: LoaderComponent, selectors: [["fusion-loader"]], features: [i0.ɵɵInheritDefinitionFeature], ngContentSelectors: _c1, decls: 1, vars: 1, consts: [["class", "is-loader", 3, "ngClass", 4, "ngIf"], [1, "is-loader", 3, "ngClass"], [3, "ngComponentOutlet", 4, "ngIf"], [4, "ngIf"], [3, "ngComponentOutlet"], ["customLoader", ""], ["class", "fu-loader", 3, "name", 4, "ngIf"], [1, "is-loader-content"], ["ref", ""], [1, "fu-loader", 3, "name"]], template: function LoaderComponent_Template(rf, ctx) { if (rf & 1) {
            i0.ɵɵprojectionDef();
            i0.ɵɵtemplate(0, LoaderComponent_div_0_Template, 3, 7, "div", 0);
        } if (rf & 2) {
            i0.ɵɵproperty("ngIf", ctx.status);
        } }, dependencies: [i1.NgClass, i1.NgComponentOutlet, i1.NgIf, i2.IconComponent], styles: ["[_nghost-%COMP%]   .is-loader[_ngcontent-%COMP%]   .is-loader-content[_ngcontent-%COMP%]{font-size:12px;font-family:HelveticaNeue,helvetica,sans-serif;font-weight:400;letter-spacing:.04px}[_nghost-%COMP%]   .is-loader[_ngcontent-%COMP%]{z-index:1000!important}[_nghost-%COMP%]{display:block}[_nghost-%COMP%]   .is-loader[_ngcontent-%COMP%]{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;flex-direction:column;color:var(--fu-light-900, #7b838c)}[_nghost-%COMP%]   .is-loader.blue[_ngcontent-%COMP%]{color:var(--fu-primary-500, #3083ff)}[_nghost-%COMP%]   .is-loader.white[_ngcontent-%COMP%]{color:var(--fu-white, #ffffff)}[_nghost-%COMP%]   .is-loader[_ngcontent-%COMP%]   fusion-icon.fu-loader[_ngcontent-%COMP%]     svg{width:40px}[_nghost-%COMP%]   .is-loader[_ngcontent-%COMP%]   fusion-icon.fu-loader[_ngcontent-%COMP%]     svg *{fill:currentColor}[_nghost-%COMP%]   .is-loader[_ngcontent-%COMP%]   .is-loader-content[_ngcontent-%COMP%]{margin-top:15px}[_nghost-%COMP%]   .is-loader.small[_ngcontent-%COMP%]   fusion-icon.fu-loader[_ngcontent-%COMP%]     svg{width:30px}[_nghost-%COMP%]   .is-loader.small[_ngcontent-%COMP%]   fusion-icon.fu-loader[_ngcontent-%COMP%]     svg *{fill:currentColor}[_nghost-%COMP%]   .is-loader.inline[_ngcontent-%COMP%]   fusion-icon[class^=fu-loader][_ngcontent-%COMP%]{display:block;position:absolute;right:0}[_nghost-%COMP%]   .is-loader.inline[_ngcontent-%COMP%]   fusion-icon[class^=fu-loader][_ngcontent-%COMP%]     svg{width:32px;height:32px}[_nghost-%COMP%]   .is-loader.inline[_ngcontent-%COMP%]   fusion-icon[class^=fu-loader][_ngcontent-%COMP%]     svg *{fill:currentColor}"], changeDetection: 0 }); }
}
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LoaderComponent, [{
        type: Component,
        args: [{ selector: 'fusion-loader', changeDetection: ChangeDetectionStrategy.OnPush, template: "<div *ngIf=\"status\" class=\"is-loader\" [ngClass]=\"[size, color, loaderPosition]\">\n    <ng-container *ngIf=\"componentType\" [ngComponentOutlet]=\"componentType\" #customLoader></ng-container>\n    <ng-container *ngIf=\"!componentType\">\n        <fusion-icon *ngIf=\"loaderIconName\" class=\"fu-loader\" [name]=\"loaderIconName\"></fusion-icon>\n        <span class=\"is-loader-content\" #ref><ng-content></ng-content></span>\n    </ng-container>\n</div>\n", styles: [":host .is-loader .is-loader-content{font-size:12px;font-family:HelveticaNeue,helvetica,sans-serif;font-weight:400;letter-spacing:.04px}:host .is-loader{z-index:1000!important}:host{display:block}:host .is-loader{position:absolute;inset:0;display:flex;align-items:center;justify-content:center;flex-direction:column;color:var(--fu-light-900, #7b838c)}:host .is-loader.blue{color:var(--fu-primary-500, #3083ff)}:host .is-loader.white{color:var(--fu-white, #ffffff)}:host .is-loader fusion-icon.fu-loader ::ng-deep svg{width:40px}:host .is-loader fusion-icon.fu-loader ::ng-deep svg *{fill:currentColor}:host .is-loader .is-loader-content{margin-top:15px}:host .is-loader.small fusion-icon.fu-loader ::ng-deep svg{width:30px}:host .is-loader.small fusion-icon.fu-loader ::ng-deep svg *{fill:currentColor}:host .is-loader.inline fusion-icon[class^=fu-loader]{display:block;position:absolute;right:0}:host .is-loader.inline fusion-icon[class^=fu-loader] ::ng-deep svg{width:32px;height:32px}:host .is-loader.inline fusion-icon[class^=fu-loader] ::ng-deep svg *{fill:currentColor}\n"] }]
    }], null, null); })();
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(LoaderComponent, { className: "LoaderComponent", filePath: "loader.component.ts", lineNumber: 10 }); })();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9hZGVyLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL2Z1c2lvbi11aS9jb21wb25lbnRzL2xvYWRlci92Mi9sb2FkZXIuY29tcG9uZW50LnRzIiwiLi4vLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvZnVzaW9uLXVpL2NvbXBvbmVudHMvbG9hZGVyL2NvbW1vbi9iYXNlL2xvYWRlci5iYXNlLmNvbXBvbmVudC5odG1sIl0s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