igniteui-angular 12.3.27 → 12.3.30
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/igniteui-angular.umd.js +294 -170
- package/bundles/igniteui-angular.umd.js.map +1 -1
- package/esm2015/lib/grids/api.service.js +3 -4
- package/esm2015/lib/grids/columns/column.component.js +5 -5
- package/esm2015/lib/grids/common/crud.service.js +3 -3
- package/esm2015/lib/grids/common/events.js +1 -1
- package/esm2015/lib/grids/grid/grid.component.js +11 -11
- package/esm2015/lib/grids/grid-base.directive.js +83 -85
- package/esm2015/lib/grids/grid-mrl-navigation.service.js +2 -2
- package/esm2015/lib/grids/grid-public-row.js +3 -3
- package/esm2015/lib/grids/grouping/group-by-area.directive.js +1 -1
- package/esm2015/lib/grids/grouping/tree-grid-group-by-area.component.js +6 -6
- package/esm2015/lib/grids/hierarchical-grid/hierarchical-grid-base.directive.js +4 -5
- package/esm2015/lib/grids/hierarchical-grid/hierarchical-grid.component.js +25 -14
- package/esm2015/lib/grids/hierarchical-grid/row-island.component.js +7 -11
- package/esm2015/lib/grids/state.directive.js +12 -9
- package/esm2015/lib/grids/summaries/grid-summary.service.js +5 -5
- package/esm2015/lib/grids/tree-grid/tree-grid.component.js +25 -9
- package/esm2015/lib/services/exporter-common/base-export-service.js +3 -3
- package/esm2015/lib/simple-combo/simple-combo.component.js +2 -2
- package/esm2015/lib/splitter/splitter-pane/splitter-pane.component.js +58 -6
- package/esm2015/lib/splitter/splitter.component.js +22 -3
- package/esm2015/lib/tree/tree.component.js +30 -1
- package/fesm2015/igniteui-angular.js +289 -167
- package/fesm2015/igniteui-angular.js.map +1 -1
- package/igniteui-angular.metadata.json +1 -1
- package/lib/grids/common/events.d.ts +1 -0
- package/lib/grids/grid-base.directive.d.ts +9 -13
- package/lib/grids/hierarchical-grid/hierarchical-grid.component.d.ts +2 -1
- package/lib/grids/hierarchical-grid/row-island.component.d.ts +1 -0
- package/lib/grids/tree-grid/tree-grid.component.d.ts +2 -2
- package/lib/splitter/splitter-pane/splitter-pane.component.d.ts +19 -5
- package/lib/tree/tree.component.d.ts +29 -0
- package/package.json +1 -1
|
@@ -7464,8 +7464,8 @@
|
|
|
7464
7464
|
if (isAddRow) {
|
|
7465
7465
|
this.endAddRow();
|
|
7466
7466
|
if (commit) {
|
|
7467
|
-
this.grid.rowAddedNotifier.next({ data: args.newValue });
|
|
7468
|
-
this.grid.rowAdded.emit({ data: args.newValue });
|
|
7467
|
+
this.grid.rowAddedNotifier.next({ data: args.newValue, owner: this.grid });
|
|
7468
|
+
this.grid.rowAdded.emit({ data: args.newValue, owner: this.grid });
|
|
7469
7469
|
}
|
|
7470
7470
|
}
|
|
7471
7471
|
return args;
|
|
@@ -7658,7 +7658,7 @@
|
|
|
7658
7658
|
this.destroyMap = new Map();
|
|
7659
7659
|
}
|
|
7660
7660
|
GridBaseAPIService.prototype.get_column_by_name = function (name) {
|
|
7661
|
-
return this.grid.
|
|
7661
|
+
return this.grid.columns.find(function (col) { return col.field === name; });
|
|
7662
7662
|
};
|
|
7663
7663
|
GridBaseAPIService.prototype.get_summary_data = function () {
|
|
7664
7664
|
var grid = this.grid;
|
|
@@ -7930,8 +7930,7 @@
|
|
|
7930
7930
|
return;
|
|
7931
7931
|
}
|
|
7932
7932
|
var record = data[index];
|
|
7933
|
-
|
|
7934
|
-
grid.rowDeletedNotifier.next({ data: data[index] });
|
|
7933
|
+
grid.rowDeletedNotifier.next({ data: data[index], owner: grid });
|
|
7935
7934
|
this.deleteRowFromData(rowId, index);
|
|
7936
7935
|
if (grid.selectionService.isRowSelected(rowId)) {
|
|
7937
7936
|
grid.selectionService.deselectRow(rowId);
|
|
@@ -11855,8 +11854,7 @@
|
|
|
11855
11854
|
IgxColumnComponent.prototype.move = function (index) {
|
|
11856
11855
|
var _this = this;
|
|
11857
11856
|
var target;
|
|
11858
|
-
var
|
|
11859
|
-
var columns = grid.columnList.filter(function (c) { return c.visibleIndex > -1; });
|
|
11857
|
+
var columns = this.grid.columns.filter(function (c) { return c.visibleIndex > -1; });
|
|
11860
11858
|
// grid last visible index
|
|
11861
11859
|
var li = columns.map(function (c) { return c.visibleIndex; }).reduce(function (a, b) { return Math.max(a, b); });
|
|
11862
11860
|
var parent = this.parent;
|
|
@@ -11874,7 +11872,8 @@
|
|
|
11874
11872
|
/* eslint-enable max-len */
|
|
11875
11873
|
if (isPreceding) {
|
|
11876
11874
|
columns = columns.filter(function (c) { return c.visibleIndex > _this.visibleIndex; });
|
|
11877
|
-
target = columns.find(function (c) { return c.level === _this.level &&
|
|
11875
|
+
target = columns.find(function (c) { return c.level === _this.level &&
|
|
11876
|
+
c.visibleIndex + c.calcChildren() - _this.calcChildren() === index; });
|
|
11878
11877
|
}
|
|
11879
11878
|
else {
|
|
11880
11879
|
columns = columns.filter(function (c) { return c.visibleIndex < _this.visibleIndex; });
|
|
@@ -11884,7 +11883,7 @@
|
|
|
11884
11883
|
return;
|
|
11885
11884
|
}
|
|
11886
11885
|
var pos = isPreceding ? DropPosition.AfterDropTarget : DropPosition.BeforeDropTarget;
|
|
11887
|
-
grid.moveColumn(this, target, pos);
|
|
11886
|
+
this.grid.moveColumn(this, target, pos);
|
|
11888
11887
|
};
|
|
11889
11888
|
/**
|
|
11890
11889
|
* No children for the column, so will returns 1 or 0, if the column is hidden.
|
|
@@ -12900,7 +12899,7 @@
|
|
|
12900
12899
|
throw Error('No options provided!');
|
|
12901
12900
|
}
|
|
12902
12901
|
this.options = options;
|
|
12903
|
-
var columns = grid.
|
|
12902
|
+
var columns = grid.columns;
|
|
12904
12903
|
if (this.options.ignoreMultiColumnHeaders) {
|
|
12905
12904
|
columns = columns.filter(function (col) { return col.children === undefined; });
|
|
12906
12905
|
}
|
|
@@ -13658,7 +13657,7 @@
|
|
|
13658
13657
|
columnList = this.getAutoGeneratedColumns(islandData);
|
|
13659
13658
|
}
|
|
13660
13659
|
else {
|
|
13661
|
-
var islandColumnList = island.
|
|
13660
|
+
var islandColumnList = island.columns;
|
|
13662
13661
|
columnList = this.getColumns(islandColumnList);
|
|
13663
13662
|
}
|
|
13664
13663
|
this._ownersMap.set(island, columnList);
|
|
@@ -41503,7 +41502,7 @@
|
|
|
41503
41502
|
};
|
|
41504
41503
|
/** @hidden @internal */
|
|
41505
41504
|
IgxSimpleComboComponent.prototype.onBlur = function () {
|
|
41506
|
-
if (this.collapsed) {
|
|
41505
|
+
if (this.collapsed && !this.selectedItem) {
|
|
41507
41506
|
this.clearOnBlur();
|
|
41508
41507
|
}
|
|
41509
41508
|
_super.prototype.onBlur.call(this);
|
|
@@ -49494,7 +49493,7 @@
|
|
|
49494
49493
|
this.removeSummaries(rowID);
|
|
49495
49494
|
}
|
|
49496
49495
|
if (args.rowID !== undefined && args.rowID !== null) {
|
|
49497
|
-
var columnName = args.cellID ? this.grid.
|
|
49496
|
+
var columnName = args.cellID ? this.grid.columns.find(function (col) { return col.index === args.cellID.columnID; }).field : undefined;
|
|
49498
49497
|
if (columnName && this.grid.rowEditable) {
|
|
49499
49498
|
return;
|
|
49500
49499
|
}
|
|
@@ -49552,7 +49551,7 @@
|
|
|
49552
49551
|
return this.summaryHeight = 0;
|
|
49553
49552
|
}
|
|
49554
49553
|
var maxSummaryLength = 0;
|
|
49555
|
-
this.grid.
|
|
49554
|
+
this.grid.columns.filter(function (col) { return col.hasSummary && !col.hidden; }).forEach(function (column) {
|
|
49556
49555
|
var getCurrentSummaryColumn = column.summaries.operate([], [], column.field).length;
|
|
49557
49556
|
if (getCurrentSummaryColumn) {
|
|
49558
49557
|
if (maxSummaryLength < getCurrentSummaryColumn) {
|
|
@@ -49574,7 +49573,7 @@
|
|
|
49574
49573
|
if (!this.hasSummarizedColumns || !data) {
|
|
49575
49574
|
return rowSummaries;
|
|
49576
49575
|
}
|
|
49577
|
-
this.grid.
|
|
49576
|
+
this.grid.columns.filter(function (col) { return col.hasSummary; }).forEach(function (column) {
|
|
49578
49577
|
if (!rowSummaries.get(column.field)) {
|
|
49579
49578
|
var summaryResult = column.summaries.operate(data.map(function (r) { return resolveNestedPath(r, column.field); }), data, column.field, _this.grid.locale, column.pipeArgs);
|
|
49580
49579
|
rowSummaries.set(column.field, summaryResult);
|
|
@@ -49610,7 +49609,7 @@
|
|
|
49610
49609
|
};
|
|
49611
49610
|
Object.defineProperty(IgxGridSummaryService.prototype, "hasSummarizedColumns", {
|
|
49612
49611
|
get: function () {
|
|
49613
|
-
var summarizedColumns = this.grid.
|
|
49612
|
+
var summarizedColumns = this.grid.columns.filter(function (col) { return col.hasSummary && !col.hidden; });
|
|
49614
49613
|
return summarizedColumns.length > 0;
|
|
49615
49614
|
},
|
|
49616
49615
|
enumerable: false,
|
|
@@ -57140,8 +57139,8 @@
|
|
|
57140
57139
|
get: function () {
|
|
57141
57140
|
if (this._maxLevelHeaderDepth === null) {
|
|
57142
57141
|
this._maxLevelHeaderDepth = this.hasColumnLayouts ?
|
|
57143
|
-
this.
|
|
57144
|
-
this.
|
|
57142
|
+
this._columns.reduce(function (acc, col) { return Math.max(acc, col.rowStart); }, 0) :
|
|
57143
|
+
this._columns.reduce(function (acc, col) { return Math.max(acc, col.level); }, 0);
|
|
57145
57144
|
}
|
|
57146
57145
|
return this._maxLevelHeaderDepth;
|
|
57147
57146
|
},
|
|
@@ -57158,7 +57157,7 @@
|
|
|
57158
57157
|
* ``
|
|
57159
57158
|
*/
|
|
57160
57159
|
get: function () {
|
|
57161
|
-
return this.
|
|
57160
|
+
return this._columns.filter(function (col) { return col.columnGroup === false && col.hidden === true; }).length;
|
|
57162
57161
|
},
|
|
57163
57162
|
enumerable: false,
|
|
57164
57163
|
configurable: true
|
|
@@ -57978,8 +57977,8 @@
|
|
|
57978
57977
|
_this.notifyChanges(true);
|
|
57979
57978
|
_this.cdr.detectChanges();
|
|
57980
57979
|
});
|
|
57981
|
-
this.verticalScrollContainer.contentSizeChange.pipe(operators.filter(function () { return !_this._init; }), destructor).subscribe(function () {
|
|
57982
|
-
_this.notifyChanges();
|
|
57980
|
+
this.verticalScrollContainer.contentSizeChange.pipe(operators.filter(function () { return !_this._init; }), operators.throttleTime(30), destructor).subscribe(function () {
|
|
57981
|
+
_this.notifyChanges(true);
|
|
57983
57982
|
});
|
|
57984
57983
|
this.onDensityChanged.pipe(destructor).subscribe(function () {
|
|
57985
57984
|
_this.crudService.endEdit(false);
|
|
@@ -58005,14 +58004,14 @@
|
|
|
58005
58004
|
* @internal
|
|
58006
58005
|
*/
|
|
58007
58006
|
IgxGridBaseDirective.prototype.resetColumnsCaches = function () {
|
|
58008
|
-
this.
|
|
58007
|
+
this._columns.forEach(function (column) { return column.resetCaches(); });
|
|
58009
58008
|
};
|
|
58010
58009
|
/**
|
|
58011
58010
|
* @hidden @internal
|
|
58012
58011
|
*/
|
|
58013
58012
|
IgxGridBaseDirective.prototype.generateRowID = function () {
|
|
58014
58013
|
var _this = this;
|
|
58015
|
-
var primaryColumn = this.
|
|
58014
|
+
var primaryColumn = this._columns.find(function (col) { return col.field === _this.primaryKey; });
|
|
58016
58015
|
var idType = this.data.length ?
|
|
58017
58016
|
this.resolveDataTypes(this.data[0][this.primaryKey]) : primaryColumn ? primaryColumn.dataType : 'string';
|
|
58018
58017
|
return idType === 'string' ? uuid.v4() : FAKE_ROW_ID--;
|
|
@@ -58080,7 +58079,7 @@
|
|
|
58080
58079
|
this.resetColumnCollections();
|
|
58081
58080
|
this.resetCachedWidths();
|
|
58082
58081
|
this.hasVisibleColumns = undefined;
|
|
58083
|
-
this._columnGroups = this.
|
|
58082
|
+
this._columnGroups = this._columns.some(function (col) { return col.columnGroup; });
|
|
58084
58083
|
};
|
|
58085
58084
|
/**
|
|
58086
58085
|
* @hidden
|
|
@@ -58315,7 +58314,7 @@
|
|
|
58315
58314
|
* ```
|
|
58316
58315
|
*/
|
|
58317
58316
|
IgxGridBaseDirective.prototype.toggleColumnVisibility = function (args) {
|
|
58318
|
-
var col = args.column ? this.
|
|
58317
|
+
var col = args.column ? this._columns.find(function (c) { return c === args.column; }) : undefined;
|
|
58319
58318
|
if (!col) {
|
|
58320
58319
|
return;
|
|
58321
58320
|
}
|
|
@@ -58593,17 +58592,6 @@
|
|
|
58593
58592
|
configurable: true
|
|
58594
58593
|
});
|
|
58595
58594
|
Object.defineProperty(IgxGridBaseDirective.prototype, "columns", {
|
|
58596
|
-
/**
|
|
58597
|
-
* @hidden
|
|
58598
|
-
* @internal
|
|
58599
|
-
*/
|
|
58600
|
-
get: function () {
|
|
58601
|
-
return this._columns;
|
|
58602
|
-
},
|
|
58603
|
-
enumerable: false,
|
|
58604
|
-
configurable: true
|
|
58605
|
-
});
|
|
58606
|
-
Object.defineProperty(IgxGridBaseDirective.prototype, "columnsCollection", {
|
|
58607
58595
|
/**
|
|
58608
58596
|
* Gets an array of `IgxColumnComponent`s.
|
|
58609
58597
|
*
|
|
@@ -58613,7 +58601,7 @@
|
|
|
58613
58601
|
* ```
|
|
58614
58602
|
*/
|
|
58615
58603
|
get: function () {
|
|
58616
|
-
return this.
|
|
58604
|
+
return this._columns || [];
|
|
58617
58605
|
},
|
|
58618
58606
|
enumerable: false,
|
|
58619
58607
|
configurable: true
|
|
@@ -58695,7 +58683,7 @@
|
|
|
58695
58683
|
* @param name
|
|
58696
58684
|
*/
|
|
58697
58685
|
IgxGridBaseDirective.prototype.getColumnByName = function (name) {
|
|
58698
|
-
return this.
|
|
58686
|
+
return this._columns.find(function (col) { return col.field === name; });
|
|
58699
58687
|
};
|
|
58700
58688
|
IgxGridBaseDirective.prototype.getColumnByVisibleIndex = function (index) {
|
|
58701
58689
|
return this.visibleColumns.find(function (col) { return !col.columnGroup && !col.columnLayout &&
|
|
@@ -58714,7 +58702,7 @@
|
|
|
58714
58702
|
if (this._visibleColumns.length) {
|
|
58715
58703
|
return this._visibleColumns;
|
|
58716
58704
|
}
|
|
58717
|
-
this._visibleColumns = this.
|
|
58705
|
+
this._visibleColumns = this._columns.filter(function (c) { return !c.hidden; });
|
|
58718
58706
|
return this._visibleColumns;
|
|
58719
58707
|
},
|
|
58720
58708
|
enumerable: false,
|
|
@@ -58873,7 +58861,7 @@
|
|
|
58873
58861
|
* @internal
|
|
58874
58862
|
*/
|
|
58875
58863
|
get: function () {
|
|
58876
|
-
return this.rowEditable && this.dataView.length === 0 && this.
|
|
58864
|
+
return this.rowEditable && this.dataView.length === 0 && this._columns.length > 0;
|
|
58877
58865
|
},
|
|
58878
58866
|
enumerable: false,
|
|
58879
58867
|
configurable: true
|
|
@@ -58884,7 +58872,7 @@
|
|
|
58884
58872
|
* @internal
|
|
58885
58873
|
*/
|
|
58886
58874
|
get: function () {
|
|
58887
|
-
return this.rowDraggable && this.
|
|
58875
|
+
return this.rowDraggable && this._columns.length > this.hiddenColumnsCount;
|
|
58888
58876
|
},
|
|
58889
58877
|
enumerable: false,
|
|
58890
58878
|
configurable: true
|
|
@@ -58925,12 +58913,12 @@
|
|
|
58925
58913
|
var index = pos === DropPosition.AfterDropTarget ? unpinnedIndex + 1 : unpinnedIndex;
|
|
58926
58914
|
columnPinStateChanged = column.unpin(index);
|
|
58927
58915
|
}
|
|
58928
|
-
if (target.pinned && column.pinned && !columnPinStateChanged) {
|
|
58929
|
-
|
|
58930
|
-
}
|
|
58931
|
-
if (!target.pinned && !column.pinned && !columnPinStateChanged) {
|
|
58932
|
-
|
|
58933
|
-
}
|
|
58916
|
+
// if (target.pinned && column.pinned && !columnPinStateChanged) {
|
|
58917
|
+
// this._reorderColumns(column, target, pos, this._pinnedColumns);
|
|
58918
|
+
// }
|
|
58919
|
+
// if (!target.pinned && !column.pinned && !columnPinStateChanged) {
|
|
58920
|
+
// this._reorderColumns(column, target, pos, this._unpinnedColumns);
|
|
58921
|
+
// }
|
|
58934
58922
|
this._moveColumns(column, target, pos);
|
|
58935
58923
|
this._columnsReordered(column);
|
|
58936
58924
|
};
|
|
@@ -58993,7 +58981,7 @@
|
|
|
58993
58981
|
// commit pending states prior to adding a row
|
|
58994
58982
|
this.crudService.endEdit(true);
|
|
58995
58983
|
this.gridAPI.addRowToData(data);
|
|
58996
|
-
this.rowAddedNotifier.next({ data: data });
|
|
58984
|
+
this.rowAddedNotifier.next({ data: data, owner: this });
|
|
58997
58985
|
this.pipeTrigger++;
|
|
58998
58986
|
this.notifyChanges();
|
|
58999
58987
|
};
|
|
@@ -59020,7 +59008,8 @@
|
|
|
59020
59008
|
rowID: rowId,
|
|
59021
59009
|
cancel: false,
|
|
59022
59010
|
rowData: this.getRowData(rowId),
|
|
59023
|
-
oldValue: null
|
|
59011
|
+
oldValue: null,
|
|
59012
|
+
owner: this
|
|
59024
59013
|
};
|
|
59025
59014
|
this.rowDelete.emit(args);
|
|
59026
59015
|
if (args.cancel) {
|
|
@@ -59028,8 +59017,7 @@
|
|
|
59028
59017
|
}
|
|
59029
59018
|
var record = this.gridAPI.deleteRowById(rowId);
|
|
59030
59019
|
if (record !== null && record !== undefined) {
|
|
59031
|
-
|
|
59032
|
-
this.rowDeleted.emit({ data: record });
|
|
59020
|
+
this.rowDeleted.emit({ data: record, owner: this });
|
|
59033
59021
|
}
|
|
59034
59022
|
return record;
|
|
59035
59023
|
};
|
|
@@ -59048,7 +59036,7 @@
|
|
|
59048
59036
|
*/
|
|
59049
59037
|
IgxGridBaseDirective.prototype.updateCell = function (value, rowSelector, column) {
|
|
59050
59038
|
if (this.isDefined(this.primaryKey)) {
|
|
59051
|
-
var col = this.
|
|
59039
|
+
var col = this._columns.find(function (c) { return c.field === column; });
|
|
59052
59040
|
if (col) {
|
|
59053
59041
|
// Simplify
|
|
59054
59042
|
var rowData = this.gridAPI.getRowData(rowSelector);
|
|
@@ -59531,7 +59519,7 @@
|
|
|
59531
59519
|
* ```
|
|
59532
59520
|
*/
|
|
59533
59521
|
get: function () {
|
|
59534
|
-
return this.
|
|
59522
|
+
return this._columns.some(function (col) { return col.sortable; });
|
|
59535
59523
|
},
|
|
59536
59524
|
enumerable: false,
|
|
59537
59525
|
configurable: true
|
|
@@ -59546,7 +59534,7 @@
|
|
|
59546
59534
|
* ```
|
|
59547
59535
|
*/
|
|
59548
59536
|
get: function () {
|
|
59549
|
-
return this.
|
|
59537
|
+
return this._columns.some(function (col) { return col.editable; });
|
|
59550
59538
|
},
|
|
59551
59539
|
enumerable: false,
|
|
59552
59540
|
configurable: true
|
|
@@ -59561,7 +59549,7 @@
|
|
|
59561
59549
|
* ```
|
|
59562
59550
|
*/
|
|
59563
59551
|
get: function () {
|
|
59564
|
-
return this.
|
|
59552
|
+
return this._columns.some(function (col) { return col.filterable; });
|
|
59565
59553
|
},
|
|
59566
59554
|
enumerable: false,
|
|
59567
59555
|
configurable: true
|
|
@@ -59576,7 +59564,7 @@
|
|
|
59576
59564
|
* ```
|
|
59577
59565
|
*/
|
|
59578
59566
|
get: function () {
|
|
59579
|
-
var summarizedColumns = this.
|
|
59567
|
+
var summarizedColumns = this._columns.filter(function (col) { return col.hasSummary && !col.hidden; });
|
|
59580
59568
|
return summarizedColumns.length > 0;
|
|
59581
59569
|
},
|
|
59582
59570
|
enumerable: false,
|
|
@@ -59598,7 +59586,7 @@
|
|
|
59598
59586
|
*/
|
|
59599
59587
|
get: function () {
|
|
59600
59588
|
if (this._hasVisibleColumns === undefined) {
|
|
59601
|
-
return this.
|
|
59589
|
+
return this._columns ? this._columns.some(function (c) { return !c.hidden; }) : false;
|
|
59602
59590
|
}
|
|
59603
59591
|
return this._hasVisibleColumns;
|
|
59604
59592
|
},
|
|
@@ -59618,7 +59606,7 @@
|
|
|
59618
59606
|
* ```
|
|
59619
59607
|
*/
|
|
59620
59608
|
get: function () {
|
|
59621
|
-
return this.
|
|
59609
|
+
return this.columns && this.columns.some(function (col) { return col.movable; });
|
|
59622
59610
|
},
|
|
59623
59611
|
enumerable: false,
|
|
59624
59612
|
configurable: true
|
|
@@ -59648,7 +59636,7 @@
|
|
|
59648
59636
|
* ```
|
|
59649
59637
|
*/
|
|
59650
59638
|
get: function () {
|
|
59651
|
-
return !!this.
|
|
59639
|
+
return !!this._columns.some(function (col) { return col.columnLayout; });
|
|
59652
59640
|
},
|
|
59653
59641
|
enumerable: false,
|
|
59654
59642
|
configurable: true
|
|
@@ -60178,7 +60166,7 @@
|
|
|
60178
60166
|
* ```
|
|
60179
60167
|
*/
|
|
60180
60168
|
IgxGridBaseDirective.prototype.selectAllColumns = function () {
|
|
60181
|
-
this.selectColumns(this.
|
|
60169
|
+
this.selectColumns(this._columns.filter(function (c) { return !c.columnGroup; }));
|
|
60182
60170
|
};
|
|
60183
60171
|
/**
|
|
60184
60172
|
*
|
|
@@ -60303,7 +60291,7 @@
|
|
|
60303
60291
|
var _a;
|
|
60304
60292
|
var totalItems = (_a = this.totalItemCount) !== null && _a !== void 0 ? _a : this.dataView.length - 1;
|
|
60305
60293
|
if (rowIndex < 0 || rowIndex > totalItems || (visibleColIndex !== -1
|
|
60306
|
-
&& this.
|
|
60294
|
+
&& this._columns.map(function (col) { return col.visibleIndex; }).indexOf(visibleColIndex) === -1)) {
|
|
60307
60295
|
return;
|
|
60308
60296
|
}
|
|
60309
60297
|
if (this.dataView.slice(rowIndex, rowIndex + 1).find(function (rec) { return rec.expression || rec.childGridsData; })) {
|
|
@@ -60350,7 +60338,7 @@
|
|
|
60350
60338
|
*/
|
|
60351
60339
|
IgxGridBaseDirective.prototype.getNextCell = function (currRowIndex, curVisibleColIndex, callback) {
|
|
60352
60340
|
if (callback === void 0) { callback = null; }
|
|
60353
|
-
var columns = this.
|
|
60341
|
+
var columns = this._columns.filter(function (col) { return !col.columnGroup && col.visibleIndex >= 0; });
|
|
60354
60342
|
var dataViewIndex = this._getDataViewIndex(currRowIndex);
|
|
60355
60343
|
if (!this.isValidPosition(dataViewIndex, curVisibleColIndex)) {
|
|
60356
60344
|
return { rowIndex: currRowIndex, visibleColumnIndex: curVisibleColIndex };
|
|
@@ -60386,7 +60374,7 @@
|
|
|
60386
60374
|
*/
|
|
60387
60375
|
IgxGridBaseDirective.prototype.getPreviousCell = function (currRowIndex, curVisibleColIndex, callback) {
|
|
60388
60376
|
if (callback === void 0) { callback = null; }
|
|
60389
|
-
var columns = this.
|
|
60377
|
+
var columns = this._columns.filter(function (col) { return !col.columnGroup && col.visibleIndex >= 0; });
|
|
60390
60378
|
var dataViewIndex = this._getDataViewIndex(currRowIndex);
|
|
60391
60379
|
if (!this.isValidPosition(dataViewIndex, curVisibleColIndex)) {
|
|
60392
60380
|
return { rowIndex: currRowIndex, visibleColumnIndex: curVisibleColIndex };
|
|
@@ -60657,21 +60645,6 @@
|
|
|
60657
60645
|
console.warn('The row with the specified PK or index is outside of the current data view.');
|
|
60658
60646
|
}
|
|
60659
60647
|
};
|
|
60660
|
-
/**
|
|
60661
|
-
* Update internal column's collection.
|
|
60662
|
-
*
|
|
60663
|
-
* @hidden
|
|
60664
|
-
*/
|
|
60665
|
-
IgxGridBaseDirective.prototype.updateColumns = function (newColumns) {
|
|
60666
|
-
var _this = this;
|
|
60667
|
-
// update internal collections to retain order.
|
|
60668
|
-
this._pinnedColumns = newColumns
|
|
60669
|
-
.filter(function (c) { return c.pinned; }).sort(function (a, b) { return _this._pinnedColumns.indexOf(a) - _this._pinnedColumns.indexOf(b); });
|
|
60670
|
-
this._unpinnedColumns = newColumns.filter(function (c) { return !c.pinned; });
|
|
60671
|
-
this.columnList.reset(newColumns);
|
|
60672
|
-
this.columnList.notifyOnChanges();
|
|
60673
|
-
this._columns = this.columnList.toArray();
|
|
60674
|
-
};
|
|
60675
60648
|
/**
|
|
60676
60649
|
* Enters add mode by spawning the UI at the specified index.
|
|
60677
60650
|
*
|
|
@@ -60689,6 +60662,19 @@
|
|
|
60689
60662
|
}
|
|
60690
60663
|
return this.beginAddRowById(this.gridAPI.get_rec_id_by_index(index - 1, this.dataView));
|
|
60691
60664
|
};
|
|
60665
|
+
/**
|
|
60666
|
+
* Update internal column's collection.
|
|
60667
|
+
*
|
|
60668
|
+
* @hidden
|
|
60669
|
+
*/
|
|
60670
|
+
IgxGridBaseDirective.prototype.updateColumns = function (newColumns) {
|
|
60671
|
+
// update internal collections to retain order.
|
|
60672
|
+
this._pinnedColumns = newColumns
|
|
60673
|
+
.filter(function (c) { return c.pinned; });
|
|
60674
|
+
this._unpinnedColumns = newColumns.filter(function (c) { return !c.pinned; });
|
|
60675
|
+
this._columns = newColumns;
|
|
60676
|
+
this.resetCaches();
|
|
60677
|
+
};
|
|
60692
60678
|
IgxGridBaseDirective.prototype.beginAddRowForIndex = function (index, asChild) {
|
|
60693
60679
|
if (asChild === void 0) { asChild = false; }
|
|
60694
60680
|
var row = index == null ?
|
|
@@ -60841,7 +60827,7 @@
|
|
|
60841
60827
|
if (!this.columnWidthSetByUser) {
|
|
60842
60828
|
this._columnWidth = this.width !== null ? this.getPossibleColumnWidth() : MINIMUM_COLUMN_WIDTH + 'px';
|
|
60843
60829
|
}
|
|
60844
|
-
this.
|
|
60830
|
+
this._columns.forEach(function (column) {
|
|
60845
60831
|
if (_this.hasColumnLayouts && parseInt(_this._columnWidth, 10)) {
|
|
60846
60832
|
var columnWidthCombined = parseInt(_this._columnWidth, 10) * (column.colEnd ? column.colEnd - column.colStart : 1);
|
|
60847
60833
|
column.defaultWidth = columnWidthCombined + 'px';
|
|
@@ -60893,7 +60879,8 @@
|
|
|
60893
60879
|
* @hidden
|
|
60894
60880
|
*/
|
|
60895
60881
|
IgxGridBaseDirective.prototype._moveColumns = function (from, to, pos) {
|
|
60896
|
-
var
|
|
60882
|
+
var orderedList = this._pinnedColumns.concat(this._unpinnedColumns);
|
|
60883
|
+
var list = orderedList;
|
|
60897
60884
|
this._reorderColumns(from, to, pos, list);
|
|
60898
60885
|
var newList = this._resetColumnList(list);
|
|
60899
60886
|
this.updateColumns(newList);
|
|
@@ -60903,7 +60890,7 @@
|
|
|
60903
60890
|
*/
|
|
60904
60891
|
IgxGridBaseDirective.prototype._resetColumnList = function (list) {
|
|
60905
60892
|
if (!list) {
|
|
60906
|
-
list = this.
|
|
60893
|
+
list = this._columns;
|
|
60907
60894
|
}
|
|
60908
60895
|
var newList = [];
|
|
60909
60896
|
list.filter(function (c) { return c.level === 0; }).forEach(function (p) {
|
|
@@ -60950,7 +60937,10 @@
|
|
|
60950
60937
|
if (this.autoGenerate) {
|
|
60951
60938
|
this.autogenerateColumns();
|
|
60952
60939
|
}
|
|
60953
|
-
|
|
60940
|
+
else {
|
|
60941
|
+
this._columns = this.getColumnList();
|
|
60942
|
+
}
|
|
60943
|
+
this.initColumns(this._columns, function (col) { return _this.columnInit.emit(col); });
|
|
60954
60944
|
this.columnListDiffer.diff(this.columnList);
|
|
60955
60945
|
this.columnList.changes
|
|
60956
60946
|
.pipe(operators.takeUntil(this.destroy$))
|
|
@@ -60958,6 +60948,9 @@
|
|
|
60958
60948
|
_this.onColumnsChanged(change);
|
|
60959
60949
|
});
|
|
60960
60950
|
};
|
|
60951
|
+
IgxGridBaseDirective.prototype.getColumnList = function () {
|
|
60952
|
+
return this.columnList.toArray();
|
|
60953
|
+
};
|
|
60961
60954
|
/**
|
|
60962
60955
|
* @hidden
|
|
60963
60956
|
*/
|
|
@@ -61000,10 +60993,10 @@
|
|
|
61000
60993
|
IgxGridBaseDirective.prototype.onColumnsChanged = function (change) {
|
|
61001
60994
|
var _this = this;
|
|
61002
60995
|
var diff = this.columnListDiffer.diff(change);
|
|
61003
|
-
if (this.autoGenerate && this.
|
|
60996
|
+
if (this.autoGenerate && this._columns.length === 0 && this._autoGeneratedCols.length > 0) {
|
|
61004
60997
|
// In Ivy if there are nested conditional templates the content children are re-evaluated
|
|
61005
60998
|
// hence autogenerated columns are cleared and need to be reset.
|
|
61006
|
-
this.
|
|
60999
|
+
this.updateColumns(this._autoGeneratedCols);
|
|
61007
61000
|
return;
|
|
61008
61001
|
}
|
|
61009
61002
|
if (diff) {
|
|
@@ -61018,7 +61011,7 @@
|
|
|
61018
61011
|
_this._unpinnedColumns.push(record.item);
|
|
61019
61012
|
}
|
|
61020
61013
|
});
|
|
61021
|
-
this.initColumns(this.columnList, function (col) { return _this.columnInit.emit(col); });
|
|
61014
|
+
this.initColumns(this.columnList.toArray(), function (col) { return _this.columnInit.emit(col); });
|
|
61022
61015
|
diff.forEachRemovedItem(function (record) {
|
|
61023
61016
|
var isColumnGroup = record.item instanceof IgxColumnGroupComponent;
|
|
61024
61017
|
if (!isColumnGroup) {
|
|
@@ -61233,10 +61226,12 @@
|
|
|
61233
61226
|
this.tbody.nativeElement.style.display = 'none';
|
|
61234
61227
|
var res = !this.nativeElement.parentElement ||
|
|
61235
61228
|
this.nativeElement.parentElement.clientHeight === 0 ||
|
|
61236
|
-
this.nativeElement.parentElement.clientHeight === renderedHeight
|
|
61229
|
+
this.nativeElement.parentElement.clientHeight === renderedHeight;
|
|
61230
|
+
if (!this.platform.isChromium && !this.platform.isFirefox) {
|
|
61237
61231
|
// If grid causes the parent container to extend (for example when container is flex)
|
|
61238
61232
|
// we should always auto-size since the actual size of the container will continuously change as the grid renders elements.
|
|
61239
|
-
this.checkContainerSizeChange();
|
|
61233
|
+
res = this.checkContainerSizeChange();
|
|
61234
|
+
}
|
|
61240
61235
|
this.tbody.nativeElement.style.display = '';
|
|
61241
61236
|
return res;
|
|
61242
61237
|
};
|
|
@@ -61324,7 +61319,7 @@
|
|
|
61324
61319
|
columns.push(ref.instance);
|
|
61325
61320
|
});
|
|
61326
61321
|
this._autoGeneratedCols = columns;
|
|
61327
|
-
this.
|
|
61322
|
+
this.updateColumns(columns);
|
|
61328
61323
|
if (data && data.length > 0) {
|
|
61329
61324
|
this.shouldGenerate = false;
|
|
61330
61325
|
}
|
|
@@ -61352,10 +61347,10 @@
|
|
|
61352
61347
|
IgxGridBaseDirective.prototype.initColumns = function (collection, cb) {
|
|
61353
61348
|
var _this = this;
|
|
61354
61349
|
if (cb === void 0) { cb = null; }
|
|
61355
|
-
this._columnGroups =
|
|
61350
|
+
this._columnGroups = collection.some(function (col) { return col.columnGroup; });
|
|
61356
61351
|
if (this.hasColumnLayouts) {
|
|
61357
61352
|
// Set overall row layout size
|
|
61358
|
-
|
|
61353
|
+
collection.forEach(function (col) {
|
|
61359
61354
|
if (col.columnLayout) {
|
|
61360
61355
|
var layoutSize = col.children ?
|
|
61361
61356
|
col.children.reduce(function (acc, val) { return Math.max(val.rowStart + val.gridRowSpan - 1, acc); }, 1) :
|
|
@@ -61367,18 +61362,17 @@
|
|
|
61367
61362
|
if (this.hasColumnLayouts && this.hasColumnGroups) {
|
|
61368
61363
|
// invalid configuration - multi-row and column groups
|
|
61369
61364
|
// remove column groups
|
|
61370
|
-
var columnLayoutColumns =
|
|
61371
|
-
|
|
61365
|
+
var columnLayoutColumns = collection.filter(function (col) { return col.columnLayout || col.columnLayoutChild; });
|
|
61366
|
+
collection = columnLayoutColumns;
|
|
61372
61367
|
}
|
|
61373
61368
|
this._maxLevelHeaderDepth = null;
|
|
61374
|
-
this._columns = this.columnList.toArray();
|
|
61375
61369
|
collection.forEach(function (column) {
|
|
61376
61370
|
column.defaultWidth = _this.columnWidthSetByUser ? _this._columnWidth : column.defaultWidth ? column.defaultWidth : '';
|
|
61377
61371
|
if (cb) {
|
|
61378
61372
|
cb(column);
|
|
61379
61373
|
}
|
|
61380
61374
|
});
|
|
61381
|
-
this.
|
|
61375
|
+
this.updateColumns(collection);
|
|
61382
61376
|
if (this.hasColumnLayouts) {
|
|
61383
61377
|
collection.forEach(function (column) {
|
|
61384
61378
|
column.populateVisibleIndexes();
|
|
@@ -61390,13 +61384,11 @@
|
|
|
61390
61384
|
*/
|
|
61391
61385
|
IgxGridBaseDirective.prototype.reinitPinStates = function () {
|
|
61392
61386
|
var _this = this;
|
|
61393
|
-
this._pinnedColumns = this.
|
|
61394
|
-
.filter(function (c) { return c.pinned; })
|
|
61395
|
-
|
|
61396
|
-
|
|
61397
|
-
|
|
61398
|
-
.sort(function (a, b) { return _this._unpinnedColumns.findIndex(function (x) { return x.field === a.field; }) -
|
|
61399
|
-
_this._unpinnedColumns.findIndex(function (x) { return x.field === b.field; }); });
|
|
61387
|
+
this._pinnedColumns = this._columns
|
|
61388
|
+
.filter(function (c) { return c.pinned; }).sort(function (a, b) { return _this._pinnedColumns.indexOf(a) - _this._pinnedColumns.indexOf(b); });
|
|
61389
|
+
this._unpinnedColumns = this.hasColumnGroups ? this._columns.filter(function (c) { return !c.pinned; }) :
|
|
61390
|
+
this._columns.filter(function (c) { return !c.pinned; })
|
|
61391
|
+
.sort(function (a, b) { return _this._unpinnedColumns.indexOf(a) - _this._unpinnedColumns.indexOf(b); });
|
|
61400
61392
|
};
|
|
61401
61393
|
IgxGridBaseDirective.prototype.extractDataFromSelection = function (source, formatters, headers, columnData) {
|
|
61402
61394
|
var e_4, _h, e_5, _j, e_6, _k;
|
|
@@ -61785,7 +61777,7 @@
|
|
|
61785
61777
|
IgxGridBaseDirective.prototype._columnsReordered = function (column) {
|
|
61786
61778
|
this.notifyChanges();
|
|
61787
61779
|
if (this.hasColumnLayouts) {
|
|
61788
|
-
this.
|
|
61780
|
+
this._columns.filter(function (x) { return x.columnLayout; }).forEach(function (x) { return x.populateVisibleIndexes(); });
|
|
61789
61781
|
}
|
|
61790
61782
|
// after reordering is done reset cached column collections.
|
|
61791
61783
|
this.resetColumnCollections();
|
|
@@ -61953,7 +61945,7 @@
|
|
|
61953
61945
|
};
|
|
61954
61946
|
IgxGridBaseDirective.prototype.isValidPosition = function (rowIndex, colIndex) {
|
|
61955
61947
|
var rows = this.summariesRowList.filter(function (s) { return s.index !== 0; }).concat(this.rowList.toArray()).length;
|
|
61956
|
-
var cols = this.
|
|
61948
|
+
var cols = this._columns.filter(function (col) { return !col.columnGroup && col.visibleIndex >= 0 && !col.hidden; }).length;
|
|
61957
61949
|
if (rows < 1 || cols < 1) {
|
|
61958
61950
|
return false;
|
|
61959
61951
|
}
|
|
@@ -62573,7 +62565,7 @@
|
|
|
62573
62565
|
get: function () {
|
|
62574
62566
|
var _this = this;
|
|
62575
62567
|
var res = [];
|
|
62576
|
-
this.grid.
|
|
62568
|
+
this.grid.columns.forEach(function (col) {
|
|
62577
62569
|
var cell = new IgxGridCell(_this.grid, _this.index, col.field);
|
|
62578
62570
|
res.push(cell);
|
|
62579
62571
|
});
|
|
@@ -62953,7 +62945,7 @@
|
|
|
62953
62945
|
get: function () {
|
|
62954
62946
|
var _this = this;
|
|
62955
62947
|
var res = [];
|
|
62956
|
-
this.grid.
|
|
62948
|
+
this.grid.columns.forEach(function (col) {
|
|
62957
62949
|
var cell = new IgxGridCell(_this.grid, _this.index, col.field);
|
|
62958
62950
|
res.push(cell);
|
|
62959
62951
|
});
|
|
@@ -69155,7 +69147,7 @@
|
|
|
69155
69147
|
col.visibleIndex > _this.activeNode.column && col.colStart > _this.activeNode.layout.colStart; });
|
|
69156
69148
|
if (!column || (previous && this.activeNode.layout.colStart === 1)) {
|
|
69157
69149
|
var index_1 = previous ? parent.visibleIndex - 1 : parent.visibleIndex + 1;
|
|
69158
|
-
var children = this.grid.
|
|
69150
|
+
var children = this.grid.columns.find(function (cols) { return cols.columnLayout && cols.visibleIndex === index_1; }).children;
|
|
69159
69151
|
column = previous ? children.toArray().reverse().find(function (child) { return child.rowStart <= _this.activeNode.layout.rowStart; }) :
|
|
69160
69152
|
children.find(function (child) { return _this.rowEnd(child) > _this.activeNode.layout.rowStart && child.colStart === 1; });
|
|
69161
69153
|
}
|
|
@@ -69637,7 +69629,7 @@
|
|
|
69637
69629
|
// setter called before grid is registered in grid API service
|
|
69638
69630
|
this.sortingExpressions.unshift.apply(this.sortingExpressions, this._groupingExpressions);
|
|
69639
69631
|
}
|
|
69640
|
-
if (!this._init && JSON.stringify(oldExpressions) !== JSON.stringify(newExpressions) && this.
|
|
69632
|
+
if (!this._init && JSON.stringify(oldExpressions) !== JSON.stringify(newExpressions) && this._columns) {
|
|
69641
69633
|
var groupedCols_1 = [];
|
|
69642
69634
|
var ungroupedCols_1 = [];
|
|
69643
69635
|
var groupedColsArr = newExpressions.filter(function (obj) { return !oldExpressions.some(function (obj2) { return obj.fieldName === obj2.fieldName; }); });
|
|
@@ -69709,7 +69701,7 @@
|
|
|
69709
69701
|
else {
|
|
69710
69702
|
this.groupingDiffer = null;
|
|
69711
69703
|
}
|
|
69712
|
-
if (this.
|
|
69704
|
+
if (this._columns && this.groupingExpressions) {
|
|
69713
69705
|
this._setGroupColsVisibility(value);
|
|
69714
69706
|
}
|
|
69715
69707
|
this._hideGroupedColumns = value;
|
|
@@ -69775,7 +69767,7 @@
|
|
|
69775
69767
|
IgxGridComponent.prototype.getCellByColumnVisibleIndex = function (rowIndex, index) {
|
|
69776
69768
|
var _a;
|
|
69777
69769
|
var row = this.getRowByIndex(rowIndex);
|
|
69778
|
-
var column = this.
|
|
69770
|
+
var column = this._columns.find(function (col) { return col.visibleIndex === index; });
|
|
69779
69771
|
if (row && row instanceof IgxGridRow && !((_a = row.data) === null || _a === void 0 ? void 0 : _a.detailsData) && column) {
|
|
69780
69772
|
return new IgxGridCell(this, rowIndex, column.field);
|
|
69781
69773
|
}
|
|
@@ -70066,7 +70058,7 @@
|
|
|
70066
70058
|
* ```
|
|
70067
70059
|
*/
|
|
70068
70060
|
get: function () {
|
|
70069
|
-
return this.
|
|
70061
|
+
return this._columns.some(function (col) { return col.groupable && !col.columnGroup; });
|
|
70070
70062
|
},
|
|
70071
70063
|
enumerable: false,
|
|
70072
70064
|
configurable: true
|
|
@@ -70207,7 +70199,7 @@
|
|
|
70207
70199
|
this._groupRowTemplate = this.groupTemplate.template;
|
|
70208
70200
|
}
|
|
70209
70201
|
this.detailTemplate.changes.subscribe(function () { return _this.trackChanges = function (_, rec) { return ((rec === null || rec === void 0 ? void 0 : rec.detailsData) !== undefined ? rec.detailsData : rec); }; });
|
|
70210
|
-
if (this.hideGroupedColumns && this.
|
|
70202
|
+
if (this.hideGroupedColumns && this._columns && this.groupingExpressions) {
|
|
70211
70203
|
this._setGroupColsVisibility(this.hideGroupedColumns);
|
|
70212
70204
|
}
|
|
70213
70205
|
this._setupNavigationService();
|
|
@@ -70258,9 +70250,9 @@
|
|
|
70258
70250
|
*/
|
|
70259
70251
|
IgxGridComponent.prototype.ngDoCheck = function () {
|
|
70260
70252
|
var _this = this;
|
|
70261
|
-
if (this.groupingDiffer && this.
|
|
70253
|
+
if (this.groupingDiffer && this._columns && !this.hasColumnLayouts) {
|
|
70262
70254
|
var changes = this.groupingDiffer.diff(this.groupingExpressions);
|
|
70263
|
-
if (changes && this.
|
|
70255
|
+
if (changes && this._columns.length > 0) {
|
|
70264
70256
|
changes.forEachAddedItem(function (rec) {
|
|
70265
70257
|
var col = _this.getColumnByName(rec.item.fieldName);
|
|
70266
70258
|
if (col) {
|
|
@@ -70403,7 +70395,7 @@
|
|
|
70403
70395
|
IgxGridComponent.prototype.getCellByColumn = function (rowIndex, columnField) {
|
|
70404
70396
|
var _a;
|
|
70405
70397
|
var row = this.getRowByIndex(rowIndex);
|
|
70406
|
-
var column = this.
|
|
70398
|
+
var column = this._columns.find(function (col) { return col.field === columnField; });
|
|
70407
70399
|
if (row && row instanceof IgxGridRow && !((_a = row.data) === null || _a === void 0 ? void 0 : _a.detailsData) && column) {
|
|
70408
70400
|
if (this.pagingMode === 1 && this.gridAPI.grid.page !== 0) {
|
|
70409
70401
|
row.index = rowIndex + this.paginator.perPage * this.paginator.page;
|
|
@@ -70425,7 +70417,7 @@
|
|
|
70425
70417
|
*/
|
|
70426
70418
|
IgxGridComponent.prototype.getCellByKey = function (rowSelector, columnField) {
|
|
70427
70419
|
var row = this.getRowByKey(rowSelector);
|
|
70428
|
-
var column = this.
|
|
70420
|
+
var column = this._columns.find(function (col) { return col.field === columnField; });
|
|
70429
70421
|
if (row && column) {
|
|
70430
70422
|
return new IgxGridCell(this, row.index, columnField);
|
|
70431
70423
|
}
|
|
@@ -70542,7 +70534,7 @@
|
|
|
70542
70534
|
};
|
|
70543
70535
|
IgxGridComponent.prototype._setGroupColsVisibility = function (value) {
|
|
70544
70536
|
var _this = this;
|
|
70545
|
-
if (this.
|
|
70537
|
+
if (this._columns.length > 0 && !this.hasColumnLayouts) {
|
|
70546
70538
|
this.groupingExpressions.forEach(function (expr) {
|
|
70547
70539
|
var col = _this.getColumnByName(expr.fieldName);
|
|
70548
70540
|
col.hidden = value;
|
|
@@ -70756,6 +70748,9 @@
|
|
|
70756
70748
|
}
|
|
70757
70749
|
});
|
|
70758
70750
|
context.grid.updateColumns(newColumns);
|
|
70751
|
+
newColumns.forEach(function (col) {
|
|
70752
|
+
context.grid.columnInit.emit(col);
|
|
70753
|
+
});
|
|
70759
70754
|
}
|
|
70760
70755
|
},
|
|
70761
70756
|
groupBy: {
|
|
@@ -71002,17 +70997,14 @@
|
|
|
71002
70997
|
* The method that calls corresponding methods to restore features from the passed IGridState object.
|
|
71003
70998
|
*/
|
|
71004
70999
|
IgxGridStateDirective.prototype.restoreGridState = function (state, features) {
|
|
71005
|
-
var _this = this;
|
|
71006
71000
|
// TODO Notify the grid that columnList.changes is triggered by the state directive
|
|
71007
71001
|
// instead of piping it like below
|
|
71008
71002
|
var columns = 'columns';
|
|
71009
|
-
this.grid.columnList.changes.pipe(operators.delay(0), operators.take(1)).subscribe(function () {
|
|
71010
|
-
_this.featureKeys = _this.featureKeys.filter(function (f) { return f !== columns; });
|
|
71011
|
-
_this.restoreFeatures(state);
|
|
71012
|
-
});
|
|
71013
71003
|
this.applyFeatures(features);
|
|
71014
71004
|
if (this.featureKeys.includes(columns) && this.options[columns] && state[columns]) {
|
|
71015
71005
|
this.getFeature(columns).restoreFeatureState(this, state[columns]);
|
|
71006
|
+
this.featureKeys = this.featureKeys.filter(function (f) { return f !== columns; });
|
|
71007
|
+
this.restoreFeatures(state);
|
|
71016
71008
|
}
|
|
71017
71009
|
else {
|
|
71018
71010
|
this.restoreFeatures(state);
|
|
@@ -71076,8 +71068,8 @@
|
|
|
71076
71068
|
else {
|
|
71077
71069
|
var expr_1 = item;
|
|
71078
71070
|
var dataType = void 0;
|
|
71079
|
-
if (this_1.currGrid.
|
|
71080
|
-
dataType = this_1.currGrid.
|
|
71071
|
+
if (this_1.currGrid.columns.length > 0) {
|
|
71072
|
+
dataType = this_1.currGrid.columns.find(function (c) { return c.field === expr_1.fieldName; }).dataType;
|
|
71081
71073
|
}
|
|
71082
71074
|
else if (this_1.state.columns) {
|
|
71083
71075
|
dataType = this_1.state.columns.find(function (c) { return c.field === expr_1.fieldName; }).dataType;
|
|
@@ -71132,6 +71124,9 @@
|
|
|
71132
71124
|
case GridColumnDataType.Date:
|
|
71133
71125
|
filters = IgxDateFilteringOperand.instance();
|
|
71134
71126
|
break;
|
|
71127
|
+
case GridColumnDataType.DateTime:
|
|
71128
|
+
filters = IgxDateTimeFilteringOperand.instance();
|
|
71129
|
+
break;
|
|
71135
71130
|
case GridColumnDataType.String:
|
|
71136
71131
|
default:
|
|
71137
71132
|
filters = IgxStringFilteringOperand.instance();
|
|
@@ -73439,7 +73434,7 @@
|
|
|
73439
73434
|
return this._hideGroupedColumns;
|
|
73440
73435
|
},
|
|
73441
73436
|
set: function (value) {
|
|
73442
|
-
if (this.grid.
|
|
73437
|
+
if (this.grid.columns && this.expressions) {
|
|
73443
73438
|
this.setColumnsVisibility(value);
|
|
73444
73439
|
}
|
|
73445
73440
|
this._hideGroupedColumns = value;
|
|
@@ -73449,7 +73444,7 @@
|
|
|
73449
73444
|
});
|
|
73450
73445
|
IgxTreeGridGroupByAreaComponent.prototype.ngAfterContentInit = function () {
|
|
73451
73446
|
var _this = this;
|
|
73452
|
-
if (this.grid.
|
|
73447
|
+
if (this.grid.columns && this.expressions) {
|
|
73453
73448
|
this.groupingDiffer = this.differs.find(this.expressions).create();
|
|
73454
73449
|
this.updateColumnsVisibility();
|
|
73455
73450
|
}
|
|
@@ -73529,9 +73524,9 @@
|
|
|
73529
73524
|
};
|
|
73530
73525
|
IgxTreeGridGroupByAreaComponent.prototype.updateColumnsVisibility = function () {
|
|
73531
73526
|
var _this = this;
|
|
73532
|
-
if (this.groupingDiffer && this.grid.
|
|
73527
|
+
if (this.groupingDiffer && this.grid.columns && !this.grid.hasColumnLayouts) {
|
|
73533
73528
|
var changes = this.groupingDiffer.diff(this.expressions);
|
|
73534
|
-
if (changes && this.grid.
|
|
73529
|
+
if (changes && this.grid.columns.length > 0) {
|
|
73535
73530
|
changes.forEachAddedItem(function (rec) {
|
|
73536
73531
|
var col = _this.grid.getColumnByName(rec.item.fieldName);
|
|
73537
73532
|
col.hidden = _this.hideGroupedColumns;
|
|
@@ -73545,7 +73540,7 @@
|
|
|
73545
73540
|
};
|
|
73546
73541
|
IgxTreeGridGroupByAreaComponent.prototype.setColumnsVisibility = function (value) {
|
|
73547
73542
|
var _this = this;
|
|
73548
|
-
if (this.grid.
|
|
73543
|
+
if (this.grid.columns.length > 0 && !this.grid.hasColumnLayouts) {
|
|
73549
73544
|
this.expressions.forEach(function (expr) {
|
|
73550
73545
|
var col = _this.grid.getColumnByName(expr.fieldName);
|
|
73551
73546
|
col.hidden = value;
|
|
@@ -73796,7 +73791,7 @@
|
|
|
73796
73791
|
*/
|
|
73797
73792
|
IgxTreeGridComponent.prototype.getCellByColumnVisibleIndex = function (rowIndex, index) {
|
|
73798
73793
|
var row = this.getRowByIndex(rowIndex);
|
|
73799
|
-
var column = this.
|
|
73794
|
+
var column = this.columns.find(function (col) { return col.visibleIndex === index; });
|
|
73800
73795
|
if (row && row instanceof IgxTreeGridRow && column) {
|
|
73801
73796
|
return new IgxGridCell(this, rowIndex, column.field);
|
|
73802
73797
|
}
|
|
@@ -73952,7 +73947,7 @@
|
|
|
73952
73947
|
IgxTreeGridComponent.prototype.addRow = function (data, parentRowID) {
|
|
73953
73948
|
this.crudService.endEdit(true);
|
|
73954
73949
|
this.gridAPI.addRowToData(data, parentRowID);
|
|
73955
|
-
this.rowAddedNotifier.next({ data: data });
|
|
73950
|
+
this.rowAddedNotifier.next({ data: data, owner: this });
|
|
73956
73951
|
this.pipeTrigger++;
|
|
73957
73952
|
this.notifyChanges();
|
|
73958
73953
|
};
|
|
@@ -74062,7 +74057,22 @@
|
|
|
74062
74057
|
// if this is flat self-referencing data, and CascadeOnDelete is set to true
|
|
74063
74058
|
// and if we have transactions we should start pending transaction. This allows
|
|
74064
74059
|
// us in case of delete action to delete all child rows as single undo action
|
|
74065
|
-
|
|
74060
|
+
var args = {
|
|
74061
|
+
rowID: rowId,
|
|
74062
|
+
cancel: false,
|
|
74063
|
+
rowData: this.getRowData(rowId),
|
|
74064
|
+
oldValue: null,
|
|
74065
|
+
owner: this
|
|
74066
|
+
};
|
|
74067
|
+
this.rowDelete.emit(args);
|
|
74068
|
+
if (args.cancel) {
|
|
74069
|
+
return;
|
|
74070
|
+
}
|
|
74071
|
+
var record = this.gridAPI.deleteRowById(rowId);
|
|
74072
|
+
if (record !== null && record !== undefined) {
|
|
74073
|
+
this.rowDeleted.emit({ data: record, owner: this });
|
|
74074
|
+
}
|
|
74075
|
+
return record;
|
|
74066
74076
|
};
|
|
74067
74077
|
/**
|
|
74068
74078
|
* Returns the `IgxTreeGridRow` by index.
|
|
@@ -74143,7 +74153,7 @@
|
|
|
74143
74153
|
*/
|
|
74144
74154
|
IgxTreeGridComponent.prototype.getCellByColumn = function (rowIndex, columnField) {
|
|
74145
74155
|
var row = this.getRowByIndex(rowIndex);
|
|
74146
|
-
var column = this.
|
|
74156
|
+
var column = this.columns.find(function (col) { return col.field === columnField; });
|
|
74147
74157
|
if (row && row instanceof IgxTreeGridRow && column) {
|
|
74148
74158
|
return new IgxGridCell(this, rowIndex, columnField);
|
|
74149
74159
|
}
|
|
@@ -74162,7 +74172,7 @@
|
|
|
74162
74172
|
*/
|
|
74163
74173
|
IgxTreeGridComponent.prototype.getCellByKey = function (rowSelector, columnField) {
|
|
74164
74174
|
var row = this.getRowByKey(rowSelector);
|
|
74165
|
-
var column = this.
|
|
74175
|
+
var column = this.columns.find(function (col) { return col.field === columnField; });
|
|
74166
74176
|
if (row && column) {
|
|
74167
74177
|
return new IgxGridCell(this, row.index, columnField);
|
|
74168
74178
|
}
|
|
@@ -74222,7 +74232,7 @@
|
|
|
74222
74232
|
* ```
|
|
74223
74233
|
*/
|
|
74224
74234
|
get: function () {
|
|
74225
|
-
return this.
|
|
74235
|
+
return this.columns.some(function (col) { return col.groupable && !col.columnGroup; });
|
|
74226
74236
|
},
|
|
74227
74237
|
enumerable: false,
|
|
74228
74238
|
configurable: true
|
|
@@ -74319,8 +74329,8 @@
|
|
|
74319
74329
|
if (this.hasColumnLayouts) {
|
|
74320
74330
|
// invalid configuration - tree grid should not allow column layouts
|
|
74321
74331
|
// remove column layouts
|
|
74322
|
-
var nonColumnLayoutColumns = this.
|
|
74323
|
-
this.
|
|
74332
|
+
var nonColumnLayoutColumns = this.columns.filter(function (col) { return !col.columnLayout && !col.columnLayoutChild; });
|
|
74333
|
+
this.updateColumns(nonColumnLayoutColumns);
|
|
74324
74334
|
}
|
|
74325
74335
|
_super.prototype.initColumns.call(this, collection, cb);
|
|
74326
74336
|
};
|
|
@@ -74454,6 +74464,7 @@
|
|
|
74454
74464
|
{ provide: GridBaseAPIService, useClass: IgxTreeGridAPIService },
|
|
74455
74465
|
{ provide: IgxGridBaseDirective, useExisting: i0.forwardRef(function () { return IgxTreeGridComponent; }) },
|
|
74456
74466
|
IgxFilteringService,
|
|
74467
|
+
IgxColumnResizingService,
|
|
74457
74468
|
IgxForOfSyncService,
|
|
74458
74469
|
IgxForOfScrollSyncService
|
|
74459
74470
|
]
|
|
@@ -76103,7 +76114,7 @@
|
|
|
76103
76114
|
*/
|
|
76104
76115
|
get: function () {
|
|
76105
76116
|
if (this._maxLevelHeaderDepth === null) {
|
|
76106
|
-
this._maxLevelHeaderDepth = this.
|
|
76117
|
+
this._maxLevelHeaderDepth = this.columns.reduce(function (acc, col) { return Math.max(acc, col.level); }, 0);
|
|
76107
76118
|
}
|
|
76108
76119
|
return this._maxLevelHeaderDepth;
|
|
76109
76120
|
},
|
|
@@ -76158,13 +76169,12 @@
|
|
|
76158
76169
|
columns.push(ref.instance);
|
|
76159
76170
|
});
|
|
76160
76171
|
var result = flatten(columns);
|
|
76161
|
-
this.
|
|
76162
|
-
this.columnList.notifyOnChanges();
|
|
76172
|
+
this.updateColumns(result);
|
|
76163
76173
|
this.initPinning();
|
|
76164
76174
|
var factoryColumn = this.resolver.resolveComponentFactory(IgxColumnComponent);
|
|
76165
76175
|
var outputs = factoryColumn.outputs.filter(function (o) { return o.propName !== 'columnChange'; });
|
|
76166
76176
|
outputs.forEach(function (output) {
|
|
76167
|
-
_this.
|
|
76177
|
+
_this.columns.forEach(function (column) {
|
|
76168
76178
|
if (column[output.propName]) {
|
|
76169
76179
|
column[output.propName].pipe(operators.takeUntil(column.destroy$)).subscribe(function (args) {
|
|
76170
76180
|
var rowIslandColumn = _this.parentIsland.childColumns.find(function (col) { return col.field === column.field; });
|
|
@@ -76522,6 +76532,7 @@
|
|
|
76522
76532
|
* @hidden
|
|
76523
76533
|
*/
|
|
76524
76534
|
_this.rootGrid = null;
|
|
76535
|
+
_this._childColumns = [];
|
|
76525
76536
|
_this.layout_id = "igx-row-island-";
|
|
76526
76537
|
_this.isInit = false;
|
|
76527
76538
|
_this.hgridAPI = gridAPI;
|
|
@@ -76632,7 +76643,8 @@
|
|
|
76632
76643
|
var nestedColumns = this.children.map(function (layout) { return layout.columnList.toArray(); });
|
|
76633
76644
|
var colsArray = [].concat.apply([], nestedColumns);
|
|
76634
76645
|
var topCols = this.columnList.filter(function (item) { return colsArray.indexOf(item) === -1; });
|
|
76635
|
-
this.
|
|
76646
|
+
this._childColumns = topCols;
|
|
76647
|
+
this.updateColumns(this._childColumns);
|
|
76636
76648
|
this.columnList.changes.pipe(operators.takeUntil(this.destroy$)).subscribe(function () {
|
|
76637
76649
|
Promise.resolve().then(function () {
|
|
76638
76650
|
_this.updateColumnList();
|
|
@@ -76640,7 +76652,7 @@
|
|
|
76640
76652
|
});
|
|
76641
76653
|
// handle column changes so that they are passed to child grid instances when columnChange is emitted.
|
|
76642
76654
|
this.ri_columnListDiffer.diff(this.childColumns);
|
|
76643
|
-
this.
|
|
76655
|
+
this._childColumns.forEach(function (x) { return x.columnChange.pipe(operators.takeUntil(x.destroy$)).subscribe(function () { return _this.updateColumnList(); }); });
|
|
76644
76656
|
this.childColumns.changes.pipe(operators.takeUntil(this.destroy$)).subscribe(function (change) {
|
|
76645
76657
|
var diff = _this.ri_columnListDiffer.diff(change);
|
|
76646
76658
|
if (diff) {
|
|
@@ -76735,15 +76747,9 @@
|
|
|
76735
76747
|
}
|
|
76736
76748
|
return false;
|
|
76737
76749
|
});
|
|
76738
|
-
this.
|
|
76739
|
-
if (this.parentIsland) {
|
|
76740
|
-
this.parentIsland.columnList.notifyOnChanges();
|
|
76741
|
-
}
|
|
76742
|
-
else {
|
|
76743
|
-
this.rootGrid.columnList.notifyOnChanges();
|
|
76744
|
-
}
|
|
76750
|
+
this._childColumns = topCols;
|
|
76745
76751
|
this.rowIslandAPI.getChildGrids().forEach(function (grid) {
|
|
76746
|
-
grid.createColumnsList(_this.
|
|
76752
|
+
grid.createColumnsList(_this._childColumns);
|
|
76747
76753
|
if (!document.body.contains(grid.nativeElement)) {
|
|
76748
76754
|
grid.updateOnRender = true;
|
|
76749
76755
|
}
|
|
@@ -77011,7 +77017,7 @@
|
|
|
77011
77017
|
*/
|
|
77012
77018
|
IgxHierarchicalGridComponent.prototype.getCellByColumnVisibleIndex = function (rowIndex, index) {
|
|
77013
77019
|
var row = this.getRowByIndex(rowIndex);
|
|
77014
|
-
var column = this.
|
|
77020
|
+
var column = this.columns.find(function (col) { return col.visibleIndex === index; });
|
|
77015
77021
|
if (row && row instanceof IgxHierarchicalGridRow && column) {
|
|
77016
77022
|
return new IgxGridCell(this, rowIndex, column.field);
|
|
77017
77023
|
}
|
|
@@ -77270,7 +77276,7 @@
|
|
|
77270
77276
|
*/
|
|
77271
77277
|
IgxHierarchicalGridComponent.prototype.getCellByColumn = function (rowIndex, columnField) {
|
|
77272
77278
|
var row = this.getRowByIndex(rowIndex);
|
|
77273
|
-
var column = this.
|
|
77279
|
+
var column = this.columns.find(function (col) { return col.field === columnField; });
|
|
77274
77280
|
if (row && row instanceof IgxHierarchicalGridRow && column) {
|
|
77275
77281
|
return new IgxGridCell(this, rowIndex, columnField);
|
|
77276
77282
|
}
|
|
@@ -77289,7 +77295,7 @@
|
|
|
77289
77295
|
*/
|
|
77290
77296
|
IgxHierarchicalGridComponent.prototype.getCellByKey = function (rowSelector, columnField) {
|
|
77291
77297
|
var row = this.getRowByKey(rowSelector);
|
|
77292
|
-
var column = this.
|
|
77298
|
+
var column = this.columns.find(function (col) { return col.field === columnField; });
|
|
77293
77299
|
if (row && column) {
|
|
77294
77300
|
return new IgxGridCell(this, row.index, columnField);
|
|
77295
77301
|
}
|
|
@@ -77575,8 +77581,8 @@
|
|
|
77575
77581
|
if (this.hasColumnLayouts) {
|
|
77576
77582
|
// invalid configuration - hierarchical grid should not allow column layouts
|
|
77577
77583
|
// remove column layouts
|
|
77578
|
-
var nonColumnLayoutColumns = this.
|
|
77579
|
-
this.
|
|
77584
|
+
var nonColumnLayoutColumns = this.columns.filter(function (col) { return !col.columnLayout && !col.columnLayoutChild; });
|
|
77585
|
+
this.updateColumns(nonColumnLayoutColumns);
|
|
77580
77586
|
}
|
|
77581
77587
|
_super.prototype.initColumns.call(this, collection, cb);
|
|
77582
77588
|
};
|
|
@@ -77584,17 +77590,26 @@
|
|
|
77584
77590
|
if (this.parentIsland && this.parentIsland.childColumns.length > 0 && !this.autoGenerate) {
|
|
77585
77591
|
this.createColumnsList(this.parentIsland.childColumns.toArray());
|
|
77586
77592
|
}
|
|
77587
|
-
|
|
77593
|
+
else {
|
|
77594
|
+
_super.prototype.setupColumns.call(this);
|
|
77595
|
+
}
|
|
77596
|
+
};
|
|
77597
|
+
IgxHierarchicalGridComponent.prototype.getColumnList = function () {
|
|
77598
|
+
var childLayouts = this.parent ? this.childLayoutList : this.allLayoutList;
|
|
77599
|
+
var nestedColumns = childLayouts.map(function (layout) { return layout.columnList.toArray(); });
|
|
77600
|
+
var colsArray = [].concat.apply([], nestedColumns);
|
|
77601
|
+
if (colsArray.length > 0) {
|
|
77602
|
+
var topCols = this.columnList.filter(function (item) { return colsArray.indexOf(item) === -1; });
|
|
77603
|
+
return topCols;
|
|
77604
|
+
}
|
|
77605
|
+
else {
|
|
77606
|
+
return this.columnList.toArray();
|
|
77607
|
+
}
|
|
77588
77608
|
};
|
|
77589
77609
|
IgxHierarchicalGridComponent.prototype.onColumnsChanged = function (change) {
|
|
77590
77610
|
var _this = this;
|
|
77591
77611
|
Promise.resolve().then(function () {
|
|
77592
77612
|
_this.updateColumnList();
|
|
77593
|
-
var cols = change.filter(function (c) { return c.gridAPI.grid === _this; });
|
|
77594
|
-
if (cols.length > 0 || _this.autoGenerate) {
|
|
77595
|
-
_this.columnList.reset(cols);
|
|
77596
|
-
_super.prototype.onColumnsChanged.call(_this, _this.columnList);
|
|
77597
|
-
}
|
|
77598
77613
|
});
|
|
77599
77614
|
};
|
|
77600
77615
|
IgxHierarchicalGridComponent.prototype._shouldAutoSize = function (renderedHeight) {
|
|
@@ -77611,8 +77626,8 @@
|
|
|
77611
77626
|
var colLength = this.columnList.length;
|
|
77612
77627
|
if (colsArray.length > 0) {
|
|
77613
77628
|
var topCols = this.columnList.filter(function (item) { return colsArray.indexOf(item) === -1; });
|
|
77614
|
-
this.
|
|
77615
|
-
if (recalcColSizes && this.
|
|
77629
|
+
this.updateColumns(topCols);
|
|
77630
|
+
if (recalcColSizes && this.columns.length !== colLength) {
|
|
77616
77631
|
this.calculateGridSizes(false);
|
|
77617
77632
|
}
|
|
77618
77633
|
}
|
|
@@ -77646,6 +77661,7 @@
|
|
|
77646
77661
|
{ provide: GridBaseAPIService, useClass: IgxHierarchicalGridAPIService },
|
|
77647
77662
|
{ provide: IgxGridBaseDirective, useExisting: i0.forwardRef(function () { return IgxHierarchicalGridComponent; }) },
|
|
77648
77663
|
IgxGridSummaryService,
|
|
77664
|
+
IgxColumnResizingService,
|
|
77649
77665
|
IgxFilteringService,
|
|
77650
77666
|
IgxHierarchicalGridNavigationService,
|
|
77651
77667
|
IgxForOfSyncService,
|
|
@@ -82889,17 +82905,75 @@
|
|
|
82889
82905
|
this.overflow = 'auto';
|
|
82890
82906
|
/**
|
|
82891
82907
|
* @hidden @internal
|
|
82892
|
-
*
|
|
82908
|
+
* Get/Sets the `minWidth` properties of the current pane.
|
|
82909
|
+
*/
|
|
82910
|
+
this.minWidth = '0';
|
|
82911
|
+
/**
|
|
82912
|
+
* @hidden @internal
|
|
82913
|
+
* Get/Sets the `maxWidth` properties of the current pane.
|
|
82893
82914
|
*/
|
|
82894
|
-
this.
|
|
82915
|
+
this.maxWidth = '100%';
|
|
82895
82916
|
/**
|
|
82896
82917
|
* @hidden @internal
|
|
82897
|
-
* Gets/Sets the `
|
|
82918
|
+
* Gets/Sets the `minHeight` properties of the current pane.
|
|
82919
|
+
*/
|
|
82920
|
+
this.minHeight = '0';
|
|
82921
|
+
/**
|
|
82922
|
+
* @hidden @internal
|
|
82923
|
+
* Gets/Sets the `maxHeight` properties of the current `IgxSplitterPaneComponent`.
|
|
82898
82924
|
*/
|
|
82899
82925
|
this.maxHeight = '100%';
|
|
82900
82926
|
this._size = 'auto';
|
|
82901
82927
|
this._collapsed = false;
|
|
82902
82928
|
}
|
|
82929
|
+
Object.defineProperty(IgxSplitterPaneComponent.prototype, "minSize", {
|
|
82930
|
+
/**
|
|
82931
|
+
* Gets/Sets the minimum allowed size of the current pane.
|
|
82932
|
+
*
|
|
82933
|
+
* @example
|
|
82934
|
+
* ```html
|
|
82935
|
+
* <igx-splitter>
|
|
82936
|
+
* <igx-splitter-pane [minSize]='minSize'>...</igx-splitter-pane>
|
|
82937
|
+
* </igx-splitter>
|
|
82938
|
+
* ```
|
|
82939
|
+
*/
|
|
82940
|
+
get: function () {
|
|
82941
|
+
return this._minSize;
|
|
82942
|
+
},
|
|
82943
|
+
set: function (value) {
|
|
82944
|
+
this._minSize = value;
|
|
82945
|
+
if (this.owner) {
|
|
82946
|
+
this.owner.panes.notifyOnChanges();
|
|
82947
|
+
}
|
|
82948
|
+
},
|
|
82949
|
+
enumerable: false,
|
|
82950
|
+
configurable: true
|
|
82951
|
+
});
|
|
82952
|
+
;
|
|
82953
|
+
Object.defineProperty(IgxSplitterPaneComponent.prototype, "maxSize", {
|
|
82954
|
+
/**
|
|
82955
|
+
* Gets/Set the maximum allowed size of the current pane.
|
|
82956
|
+
*
|
|
82957
|
+
* @example
|
|
82958
|
+
* ```html
|
|
82959
|
+
* <igx-splitter>
|
|
82960
|
+
* <igx-splitter-pane [maxSize]='maxSize'>...</igx-splitter-pane>
|
|
82961
|
+
* </igx-splitter>
|
|
82962
|
+
* ```
|
|
82963
|
+
*/
|
|
82964
|
+
get: function () {
|
|
82965
|
+
return this._maxSize;
|
|
82966
|
+
},
|
|
82967
|
+
set: function (value) {
|
|
82968
|
+
this._maxSize = value;
|
|
82969
|
+
if (this.owner) {
|
|
82970
|
+
this.owner.panes.notifyOnChanges();
|
|
82971
|
+
}
|
|
82972
|
+
},
|
|
82973
|
+
enumerable: false,
|
|
82974
|
+
configurable: true
|
|
82975
|
+
});
|
|
82976
|
+
;
|
|
82903
82977
|
Object.defineProperty(IgxSplitterPaneComponent.prototype, "size", {
|
|
82904
82978
|
/**
|
|
82905
82979
|
* Gets/Sets the size of the current pane.
|
|
@@ -83036,8 +83110,10 @@
|
|
|
83036
83110
|
collapsedChange: [{ type: i0.Output }],
|
|
83037
83111
|
order: [{ type: i0.HostBinding, args: ['style.order',] }],
|
|
83038
83112
|
overflow: [{ type: i0.HostBinding, args: ['style.overflow',] }],
|
|
83039
|
-
|
|
83040
|
-
|
|
83113
|
+
minWidth: [{ type: i0.HostBinding, args: ['style.min-width',] }],
|
|
83114
|
+
maxWidth: [{ type: i0.HostBinding, args: ['style.max-width',] }],
|
|
83115
|
+
minHeight: [{ type: i0.HostBinding, args: ['style.min-height',] }],
|
|
83116
|
+
maxHeight: [{ type: i0.HostBinding, args: ['style.max-height',] }],
|
|
83041
83117
|
size: [{ type: i0.Input }],
|
|
83042
83118
|
flex: [{ type: i0.HostBinding, args: ['style.flex',] }],
|
|
83043
83119
|
collapsed: [{ type: i0.Input }]
|
|
@@ -83139,8 +83215,10 @@
|
|
|
83139
83215
|
return this._type;
|
|
83140
83216
|
},
|
|
83141
83217
|
set: function (value) {
|
|
83218
|
+
var _a;
|
|
83142
83219
|
this._type = value;
|
|
83143
83220
|
this.resetPaneSizes();
|
|
83221
|
+
(_a = this.panes) === null || _a === void 0 ? void 0 : _a.notifyOnChanges();
|
|
83144
83222
|
},
|
|
83145
83223
|
enumerable: false,
|
|
83146
83224
|
configurable: true
|
|
@@ -83254,7 +83332,18 @@
|
|
|
83254
83332
|
*/
|
|
83255
83333
|
IgxSplitterComponent.prototype.initPanes = function () {
|
|
83256
83334
|
var _this = this;
|
|
83257
|
-
this.panes.forEach(function (pane) {
|
|
83335
|
+
this.panes.forEach(function (pane) {
|
|
83336
|
+
var _a, _b, _c, _d;
|
|
83337
|
+
pane.owner = _this;
|
|
83338
|
+
if (_this.type === exports.SplitterType.Horizontal) {
|
|
83339
|
+
pane.minWidth = (_a = pane.minSize) !== null && _a !== void 0 ? _a : '0';
|
|
83340
|
+
pane.maxWidth = (_b = pane.maxSize) !== null && _b !== void 0 ? _b : '100%';
|
|
83341
|
+
}
|
|
83342
|
+
else {
|
|
83343
|
+
pane.minHeight = (_c = pane.minSize) !== null && _c !== void 0 ? _c : '0';
|
|
83344
|
+
pane.maxHeight = (_d = pane.maxSize) !== null && _d !== void 0 ? _d : '100%';
|
|
83345
|
+
}
|
|
83346
|
+
});
|
|
83258
83347
|
this.assignFlexOrder();
|
|
83259
83348
|
if (this.panes.filter(function (x) { return x.collapsed; }).length > 0) {
|
|
83260
83349
|
// if any panes are collapsed, reset sizes.
|
|
@@ -83268,7 +83357,13 @@
|
|
|
83268
83357
|
IgxSplitterComponent.prototype.resetPaneSizes = function () {
|
|
83269
83358
|
if (this.panes) {
|
|
83270
83359
|
// if type is changed runtime, should reset sizes.
|
|
83271
|
-
this.panes.forEach(function (x) {
|
|
83360
|
+
this.panes.forEach(function (x) {
|
|
83361
|
+
x.size = 'auto';
|
|
83362
|
+
x.minWidth = '0';
|
|
83363
|
+
x.maxWidth = '100%';
|
|
83364
|
+
x.minHeight = '0';
|
|
83365
|
+
x.maxHeight = '100%';
|
|
83366
|
+
});
|
|
83272
83367
|
}
|
|
83273
83368
|
};
|
|
83274
83369
|
/**
|
|
@@ -86087,6 +86182,35 @@
|
|
|
86087
86182
|
selector: '[igxTreeExpandIndicator]'
|
|
86088
86183
|
},] }
|
|
86089
86184
|
];
|
|
86185
|
+
/**
|
|
86186
|
+
* IgxTreeComponent allows a developer to show a set of nodes in a hierarchical fashion.
|
|
86187
|
+
*
|
|
86188
|
+
* @igxModule IgxTreeModule
|
|
86189
|
+
* @igxKeywords tree
|
|
86190
|
+
* @igxTheme igx-tree-theme
|
|
86191
|
+
* @igxGroup Grids & Lists
|
|
86192
|
+
*
|
|
86193
|
+
* @remark
|
|
86194
|
+
* The Angular Tree Component allows users to represent hierarchical data in a tree-view structure,
|
|
86195
|
+
* maintaining parent-child relationships, as well as to define static tree-view structure without a corresponding data model.
|
|
86196
|
+
* Its primary purpose is to allow end-users to visualize and navigate within hierarchical data structures.
|
|
86197
|
+
* The Ignite UI for Angular Tree Component also provides load on demand capabilities, item activation,
|
|
86198
|
+
* bi-state and cascading selection of items through built-in checkboxes, built-in keyboard navigation and more.
|
|
86199
|
+
*
|
|
86200
|
+
* @example
|
|
86201
|
+
* ```html
|
|
86202
|
+
* <igx-tree>
|
|
86203
|
+
* <igx-tree-node>
|
|
86204
|
+
* I am a parent node 1
|
|
86205
|
+
* <igx-tree-node>
|
|
86206
|
+
* I am a child node 1
|
|
86207
|
+
* </igx-tree-node>
|
|
86208
|
+
* ...
|
|
86209
|
+
* </igx-tree-node>
|
|
86210
|
+
* ...
|
|
86211
|
+
* </igx-tree>
|
|
86212
|
+
* ```
|
|
86213
|
+
*/
|
|
86090
86214
|
var IgxTreeComponent = /** @class */ (function (_super) {
|
|
86091
86215
|
__extends(IgxTreeComponent, _super);
|
|
86092
86216
|
function IgxTreeComponent(navService, selectionService, treeService, element, _displayDensityOptions) {
|