@syncfusion/ej2-treegrid 27.1.53 → 27.1.56
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/dist/ej2-treegrid.min.js +2 -2
- package/dist/ej2-treegrid.umd.min.js +2 -2
- package/dist/ej2-treegrid.umd.min.js.map +1 -1
- package/dist/es6/ej2-treegrid.es2015.js +31 -24
- package/dist/es6/ej2-treegrid.es2015.js.map +1 -1
- package/dist/es6/ej2-treegrid.es5.js +31 -24
- package/dist/es6/ej2-treegrid.es5.js.map +1 -1
- package/dist/global/ej2-treegrid.min.js +2 -2
- package/dist/global/ej2-treegrid.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +8 -8
- package/src/treegrid/actions/detail-row.js +1 -1
- package/src/treegrid/actions/freeze-column.js +3 -3
- package/src/treegrid/base/data.js +1 -1
- package/src/treegrid/base/treegrid.d.ts +1 -0
- package/src/treegrid/base/treegrid.js +22 -15
- package/src/treegrid/renderer/render.js +4 -4
- package/styles/bootstrap-dark-lite.css +5 -1
- package/styles/bootstrap-dark.css +5 -1
- package/styles/bootstrap-lite.css +5 -1
- package/styles/bootstrap.css +5 -1
- package/styles/bootstrap4-lite.css +5 -1
- package/styles/bootstrap4.css +5 -1
- package/styles/bootstrap5-dark-lite.css +5 -1
- package/styles/bootstrap5-dark.css +5 -1
- package/styles/bootstrap5-lite.css +5 -1
- package/styles/bootstrap5.3-lite.css +5 -1
- package/styles/bootstrap5.3.css +5 -1
- package/styles/bootstrap5.css +5 -1
- package/styles/fabric-dark-lite.css +5 -1
- package/styles/fabric-dark.css +5 -1
- package/styles/fabric-lite.css +5 -1
- package/styles/fabric.css +5 -1
- package/styles/fluent-dark-lite.css +5 -1
- package/styles/fluent-dark.css +5 -1
- package/styles/fluent-lite.css +5 -1
- package/styles/fluent.css +5 -1
- package/styles/fluent2-lite.css +5 -1
- package/styles/fluent2.css +5 -1
- package/styles/highcontrast-light-lite.css +5 -1
- package/styles/highcontrast-light.css +5 -1
- package/styles/highcontrast-lite.css +5 -1
- package/styles/highcontrast.css +5 -1
- package/styles/material-dark-lite.css +5 -1
- package/styles/material-dark.css +5 -1
- package/styles/material-lite.css +5 -1
- package/styles/material.css +5 -1
- package/styles/material3-dark-lite.css +5 -1
- package/styles/material3-dark.css +5 -1
- package/styles/material3-lite.css +5 -1
- package/styles/material3.css +5 -1
- package/styles/tailwind-dark-lite.css +5 -1
- package/styles/tailwind-dark.css +5 -1
- package/styles/tailwind-lite.css +5 -1
- package/styles/tailwind.css +5 -1
- package/styles/treegrid/_layout.scss +6 -1
- package/styles/treegrid/bootstrap-dark.css +5 -1
- package/styles/treegrid/bootstrap.css +5 -1
- package/styles/treegrid/bootstrap4.css +5 -1
- package/styles/treegrid/bootstrap5-dark.css +5 -1
- package/styles/treegrid/bootstrap5.3.css +5 -1
- package/styles/treegrid/bootstrap5.css +5 -1
- package/styles/treegrid/fabric-dark.css +5 -1
- package/styles/treegrid/fabric.css +5 -1
- package/styles/treegrid/fluent-dark.css +5 -1
- package/styles/treegrid/fluent.css +5 -1
- package/styles/treegrid/fluent2.css +5 -1
- package/styles/treegrid/highcontrast-light.css +5 -1
- package/styles/treegrid/highcontrast.css +5 -1
- package/styles/treegrid/material-dark.css +5 -1
- package/styles/treegrid/material.css +5 -1
- package/styles/treegrid/material3-dark.css +5 -1
- package/styles/treegrid/material3.css +5 -1
- package/styles/treegrid/tailwind-dark.css +5 -1
- package/styles/treegrid/tailwind.css +5 -1
|
@@ -1693,7 +1693,7 @@ var Render = /** @__PURE__ @class */ (function () {
|
|
|
1693
1693
|
parentData[this.parent.expandStateMapping]) || this.parent.enableCollapseAll)) ||
|
|
1694
1694
|
!getExpandStatus(this.parent, args.data, this.parent.grid.getCurrentViewRecords());
|
|
1695
1695
|
if (collapsed && !isNullOrUndefined(args.row)) {
|
|
1696
|
-
args.row
|
|
1696
|
+
this.parent['toggleRowVisibility'](args.row, 'e-childrow-hidden');
|
|
1697
1697
|
var rowsObj = this.parent.grid.getRowsObject();
|
|
1698
1698
|
if (!this.parent.grid.isFrozenGrid() && !isNullOrUndefined(args.row.getAttribute('data-uid'))) {
|
|
1699
1699
|
rowsObj.filter(function (e) { return e.uid === args.row.getAttribute('data-uid'); })[0].visible = false;
|
|
@@ -1706,8 +1706,8 @@ var Render = /** @__PURE__ @class */ (function () {
|
|
|
1706
1706
|
return getValue(proxy_1.idMapping, rec) === getValue(proxy_1.parentIdMapping, data);
|
|
1707
1707
|
});
|
|
1708
1708
|
if (parentrec.length > 0 && !parentrec[0].isSummaryRow && !isNullOrUndefined(args.row)) {
|
|
1709
|
-
var display = parentrec[0].expanded ? '
|
|
1710
|
-
args.row
|
|
1709
|
+
var display = parentrec[0].expanded ? 'e-childrow-visible' : 'e-childrow-hidden';
|
|
1710
|
+
this.parent['toggleRowVisibility'](args.row, display);
|
|
1711
1711
|
}
|
|
1712
1712
|
}
|
|
1713
1713
|
//addClass([args.row], 'e-gridrowindex' + index + 'level' + (<ITreeData>args.data).level);
|
|
@@ -1724,7 +1724,7 @@ var Render = /** @__PURE__ @class */ (function () {
|
|
|
1724
1724
|
}
|
|
1725
1725
|
if (this.parent.enableCollapseAll && this.parent.initialRender) {
|
|
1726
1726
|
if (!isNullOrUndefined(data.parentItem)) {
|
|
1727
|
-
args.row
|
|
1727
|
+
this.parent['toggleRowVisibility'](args.row, 'e-childrow-hidden');
|
|
1728
1728
|
}
|
|
1729
1729
|
}
|
|
1730
1730
|
}
|
|
@@ -2346,7 +2346,7 @@ var DataManipulation = /** @__PURE__ @class */ (function () {
|
|
|
2346
2346
|
rowDetails.record.expanded = true;
|
|
2347
2347
|
}
|
|
2348
2348
|
for (var i = 0; i < rowDetails.rows.length; i++) {
|
|
2349
|
-
rowDetails.rows[parseInt(i.toString(), 10)]
|
|
2349
|
+
this.parent['toggleRowVisibility'](rowDetails.rows[parseInt(i.toString(), 10)], 'e-childrow-visible');
|
|
2350
2350
|
if (!this.parent.loadChildOnDemand) {
|
|
2351
2351
|
var targetEle = rowDetails.rows[parseInt(i.toString(), 10)].getElementsByClassName('e-treegridcollapse')[0];
|
|
2352
2352
|
childRecord = this.parent.rowTemplate ?
|
|
@@ -4155,7 +4155,7 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
4155
4155
|
TreeGrid.prototype.findnextRowElement = function (summaryRowElement) {
|
|
4156
4156
|
var rowElement = summaryRowElement.nextElementSibling;
|
|
4157
4157
|
if (rowElement !== null && (rowElement.className.indexOf('e-summaryrow') !== -1 ||
|
|
4158
|
-
rowElement.
|
|
4158
|
+
rowElement.classList.contains('e-childrow-hidden'))) {
|
|
4159
4159
|
rowElement = this.findnextRowElement(rowElement);
|
|
4160
4160
|
}
|
|
4161
4161
|
return rowElement;
|
|
@@ -4164,7 +4164,7 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
4164
4164
|
TreeGrid.prototype.findPreviousRowElement = function (summaryRowElement) {
|
|
4165
4165
|
var rowElement = summaryRowElement.previousElementSibling;
|
|
4166
4166
|
if (rowElement !== null && (rowElement.className.indexOf('e-summaryrow') !== -1 ||
|
|
4167
|
-
rowElement.
|
|
4167
|
+
rowElement.classList.contains('e-childrow-hidden'))) {
|
|
4168
4168
|
rowElement = this.findPreviousRowElement(rowElement);
|
|
4169
4169
|
}
|
|
4170
4170
|
return rowElement;
|
|
@@ -7094,7 +7094,7 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7094
7094
|
else {
|
|
7095
7095
|
var displayAction = void 0;
|
|
7096
7096
|
if (action === 'expand') {
|
|
7097
|
-
displayAction = '
|
|
7097
|
+
displayAction = 'e-childrow-visible';
|
|
7098
7098
|
if (!isChild) {
|
|
7099
7099
|
record.expanded = true;
|
|
7100
7100
|
this.uniqueIDCollection[record.uniqueID].expanded = record.expanded;
|
|
@@ -7115,7 +7115,7 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7115
7115
|
removeClass([targetEle], 'e-treegridcollapse');
|
|
7116
7116
|
}
|
|
7117
7117
|
else {
|
|
7118
|
-
displayAction = '
|
|
7118
|
+
displayAction = 'e-childrow-hidden';
|
|
7119
7119
|
if (!isChild || isCountRequired(this)) {
|
|
7120
7120
|
record.expanded = false;
|
|
7121
7121
|
this.uniqueIDCollection[record.uniqueID].expanded = record.expanded;
|
|
@@ -7316,7 +7316,7 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7316
7316
|
var rows_2 = this.getContentTable().rows;
|
|
7317
7317
|
gridRows = [].slice.call(rows_2);
|
|
7318
7318
|
}
|
|
7319
|
-
var displayAction = (action === 'expand') ? '
|
|
7319
|
+
var displayAction = (action === 'expand') ? 'e-childrow-visible' : 'e-childrow-hidden';
|
|
7320
7320
|
var primaryKeyField = this.getPrimaryKeyFieldNames()[0];
|
|
7321
7321
|
if (this.enableImmutableMode && !this.allowPaging) {
|
|
7322
7322
|
rows = [];
|
|
@@ -7356,11 +7356,11 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7356
7356
|
});
|
|
7357
7357
|
for (var i = 0; i < rows.length; i++) {
|
|
7358
7358
|
if (!isNullOrUndefined(rows[parseInt(i.toString(), 10)])) {
|
|
7359
|
-
rows[parseInt(i.toString(), 10)]
|
|
7359
|
+
this.toggleRowVisibility(rows[parseInt(i.toString(), 10)], displayAction);
|
|
7360
7360
|
}
|
|
7361
7361
|
if (!isNullOrUndefined(rows[parseInt(i.toString(), 10)]) && !this.allowPaging && !(this.enableVirtualization
|
|
7362
7362
|
|| this.enableInfiniteScrolling || isRemoteData(this) || isCountRequired(this))) {
|
|
7363
|
-
gridRowsObject[rows[parseInt(i.toString(), 10)].rowIndex].visible = displayAction !== '
|
|
7363
|
+
gridRowsObject[rows[parseInt(i.toString(), 10)].rowIndex].visible = displayAction !== 'e-childrow-hidden' ? true : false;
|
|
7364
7364
|
var parentRecord = currentViewData.filter(function (e) {
|
|
7365
7365
|
return e.uniqueID === currentRecord[0].parentUniqueID;
|
|
7366
7366
|
});
|
|
@@ -7369,10 +7369,10 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7369
7369
|
}
|
|
7370
7370
|
}
|
|
7371
7371
|
if (!isNullOrUndefined(movableRows)) {
|
|
7372
|
-
movableRows[parseInt(i.toString(), 10)]
|
|
7372
|
+
this.toggleRowVisibility(movableRows[parseInt(i.toString(), 10)], displayAction);
|
|
7373
7373
|
}
|
|
7374
7374
|
if (!isNullOrUndefined(freezeRightRows)) {
|
|
7375
|
-
freezeRightRows[parseInt(i.toString(), 10)]
|
|
7375
|
+
this.toggleRowVisibility(freezeRightRows[parseInt(i.toString(), 10)], displayAction);
|
|
7376
7376
|
}
|
|
7377
7377
|
this.notify('childRowExpand', { row: rows[parseInt(i.toString(), 10)] });
|
|
7378
7378
|
if ((!isNullOrUndefined(childRecords[parseInt(i.toString(), 10)].childRecords) && childRecords[parseInt(i.toString(), 10)].childRecords.length > 0) && (action !== 'expand' ||
|
|
@@ -7386,8 +7386,8 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7386
7386
|
for (var i = 0; i < detailrows.length; i++) {
|
|
7387
7387
|
if (!isNullOrUndefined(detailrows[parseInt(i.toString(), 10)]) && !this.allowPaging && !(this.enableVirtualization ||
|
|
7388
7388
|
this.enableInfiniteScrolling || isRemoteData(this) || isCountRequired(this))) {
|
|
7389
|
-
gridRowsObject[detailrows[parseInt(i.toString(), 10)].rowIndex].visible = displayAction !== '
|
|
7390
|
-
detailrows[parseInt(i.toString(), 10)]
|
|
7389
|
+
gridRowsObject[detailrows[parseInt(i.toString(), 10)].rowIndex].visible = displayAction !== 'e-childrow-hidden' ? true : false;
|
|
7390
|
+
this.toggleRowVisibility(detailrows[parseInt(i.toString(), 10)], displayAction);
|
|
7391
7391
|
}
|
|
7392
7392
|
}
|
|
7393
7393
|
if (!this.allowPaging && !(this.enableVirtualization || this.enableInfiniteScrolling || isRemoteData(this)
|
|
@@ -7395,12 +7395,18 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7395
7395
|
this.grid.notify('refresh-Expand-and-Collapse', { rows: this.grid.getRowsObject() });
|
|
7396
7396
|
}
|
|
7397
7397
|
};
|
|
7398
|
+
TreeGrid.prototype.toggleRowVisibility = function (row, displayAction) {
|
|
7399
|
+
if (row) {
|
|
7400
|
+
row.classList.remove('e-childrow-hidden', 'e-childrow-visible');
|
|
7401
|
+
row.classList.add(displayAction);
|
|
7402
|
+
}
|
|
7403
|
+
};
|
|
7398
7404
|
TreeGrid.prototype.updateAltRow = function (rows) {
|
|
7399
7405
|
if (this.enableAltRow && !this.rowTemplate) {
|
|
7400
7406
|
var visibleRowCount = 0;
|
|
7401
7407
|
for (var i = 0; rows && i < rows.length; i++) {
|
|
7402
7408
|
var gridRow = rows[parseInt(i.toString(), 10)];
|
|
7403
|
-
if (gridRow.
|
|
7409
|
+
if (!gridRow.classList.contains('e-childrow-hidden')) {
|
|
7404
7410
|
if (gridRow.classList.contains('e-altrow')) {
|
|
7405
7411
|
removeClass([gridRow], 'e-altrow');
|
|
7406
7412
|
}
|
|
@@ -7446,15 +7452,15 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7446
7452
|
});
|
|
7447
7453
|
}
|
|
7448
7454
|
for (var i = 0; i < rows.length; i++) {
|
|
7449
|
-
rows[parseInt(i.toString(), 10)]
|
|
7455
|
+
this.toggleRowVisibility(rows[parseInt(i.toString(), 10)], 'e-childrow-hidden');
|
|
7450
7456
|
row = rows[parseInt(i.toString(), 10)];
|
|
7451
7457
|
var collapsingTd = rows[parseInt(i.toString(), 10)].querySelector('.e-detailrowexpand');
|
|
7452
7458
|
if (!isNullOrUndefined(collapsingTd)) {
|
|
7453
7459
|
this.grid.detailRowModule.collapse(collapsingTd);
|
|
7454
7460
|
}
|
|
7455
7461
|
if (freeze) {
|
|
7456
|
-
movablerows[parseInt(i.toString(), 10)]
|
|
7457
|
-
rightrows[parseInt(i.toString(), 10)]
|
|
7462
|
+
this.toggleRowVisibility(movablerows[parseInt(i.toString(), 10)], 'e-childrow-hidden');
|
|
7463
|
+
this.toggleRowVisibility(rightrows[parseInt(i.toString(), 10)], 'e-childrow-hidden');
|
|
7458
7464
|
if (!rows[parseInt(i.toString(), 10)].querySelector('.e-treecolumn-container .e-treegridexpand')) {
|
|
7459
7465
|
if (movablerows[parseInt(i.toString(), 10)].querySelector('.e-treecolumn-container .e-treegridexpand')) {
|
|
7460
7466
|
row = movablerows[parseInt(i.toString(), 10)];
|
|
@@ -7605,6 +7611,7 @@ var TreeGrid = /** @__PURE__ @class */ (function (_super) {
|
|
|
7605
7611
|
* @returns {void}
|
|
7606
7612
|
*/
|
|
7607
7613
|
TreeGrid.prototype.clearSelection = function () {
|
|
7614
|
+
this.grid.selectionModule['actualTarget'] = null;
|
|
7608
7615
|
this.grid.clearSelection();
|
|
7609
7616
|
};
|
|
7610
7617
|
/**
|
|
@@ -13254,7 +13261,7 @@ var DetailRow = /** @__PURE__ @class */ (function () {
|
|
|
13254
13261
|
return;
|
|
13255
13262
|
}
|
|
13256
13263
|
for (var i = 0; i < args.detailrows.length; i++) {
|
|
13257
|
-
args.detailrows[parseInt(i.toString(), 10)]
|
|
13264
|
+
this.parent['toggleRowVisibility'](args.detailrows[parseInt(i.toString(), 10)], args.action);
|
|
13258
13265
|
}
|
|
13259
13266
|
};
|
|
13260
13267
|
DetailRow.prototype.detaildataBound = function (args) {
|
|
@@ -14299,11 +14306,11 @@ var Freeze = /** @__PURE__ @class */ (function () {
|
|
|
14299
14306
|
if (!isNullOrUndefined(movableRows) && row.parentElement.firstElementChild.clientHeight > 0) {
|
|
14300
14307
|
row.style.height = row.parentElement.firstElementChild.clientHeight + 'px';
|
|
14301
14308
|
}
|
|
14302
|
-
row
|
|
14309
|
+
this.parent['toggleRowVisibility'](row, args.action);
|
|
14303
14310
|
if (freeze && frozenRightRows.length) {
|
|
14304
|
-
frozenRightRows[parseInt(i.toString(), 10)]
|
|
14311
|
+
this.parent['toggleRowVisibility'](frozenRightRows[parseInt(i.toString(), 10)], args.action);
|
|
14305
14312
|
}
|
|
14306
|
-
var queryselector = args.action === '
|
|
14313
|
+
var queryselector = args.action === 'e-childrow-hidden' ? '.e-treecolumn-container .e-treegridcollapse'
|
|
14307
14314
|
: '.e-treecolumn-container .e-treegridexpand';
|
|
14308
14315
|
if (frozenrows[row.rowIndex].querySelector(queryselector)) {
|
|
14309
14316
|
var cRow = [];
|