import { ChangeDetectionStrategy, Component } from '@angular/core';
import { Reason } from '../page-guard/public-api';
import * as i0 from "@angular/core";
function AbnormalPageComponent_ng_container_1_Template(rf, ctx) { if (rf & 1) {
    const _r2 = i0.ɵɵgetCurrentView();
    i0.ɵɵelementContainerStart(0);
    i0.ɵɵelementStart(1, "p", 2)(2, "span");
    i0.ɵɵtext(3);
    i0.ɵɵpipe(4, "translate");
    i0.ɵɵpipe(5, "translate");
    i0.ɵɵelementEnd();
    i0.ɵɵelementStart(6, "button", 3);
    i0.ɵɵlistener("click", function AbnormalPageComponent_ng_container_1_Template_button_click_6_listener() { i0.ɵɵrestoreView(_r2); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.retry()); });
    i0.ɵɵtext(7);
    i0.ɵɵpipe(8, "translate");
    i0.ɵɵelementEnd()();
    i0.ɵɵelementContainerEnd();
} if (rf & 2) {
    i0.ɵɵadvance(3);
    i0.ɵɵtextInterpolate2("", i0.ɵɵpipeBind1(4, 3, "system_abnormal_description"), "", i0.ɵɵpipeBind1(5, 5, "or"), "");
    i0.ɵɵadvance(4);
    i0.ɵɵtextInterpolate1(" ", i0.ɵɵpipeBind1(8, 7, "retry"), " ");
} }
export class AbnormalPageComponent {
    constructor() {
        this.reason = Reason;
    }
    retry() {
        window.location.reload();
    }
}
AbnormalPageComponent.ɵfac = function AbnormalPageComponent_Factory(t) { return new (t || AbnormalPageComponent)(); };
AbnormalPageComponent.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: AbnormalPageComponent, selectors: [["acl-abnormal-page"]], decls: 2, vars: 3, consts: [[3, "allowed", "reason", "isFull"], [4, "aclPageGuardDescription"], [1, "description"], ["aui-button", "text", "size", "small", 3, "click"]], template: function AbnormalPageComponent_Template(rf, ctx) { if (rf & 1) {
        i0.ɵɵelementStart(0, "acl-page-guard", 0);
        i0.ɵɵtemplate(1, AbnormalPageComponent_ng_container_1_Template, 9, 9, "ng-container", 1);
        i0.ɵɵelementEnd();
    } if (rf & 2) {
        i0.ɵɵproperty("allowed", false)("reason", ctx.reason.Abnormal)("isFull", true);
    } }, styles: [".description[_ngcontent-%COMP%]{color:rgb(var(--aui-color-secondary-text))}"], changeDetection: 0 });
(function () { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AbnormalPageComponent, [{
        type: Component,
        args: [{ selector: 'acl-abnormal-page', template: `
    <acl-page-guard
      [allowed]="false"
      [reason]="reason.Abnormal"
      [isFull]="true"
    >
      <ng-container *aclPageGuardDescription>
        <p class="description">
          <span
            >{{ 'system_abnormal_description' | translate
            }}{{ 'or' | translate }}</span
          >
          <button
            aui-button="text"
            size="small"
            (click)="retry()"
          >
            {{ 'retry' | translate }}
          </button>
        </p>
      </ng-container>
    </acl-page-guard>
  `, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".description{color:rgb(var(--aui-color-secondary-text))}\n"] }]
    }], null, null); })();
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYWJub3JtYWwtcGFnZS5jb21wb25lbnQuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi9saWJzL2NvbW1vbi9zcmMvYWJub3JtYWwtcGFnZS9hYm5vcm1hbC1wYWdlLmNvbXBvbmVudC50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsdUJBQXVCLEVBQUUsU0FBUyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBRW5FLE9BQU8sRUFBRSxNQUFNLEVBQUUsTUFBTSwwQkFBMEIsQ0FBQzs7OztJQVU1Qyw2QkFBdUM7SUFDckMsNEJBQXVCLFdBQUE7SUFFbEIsWUFDdUI7OztJQUFBLGlCQUN6QjtJQUNELGlDQUlDO0lBREMsMktBQVMsZUFBQSxjQUFPLENBQUEsSUFBQztJQUVqQixZQUNGOztJQUFBLGlCQUFTLEVBQUE7SUFFYiwwQkFBZT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