import { Component, Input, Output, EventEmitter } from '@angular/core';
import * as i0 from "@angular/core";
import * as i1 from "@angular/common";
import * as i2 from "@angular/material/button";
export class LoadingContainerComponent {
    ;
    constructor() {
        this.loadingHeightPxSubstract = 38;
        this.isLoadingData = false;
        this.loadingText = `Loading ...`;
        this.hasErrors = false;
        this.errorCaption = "Error";
        this.errorText = "";
        this.enableRetryOnError = false;
        this.retryButtonText = "Retry";
        this.Retry_Click = new EventEmitter();
    }
    ngOnInit() {
    }
    onRetryClick() {
        this.Retry_Click.emit();
    }
    static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: LoadingContainerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
    static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "17.3.12", type: LoadingContainerComponent, selector: "mobicloud-loading-container", inputs: { loadingHeightPxSubstract: "loadingHeightPxSubstract", isLoadingData: "isLoadingData", loadingText: "loadingText", hasErrors: "hasErrors", errorCaption: "errorCaption", errorText: "errorText", enableRetryOnError: "enableRetryOnError", retryButtonText: "retryButtonText" }, outputs: { Retry_Click: "Retry_Click" }, ngImport: i0, template: "<div class=\"mobi-loader\">\n  <div class=\"mobi-loader-overlay\" *ngIf=\"isLoadingData || hasErrors\" [class.loading-page-overlay-error]=\"!isLoadingData && hasErrors\">\n    <div class=\"spinner\" *ngIf=\"isLoadingData\">\n      <svg class=\"spinner_svg\" viewBox=\"25 25 50 50\">\n        <circle class=\"spinner_circle\" cx=\"50\" cy=\"50\" r=\"20\" fill=\"none\" stroke-width=\"2.8\" stroke-miterlimit=\"10\"/>\n      </svg> \n      <svg class=\"logo_svg\">\n        <path fill-rule=\"nonzero\" d=\"M22.5376485,22.9944117 L12.077758,22.9944117 C8.85296405,22.9944117 7.69574135,21.0975616 7.69574135,19.3189149 C7.69574135,17.7759756 8.77651721,16.480634 10.2823094,16.1211278 C10.1294157,15.6322272 10.0641905,15.1195461 10.093647,14.6012696 C10.229007,12.3987692 12.2018964,10.5956425 14.4756637,10.5781568 L14.5114324,10.5781568 C16.3594819,10.5781568 17.9957247,11.6979419 18.6451721,13.3234137 C19.3184653,12.7925475 20.1930451,12.5337589 21.0851586,12.6162915 C22.3482847,12.7337955 23.4536078,13.570312 23.8961578,14.7607393 C24.0911323,15.2846113 24.1437333,15.8203735 24.0490514,16.3624306 C25.2076768,16.9100831 25.9693398,18.0585447 25.9693398,19.3252098 C25.9693398,21.0975616 24.5869847,22.9944117 22.5376485,22.9944117 M16.8321899,0 C7.53583421,0 -0.000140269418,7.51535935 -0.000140269418,16.7862843 C-0.000140269418,26.0572092 7.53583421,33.5725685 16.8321899,33.5725685 C26.1285456,33.5725685 33.66452,26.0572092 33.66452,16.7862843 C33.66452,7.51535935 26.1285456,0 16.8321899,0\"/>\n      </svg>   \n    </div> \n    <div class=\"spinner-text\" *ngIf=\"isLoadingData\">{{loadingText}}</div>\n    <div class=\"mobi-loader-error-info\" *ngIf=\"hasErrors\">\n      <div class=\"error-caption\" *ngIf=\"hasErrors && !isLoadingData && errorCaption!=''\">\n        {{errorCaption}}\n      </div>                    \n      <div class=\"error-text\" *ngIf=\"hasErrors && !isLoadingData && errorText!=''\">\n        {{errorText}}\n      </div>\n      <button class=\"error-retry-button\" mat-raised-button color=\"warn\" (click)=\"onRetryClick()\" *ngIf=\"!isLoadingData && enableRetryOnError\">{{retryButtonText}}</button>\n    </div>       \n  </div>\n  <ng-content></ng-content>\n</div>", styles: [".mobi-loader{width:100%;height:100%}.mobi-loader-overlay{position:absolute;z-index:1002;background-color:var(--default-background-overlay);width:100%;height:100%}.mobi-loader .spinner{width:100%;position:absolute;top:200px;display:flex;align-items:center}.mobi-loader .spinner_svg{height:100px;width:100px;animation:rotate 2s linear infinite;transform-origin:center center;margin:auto}.mobi-loader .logo_svg{fill:var(--default-basecolor-dark);width:36px;height:36px;transform:scale(1.3);position:absolute;left:calc(50% - 16px);top:32px}.mobi-loader .spinner_svg .spinner_circle{stroke-dasharray:1,200;stroke-dashoffset:0;animation:dash 1.5s ease-in-out infinite;stroke-linecap:round;stroke:var(--default-basecolor-dark)}.mobi-loader .spinner-text{margin-top:2px;text-align:center;font-weight:600;position:absolute;top:300px;width:100%;color:var(--default-textcolor-loading)}.mobi-loader-error-info{width:100%;text-align:center;position:absolute;top:calc(50% - 50px);background-color:var(--default-background-error)}.mobi-loader-error-info .error-caption{font-weight:600;font-size:medium;margin-top:20px;color:var(--default-textcolor-error)}.mobi-loader-error-info .error-text{font-size:medium;margin-top:10px;color:var(--default-textcolor-error)}.mobi-loader-error-info .error-retry-button{margin-top:20px;margin-bottom:20px}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i2.MatButton, selector: "    button[mat-button], button[mat-raised-button], button[mat-flat-button],    button[mat-stroked-button]  ", exportAs: ["matButton"] }] }); }
}
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "17.3.12", ngImport: i0, type: LoadingContainerComponent, decorators: [{
            type: Component,
            args: [{ selector: 'mobicloud-loading-container', template: "<div class=\"mobi-loader\">\n  <div class=\"mobi-loader-overlay\" *ngIf=\"isLoadingData || hasErrors\" [class.loading-page-overlay-error]=\"!isLoadingData && hasErrors\">\n    <div class=\"spinner\" *ngIf=\"isLoadingData\">\n      <svg class=\"spinner_svg\" viewBox=\"25 25 50 50\">\n        <circle class=\"spinner_circle\" cx=\"50\" cy=\"50\" r=\"20\" fill=\"none\" stroke-width=\"2.8\" stroke-miterlimit=\"10\"/>\n      </svg> \n      <svg class=\"logo_svg\">\n        <path fill-rule=\"nonzero\" d=\"M22.5376485,22.9944117 L12.077758,22.9944117 C8.85296405,22.9944117 7.69574135,21.0975616 7.69574135,19.3189149 C7.69574135,17.7759756 8.77651721,16.480634 10.2823094,16.1211278 C10.1294157,15.6322272 10.0641905,15.1195461 10.093647,14.6012696 C10.229007,12.3987692 12.2018964,10.5956425 14.4756637,10.5781568 L14.5114324,10.5781568 C16.3594819,10.5781568 17.9957247,11.6979419 18.6451721,13.3234137 C19.3184653,12.7925475 20.1930451,12.5337589 21.0851586,12.6162915 C22.3482847,12.7337955 23.4536078,13.570312 23.8961578,14.7607393 C24.0911323,15.2846113 24.1437333,15.8203735 24.0490514,16.3624306 C25.2076768,16.9100831 25.9693398,18.0585447 25.9693398,19.3252098 C25.9693398,21.0975616 24.5869847,22.9944117 22.5376485,22.9944117 M16.8321899,0 C7.53583421,0 -0.000140269418,7.51535935 -0.000140269418,16.7862843 C-0.000140269418,26.0572092 7.53583421,33.5725685 16.8321899,33.5725685 C26.1285456,33.5725685 33.66452,26.0572092 33.66452,16.7862843 C33.66452,7.51535935 26.1285456,0 16.8321899,0\"/>\n      </svg>   \n    </div> \n    <div class=\"spinner-text\" *ngIf=\"isLoadingData\">{{loadingText}}</div>\n    <div class=\"mobi-loader-error-info\" *ngIf=\"hasErrors\">\n      <div class=\"error-caption\" *ngIf=\"hasErrors && !isLoadingData && errorCaption!=''\">\n        {{errorCaption}}\n      </div>                    \n      <div class=\"error-text\" *ngIf=\"hasErrors && !isLoadingData && errorText!=''\">\n        {{errorText}}\n      </div>\n      <button class=\"error-retry-button\" mat-raised-button color=\"warn\" (click)=\"onRetryClick()\" *ngIf=\"!isLoadingData && enableRetryOnError\">{{retryButtonText}}</button>\n    </div>       \n  </div>\n  <ng-content></ng-content>\n</div>", styles: [".mobi-loader{width:100%;height:100%}.mobi-loader-overlay{position:absolute;z-index:1002;background-color:var(--default-background-overlay);width:100%;height:100%}.mobi-loader .spinner{width:100%;position:absolute;top:200px;display:flex;align-items:center}.mobi-loader .spinner_svg{height:100px;width:100px;animation:rotate 2s linear infinite;transform-origin:center center;margin:auto}.mobi-loader .logo_svg{fill:var(--default-basecolor-dark);width:36px;height:36px;transform:scale(1.3);position:absolute;left:calc(50% - 16px);top:32px}.mobi-loader .spinner_svg .spinner_circle{stroke-dasharray:1,200;stroke-dashoffset:0;animation:dash 1.5s ease-in-out infinite;stroke-linecap:round;stroke:var(--default-basecolor-dark)}.mobi-loader .spinner-text{margin-top:2px;text-align:center;font-weight:600;position:absolute;top:300px;width:100%;color:var(--default-textcolor-loading)}.mobi-loader-error-info{width:100%;text-align:center;position:absolute;top:calc(50% - 50px);background-color:var(--default-background-error)}.mobi-loader-error-info .error-caption{font-weight:600;font-size:medium;margin-top:20px;color:var(--default-textcolor-error)}.mobi-loader-error-info .error-text{font-size:medium;margin-top:10px;color:var(--default-textcolor-error)}.mobi-loader-error-info .error-retry-button{margin-top:20px;margin-bottom:20px}\n"] }]
        }], ctorParameters: () => [], propDecorators: { loadingHeightPxSubstract: [{
                type: Input
            }], isLoadingData: [{
                type: Input
            }], loadingText: [{
                type: Input
            }], hasErrors: [{
                type: Input
            }], errorCaption: [{
                type: Input
            }], errorText: [{
                type: Input
            }], enableRetryOnError: [{
                type: Input
            }], retryButtonText: [{
                type: Input
            }], Retry_Click: [{
                type: Output
            }] } });
//# sourceMappingURL=data:application/json;base64, 