@syncfusion/ej2-treegrid 33.2.10 → 33.2.12
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 +22 -1
- package/dist/es6/ej2-treegrid.es2015.js.map +1 -1
- package/dist/es6/ej2-treegrid.es5.js +22 -1
- 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 +3 -3
- package/src/treegrid/renderer/virtual-tree-content-render.js +22 -1
- package/helpers/e2e/index.d.ts +0 -1
- package/helpers/e2e/index.js +0 -8
- package/helpers/e2e/treegridhelper.d.ts +0 -21
- package/helpers/e2e/treegridhelper.js +0 -83
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 33.2.
|
|
3
|
+
* version : 33.2.12
|
|
4
4
|
* Copyright Syncfusion Inc. 2001 - 2025. All rights reserved.
|
|
5
5
|
* Use of this code is subject to the terms of our license.
|
|
6
6
|
* A copy of the current license can be obtained at any time by e-mailing
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@syncfusion/ej2-treegrid",
|
|
3
|
-
"version": "33.2.
|
|
3
|
+
"version": "33.2.12",
|
|
4
4
|
"description": "Essential JS 2 TreeGrid Component",
|
|
5
5
|
"author": "Syncfusion Inc.",
|
|
6
6
|
"license": "SEE LICENSE IN license",
|
|
@@ -9,8 +9,8 @@
|
|
|
9
9
|
"es2015": "./dist/es6/ej2-treegrid.es5.js",
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@syncfusion/ej2-base": "~33.2.3",
|
|
12
|
-
"@syncfusion/ej2-data": "~33.2.
|
|
13
|
-
"@syncfusion/ej2-grids": "~33.2.
|
|
12
|
+
"@syncfusion/ej2-data": "~33.2.12",
|
|
13
|
+
"@syncfusion/ej2-grids": "~33.2.12",
|
|
14
14
|
"@syncfusion/ej2-popups": "~33.2.7"
|
|
15
15
|
},
|
|
16
16
|
"devDependencies": {},
|
|
@@ -713,6 +713,10 @@ var VirtualTreeContentRenderer = /** @class */ (function (_super) {
|
|
|
713
713
|
this.parent.root.scrollPosition = scrollArgs.offset;
|
|
714
714
|
}
|
|
715
715
|
var info = scrollArgs.sentinel;
|
|
716
|
+
var treeGridParent = null;
|
|
717
|
+
if (this.parent.clipboardModule && this.parent.clipboardModule['treeGridParent']) {
|
|
718
|
+
treeGridParent = this.parent.clipboardModule['treeGridParent'];
|
|
719
|
+
}
|
|
716
720
|
var rowHeight = parseInt(this.parent.getRowHeight().toString(), 10);
|
|
717
721
|
var outBuffer = this.parent.pageSettings.pageSize - Math.ceil(this.parent.pageSettings.pageSize / 2);
|
|
718
722
|
var content;
|
|
@@ -790,7 +794,7 @@ var VirtualTreeContentRenderer = /** @class */ (function (_super) {
|
|
|
790
794
|
else if (downScroll && (scrollArgs.direction !== 'right' && scrollArgs.direction !== 'left') && !isNullOrUndefined(content)) {
|
|
791
795
|
var nextSetResIndex = ~~(content.scrollTop / rowHeight);
|
|
792
796
|
var isLastBlock = (this["" + selectedRowIndex] + this.parent.pageSettings.pageSize) < this.totalRecords ? false : true;
|
|
793
|
-
if (!isNullOrUndefined(this["" + selectedRowIndex]) && this["" + selectedRowIndex] !== -1 &&
|
|
797
|
+
if (treeGridParent !== null && treeGridParent.isGantt && !isNullOrUndefined(this["" + selectedRowIndex]) && this["" + selectedRowIndex] !== -1 &&
|
|
794
798
|
nextSetResIndex !== this["" + selectedRowIndex] && !isLastBlock && !this.parent.allowRowDragAndDrop) {
|
|
795
799
|
nextSetResIndex = this["" + selectedRowIndex];
|
|
796
800
|
}
|
|
@@ -901,6 +905,15 @@ var VirtualTreeContentRenderer = /** @class */ (function (_super) {
|
|
|
901
905
|
* @returns {void}
|
|
902
906
|
*/
|
|
903
907
|
VirtualTreeContentRenderer.prototype.appendContent = function (target, newChild, e) {
|
|
908
|
+
var treeGridParent = null;
|
|
909
|
+
if (this.parent.clipboardModule && this.parent.clipboardModule['treeGridParent']) {
|
|
910
|
+
treeGridParent = this.parent.clipboardModule['treeGridParent'];
|
|
911
|
+
}
|
|
912
|
+
var totalBlocks = this.getTotalBlocks();
|
|
913
|
+
var lastPage = Math.ceil(totalBlocks / 2);
|
|
914
|
+
var isBottom = (this.parent.pageSettings.currentPage === lastPage) &&
|
|
915
|
+
(treeGridParent && treeGridParent.flatData &&
|
|
916
|
+
treeGridParent.flatData.length === e.index + 1);
|
|
904
917
|
if ((this.parent.dataSource instanceof DataManager && this.parent.dataSource.dataSource.url !== undefined
|
|
905
918
|
&& !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent)
|
|
906
919
|
|| (this.parent.isFrozenGrid() && (e.requestType === undefined || !isNullOrUndefined(e.virtualInfo) && (e.virtualInfo.direction === 'right' || e.virtualInfo.direction === 'left')))) {
|
|
@@ -985,6 +998,14 @@ var VirtualTreeContentRenderer = /** @class */ (function (_super) {
|
|
|
985
998
|
}
|
|
986
999
|
}
|
|
987
1000
|
}
|
|
1001
|
+
if ((treeGridParent !== null && !treeGridParent.isGantt) && e.action === 'add' && isBottom) {
|
|
1002
|
+
var rowHeight = this.parent.getRowHeight();
|
|
1003
|
+
var pageSize = this.parent.pageSettings.pageSize;
|
|
1004
|
+
var newTranslateY = (this.totalRecords * rowHeight) - (pageSize * rowHeight);
|
|
1005
|
+
this.translateY = newTranslateY > 0 ? newTranslateY : this.translateY;
|
|
1006
|
+
this.virtualEle.adjustTable(cOffset, this.translateY);
|
|
1007
|
+
this.content.scrollTop = this.translateY;
|
|
1008
|
+
}
|
|
988
1009
|
this.restoreEditState();
|
|
989
1010
|
_super.prototype["" + restoreAdd].call(this);
|
|
990
1011
|
_super.prototype["" + ensureSelectedRowPosition].call(this);
|
package/helpers/e2e/index.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export * from './treegridhelper';
|
package/helpers/e2e/index.js
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
define(["require", "exports", "./treegridhelper"], function (require, exports, treegridhelper_1) {
|
|
2
|
-
"use strict";
|
|
3
|
-
function __export(m) {
|
|
4
|
-
for (var p in m) if (!exports.hasOwnProperty(p)) exports[p] = m[p];
|
|
5
|
-
}
|
|
6
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
-
__export(treegridhelper_1);
|
|
8
|
-
});
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
import { TestHelper } from '@syncfusion/ej2-base/helpers/e2e';
|
|
2
|
-
export declare class TreeGridHelper extends TestHelper {
|
|
3
|
-
id: string;
|
|
4
|
-
wrapperFn: Function;
|
|
5
|
-
constructor(id: string, wrapperFn: Function);
|
|
6
|
-
getDataGridElement(): any;
|
|
7
|
-
getHeaderElement(): any;
|
|
8
|
-
getContentElement(): any;
|
|
9
|
-
getFooterElement(): any;
|
|
10
|
-
getPagerElement(): any;
|
|
11
|
-
getDialogElement(): any;
|
|
12
|
-
getFilterPopupElement(): any;
|
|
13
|
-
getToolbarElement(): any;
|
|
14
|
-
getCurrentPagerElement(): any;
|
|
15
|
-
getPagerDropDownElement(): any;
|
|
16
|
-
getExpandedElements(): any;
|
|
17
|
-
getCollapsedElements(): any;
|
|
18
|
-
setModel(property: any, value: any): any;
|
|
19
|
-
getModel(property: any): any;
|
|
20
|
-
invoke(fName: any, args?: any): any;
|
|
21
|
-
}
|
|
@@ -1,83 +0,0 @@
|
|
|
1
|
-
var __extends = (this && this.__extends) || (function () {
|
|
2
|
-
var extendStatics = function (d, b) {
|
|
3
|
-
extendStatics = Object.setPrototypeOf ||
|
|
4
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
5
|
-
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
|
6
|
-
return extendStatics(d, b);
|
|
7
|
-
};
|
|
8
|
-
return function (d, b) {
|
|
9
|
-
extendStatics(d, b);
|
|
10
|
-
function __() { this.constructor = d; }
|
|
11
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
12
|
-
};
|
|
13
|
-
})();
|
|
14
|
-
define(["require", "exports", "@syncfusion/ej2-base/helpers/e2e"], function (require, exports, e2e_1) {
|
|
15
|
-
"use strict";
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
var TreeGridHelper = (function (_super) {
|
|
18
|
-
__extends(TreeGridHelper, _super);
|
|
19
|
-
function TreeGridHelper(id, wrapperFn) {
|
|
20
|
-
var _this = _super.call(this) || this;
|
|
21
|
-
_this.id = id;
|
|
22
|
-
if (wrapperFn !== undefined) {
|
|
23
|
-
_this.wrapperFn = wrapperFn;
|
|
24
|
-
}
|
|
25
|
-
return _this;
|
|
26
|
-
}
|
|
27
|
-
TreeGridHelper.prototype.getDataGridElement = function () {
|
|
28
|
-
return this.selector('#' + this.id);
|
|
29
|
-
};
|
|
30
|
-
TreeGridHelper.prototype.getHeaderElement = function () {
|
|
31
|
-
return this.selector('#' + this.id + ' .e-gridheader');
|
|
32
|
-
};
|
|
33
|
-
TreeGridHelper.prototype.getContentElement = function () {
|
|
34
|
-
return this.selector('#' + this.id + ' .e-gridcontent');
|
|
35
|
-
};
|
|
36
|
-
TreeGridHelper.prototype.getFooterElement = function () {
|
|
37
|
-
return this.selector('#' + this.id + ' .e-gridfooter');
|
|
38
|
-
};
|
|
39
|
-
TreeGridHelper.prototype.getPagerElement = function () {
|
|
40
|
-
return this.selector('#' + this.id + ' .e-gridpager');
|
|
41
|
-
};
|
|
42
|
-
TreeGridHelper.prototype.getDialogElement = function () {
|
|
43
|
-
return this.selector('#' + this.id + '_gridcontrol_dialogEdit_wrapper');
|
|
44
|
-
};
|
|
45
|
-
TreeGridHelper.prototype.getFilterPopupElement = function () {
|
|
46
|
-
return this.selector('#' + this.id + ' .e-filter-popup');
|
|
47
|
-
};
|
|
48
|
-
TreeGridHelper.prototype.getToolbarElement = function () {
|
|
49
|
-
return this.selector('#' + this.id + '_gridcontrol_toolbarItems');
|
|
50
|
-
};
|
|
51
|
-
TreeGridHelper.prototype.getCurrentPagerElement = function () {
|
|
52
|
-
return this.selector('#' + this.id + ' .e-numericitem.e-currentitem');
|
|
53
|
-
};
|
|
54
|
-
TreeGridHelper.prototype.getPagerDropDownElement = function () {
|
|
55
|
-
return this.selector('#' + this.id + ' .e-pagerdropdown');
|
|
56
|
-
};
|
|
57
|
-
TreeGridHelper.prototype.getExpandedElements = function () {
|
|
58
|
-
return this.selector('#' + this.id + ' .e-treegridexpand');
|
|
59
|
-
};
|
|
60
|
-
TreeGridHelper.prototype.getCollapsedElements = function () {
|
|
61
|
-
return this.selector('#' + this.id + ' .e-treegridcollapsed');
|
|
62
|
-
};
|
|
63
|
-
TreeGridHelper.prototype.setModel = function (property, value) {
|
|
64
|
-
return cy.get('#' + this.id).then(function (ele) {
|
|
65
|
-
return ele[0].ej2_instances[0][property] = value;
|
|
66
|
-
});
|
|
67
|
-
};
|
|
68
|
-
TreeGridHelper.prototype.getModel = function (property) {
|
|
69
|
-
return cy.get('#' + this.id).then(function (ele) {
|
|
70
|
-
return ele[0].ej2_instances[0][property];
|
|
71
|
-
});
|
|
72
|
-
};
|
|
73
|
-
TreeGridHelper.prototype.invoke = function (fName, args) {
|
|
74
|
-
if (args === void 0) { args = []; }
|
|
75
|
-
return cy.get('#' + this.id).then(function (ele) {
|
|
76
|
-
var inst = ele[0].ej2_instances[0];
|
|
77
|
-
return inst[fName].apply(inst, args);
|
|
78
|
-
});
|
|
79
|
-
};
|
|
80
|
-
return TreeGridHelper;
|
|
81
|
-
}(e2e_1.TestHelper));
|
|
82
|
-
exports.TreeGridHelper = TreeGridHelper;
|
|
83
|
-
});
|