import { ChangeDetectionStrategy, Component, HostBinding, Input, } from '@angular/core';
/**
 * A simple loading mask component which will show a spinner
 * when loading attribute is true.
 */
export class LoadingMaskComponent {
    constructor() {
        this.type = 'content';
    }
    get hidden() {
        return !this.loading;
    }
}
LoadingMaskComponent.decorators = [
    { type: Component, args: [{
                selector: 'acl-loading-mask',
                template: "<div class=\"acl-loading-mask acl-loading-mask--{{ type }}\" *ngIf=\"loading\">\n  <aui-icon class=\"acl-loading-mask__icon\" icon=\"spinner\"></aui-icon>\n  <span class=\"acl-loading-mask__text\">\n    <ng-container *ngIf=\"text\">\n      {{ text }}\n    </ng-container>\n    <ng-container *ngIf=\"!text\">\n      <ng-container *ngIf=\"type === 'module'\">\n        {{ 'loading_please_wait' | translate }}\n      </ng-container>\n      <ng-container *ngIf=\"type === 'content'\">\n        {{ 'loading' | translate }}\n      </ng-container>\n    </ng-container>\n  </span>\n</div>\n",
                changeDetection: ChangeDetectionStrategy.OnPush,
                styles: [":host{display:block}.acl-loading-mask{display:flex;justify-content:center;height:40px;padding:12px 0;align-items:center}.acl-loading-mask__icon{margin-right:4px;color:var(--aui-color-primary);font-size:16px;display:inline-flex}.acl-loading-mask--module{flex-direction:column;height:80px}.acl-loading-mask--module .acl-loading-mask__icon{font-size:32px;margin-bottom:16px}.acl-loading-mask--module .acl-loading-mask__text{font-size:18px}\n"]
            },] }
];
LoadingMaskComponent.propDecorators = {
    loading: [{ type: Input }],
    type: [{ type: Input }],
    text: [{ type: Input }],
    hidden: [{ type: HostBinding, args: ['hidden',] }]
};
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibG9hZGluZy1tYXNrLmNvbXBvbmVudC5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3BhY2thZ2VzL2FsYXVkYS1jb21tb24tbGliL3NyYy93aWRnZXQvbG9hZGluZy1tYXNrL2xvYWRpbmctbWFzay5jb21wb25lbnQudHM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