raise-common-lib 0.0.150 → 0.0.151
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/bundles/raise-common-lib.umd.js +227 -154
- package/bundles/raise-common-lib.umd.js.map +1 -1
- package/bundles/raise-common-lib.umd.min.js +1 -1
- package/bundles/raise-common-lib.umd.min.js.map +1 -1
- package/esm2015/lib/dialog/common-delete-dialog/index.component.js +30 -2
- package/esm2015/lib/dialog/common-dialog/index.component.js +47 -11
- package/esm2015/lib/raise-common-lib.module.js +5 -4
- package/esm2015/lib/service/dialog.service.js +1 -1
- package/esm2015/public-api.js +2 -1
- package/esm2015/raise-common-lib.js +3 -4
- package/esm5/lib/dialog/common-delete-dialog/index.component.js +35 -2
- package/esm5/lib/dialog/common-dialog/index.component.js +51 -12
- package/esm5/lib/raise-common-lib.module.js +5 -4
- package/esm5/lib/service/dialog.service.js +1 -1
- package/esm5/public-api.js +2 -1
- package/esm5/raise-common-lib.js +3 -4
- package/fesm2015/raise-common-lib.js +202 -137
- package/fesm2015/raise-common-lib.js.map +1 -1
- package/fesm5/raise-common-lib.js +226 -153
- package/fesm5/raise-common-lib.js.map +1 -1
- package/lib/dialog/common-delete-dialog/index.component.d.ts +4 -0
- package/lib/dialog/common-dialog/index.component.d.ts +6 -1
- package/lib/service/dialog.service.d.ts +2 -0
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
- package/raise-common-lib.d.ts +1 -2
- package/raise-common-lib.metadata.json +1 -1
- package/src/assets/img/grow-icon.svg +6 -0
- package/src/assets/img/shrink-icon.svg +6 -0
|
@@ -1767,6 +1767,10 @@ if (false) {
|
|
|
1767
1767
|
DialogConfig.prototype.hideSaveBtn;
|
|
1768
1768
|
/** @type {?|undefined} */
|
|
1769
1769
|
DialogConfig.prototype.hideCloseBtn;
|
|
1770
|
+
/** @type {?|undefined} */
|
|
1771
|
+
DialogConfig.prototype.showZoomBtn;
|
|
1772
|
+
/** @type {?|undefined} */
|
|
1773
|
+
DialogConfig.prototype.onCloseRequest;
|
|
1770
1774
|
}
|
|
1771
1775
|
var CommonDeleteComponent = /** @class */ (function () {
|
|
1772
1776
|
function CommonDeleteComponent(data, dialogRef) {
|
|
@@ -1777,6 +1781,7 @@ var CommonDeleteComponent = /** @class */ (function () {
|
|
|
1777
1781
|
this.cancelBtnLabel = "";
|
|
1778
1782
|
this.description = "";
|
|
1779
1783
|
this.size = "small";
|
|
1784
|
+
this.showZoomBtn = false;
|
|
1780
1785
|
}
|
|
1781
1786
|
/**
|
|
1782
1787
|
* @return {?}
|
|
@@ -1797,6 +1802,7 @@ var CommonDeleteComponent = /** @class */ (function () {
|
|
|
1797
1802
|
this.translation.IF_YOU_DELETE_THIS_RECORD_WARNING ||
|
|
1798
1803
|
".If you delete this record, you won't be able to recover it. Do you want to delete it?";
|
|
1799
1804
|
this.size = this.data.size || "small";
|
|
1805
|
+
this.showZoomBtn = this.data.showZoomBtn || false;
|
|
1800
1806
|
};
|
|
1801
1807
|
/**
|
|
1802
1808
|
* @param {?} e
|
|
@@ -1809,10 +1815,35 @@ var CommonDeleteComponent = /** @class */ (function () {
|
|
|
1809
1815
|
function (e) {
|
|
1810
1816
|
this.dialogRef.close(e);
|
|
1811
1817
|
};
|
|
1818
|
+
/**
|
|
1819
|
+
* @param {?} e
|
|
1820
|
+
* @return {?}
|
|
1821
|
+
*/
|
|
1822
|
+
CommonDeleteComponent.prototype.onClose = /**
|
|
1823
|
+
* @param {?} e
|
|
1824
|
+
* @return {?}
|
|
1825
|
+
*/
|
|
1826
|
+
function (e) {
|
|
1827
|
+
var _this = this;
|
|
1828
|
+
if (this.data.onCloseRequest) {
|
|
1829
|
+
this.data.onCloseRequest(e).then((/**
|
|
1830
|
+
* @param {?} confirmed
|
|
1831
|
+
* @return {?}
|
|
1832
|
+
*/
|
|
1833
|
+
function (confirmed) {
|
|
1834
|
+
if (confirmed) {
|
|
1835
|
+
_this.dialogRef.close();
|
|
1836
|
+
}
|
|
1837
|
+
}));
|
|
1838
|
+
}
|
|
1839
|
+
else {
|
|
1840
|
+
this.dialogRef.close();
|
|
1841
|
+
}
|
|
1842
|
+
};
|
|
1812
1843
|
CommonDeleteComponent.decorators = [
|
|
1813
1844
|
{ type: Component, args: [{
|
|
1814
1845
|
selector: "kt-common-delete-dialog",
|
|
1815
|
-
template: "<kt-common-dialog\r\n\t[size]=\"size\"\r\n\t[title]=\"title\"\r\n\t[hideHeader]=\"false\"\r\n\t[hideCloseBtn]=\"data.hideCloseBtn === undefined ? false : data.hideCloseBtn\"\r\n\t[hideSaveBtn]=\"data.hideSaveBtn === undefined ? false : data.hideSaveBtn\"\r\n\t[saveBtnLabel]=\"saveBtnLabel\"\r\n\t[cancelBtnLabel]=\"cancelBtnLabel\"\r\n\t[showErrorIcon]=\"\r\n\t\tdata.showErrorIcon === undefined ? false : data.showErrorIcon\r\n\t\"\r\n\t[hideCloseIcon]=\"\r\n\t\tdata.hideCloseIcon === undefined ? false : data.hideCloseIcon\r\n\t\"\r\n\t(saveEmit)=\"onSave($event)\"\r\n>\r\n\t<div class=\"mapping-dialog\">\r\n\t\t{{ description }}\r\n\t</div>\r\n</kt-common-dialog>\r\n",
|
|
1846
|
+
template: "<kt-common-dialog\r\n\t[size]=\"size\"\r\n\t[title]=\"title\"\r\n\t[hideHeader]=\"false\"\r\n\t[hideCloseBtn]=\"data.hideCloseBtn === undefined ? false : data.hideCloseBtn\"\r\n\t[hideSaveBtn]=\"data.hideSaveBtn === undefined ? false : data.hideSaveBtn\"\r\n\t[saveBtnLabel]=\"saveBtnLabel\"\r\n\t[cancelBtnLabel]=\"cancelBtnLabel\"\r\n\t[showZoomBtn]=\"showZoomBtn\"\r\n\t[showErrorIcon]=\"\r\n\t\tdata.showErrorIcon === undefined ? false : data.showErrorIcon\r\n\t\"\r\n\t[hideCloseIcon]=\"\r\n\t\tdata.hideCloseIcon === undefined ? false : data.hideCloseIcon\r\n\t\"\r\n\t(saveEmit)=\"onSave($event)\"\r\n>\r\n\t<div class=\"mapping-dialog\">\r\n\t\t{{ description }}\r\n\t</div>\r\n</kt-common-dialog>\r\n",
|
|
1816
1847
|
styles: [".mapping-dialog{color:#44566c;font-family:Arial;font-size:12px;line-height:16px;white-space:pre-line}"]
|
|
1817
1848
|
}] }
|
|
1818
1849
|
];
|
|
@@ -1837,6 +1868,8 @@ if (false) {
|
|
|
1837
1868
|
/** @type {?} */
|
|
1838
1869
|
CommonDeleteComponent.prototype.size;
|
|
1839
1870
|
/** @type {?} */
|
|
1871
|
+
CommonDeleteComponent.prototype.showZoomBtn;
|
|
1872
|
+
/** @type {?} */
|
|
1840
1873
|
CommonDeleteComponent.prototype.data;
|
|
1841
1874
|
/** @type {?} */
|
|
1842
1875
|
CommonDeleteComponent.prototype.dialogRef;
|
|
@@ -22651,6 +22684,194 @@ if (false) {
|
|
|
22651
22684
|
ToolbarItemComponent.prototype.ImageType;
|
|
22652
22685
|
}
|
|
22653
22686
|
|
|
22687
|
+
/**
|
|
22688
|
+
* @fileoverview added by tsickle
|
|
22689
|
+
* Generated from: lib/dialog/common-dialog/index.component.ts
|
|
22690
|
+
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
22691
|
+
*/
|
|
22692
|
+
var CommonDialogComponent = /** @class */ (function () {
|
|
22693
|
+
function CommonDialogComponent(dialogRef) {
|
|
22694
|
+
this.dialogRef = dialogRef;
|
|
22695
|
+
// 隐藏元素相关属性
|
|
22696
|
+
this.hideHeader = false;
|
|
22697
|
+
this.hideCloseIcon = false;
|
|
22698
|
+
this.hideCloseBtn = false;
|
|
22699
|
+
this.hideSaveBtn = false;
|
|
22700
|
+
this.saveBtnLabel = "";
|
|
22701
|
+
this.cancelBtnLabel = "";
|
|
22702
|
+
this.showErrorIcon = false;
|
|
22703
|
+
this.showZoomBtn = false;
|
|
22704
|
+
// 显示相关属性
|
|
22705
|
+
this.dialogStyle = {};
|
|
22706
|
+
this.size = "";
|
|
22707
|
+
this.title = "Dialog";
|
|
22708
|
+
this.loading = false;
|
|
22709
|
+
this.saveEmit = new EventEmitter();
|
|
22710
|
+
this.closeEmit = new EventEmitter();
|
|
22711
|
+
this.defaultSize = "";
|
|
22712
|
+
this.customFooter = false;
|
|
22713
|
+
}
|
|
22714
|
+
/**
|
|
22715
|
+
* @return {?}
|
|
22716
|
+
*/
|
|
22717
|
+
CommonDialogComponent.prototype.ngAfterContentInit = /**
|
|
22718
|
+
* @return {?}
|
|
22719
|
+
*/
|
|
22720
|
+
function () {
|
|
22721
|
+
this.customFooter = !!this.footerContent;
|
|
22722
|
+
};
|
|
22723
|
+
/**
|
|
22724
|
+
* @return {?}
|
|
22725
|
+
*/
|
|
22726
|
+
CommonDialogComponent.prototype.ngOnInit = /**
|
|
22727
|
+
* @return {?}
|
|
22728
|
+
*/
|
|
22729
|
+
function () {
|
|
22730
|
+
this.getInfo();
|
|
22731
|
+
};
|
|
22732
|
+
/**
|
|
22733
|
+
* @return {?}
|
|
22734
|
+
*/
|
|
22735
|
+
CommonDialogComponent.prototype.onClose = /**
|
|
22736
|
+
* @return {?}
|
|
22737
|
+
*/
|
|
22738
|
+
function () {
|
|
22739
|
+
var _this = this;
|
|
22740
|
+
if (this.onCloseRequest) {
|
|
22741
|
+
this.onCloseRequest().then((/**
|
|
22742
|
+
* @param {?} confirmed
|
|
22743
|
+
* @return {?}
|
|
22744
|
+
*/
|
|
22745
|
+
function (confirmed) {
|
|
22746
|
+
if (confirmed) {
|
|
22747
|
+
_this.dialogRef.close();
|
|
22748
|
+
}
|
|
22749
|
+
}));
|
|
22750
|
+
}
|
|
22751
|
+
else {
|
|
22752
|
+
this.dialogRef.close();
|
|
22753
|
+
}
|
|
22754
|
+
};
|
|
22755
|
+
/**
|
|
22756
|
+
* @return {?}
|
|
22757
|
+
*/
|
|
22758
|
+
CommonDialogComponent.prototype.onZoom = /**
|
|
22759
|
+
* @return {?}
|
|
22760
|
+
*/
|
|
22761
|
+
function () {
|
|
22762
|
+
if (this.size === "largest") {
|
|
22763
|
+
this.size = this.defaultSize; // 恢复到原始大小
|
|
22764
|
+
}
|
|
22765
|
+
else {
|
|
22766
|
+
this.size = "largest"; // 设置为最大化
|
|
22767
|
+
}
|
|
22768
|
+
};
|
|
22769
|
+
/**
|
|
22770
|
+
* @return {?}
|
|
22771
|
+
*/
|
|
22772
|
+
CommonDialogComponent.prototype.onSave = /**
|
|
22773
|
+
* @return {?}
|
|
22774
|
+
*/
|
|
22775
|
+
function () {
|
|
22776
|
+
var _this = this;
|
|
22777
|
+
// 这里把关闭事件emit上去,但是必须使用箭头函数保存this对象
|
|
22778
|
+
this.saveEmit.emit((/**
|
|
22779
|
+
* @param {?} res
|
|
22780
|
+
* @return {?}
|
|
22781
|
+
*/
|
|
22782
|
+
function (res) {
|
|
22783
|
+
_this.dialogRef.close(res);
|
|
22784
|
+
}));
|
|
22785
|
+
};
|
|
22786
|
+
/**
|
|
22787
|
+
* @private
|
|
22788
|
+
* @return {?}
|
|
22789
|
+
*/
|
|
22790
|
+
CommonDialogComponent.prototype.getInfo = /**
|
|
22791
|
+
* @private
|
|
22792
|
+
* @return {?}
|
|
22793
|
+
*/
|
|
22794
|
+
function () {
|
|
22795
|
+
this.translation = JSON.parse(localStorage.getItem("translation")) || {};
|
|
22796
|
+
this.saveBtnLabel = this.saveBtnLabel || this.translation.SAVE || ".SAVE";
|
|
22797
|
+
this.cancelBtnLabel =
|
|
22798
|
+
this.cancelBtnLabel || this.translation.CANCEL || ".CANCEL";
|
|
22799
|
+
this.defaultSize = this.size;
|
|
22800
|
+
};
|
|
22801
|
+
CommonDialogComponent.decorators = [
|
|
22802
|
+
{ type: Component, args: [{
|
|
22803
|
+
selector: "rs-common-dialog",
|
|
22804
|
+
template: "<div class=\"dialog\" [ngClass]=\"size\" [ngStyle]=\"dialogStyle\">\r\n <!-- \u5934\u90E8 -->\r\n <div *ngIf=\"!hideHeader\" mat-dialog-title class=\"dialog__header\">\r\n <div class=\"header__title\">\r\n <img\r\n src=\"../../../assets/img/notification-status-warning.svg\"\r\n alt=\"\"\r\n *ngIf=\"showErrorIcon\"\r\n />\r\n {{ title }}\r\n </div>\r\n <div class=\"header__actions\">\r\n <div *ngIf=\"showZoomBtn\" class=\"header__close-btn\" (click)=\"onZoom()\">\r\n <img\r\n class=\"header__close-icon\"\r\n *ngIf=\"size === 'largest'\"\r\n src=\"../../../assets/img/shrink-icon.svg\"\r\n />\r\n <img\r\n class=\"header__close-icon\"\r\n *ngIf=\"size !== 'largest'\"\r\n src=\"../../../assets/img/grow-icon.svg\"\r\n />\r\n </div>\r\n <div *ngIf=\"!hideCloseIcon\" class=\"header__close-btn\" (click)=\"onClose()\">\r\n <img class=\"header__close-icon\" src=\"../../../assets/img/close.svg\" />\r\n </div>\r\n </div>\r\n </div>\r\n <!-- \u5185\u5BB9 -->\r\n <div class=\"dialog__content\" mat-dialog-content>\r\n <ng-content></ng-content>\r\n </div>\r\n <!-- \u5E95\u90E8\u6309\u94AE -->\r\n <div mat-dialog-actions class=\"dialog__footer\">\r\n <ng-content select=\"[footerSlot]\"></ng-content>\r\n <!-- \u9ED8\u8BA4\u5C55\u793A\u4FDD\u5B58/\u5173\u95ED\u6309\u94AE -->\r\n <ng-container *ngIf=\"!customFooter\">\r\n <ng-template [ngTemplateOutlet]=\"defaultTemplate\"></ng-template>\r\n </ng-container>\r\n <ng-template #defaultTemplate>\r\n <button\r\n *ngIf=\"!hideCloseBtn\"\r\n class=\"e-btn\"\r\n (click)=\"onClose()\"\r\n >\r\n {{ cancelBtnLabel }}\r\n </button>\r\n <button\r\n *ngIf=\"!hideSaveBtn\"\r\n class=\"e-btn e-primary\"\r\n (click)=\"onSave()\"\r\n >\r\n {{ saveBtnLabel }}\r\n </button>\r\n </ng-template>\r\n </div>\r\n <!-- loading -->\r\n <div class=\"dialog__loading\" [hidden]=\"!loading\">\r\n <img src=\"../../../assets/img/raise_loading.gif\" alt=\"\" />\r\n </div>\r\n</div>\r\n",
|
|
22805
|
+
styles: [":host::ng-deep .dialog{position:relative;max-height:90vh;font-weight:400;padding:20px;overflow:hidden;display:flex;flex-direction:column}:host::ng-deep .dialog.largest{width:80vw!important;max-width:1885px;padding:20px}:host::ng-deep .dialog.medium{width:500px;padding:20px}:host::ng-deep .dialog.small{width:350px;padding:20px 16px}:host::ng-deep .dialog.small .dialog__header{color:#002c4f;margin-bottom:16px}:host::ng-deep .dialog.small .dialog__header .header__title{font-size:13px;line-height:16px}:host::ng-deep .dialog.small .dialog__content{font-size:12px;line-height:16px}:host::ng-deep .dialog.small .dialog__footer{min-height:42px;padding:16px 0 0;font-size:12px;line-height:14px}:host::ng-deep .dialog.small .dialog__footer button{padding:6px 12px;min-width:60px}:host::ng-deep .dialog.large{width:800px;padding:20px}:host::ng-deep .dialog .dialog__header{width:100%;display:flex;justify-content:space-between;align-items:center;padding:0}:host::ng-deep .dialog .dialog__header::before{display:none}:host::ng-deep .dialog .dialog__header .header__title{color:#002c4f;font-family:Arial;font-size:15px;font-weight:700;line-height:18px;flex:1;overflow:hidden;display:flex;align-items:center;gap:8px}:host::ng-deep .dialog .dialog__header .header__actions{display:flex;align-items:center;gap:20px}:host::ng-deep .dialog .dialog__header .header__close-icon{display:block;width:100%;height:100%}:host::ng-deep .dialog .dialog__header .header__close-btn{cursor:pointer;flex:0 0 20px;padding:4px;width:20px;height:20px;display:flex;justify-content:center;align-items:center}:host::ng-deep .dialog .dialog__content{width:100%;min-height:38px;position:relative;overflow-y:auto;overflow-x:hidden;margin:0;padding:0;font-size:13px;line-height:19px;flex:1;height:0}:host::ng-deep .dialog .dialog__footer{position:relative;display:flex;align-items:center;justify-content:flex-end;padding:20px 0 0;font-size:13px;line-height:16px;margin-bottom:0}:host::ng-deep .dialog .dialog__footer button{border-radius:4px;padding:6px 16px;border:none;min-width:70px}:host::ng-deep .dialog .dialog__footer button+button{margin-left:12px}:host::ng-deep .dialog .dialog__footer .save-btn{background:#1364b3;border:1px solid #1364b3;font-weight:700;color:#fff}:host::ng-deep .dialog .dialog__footer .cancel-btn{border:1px solid #adb5bd;background:#fff}:host::ng-deep .dialog .dialog__loading{height:100%;background:0 0;position:fixed;top:0;left:0;right:0;bottom:0;z-index:9999}:host::ng-deep .dialog .dialog__loading img{position:absolute;left:50%;top:50%;width:40px;height:40px;transform:translate(-50%,-50%)}"]
|
|
22806
|
+
}] }
|
|
22807
|
+
];
|
|
22808
|
+
/** @nocollapse */
|
|
22809
|
+
CommonDialogComponent.ctorParameters = function () { return [
|
|
22810
|
+
{ type: MatDialogRef }
|
|
22811
|
+
]; };
|
|
22812
|
+
CommonDialogComponent.propDecorators = {
|
|
22813
|
+
hideHeader: [{ type: Input }],
|
|
22814
|
+
hideCloseIcon: [{ type: Input }],
|
|
22815
|
+
hideCloseBtn: [{ type: Input }],
|
|
22816
|
+
hideSaveBtn: [{ type: Input }],
|
|
22817
|
+
saveBtnLabel: [{ type: Input }],
|
|
22818
|
+
cancelBtnLabel: [{ type: Input }],
|
|
22819
|
+
showErrorIcon: [{ type: Input }],
|
|
22820
|
+
showZoomBtn: [{ type: Input }],
|
|
22821
|
+
onCloseRequest: [{ type: Input }],
|
|
22822
|
+
dialogStyle: [{ type: Input }],
|
|
22823
|
+
size: [{ type: Input }],
|
|
22824
|
+
title: [{ type: Input }],
|
|
22825
|
+
loading: [{ type: Input }],
|
|
22826
|
+
saveEmit: [{ type: Output }],
|
|
22827
|
+
closeEmit: [{ type: Output }],
|
|
22828
|
+
footerContent: [{ type: ContentChild, args: ["footerSlot", { static: false },] }]
|
|
22829
|
+
};
|
|
22830
|
+
return CommonDialogComponent;
|
|
22831
|
+
}());
|
|
22832
|
+
if (false) {
|
|
22833
|
+
/** @type {?} */
|
|
22834
|
+
CommonDialogComponent.prototype.translation;
|
|
22835
|
+
/** @type {?} */
|
|
22836
|
+
CommonDialogComponent.prototype.hideHeader;
|
|
22837
|
+
/** @type {?} */
|
|
22838
|
+
CommonDialogComponent.prototype.hideCloseIcon;
|
|
22839
|
+
/** @type {?} */
|
|
22840
|
+
CommonDialogComponent.prototype.hideCloseBtn;
|
|
22841
|
+
/** @type {?} */
|
|
22842
|
+
CommonDialogComponent.prototype.hideSaveBtn;
|
|
22843
|
+
/** @type {?} */
|
|
22844
|
+
CommonDialogComponent.prototype.saveBtnLabel;
|
|
22845
|
+
/** @type {?} */
|
|
22846
|
+
CommonDialogComponent.prototype.cancelBtnLabel;
|
|
22847
|
+
/** @type {?} */
|
|
22848
|
+
CommonDialogComponent.prototype.showErrorIcon;
|
|
22849
|
+
/** @type {?} */
|
|
22850
|
+
CommonDialogComponent.prototype.showZoomBtn;
|
|
22851
|
+
/** @type {?} */
|
|
22852
|
+
CommonDialogComponent.prototype.onCloseRequest;
|
|
22853
|
+
/** @type {?} */
|
|
22854
|
+
CommonDialogComponent.prototype.dialogStyle;
|
|
22855
|
+
/** @type {?} */
|
|
22856
|
+
CommonDialogComponent.prototype.size;
|
|
22857
|
+
/** @type {?} */
|
|
22858
|
+
CommonDialogComponent.prototype.title;
|
|
22859
|
+
/** @type {?} */
|
|
22860
|
+
CommonDialogComponent.prototype.loading;
|
|
22861
|
+
/** @type {?} */
|
|
22862
|
+
CommonDialogComponent.prototype.saveEmit;
|
|
22863
|
+
/** @type {?} */
|
|
22864
|
+
CommonDialogComponent.prototype.closeEmit;
|
|
22865
|
+
/** @type {?} */
|
|
22866
|
+
CommonDialogComponent.prototype.defaultSize;
|
|
22867
|
+
/** @type {?} */
|
|
22868
|
+
CommonDialogComponent.prototype.footerContent;
|
|
22869
|
+
/** @type {?} */
|
|
22870
|
+
CommonDialogComponent.prototype.customFooter;
|
|
22871
|
+
/** @type {?} */
|
|
22872
|
+
CommonDialogComponent.prototype.dialogRef;
|
|
22873
|
+
}
|
|
22874
|
+
|
|
22654
22875
|
/**
|
|
22655
22876
|
* @fileoverview added by tsickle
|
|
22656
22877
|
* Generated from: lib/service/icon-loader.service.ts
|
|
@@ -22878,155 +23099,6 @@ var KeepAliveService = /** @class */ (function () {
|
|
|
22878
23099
|
return KeepAliveService;
|
|
22879
23100
|
}());
|
|
22880
23101
|
|
|
22881
|
-
/**
|
|
22882
|
-
* @fileoverview added by tsickle
|
|
22883
|
-
* Generated from: lib/dialog/common-dialog/index.component.ts
|
|
22884
|
-
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
22885
|
-
*/
|
|
22886
|
-
var CommonDialogComponent = /** @class */ (function () {
|
|
22887
|
-
function CommonDialogComponent(dialogRef) {
|
|
22888
|
-
this.dialogRef = dialogRef;
|
|
22889
|
-
// 隐藏元素相关属性
|
|
22890
|
-
this.hideHeader = false;
|
|
22891
|
-
this.hideCloseIcon = false;
|
|
22892
|
-
this.hideCloseBtn = false;
|
|
22893
|
-
this.hideSaveBtn = false;
|
|
22894
|
-
this.saveBtnLabel = "";
|
|
22895
|
-
this.cancelBtnLabel = "";
|
|
22896
|
-
this.showErrorIcon = false;
|
|
22897
|
-
// 显示相关属性
|
|
22898
|
-
this.size = "";
|
|
22899
|
-
this.title = "Dialog";
|
|
22900
|
-
this.loading = false;
|
|
22901
|
-
this.saveEmit = new EventEmitter();
|
|
22902
|
-
this.closeEmit = new EventEmitter();
|
|
22903
|
-
this.customFooter = false;
|
|
22904
|
-
}
|
|
22905
|
-
/**
|
|
22906
|
-
* @return {?}
|
|
22907
|
-
*/
|
|
22908
|
-
CommonDialogComponent.prototype.ngAfterContentInit = /**
|
|
22909
|
-
* @return {?}
|
|
22910
|
-
*/
|
|
22911
|
-
function () {
|
|
22912
|
-
this.customFooter = !!this.footerContent;
|
|
22913
|
-
};
|
|
22914
|
-
/**
|
|
22915
|
-
* @return {?}
|
|
22916
|
-
*/
|
|
22917
|
-
CommonDialogComponent.prototype.ngOnInit = /**
|
|
22918
|
-
* @return {?}
|
|
22919
|
-
*/
|
|
22920
|
-
function () {
|
|
22921
|
-
this.getInfo();
|
|
22922
|
-
};
|
|
22923
|
-
/**
|
|
22924
|
-
* @param {?=} res
|
|
22925
|
-
* @return {?}
|
|
22926
|
-
*/
|
|
22927
|
-
CommonDialogComponent.prototype.onClose = /**
|
|
22928
|
-
* @param {?=} res
|
|
22929
|
-
* @return {?}
|
|
22930
|
-
*/
|
|
22931
|
-
function (res) {
|
|
22932
|
-
this.dialogRef.close(res);
|
|
22933
|
-
this.closeEmit.emit(res);
|
|
22934
|
-
};
|
|
22935
|
-
/**
|
|
22936
|
-
* @return {?}
|
|
22937
|
-
*/
|
|
22938
|
-
CommonDialogComponent.prototype.onSave = /**
|
|
22939
|
-
* @return {?}
|
|
22940
|
-
*/
|
|
22941
|
-
function () {
|
|
22942
|
-
var _this = this;
|
|
22943
|
-
// 这里把关闭事件emit上去,但是必须使用箭头函数保存this对象
|
|
22944
|
-
this.saveEmit.emit((/**
|
|
22945
|
-
* @param {?} res
|
|
22946
|
-
* @return {?}
|
|
22947
|
-
*/
|
|
22948
|
-
function (res) {
|
|
22949
|
-
_this.onClose(res);
|
|
22950
|
-
}));
|
|
22951
|
-
};
|
|
22952
|
-
/**
|
|
22953
|
-
* @private
|
|
22954
|
-
* @return {?}
|
|
22955
|
-
*/
|
|
22956
|
-
CommonDialogComponent.prototype.getInfo = /**
|
|
22957
|
-
* @private
|
|
22958
|
-
* @return {?}
|
|
22959
|
-
*/
|
|
22960
|
-
function () {
|
|
22961
|
-
this.translation = JSON.parse(localStorage.getItem("translation")) || {};
|
|
22962
|
-
this.saveBtnLabel =
|
|
22963
|
-
this.saveBtnLabel || this.translation.SAVE || ".SAVE";
|
|
22964
|
-
this.cancelBtnLabel =
|
|
22965
|
-
this.cancelBtnLabel || this.translation.CANCEL || ".CANCEL";
|
|
22966
|
-
};
|
|
22967
|
-
CommonDialogComponent.decorators = [
|
|
22968
|
-
{ type: Component, args: [{
|
|
22969
|
-
selector: "kt-common-dialog",
|
|
22970
|
-
template: "<div class=\"dialog\" [ngClass]=\"size\">\r\n\t<!-- \u5934\u90E8 -->\r\n\t<div *ngIf=\"!hideHeader\" mat-dialog-title class=\"dialog__header\">\r\n\t\t<div class=\"header__title\">\r\n\t\t\t<img\r\n\t\t\t\tsrc=\"../../../assets/img/notification-status-warning.svg\"\r\n\t\t\t\talt=\"\"\r\n\t\t\t\t*ngIf=\"showErrorIcon\"\r\n\t\t\t/>\r\n\t\t\t{{ title }}\r\n\t\t</div>\r\n\t\t<div\r\n\t\t\t*ngIf=\"!hideCloseIcon\"\r\n\t\t\tclass=\"header__close-btn\"\r\n\t\t\t(click)=\"onClose()\"\r\n\t\t>\r\n\t\t\t<img\r\n\t\t\t\tclass=\"header__close-icon\"\r\n\t\t\t\tsrc=\"../../../assets/img/close.svg\"\r\n\t\t\t/>\r\n\t\t</div>\r\n\t</div>\r\n\t<!-- \u5185\u5BB9 -->\r\n\t<div class=\"dialog__content\" mat-dialog-content>\r\n\t\t<ng-content></ng-content>\r\n\t</div>\r\n\t<!-- \u5E95\u90E8\u6309\u94AE -->\r\n\t<div mat-dialog-actions class=\"dialog__footer\">\r\n\t\t<ng-content select=\"[footerSlot]\"></ng-content>\r\n\t\t<!-- \u9ED8\u8BA4\u5C55\u793A\u4FDD\u5B58/\u5173\u95ED\u6309\u94AE -->\r\n\t\t<ng-container *ngIf=\"!customFooter\">\r\n\t\t\t<ng-template [ngTemplateOutlet]=\"defaultTemplate\"></ng-template>\r\n\t\t</ng-container>\r\n\t\t<ng-template #defaultTemplate>\r\n\t\t\t<button *ngIf=\"!hideCloseBtn\" class=\"e-btn\" [ngClass]=\"size\" mat-dialog-close>\r\n\t\t\t\t{{ cancelBtnLabel }}\r\n\t\t\t</button>\r\n\t\t\t<button *ngIf=\"!hideSaveBtn\" class=\"e-btn e-primary\" [ngClass]=\"size\" (click)=\"onSave()\">\r\n\t\t\t\t{{ saveBtnLabel }}\r\n\t\t\t</button>\r\n\t\t</ng-template>\r\n\t</div>\r\n\t<!-- loading -->\r\n\t<div class=\"dialog__loading\" [hidden]=\"!loading\">\r\n\t\t<img src=\"../../../assets/img/raise_loading.gif\" alt=\"\" />\r\n\t</div>\r\n</div>\r\n",
|
|
22971
|
-
styles: [":host::ng-deep .dialog{position:relative;max-height:90vh;font-weight:400;overflow:hidden}:host::ng-deep .dialog.medium{width:500px;padding:20px}:host::ng-deep .dialog.small{width:350px;padding:20px 16px}:host::ng-deep .dialog.small .dialog__header{color:#002c4f;margin-bottom:16px}:host::ng-deep .dialog.small .dialog__header .header__title{font-size:13px;line-height:16px}:host::ng-deep .dialog.small .dialog__content{font-size:12px;line-height:16px}:host::ng-deep .dialog.small .dialog__footer{min-height:42px;padding:16px 0 0;font-size:12px;line-height:14px}:host::ng-deep .dialog.small .dialog__footer button{padding:6px 12px;min-width:60px}:host::ng-deep .dialog.large{width:800px;padding:20px}:host::ng-deep .dialog .dialog__header{width:100%;display:flex;justify-content:space-between;align-items:center;padding:0}:host::ng-deep .dialog .dialog__header::before{display:none}:host::ng-deep .dialog .dialog__header .header__title{color:#002c4f;font-family:Arial;font-size:15px;font-weight:700;line-height:18px;flex:1;overflow:hidden;display:flex;align-items:center;gap:8px}:host::ng-deep .dialog .dialog__header .header__close-icon{display:block;width:100%;height:100%}:host::ng-deep .dialog .dialog__header .header__close-btn{cursor:pointer;flex:0 0 20px;padding:4px;width:20px;height:20px;display:flex;justify-content:center;align-items:center}:host::ng-deep .dialog .dialog__content{width:100%;min-height:38px;position:relative;overflow-y:auto;overflow-x:hidden;margin:0;padding:0;font-size:13px;line-height:19px}:host::ng-deep .dialog .dialog__footer{position:relative;display:flex;align-items:center;justify-content:flex-end;padding:20px 0 0;font-size:13px;line-height:16px;margin-bottom:0}:host::ng-deep .dialog .dialog__footer button{border-radius:4px;padding:6px 16px;border:none;min-width:70px}:host::ng-deep .dialog .dialog__footer button+button{margin-left:12px}:host::ng-deep .dialog .dialog__footer .save-btn{background:#1364b3;border:1px solid #1364b3;font-weight:700;color:#fff}:host::ng-deep .dialog .dialog__footer .cancel-btn{border:1px solid #adb5bd;background:#fff}:host::ng-deep .dialog .dialog__loading{height:100%;background:0 0;position:fixed;top:0;left:0;right:0;bottom:0;z-index:9999}:host::ng-deep .dialog .dialog__loading img{position:absolute;left:50%;top:50%;width:40px;height:40px;transform:translate(-50%,-50%)}"]
|
|
22972
|
-
}] }
|
|
22973
|
-
];
|
|
22974
|
-
/** @nocollapse */
|
|
22975
|
-
CommonDialogComponent.ctorParameters = function () { return [
|
|
22976
|
-
{ type: MatDialogRef }
|
|
22977
|
-
]; };
|
|
22978
|
-
CommonDialogComponent.propDecorators = {
|
|
22979
|
-
hideHeader: [{ type: Input }],
|
|
22980
|
-
hideCloseIcon: [{ type: Input }],
|
|
22981
|
-
hideCloseBtn: [{ type: Input }],
|
|
22982
|
-
hideSaveBtn: [{ type: Input }],
|
|
22983
|
-
saveBtnLabel: [{ type: Input }],
|
|
22984
|
-
cancelBtnLabel: [{ type: Input }],
|
|
22985
|
-
showErrorIcon: [{ type: Input }],
|
|
22986
|
-
size: [{ type: Input }],
|
|
22987
|
-
title: [{ type: Input }],
|
|
22988
|
-
loading: [{ type: Input }],
|
|
22989
|
-
saveEmit: [{ type: Output }],
|
|
22990
|
-
closeEmit: [{ type: Output }],
|
|
22991
|
-
footerContent: [{ type: ContentChild, args: ["footerSlot", { static: false },] }]
|
|
22992
|
-
};
|
|
22993
|
-
return CommonDialogComponent;
|
|
22994
|
-
}());
|
|
22995
|
-
if (false) {
|
|
22996
|
-
/** @type {?} */
|
|
22997
|
-
CommonDialogComponent.prototype.translation;
|
|
22998
|
-
/** @type {?} */
|
|
22999
|
-
CommonDialogComponent.prototype.hideHeader;
|
|
23000
|
-
/** @type {?} */
|
|
23001
|
-
CommonDialogComponent.prototype.hideCloseIcon;
|
|
23002
|
-
/** @type {?} */
|
|
23003
|
-
CommonDialogComponent.prototype.hideCloseBtn;
|
|
23004
|
-
/** @type {?} */
|
|
23005
|
-
CommonDialogComponent.prototype.hideSaveBtn;
|
|
23006
|
-
/** @type {?} */
|
|
23007
|
-
CommonDialogComponent.prototype.saveBtnLabel;
|
|
23008
|
-
/** @type {?} */
|
|
23009
|
-
CommonDialogComponent.prototype.cancelBtnLabel;
|
|
23010
|
-
/** @type {?} */
|
|
23011
|
-
CommonDialogComponent.prototype.showErrorIcon;
|
|
23012
|
-
/** @type {?} */
|
|
23013
|
-
CommonDialogComponent.prototype.size;
|
|
23014
|
-
/** @type {?} */
|
|
23015
|
-
CommonDialogComponent.prototype.title;
|
|
23016
|
-
/** @type {?} */
|
|
23017
|
-
CommonDialogComponent.prototype.loading;
|
|
23018
|
-
/** @type {?} */
|
|
23019
|
-
CommonDialogComponent.prototype.saveEmit;
|
|
23020
|
-
/** @type {?} */
|
|
23021
|
-
CommonDialogComponent.prototype.closeEmit;
|
|
23022
|
-
/** @type {?} */
|
|
23023
|
-
CommonDialogComponent.prototype.footerContent;
|
|
23024
|
-
/** @type {?} */
|
|
23025
|
-
CommonDialogComponent.prototype.customFooter;
|
|
23026
|
-
/** @type {?} */
|
|
23027
|
-
CommonDialogComponent.prototype.dialogRef;
|
|
23028
|
-
}
|
|
23029
|
-
|
|
23030
23102
|
/**
|
|
23031
23103
|
* @fileoverview added by tsickle
|
|
23032
23104
|
* Generated from: lib/raise-common-lib.module.ts
|
|
@@ -23064,7 +23136,7 @@ var RaiseCommonLibModule = /** @class */ (function () {
|
|
|
23064
23136
|
RsCommentaryComponent,
|
|
23065
23137
|
RSNavCardGroupComponent,
|
|
23066
23138
|
RSToolbarComponent,
|
|
23067
|
-
TruncatedTextToggleComponent
|
|
23139
|
+
TruncatedTextToggleComponent,
|
|
23068
23140
|
],
|
|
23069
23141
|
imports: [
|
|
23070
23142
|
CommonModule,
|
|
@@ -23221,7 +23293,8 @@ var RaiseCommonLibModule = /** @class */ (function () {
|
|
|
23221
23293
|
RsCommentaryComponent,
|
|
23222
23294
|
RSNavCardGroupComponent,
|
|
23223
23295
|
RSToolbarComponent,
|
|
23224
|
-
TruncatedTextToggleComponent
|
|
23296
|
+
TruncatedTextToggleComponent,
|
|
23297
|
+
CommonDialogComponent,
|
|
23225
23298
|
],
|
|
23226
23299
|
entryComponents: [
|
|
23227
23300
|
NewActionNotificationComponent,
|
|
@@ -23246,5 +23319,5 @@ var RaiseCommonLibModule = /** @class */ (function () {
|
|
|
23246
23319
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
23247
23320
|
*/
|
|
23248
23321
|
|
|
23249
|
-
export { CheckboxGroupComponent, CommonFunctionService, CommonGridComponent, DefaultDrawerConfig, DialogService, DrawerComponent, DrawerFormComponent, DrawerService, EmailPattern, EncryptedInputComponent, FloatBoxComponent, GridActionComponent, GridActionItemComponent, GridBoxComponent, IconLoaderService, KeepAliveService, MainContainerComponent, MessageType, MultiTabComponent, RSAsideComponent, RSFooterComponent, RSHeaderComponent, RSNavCardGroupComponent, RSToolbarComponent, RadioGroupComponent, RaiseCommonLibModule, RsCommentaryComponent, RsPageListComponent, RsPageTabComponent, SwitchInputComponent, TagInputComponent, ToolbarItemComponent, TranslationService, TruncatedTextToggleComponent, filterShowSection, Debounce as ɵa, NewActionNotificationComponent as ɵb,
|
|
23322
|
+
export { CheckboxGroupComponent, CommonDialogComponent, CommonFunctionService, CommonGridComponent, DefaultDrawerConfig, DialogService, DrawerComponent, DrawerFormComponent, DrawerService, EmailPattern, EncryptedInputComponent, FloatBoxComponent, GridActionComponent, GridActionItemComponent, GridBoxComponent, IconLoaderService, KeepAliveService, MainContainerComponent, MessageType, MultiTabComponent, RSAsideComponent, RSFooterComponent, RSHeaderComponent, RSNavCardGroupComponent, RSToolbarComponent, RadioGroupComponent, RaiseCommonLibModule, RsCommentaryComponent, RsPageListComponent, RsPageTabComponent, SwitchInputComponent, TagInputComponent, ToolbarItemComponent, TranslationService, TruncatedTextToggleComponent, filterShowSection, Debounce as ɵa, NewActionNotificationComponent as ɵb, CommonDeleteComponent as ɵc };
|
|
23250
23323
|
//# sourceMappingURL=raise-common-lib.js.map
|