raise-common-lib 0.0.134 → 0.0.136
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 +129 -25
- 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/commentary/constants.js +10 -10
- package/esm2015/lib/commentary/index.component.js +36 -20
- package/esm2015/lib/common-grid/index.component.js +6 -2
- package/esm2015/lib/raise-common-lib.module.js +9 -5
- package/esm2015/lib/truncated-text-toggle/index.component.js +67 -0
- package/esm2015/public-api.js +2 -1
- package/esm2015/raise-common-lib.js +2 -2
- package/esm5/lib/commentary/constants.js +10 -10
- package/esm5/lib/commentary/index.component.js +43 -23
- package/esm5/lib/common-grid/index.component.js +6 -2
- package/esm5/lib/raise-common-lib.module.js +9 -5
- package/esm5/lib/truncated-text-toggle/index.component.js +78 -0
- package/esm5/public-api.js +2 -1
- package/esm5/raise-common-lib.js +2 -2
- package/fesm2015/raise-common-lib.js +113 -24
- package/fesm2015/raise-common-lib.js.map +1 -1
- package/fesm5/raise-common-lib.js +130 -27
- package/fesm5/raise-common-lib.js.map +1 -1
- package/lib/commentary/constants.d.ts +9 -9
- package/lib/commentary/index.component.d.ts +7 -0
- package/lib/common-grid/index.component.d.ts +1 -0
- package/lib/truncated-text-toggle/index.component.d.ts +12 -0
- package/package.json +1 -1
- package/public-api.d.ts +1 -0
- package/raise-common-lib.metadata.json +1 -1
- package/src/assets/img/click_show_more_icon.svg +3 -0
- package/src/assets/img/comment-cancel.svg +4 -4
- package/src/assets/img/comment-check.svg +5 -5
- package/src/assets/img/drawer-back.svg +4 -4
- package/src/assets/img/eye-close.svg +4 -4
- package/src/assets/img/eye-open.svg +4 -4
- package/src/assets/img/toolbar-action-add.svg +4 -4
- package/src/assets/img/toolbar-action-delete.svg +14 -14
- package/src/assets/img/toolbar-action-download.svg +5 -5
- package/src/assets/img/toolbar-action-duplicate.svg +6 -6
- package/src/assets/img/toolbar-action-export.svg +5 -5
- package/src/assets/img/toolbar-action-import.svg +5 -5
- package/src/assets/img/toolbar-action-refresh.svg +14 -14
- package/src/assets/img/toolbar-action-upload.svg +5 -5
- package/src/assets/style/reset/grid.scss +3 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { EventEmitter, Component, ChangeDetectorRef, ViewChild, Input, Output, HostBinding, Injectable, ɵɵdefineInjectable, Inject, ɵɵinject, ContentChild, HostListener, ComponentFactoryResolver, ViewContainerRef, ViewChildren, ElementRef, NgModule, CUSTOM_ELEMENTS_SCHEMA } from '@angular/core';
|
|
2
|
-
import { GridComponent, GridModule, PagerModule, GridAllModule, PageService, SortService, FilterService, ExcelExportService, EditService, ResizeService, ToolbarService, ColumnChooserService, AggregateService, ColumnMenuService, DetailRowService, SelectionService, GroupService } from '@syncfusion/ej2-angular-grids';
|
|
2
|
+
import { GridComponent, GridModule, PagerModule, GridAllModule, PageService, RowDDService, SortService, FilterService, ExcelExportService, EditService, ResizeService, ToolbarService, ColumnChooserService, AggregateService, ColumnMenuService, DetailRowService, SelectionService, GroupService } from '@syncfusion/ej2-angular-grids';
|
|
3
3
|
import { times, debounce } from 'lodash';
|
|
4
4
|
import { __awaiter, __decorate, __metadata } from 'tslib';
|
|
5
5
|
import { Subject, BehaviorSubject } from 'rxjs';
|
|
@@ -58,6 +58,7 @@ class CommonGridComponent {
|
|
|
58
58
|
this.fields = [];
|
|
59
59
|
this.dataSource = [];
|
|
60
60
|
this.allowPaging = true;
|
|
61
|
+
this.allowRowDragAndDrop = false;
|
|
61
62
|
this.clipMode = "EllipsisWithTooltip";
|
|
62
63
|
this.checkBoxWidth = 32; // col 数量过少的时候,check宽度会拉伸,这时候设置null
|
|
63
64
|
/**
|
|
@@ -612,7 +613,7 @@ class CommonGridComponent {
|
|
|
612
613
|
CommonGridComponent.decorators = [
|
|
613
614
|
{ type: Component, args: [{
|
|
614
615
|
selector: "rs-common-grid",
|
|
615
|
-
template: "<ejs-grid\r\n
|
|
616
|
+
template: "<ejs-grid\r\n #grid\r\n [id]=\"gridId\"\r\n [ngClass]=\"{\r\n 'hide-Check-box': !alwaysShowCheckbox,\r\n 'grid-loading': className === 'grid-loading'\r\n }\"\r\n [dataSource]=\"dataSource\"\r\n [allowPaging]=\"allowPaging && pageSettings\"\r\n [allowResizing]=\"true\"\r\n [pageSettings]=\"pageSettings\"\r\n [showColumnMenu]=\"true\"\r\n [allowSorting]=\"true\"\r\n [allowFiltering]=\"true\"\r\n [allowExcelExport]=\"true\"\r\n [allowRowDragAndDrop]=\"allowRowDragAndDrop\"\r\n [filterSettings]=\"filterSettings\"\r\n [resizeSettings]=\"resizeSettings\"\r\n [allowSelection]=\"true\"\r\n [editSettings]=\"editSettings\"\r\n [childGrid]=\"childGrid\"\r\n [contextMenuItems]=\"dataSource && dataSource.length ? contextMenuItems : null\"\r\n [selectionSettings]=\"selectionSettings\"\r\n (recordClick)=\"_recordClick($event)\"\r\n (recordDoubleClick)=\"_recordDoubleClick($event)\"\r\n (actionBegin)=\"_actionBegin($event)\"\r\n (actionComplete)=\"_actionHandler($event)\"\r\n (rowSelected)=\"_rowSelected($event)\"\r\n (rowDeselected)=\"_rowDeselected($event)\"\r\n style=\"border: none\"\r\n (contextMenuClick)=\"_onContextMenu($event)\"\r\n (contextMenuOpen)=\"contextMenuOpen($event)\"\r\n (queryCellInfo)=\"customiseCell($event)\"\r\n (dataBound)=\"_dataBound($event)\"\r\n (rowDataBound)=\"_rowDataBound($event)\"\r\n (rowSelecting)=\"_rowSelecting($event)\"\r\n (excelQueryCellInfo)=\"_exportQueryCellInfo($event)\"\r\n (load)=\"_load()\"\r\n [frozenColumns]=\"frozenColumns\"\r\n [columnChooserSettings]=\"columnChooserSettings\"\r\n>\r\n <e-columns>\r\n <e-column\r\n *ngIf=\"showCheckBox\"\r\n type=\"checkbox\"\r\n [width]=\"checkBoxWidth\"\r\n [showColumnMenu]=\"false\"\r\n [allowResizing]=\"false\"\r\n ></e-column>\r\n <e-column\r\n *ngFor=\"let item of fields; trackBy: trackByFn; let last = last\"\r\n [field]=\"item.columnName\"\r\n [filter]=\"item.filter ? item.filter : { type: 'CheckBox' }\"\r\n [customAttributes]=\"\r\n item.colName === 'entityUserList' || item.colName === 'kycProgress'\r\n ? { class: 'hideColumnFilterClass' }\r\n : {}\r\n \"\r\n [headerText]=\"item.columnDisplayName\"\r\n [textAlign]=\"item.textAlign\"\r\n [showColumnMenu]=\"item.showColumnMenu === undefined ? true : false\"\r\n [allowFiltering]=\"item.allowFiltering === undefined ? true : false\"\r\n [allowSorting]=\"item.allowSorting === undefined ? true : false\"\r\n [editType]=\"item.editType\"\r\n [validationRules]=\"item.validationRules\"\r\n [type]=\"item.dataType || 'string'\"\r\n [width]=\"item.width\"\r\n [minWidth]=\"item.minWidth\"\r\n [format]=\"item.format\"\r\n [visible]=\"item.visible\"\r\n [template]=\"item.showTemplate ? columnTemplate : undefined\"\r\n [clipMode]=\"\r\n item.clipMode ? item.clipMode : clipMode || 'EllipsisWithTooltip'\r\n \"\r\n [sortComparer]=\"item.dateComparer\"\r\n [allowResizing]=\"!last\"\r\n >\r\n </e-column>\r\n </e-columns>\r\n</ejs-grid>\r\n",
|
|
616
617
|
styles: [""]
|
|
617
618
|
}] }
|
|
618
619
|
];
|
|
@@ -638,6 +639,7 @@ CommonGridComponent.propDecorators = {
|
|
|
638
639
|
columnTemplate: [{ type: Input }],
|
|
639
640
|
pageSettings: [{ type: Input }],
|
|
640
641
|
allowPaging: [{ type: Input }],
|
|
642
|
+
allowRowDragAndDrop: [{ type: Input }],
|
|
641
643
|
clipMode: [{ type: Input }],
|
|
642
644
|
checkBoxWidth: [{ type: Input }],
|
|
643
645
|
childGrid: [{ type: Input }],
|
|
@@ -698,6 +700,8 @@ if (false) {
|
|
|
698
700
|
/** @type {?} */
|
|
699
701
|
CommonGridComponent.prototype.allowPaging;
|
|
700
702
|
/** @type {?} */
|
|
703
|
+
CommonGridComponent.prototype.allowRowDragAndDrop;
|
|
704
|
+
/** @type {?} */
|
|
701
705
|
CommonGridComponent.prototype.clipMode;
|
|
702
706
|
/** @type {?} */
|
|
703
707
|
CommonGridComponent.prototype.checkBoxWidth;
|
|
@@ -1794,6 +1798,13 @@ class RsCommentaryComponent {
|
|
|
1794
1798
|
this.deletePermission = true; // delete权限
|
|
1795
1799
|
// delete权限
|
|
1796
1800
|
this.isReadOnly = false;
|
|
1801
|
+
this.filedsKey = {
|
|
1802
|
+
commentaries: "commentaries",
|
|
1803
|
+
messageId: "messageId",
|
|
1804
|
+
ownerName: "ownerName",
|
|
1805
|
+
lastModifiedOn: "lastModifiedOn",
|
|
1806
|
+
messageBody: "messageBody",
|
|
1807
|
+
};
|
|
1797
1808
|
this.actionComplete = new EventEmitter();
|
|
1798
1809
|
this.commentVal = "";
|
|
1799
1810
|
this.replyVal = "";
|
|
@@ -1825,11 +1836,11 @@ class RsCommentaryComponent {
|
|
|
1825
1836
|
*/
|
|
1826
1837
|
(res) => {
|
|
1827
1838
|
this.commentData.unshift({
|
|
1828
|
-
messageId: res.messageId,
|
|
1829
|
-
commentaries: [],
|
|
1830
|
-
ownerName: this.displayName,
|
|
1831
|
-
lastModifiedOn: Date.now(),
|
|
1832
|
-
messageBody: this.commentVal,
|
|
1839
|
+
[`${this.filedsKey["messageId"]}`]: res.messageId,
|
|
1840
|
+
[`${this.filedsKey["commentaries"]}`]: [],
|
|
1841
|
+
[`${this.filedsKey["ownerName"]}`]: this.displayName,
|
|
1842
|
+
[`${this.filedsKey["lastModifiedOn"]}`]: Date.now(),
|
|
1843
|
+
[`${this.filedsKey["messageBody"]}`]: this.commentVal,
|
|
1833
1844
|
});
|
|
1834
1845
|
this.commentVal = "";
|
|
1835
1846
|
}),
|
|
@@ -1840,7 +1851,7 @@ class RsCommentaryComponent {
|
|
|
1840
1851
|
* @return {?}
|
|
1841
1852
|
*/
|
|
1842
1853
|
editComment(item) {
|
|
1843
|
-
this.editCommentVal = item.messageBody;
|
|
1854
|
+
this.editCommentVal = item[this.filedsKey["messageBody"]];
|
|
1844
1855
|
item.showCommentEdit = true;
|
|
1845
1856
|
}
|
|
1846
1857
|
/**
|
|
@@ -1857,7 +1868,7 @@ class RsCommentaryComponent {
|
|
|
1857
1868
|
* @return {?}
|
|
1858
1869
|
*/
|
|
1859
1870
|
(res) => {
|
|
1860
|
-
item.messageBody = this.editCommentVal;
|
|
1871
|
+
item[this.filedsKey["messageBody"]] = this.editCommentVal;
|
|
1861
1872
|
item.showCommentEdit = false;
|
|
1862
1873
|
this.ref.markForCheck();
|
|
1863
1874
|
}),
|
|
@@ -1888,7 +1899,7 @@ class RsCommentaryComponent {
|
|
|
1888
1899
|
* @param {?} ele
|
|
1889
1900
|
* @return {?}
|
|
1890
1901
|
*/
|
|
1891
|
-
(ele) => ele.messageId === item.messageId));
|
|
1902
|
+
(ele) => ele[this.filedsKey.messageId] === item[this.filedsKey.messageId]));
|
|
1892
1903
|
this.actionComplete.emit({
|
|
1893
1904
|
action: "deleteComment",
|
|
1894
1905
|
data: item,
|
|
@@ -1917,12 +1928,12 @@ class RsCommentaryComponent {
|
|
|
1917
1928
|
* @return {?}
|
|
1918
1929
|
*/
|
|
1919
1930
|
(res) => {
|
|
1920
|
-
item.commentaries.unshift({
|
|
1921
|
-
messageId: res.messageId,
|
|
1922
|
-
commentaries: [],
|
|
1923
|
-
ownerName: this.displayName,
|
|
1924
|
-
lastModifiedOn: Date.now(),
|
|
1925
|
-
messageBody: this.replyVal,
|
|
1931
|
+
item[this.filedsKey["commentaries"]].unshift({
|
|
1932
|
+
[`${this.filedsKey["messageId"]}`]: res[this.filedsKey["messageId"]],
|
|
1933
|
+
[`${this.filedsKey["commentaries"]}`]: [],
|
|
1934
|
+
[`${this.filedsKey["ownerName"]}`]: this.displayName,
|
|
1935
|
+
[`${this.filedsKey["lastModifiedOn"]}`]: Date.now(),
|
|
1936
|
+
[`${this.filedsKey["messageBody"]}`]: this.replyVal,
|
|
1926
1937
|
});
|
|
1927
1938
|
this.replyVal = "";
|
|
1928
1939
|
item.showReplyInput = false;
|
|
@@ -1938,15 +1949,21 @@ class RsCommentaryComponent {
|
|
|
1938
1949
|
adjustTextareaHeight(e) {
|
|
1939
1950
|
/** @type {?} */
|
|
1940
1951
|
const textarea = e.target;
|
|
1941
|
-
|
|
1942
|
-
|
|
1952
|
+
if (e.type === "focus" && textarea.value) {
|
|
1953
|
+
textarea.style.height = "auto";
|
|
1954
|
+
textarea.style.height = textarea.scrollHeight + "px";
|
|
1955
|
+
}
|
|
1956
|
+
else if (e.type === "input") {
|
|
1957
|
+
textarea.style.height = "auto";
|
|
1958
|
+
textarea.style.height = textarea.scrollHeight + "px";
|
|
1959
|
+
}
|
|
1943
1960
|
}
|
|
1944
1961
|
}
|
|
1945
1962
|
RsCommentaryComponent.decorators = [
|
|
1946
1963
|
{ type: Component, args: [{
|
|
1947
1964
|
selector: "rs-commentary",
|
|
1948
|
-
template: "<div class=\"rs-commentary-wrap\">\r\n <ng-container\r\n [ngTemplateOutlet]=\"commentBoxTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'comment' }\"\r\n ></ng-container>\r\n <div class=\"reply-box\">\r\n <div *ngFor=\"let item of commentData\">\r\n <ng-container\r\n [ngTemplateOutlet]=\"replyItemTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'comment', item: item }\"\r\n ></ng-container>\r\n <div class=\"sub-reply-list\">\r\n <ng-container\r\n *ngFor=\"\r\n let sub of item.isExpanded\r\n ? item.commentaries\r\n : item.commentaries.slice(0, 3)\r\n \"\r\n [ngTemplateOutlet]=\"replyItemTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'sub', item: sub }\"\r\n ></ng-container>\r\n </div>\r\n <button\r\n class=\"e-btn text\"\r\n *ngIf=\"item.commentaries.length > 3\"\r\n (click)=\"item.isExpanded = !item.isExpanded\"\r\n style=\"margin-bottom: 8px
|
|
1949
|
-
styles: [".rs-commentary-wrap{width:100%;height:100%;padding:32px;display:flex;flex-direction:column}.rs-commentary-wrap .comment-box{width:100%}.rs-commentary-wrap .comment-box .comment-input-wrap{margin-bottom:12px;display:flex;gap:12px}.rs-commentary-wrap .comment-box .comment-input-wrap .e-input{flex:1;width:0;height:
|
|
1965
|
+
template: "<div class=\"rs-commentary-wrap\">\r\n <ng-container\r\n [ngTemplateOutlet]=\"commentBoxTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'comment' }\"\r\n ></ng-container>\r\n <div class=\"reply-box\">\r\n <div *ngFor=\"let item of commentData\">\r\n <ng-container\r\n [ngTemplateOutlet]=\"replyItemTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'comment', item: item }\"\r\n ></ng-container>\r\n <div class=\"sub-reply-list\">\r\n <ng-container\r\n *ngFor=\"\r\n let sub of item.isExpanded\r\n ? item[filedsKey.commentaries]\r\n : item[filedsKey.commentaries].slice(0, 3)\r\n \"\r\n [ngTemplateOutlet]=\"replyItemTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'sub', item: sub }\"\r\n ></ng-container>\r\n </div>\r\n <button\r\n class=\"e-btn text\"\r\n *ngIf=\"item[filedsKey.commentaries].length > 3\"\r\n (click)=\"item.isExpanded = !item.isExpanded\"\r\n style=\"margin-bottom: 8px\"\r\n >\r\n {{\r\n item.isExpanded\r\n ? \"Collapse\"\r\n : \"View All \" + item[filedsKey.commentaries].length + \" Replies\"\r\n }}\r\n <img\r\n class=\"arrow\"\r\n [ngClass]=\"{ collapse: item.isExpanded }\"\r\n src=\"../../assets/img/dropdown-arrow.svg\"\r\n alt=\"\"\r\n />\r\n </button>\r\n </div>\r\n </div>\r\n</div>\r\n\r\n<ng-template #commentBoxTemplate let-type=\"type\" let-item=\"item\">\r\n <div class=\"comment-box\">\r\n <div class=\"comment-input-wrap\">\r\n <div class=\"avatar\" *ngIf=\"type !== 'editComment'\">\r\n {{ cf.rtn(displayName) }}\r\n </div>\r\n <textarea\r\n *ngIf=\"type === 'comment'\"\r\n class=\"e-input\"\r\n rows=\"3\"\r\n [(ngModel)]=\"commentVal\"\r\n (input)=\"adjustTextareaHeight($event)\"\r\n (focus)=\"adjustTextareaHeight($event)\"\r\n [disabled]=\"isReadOnly || !editPermission\"\r\n placeholder=\"Write your comment...\"\r\n ></textarea>\r\n <textarea\r\n *ngIf=\"type === 'reply'\"\r\n class=\"e-input\"\r\n rows=\"3\"\r\n [(ngModel)]=\"replyVal\"\r\n (input)=\"adjustTextareaHeight($event)\"\r\n (focus)=\"adjustTextareaHeight($event)\"\r\n placeholder=\"Write your comment...\"\r\n ></textarea>\r\n <textarea\r\n *ngIf=\"type === 'editComment'\"\r\n class=\"e-input\"\r\n rows=\"3\"\r\n [(ngModel)]=\"editCommentVal\"\r\n (input)=\"adjustTextareaHeight($event)\"\r\n (focus)=\"adjustTextareaHeight($event)\"\r\n placeholder=\"Write your comment...\"\r\n ></textarea>\r\n </div>\r\n <div class=\"btn-wrap\">\r\n <button\r\n *ngIf=\"type === 'comment'\"\r\n class=\"e-btn e-primary small\"\r\n [disabled]=\"commentVal === '' || isReadOnly || !editPermission\"\r\n (click)=\"addComment()\"\r\n >\r\n {{ translation.COMMENT || \".COMMENT\" }}\r\n </button>\r\n <ng-container *ngIf=\"type === 'reply'\">\r\n <button\r\n class=\"e-btn small\"\r\n (click)=\"item.showReplyInput = false; replyVal = ''\"\r\n >\r\n {{ translation.CANCEL || \".CANCEL\" }}\r\n </button>\r\n <button\r\n class=\"e-btn e-primary small\"\r\n [disabled]=\"replyVal === ''\"\r\n (click)=\"addReply(item)\"\r\n >\r\n {{ translation.REPLY || \".REPLY\" }}\r\n </button>\r\n </ng-container>\r\n <ng-container *ngIf=\"type === 'editComment'\">\r\n <button class=\"e-btn text\" (click)=\"item.showCommentEdit = false\">\r\n <img src=\"../../assets/img/comment-cancel.svg\" alt=\"\" />\r\n </button>\r\n <button\r\n class=\"e-btn text\"\r\n [disabled]=\"editCommentVal === ''\"\r\n (click)=\"updateComment(item)\"\r\n >\r\n <img src=\"../../assets/img/comment-check.svg\" alt=\"\" />\r\n </button>\r\n </ng-container>\r\n </div>\r\n </div>\r\n</ng-template>\r\n<ng-template #replyItemTemplate let-type=\"type\" let-item=\"item\">\r\n <div class=\"reply-item\" [ngClass]=\"{ comment: type === 'comment' }\">\r\n <div class=\"avatar\">\r\n {{ cf.rtn(item[filedsKey.ownerName]) }}\r\n </div>\r\n <div class=\"owner-wrap\">\r\n <div class=\"owner-info\">\r\n <div class=\"name\">\r\n {{ item[filedsKey.ownerName] }}\r\n </div>\r\n <div class=\"time\">\r\n {{ item[filedsKey.lastModifiedOn] | date : dateTimePipeFormat }}\r\n </div>\r\n </div>\r\n <div class=\"message-wrap\">\r\n <div class=\"message\" *ngIf=\"!item.showCommentEdit\">\r\n <!-- {{ item[filedsKey.messageBody] }} -->\r\n <truncated-text-toggle\r\n [maximum]=\"1050\"\r\n [data]=\"item[filedsKey.messageBody]\"\r\n >\r\n </truncated-text-toggle>\r\n </div>\r\n <ng-container\r\n *ngIf=\"item.showCommentEdit\"\r\n [ngTemplateOutlet]=\"commentBoxTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'editComment', item: item }\"\r\n ></ng-container>\r\n </div>\r\n\r\n <button\r\n *ngIf=\"\r\n type === 'comment' && !item.showReplyInput && !item.showCommentEdit\r\n \"\r\n class=\"e-btn text\"\r\n (click)=\"item.showReplyInput = true\"\r\n [disabled]=\"isReadOnly || !editPermission\"\r\n >\r\n {{ translation.REPLY || \".REPLY\" }}\r\n </button>\r\n <ng-container\r\n *ngIf=\"item.showReplyInput\"\r\n [ngTemplateOutlet]=\"commentBoxTemplate\"\r\n [ngTemplateOutletContext]=\"{ type: 'reply', item: item }\"\r\n ></ng-container>\r\n\r\n <rs-grid-action *ngIf=\"type === 'comment'\">\r\n <rs-grid-action-item\r\n image=\"Edit\"\r\n [text]=\"translation.EDIT\"\r\n [disabled]=\"isReadOnly || !editPermission\"\r\n (click)=\"editComment(item)\"\r\n ></rs-grid-action-item>\r\n <rs-grid-action-item\r\n image=\"Delete\"\r\n [text]=\"translation.DELETE\"\r\n [disabled]=\"isReadOnly || !deletePermission\"\r\n (click)=\"deleteComment(item)\"\r\n ></rs-grid-action-item>\r\n </rs-grid-action>\r\n </div>\r\n </div>\r\n</ng-template>\r\n",
|
|
1966
|
+
styles: [".rs-commentary-wrap{width:100%;height:100%;padding:32px;display:flex;flex-direction:column}.rs-commentary-wrap .comment-box{width:100%}.rs-commentary-wrap .comment-box .comment-input-wrap{margin-bottom:12px;display:flex;gap:12px}.rs-commentary-wrap .comment-box .comment-input-wrap .e-input{flex:1;width:0;height:62px}.rs-commentary-wrap .comment-box .btn-wrap{display:flex;justify-content:flex-end;gap:12px}.rs-commentary-wrap .comment-box .btn-wrap .e-btn.text{padding:4px}.rs-commentary-wrap .reply-box{height:0;flex:1;overflow:auto;margin-top:16px;margin-right:-32px;padding-right:32px}.rs-commentary-wrap .reply-box .sub-reply-list{padding-left:40px}.rs-commentary-wrap .reply-box .e-btn.text{padding:0!important;min-width:auto;height:auto;color:#6c7c90!important}.rs-commentary-wrap .reply-box .e-btn.text:hover{background:0 0!important;color:#1364b3!important}.rs-commentary-wrap .reply-box .e-btn.text:focus{background:0 0!important;color:#6c7c90!important}.rs-commentary-wrap .reply-box .arrow.collapse{transform:rotate(180deg)}.rs-commentary-wrap .reply-box .reply-item{display:flex;gap:12px;padding:12px 0}.rs-commentary-wrap .reply-box .reply-item.comment{border-top:1px solid #eaedf0}.rs-commentary-wrap .reply-box .reply-item.comment:hover{background-color:#f6faff}.rs-commentary-wrap .reply-box .reply-item.comment:hover rs-grid-action{display:block}.rs-commentary-wrap .reply-box .reply-item rs-grid-action{display:none;position:absolute;cursor:pointer;top:-4px;right:8px}.rs-commentary-wrap .reply-box .owner-wrap{flex:1;width:0;position:relative}.rs-commentary-wrap .reply-box .owner-wrap .owner-info{display:flex;align-items:center;gap:8px;height:28px}.rs-commentary-wrap .reply-box .owner-wrap .owner-info .name{color:#44566c;font-family:Arial;font-size:12px;font-style:normal;font-weight:700;line-height:14px}.rs-commentary-wrap .reply-box .owner-wrap .owner-info .time{color:#6c7c90;font-family:Arial;font-size:10px;font-style:normal;font-weight:400;line-height:12px}.rs-commentary-wrap .reply-box .owner-wrap .message-wrap{padding:12px 0}.rs-commentary-wrap .reply-box .owner-wrap .message-wrap .message{color:#44566c;font-family:Arial;font-size:12px;font-style:normal;font-weight:400;line-height:16px;padding-right:8px;white-space:pre-wrap}.rs-commentary-wrap .avatar{width:32px;height:32px;border-radius:100%;border:1px solid rgba(108,124,144,.4);color:#44566c;display:flex;align-items:center;justify-content:center;font-family:Arial;font-size:12px;font-style:normal;font-weight:400;line-height:14px}"]
|
|
1950
1967
|
}] }
|
|
1951
1968
|
];
|
|
1952
1969
|
/** @nocollapse */
|
|
@@ -1961,6 +1978,7 @@ RsCommentaryComponent.propDecorators = {
|
|
|
1961
1978
|
editPermission: [{ type: Input }],
|
|
1962
1979
|
deletePermission: [{ type: Input }],
|
|
1963
1980
|
isReadOnly: [{ type: Input }],
|
|
1981
|
+
filedsKey: [{ type: Input }],
|
|
1964
1982
|
actionComplete: [{ type: Output }]
|
|
1965
1983
|
};
|
|
1966
1984
|
__decorate([
|
|
@@ -1982,7 +2000,7 @@ __decorate([
|
|
|
1982
2000
|
__metadata("design:returntype", void 0)
|
|
1983
2001
|
], RsCommentaryComponent.prototype, "addReply", null);
|
|
1984
2002
|
__decorate([
|
|
1985
|
-
Debounce(
|
|
2003
|
+
Debounce(100),
|
|
1986
2004
|
__metadata("design:type", Function),
|
|
1987
2005
|
__metadata("design:paramtypes", [Object]),
|
|
1988
2006
|
__metadata("design:returntype", void 0)
|
|
@@ -1999,6 +2017,8 @@ if (false) {
|
|
|
1999
2017
|
/** @type {?} */
|
|
2000
2018
|
RsCommentaryComponent.prototype.isReadOnly;
|
|
2001
2019
|
/** @type {?} */
|
|
2020
|
+
RsCommentaryComponent.prototype.filedsKey;
|
|
2021
|
+
/** @type {?} */
|
|
2002
2022
|
RsCommentaryComponent.prototype.actionComplete;
|
|
2003
2023
|
/** @type {?} */
|
|
2004
2024
|
RsCommentaryComponent.prototype.commentVal;
|
|
@@ -2024,6 +2044,72 @@ if (false) {
|
|
|
2024
2044
|
RsCommentaryComponent.prototype.ref;
|
|
2025
2045
|
}
|
|
2026
2046
|
|
|
2047
|
+
/**
|
|
2048
|
+
* @fileoverview added by tsickle
|
|
2049
|
+
* Generated from: lib/truncated-text-toggle/index.component.ts
|
|
2050
|
+
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
2051
|
+
*/
|
|
2052
|
+
class TruncatedTextToggleComponent {
|
|
2053
|
+
constructor() {
|
|
2054
|
+
this.showData = "";
|
|
2055
|
+
this.showExpandMoreBtn = false;
|
|
2056
|
+
this.showCollapseBtn = false;
|
|
2057
|
+
}
|
|
2058
|
+
/**
|
|
2059
|
+
* @return {?}
|
|
2060
|
+
*/
|
|
2061
|
+
ngOnInit() {
|
|
2062
|
+
if (this.data.length > this.maximum) {
|
|
2063
|
+
this.showExpandMoreBtn = true;
|
|
2064
|
+
this.showData = this.data.substring(0, this.maximum) + "...";
|
|
2065
|
+
}
|
|
2066
|
+
else {
|
|
2067
|
+
this.showData = this.data;
|
|
2068
|
+
}
|
|
2069
|
+
}
|
|
2070
|
+
/**
|
|
2071
|
+
* @return {?}
|
|
2072
|
+
*/
|
|
2073
|
+
showAll() {
|
|
2074
|
+
this.showExpandMoreBtn = false;
|
|
2075
|
+
this.showCollapseBtn = true;
|
|
2076
|
+
this.showData = this.data;
|
|
2077
|
+
}
|
|
2078
|
+
/**
|
|
2079
|
+
* @return {?}
|
|
2080
|
+
*/
|
|
2081
|
+
collapse() {
|
|
2082
|
+
this.showExpandMoreBtn = true;
|
|
2083
|
+
this.showCollapseBtn = false;
|
|
2084
|
+
this.showData = this.data.substring(0, this.maximum) + "...";
|
|
2085
|
+
}
|
|
2086
|
+
}
|
|
2087
|
+
TruncatedTextToggleComponent.decorators = [
|
|
2088
|
+
{ type: Component, args: [{
|
|
2089
|
+
selector: "truncated-text-toggle",
|
|
2090
|
+
template: "<div class=\"click-show-more-content\">\r\n <span>{{ showData }}</span>\r\n <span *ngIf=\"showExpandMoreBtn\" class=\"show-more\" (click)=\"showAll()\">\r\n Read More\r\n <img src=\"./assets/img/click_show_more_icon.svg\" alt=\"\" />\r\n </span>\r\n <div\r\n class=\"show-more collapse-btn\"\r\n (click)=\"collapse()\"\r\n *ngIf=\"showCollapseBtn\"\r\n >\r\n Collapse\r\n <img src=\"./assets/img/click_show_more_icon.svg\" alt=\"\" />\r\n </div>\r\n</div>\r\n",
|
|
2091
|
+
styles: [".click-show-more-content{word-wrap:break-word}.click-show-more-content .show-more{cursor:pointer;color:#1364b3;font-size:11px;margin-left:4px;vertical-align:middle}.click-show-more-content .show-more img{margin-left:2px;vertical-align:middle}.click-show-more-content .collapse-btn{display:flex;align-items:center;justify-content:flex-end}.click-show-more-content .collapse-btn img{transform:rotate(-180deg)}"]
|
|
2092
|
+
}] }
|
|
2093
|
+
];
|
|
2094
|
+
/** @nocollapse */
|
|
2095
|
+
TruncatedTextToggleComponent.ctorParameters = () => [];
|
|
2096
|
+
TruncatedTextToggleComponent.propDecorators = {
|
|
2097
|
+
data: [{ type: Input }],
|
|
2098
|
+
maximum: [{ type: Input }]
|
|
2099
|
+
};
|
|
2100
|
+
if (false) {
|
|
2101
|
+
/** @type {?} */
|
|
2102
|
+
TruncatedTextToggleComponent.prototype.data;
|
|
2103
|
+
/** @type {?} */
|
|
2104
|
+
TruncatedTextToggleComponent.prototype.maximum;
|
|
2105
|
+
/** @type {?} */
|
|
2106
|
+
TruncatedTextToggleComponent.prototype.showData;
|
|
2107
|
+
/** @type {?} */
|
|
2108
|
+
TruncatedTextToggleComponent.prototype.showExpandMoreBtn;
|
|
2109
|
+
/** @type {?} */
|
|
2110
|
+
TruncatedTextToggleComponent.prototype.showCollapseBtn;
|
|
2111
|
+
}
|
|
2112
|
+
|
|
2027
2113
|
/**
|
|
2028
2114
|
* @fileoverview added by tsickle
|
|
2029
2115
|
* Generated from: lib/layout/page-list/index.component.ts
|
|
@@ -21935,7 +22021,8 @@ RaiseCommonLibModule.decorators = [
|
|
|
21935
22021
|
ToolbarItemComponent,
|
|
21936
22022
|
RsCommentaryComponent,
|
|
21937
22023
|
RSNavCardGroupComponent,
|
|
21938
|
-
RSToolbarComponent
|
|
22024
|
+
RSToolbarComponent,
|
|
22025
|
+
TruncatedTextToggleComponent
|
|
21939
22026
|
],
|
|
21940
22027
|
imports: [
|
|
21941
22028
|
CommonModule,
|
|
@@ -21986,6 +22073,7 @@ RaiseCommonLibModule.decorators = [
|
|
|
21986
22073
|
],
|
|
21987
22074
|
providers: [
|
|
21988
22075
|
PageService,
|
|
22076
|
+
RowDDService,
|
|
21989
22077
|
SortService,
|
|
21990
22078
|
FilterService,
|
|
21991
22079
|
ExcelExportService,
|
|
@@ -22086,7 +22174,8 @@ RaiseCommonLibModule.decorators = [
|
|
|
22086
22174
|
ToolbarItemComponent,
|
|
22087
22175
|
RsCommentaryComponent,
|
|
22088
22176
|
RSNavCardGroupComponent,
|
|
22089
|
-
RSToolbarComponent
|
|
22177
|
+
RSToolbarComponent,
|
|
22178
|
+
TruncatedTextToggleComponent
|
|
22090
22179
|
],
|
|
22091
22180
|
entryComponents: [
|
|
22092
22181
|
NewActionNotificationComponent,
|
|
@@ -22109,5 +22198,5 @@ RaiseCommonLibModule.decorators = [
|
|
|
22109
22198
|
* @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
|
|
22110
22199
|
*/
|
|
22111
22200
|
|
|
22112
|
-
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, filterShowSection, Debounce as ɵa, NewActionNotificationComponent as ɵb, CommonDialogComponent as ɵc, CommonDeleteComponent as ɵd };
|
|
22201
|
+
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, CommonDialogComponent as ɵc, CommonDeleteComponent as ɵd };
|
|
22113
22202
|
//# sourceMappingURL=raise-common-lib.js.map
|