You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
abp/npm/ng-packs/dist/theme-shared/fesm5/abp-ng.theme.shared.js

2378 lines
87 KiB

import { ConfigState, ChangePassword, StartLoader, StopLoader, GetProfile, UpdateProfile, ProfileState, RestOccurError, LazyLoadService, CoreModule } from '@abp/ng.core';
import { Component, EventEmitter, Renderer2, Input, Output, ViewChild, Injectable, ɵɵdefineInjectable, ɵɵinject, ElementRef, ChangeDetectorRef, ContentChild, ViewChildren, NgZone, ApplicationRef, ComponentFactoryResolver, RendererFactory2, Injector, INJECTOR, APP_INITIALIZER, NgModule } from '@angular/core';
import { MessageService } from 'primeng/components/common/messageservice';
import { ToastModule } from 'primeng/toast';
import { Subject, ReplaySubject, BehaviorSubject, fromEvent, interval, timer, Observable, forkJoin } from 'rxjs';
import { __read, __assign, __extends, __spread, __decorate, __metadata } from 'tslib';
import { Router, NavigationStart, NavigationEnd, NavigationError } from '@angular/router';
import { Store, ofActionSuccessful, Actions, Select } from '@ngxs/store';
import { Validators, FormBuilder } from '@angular/forms';
import { comparePasswords, takeUntilDestroy, NgxValidateCoreModule } from '@ngx-validate/core';
import snq from 'snq';
import { finalize, takeUntil, debounceTime, filter, withLatestFrom, take } from 'rxjs/operators';
import { animation, style, animate, trigger, transition, useAnimation, keyframes, state } from '@angular/animations';
import { HttpErrorResponse } from '@angular/common/http';
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var BreadcrumbComponent = /** @class */ (function () {
function BreadcrumbComponent(router, store) {
this.router = router;
this.store = store;
this.segments = [];
this.show = !!this.store.selectSnapshot((/**
* @param {?} state
* @return {?}
*/
function (state) { return state.LeptonLayoutState; }));
}
/**
* @return {?}
*/
BreadcrumbComponent.prototype.ngOnInit = /**
* @return {?}
*/
function () {
/** @type {?} */
var splittedUrl = this.router.url.split('/').filter((/**
* @param {?} chunk
* @return {?}
*/
function (chunk) { return chunk; }));
/** @type {?} */
var currentUrl = this.store.selectSnapshot(ConfigState.getRoute(splittedUrl[0]));
this.segments.push(currentUrl.name);
if (splittedUrl.length > 1) {
var _a = __read(splittedUrl), arr = _a.slice(1);
/** @type {?} */
var childRoute = currentUrl;
var _loop_1 = function (i) {
/** @type {?} */
var element = arr[i];
childRoute = childRoute.children.find((/**
* @param {?} child
* @return {?}
*/
function (child) { return child.path === element; }));
this_1.segments.push(childRoute.name);
};
var this_1 = this;
for (var i = 0; i < arr.length; i++) {
_loop_1(i);
}
}
};
BreadcrumbComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-breadcrumb',
template: "<ol *ngIf=\"show\" class=\"breadcrumb\">\n <li class=\"breadcrumb-item\">\n <a routerLink=\"/\"><i class=\"fa fa-home\"></i> </a>\n </li>\n <li\n *ngFor=\"let segment of segments; let last = last\"\n class=\"breadcrumb-item\"\n [class.active]=\"last\"\n aria-current=\"page\"\n >\n {{ segment | abpLocalization }}\n </li>\n</ol>\n"
}] }
];
/** @nocollapse */
BreadcrumbComponent.ctorParameters = function () { return [
{ type: Router },
{ type: Store }
]; };
return BreadcrumbComponent;
}());
if (false) {
/** @type {?} */
BreadcrumbComponent.prototype.show;
/** @type {?} */
BreadcrumbComponent.prototype.segments;
/**
* @type {?}
* @private
*/
BreadcrumbComponent.prototype.router;
/**
* @type {?}
* @private
*/
BreadcrumbComponent.prototype.store;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ButtonComponent = /** @class */ (function () {
function ButtonComponent(renderer) {
this.renderer = renderer;
this.buttonClass = 'btn btn-primary';
this.loading = false;
this.disabled = false;
// tslint:disable-next-line: no-output-native
this.click = new EventEmitter();
// tslint:disable-next-line: no-output-native
this.focus = new EventEmitter();
// tslint:disable-next-line: no-output-native
this.blur = new EventEmitter();
/**
* @deprecated Use buttonType instead. To be deleted in v1
*/
this.type = 'button';
}
Object.defineProperty(ButtonComponent.prototype, "icon", {
get: /**
* @return {?}
*/
function () {
return "" + (this.loading ? 'fa fa-spinner fa-spin' : this.iconClass || 'd-none');
},
enumerable: true,
configurable: true
});
/**
* @return {?}
*/
ButtonComponent.prototype.ngOnInit = /**
* @return {?}
*/
function () {
var _this = this;
if (this.attributes) {
Object.keys(this.attributes).forEach((/**
* @param {?} key
* @return {?}
*/
function (key) {
_this.renderer.setAttribute(_this.buttonRef.nativeElement, key, _this.attributes[key]);
}));
}
};
ButtonComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-button',
// tslint:disable-next-line: component-max-inline-declarations
template: "\n <button\n #button\n [attr.type]=\"buttonType || type\"\n [ngClass]=\"buttonClass\"\n [disabled]=\"loading || disabled\"\n (click)=\"click.emit($event)\"\n (focus)=\"focus.emit($event)\"\n (blur)=\"blur.emit($event)\"\n >\n <i [ngClass]=\"icon\" class=\"mr-1\"></i><ng-content></ng-content>\n </button>\n "
}] }
];
/** @nocollapse */
ButtonComponent.ctorParameters = function () { return [
{ type: Renderer2 }
]; };
ButtonComponent.propDecorators = {
buttonClass: [{ type: Input }],
buttonType: [{ type: Input }],
iconClass: [{ type: Input }],
loading: [{ type: Input }],
disabled: [{ type: Input }],
attributes: [{ type: Input }],
click: [{ type: Output }],
focus: [{ type: Output }],
blur: [{ type: Output }],
buttonRef: [{ type: ViewChild, args: ['button', { static: true },] }],
type: [{ type: Input }]
};
return ButtonComponent;
}());
if (false) {
/** @type {?} */
ButtonComponent.prototype.buttonClass;
/** @type {?} */
ButtonComponent.prototype.buttonType;
/** @type {?} */
ButtonComponent.prototype.iconClass;
/** @type {?} */
ButtonComponent.prototype.loading;
/** @type {?} */
ButtonComponent.prototype.disabled;
/** @type {?} */
ButtonComponent.prototype.attributes;
/** @type {?} */
ButtonComponent.prototype.click;
/** @type {?} */
ButtonComponent.prototype.focus;
/** @type {?} */
ButtonComponent.prototype.blur;
/** @type {?} */
ButtonComponent.prototype.buttonRef;
/**
* @deprecated Use buttonType instead. To be deleted in v1
* @type {?}
*/
ButtonComponent.prototype.type;
/**
* @type {?}
* @private
*/
ButtonComponent.prototype.renderer;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @abstract
* @template T
*/
var /**
* @abstract
* @template T
*/
AbstractToaster = /** @class */ (function () {
function AbstractToaster(messageService) {
this.messageService = messageService;
this.key = 'abpToast';
this.sticky = false;
}
/**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
AbstractToaster.prototype.info = /**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
function (message, title, options) {
return this.show(message, title, 'info', options);
};
/**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
AbstractToaster.prototype.success = /**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
function (message, title, options) {
return this.show(message, title, 'success', options);
};
/**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
AbstractToaster.prototype.warn = /**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
function (message, title, options) {
return this.show(message, title, 'warn', options);
};
/**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
AbstractToaster.prototype.error = /**
* @param {?} message
* @param {?} title
* @param {?=} options
* @return {?}
*/
function (message, title, options) {
return this.show(message, title, 'error', options);
};
/**
* @protected
* @param {?} message
* @param {?} title
* @param {?} severity
* @param {?=} options
* @return {?}
*/
AbstractToaster.prototype.show = /**
* @protected
* @param {?} message
* @param {?} title
* @param {?} severity
* @param {?=} options
* @return {?}
*/
function (message, title, severity, options) {
this.messageService.clear(this.key);
this.messageService.add(__assign({ severity: severity, detail: message || '', summary: title || '' }, options, { key: this.key }, (typeof (options || ((/** @type {?} */ ({})))).sticky === 'undefined' && { sticky: this.sticky })));
this.status$ = new Subject();
return this.status$;
};
/**
* @param {?=} status
* @return {?}
*/
AbstractToaster.prototype.clear = /**
* @param {?=} status
* @return {?}
*/
function (status) {
this.messageService.clear(this.key);
this.status$.next(status || "dismiss" /* dismiss */);
this.status$.complete();
};
return AbstractToaster;
}());
if (false) {
/** @type {?} */
AbstractToaster.prototype.status$;
/** @type {?} */
AbstractToaster.prototype.key;
/** @type {?} */
AbstractToaster.prototype.sticky;
/**
* @type {?}
* @protected
*/
AbstractToaster.prototype.messageService;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ToasterService = /** @class */ (function (_super) {
__extends(ToasterService, _super);
function ToasterService() {
return _super !== null && _super.apply(this, arguments) || this;
}
/**
* @param {?} messages
* @return {?}
*/
ToasterService.prototype.addAll = /**
* @param {?} messages
* @return {?}
*/
function (messages) {
var _this = this;
this.messageService.addAll(messages.map((/**
* @param {?} message
* @return {?}
*/
function (message) { return (__assign({ key: _this.key }, message)); })));
};
ToasterService.decorators = [
{ type: Injectable, args: [{ providedIn: 'root' },] }
];
/** @nocollapse */ ToasterService.ngInjectableDef = ɵɵdefineInjectable({ factory: function ToasterService_Factory() { return new ToasterService(ɵɵinject(MessageService)); }, token: ToasterService, providedIn: "root" });
return ToasterService;
}(AbstractToaster));
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var minLength = Validators.minLength, required = Validators.required;
/** @type {?} */
var PASSWORD_FIELDS = ['newPassword', 'repeatNewPassword'];
var ChangePasswordComponent = /** @class */ (function () {
function ChangePasswordComponent(fb, store, toasterService) {
this.fb = fb;
this.store = store;
this.toasterService = toasterService;
this.visibleChange = new EventEmitter();
this.modalBusy = false;
this.mapErrorsFn = (/**
* @param {?} errors
* @param {?} groupErrors
* @param {?} control
* @return {?}
*/
function (errors, groupErrors, control) {
if (PASSWORD_FIELDS.indexOf(control.name) < 0)
return errors;
return errors.concat(groupErrors.filter((/**
* @param {?} __0
* @return {?}
*/
function (_a) {
var key = _a.key;
return key === 'passwordMismatch';
})));
});
}
Object.defineProperty(ChangePasswordComponent.prototype, "visible", {
get: /**
* @return {?}
*/
function () {
return this._visible;
},
set: /**
* @param {?} value
* @return {?}
*/
function (value) {
this._visible = value;
this.visibleChange.emit(value);
},
enumerable: true,
configurable: true
});
/**
* @return {?}
*/
ChangePasswordComponent.prototype.ngOnInit = /**
* @return {?}
*/
function () {
this.form = this.fb.group({
password: ['', required],
newPassword: ['', required],
repeatNewPassword: ['', required],
}, {
validators: [comparePasswords(PASSWORD_FIELDS)],
});
};
/**
* @return {?}
*/
ChangePasswordComponent.prototype.onSubmit = /**
* @return {?}
*/
function () {
var _this = this;
if (this.form.invalid)
return;
this.modalBusy = true;
this.store
.dispatch(new ChangePassword({
currentPassword: this.form.get('password').value,
newPassword: this.form.get('newPassword').value,
}))
.pipe(finalize((/**
* @return {?}
*/
function () {
_this.modalBusy = false;
})))
.subscribe({
next: (/**
* @return {?}
*/
function () {
_this.visible = false;
_this.form.reset();
}),
error: (/**
* @param {?} err
* @return {?}
*/
function (err) {
_this.toasterService.error(snq((/**
* @return {?}
*/
function () { return err.error.error.message; }), 'AbpAccount::DefaultErrorMessage'), 'Error', {
life: 7000,
});
}),
});
};
/**
* @return {?}
*/
ChangePasswordComponent.prototype.openModal = /**
* @return {?}
*/
function () {
this.visible = true;
};
/**
* @param {?} __0
* @return {?}
*/
ChangePasswordComponent.prototype.ngOnChanges = /**
* @param {?} __0
* @return {?}
*/
function (_a) {
var visible = _a.visible;
if (!visible)
return;
if (visible.currentValue) {
this.openModal();
}
else if (visible.currentValue === false && this.visible) {
this.visible = false;
}
};
ChangePasswordComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-change-password',
template: "<abp-modal [(visible)]=\"visible\" [busy]=\"modalBusy\">\n <ng-template #abpHeader>\n <h4>{{ 'AbpIdentity::ChangePassword' | abpLocalization }}</h4>\n </ng-template>\n <ng-template #abpBody>\n <form [formGroup]=\"form\" (ngSubmit)=\"onSubmit()\" [mapErrorsFn]=\"mapErrorsFn\">\n <div class=\"form-group\">\n <label for=\"current-password\">{{ 'AbpIdentity::DisplayName:CurrentPassword' | abpLocalization }}</label\n ><span> * </span\n ><input type=\"password\" id=\"current-password\" class=\"form-control\" formControlName=\"password\" autofocus />\n </div>\n <div class=\"form-group\">\n <label for=\"new-password\">{{ 'AbpIdentity::DisplayName:NewPassword' | abpLocalization }}</label\n ><span> * </span><input type=\"password\" id=\"new-password\" class=\"form-control\" formControlName=\"newPassword\" />\n </div>\n <div class=\"form-group\">\n <label for=\"confirm-new-password\">{{ 'AbpIdentity::DisplayName:NewPasswordConfirm' | abpLocalization }}</label\n ><span> * </span\n ><input type=\"password\" id=\"confirm-new-password\" class=\"form-control\" formControlName=\"repeatNewPassword\" />\n </div>\n </form>\n </ng-template>\n <ng-template #abpFooter>\n <button type=\"button\" class=\"btn btn-secondary color-white\" #abpClose>\n {{ 'AbpIdentity::Cancel' | abpLocalization }}\n </button>\n <abp-button iconClass=\"fa fa-check\" buttonClass=\"btn btn-primary color-white\" (click)=\"onSubmit()\">{{\n 'AbpIdentity::Save' | abpLocalization\n }}</abp-button>\n </ng-template>\n</abp-modal>\n"
}] }
];
/** @nocollapse */
ChangePasswordComponent.ctorParameters = function () { return [
{ type: FormBuilder },
{ type: Store },
{ type: ToasterService }
]; };
ChangePasswordComponent.propDecorators = {
visible: [{ type: Input }],
visibleChange: [{ type: Output }],
modalContent: [{ type: ViewChild, args: ['modalContent', { static: false },] }]
};
return ChangePasswordComponent;
}());
if (false) {
/**
* @type {?}
* @protected
*/
ChangePasswordComponent.prototype._visible;
/** @type {?} */
ChangePasswordComponent.prototype.visibleChange;
/** @type {?} */
ChangePasswordComponent.prototype.modalContent;
/** @type {?} */
ChangePasswordComponent.prototype.form;
/** @type {?} */
ChangePasswordComponent.prototype.modalBusy;
/** @type {?} */
ChangePasswordComponent.prototype.mapErrorsFn;
/**
* @type {?}
* @private
*/
ChangePasswordComponent.prototype.fb;
/**
* @type {?}
* @private
*/
ChangePasswordComponent.prototype.store;
/**
* @type {?}
* @private
*/
ChangePasswordComponent.prototype.toasterService;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @param {?} count
* @return {?}
*/
function getRandomBackgroundColor(count) {
/** @type {?} */
var colors = [];
for (var i = 0; i < count; i++) {
/** @type {?} */
var r = ((i + 5) * (i + 5) * 474) % 255;
/** @type {?} */
var g = ((i + 5) * (i + 5) * 1600) % 255;
/** @type {?} */
var b = ((i + 5) * (i + 5) * 84065) % 255;
colors.push('rgba(' + r + ', ' + g + ', ' + b + ', 0.7)');
}
return colors;
}
/** @type {?} */
var chartJsLoaded$ = new ReplaySubject(1);
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ChartComponent = /** @class */ (function () {
function ChartComponent(el, cdRef) {
var _this = this;
this.el = el;
this.cdRef = cdRef;
this.options = {};
this.plugins = [];
this.responsive = true;
// tslint:disable-next-line: no-output-on-prefix
this.onDataSelect = new EventEmitter();
this.initialized = new BehaviorSubject(this);
this.onCanvasClick = (/**
* @param {?} event
* @return {?}
*/
function (event) {
if (_this.chart) {
/** @type {?} */
var element = _this.chart.getElementAtEvent(event);
/** @type {?} */
var dataset = _this.chart.getDatasetAtEvent(event);
if (element && element[0] && dataset) {
_this.onDataSelect.emit({
originalEvent: event,
element: element[0],
dataset: dataset
});
}
}
});
this.initChart = (/**
* @return {?}
*/
function () {
/** @type {?} */
var opts = _this.options || {};
opts.responsive = _this.responsive;
// allows chart to resize in responsive mode
if (opts.responsive && (_this.height || _this.width)) {
opts.maintainAspectRatio = false;
}
_this.chart = new Chart(_this.el.nativeElement.children[0].children[0], {
type: _this.type,
data: _this.data,
options: _this.options,
plugins: _this.plugins
});
_this.cdRef.detectChanges();
});
this.generateLegend = (/**
* @return {?}
*/
function () {
if (_this.chart) {
return _this.chart.generateLegend();
}
});
this.refresh = (/**
* @return {?}
*/
function () {
if (_this.chart) {
_this.chart.update();
_this.cdRef.detectChanges();
}
});
this.reinit = (/**
* @return {?}
*/
function () {
if (_this.chart) {
_this.chart.destroy();
_this.initChart();
}
});
}
Object.defineProperty(ChartComponent.prototype, "data", {
get: /**
* @return {?}
*/
function () {
return this._data;
},
set: /**
* @param {?} val
* @return {?}
*/
function (val) {
this._data = val;
this.reinit();
},
enumerable: true,
configurable: true
});
Object.defineProperty(ChartComponent.prototype, "canvas", {
get: /**
* @return {?}
*/
function () {
return this.el.nativeElement.children[0].children[0];
},
enumerable: true,
configurable: true
});
Object.defineProperty(ChartComponent.prototype, "base64Image", {
get: /**
* @return {?}
*/
function () {
return this.chart.toBase64Image();
},
enumerable: true,
configurable: true
});
/**
* @return {?}
*/
ChartComponent.prototype.ngAfterViewInit = /**
* @return {?}
*/
function () {
var _this = this;
chartJsLoaded$.subscribe((/**
* @return {?}
*/
function () {
try {
// tslint:disable-next-line: no-unused-expression
Chart;
}
catch (error) {
console.error("Chart is not found. Import the Chart from app.module like shown below:\n import('chart.js');\n ");
return;
}
_this.initChart();
_this._initialized = true;
}));
};
/**
* @return {?}
*/
ChartComponent.prototype.ngOnDestroy = /**
* @return {?}
*/
function () {
if (this.chart) {
this.chart.destroy();
this._initialized = false;
this.chart = null;
}
};
ChartComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-chart',
template: "<div\n style=\"position:relative\"\n [style.width]=\"responsive && !width ? null : width\"\n [style.height]=\"responsive && !height ? null : height\"\n>\n <canvas\n [attr.width]=\"responsive && !width ? null : width\"\n [attr.height]=\"responsive && !height ? null : height\"\n (click)=\"onCanvasClick($event)\"\n ></canvas>\n</div>\n"
}] }
];
/** @nocollapse */
ChartComponent.ctorParameters = function () { return [
{ type: ElementRef },
{ type: ChangeDetectorRef }
]; };
ChartComponent.propDecorators = {
type: [{ type: Input }],
options: [{ type: Input }],
plugins: [{ type: Input }],
width: [{ type: Input }],
height: [{ type: Input }],
responsive: [{ type: Input }],
onDataSelect: [{ type: Output }],
initialized: [{ type: Output }],
data: [{ type: Input }]
};
return ChartComponent;
}());
if (false) {
/** @type {?} */
ChartComponent.prototype.type;
/** @type {?} */
ChartComponent.prototype.options;
/** @type {?} */
ChartComponent.prototype.plugins;
/** @type {?} */
ChartComponent.prototype.width;
/** @type {?} */
ChartComponent.prototype.height;
/** @type {?} */
ChartComponent.prototype.responsive;
/** @type {?} */
ChartComponent.prototype.onDataSelect;
/** @type {?} */
ChartComponent.prototype.initialized;
/**
* @type {?}
* @private
*/
ChartComponent.prototype._initialized;
/** @type {?} */
ChartComponent.prototype._data;
/** @type {?} */
ChartComponent.prototype.chart;
/** @type {?} */
ChartComponent.prototype.onCanvasClick;
/** @type {?} */
ChartComponent.prototype.initChart;
/** @type {?} */
ChartComponent.prototype.generateLegend;
/** @type {?} */
ChartComponent.prototype.refresh;
/** @type {?} */
ChartComponent.prototype.reinit;
/** @type {?} */
ChartComponent.prototype.el;
/**
* @type {?}
* @private
*/
ChartComponent.prototype.cdRef;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ConfirmationService = /** @class */ (function (_super) {
__extends(ConfirmationService, _super);
function ConfirmationService(messageService) {
var _this = _super.call(this, messageService) || this;
_this.messageService = messageService;
_this.key = 'abpConfirmation';
_this.sticky = true;
_this.destroy$ = new Subject();
return _this;
}
/**
* @param {?} message
* @param {?} title
* @param {?} severity
* @param {?=} options
* @return {?}
*/
ConfirmationService.prototype.show = /**
* @param {?} message
* @param {?} title
* @param {?} severity
* @param {?=} options
* @return {?}
*/
function (message, title, severity, options) {
this.listenToEscape();
return _super.prototype.show.call(this, message, title, severity, options);
};
/**
* @param {?=} status
* @return {?}
*/
ConfirmationService.prototype.clear = /**
* @param {?=} status
* @return {?}
*/
function (status) {
_super.prototype.clear.call(this, status);
this.destroy$.next();
};
/**
* @return {?}
*/
ConfirmationService.prototype.listenToEscape = /**
* @return {?}
*/
function () {
var _this = this;
fromEvent(document, 'keyup')
.pipe(takeUntil(this.destroy$), debounceTime(150), filter((/**
* @param {?} key
* @return {?}
*/
function (key) { return key && key.code === 'Escape'; })))
.subscribe((/**
* @param {?} _
* @return {?}
*/
function (_) {
_this.clear();
}));
};
ConfirmationService.decorators = [
{ type: Injectable, args: [{ providedIn: 'root' },] }
];
/** @nocollapse */
ConfirmationService.ctorParameters = function () { return [
{ type: MessageService }
]; };
/** @nocollapse */ ConfirmationService.ngInjectableDef = ɵɵdefineInjectable({ factory: function ConfirmationService_Factory() { return new ConfirmationService(ɵɵinject(MessageService)); }, token: ConfirmationService, providedIn: "root" });
return ConfirmationService;
}(AbstractToaster));
if (false) {
/** @type {?} */
ConfirmationService.prototype.key;
/** @type {?} */
ConfirmationService.prototype.sticky;
/** @type {?} */
ConfirmationService.prototype.destroy$;
/**
* @type {?}
* @protected
*/
ConfirmationService.prototype.messageService;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ConfirmationComponent = /** @class */ (function () {
function ConfirmationComponent(confirmationService) {
this.confirmationService = confirmationService;
this.confirm = "confirm" /* confirm */;
this.reject = "reject" /* reject */;
this.dismiss = "dismiss" /* dismiss */;
}
/**
* @param {?} status
* @return {?}
*/
ConfirmationComponent.prototype.close = /**
* @param {?} status
* @return {?}
*/
function (status) {
this.confirmationService.clear(status);
};
ConfirmationComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-confirmation',
// tslint:disable-next-line: component-max-inline-declarations
template: "\n <p-toast\n position=\"center\"\n key=\"abpConfirmation\"\n (onClose)=\"close(dismiss)\"\n [modal]=\"true\"\n [baseZIndex]=\"1000\"\n styleClass=\"abp-confirm\"\n >\n <ng-template let-message pTemplate=\"message\">\n <i class=\"fa fa-exclamation-circle abp-confirm-icon\"></i>\n <div *ngIf=\"message.summary\" class=\"abp-confirm-summary\">\n {{ message.summary | abpLocalization: message.titleLocalizationParams }}\n </div>\n <div class=\"abp-confirm-body\">\n {{ message.detail | abpLocalization: message.messageLocalizationParams }}\n </div>\n\n <div class=\"abp-confirm-footer justify-content-center\">\n <button\n *ngIf=\"!message.hideCancelBtn\"\n id=\"cancel\"\n type=\"button\"\n class=\"btn btn-sm btn-primary\"\n (click)=\"close(reject)\"\n >\n {{ message.cancelCopy || 'AbpIdentity::Cancel' | abpLocalization }}\n </button>\n <button\n *ngIf=\"!message.hideYesBtn\"\n id=\"confirm\"\n type=\"button\"\n class=\"btn btn-sm btn-primary\"\n (click)=\"close(confirm)\"\n autofocus\n >\n <span>{{ message.yesCopy || 'AbpIdentity::Yes' | abpLocalization }}</span>\n </button>\n </div>\n </ng-template>\n </p-toast>\n "
}] }
];
/** @nocollapse */
ConfirmationComponent.ctorParameters = function () { return [
{ type: ConfirmationService }
]; };
return ConfirmationComponent;
}());
if (false) {
/** @type {?} */
ConfirmationComponent.prototype.confirm;
/** @type {?} */
ConfirmationComponent.prototype.reject;
/** @type {?} */
ConfirmationComponent.prototype.dismiss;
/**
* @type {?}
* @private
*/
ConfirmationComponent.prototype.confirmationService;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ErrorComponent = /** @class */ (function () {
function ErrorComponent() {
this.title = 'Oops!';
this.details = 'Sorry, an error has occured.';
}
/**
* @return {?}
*/
ErrorComponent.prototype.destroy = /**
* @return {?}
*/
function () {
this.renderer.removeChild(this.host, this.elementRef.nativeElement);
};
ErrorComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-error',
template: "<div class=\"error\">\n <button id=\"abp-close-button mr-3\" type=\"button\" class=\"close\" (click)=\"destroy()\">\n <span aria-hidden=\"true\">&times;</span>\n </button>\n <div class=\"row centered\">\n <div class=\"col-md-12\">\n <div class=\"error-template\">\n <h1>\n {{ title | abpLocalization }}\n </h1>\n <div class=\"error-details\">\n {{ details | abpLocalization }}\n </div>\n <div class=\"error-actions\">\n <a (click)=\"destroy()\" routerLink=\"/\" class=\"btn btn-primary btn-md mt-2\"\n ><span class=\"glyphicon glyphicon-home\"></span>\n {{ { key: '::Menu:Home', defaultValue: 'Home' } | abpLocalization }}\n </a>\n </div>\n </div>\n </div>\n </div>\n</div>\n",
styles: [".error{position:fixed;top:0;background-color:#fff;width:100vw;height:100vh;z-index:999999}.centered{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%)}"]
}] }
];
return ErrorComponent;
}());
if (false) {
/** @type {?} */
ErrorComponent.prototype.title;
/** @type {?} */
ErrorComponent.prototype.details;
/** @type {?} */
ErrorComponent.prototype.renderer;
/** @type {?} */
ErrorComponent.prototype.elementRef;
/** @type {?} */
ErrorComponent.prototype.host;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var LoaderBarComponent = /** @class */ (function () {
function LoaderBarComponent(actions, router, cdRef) {
var _this = this;
this.actions = actions;
this.router = router;
this.cdRef = cdRef;
this.containerClass = 'abp-loader-bar';
this.color = '#77b6ff';
this.isLoading = false;
this.progressLevel = 0;
this.filter = (/**
* @param {?} action
* @return {?}
*/
function (action) { return action.payload.url.indexOf('openid-configuration') < 0; });
actions
.pipe(ofActionSuccessful(StartLoader, StopLoader), filter(this.filter), takeUntilDestroy(this))
.subscribe((/**
* @param {?} action
* @return {?}
*/
function (action) {
if (action instanceof StartLoader)
_this.startLoading();
else
_this.stopLoading();
}));
router.events
.pipe(filter((/**
* @param {?} event
* @return {?}
*/
function (event) {
return event instanceof NavigationStart || event instanceof NavigationEnd || event instanceof NavigationError;
})), takeUntilDestroy(this))
.subscribe((/**
* @param {?} event
* @return {?}
*/
function (event) {
if (event instanceof NavigationStart)
_this.startLoading();
else
_this.stopLoading();
}));
}
Object.defineProperty(LoaderBarComponent.prototype, "boxShadow", {
get: /**
* @return {?}
*/
function () {
return "0 0 10px rgba(" + this.color + ", 0.5)";
},
enumerable: true,
configurable: true
});
/**
* @return {?}
*/
LoaderBarComponent.prototype.ngOnDestroy = /**
* @return {?}
*/
function () {
this.interval.unsubscribe();
};
/**
* @return {?}
*/
LoaderBarComponent.prototype.startLoading = /**
* @return {?}
*/
function () {
var _this = this;
if (this.isLoading || this.progressLevel !== 0)
return;
this.isLoading = true;
this.interval = interval(350).subscribe((/**
* @return {?}
*/
function () {
if (_this.progressLevel < 75) {
_this.progressLevel += Math.random() * 10;
}
else if (_this.progressLevel < 90) {
_this.progressLevel += 0.4;
}
else if (_this.progressLevel < 100) {
_this.progressLevel += 0.1;
}
else {
_this.interval.unsubscribe();
}
_this.cdRef.detectChanges();
}));
};
/**
* @return {?}
*/
LoaderBarComponent.prototype.stopLoading = /**
* @return {?}
*/
function () {
var _this = this;
this.interval.unsubscribe();
this.progressLevel = 100;
this.isLoading = false;
if (this.timer && !this.timer.closed)
return;
this.timer = timer(820).subscribe((/**
* @return {?}
*/
function () {
_this.progressLevel = 0;
_this.cdRef.detectChanges();
}));
};
LoaderBarComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-loader-bar',
template: "\n <div id=\"abp-loader-bar\" [ngClass]=\"containerClass\" [class.is-loading]=\"isLoading\">\n <div\n class=\"abp-progress\"\n [style.width.vw]=\"progressLevel\"\n [ngStyle]=\"{\n 'background-color': color,\n 'box-shadow': boxShadow\n }\"\n ></div>\n </div>\n ",
styles: [".abp-loader-bar{left:0;opacity:0;position:fixed;top:0;transition:opacity .4s linear .4s;z-index:99999}.abp-loader-bar.is-loading{opacity:1;transition:none}.abp-loader-bar .abp-progress{height:3px;left:0;position:fixed;top:0;transition:width .4s}"]
}] }
];
/** @nocollapse */
LoaderBarComponent.ctorParameters = function () { return [
{ type: Actions },
{ type: Router },
{ type: ChangeDetectorRef }
]; };
LoaderBarComponent.propDecorators = {
containerClass: [{ type: Input }],
color: [{ type: Input }],
isLoading: [{ type: Input }],
filter: [{ type: Input }]
};
return LoaderBarComponent;
}());
if (false) {
/** @type {?} */
LoaderBarComponent.prototype.containerClass;
/** @type {?} */
LoaderBarComponent.prototype.color;
/** @type {?} */
LoaderBarComponent.prototype.isLoading;
/** @type {?} */
LoaderBarComponent.prototype.progressLevel;
/** @type {?} */
LoaderBarComponent.prototype.interval;
/** @type {?} */
LoaderBarComponent.prototype.timer;
/** @type {?} */
LoaderBarComponent.prototype.filter;
/**
* @type {?}
* @private
*/
LoaderBarComponent.prototype.actions;
/**
* @type {?}
* @private
*/
LoaderBarComponent.prototype.router;
/**
* @type {?}
* @private
*/
LoaderBarComponent.prototype.cdRef;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/** @type {?} */
var fadeIn = animation([style({ opacity: '0' }), animate('{{ time}} {{ easing }}', style({ opacity: '1' }))], {
params: { time: '350ms', easing: 'ease' },
});
/** @type {?} */
var fadeOut = animation([style({ opacity: '1' }), animate('{{ time}} {{ easing }}', style({ opacity: '0' }))], { params: { time: '350ms', easing: 'ease' } });
/** @type {?} */
var fadeInDown = animation([
style({ opacity: '0', transform: '{{ transform }} translateY(-20px)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '1', transform: '{{ transform }} translateY(0)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/** @type {?} */
var fadeInUp = animation([
style({ opacity: '0', transform: '{{ transform }} translateY(20px)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '1', transform: '{{ transform }} translateY(0)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/** @type {?} */
var fadeInLeft = animation([
style({ opacity: '0', transform: '{{ transform }} translateX(20px)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '1', transform: '{{ transform }} translateX(0)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/** @type {?} */
var fadeInRight = animation([
style({ opacity: '0', transform: '{{ transform }} translateX(-20px)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '1', transform: '{{ transform }} translateX(0)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/** @type {?} */
var fadeOutDown = animation([
style({ opacity: '1', transform: '{{ transform }} translateY(0)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '0', transform: '{{ transform }} translateY(20px)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/** @type {?} */
var fadeOutUp = animation([
style({ opacity: '1', transform: '{{ transform }} translateY(0)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '0', transform: '{{ transform }} translateY(-20px)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/** @type {?} */
var fadeOutLeft = animation([
style({ opacity: '1', transform: '{{ transform }} translateX(0)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '0', transform: '{{ transform }} translateX(20px)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/** @type {?} */
var fadeOutRight = animation([
style({ opacity: '1', transform: '{{ transform }} translateX(0)' }),
animate('{{ time }} {{ easing }}', style({ opacity: '0', transform: '{{ transform }} translateX(-20px)' })),
], { params: { time: '350ms', easing: 'ease', transform: '' } });
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/** @type {?} */
var fadeAnimation = trigger('fade', [
transition(':enter', useAnimation(fadeIn)),
transition(':leave', useAnimation(fadeOut)),
]);
/** @type {?} */
var dialogAnimation = trigger('dialog', [
transition(':enter', useAnimation(fadeInDown)),
transition(':leave', useAnimation(fadeOut)),
]);
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ModalComponent = /** @class */ (function () {
function ModalComponent(renderer, confirmationService) {
this.renderer = renderer;
this.confirmationService = confirmationService;
this.centered = false;
this.modalClass = '';
this.size = 'lg';
this.visibleChange = new EventEmitter();
this.init = new EventEmitter();
this.appear = new EventEmitter();
this.disappear = new EventEmitter();
this._visible = false;
this._busy = false;
this.isModalOpen = false;
this.isConfirmationOpen = false;
this.destroy$ = new Subject();
}
Object.defineProperty(ModalComponent.prototype, "visible", {
get: /**
* @return {?}
*/
function () {
return this._visible;
},
set: /**
* @param {?} value
* @return {?}
*/
function (value) {
var _this = this;
if (typeof value !== 'boolean')
return;
this.isModalOpen = value;
this._visible = value;
this.visibleChange.emit(value);
if (value) {
setTimeout((/**
* @return {?}
*/
function () { return _this.listen(); }), 0);
this.renderer.addClass(document.body, 'modal-open');
this.appear.emit();
}
else {
this.renderer.removeClass(document.body, 'modal-open');
this.disappear.emit();
}
},
enumerable: true,
configurable: true
});
Object.defineProperty(ModalComponent.prototype, "busy", {
get: /**
* @return {?}
*/
function () {
return this._busy;
},
set: /**
* @param {?} value
* @return {?}
*/
function (value) {
if (this.abpSubmit && this.abpSubmit instanceof ButtonComponent) {
this.abpSubmit.loading = value;
}
this._busy = value;
},
enumerable: true,
configurable: true
});
/**
* @return {?}
*/
ModalComponent.prototype.ngOnDestroy = /**
* @return {?}
*/
function () {
this.destroy$.next();
};
/**
* @return {?}
*/
ModalComponent.prototype.close = /**
* @return {?}
*/
function () {
var _this = this;
if (this.busy)
return;
/** @type {?} */
var nodes = getFlatNodes(((/** @type {?} */ (this.modalContent.nativeElement.querySelector('#abp-modal-body')))).childNodes);
if (hasNgDirty(nodes)) {
if (this.isConfirmationOpen)
return;
this.isConfirmationOpen = true;
this.confirmationService
.warn('AbpAccount::AreYouSureYouWantToCancelEditingWarningMessage', 'AbpAccount::AreYouSure')
.subscribe((/**
* @param {?} status
* @return {?}
*/
function (status) {
_this.isConfirmationOpen = false;
if (status === "confirm" /* confirm */) {
_this.visible = false;
}
}));
}
else {
this.visible = false;
}
};
/**
* @return {?}
*/
ModalComponent.prototype.listen = /**
* @return {?}
*/
function () {
var _this = this;
fromEvent(document, 'keyup')
.pipe(takeUntil(this.destroy$), debounceTime(150), filter((/**
* @param {?} key
* @return {?}
*/
function (key) { return key && key.code === 'Escape'; })))
.subscribe((/**
* @param {?} _
* @return {?}
*/
function (_) {
_this.close();
}));
setTimeout((/**
* @return {?}
*/
function () {
if (!_this.abpClose)
return;
fromEvent(_this.abpClose.nativeElement, 'click')
.pipe(takeUntil(_this.destroy$), filter((/**
* @return {?}
*/
function () { return !!_this.modalContent; })))
.subscribe((/**
* @return {?}
*/
function () { return _this.close(); }));
}), 0);
this.init.emit();
};
ModalComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-modal',
template: "<ng-container *ngIf=\"visible\">\n <div class=\"modal show {{ modalClass }}\" tabindex=\"-1\" role=\"dialog\">\n <div class=\"modal-backdrop\" [@fade]=\"isModalOpen\" (click)=\"close()\"></div>\n <div\n id=\"abp-modal-dialog\"\n class=\"modal-dialog modal-{{ size }}\"\n role=\"document\"\n [@dialog]=\"isModalOpen\"\n #abpModalContent\n >\n <div id=\"abp-modal-content\" class=\"modal-content\">\n <div id=\"abp-modal-header\" class=\"modal-header\">\n <ng-container *ngTemplateOutlet=\"abpHeader\"></ng-container>\n \u200B\n <button id=\"abp-modal-close-button\" type=\"button\" class=\"close\" aria-label=\"Close\" (click)=\"close()\">\n <span aria-hidden=\"true\">&times;</span>\n </button>\n </div>\n <div id=\"abp-modal-body\" class=\"modal-body\">\n <ng-container *ngTemplateOutlet=\"abpBody\"></ng-container>\n </div>\n <div id=\"abp-modal-footer\" class=\"modal-footer\">\n <ng-container *ngTemplateOutlet=\"abpFooter\"></ng-container>\n </div>\n </div>\n </div>\n <ng-content></ng-content>\n </div>\n</ng-container>\n",
animations: [fadeAnimation, dialogAnimation]
}] }
];
/** @nocollapse */
ModalComponent.ctorParameters = function () { return [
{ type: Renderer2 },
{ type: ConfirmationService }
]; };
ModalComponent.propDecorators = {
visible: [{ type: Input }],
busy: [{ type: Input }],
centered: [{ type: Input }],
modalClass: [{ type: Input }],
size: [{ type: Input }],
abpSubmit: [{ type: ContentChild, args: [ButtonComponent, { static: false, read: ButtonComponent },] }],
abpHeader: [{ type: ContentChild, args: ['abpHeader', { static: false },] }],
abpBody: [{ type: ContentChild, args: ['abpBody', { static: false },] }],
abpFooter: [{ type: ContentChild, args: ['abpFooter', { static: false },] }],
abpClose: [{ type: ContentChild, args: ['abpClose', { static: false, read: ElementRef },] }],
modalContent: [{ type: ViewChild, args: ['abpModalContent', { static: false },] }],
abpButtons: [{ type: ViewChildren, args: ['abp-button',] }],
visibleChange: [{ type: Output }],
init: [{ type: Output }],
appear: [{ type: Output }],
disappear: [{ type: Output }]
};
return ModalComponent;
}());
if (false) {
/** @type {?} */
ModalComponent.prototype.centered;
/** @type {?} */
ModalComponent.prototype.modalClass;
/** @type {?} */
ModalComponent.prototype.size;
/** @type {?} */
ModalComponent.prototype.abpSubmit;
/** @type {?} */
ModalComponent.prototype.abpHeader;
/** @type {?} */
ModalComponent.prototype.abpBody;
/** @type {?} */
ModalComponent.prototype.abpFooter;
/** @type {?} */
ModalComponent.prototype.abpClose;
/** @type {?} */
ModalComponent.prototype.modalContent;
/** @type {?} */
ModalComponent.prototype.abpButtons;
/** @type {?} */
ModalComponent.prototype.visibleChange;
/** @type {?} */
ModalComponent.prototype.init;
/** @type {?} */
ModalComponent.prototype.appear;
/** @type {?} */
ModalComponent.prototype.disappear;
/** @type {?} */
ModalComponent.prototype._visible;
/** @type {?} */
ModalComponent.prototype._busy;
/** @type {?} */
ModalComponent.prototype.isModalOpen;
/** @type {?} */
ModalComponent.prototype.isConfirmationOpen;
/** @type {?} */
ModalComponent.prototype.destroy$;
/**
* @type {?}
* @private
*/
ModalComponent.prototype.renderer;
/**
* @type {?}
* @private
*/
ModalComponent.prototype.confirmationService;
}
/**
* @param {?} nodes
* @return {?}
*/
function getFlatNodes(nodes) {
return Array.from(nodes).reduce((/**
* @param {?} acc
* @param {?} val
* @return {?}
*/
function (acc, val) { return __spread(acc, (val.childNodes && val.childNodes.length ? getFlatNodes(val.childNodes) : [val])); }), []);
}
/**
* @param {?} nodes
* @return {?}
*/
function hasNgDirty(nodes) {
return nodes.findIndex((/**
* @param {?} node
* @return {?}
*/
function (node) { return (node.className || '').indexOf('ng-dirty') > -1; })) > -1;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var maxLength = Validators.maxLength, required$1 = Validators.required, email = Validators.email;
var ProfileComponent = /** @class */ (function () {
function ProfileComponent(fb, store) {
this.fb = fb;
this.store = store;
this.visibleChange = new EventEmitter();
this.modalBusy = false;
}
Object.defineProperty(ProfileComponent.prototype, "visible", {
get: /**
* @return {?}
*/
function () {
return this._visible;
},
set: /**
* @param {?} value
* @return {?}
*/
function (value) {
this._visible = value;
this.visibleChange.emit(value);
},
enumerable: true,
configurable: true
});
/**
* @return {?}
*/
ProfileComponent.prototype.buildForm = /**
* @return {?}
*/
function () {
var _this = this;
this.store
.dispatch(new GetProfile())
.pipe(withLatestFrom(this.profile$), take(1))
.subscribe((/**
* @param {?} __0
* @return {?}
*/
function (_a) {
var _b = __read(_a, 2), profile = _b[1];
_this.form = _this.fb.group({
userName: [profile.userName, [required$1, maxLength(256)]],
email: [profile.email, [required$1, email, maxLength(256)]],
name: [profile.name || '', [maxLength(64)]],
surname: [profile.surname || '', [maxLength(64)]],
phoneNumber: [profile.phoneNumber || '', [maxLength(16)]]
});
}));
};
/**
* @return {?}
*/
ProfileComponent.prototype.submit = /**
* @return {?}
*/
function () {
var _this = this;
if (this.form.invalid)
return;
this.modalBusy = true;
this.store.dispatch(new UpdateProfile(this.form.value)).subscribe((/**
* @return {?}
*/
function () {
_this.modalBusy = false;
_this.visible = false;
_this.form.reset();
}));
};
/**
* @return {?}
*/
ProfileComponent.prototype.openModal = /**
* @return {?}
*/
function () {
this.buildForm();
this.visible = true;
};
/**
* @param {?} __0
* @return {?}
*/
ProfileComponent.prototype.ngOnChanges = /**
* @param {?} __0
* @return {?}
*/
function (_a) {
var visible = _a.visible;
if (!visible)
return;
if (visible.currentValue) {
this.openModal();
}
else if (visible.currentValue === false && this.visible) {
this.visible = false;
}
};
ProfileComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-profile',
template: "<abp-modal [(visible)]=\"visible\" [busy]=\"modalBusy\">\n <ng-template #abpHeader>\n <h4>{{ 'AbpIdentity::PersonalInfo' | abpLocalization }}</h4>\n </ng-template>\n <ng-template #abpBody>\n <form novalidate *ngIf=\"form\" [formGroup]=\"form\" (ngSubmit)=\"submit()\">\n <div class=\"form-group\">\n <label for=\"username\">{{ 'AbpIdentity::DisplayName:UserName' | abpLocalization }}</label\n ><span> * </span><input type=\"text\" id=\"username\" class=\"form-control\" formControlName=\"userName\" autofocus />\n </div>\n <div class=\"row\">\n <div class=\"col col-md-6\">\n <div class=\"form-group\">\n <label for=\"name\">{{ 'AbpIdentity::DisplayName:Name' | abpLocalization }}</label\n ><input type=\"text\" id=\"name\" class=\"form-control\" formControlName=\"name\" />\n </div>\n </div>\n <div class=\"col col-md-6\">\n <div class=\"form-group\">\n <label for=\"surname\">{{ 'AbpIdentity::DisplayName:Surname' | abpLocalization }}</label\n ><input type=\"text\" id=\"surname\" class=\"form-control\" formControlName=\"surname\" />\n </div>\n </div>\n </div>\n <div class=\"form-group\">\n <label for=\"email-address\">{{ 'AbpIdentity::DisplayName:Email' | abpLocalization }}</label\n ><span> * </span><input type=\"text\" id=\"email-address\" class=\"form-control\" formControlName=\"email\" />\n </div>\n <div class=\"form-group\">\n <label for=\"phone-number\">{{ 'AbpIdentity::DisplayName:PhoneNumber' | abpLocalization }}</label\n ><input type=\"text\" id=\"phone-number\" class=\"form-control\" formControlName=\"phoneNumber\" />\n </div>\n </form>\n </ng-template>\n <ng-template #abpFooter>\n <button #abpClose type=\"button\" class=\"btn btn-secondary color-white\">\n {{ 'AbpIdentity::Cancel' | abpLocalization }}\n </button>\n <abp-button iconClass=\"fa fa-check\" buttonClass=\"btn btn-primary color-white\" (click)=\"submit()\">{{ 'AbpIdentity::Save' | abpLocalization }}</abp-button>\n </ng-template>\n</abp-modal>\n"
}] }
];
/** @nocollapse */
ProfileComponent.ctorParameters = function () { return [
{ type: FormBuilder },
{ type: Store }
]; };
ProfileComponent.propDecorators = {
visible: [{ type: Input }],
visibleChange: [{ type: Output }]
};
__decorate([
Select(ProfileState.getProfile),
__metadata("design:type", Observable)
], ProfileComponent.prototype, "profile$", void 0);
return ProfileComponent;
}());
if (false) {
/**
* @type {?}
* @protected
*/
ProfileComponent.prototype._visible;
/** @type {?} */
ProfileComponent.prototype.visibleChange;
/** @type {?} */
ProfileComponent.prototype.profile$;
/** @type {?} */
ProfileComponent.prototype.form;
/** @type {?} */
ProfileComponent.prototype.modalBusy;
/**
* @type {?}
* @private
*/
ProfileComponent.prototype.fb;
/**
* @type {?}
* @private
*/
ProfileComponent.prototype.store;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var ToastComponent = /** @class */ (function () {
function ToastComponent() {
}
ToastComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-toast',
// tslint:disable-next-line: component-max-inline-declarations
template: "\n <p-toast position=\"bottom-right\" key=\"abpToast\" styleClass=\"abp-toast\" [baseZIndex]=\"1000\">\n <ng-template let-message pTemplate=\"message\">\n <span\n class=\"ui-toast-icon pi\"\n [ngClass]=\"{\n 'pi-info-circle': message.severity == 'info',\n 'pi-exclamation-triangle': message.severity == 'warn',\n 'pi-times': message.severity == 'error',\n 'pi-check': message.severity == 'success'\n }\"\n ></span>\n <div class=\"ui-toast-message-text-content\">\n <div class=\"ui-toast-summary\">{{ message.summary | abpLocalization: message.titleLocalizationParams }}</div>\n <div class=\"ui-toast-detail\">{{ message.detail | abpLocalization: message.messageLocalizationParams }}</div>\n </div>\n </ng-template>\n </p-toast>\n "
}] }
];
return ToastComponent;
}());
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var SortOrderIconComponent = /** @class */ (function () {
function SortOrderIconComponent() {
this.selectedKeyChange = new EventEmitter();
this.orderChange = new EventEmitter();
}
Object.defineProperty(SortOrderIconComponent.prototype, "selectedKey", {
get: /**
* @return {?}
*/
function () {
return this._selectedKey;
},
set: /**
* @param {?} value
* @return {?}
*/
function (value) {
this._selectedKey = value;
this.selectedKeyChange.emit(value);
},
enumerable: true,
configurable: true
});
Object.defineProperty(SortOrderIconComponent.prototype, "order", {
get: /**
* @return {?}
*/
function () {
return this._order;
},
set: /**
* @param {?} value
* @return {?}
*/
function (value) {
this._order = value;
this.orderChange.emit(value);
},
enumerable: true,
configurable: true
});
Object.defineProperty(SortOrderIconComponent.prototype, "icon", {
get: /**
* @return {?}
*/
function () {
if (!this.selectedKey)
return 'fa-sort';
if (this.selectedKey === this.key)
return "fa-sort-" + this.order;
else
return '';
},
enumerable: true,
configurable: true
});
/**
* @param {?} key
* @return {?}
*/
SortOrderIconComponent.prototype.sort = /**
* @param {?} key
* @return {?}
*/
function (key) {
this.selectedKey = key;
switch (this.order) {
case '':
this.order = 'asc';
break;
case 'asc':
this.order = 'desc';
this.orderChange.emit('desc');
break;
case 'desc':
this.order = '';
this.selectedKey = '';
break;
}
};
SortOrderIconComponent.decorators = [
{ type: Component, args: [{
selector: 'abp-sort-order-icon',
template: "<span class=\"float-right {{ iconClass }}\">\n <i class=\"fa {{ icon }}\"></i>\n</span>\n"
}] }
];
SortOrderIconComponent.propDecorators = {
selectedKey: [{ type: Input }],
selectedKeyChange: [{ type: Output }],
key: [{ type: Input }],
order: [{ type: Input }],
orderChange: [{ type: Output }],
iconClass: [{ type: Input }]
};
return SortOrderIconComponent;
}());
if (false) {
/**
* @type {?}
* @private
*/
SortOrderIconComponent.prototype._order;
/**
* @type {?}
* @private
*/
SortOrderIconComponent.prototype._selectedKey;
/** @type {?} */
SortOrderIconComponent.prototype.selectedKeyChange;
/** @type {?} */
SortOrderIconComponent.prototype.key;
/** @type {?} */
SortOrderIconComponent.prototype.orderChange;
/** @type {?} */
SortOrderIconComponent.prototype.iconClass;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var styles = "\n.is-invalid .form-control {\n border-color: #dc3545;\n border-style: solid !important;\n}\n\n.is-invalid .invalid-feedback,\n.is-invalid + * .invalid-feedback {\n display: block;\n}\n\n.data-tables-filter {\n text-align: right;\n}\n\n.pointer {\n cursor: pointer;\n}\n\n.navbar .dropdown-submenu a::after {\n transform: rotate(-90deg);\n position: absolute;\n right: 16px;\n top: 18px;\n}\n\n.navbar .dropdown-menu {\n min-width: 215px;\n}\n\n.modal.show {\n display: block !important;\n}\n\n.modal-backdrop {\n position: absolute !important;\n top: 0 !important;\n left: 0 !important;\n width: 100% !important;\n height: 100% !important;\n background-color: rgba(0, 0, 0, 0.6) !important;\n z-index: 1040 !important;\n}\n\n.modal-dialog {\n z-index: 1050 !important;\n}\n\n.abp-ellipsis-inline {\n display: inline-block;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.abp-ellipsis {\n overflow: hidden !important;\n text-overflow: ellipsis;\n white-space: nowrap;\n}\n\n.abp-toast .ui-toast-message {\n box-sizing: border-box !important;\n border: 2px solid transparent !important;\n border-radius: 4px !important;\n background-color: #f4f4f7 !important;\n color: #1b1d29 !important;\n}\n\n.abp-toast .ui-toast-message-content {\n padding: 10px !important;\n}\n\n.abp-toast .ui-toast-message-content .ui-toast-icon {\n top: 0 !important;\n left: 0 !important;\n padding: 10px !important;\n}\n\n.abp-toast .ui-toast-summary {\n margin: 0 !important;\n font-weight: 700 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-error {\n border-color: #ba1659 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-error .ui-toast-message-content .ui-toast-icon {\n color: #ba1659 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-warning {\n border-color: #ed5d98 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-warning .ui-toast-message-content .ui-toast-icon {\n color: #ed5d98 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-success {\n border-color: #1c9174 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-success .ui-toast-message-content .ui-toast-icon {\n color: #1c9174 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-info {\n border-color: #fccb31 !important;\n}\n\n.abp-toast .ui-toast-message.ui-toast-message-info .ui-toast-message-content .ui-toast-icon {\n color: #fccb31 !important;\n}\n\n.abp-confirm .ui-toast-message {\n box-sizing: border-box !important;\n padding: 0px !important;\n border:0 none !important;\n border-radius: 4px !important;\n background-color: #fff !important;\n color: rgba(0, 0, 0, .65) !important;\n font-family: \"Poppins\", sans-serif;\n text-align: center !important;\n}\n\n.abp-confirm .ui-toast-message-content {\n padding: 0px !important;\n}\n\n.abp-confirm .abp-confirm-icon {\n margin: 32px 50px 5px !important;\n color: #f8bb86 !important;\n font-size: 52px !important;\n}\n\n.abp-confirm .ui-toast-close-icon {\n display: none !important;\n}\n\n.abp-confirm .abp-confirm-summary {\n display: block !important;\n margin-bottom: 13px !important;\n padding: 13px 16px 0px !important;\n font-weight: 600 !important;\n font-size: 18px !important;\n}\n\n.abp-confirm .abp-confirm-body {\n display: inline-block !important;\n padding: 0px 10px !important;\n}\n\n.abp-confirm .abp-confirm-footer {\n display: block !important;\n margin-top: 30px !important;\n padding: 16px !important;\n background-color: #f4f4f7 !important;\n text-align: right !important;\n}\n\n.abp-confirm .abp-confirm-footer .btn {\n margin-left: 10px !important;\n}\n\n.ui-widget-overlay {\n z-index: 1000;\n}\n\n.color-white {\n color: #FFF !important;\n}\n\n/* <animations */\n\n.fade-in-top {\n animation: fadeInTop 0.2s ease-in-out;\n}\n\n.fade-out-top {\n animation: fadeOutTop 0.2s ease-in-out;\n}\n\n\n@keyframes fadeInTop {\n from {\n transform: translateY(-5px);\n opacity: 0;\n }\n\n to {\n transform: translateY(0px);\n opacity: 1;\n }\n}\n\n@keyframes fadeOutTop {\n to {\n transform: translateY(-5px);\n opacity: 0;\n }\n}\n\n/* </animations */\n\n";
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/** @type {?} */
var DEFAULT_ERROR_MESSAGES = {
defaultError: {
title: 'An error has occurred!',
details: 'Error detail not sent by server.',
},
defaultError401: {
title: 'You are not authenticated!',
details: 'You should be authenticated (sign in) in order to perform this operation.',
},
defaultError403: {
title: 'You are not authorized!',
details: 'You are not allowed to perform this operation.',
},
defaultError404: {
title: 'Resource not found!',
details: 'The resource requested could not found on the server.',
},
defaultError500: {
title: '500',
details: { key: 'AbpAccount::InternalServerErrorMessage', defaultValue: 'Error detail not sent by server.' },
},
defaultErrorUnknown: {
title: 'Unknown Error',
details: { key: 'AbpAccount::InternalServerErrorMessage', defaultValue: 'Error detail not sent by server.' },
},
};
var ErrorHandler = /** @class */ (function () {
function ErrorHandler(actions, router, ngZone, store, confirmationService, appRef, cfRes, rendererFactory, injector) {
var _this = this;
this.actions = actions;
this.router = router;
this.ngZone = ngZone;
this.store = store;
this.confirmationService = confirmationService;
this.appRef = appRef;
this.cfRes = cfRes;
this.rendererFactory = rendererFactory;
this.injector = injector;
actions.pipe(ofActionSuccessful(RestOccurError)).subscribe((/**
* @param {?} res
* @return {?}
*/
function (res) {
var _a = res.payload, err = _a === void 0 ? (/** @type {?} */ ({})) : _a;
/** @type {?} */
var body = snq((/**
* @return {?}
*/
function () { return ((/** @type {?} */ (err))).error.error; }), DEFAULT_ERROR_MESSAGES.defaultError.title);
if (err instanceof HttpErrorResponse && err.headers.get('_AbpErrorFormat')) {
/** @type {?} */
var confirmation$ = _this.showError(null, null, body);
if (err.status === 401) {
confirmation$.subscribe((/**
* @return {?}
*/
function () {
_this.navigateToLogin();
}));
}
}
else {
switch (((/** @type {?} */ (err))).status) {
case 401:
_this.showError(DEFAULT_ERROR_MESSAGES.defaultError401.details, DEFAULT_ERROR_MESSAGES.defaultError401.title).subscribe((/**
* @return {?}
*/
function () { return _this.navigateToLogin(); }));
break;
case 403:
_this.createErrorComponent({
title: DEFAULT_ERROR_MESSAGES.defaultError403.title,
details: DEFAULT_ERROR_MESSAGES.defaultError403.details,
});
break;
case 404:
_this.showError(DEFAULT_ERROR_MESSAGES.defaultError404.details, DEFAULT_ERROR_MESSAGES.defaultError404.title);
break;
case 500:
_this.createErrorComponent({
title: DEFAULT_ERROR_MESSAGES.defaultError500.title,
details: DEFAULT_ERROR_MESSAGES.defaultError500.details,
});
break;
case 0:
if (((/** @type {?} */ (err))).statusText === 'Unknown Error') {
_this.createErrorComponent({
title: DEFAULT_ERROR_MESSAGES.defaultErrorUnknown.title,
details: DEFAULT_ERROR_MESSAGES.defaultErrorUnknown.details,
});
}
break;
default:
_this.showError(DEFAULT_ERROR_MESSAGES.defaultError.details, DEFAULT_ERROR_MESSAGES.defaultError.title);
break;
}
}
}));
}
/**
* @private
* @param {?=} message
* @param {?=} title
* @param {?=} body
* @return {?}
*/
ErrorHandler.prototype.showError = /**
* @private
* @param {?=} message
* @param {?=} title
* @param {?=} body
* @return {?}
*/
function (message, title, body) {
if (body) {
if (body.details) {
message = body.details;
title = body.message;
}
else {
message = body.message || DEFAULT_ERROR_MESSAGES.defaultError.title;
}
}
return this.confirmationService.error(message, title, {
hideCancelBtn: true,
yesCopy: 'OK',
});
};
/**
* @private
* @return {?}
*/
ErrorHandler.prototype.navigateToLogin = /**
* @private
* @return {?}
*/
function () {
var _this = this;
this.ngZone.run((/**
* @return {?}
*/
function () {
_this.router.navigate(['/account/login'], {
state: { redirectUrl: _this.router.url },
});
}));
};
/**
* @param {?} instance
* @return {?}
*/
ErrorHandler.prototype.createErrorComponent = /**
* @param {?} instance
* @return {?}
*/
function (instance) {
/** @type {?} */
var renderer = this.rendererFactory.createRenderer(null, null);
/** @type {?} */
var host = renderer.selectRootElement(document.body, true);
/** @type {?} */
var componentRef = this.cfRes.resolveComponentFactory(ErrorComponent).create(this.injector);
for (var key in componentRef.instance) {
if (componentRef.instance.hasOwnProperty(key)) {
componentRef.instance[key] = instance[key];
}
}
this.appRef.attachView(componentRef.hostView);
renderer.appendChild(host, ((/** @type {?} */ (componentRef.hostView))).rootNodes[0]);
componentRef.instance.renderer = renderer;
componentRef.instance.elementRef = componentRef.location;
componentRef.instance.host = host;
};
ErrorHandler.decorators = [
{ type: Injectable, args: [{ providedIn: 'root' },] }
];
/** @nocollapse */
ErrorHandler.ctorParameters = function () { return [
{ type: Actions },
{ type: Router },
{ type: NgZone },
{ type: Store },
{ type: ConfirmationService },
{ type: ApplicationRef },
{ type: ComponentFactoryResolver },
{ type: RendererFactory2 },
{ type: Injector }
]; };
/** @nocollapse */ ErrorHandler.ngInjectableDef = ɵɵdefineInjectable({ factory: function ErrorHandler_Factory() { return new ErrorHandler(ɵɵinject(Actions), ɵɵinject(Router), ɵɵinject(NgZone), ɵɵinject(Store), ɵɵinject(ConfirmationService), ɵɵinject(ApplicationRef), ɵɵinject(ComponentFactoryResolver), ɵɵinject(RendererFactory2), ɵɵinject(INJECTOR)); }, token: ErrorHandler, providedIn: "root" });
return ErrorHandler;
}());
if (false) {
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.actions;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.router;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.ngZone;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.store;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.confirmationService;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.appRef;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.cfRes;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.rendererFactory;
/**
* @type {?}
* @private
*/
ErrorHandler.prototype.injector;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var TableEmptyMessageComponent = /** @class */ (function () {
function TableEmptyMessageComponent() {
this.colspan = 2;
this.localizationResource = 'AbpAccount';
this.localizationProp = 'NoDataAvailableInDatatable';
}
Object.defineProperty(TableEmptyMessageComponent.prototype, "emptyMessage", {
get: /**
* @return {?}
*/
function () {
return this.message || this.localizationResource + "::" + this.localizationProp;
},
enumerable: true,
configurable: true
});
TableEmptyMessageComponent.decorators = [
{ type: Component, args: [{
// tslint:disable-next-line: component-selector
selector: '[abp-table-empty-message]',
template: "\n <td class=\"text-center\" [attr.colspan]=\"colspan\">\n {{ emptyMessage | abpLocalization }}\n </td>\n "
}] }
];
TableEmptyMessageComponent.propDecorators = {
colspan: [{ type: Input }],
message: [{ type: Input }],
localizationResource: [{ type: Input }],
localizationProp: [{ type: Input }]
};
return TableEmptyMessageComponent;
}());
if (false) {
/** @type {?} */
TableEmptyMessageComponent.prototype.colspan;
/** @type {?} */
TableEmptyMessageComponent.prototype.message;
/** @type {?} */
TableEmptyMessageComponent.prototype.localizationResource;
/** @type {?} */
TableEmptyMessageComponent.prototype.localizationProp;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @param {?} injector
* @return {?}
*/
function appendScript(injector) {
/** @type {?} */
var fn = (/**
* @return {?}
*/
function () {
import('chart.js').then((/**
* @return {?}
*/
function () { return chartJsLoaded$.next(true); }));
/** @type {?} */
var lazyLoadService = injector.get(LazyLoadService);
return forkJoin(lazyLoadService.load(null, 'style', styles, 'head', 'afterbegin') /* lazyLoadService.load(null, 'script', scripts) */).toPromise();
});
return fn;
}
var ThemeSharedModule = /** @class */ (function () {
function ThemeSharedModule() {
}
/**
* @return {?}
*/
ThemeSharedModule.forRoot = /**
* @return {?}
*/
function () {
return {
ngModule: ThemeSharedModule,
providers: [
{
provide: APP_INITIALIZER,
multi: true,
deps: [Injector, ErrorHandler],
useFactory: appendScript,
},
{ provide: MessageService, useClass: MessageService },
],
};
};
ThemeSharedModule.decorators = [
{ type: NgModule, args: [{
imports: [CoreModule, ToastModule, NgxValidateCoreModule],
declarations: [
BreadcrumbComponent,
ButtonComponent,
ChangePasswordComponent,
ChartComponent,
ConfirmationComponent,
ErrorComponent,
LoaderBarComponent,
ModalComponent,
ProfileComponent,
TableEmptyMessageComponent,
ToastComponent,
SortOrderIconComponent,
],
exports: [
BreadcrumbComponent,
ButtonComponent,
ChangePasswordComponent,
ChartComponent,
ConfirmationComponent,
LoaderBarComponent,
ModalComponent,
ProfileComponent,
TableEmptyMessageComponent,
ToastComponent,
SortOrderIconComponent,
],
entryComponents: [ErrorComponent],
},] }
];
return ThemeSharedModule;
}());
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/** @type {?} */
var bounceIn = animation([
style({ opacity: '0', display: '{{ display }}' }),
animate('{{ time}} {{ easing }}', keyframes([
style({ opacity: '0', transform: '{{ transform }} scale(0.0)', offset: 0 }),
style({ opacity: '0', transform: '{{ transform }} scale(0.8)', offset: 0.5 }),
style({ opacity: '1', transform: '{{ transform }} scale(1.0)', offset: 1 })
]))
], {
params: {
time: '350ms',
easing: 'cubic-bezier(.7,.31,.72,1.47)',
display: 'block',
transform: 'translate(-50%, -50%)'
}
});
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/** @type {?} */
var collapseY = animation([
style({ height: '*', overflow: 'hidden', 'box-sizing': 'border-box' }),
animate('{{ time }} {{ easing }}', style({ height: '0', padding: '0px' }))
], { params: { time: '350ms', easing: 'ease' } });
/** @type {?} */
var collapseX = animation([
style({ width: '*', overflow: 'hidden', 'box-sizing': 'border-box' }),
animate('{{ time }} {{ easing }}', style({ width: '0', padding: '0px' }))
], { params: { time: '350ms', easing: 'ease' } });
/** @type {?} */
var expandY = animation([
style({ height: '0', overflow: 'hidden', 'box-sizing': 'border-box' }),
animate('{{ time }} {{ easing }}', style({ height: '*', padding: '*' }))
], { params: { time: '350ms', easing: 'ease' } });
/** @type {?} */
var expandX = animation([
style({ width: '0', overflow: 'hidden', 'box-sizing': 'border-box' }),
animate('{{ time }} {{ easing }}', style({ width: '*', padding: '*' }))
], { params: { time: '350ms', easing: 'ease' } });
/** @type {?} */
var collapse = trigger('collapse', [
state('collapsed', style({ height: '0', overflow: 'hidden' })),
state('expanded', style({ height: '*', overflow: 'hidden' })),
transition('expanded => collapsed', useAnimation(collapseY)),
transition('collapsed => expanded', useAnimation(expandY))
]);
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/** @type {?} */
var slideFromBottom = trigger('slideFromBottom', [
transition('* <=> *', [
style({ 'margin-top': '20px', opacity: '0' }),
animate('0.2s ease-out', style({ opacity: '1', 'margin-top': '0px' })),
]),
]);
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var Confirmation;
(function (Confirmation) {
/**
* @record
*/
function Options() { }
Confirmation.Options = Options;
if (false) {
/** @type {?|undefined} */
Options.prototype.hideCancelBtn;
/** @type {?|undefined} */
Options.prototype.hideYesBtn;
/** @type {?|undefined} */
Options.prototype.cancelCopy;
/** @type {?|undefined} */
Options.prototype.yesCopy;
}
})(Confirmation || (Confirmation = {}));
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @record
*/
function SettingTab() { }
if (false) {
/** @type {?} */
SettingTab.prototype.component;
/** @type {?} */
SettingTab.prototype.name;
/** @type {?} */
SettingTab.prototype.order;
/** @type {?|undefined} */
SettingTab.prototype.requiredPolicy;
}
/** @type {?} */
var SETTING_TABS = (/** @type {?} */ ([]));
/**
* @param {?} tab
* @return {?}
*/
function addSettingTab(tab) {
if (!Array.isArray(tab)) {
tab = [tab];
}
SETTING_TABS.push.apply(SETTING_TABS, __spread(tab));
}
/**
* @return {?}
*/
function getSettingTabs() {
return SETTING_TABS;
}
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var Statistics;
(function (Statistics) {
/**
* @record
*/
function Response() { }
Statistics.Response = Response;
if (false) {
/** @type {?} */
Response.prototype.data;
}
/**
* @record
*/
function Data() { }
Statistics.Data = Data;
/**
* @record
*/
function Filter() { }
Statistics.Filter = Filter;
if (false) {
/** @type {?} */
Filter.prototype.startDate;
/** @type {?} */
Filter.prototype.endDate;
}
})(Statistics || (Statistics = {}));
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
var Toaster;
(function (Toaster) {
/**
* @record
*/
function Options() { }
Toaster.Options = Options;
if (false) {
/** @type {?|undefined} */
Options.prototype.id;
/** @type {?|undefined} */
Options.prototype.closable;
/** @type {?|undefined} */
Options.prototype.life;
/** @type {?|undefined} */
Options.prototype.sticky;
/** @type {?|undefined} */
Options.prototype.data;
/** @type {?|undefined} */
Options.prototype.messageLocalizationParams;
/** @type {?|undefined} */
Options.prototype.titleLocalizationParams;
}
})(Toaster || (Toaster = {}));
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
/**
* @fileoverview added by tsickle
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
*/
export { BreadcrumbComponent, ButtonComponent, ChangePasswordComponent, ChartComponent, ConfirmationComponent, ConfirmationService, LoaderBarComponent, ModalComponent, ProfileComponent, SortOrderIconComponent, TableEmptyMessageComponent, ThemeSharedModule, ToastComponent, Toaster, ToasterService, addSettingTab, appendScript, bounceIn, chartJsLoaded$, collapse, collapseX, collapseY, dialogAnimation, expandX, expandY, fadeAnimation, fadeIn, fadeInDown, fadeInLeft, fadeInRight, fadeInUp, fadeOut, fadeOutDown, fadeOutLeft, fadeOutRight, fadeOutUp, getRandomBackgroundColor, getSettingTabs, slideFromBottom, BreadcrumbComponent as ɵa, ButtonComponent as ɵb, ChangePasswordComponent as ɵc, ToasterService as ɵd, AbstractToaster as ɵe, ChartComponent as ɵf, ConfirmationComponent as ɵg, ConfirmationService as ɵh, ErrorComponent as ɵi, LoaderBarComponent as ɵj, ModalComponent as ɵk, fadeAnimation as ɵl, dialogAnimation as ɵm, fadeIn as ɵn, fadeOut as ɵo, fadeInDown as ɵp, ProfileComponent as ɵq, TableEmptyMessageComponent as ɵr, ToastComponent as ɵs, SortOrderIconComponent as ɵt, ErrorHandler as ɵu };
//# sourceMappingURL=abp-ng.theme.shared.js.map