/**
 *
 * An icon block component for Alert Logic
 *
 */
import { Component, Input, ViewEncapsulation } from '@angular/core';
import * as i0 from "@angular/core";
import * as i1 from "@angular/common";
import * as i2 from "primeng-lts/tooltip";
function AlIconBlockComponent_div_0_span_3_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementStart(0, "span", 5);
    i0.ɵɵtext(1);
    i0.ɵɵelementEnd();
} if (rf & 2) {
    const ctx_r2 = i0.ɵɵnextContext(2);
    i0.ɵɵadvance(1);
    i0.ɵɵtextInterpolate(ctx_r2.label);
} }
const _c0 = function (a0) { return { "disabled": a0 }; };
function AlIconBlockComponent_div_0_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementStart(0, "div", 2);
    i0.ɵɵelementStart(1, "i", 3);
    i0.ɵɵtext(2);
    i0.ɵɵelementEnd();
    i0.ɵɵtemplate(3, AlIconBlockComponent_div_0_span_3_Template, 2, 1, "span", 4);
    i0.ɵɵelementEnd();
} if (rf & 2) {
    const ctx_r0 = i0.ɵɵnextContext();
    i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(4, _c0, ctx_r0.disabled));
    i0.ɵɵadvance(1);
    i0.ɵɵproperty("ngClass", ctx_r0.iconClass && !ctx_r0.matIcon ? ctx_r0.iconClass : "material-icons");
    i0.ɵɵadvance(1);
    i0.ɵɵtextInterpolate(ctx_r0.matIcon);
    i0.ɵɵadvance(1);
    i0.ɵɵproperty("ngIf", ctx_r0.label);
} }
function AlIconBlockComponent_div_1_i_1_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementStart(0, "i", 9);
    i0.ɵɵtext(1);
    i0.ɵɵelementEnd();
} if (rf & 2) {
    const ctx_r3 = i0.ɵɵnextContext(2);
    i0.ɵɵproperty("ngClass", ctx_r3.iconClass && !ctx_r3.matIcon ? ctx_r3.iconClass : "material-icons");
    i0.ɵɵadvance(1);
    i0.ɵɵtextInterpolate(ctx_r3.matIcon);
} }
function AlIconBlockComponent_div_1_span_2_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementStart(0, "span", 10);
    i0.ɵɵtext(1);
    i0.ɵɵelementEnd();
} if (rf & 2) {
    const ctx_r4 = i0.ɵɵnextContext(2);
    i0.ɵɵadvance(1);
    i0.ɵɵtextInterpolate(ctx_r4.label);
} }
const _c1 = function (a0) { return { "disabled u-bg-gray-100": a0 }; };
function AlIconBlockComponent_div_1_Template(rf, ctx) { if (rf & 1) {
    i0.ɵɵelementStart(0, "div", 6);
    i0.ɵɵtemplate(1, AlIconBlockComponent_div_1_i_1_Template, 2, 2, "i", 7);
    i0.ɵɵtemplate(2, AlIconBlockComponent_div_1_span_2_Template, 2, 1, "span", 8);
    i0.ɵɵelementEnd();
} if (rf & 2) {
    const ctx_r1 = i0.ɵɵnextContext();
    i0.ɵɵpropertyInterpolate("pTooltip", ctx_r1.tooltip.tooltipText);
    i0.ɵɵpropertyInterpolate("tooltipPosition", ctx_r1.tooltip.tooltipPosition || "bottom");
    i0.ɵɵproperty("ngClass", i0.ɵɵpureFunction1(5, _c1, ctx_r1.disabled));
    i0.ɵɵadvance(1);
    i0.ɵɵproperty("ngIf", ctx_r1.tooltip.showTooltip);
    i0.ɵɵadvance(1);
    i0.ɵɵproperty("ngIf", ctx_r1.label);
} }
export class AlIconBlockComponent {
    constructor() {
        this.disabled = false;
        this.tooltip = {
            showTooltip: false
        };
    }
}
/** @nocollapse */ AlIconBlockComponent.ɵfac = function AlIconBlockComponent_Factory(t) { return new (t || AlIconBlockComponent)(); };
/** @nocollapse */ AlIconBlockComponent.ɵcmp = i0.ɵɵdefineComponent({ type: AlIconBlockComponent, selectors: [["al-icon-block"]], inputs: { matIcon: "matIcon", iconClass: "iconClass", label: "label", disabled: "disabled", tooltip: "tooltip" }, decls: 2, vars: 2, consts: [["class", "wrapper u-flex u-col-align-center u-justify-center u-flex-col u-cursor-pointer u-w-18", 3, "ngClass", 4, "ngIf"], ["class", "wrapper u-w-18", 3, "ngClass", "pTooltip", "tooltipPosition", 4, "ngIf"], [1, "wrapper", "u-flex", "u-col-align-center", "u-justify-center", "u-flex-col", "u-cursor-pointer", "u-w-18", 3, "ngClass"], [1, "u-text-xxxl", 3, "ngClass"], ["class", "u-pt-1 u-text-xxs", 4, "ngIf"], [1, "u-pt-1", "u-text-xxs"], [1, "wrapper", "u-w-18", 3, "ngClass", "pTooltip", "tooltipPosition"], ["class", "u-text-xxl", 3, "ngClass", 4, "ngIf"], ["class", "label u-pt-1 u-text-xxs", 4, "ngIf"], [1, "u-text-xxl", 3, "ngClass"], [1, "label", "u-pt-1", "u-text-xxs"]], template: function AlIconBlockComponent_Template(rf, ctx) { if (rf & 1) {
        i0.ɵɵtemplate(0, AlIconBlockComponent_div_0_Template, 4, 6, "div", 0);
        i0.ɵɵtemplate(1, AlIconBlockComponent_div_1_Template, 3, 7, "div", 1);
    } if (rf & 2) {
        i0.ɵɵproperty("ngIf", !ctx.tooltip.showTooltip);
        i0.ɵɵadvance(1);
        i0.ɵɵproperty("ngIf", ctx.tooltip.showTooltip);
    } }, directives: [i1.NgIf, i1.NgClass, i2.Tooltip], styles: ["al-icon-block .wrapper{overflow-y:visible;display:flex;flex-direction:column;align-items:center}al-icon-block .wrapper.disabled{cursor:not-allowed;opacity:.5;background-color:transparent}"], encapsulation: 2 });
/*@__PURE__*/ (function () { i0.ɵsetClassMetadata(AlIconBlockComponent, [{
        type: Component,
        args: [{
                selector: 'al-icon-block',
                templateUrl: './al-icon-block.component.html',
                styleUrls: ['./al-icon-block.component.scss'],
                encapsulation: ViewEncapsulation.None
            }]
    }], null, { matIcon: [{
            type: Input
        }], iconClass: [{
            type: Input
        }], label: [{
            type: Input
        }], disabled: [{
            type: Input
        }], tooltip: [{
            type: Input
        }] }); })();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWwtaWNvbi1ibG9jay5jb21wb25lbnQuanMiLCJzb3VyY2VSb290Ijoibmc6Ly9AYWwvbmctZ2VuZXJpYy1jb21wb25lbnRzLyIsIn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