import * as i0 from '@angular/core';
import { Component, ChangeDetectionStrategy, NgModule } from '@angular/core';
import { LoaderBaseComponent } from '@ironsource/fusion-ui/components/loader/common/base';
import * as i1 from '@angular/common';
import { CommonModule } from '@angular/common';
import * as i2 from '@ironsource/fusion-ui/components/icon/v1';
import { IconModule } 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 = ["*"];
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 }); })();

class LoaderModule {
    static { this.ɵfac = function LoaderModule_Factory(t) { return new (t || LoaderModule)(); }; }
    static { this.ɵmod = /*@__PURE__*/ i0.ɵɵdefineNgModule({ type: LoaderModule }); }
    static { this.ɵinj = /*@__PURE__*/ i0.ɵɵdefineInjector({ imports: [CommonModule, IconModule] }); }
}
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(LoaderModule, [{
        type: NgModule,
        args: [{
                declarations: [LoaderComponent],
                exports: [LoaderComponent],
                imports: [CommonModule, IconModule]
            }]
    }], null, null); })();
(function () { (typeof ngJitMode === "undefined" || ngJitMode) && i0.ɵɵsetNgModuleScope(LoaderModule, { declarations: [LoaderComponent], imports: [CommonModule, IconModule], exports: [LoaderComponent] }); })();

/**
 * Generated bundle index. Do not edit.
 */

export { LoaderComponent, LoaderModule };
//# sourceMappingURL=ironsource-fusion-ui-components-loader-v2.mjs.map
