@syncfusion/ej2-treegrid 28.2.4 → 29.1.33

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.
Files changed (84) hide show
  1. package/README.md +2 -2
  2. package/dist/ej2-treegrid.min.js +2 -2
  3. package/dist/ej2-treegrid.umd.min.js +2 -2
  4. package/dist/ej2-treegrid.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-treegrid.es2015.js +1275 -519
  6. package/dist/es6/ej2-treegrid.es2015.js.map +1 -1
  7. package/dist/es6/ej2-treegrid.es5.js +1277 -519
  8. package/dist/es6/ej2-treegrid.es5.js.map +1 -1
  9. package/dist/global/ej2-treegrid.min.js +2 -2
  10. package/dist/global/ej2-treegrid.min.js.map +1 -1
  11. package/dist/global/index.d.ts +1 -1
  12. package/package.json +10 -10
  13. package/src/treegrid/actions/batch-edit.js +12 -5
  14. package/src/treegrid/actions/edit.js +12 -12
  15. package/src/treegrid/actions/page.js +1 -1
  16. package/src/treegrid/actions/rowdragdrop.d.ts +21 -1
  17. package/src/treegrid/actions/rowdragdrop.js +248 -48
  18. package/src/treegrid/actions/summary.js +1 -1
  19. package/src/treegrid/actions/virtual-scroll.d.ts +34 -1
  20. package/src/treegrid/actions/virtual-scroll.js +58 -11
  21. package/src/treegrid/base/constant.d.ts +0 -4
  22. package/src/treegrid/base/constant.js +0 -4
  23. package/src/treegrid/base/data.js +48 -47
  24. package/src/treegrid/base/treegrid-model.d.ts +195 -208
  25. package/src/treegrid/base/treegrid.d.ts +598 -411
  26. package/src/treegrid/base/treegrid.js +523 -306
  27. package/src/treegrid/enum.d.ts +77 -80
  28. package/src/treegrid/enum.js +2 -2
  29. package/src/treegrid/models/column.d.ts +122 -177
  30. package/src/treegrid/models/column.js +14 -26
  31. package/src/treegrid/models/edit-settings-model.d.ts +24 -25
  32. package/src/treegrid/models/edit-settings.d.ts +25 -26
  33. package/src/treegrid/models/edit-settings.js +1 -1
  34. package/src/treegrid/models/filter-settings-model.d.ts +41 -49
  35. package/src/treegrid/models/filter-settings.d.ts +43 -51
  36. package/src/treegrid/models/filter-settings.js +2 -2
  37. package/src/treegrid/models/infinite-scroll-settings-model.d.ts +4 -4
  38. package/src/treegrid/models/infinite-scroll-settings.d.ts +4 -4
  39. package/src/treegrid/models/infinite-scroll-settings.js +1 -1
  40. package/src/treegrid/models/loading-indicator-model.d.ts +3 -4
  41. package/src/treegrid/models/loading-indicator.d.ts +4 -4
  42. package/src/treegrid/models/loading-indicator.js +1 -1
  43. package/src/treegrid/models/page-settings-model.d.ts +10 -13
  44. package/src/treegrid/models/page-settings.d.ts +11 -14
  45. package/src/treegrid/models/page-settings.js +1 -1
  46. package/src/treegrid/models/rowdrop-settings-model.d.ts +1 -1
  47. package/src/treegrid/models/rowdrop-settings.d.ts +13 -6
  48. package/src/treegrid/models/rowdrop-settings.js +1 -1
  49. package/src/treegrid/models/search-settings-model.d.ts +13 -11
  50. package/src/treegrid/models/search-settings.d.ts +14 -12
  51. package/src/treegrid/models/search-settings.js +1 -1
  52. package/src/treegrid/models/selection-settings-model.d.ts +18 -29
  53. package/src/treegrid/models/selection-settings.d.ts +18 -29
  54. package/src/treegrid/models/sort-settings-model.d.ts +8 -5
  55. package/src/treegrid/models/sort-settings.d.ts +10 -7
  56. package/src/treegrid/models/sort-settings.js +2 -2
  57. package/src/treegrid/models/summary-model.d.ts +28 -29
  58. package/src/treegrid/models/summary.d.ts +32 -30
  59. package/src/treegrid/models/summary.js +4 -1
  60. package/src/treegrid/models/textwrap-settings-model.d.ts +7 -4
  61. package/src/treegrid/models/textwrap-settings.d.ts +8 -5
  62. package/src/treegrid/models/textwrap-settings.js +1 -1
  63. package/src/treegrid/renderer/render.js +11 -5
  64. package/src/treegrid/renderer/virtual-row-model-generator.js +5 -4
  65. package/src/treegrid/renderer/virtual-tree-content-render.d.ts +277 -0
  66. package/src/treegrid/renderer/virtual-tree-content-render.js +328 -35
  67. package/src/treegrid/utils.d.ts +1 -1
  68. package/styles/bootstrap-lite.css +0 -12
  69. package/styles/bootstrap.css +0 -12
  70. package/styles/bootstrap5-dark-lite.css +1 -1
  71. package/styles/bootstrap5-dark.css +1 -1
  72. package/styles/treegrid/_layout.scss +0 -1
  73. package/styles/treegrid/_material-dark-definition.scss +2 -2
  74. package/styles/treegrid/_material-definition.scss +2 -2
  75. package/styles/treegrid/bootstrap.css +0 -12
  76. package/styles/treegrid/bootstrap5-dark.css +1 -1
  77. package/styles/treegrid/icons/_bootstrap.scss +0 -17
  78. package/styles/treegrid/icons/_bootstrap5.scss +1 -1
  79. package/styles/treegrid/icons/_fabric-dark.scss +1 -1
  80. package/styles/treegrid/icons/_fabric.scss +1 -1
  81. package/styles/treegrid/icons/_fluent2.scss +1 -1
  82. package/styles/treegrid/icons/_fusionnew.scss +1 -0
  83. package/styles/treegrid/icons/_highcontrast-light.scss +1 -1
  84. package/styles/treegrid/icons/_tailwind-dark.scss +2 -2
@@ -21,7 +21,7 @@ import { Property, ChildProperty, Collection, getEnumValue, compile } from '@syn
21
21
  import { Internationalization } from '@syncfusion/ej2-base';
22
22
  import { CellType } from '@syncfusion/ej2-grids';
23
23
  /**
24
- * Configures the TreeGrid's aggregate column.
24
+ * Configures the aggregate column for the TreeGrid.
25
25
  */
26
26
  var AggregateColumn = /** @class */ (function (_super) {
27
27
  __extends(AggregateColumn, _super);
@@ -113,6 +113,9 @@ var AggregateColumn = /** @class */ (function (_super) {
113
113
  return AggregateColumn;
114
114
  }(ChildProperty));
115
115
  export { AggregateColumn };
116
+ /**
117
+ * Configures the aggregate rows in the TreeGrid.
118
+ */
116
119
  var AggregateRow = /** @class */ (function (_super) {
117
120
  __extends(AggregateRow, _super);
118
121
  function AggregateRow() {
@@ -6,10 +6,13 @@ import { Property, ChildProperty } from '@syncfusion/ej2-base';import { WrapMode
6
6
  export interface TextWrapSettingsModel {
7
7
 
8
8
  /**
9
- * Defines the `wrapMode` of the TreeGrid. The available modes are:
10
- * * `Both`: Wraps both the header and content.
11
- * * `Content`: Wraps the header alone.
12
- * * `Header`: Wraps the content alone.
9
+ * Defines the `wrapMode` of the TreeGrid, controlling how text wrapping is applied to header and content.
10
+ * Available wrap modes are:
11
+ * * `Both`: Wraps both the header and the content of all columns.
12
+ * * `Content`: Wraps only the content of the columns, allowing headers to remain unchanged.
13
+ * * `Header`: Wraps only the header text of the columns, while content remains unwrapped.
14
+ *
15
+ * Text wrapping can improve readability when dealing with long text values or narrow column widths.
13
16
  *
14
17
  * @default Both
15
18
  */
@@ -1,14 +1,17 @@
1
1
  import { ChildProperty } from '@syncfusion/ej2-base';
2
2
  import { WrapMode } from '../enum';
3
3
  /**
4
- * Configures the textwrap behavior of the TreeGrid.
4
+ * Configures the text wrapping behavior of the TreeGrid.
5
5
  */
6
6
  export declare class TextWrapSettings extends ChildProperty<TextWrapSettings> {
7
7
  /**
8
- * Defines the `wrapMode` of the TreeGrid. The available modes are:
9
- * * `Both`: Wraps both the header and content.
10
- * * `Content`: Wraps the header alone.
11
- * * `Header`: Wraps the content alone.
8
+ * Defines the `wrapMode` of the TreeGrid, controlling how text wrapping is applied to header and content.
9
+ * Available wrap modes are:
10
+ * * `Both`: Wraps both the header and the content of all columns.
11
+ * * `Content`: Wraps only the content of the columns, allowing headers to remain unchanged.
12
+ * * `Header`: Wraps only the header text of the columns, while content remains unwrapped.
13
+ *
14
+ * Text wrapping can improve readability when dealing with long text values or narrow column widths.
12
15
  *
13
16
  * @default Both
14
17
  */
@@ -19,7 +19,7 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
19
19
  };
20
20
  import { Property, ChildProperty } from '@syncfusion/ej2-base';
21
21
  /**
22
- * Configures the textwrap behavior of the TreeGrid.
22
+ * Configures the text wrapping behavior of the TreeGrid.
23
23
  */
24
24
  var TextWrapSettings = /** @class */ (function (_super) {
25
25
  __extends(TextWrapSettings, _super);
@@ -134,10 +134,9 @@ var Render = /** @class */ (function () {
134
134
  if (columnIndex === this.parent.treeColumnIndex && (args.requestType === 'add' || args.requestType
135
135
  === 'rowDragAndDrop' || args.requestType === 'delete' || isNullOrUndefined(args.cell.querySelector('.e-treecell')))) {
136
136
  var container = createElement('div', { className: 'e-treecolumn-container' });
137
- var emptyExpandIcon = createElement('span', {
138
- className: 'e-icons e-none',
139
- styles: 'width: 10px; display: inline-block'
140
- });
137
+ var emptyExpandIcon = createElement('span', { className: 'e-icons e-none' });
138
+ emptyExpandIcon.style.width = '10px';
139
+ emptyExpandIcon.style.display = 'inline-block';
141
140
  for (var n = 0; n < pad; n++) {
142
141
  totalIconsWidth += 10;
143
142
  container.appendChild(emptyExpandIcon.cloneNode());
@@ -164,6 +163,13 @@ var Render = /** @class */ (function () {
164
163
  }
165
164
  else {
166
165
  expand = !(!data.expanded || !getExpandStatus(this.parent, data, this.parent.grid.getCurrentViewRecords()));
166
+ // TicketsID 43483: While Modify Data Expand and Collapse Icon Behavior Changed
167
+ if (this.parent.editSettings.mode === 'Cell' && !isRemoteData(this.parent)) {
168
+ var selectedRow = this.parent.flatData.find(function (item) { return item.uniqueID === data.uniqueID; });
169
+ if (!isNullOrUndefined(selectedRow)) {
170
+ expand = data.expanded !== selectedRow.expanded ? selectedRow.expanded : data.expanded;
171
+ }
172
+ }
167
173
  }
168
174
  addClass([expandIcon], (expand) ? 'e-treegridexpand' : 'e-treegridcollapse');
169
175
  totalIconsWidth += 18;
@@ -281,7 +287,7 @@ var Render = /** @class */ (function () {
281
287
  var templateFn = 'templateFn';
282
288
  var colindex = args.column.index;
283
289
  if (isNullOrUndefined(treeColumn.field)) {
284
- args.cell.setAttribute('data-colindex', colindex + '');
290
+ args.cell.setAttribute('aria-colindex', (colindex + 1) + '');
285
291
  }
286
292
  if (treeColumn.field === args.column.field && !isNullOrUndefined(treeColumn.template)) {
287
293
  /* eslint-disable-next-line @typescript-eslint/no-explicit-any */
@@ -15,7 +15,7 @@ import { VirtualRowModelGenerator } from '@syncfusion/ej2-grids';
15
15
  import * as events from '../base/constant';
16
16
  import { isNullOrUndefined } from '@syncfusion/ej2-base';
17
17
  import { DataManager } from '@syncfusion/ej2-data';
18
- import { isCountRequired, isRemoteData } from '../utils';
18
+ import { isCountRequired } from '../utils';
19
19
  /**
20
20
  * RowModelGenerator is used to generate grid data rows.
21
21
  *
@@ -50,7 +50,8 @@ var TreeVirtualRowModelGenerator = /** @class */ (function (_super) {
50
50
  if (!isNullOrUndefined(notifyArgs.virtualInfo)) {
51
51
  if (notifyArgs.virtualInfo.direction !== 'right' && notifyArgs.virtualInfo.direction !== 'left') {
52
52
  if (!((this.parent.dataSource instanceof DataManager && this.parent.dataSource.dataSource.url !== undefined
53
- && !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent) || isRemoteData(this.parent))) {
53
+ && !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent))
54
+ || notifyArgs.virtualInfo.blockIndexes.length === 1) {
54
55
  notifyArgs.virtualInfo.blockIndexes = info.blockIndexes;
55
56
  }
56
57
  }
@@ -59,7 +60,7 @@ var TreeVirtualRowModelGenerator = /** @class */ (function (_super) {
59
60
  }
60
61
  }
61
62
  if ((this.parent.dataSource instanceof DataManager && this.parent.dataSource.dataSource.url !== undefined
62
- && !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent) || isRemoteData(this.parent)) {
63
+ && !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent)) {
63
64
  return _super.prototype.generateRows.call(this, data, notifyArgs);
64
65
  }
65
66
  else {
@@ -80,7 +81,7 @@ var TreeVirtualRowModelGenerator = /** @class */ (function (_super) {
80
81
  var clear = ['paging', 'refresh', 'sorting', 'filtering', 'searching', 'reorder',
81
82
  'save', 'delete'].some(function (value) { return action === value; });
82
83
  if ((this.parent.dataSource instanceof DataManager && this.parent.dataSource.dataSource.url !== undefined
83
- && !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent) || isRemoteData(this.parent)) {
84
+ && !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent)) {
84
85
  var model = 'model';
85
86
  var currentPage = this["" + model].currentPage;
86
87
  if (clear) {
@@ -2,6 +2,11 @@ import { Cell, CellType, Column, NotifyArgs, SentinelType } from '@syncfusion/ej
2
2
  import { Offsets, VirtualInfo, ServiceLocator, IGrid, IModelGenerator } from '@syncfusion/ej2-grids';
3
3
  import { VirtualContentRenderer } from '@syncfusion/ej2-grids';
4
4
  import { InterSectionObserver } from '@syncfusion/ej2-grids';
5
+ /**
6
+ * VirtualTreeContentRenderer
7
+ *
8
+ * @hidden
9
+ */
5
10
  export declare class VirtualTreeContentRenderer extends VirtualContentRenderer {
6
11
  getModelGenerator(): IModelGenerator<Column>;
7
12
  constructor(parent: IGrid, locator?: ServiceLocator);
@@ -24,36 +29,285 @@ export declare class VirtualTreeContentRenderer extends VirtualContentRenderer {
24
29
  private previousInfo;
25
30
  /** @hidden */
26
31
  isDataSourceChanged: boolean;
32
+ /**
33
+ * Retrieves the row element for a given row index.
34
+ *
35
+ * @param {number} index - The index of the row to retrieve.
36
+ * @returns {Element} The row element at the specified index.
37
+ */
27
38
  getRowByIndex(index: number): Element;
39
+ /**
40
+ * Retrieves the frozen right virtual row element by its index.
41
+ *
42
+ * @param {number} index - The index of the row to be retrieved.
43
+ * @returns {Element} The DOM element representing the frozen right virtual row.
44
+ */
28
45
  getFrozenRightVirtualRowByIndex(index: number): Element;
46
+ /**
47
+ * Retrieves the row or record from the virtual tree grid based on the provided index.
48
+ * Considers conditions such as frozen rows and pagination for accurate retrieval.
49
+ *
50
+ * @param {number} index - The index of the desired row or record.
51
+ * @param {boolean} isMovable - Specifies if the content is movable.
52
+ * @param {boolean} [isRowObject] - Optional. Determines if the return value should be a row object.
53
+ * @param {boolean} [isFrozenRight] - Optional. Used for determining frozen right rows.
54
+ * @returns {Element | Object} - The HTML element or row object.
55
+ */
29
56
  getRowCollection(index: number, isMovable: boolean, isRowObject?: boolean, isFrozenRight?: boolean): Element | Object;
57
+ /**
58
+ * @hidden
59
+ * @returns {void}
60
+ */
30
61
  addEventListener(): void;
62
+ /**
63
+ * Handles virtual scrolling actions based on the provided arguments.
64
+ *
65
+ * @param {Object} args - The argument object.
66
+ * @param {boolean} args.setTop - Determines if the virtual scroll position should reset to top.
67
+ * @param {boolean} args.isExpandCollapse - Determines if the action is part of an expand/collapse operation.
68
+ * @returns {void}
69
+ */
31
70
  private virtualOtherAction;
71
+ /**
72
+ * Modifies the index based on various conditions such as record addition, deletion, or data source changes.
73
+ *
74
+ * @private
75
+ * @param {Object} args - Contains parameters for the current operation.
76
+ * @param {number} args.startIndex - The starting index for the modification.
77
+ * @param {number} args.endIndex - The ending index for the modification.
78
+ * @param {number} args.count - The number of items affected in the operation.
79
+ * @param {string} args.requestType - The type of request, such as 'insert', 'delete', or 'update'.
80
+ * @returns {void}
81
+ */
32
82
  private indexModifier;
83
+ /**
84
+ * Handles the addition or removal of event listeners for virtual scrolling in a TreeGrid.
85
+ *
86
+ * @param {string} action - The action to perform, either 'on' or 'off'.
87
+ * @returns {void}
88
+ */
33
89
  eventListener(action: string): void;
90
+ /**
91
+ * Handles cell focus transitions in a virtualized tree grid component
92
+ * when a keyboard event is triggered.
93
+ *
94
+ * @param {KeyboardEventArgs} e - The keyboard event arguments that contain
95
+ * information about the key action.
96
+ * @returns {void}
97
+ */
34
98
  private cellFocus;
99
+ /**
100
+ * Handles the data ready event for the virtual tree grid content renderer.
101
+ *
102
+ * @param {NotifyArgs} [e] - The notification arguments that contain information about the data.
103
+ * @returns {void}
104
+ */
35
105
  protected onDataReady(e?: NotifyArgs): void;
106
+ /**
107
+ * Renders the table for the virtual tree content. It sets up a new `TreeInterSectionObserver`
108
+ * based on certain conditions regarding the data source and counting requirements.
109
+ *
110
+ * @returns {void}
111
+ */
36
112
  renderTable(): void;
113
+ /**
114
+ * Calculates the translateY value for a virtual tree grid based on the scroll top, container height,
115
+ * and additional virtual scrolling information. This method specifically handles logic for remote
116
+ * data sources and ensures smooth scrolling with respect to expansion states.
117
+ *
118
+ * @param {number} sTop - The scroll top position.
119
+ * @param {number} cHeight - The height of the container.
120
+ * @param {VirtualInfo} [info] - Optional virtual scrolling information.
121
+ * @param {boolean} [isOnenter] - Flag indicating if the scroll event is on enter.
122
+ * @returns {number} The calculated translateY value.
123
+ */
37
124
  protected getTranslateY(sTop: number, cHeight: number, info?: VirtualInfo, isOnenter?: boolean): number;
125
+ /**
126
+ * Handles the dataBound event to calculate and set the initial row top position for the grid.
127
+ *
128
+ * @returns {void}
129
+ */
38
130
  private dataBoundEvent;
131
+ /**
132
+ * Handles the row selection event for virtual tree grid rows.
133
+ * It invokes the base class's rowSelected method and notifies
134
+ * the parent component about a virtual transformation change.
135
+ *
136
+ * @param {RowSelectEventArgs} args - The arguments related to the row selection event.
137
+ * @returns {void} This method does not return a value.
138
+ */
39
139
  private rowSelectedEvent;
140
+ /**
141
+ * Handles virtual row selection in TreeGrid.
142
+ *
143
+ * @param {Object} args - The argument object containing the selected index.
144
+ * @param {number} args.selectedIndex - The index of the row to be selected.
145
+ *
146
+ * @returns {void}
147
+ */
40
148
  private toSelectVirtualRow;
149
+ /**
150
+ * Refreshes the cells for the given row object by regenerating them.
151
+ *
152
+ * @param {Row<Column>} rowObj - The row object for which the cells need to be refreshed.
153
+ * @returns {void} This method does not return any value.
154
+ */
41
155
  private refreshCell;
156
+ /**
157
+ * Generates an array of cells for each column in the parent.
158
+ *
159
+ * @returns {Cell<Column>[]} An array of cells for the corresponding columns.
160
+ */
42
161
  generateCells(): Cell<Column>[];
162
+ /**
163
+ * Generates a cell object with provided column and row configurations.
164
+ *
165
+ * @param {Column} col - The Column object which holds the column configuration.
166
+ * @param {string} [rowId] - An optional string that represents the row ID.
167
+ * @param {CellType} [cellType] - An optional CellType enum to specify the type of the cell.
168
+ * @param {number} [colSpan] - An optional number to specify the column span of the cell.
169
+ * @param {number} [oIndex] - An optional number for the order index of the cell.
170
+ * @param {Object} [foreignKeyData] - An optional object for foreign key data associated with the column.
171
+ *
172
+ * @returns {Cell<Column>} Returns a newly created Cell object of type Column.
173
+ */
43
174
  generateCell(col: Column, rowId?: string, cellType?: CellType, colSpan?: number, oIndex?: number, foreignKeyData?: Object): Cell<Column>;
175
+ /**
176
+ * Begins the edit operation for a specified row in the grid.
177
+ * Updates the `editedRowIndex` and assigns row data to the event data.
178
+ *
179
+ * @param {{ data: Object, index: number }} e - An object containing the row data and index.
180
+ * @param {Object} e.data - The data of the row to be edited.
181
+ * @param {number} e.index - The index of the row to be edited.
182
+ * @returns {void}
183
+ */
44
184
  private beginEdit;
185
+ /**
186
+ * Begins the process of adding a new row in the tree grid.
187
+ *
188
+ * @param {Object} args - The arguments for adding a new row.
189
+ * @param {boolean} args.startEdit - A flag indicating whether to start editing.
190
+ * @returns {void}
191
+ */
45
192
  private beginAdd;
193
+ /**
194
+ * Restores the edit state of the tree grid content. This method calls the
195
+ * base class method to handle the restoration logic.
196
+ *
197
+ * @returns {void} This method does not return any value.
198
+ */
46
199
  private restoreEditState;
200
+ /**
201
+ * Resets the edit state if certain conditions are met.
202
+ *
203
+ * @returns {void}
204
+ */
47
205
  private resetIseditValue;
206
+ /**
207
+ * Handles the successful editing operation when virtual scrolling is enabled.
208
+ * Checks if a row has been added to the tree grid and sets the `recordAdded` flag accordingly.
209
+ *
210
+ * @returns {void}
211
+ */
48
212
  private virtualEditSuccess;
213
+ /**
214
+ * Cancels the edit operation for the provided data.
215
+ *
216
+ * @param {Object} args - The arguments containing the data to cancel edit for.
217
+ * @param {Object} args.data - The specific data object for which the edit operation needs to be canceled.
218
+ * @returns {void}
219
+ */
49
220
  private cancelEdit;
221
+ /**
222
+ * Handles the action of selecting a row when the context menu is opened.
223
+ *
224
+ * @param {Object} args - An object containing related parameters.
225
+ * @param {boolean} args.isOpen - A flag indicating whether the context menu is open.
226
+ * @returns {void} This method does not return any value.
227
+ */
50
228
  private toSelectRowOnContextOpen;
229
+ /**
230
+ * Restores a new row in the grid when necessary by adding it back to the content.
231
+ *
232
+ * @returns {void} This method does not return any value.
233
+ */
51
234
  private restoreNewRow;
235
+ /**
236
+ * Retrieves virtual data for operations like adding or canceling rows in the grid.
237
+ *
238
+ * @param {Object} data - An object containing properties to determine the virtual data processing.
239
+ * @param {Object} data.virtualData - The virtual data object to be processed.
240
+ * @param {boolean} data.isAdd - A boolean indicating if the operation is an addition.
241
+ * @param {boolean} data.isCancel - A boolean indicating if the operation is a cancellation.
242
+ * @returns {void} This method does not return any value.
243
+ */
52
244
  private getData;
245
+ /**
246
+ * Initiates the beginning of an action within the tree grid component.
247
+ * This method is invoked before any action is performed, allowing for
248
+ * any necessary modifications or cancellations of the upcoming action.
249
+ *
250
+ * @param {NotifyArgs} args - The arguments associated with the action,
251
+ * providing context and specifics about what is being commenced.
252
+ * @returns {void}
253
+ */
254
+ protected handleActionBegin(args: NotifyArgs): void;
255
+ /**
256
+ * Handles the completion of various actions, such as adding a new row.
257
+ * Updates row positions and indexes based on the action completed.
258
+ *
259
+ * @param {NotifyArgs} args - An object containing the details of the completed action.
260
+ * Specifically, it includes the `requestType` which determines the type
261
+ * of action that was completed.
262
+ * @returns {void} This method does not return any value.
263
+ */
53
264
  private onActionComplete;
265
+ /**
266
+ * Creates a callback function to be executed during virtual scrolling actions.
267
+ * This function handles the adjustment of virtual elements and rendering logic,
268
+ * particularly optimizing for non-IE browsers, wheel events, and virtual masks.
269
+ *
270
+ * @returns {Function} A function that handles scrolling and adjusts table rendering.
271
+ * @param {HTMLElement} element - The HTML element involved in the action.
272
+ * @param {SentinelType} current - The type of sentinel indicating the scroll.
273
+ * @param {string} direction - The scroll direction.
274
+ * @param {Offsets} e - The offset values indicating the current scroll position.
275
+ * @param {boolean} isWheel - Indicates if the scrolling was initiated by a mouse wheel.
276
+ * @param {boolean} check - A boolean flag for additional control logic.
277
+ */
54
278
  private onEnteredAction;
279
+ /**
280
+ * Handles scroll events to manage virtual scrolling and row rendering.
281
+ * Adjusts view information, row indexes, and translates viewport positioning
282
+ * based on the given scroll arguments.
283
+ *
284
+ * @param {ScrollArg} scrollArgs - Contains the scroll offsets, sentinel information, direction of scroll, and other related details.
285
+ * @returns {void} - No return value. It adjusts scrolling state internally.
286
+ */
55
287
  scrollListeners(scrollArgs: ScrollArg): void;
288
+ /**
289
+ * Prevents scrolling under specific conditions related to adding a new row.
290
+ *
291
+ * @param {ScrollArg} scrollArgs - The scroll event arguments containing offset details.
292
+ * @returns {void}
293
+ */
294
+ private shouldPreventScrolling;
295
+ /**
296
+ * Appends content to the target element. Handles dynamic adjustments for remote data sources,
297
+ * frozen columns, and virtual scrolling.
298
+ *
299
+ * @param {HTMLElement} target - The target HTML element where content is to be appended.
300
+ * @param {DocumentFragment} newChild - The new content as a DocumentFragment to append.
301
+ * @param {NotifyArgs} e - Object containing information about the operation.
302
+ * @returns {void}
303
+ */
56
304
  appendContent(target: HTMLElement, newChild: DocumentFragment, e: NotifyArgs): void;
305
+ /**
306
+ * Unsubscribes all event listeners to prevent memory leaks.
307
+ * This method is called when the component is being destroyed or when event listeners need to be cleaned up.
308
+ *
309
+ * @returns {void}
310
+ */
57
311
  removeEventListener(): void;
58
312
  }
59
313
  export declare class TreeInterSectionObserver extends InterSectionObserver {
@@ -61,8 +315,31 @@ export declare class TreeInterSectionObserver extends InterSectionObserver {
61
315
  private newPos;
62
316
  private lastPos;
63
317
  private timer;
318
+ /**
319
+ * Sets up observers to monitor scroll events on a given container
320
+ * and its movable companion within a virtual grid setup.
321
+ *
322
+ * @param {Function} callback - Function to call when a scroll event is detected.
323
+ * @param {Function} onEnterCallback - Function to call when a specific event, like entering a region, is detected.
324
+ * @param {IGrid} instance - The grid instance that requires observation.
325
+ * @returns {void}
326
+ */
64
327
  observes(callback: Function, onEnterCallback: Function, instance: IGrid): void;
328
+ /**
329
+ * Clears the last known position.
330
+ *
331
+ * @returns {void} No value is returned from this function.
332
+ */
65
333
  private clear;
334
+ /**
335
+ * Handles virtual scrolling events and manages scroll direction and debouncing for rendering updates.
336
+ *
337
+ * @private
338
+ * @param {Function} callback - Function to call on scroll end.
339
+ * @param {Function} onEnterCallback - Function to call on entering a virtual scrolling area.
340
+ * @param {IGrid} instance - The grid instance on which virtual scrolling is being implemented.
341
+ * @returns {Function} - A function that processes scroll events.
342
+ */
66
343
  private virtualScrollHandlers;
67
344
  }
68
345
  declare type ScrollArg = {