@tetacom/ng-components 1.0.17 → 1.0.21
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/common/util/position-util.d.ts +1 -1
- package/component/table/contract/table-context-menu-config.d.ts +2 -0
- package/component/table/public-api.d.ts +4 -0
- package/component/table/service/table.service.d.ts +1 -0
- package/component/table/table-body/table-body.component.d.ts +3 -2
- package/component/table/table.module.d.ts +2 -1
- package/component/table/util/public-api.d.ts +2 -0
- package/esm2020/common/util/position-util.mjs +13 -4
- package/esm2020/component/chart/model/chart-options.mjs +7 -2
- package/esm2020/component/dropdown/dropdown-base.mjs +24 -16
- package/esm2020/component/filter/contarct/filter-item.mjs +15 -23
- package/esm2020/component/resize-panel/resize-panel/resize-panel.component.mjs +2 -2
- package/esm2020/component/table/contract/table-column.mjs +21 -39
- package/esm2020/component/table/contract/table-context-menu-config.mjs +3 -1
- package/esm2020/component/table/public-api.mjs +5 -1
- package/esm2020/component/table/service/table.service.mjs +5 -4
- package/esm2020/component/table/table/table.component.mjs +3 -3
- package/esm2020/component/table/table-body/table-body.component.mjs +21 -16
- package/esm2020/component/table/table.module.mjs +6 -2
- package/esm2020/component/table/util/public-api.mjs +3 -0
- package/esm2020/component/table/util/table-util.mjs +1 -1
- package/fesm2015/tetacom-ng-components.mjs +101 -99
- package/fesm2015/tetacom-ng-components.mjs.map +1 -1
- package/fesm2020/tetacom-ng-components.mjs +103 -99
- package/fesm2020/tetacom-ng-components.mjs.map +1 -1
- package/package.json +1 -1
- package/style/progress.scss +6 -6
|
@@ -10,11 +10,10 @@ import { NG_VALUE_ACCESSOR, FormsModule, FormControl, FormGroup, Validators, Rea
|
|
|
10
10
|
import { BehaviorSubject, Subject, fromEvent, ReplaySubject, combineLatest, of, merge } from 'rxjs';
|
|
11
11
|
import { trigger, transition, style, animate } from '@angular/animations';
|
|
12
12
|
import * as i4 from '@angular/cdk/scrolling';
|
|
13
|
-
import { ScrollingModule } from '@angular/cdk/scrolling';
|
|
13
|
+
import { ScrollingModule, CdkVirtualScrollViewport } from '@angular/cdk/scrolling';
|
|
14
14
|
import * as i1$1 from '@ngneat/transloco';
|
|
15
15
|
import { TranslocoModule, TRANSLOCO_SCOPE } from '@ngneat/transloco';
|
|
16
16
|
import * as hash from 'object-hash';
|
|
17
|
-
import * as i6 from 'ngx-ui-scroll';
|
|
18
17
|
import { SizeStrategy, Datasource, UiScrollModule } from 'ngx-ui-scroll';
|
|
19
18
|
import * as d3 from 'd3';
|
|
20
19
|
import { zoomIdentity } from 'd3';
|
|
@@ -953,7 +952,12 @@ var VerticalAlign;
|
|
|
953
952
|
})(VerticalAlign || (VerticalAlign = {}));
|
|
954
953
|
|
|
955
954
|
class PositionUtil {
|
|
956
|
-
static getPosition(containerPosition, elementPosition, align, verticalAlign, margin = 0, verticalMargin = 0
|
|
955
|
+
static getPosition(containerPosition, elementPosition, align, verticalAlign, margin = 0, verticalMargin = 0, transformedParentRect = {
|
|
956
|
+
left: 0,
|
|
957
|
+
right: 0,
|
|
958
|
+
top: 0,
|
|
959
|
+
bottom: 0
|
|
960
|
+
}) {
|
|
957
961
|
const rect = {};
|
|
958
962
|
const elementWidth = elementPosition.right - elementPosition.left;
|
|
959
963
|
const elementHeight = elementPosition.bottom - elementPosition.top;
|
|
@@ -989,7 +993,7 @@ class PositionUtil {
|
|
|
989
993
|
}
|
|
990
994
|
}
|
|
991
995
|
if (verticalAlign === VerticalAlign.top) {
|
|
992
|
-
rect.
|
|
996
|
+
rect.top = containerPosition.top - elementHeight - verticalMargin;
|
|
993
997
|
}
|
|
994
998
|
if (verticalAlign === VerticalAlign.bottom) {
|
|
995
999
|
rect.top = containerPosition.bottom + verticalMargin;
|
|
@@ -1008,12 +1012,16 @@ class PositionUtil {
|
|
|
1008
1012
|
if (rect.top < 0) {
|
|
1009
1013
|
rect.top = 0;
|
|
1010
1014
|
}
|
|
1011
|
-
if (verticalAlign === VerticalAlign.bottom) {
|
|
1015
|
+
if (verticalAlign === VerticalAlign.bottom || verticalAlign === VerticalAlign.center) {
|
|
1012
1016
|
rect.maxHeight = window.innerHeight - rect.top;
|
|
1013
1017
|
}
|
|
1014
1018
|
if (verticalAlign === VerticalAlign.top) {
|
|
1015
1019
|
rect.maxHeight = containerPosition.top;
|
|
1016
1020
|
}
|
|
1021
|
+
rect.left = rect.left - transformedParentRect.left;
|
|
1022
|
+
rect.right = rect.right - transformedParentRect.left;
|
|
1023
|
+
rect.top = rect.top - transformedParentRect.top;
|
|
1024
|
+
rect.bottom = rect.bottom ? rect.bottom - transformedParentRect.bottom : rect.bottom;
|
|
1017
1025
|
return rect;
|
|
1018
1026
|
}
|
|
1019
1027
|
static setElementPosition(element, rect) {
|
|
@@ -1191,23 +1199,31 @@ class DropdownBase {
|
|
|
1191
1199
|
this.setPosition(this._head.nativeElement, this._body);
|
|
1192
1200
|
}
|
|
1193
1201
|
setPosition(container, target) {
|
|
1194
|
-
const
|
|
1202
|
+
const containerPosition = container.getBoundingClientRect();
|
|
1203
|
+
const targetPosition = target.getBoundingClientRect();
|
|
1195
1204
|
const rect = {
|
|
1196
|
-
bottom:
|
|
1197
|
-
top:
|
|
1198
|
-
left:
|
|
1199
|
-
right:
|
|
1205
|
+
bottom: containerPosition.bottom,
|
|
1206
|
+
top: containerPosition.top,
|
|
1207
|
+
left: containerPosition.left,
|
|
1208
|
+
right: containerPosition.right,
|
|
1209
|
+
};
|
|
1210
|
+
const targetRect = {
|
|
1211
|
+
bottom: targetPosition.bottom,
|
|
1212
|
+
top: targetPosition.top,
|
|
1213
|
+
left: targetPosition.left,
|
|
1214
|
+
right: targetPosition.right,
|
|
1215
|
+
};
|
|
1216
|
+
const targetTransformedParent = DomUtil.findTransformedParent(target);
|
|
1217
|
+
let parentPosition = {
|
|
1218
|
+
left: 0,
|
|
1219
|
+
right: 0,
|
|
1220
|
+
top: 0,
|
|
1221
|
+
bottom: 0
|
|
1200
1222
|
};
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
// rect.left = rect.left - parentPosition.left;
|
|
1206
|
-
// rect.top = rect.top - parentPosition.top;
|
|
1207
|
-
// rect.bottom = parentPosition.bottom - rect.top;
|
|
1208
|
-
// rect.right = parentPosition.right - rect.right;
|
|
1209
|
-
// }
|
|
1210
|
-
const position = PositionUtil.getPosition(rect, target.getBoundingClientRect(), this.align, this.verticalAlign);
|
|
1223
|
+
if (targetTransformedParent) {
|
|
1224
|
+
parentPosition = targetTransformedParent.getBoundingClientRect();
|
|
1225
|
+
}
|
|
1226
|
+
const position = PositionUtil.getPosition(rect, targetRect, this.align, this.verticalAlign, 0, 0, parentPosition);
|
|
1211
1227
|
PositionUtil.setElementPosition(target, position);
|
|
1212
1228
|
}
|
|
1213
1229
|
}
|
|
@@ -4699,28 +4715,20 @@ class FilterItem {
|
|
|
4699
4715
|
* Возможность фильтровать поле
|
|
4700
4716
|
*/
|
|
4701
4717
|
this.filterable = true;
|
|
4702
|
-
|
|
4703
|
-
|
|
4704
|
-
|
|
4705
|
-
|
|
4706
|
-
|
|
4707
|
-
|
|
4708
|
-
|
|
4709
|
-
|
|
4710
|
-
|
|
4711
|
-
|
|
4712
|
-
|
|
4713
|
-
|
|
4714
|
-
|
|
4715
|
-
|
|
4716
|
-
? ListFilterType.None
|
|
4717
|
-
: options.listFilterType;
|
|
4718
|
-
this.strict = options.strict || false;
|
|
4719
|
-
this.filterComponent = options.filterComponent;
|
|
4720
|
-
if (options.columns && options.columns.length) {
|
|
4721
|
-
this.columns = options.columns.map(_ => new FilterItem(_));
|
|
4722
|
-
}
|
|
4723
|
-
}
|
|
4718
|
+
this.sortOrder = options?.sortOrder ?? Number.MAX_VALUE;
|
|
4719
|
+
this.name = options?.name ?? '';
|
|
4720
|
+
this.caption = options?.caption ?? this.name;
|
|
4721
|
+
this.hint = options?.hint ?? '';
|
|
4722
|
+
this.sortable = options?.sortable ?? true;
|
|
4723
|
+
this.filterable = options?.filterable ?? true;
|
|
4724
|
+
this.sortField = options?.sortField ?? this.name;
|
|
4725
|
+
this.filterField = options?.filterField ?? this.name;
|
|
4726
|
+
this.filterType = options?.filterType;
|
|
4727
|
+
this.stringFilterType = options?.stringFilterType ?? StringFilterType.Contains;
|
|
4728
|
+
this.listFilterType = options?.listFilterType ?? ListFilterType.None;
|
|
4729
|
+
this.strict = options?.strict ?? false;
|
|
4730
|
+
this.filterComponent = options?.filterComponent;
|
|
4731
|
+
this.columns = options?.columns?.map(_ => new FilterItem(_)) ?? [];
|
|
4724
4732
|
}
|
|
4725
4733
|
}
|
|
4726
4734
|
|
|
@@ -6585,44 +6593,26 @@ class TableColumn extends FilterItem {
|
|
|
6585
6593
|
* Порядок группировки
|
|
6586
6594
|
*/
|
|
6587
6595
|
this.groupingOrder = 0;
|
|
6588
|
-
|
|
6589
|
-
|
|
6590
|
-
|
|
6591
|
-
|
|
6592
|
-
|
|
6593
|
-
|
|
6594
|
-
|
|
6595
|
-
|
|
6596
|
-
|
|
6597
|
-
|
|
6598
|
-
|
|
6599
|
-
|
|
6600
|
-
|
|
6601
|
-
|
|
6602
|
-
|
|
6603
|
-
|
|
6604
|
-
|
|
6605
|
-
|
|
6606
|
-
|
|
6607
|
-
|
|
6608
|
-
options.editable === null || options.editable === undefined
|
|
6609
|
-
? true
|
|
6610
|
-
: options.editable;
|
|
6611
|
-
if (options.columns && options.columns.length) {
|
|
6612
|
-
this.columns = [];
|
|
6613
|
-
this.columns = options.columns.map((x) => new TableColumn(x));
|
|
6614
|
-
}
|
|
6615
|
-
this.groupBy = options.groupBy ? options.groupBy : false;
|
|
6616
|
-
this.groupingOrder = options.groupingOrder ? options.groupingOrder : 0;
|
|
6617
|
-
this.groupByFn = options.groupByFn;
|
|
6618
|
-
this.headCellComponent = options.headCellComponent;
|
|
6619
|
-
this.cellComponent = options.cellComponent;
|
|
6620
|
-
this.aggregate = options.aggregate;
|
|
6621
|
-
this.defaultValue = options.defaultValue;
|
|
6622
|
-
this.maxValue = options.maxValue;
|
|
6623
|
-
this.minValue = options.minValue;
|
|
6624
|
-
this.required = options.required;
|
|
6625
|
-
}
|
|
6596
|
+
this.width = options?.width ?? 150;
|
|
6597
|
+
this.flex = options?.flex ?? 0;
|
|
6598
|
+
this.headCellClass = options?.headCellClass ?? [];
|
|
6599
|
+
this.cellClass = options?.cellClass ?? [];
|
|
6600
|
+
this.locked = options?.locked ?? false;
|
|
6601
|
+
this.parentName = options?.parentName;
|
|
6602
|
+
this.unit = options?.unit ?? '';
|
|
6603
|
+
this.data = options?.data;
|
|
6604
|
+
this.editable = options?.editable ?? true;
|
|
6605
|
+
this.groupBy = options?.groupBy ?? false;
|
|
6606
|
+
this.groupingOrder = options?.groupingOrder ?? 0;
|
|
6607
|
+
this.groupByFn = options?.groupByFn;
|
|
6608
|
+
this.headCellComponent = options?.headCellComponent;
|
|
6609
|
+
this.cellComponent = options?.cellComponent;
|
|
6610
|
+
this.aggregate = options?.aggregate;
|
|
6611
|
+
this.defaultValue = options?.defaultValue;
|
|
6612
|
+
this.maxValue = options?.maxValue;
|
|
6613
|
+
this.minValue = options?.minValue;
|
|
6614
|
+
this.required = options?.required;
|
|
6615
|
+
this.columns = options?.columns?.map((x) => new TableColumn(x)) ?? [];
|
|
6626
6616
|
}
|
|
6627
6617
|
}
|
|
6628
6618
|
|
|
@@ -6840,6 +6830,7 @@ class TableService {
|
|
|
6840
6830
|
}
|
|
6841
6831
|
setColumns(columns) {
|
|
6842
6832
|
this.initialColumns = columns ? columns.map((_) => new TableColumn(_)) : [];
|
|
6833
|
+
this.initialColumnsHash = hash.sha1(this.initialColumns);
|
|
6843
6834
|
const restored = this.restoreColumns();
|
|
6844
6835
|
if (restored) {
|
|
6845
6836
|
this.setDisplayColumns(restored);
|
|
@@ -6859,7 +6850,7 @@ class TableService {
|
|
|
6859
6850
|
saveColumnsState() {
|
|
6860
6851
|
if (this._cookieName) {
|
|
6861
6852
|
localStorage.setItem(this._columnsCookieName, JSON.stringify({
|
|
6862
|
-
hash:
|
|
6853
|
+
hash: this.initialColumnsHash,
|
|
6863
6854
|
columns: this.displayColumns.map((_) => new TableColumnStore(_)),
|
|
6864
6855
|
}));
|
|
6865
6856
|
}
|
|
@@ -6873,7 +6864,7 @@ class TableService {
|
|
|
6873
6864
|
}
|
|
6874
6865
|
restoreColumns() {
|
|
6875
6866
|
const savedColumns = JSON.parse(localStorage.getItem(this._columnsCookieName));
|
|
6876
|
-
if (savedColumns && savedColumns.hash ===
|
|
6867
|
+
if (savedColumns && savedColumns.hash === this.initialColumnsHash) {
|
|
6877
6868
|
return this.restoreColumnsState(savedColumns.columns);
|
|
6878
6869
|
}
|
|
6879
6870
|
return null;
|
|
@@ -7183,7 +7174,7 @@ class TableService {
|
|
|
7183
7174
|
}
|
|
7184
7175
|
});
|
|
7185
7176
|
column.flex = 0;
|
|
7186
|
-
column.width = maxWidth
|
|
7177
|
+
column.width = maxWidth + 20;
|
|
7187
7178
|
}
|
|
7188
7179
|
}
|
|
7189
7180
|
TableService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: TableService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
@@ -7234,11 +7225,13 @@ class TableContextMenuConfig {
|
|
|
7234
7225
|
this.copy = true;
|
|
7235
7226
|
this.delete = true;
|
|
7236
7227
|
this.add = true;
|
|
7228
|
+
this.paste = true;
|
|
7237
7229
|
if (options) {
|
|
7238
7230
|
this.contextMenu = options?.contextMenu;
|
|
7239
7231
|
this.copy = options?.copy;
|
|
7240
7232
|
this.delete = options?.delete;
|
|
7241
7233
|
this.add = options?.add;
|
|
7234
|
+
this.paste = options?.paste;
|
|
7242
7235
|
}
|
|
7243
7236
|
}
|
|
7244
7237
|
}
|
|
@@ -8984,11 +8977,14 @@ class TableBodyComponent {
|
|
|
8984
8977
|
this._svc.scrollIndex
|
|
8985
8978
|
.pipe(takeWhile((_) => this._alive))
|
|
8986
8979
|
.subscribe(async (_) => {
|
|
8987
|
-
if (this.viewport && this.dataSource && _ !== null) {
|
|
8988
|
-
|
|
8989
|
-
|
|
8990
|
-
|
|
8991
|
-
|
|
8980
|
+
// if (this.viewport && this.dataSource && _ !== null) {
|
|
8981
|
+
// await this.dataSource.adapter.relax();
|
|
8982
|
+
// await this.dataSource.adapter.fix({
|
|
8983
|
+
// scrollPosition: (_ + 1) * 24,
|
|
8984
|
+
// });
|
|
8985
|
+
// }
|
|
8986
|
+
if (this.viewport) {
|
|
8987
|
+
this.viewport.scrollToIndex(_, 'smooth');
|
|
8992
8988
|
}
|
|
8993
8989
|
this._cdr.markForCheck();
|
|
8994
8990
|
});
|
|
@@ -9020,7 +9016,8 @@ class TableBodyComponent {
|
|
|
9020
9016
|
setActiveRow(row) {
|
|
9021
9017
|
this._svc.setActiveRow(row);
|
|
9022
9018
|
}
|
|
9023
|
-
ngOnInit() {
|
|
9019
|
+
ngOnInit() {
|
|
9020
|
+
}
|
|
9024
9021
|
ngOnDestroy() {
|
|
9025
9022
|
this._alive = false;
|
|
9026
9023
|
}
|
|
@@ -9078,7 +9075,7 @@ class TableBodyComponent {
|
|
|
9078
9075
|
return template;
|
|
9079
9076
|
}
|
|
9080
9077
|
trackRow(index, row) {
|
|
9081
|
-
return
|
|
9078
|
+
return index;
|
|
9082
9079
|
}
|
|
9083
9080
|
trackColumns(index, column) {
|
|
9084
9081
|
return column.name;
|
|
@@ -9126,10 +9123,10 @@ class TableBodyComponent {
|
|
|
9126
9123
|
}
|
|
9127
9124
|
}
|
|
9128
9125
|
TableBodyComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: TableBodyComponent, deps: [{ token: TableService }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
9129
|
-
TableBodyComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: TableBodyComponent, selector: "teta-table-body", inputs: { virtual: "virtual", activeRow: "activeRow", rowHeight: "rowHeight", additionalComponent: "additionalComponent", tree: "tree", aggregate: "aggregate", grouping: "grouping", groupRowComponent: "groupRowComponent", openLevels: "openLevels", selectType: "selectType", rowClass: "rowClass" }, host: { properties: { "class.table-body": "this.tableBodyClass" } }, viewQueries: [{ propertyName: "viewport", first: true, predicate:
|
|
9126
|
+
TableBodyComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: TableBodyComponent, selector: "teta-table-body", inputs: { virtual: "virtual", activeRow: "activeRow", rowHeight: "rowHeight", additionalComponent: "additionalComponent", tree: "tree", aggregate: "aggregate", grouping: "grouping", groupRowComponent: "groupRowComponent", openLevels: "openLevels", selectType: "selectType", rowClass: "rowClass" }, host: { properties: { "class.table-body": "this.tableBodyClass" } }, viewQueries: [{ propertyName: "viewport", first: true, predicate: CdkVirtualScrollViewport, descendants: true }], ngImport: i0, template: "<!--<div #viewport class=\"table-body-container table-body-container-virtual\"-->\n<!-- *ngIf=\"virtual\"-->\n<!-- [style.grid-template-columns]=\"getTemplateColumns()\"-->\n<!-- style=\"height: 100%;\">-->\n<!-- <ng-container-->\n<!-- *uiScroll=\"let row of dataSource; let rowIndex = index; let last = last;\" style=\"display: flex;flex-grow: 1\">-->\n<!-- <ng-container *ngTemplateOutlet=\"bodyTemplate; context: {row: row, rowIndex: rowIndex}\"></ng-container>-->\n<!-- </ng-container>-->\n<!-- <ng-container *ngIf=\"aggregate\">-->\n<!-- <ng-container *ngTemplateOutlet=\"aggTemplate;\"></ng-container>-->\n<!-- </ng-container>-->\n<!--</div>-->\n\n<cdk-virtual-scroll-viewport *ngIf=\"virtual\"\n class=\"table-body-container\"\n [maxBufferPx]=\"600\"\n [minBufferPx]=\"240\"\n [itemSize]=\"24\">\n <ng-container *cdkVirtualFor=\"let row of data;templateCacheSize: 0; let rowIndex = index; trackBy: trackRow;\">\n <ng-container *ngTemplateOutlet=\"bodyTemplate; context: {row: row, rowIndex: rowIndex}\"></ng-container>\n </ng-container>\n</cdk-virtual-scroll-viewport>\n\n\n<div *ngIf=\"!virtual\"\n class=\"table-body-container\"\n [style.grid-template-rows]=\"rowHeight + 'px'\"\n [style.grid-auto-rows]=\"rowHeight + 'px'\"\n [style.grid-template-columns]=\"getTemplateColumns()\">\n <ng-container *ngFor=\"let row of data; let rowIndex = index; trackBy: trackRow;\">\n <ng-container *ngTemplateOutlet=\"bodyTemplate; context: {row: row, rowIndex: rowIndex}\"></ng-container>\n </ng-container>\n <ng-container *ngIf=\"aggregate\">\n <ng-container *ngTemplateOutlet=\"aggTemplate;\"></ng-container>\n </ng-container>\n</div>\n\n<ng-template #bodyTemplate let-row=\"row\" let-rowIndex=\"rowIndex\">\n <div class=\"table-row\"\n (click)=\"setActiveRow(row)\"\n [attr.data-row]=\"rowIndex\"\n [ngClass]=\"rowClass ? rowClass(row, rowIndex) : ''\"\n [class.table-row_virtual]=\"virtual\"\n [style.grid-template-columns]=\"virtual ? getTemplateColumns() : ''\"\n [class.table-row_active]=\"row === activeRow || selectedRows.indexOf(row) >= 0\">\n <ng-container *ngIf=\"!grouping\">\n <div class=\"table-row_locked\"\n *ngIf=\"locked.length > 0\"\n [style.grid-template-columns]=\"getLockedGridTemplateColumns(locked)\"\n [style.zIndex]=\"row === activeRow ? 1 : 'unset'\"\n [style.grid-column-end]=\"getSpan()\">\n <teta-selection-cell *ngIf=\"selectType !== selectTypeEnum.none && locked.length\"\n [row]=\"row\"></teta-selection-cell>\n <teta-cell\n *ngFor=\"let column of locked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-row]=\"rowIndex\"\n [attr.data-column]=\"column.name\"\n [column]=\"column\"\n [filterOptions]=\"dict[column.name]\"\n [dict]=\"dict\"\n [row]=\"row\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\"\n ></teta-cell>\n </div>\n <teta-selection-cell *ngIf=\"selectType !== selectTypeEnum.none && locked.length < 1\"\n [row]=\"row\"></teta-selection-cell>\n <teta-cell\n *ngFor=\"let column of unlocked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-row]=\"rowIndex\"\n [attr.data-column]=\"column.name\"\n [column]=\"column\"\n [filterOptions]=\"dict[column.name]\"\n [dict]=\"dict\"\n [row]=\"row\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\"\n ></teta-cell>\n </ng-container>\n <ng-container *ngIf=\"grouping\">\n </ng-container>\n </div>\n</ng-template>\n\n<ng-template #aggTemplate>\n <div class=\"table-row\"\n *ngIf=\"aggregate\"\n [class.table-row_virtual]=\"virtual\"\n [style.grid-template-columns]=\"virtual ? getTemplateColumns() : ''\">\n <div class=\"table-row_locked\"\n *ngIf=\"locked.length > 0\"\n [style.grid-template-columns]=\"getLockedGridTemplateColumns(locked)\"\n [style.grid-column-end]=\"getSpan()\">\n <div class=\"cell align-center justify-content-center\">\n <teta-icon [name]=\"'sumColor'\"></teta-icon>\n </div>\n <div class=\"cell cell-component justify-content-end\"\n *ngFor=\"let column of locked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-column]=\"column.name\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\">\n <span class=\"cell-text cell-text_numeric font-title-3\">\n {{getAggregateText(column)}}:\n {{getAggregateValue(column) | tetaNumber : 2}}\n </span>\n </div>\n </div>\n <div class=\"cell align-center justify-content-center\"\n *ngIf=\"selectType !== selectTypeEnum.none && locked.length < 1\">\n <teta-icon [name]=\"'sumColor'\"></teta-icon>\n </div>\n <div class=\"cell cell-component justify-content-end\"\n *ngFor=\"let column of unlocked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-column]=\"column.name\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\">\n <span class=\"cell-text cell-text_numeric font-title-3\">\n {{getAggregateText(column)}}\n {{getAggregateValue(column) | tetaNumber : 2}}\n </span>\n </div>\n </div>\n</ng-template>\n", styles: [""], components: [{ type: i4.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { type: SelectionCellComponent, selector: "teta-selection-cell", inputs: ["row"] }, { type: CellComponent, selector: "teta-cell", inputs: ["column", "filterOptions", "dict", "row"] }, { type: IconComponent, selector: "teta-icon", inputs: ["name", "size", "palette", "class"] }], directives: [{ type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { type: i4.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }, { type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i2.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }], pipes: { "tetaNumber": NumberPipe }, changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9130
9127
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: TableBodyComponent, decorators: [{
|
|
9131
9128
|
type: Component,
|
|
9132
|
-
args: [{ selector: 'teta-table-body', changeDetection: ChangeDetectionStrategy.OnPush, template: "
|
|
9129
|
+
args: [{ selector: 'teta-table-body', changeDetection: ChangeDetectionStrategy.OnPush, template: "<!--<div #viewport class=\"table-body-container table-body-container-virtual\"-->\n<!-- *ngIf=\"virtual\"-->\n<!-- [style.grid-template-columns]=\"getTemplateColumns()\"-->\n<!-- style=\"height: 100%;\">-->\n<!-- <ng-container-->\n<!-- *uiScroll=\"let row of dataSource; let rowIndex = index; let last = last;\" style=\"display: flex;flex-grow: 1\">-->\n<!-- <ng-container *ngTemplateOutlet=\"bodyTemplate; context: {row: row, rowIndex: rowIndex}\"></ng-container>-->\n<!-- </ng-container>-->\n<!-- <ng-container *ngIf=\"aggregate\">-->\n<!-- <ng-container *ngTemplateOutlet=\"aggTemplate;\"></ng-container>-->\n<!-- </ng-container>-->\n<!--</div>-->\n\n<cdk-virtual-scroll-viewport *ngIf=\"virtual\"\n class=\"table-body-container\"\n [maxBufferPx]=\"600\"\n [minBufferPx]=\"240\"\n [itemSize]=\"24\">\n <ng-container *cdkVirtualFor=\"let row of data;templateCacheSize: 0; let rowIndex = index; trackBy: trackRow;\">\n <ng-container *ngTemplateOutlet=\"bodyTemplate; context: {row: row, rowIndex: rowIndex}\"></ng-container>\n </ng-container>\n</cdk-virtual-scroll-viewport>\n\n\n<div *ngIf=\"!virtual\"\n class=\"table-body-container\"\n [style.grid-template-rows]=\"rowHeight + 'px'\"\n [style.grid-auto-rows]=\"rowHeight + 'px'\"\n [style.grid-template-columns]=\"getTemplateColumns()\">\n <ng-container *ngFor=\"let row of data; let rowIndex = index; trackBy: trackRow;\">\n <ng-container *ngTemplateOutlet=\"bodyTemplate; context: {row: row, rowIndex: rowIndex}\"></ng-container>\n </ng-container>\n <ng-container *ngIf=\"aggregate\">\n <ng-container *ngTemplateOutlet=\"aggTemplate;\"></ng-container>\n </ng-container>\n</div>\n\n<ng-template #bodyTemplate let-row=\"row\" let-rowIndex=\"rowIndex\">\n <div class=\"table-row\"\n (click)=\"setActiveRow(row)\"\n [attr.data-row]=\"rowIndex\"\n [ngClass]=\"rowClass ? rowClass(row, rowIndex) : ''\"\n [class.table-row_virtual]=\"virtual\"\n [style.grid-template-columns]=\"virtual ? getTemplateColumns() : ''\"\n [class.table-row_active]=\"row === activeRow || selectedRows.indexOf(row) >= 0\">\n <ng-container *ngIf=\"!grouping\">\n <div class=\"table-row_locked\"\n *ngIf=\"locked.length > 0\"\n [style.grid-template-columns]=\"getLockedGridTemplateColumns(locked)\"\n [style.zIndex]=\"row === activeRow ? 1 : 'unset'\"\n [style.grid-column-end]=\"getSpan()\">\n <teta-selection-cell *ngIf=\"selectType !== selectTypeEnum.none && locked.length\"\n [row]=\"row\"></teta-selection-cell>\n <teta-cell\n *ngFor=\"let column of locked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-row]=\"rowIndex\"\n [attr.data-column]=\"column.name\"\n [column]=\"column\"\n [filterOptions]=\"dict[column.name]\"\n [dict]=\"dict\"\n [row]=\"row\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\"\n ></teta-cell>\n </div>\n <teta-selection-cell *ngIf=\"selectType !== selectTypeEnum.none && locked.length < 1\"\n [row]=\"row\"></teta-selection-cell>\n <teta-cell\n *ngFor=\"let column of unlocked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-row]=\"rowIndex\"\n [attr.data-column]=\"column.name\"\n [column]=\"column\"\n [filterOptions]=\"dict[column.name]\"\n [dict]=\"dict\"\n [row]=\"row\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\"\n ></teta-cell>\n </ng-container>\n <ng-container *ngIf=\"grouping\">\n </ng-container>\n </div>\n</ng-template>\n\n<ng-template #aggTemplate>\n <div class=\"table-row\"\n *ngIf=\"aggregate\"\n [class.table-row_virtual]=\"virtual\"\n [style.grid-template-columns]=\"virtual ? getTemplateColumns() : ''\">\n <div class=\"table-row_locked\"\n *ngIf=\"locked.length > 0\"\n [style.grid-template-columns]=\"getLockedGridTemplateColumns(locked)\"\n [style.grid-column-end]=\"getSpan()\">\n <div class=\"cell align-center justify-content-center\">\n <teta-icon [name]=\"'sumColor'\"></teta-icon>\n </div>\n <div class=\"cell cell-component justify-content-end\"\n *ngFor=\"let column of locked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-column]=\"column.name\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\">\n <span class=\"cell-text cell-text_numeric font-title-3\">\n {{getAggregateText(column)}}:\n {{getAggregateValue(column) | tetaNumber : 2}}\n </span>\n </div>\n </div>\n <div class=\"cell align-center justify-content-center\"\n *ngIf=\"selectType !== selectTypeEnum.none && locked.length < 1\">\n <teta-icon [name]=\"'sumColor'\"></teta-icon>\n </div>\n <div class=\"cell cell-component justify-content-end\"\n *ngFor=\"let column of unlocked; let colIndex = index; trackBy: trackColumns;\"\n [attr.data-column]=\"column.name\"\n [ngClass]=\"column.cellClass\"\n [attr.tabindex]=\"0\">\n <span class=\"cell-text cell-text_numeric font-title-3\">\n {{getAggregateText(column)}}\n {{getAggregateValue(column) | tetaNumber : 2}}\n </span>\n </div>\n </div>\n</ng-template>\n", styles: [""] }]
|
|
9133
9130
|
}], ctorParameters: function () { return [{ type: TableService }, { type: i0.ChangeDetectorRef }]; }, propDecorators: { virtual: [{
|
|
9134
9131
|
type: Input
|
|
9135
9132
|
}], activeRow: [{
|
|
@@ -9154,7 +9151,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
9154
9151
|
type: Input
|
|
9155
9152
|
}], viewport: [{
|
|
9156
9153
|
type: ViewChild,
|
|
9157
|
-
args: [
|
|
9154
|
+
args: [CdkVirtualScrollViewport, { static: false }]
|
|
9158
9155
|
}], tableBodyClass: [{
|
|
9159
9156
|
type: HostBinding,
|
|
9160
9157
|
args: ['class.table-body']
|
|
@@ -9447,10 +9444,10 @@ class TableComponent {
|
|
|
9447
9444
|
}
|
|
9448
9445
|
}
|
|
9449
9446
|
TableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: TableComponent, deps: [{ token: TableService }, { token: i0.ElementRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
9450
|
-
TableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: TableComponent, selector: "teta-table", inputs: { data: "data", columns: "columns", dict: "dict", state: "state", rowHeight: "rowHeight", cookieName: "cookieName", virtual: "virtual", detailComponent: "detailComponent", activeRow: "activeRow", selectedRows: "selectedRows", selectType: "selectType", aggregate: "aggregate", grouping: "grouping", groupRowComponent: "groupRowComponent", openLevels: "openLevels", tree: "tree", trackBy: "trackBy", editType: "editType", editEvent: "editEvent", rowEditable: "rowEditable", cellEditable: "cellEditable", rowClass: "rowClass", scrollToIndex: "scrollToIndex", contextMenuConfig: "contextMenuConfig", showHeadCellMenu: "showHeadCellMenu" }, outputs: { stateChange: "stateChange", bodyLeft: "bodyLeft", activeRowChange: "activeRowChange", selectedRowsChange: "selectedRowsChange", rowLeft: "rowLeft", rowEditStart: "rowEditStart", rowEditEnd: "rowEditEnd", cellClick: "cellClick", cellDoubleClick: "cellDoubleClick", cellFocus: "cellFocus", cellEditStart: "cellEditStart", cellEditEnd: "cellEditEnd", valueChange: "valueChange", cellKeyUp: "cellKeyUp", pasteRows: "pasteRows", addRow: "addRow", deleteRows: "deleteRows", tableService: "tableService" }, host: { listeners: { "document:click": "handleClickOutsideAnyRow($event)", "focusin": "focusIn($event)", "dblclick": "dblclick($event)", "window:keyup": "keyup($event)", "mousedown": "mousedown($event)", "contextmenu": "contextMenu($event)" }, properties: { "class.table": "this.tableClass" } }, providers: [TableService], viewQueries: [{ propertyName: "menu", first: true, predicate: ["contextMenu"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"column column_auto\">\n <teta-table-head [selectType]=\"selectType\" [showHeadCellMenu]=\"showHeadCellMenu\"></teta-table-head>\n <teta-table-body\n [aggregate]=\"aggregate\"\n [virtual]=\"virtual\"\n [activeRow]=\"activeRow\"\n [additionalComponent]=\"detailComponent\"\n [grouping]=\"grouping\"\n [groupRowComponent]=\"groupRowComponent\"\n [openLevels]=\"openLevels\"\n [selectType]=\"selectType\"\n [rowHeight]=\"rowHeight\"\n [rowClass]=\"rowClass\"\n [tree]=\"tree\"></teta-table-body>\n</div>\n\n<div #contextMenu\n class=\"list shadow-1\"\n style=\"position: fixed; z-index: 2;\"\n [style.visibility]=\"showContextMenu ? 'visible ' : 'hidden'\"\n [tetaClickOutside]=\"showContextMenu\"\n (clickOutside)=\"showContextMenu = false\">\n <ng-container *ngIf=\"contextMenuConfig?.add\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"rowAdd()\">\n <teta-icon [name]=\"'add'\" [palette]=\"'text'\"></teta-icon>\n \u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.copy\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'copySelected'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'copy'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"pasteData()\">\n <teta-icon [name]=\"'paste'\" [palette]=\"'text'\"></teta-icon>\n \u0412\u0441\u0442\u0430\u0432\u0438\u0442\u044C\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.delete\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'deleteSelected'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'delete'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n </ng-container>\n</div>\n", styles: [""], components: [{ type: TableHeadComponent, selector: "teta-table-head", inputs: ["selectType", "showHeadCellMenu"] }, { type: TableBodyComponent, selector: "teta-table-body", inputs: ["virtual", "activeRow", "rowHeight", "additionalComponent", "tree", "aggregate", "grouping", "groupRowComponent", "openLevels", "selectType", "rowClass"] }, { type: IconComponent, selector: "teta-icon", inputs: ["name", "size", "palette", "class"] }], directives: [{ type: ClickOutsideDirective, selector: "[tetaClickOutside]", inputs: ["rightClick", "tetaClickOutside"], outputs: ["clickOutside"] }, { type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9447
|
+
TableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.1", type: TableComponent, selector: "teta-table", inputs: { data: "data", columns: "columns", dict: "dict", state: "state", rowHeight: "rowHeight", cookieName: "cookieName", virtual: "virtual", detailComponent: "detailComponent", activeRow: "activeRow", selectedRows: "selectedRows", selectType: "selectType", aggregate: "aggregate", grouping: "grouping", groupRowComponent: "groupRowComponent", openLevels: "openLevels", tree: "tree", trackBy: "trackBy", editType: "editType", editEvent: "editEvent", rowEditable: "rowEditable", cellEditable: "cellEditable", rowClass: "rowClass", scrollToIndex: "scrollToIndex", contextMenuConfig: "contextMenuConfig", showHeadCellMenu: "showHeadCellMenu" }, outputs: { stateChange: "stateChange", bodyLeft: "bodyLeft", activeRowChange: "activeRowChange", selectedRowsChange: "selectedRowsChange", rowLeft: "rowLeft", rowEditStart: "rowEditStart", rowEditEnd: "rowEditEnd", cellClick: "cellClick", cellDoubleClick: "cellDoubleClick", cellFocus: "cellFocus", cellEditStart: "cellEditStart", cellEditEnd: "cellEditEnd", valueChange: "valueChange", cellKeyUp: "cellKeyUp", pasteRows: "pasteRows", addRow: "addRow", deleteRows: "deleteRows", tableService: "tableService" }, host: { listeners: { "document:click": "handleClickOutsideAnyRow($event)", "focusin": "focusIn($event)", "dblclick": "dblclick($event)", "window:keyup": "keyup($event)", "mousedown": "mousedown($event)", "contextmenu": "contextMenu($event)" }, properties: { "class.table": "this.tableClass" } }, providers: [TableService], viewQueries: [{ propertyName: "menu", first: true, predicate: ["contextMenu"], descendants: true, static: true }], usesOnChanges: true, ngImport: i0, template: "<div class=\"column column_auto\">\n <teta-table-head [selectType]=\"selectType\" [showHeadCellMenu]=\"showHeadCellMenu\"></teta-table-head>\n <teta-table-body\n [aggregate]=\"aggregate\"\n [virtual]=\"virtual\"\n [activeRow]=\"activeRow\"\n [additionalComponent]=\"detailComponent\"\n [grouping]=\"grouping\"\n [groupRowComponent]=\"groupRowComponent\"\n [openLevels]=\"openLevels\"\n [selectType]=\"selectType\"\n [rowHeight]=\"rowHeight\"\n [rowClass]=\"rowClass\"\n [tree]=\"tree\"></teta-table-body>\n</div>\n\n<div #contextMenu\n class=\"list shadow-1\"\n style=\"position: fixed; z-index: 2;\"\n [style.visibility]=\"showContextMenu ? 'visible ' : 'hidden'\"\n [tetaClickOutside]=\"showContextMenu\"\n (clickOutside)=\"showContextMenu = false\">\n <ng-container *ngIf=\"contextMenuConfig?.add\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"rowAdd()\">\n <teta-icon [name]=\"'add'\" [palette]=\"'text'\"></teta-icon>\n \u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.copy\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'copySelected'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'copy'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.paste\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"pasteData()\">\n <teta-icon [name]=\"'paste'\" [palette]=\"'text'\"></teta-icon>\n \u0412\u0441\u0442\u0430\u0432\u0438\u0442\u044C\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.delete\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'deleteSelected'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'delete'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n </ng-container>\n</div>\n", styles: [""], components: [{ type: TableHeadComponent, selector: "teta-table-head", inputs: ["selectType", "showHeadCellMenu"] }, { type: TableBodyComponent, selector: "teta-table-body", inputs: ["virtual", "activeRow", "rowHeight", "additionalComponent", "tree", "aggregate", "grouping", "groupRowComponent", "openLevels", "selectType", "rowClass"] }, { type: IconComponent, selector: "teta-icon", inputs: ["name", "size", "palette", "class"] }], directives: [{ type: ClickOutsideDirective, selector: "[tetaClickOutside]", inputs: ["rightClick", "tetaClickOutside"], outputs: ["clickOutside"] }, { type: i2.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
9451
9448
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: TableComponent, decorators: [{
|
|
9452
9449
|
type: Component,
|
|
9453
|
-
args: [{ selector: 'teta-table', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TableService], template: "<div class=\"column column_auto\">\n <teta-table-head [selectType]=\"selectType\" [showHeadCellMenu]=\"showHeadCellMenu\"></teta-table-head>\n <teta-table-body\n [aggregate]=\"aggregate\"\n [virtual]=\"virtual\"\n [activeRow]=\"activeRow\"\n [additionalComponent]=\"detailComponent\"\n [grouping]=\"grouping\"\n [groupRowComponent]=\"groupRowComponent\"\n [openLevels]=\"openLevels\"\n [selectType]=\"selectType\"\n [rowHeight]=\"rowHeight\"\n [rowClass]=\"rowClass\"\n [tree]=\"tree\"></teta-table-body>\n</div>\n\n<div #contextMenu\n class=\"list shadow-1\"\n style=\"position: fixed; z-index: 2;\"\n [style.visibility]=\"showContextMenu ? 'visible ' : 'hidden'\"\n [tetaClickOutside]=\"showContextMenu\"\n (clickOutside)=\"showContextMenu = false\">\n <ng-container *ngIf=\"contextMenuConfig?.add\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"rowAdd()\">\n <teta-icon [name]=\"'add'\" [palette]=\"'text'\"></teta-icon>\n \u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.copy\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'copySelected'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'copy'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"pasteData()\">\n <teta-icon [name]=\"'paste'\" [palette]=\"'text'\"></teta-icon>\n \u0412\u0441\u0442\u0430\u0432\u0438\u0442\u044C\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.delete\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'deleteSelected'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'delete'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n </ng-container>\n</div>\n", styles: [""] }]
|
|
9450
|
+
args: [{ selector: 'teta-table', changeDetection: ChangeDetectionStrategy.OnPush, providers: [TableService], template: "<div class=\"column column_auto\">\n <teta-table-head [selectType]=\"selectType\" [showHeadCellMenu]=\"showHeadCellMenu\"></teta-table-head>\n <teta-table-body\n [aggregate]=\"aggregate\"\n [virtual]=\"virtual\"\n [activeRow]=\"activeRow\"\n [additionalComponent]=\"detailComponent\"\n [grouping]=\"grouping\"\n [groupRowComponent]=\"groupRowComponent\"\n [openLevels]=\"openLevels\"\n [selectType]=\"selectType\"\n [rowHeight]=\"rowHeight\"\n [rowClass]=\"rowClass\"\n [tree]=\"tree\"></teta-table-body>\n</div>\n\n<div #contextMenu\n class=\"list shadow-1\"\n style=\"position: fixed; z-index: 2;\"\n [style.visibility]=\"showContextMenu ? 'visible ' : 'hidden'\"\n [tetaClickOutside]=\"showContextMenu\"\n (clickOutside)=\"showContextMenu = false\">\n <ng-container *ngIf=\"contextMenuConfig?.add\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"rowAdd()\">\n <teta-icon [name]=\"'add'\" [palette]=\"'text'\"></teta-icon>\n \u0414\u043E\u0431\u0430\u0432\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.copy\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'copySelected'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"copy([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'copy'\" [palette]=\"'text'\"></teta-icon>\n \u041A\u043E\u043F\u0438\u0440\u043E\u0432\u0430\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.paste\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"pasteData()\">\n <teta-icon [name]=\"'paste'\" [palette]=\"'text'\"></teta-icon>\n \u0412\u0441\u0442\u0430\u0432\u0438\u0442\u044C\n </div>\n <div class=\"list-divider\"></div>\n </ng-container>\n <ng-container *ngIf=\"contextMenuConfig?.delete\">\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete(selectedRowsList)\"\n *ngIf=\"selectedRowsList?.length > 0\">\n <teta-icon [name]=\"'deleteSelected'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0432\u044B\u0434\u0435\u043B\u0435\u043D\u043D\u044B\u0435 \u0441\u0442\u0440\u043E\u043A\u0438\n </div>\n <div class=\"list-item list-item_interactive\"\n (click)=\"delete([contextMenuTarget.row])\"\n *ngIf=\"contextMenuTarget\">\n <teta-icon [name]=\"'delete'\" [palette]=\"'text'\"></teta-icon>\n \u0423\u0434\u0430\u043B\u0438\u0442\u044C \u0441\u0442\u0440\u043E\u043A\u0443\n </div>\n </ng-container>\n</div>\n", styles: [""] }]
|
|
9454
9451
|
}], ctorParameters: function () { return [{ type: TableService }, { type: i0.ElementRef }]; }, propDecorators: { data: [{
|
|
9455
9452
|
type: Input
|
|
9456
9453
|
}], columns: [{
|
|
@@ -9745,7 +9742,8 @@ TableModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "1
|
|
|
9745
9742
|
UiScrollModule,
|
|
9746
9743
|
ToolbarModule,
|
|
9747
9744
|
ClickOutsideModule,
|
|
9748
|
-
ResizeDragModule
|
|
9745
|
+
ResizeDragModule,
|
|
9746
|
+
ScrollingModule], exports: [TableComponent,
|
|
9749
9747
|
NumericCellComponent,
|
|
9750
9748
|
ListCellComponent,
|
|
9751
9749
|
DateCellComponent,
|
|
@@ -9777,6 +9775,7 @@ TableModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "1
|
|
|
9777
9775
|
ToolbarModule,
|
|
9778
9776
|
ClickOutsideModule,
|
|
9779
9777
|
ResizeDragModule,
|
|
9778
|
+
ScrollingModule,
|
|
9780
9779
|
]] });
|
|
9781
9780
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImport: i0, type: TableModule, decorators: [{
|
|
9782
9781
|
type: NgModule,
|
|
@@ -9836,6 +9835,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.1", ngImpor
|
|
|
9836
9835
|
ToolbarModule,
|
|
9837
9836
|
ClickOutsideModule,
|
|
9838
9837
|
ResizeDragModule,
|
|
9838
|
+
ScrollingModule,
|
|
9839
9839
|
],
|
|
9840
9840
|
}]
|
|
9841
9841
|
}] });
|
|
@@ -12111,7 +12111,11 @@ class ChartOptions {
|
|
|
12111
12111
|
this.gridLines = options?.gridLines == null ? true : options.gridLines;
|
|
12112
12112
|
this.width = options?.width;
|
|
12113
12113
|
this.height = options?.height;
|
|
12114
|
-
this.legend = {
|
|
12114
|
+
this.legend = {
|
|
12115
|
+
visible: true,
|
|
12116
|
+
type: LegendType.swatches,
|
|
12117
|
+
...options?.legend,
|
|
12118
|
+
};
|
|
12115
12119
|
this.bounds = { ...this.bounds, ...options?.bounds };
|
|
12116
12120
|
this.annotations = options?.annotations;
|
|
12117
12121
|
}
|
|
@@ -12961,7 +12965,7 @@ class ResizePanelComponent {
|
|
|
12961
12965
|
}
|
|
12962
12966
|
restore() {
|
|
12963
12967
|
if (this.name?.length > 0) {
|
|
12964
|
-
return JSON.parse(localStorage.getItem(`resize-panel${this.name}`)
|
|
12968
|
+
return JSON.parse(localStorage.getItem(`resize-panel${this.name}`));
|
|
12965
12969
|
}
|
|
12966
12970
|
}
|
|
12967
12971
|
restorePosition() {
|
|
@@ -13199,5 +13203,5 @@ class StringUtil {
|
|
|
13199
13203
|
* Generated bundle index. Do not edit.
|
|
13200
13204
|
*/
|
|
13201
13205
|
|
|
13202
|
-
export { AccordionComponent, AccordionContentDirective, AccordionHeadComponent, AccordionItemComponent, AccordionModule, AggregationType, Align, Annotation, AreaDrawer, ArrayUtil, Axis, AxisOptions, AxisType, BarDrawer, BooleanCellComponent, BooleanFilter, BooleanFilterComponent, ButtonComponent, ButtonModule, CHECKBOX_CONTROL_VALUE_ACCESSOR, CellComponent, CellComponentBase, CellHostComponent, Chart3dComponent, Chart3dModule, Chart3dOptions, ChartBounds, ChartComponent, ChartModule, ChartOptions, CheckboxComponent, CheckboxModule, ClickOutsideDirective, ClickOutsideModule, ClickService, ColumnReorderEvent, ColumnResizeEvent, ContextMenuDirective, ContextMenuModule, CurrentModal, DATE_PICKER_CONTROL_VALUE_ACCESSOR, DAY_SELECT_CONTROL_VALUE_ACCESSOR, DateCellComponent, DateFilter, DateFilterComponent, DateFilterValue, DatePeriod, DatePickerComponent, DatePickerModule, DateTimeCellComponent, DateUtil, DaySelectComponent, DelimiterComponent, DelimiterModule, DetailComponentBase, DialogComponent, DialogService, DisableControlDirective, DisableControlModule, DomUtil, DragPointType, DragSortContainerDirective, DragSortItemDirective, DragSortModule, DropdownComponent, DropdownContentDirective, DropdownDirective, DropdownHeadDirective, DropdownModule, DynamicComponentModule, DynamicComponentService, DynamicContentBaseDirective, DynamicData, EditEvent, EditType, ExpandPanelComponent, ExpandPanelContentDirective, ExpandPanelHeadDirective, ExpandPanelModule, FileItemComponent, FileUploadAreaComponent, FileUploadModule, FilterBase, FilterComponentBase, FilterHostComponent, FilterItem, FilterModule, FilterPanelComponent, FilterState, FilterType, FormGroupTitleComponent, FormsUtil, GroupRowComponent, HeadCellComponentBase, HeadCellHostComponent, HighlightDirective, HighlightModule, HintDirective, HintModule, IconComponent, IconModule, IconService, IconSpriteDirective, InputComponent, InputModule, LegendType, LineDrawer, ListCellComponent, ListFilter, ListFilterComponent, ListFilterType, LoaderDirective, LoaderModule, MONTH_PICKER_CONTROL_VALUE_ACCESSOR, Message, MessageComponent, MessageHostComponent, MessageModule, MessageService, ModalCloseReason, ModalContainerComponent, ModalInstance, ModalModule, ModalService, MonthPickerComponent, NoAutofillDirective, NoAutofillModule, NumberPipe, NumberPipeModule, NumericCellComponent, NumericFilter, NumericFilterComponent, NumericFilterValue, OnlyNumberDirective, OnlyNumberModule, OverlayContainerService, PagerComponent, PagerModule, PagerState, PagerUtil, PanelComponent, PanelModule, PieDrawer, PlotBand, PlotLine, PopupContentComponent, PositionUtil, ProgressBarComponent, ProgressBarModule, PropertyGridComponent, PropertyGridModule, RadioButtonComponent, RadioComponent, RadioModule, ResizeDragDirective, ResizeDragModule, ResizePanelComponent, ResizePanelModule, SLIDER_CONTROL_VALUE_ACCESSOR, SWITCH_CONTROL_VALUE_ACCESSOR, Scale, ScaleType, ScatterDrawer, SelectComponent, SelectModule, SelectOptionDirective, SelectType, SelectValueDirective, Series, SeriesType, SidebarComponent, SidebarModule, SidebarPosition, SortEvent, SortParam, SplineDrawer, StringCellComponent, StringFilter, StringFilterComponent, StringFilterType, StringUtil, SwitchButtonComponent, SwitchComponent, SwitchModule, TOGGLE_CONTROL_VALUE_ACCESSOR, TabComponent, TabContentDirective, TabTitleDirective, TableBodyComponent, TableColumn, TableColumnStore, TableComponent, TableContextMenuConfig, TableHeadComponent, TableModule, TableRow, TableService, TabsComponent, TabsModule, TetaChart, TetaContentRef, TetaSize, TetaTemplateDirective, TetaTemplateModule, TextFieldComponent, ThemeSwitchComponent, ThemeSwitchModule, ThemeSwitchService, ToggleComponent, ToggleModule, ToolbarComponent, ToolbarModule, TooltipDirective, TooltipModule, TooltipOptions, TreeComponent, TreeItemToggleComponent, TreeModule, TreeService, VerticalAlign, ZoomType, getCellComponent };
|
|
13206
|
+
export { AccordionComponent, AccordionContentDirective, AccordionHeadComponent, AccordionItemComponent, AccordionModule, AggregationType, Align, Annotation, AreaDrawer, ArrayUtil, Axis, AxisOptions, AxisType, BarDrawer, BooleanCellComponent, BooleanFilter, BooleanFilterComponent, ButtonComponent, ButtonModule, CHECKBOX_CONTROL_VALUE_ACCESSOR, CellComponent, CellComponentBase, CellHostComponent, Chart3dComponent, Chart3dModule, Chart3dOptions, ChartBounds, ChartComponent, ChartModule, ChartOptions, CheckboxComponent, CheckboxModule, ClickOutsideDirective, ClickOutsideModule, ClickService, ColumnReorderEvent, ColumnResizeEvent, ContextMenuDirective, ContextMenuModule, CurrentModal, DATE_PICKER_CONTROL_VALUE_ACCESSOR, DAY_SELECT_CONTROL_VALUE_ACCESSOR, DateCellComponent, DateFilter, DateFilterComponent, DateFilterValue, DatePeriod, DatePickerComponent, DatePickerModule, DateTimeCellComponent, DateUtil, DaySelectComponent, DelimiterComponent, DelimiterModule, DetailComponentBase, DialogComponent, DialogService, DisableControlDirective, DisableControlModule, DomUtil, DragPointType, DragSortContainerDirective, DragSortItemDirective, DragSortModule, DropdownComponent, DropdownContentDirective, DropdownDirective, DropdownHeadDirective, DropdownModule, DynamicComponentModule, DynamicComponentService, DynamicContentBaseDirective, DynamicData, EditEvent, EditType, ExpandPanelComponent, ExpandPanelContentDirective, ExpandPanelHeadDirective, ExpandPanelModule, FileItemComponent, FileUploadAreaComponent, FileUploadModule, FilterBase, FilterComponentBase, FilterHostComponent, FilterItem, FilterModule, FilterPanelComponent, FilterState, FilterType, FormGroupTitleComponent, FormsUtil, GroupRowComponent, HeadCellComponentBase, HeadCellHostComponent, HighlightDirective, HighlightModule, HintDirective, HintModule, IconComponent, IconModule, IconService, IconSpriteDirective, InputComponent, InputModule, LegendType, LineDrawer, ListCellComponent, ListFilter, ListFilterComponent, ListFilterType, LoaderDirective, LoaderModule, MONTH_PICKER_CONTROL_VALUE_ACCESSOR, Message, MessageComponent, MessageHostComponent, MessageModule, MessageService, ModalCloseReason, ModalContainerComponent, ModalInstance, ModalModule, ModalService, MonthPickerComponent, NoAutofillDirective, NoAutofillModule, NumberPipe, NumberPipeModule, NumericCellComponent, NumericFilter, NumericFilterComponent, NumericFilterValue, OnlyNumberDirective, OnlyNumberModule, OverlayContainerService, PagerComponent, PagerModule, PagerState, PagerUtil, PanelComponent, PanelModule, PieDrawer, PlotBand, PlotLine, PopupContentComponent, PositionUtil, ProgressBarComponent, ProgressBarModule, PropertyGridComponent, PropertyGridModule, RadioButtonComponent, RadioComponent, RadioModule, ResizeDragDirective, ResizeDragModule, ResizePanelComponent, ResizePanelModule, SLIDER_CONTROL_VALUE_ACCESSOR, SWITCH_CONTROL_VALUE_ACCESSOR, Scale, ScaleType, ScatterDrawer, SelectComponent, SelectModule, SelectOptionDirective, SelectType, SelectValueDirective, Series, SeriesType, SidebarComponent, SidebarModule, SidebarPosition, SortEvent, SortParam, SplineDrawer, StateUtil, StringCellComponent, StringFilter, StringFilterComponent, StringFilterType, StringUtil, SwitchButtonComponent, SwitchComponent, SwitchModule, TOGGLE_CONTROL_VALUE_ACCESSOR, TabComponent, TabContentDirective, TabTitleDirective, TableBodyComponent, TableColumn, TableColumnStore, TableComponent, TableContextMenuConfig, TableHeadComponent, TableModule, TableRow, TableService, TableUtil, TabsComponent, TabsModule, TetaChart, TetaContentRef, TetaSize, TetaTemplateDirective, TetaTemplateModule, TextFieldComponent, ThemeSwitchComponent, ThemeSwitchModule, ThemeSwitchService, ToggleComponent, ToggleModule, ToolbarComponent, ToolbarModule, TooltipDirective, TooltipModule, TooltipOptions, TreeComponent, TreeItemToggleComponent, TreeModule, TreeService, VerticalAlign, ZoomType, getCellComponent };
|
|
13203
13207
|
//# sourceMappingURL=tetacom-ng-components.mjs.map
|