@syncfusion/ej2-treegrid 22.2.9 → 23.1.39

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 (64) hide show
  1. package/CHANGELOG.md +15 -50
  2. package/dist/ej2-treegrid.min.js +3 -3
  3. package/dist/ej2-treegrid.umd.min.js +3 -3
  4. package/dist/ej2-treegrid.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-treegrid.es2015.js +234 -328
  6. package/dist/es6/ej2-treegrid.es2015.js.map +1 -1
  7. package/dist/es6/ej2-treegrid.es5.js +233 -351
  8. package/dist/es6/ej2-treegrid.es5.js.map +1 -1
  9. package/dist/global/ej2-treegrid.min.js +3 -3
  10. package/dist/global/ej2-treegrid.min.js.map +1 -1
  11. package/dist/global/index.d.ts +2 -2
  12. package/package.json +10 -10
  13. package/src/treegrid/actions/batch-edit.js +2 -28
  14. package/src/treegrid/actions/crud-actions.js +1 -1
  15. package/src/treegrid/actions/edit.js +6 -52
  16. package/src/treegrid/actions/excel-export.d.ts +2 -2
  17. package/src/treegrid/actions/freeze-column.d.ts +0 -1
  18. package/src/treegrid/actions/freeze-column.js +4 -36
  19. package/src/treegrid/actions/infinite-scroll.js +8 -8
  20. package/src/treegrid/actions/pdf-export.d.ts +2 -2
  21. package/src/treegrid/actions/rowdragdrop.js +3 -1
  22. package/src/treegrid/actions/selection.js +1 -1
  23. package/src/treegrid/actions/virtual-scroll.js +6 -8
  24. package/src/treegrid/base/data.js +20 -4
  25. package/src/treegrid/base/treegrid-model.d.ts +8 -1
  26. package/src/treegrid/base/treegrid.d.ts +69 -1
  27. package/src/treegrid/base/treegrid.js +172 -34
  28. package/src/treegrid/models/column.d.ts +1 -0
  29. package/src/treegrid/renderer/virtual-row-model-generator.js +4 -4
  30. package/src/treegrid/renderer/virtual-tree-content-render.d.ts +0 -1
  31. package/src/treegrid/renderer/virtual-tree-content-render.js +9 -21
  32. package/styles/material-dark.css +0 -1
  33. package/styles/material.css +0 -1
  34. package/styles/material3-dark.css +0 -1
  35. package/styles/material3-dark.scss +1 -1
  36. package/styles/material3.css +0 -1
  37. package/styles/material3.scss +1 -1
  38. package/styles/tailwind-dark.css +0 -1
  39. package/styles/tailwind.css +0 -1
  40. package/styles/treegrid/bootstrap-dark.scss +1 -1
  41. package/styles/treegrid/bootstrap.scss +1 -1
  42. package/styles/treegrid/bootstrap4.scss +1 -1
  43. package/styles/treegrid/bootstrap5-dark.scss +1 -1
  44. package/styles/treegrid/bootstrap5.scss +1 -1
  45. package/styles/treegrid/fabric-dark.scss +1 -1
  46. package/styles/treegrid/fabric.scss +1 -1
  47. package/styles/treegrid/fluent-dark.scss +1 -1
  48. package/styles/treegrid/fluent.scss +1 -1
  49. package/styles/treegrid/highcontrast-light.scss +1 -1
  50. package/styles/treegrid/highcontrast.scss +1 -1
  51. package/styles/treegrid/material-dark.css +0 -1
  52. package/styles/treegrid/material-dark.scss +1 -1
  53. package/styles/treegrid/material.css +0 -1
  54. package/styles/treegrid/material.scss +1 -1
  55. package/styles/treegrid/material3-dark.css +0 -1
  56. package/styles/treegrid/material3-dark.scss +1 -1
  57. package/styles/treegrid/material3.css +0 -1
  58. package/styles/treegrid/material3.scss +1 -1
  59. package/styles/treegrid/tailwind-dark.css +0 -1
  60. package/styles/treegrid/tailwind-dark.scss +1 -1
  61. package/styles/treegrid/tailwind.css +0 -1
  62. package/styles/treegrid/tailwind.scss +1 -1
  63. package/src/treegrid/renderer/virtual-tree-freeze-render.d.ts +0 -59
  64. package/src/treegrid/renderer/virtual-tree-freeze-render.js +0 -163
@@ -42,18 +42,19 @@ var VirtualTreeContentRenderer = /** @class */ (function (_super) {
42
42
  return new TreeVirtualRowModelGenerator(this.parent);
43
43
  };
44
44
  VirtualTreeContentRenderer.prototype.getRowByIndex = function (index) {
45
- return this.parent.getDataRows().filter(function (e) { return parseInt(e.getAttribute('data-rowindex'), 10) === index; })[0];
46
- };
47
- VirtualTreeContentRenderer.prototype.getMovableVirtualRowByIndex = function (index) {
48
- return this.getRowCollection(index, true);
45
+ if (this.parent.enableVirtualization && this.parent.isFrozenGrid()) {
46
+ return this.getRowCollection(index, true);
47
+ }
48
+ else {
49
+ return this.parent.getDataRows().filter(function (e) { return parseInt(e.getAttribute('data-rowindex'), 10) === index; })[0];
50
+ }
49
51
  };
50
52
  VirtualTreeContentRenderer.prototype.getFrozenRightVirtualRowByIndex = function (index) {
51
53
  return this.getRowCollection(index, false, false, true);
52
54
  };
53
55
  VirtualTreeContentRenderer.prototype.getRowCollection = function (index, isMovable, isRowObject, isFrozenRight) {
54
56
  var startIdx = parseInt(this.parent.getRows()[0].getAttribute(literals.dataRowIndex), 10);
55
- var rowCollection = isMovable ? this.parent.getMovableDataRows() : this.parent.getDataRows();
56
- rowCollection = isFrozenRight ? this.parent.getFrozenRightDataRows() : rowCollection;
57
+ var rowCollection = this.parent.getDataRows();
57
58
  var collection = isRowObject ? this.parent.getCurrentViewRecords() : rowCollection;
58
59
  var selectedRow = collection[index - startIdx];
59
60
  if (this.parent.frozenRows && this.parent.pageSettings.currentPage > 1) {
@@ -106,8 +107,8 @@ var VirtualTreeContentRenderer = /** @class */ (function (_super) {
106
107
  this.endIndex = this.parent.pageSettings.pageSize - 1;
107
108
  }
108
109
  if ((this.endIndex - this.startIndex !== this.parent.pageSettings.pageSize) &&
109
- (this.totalRecords > this.parent.pageSettings.pageSize) &&
110
- (this.endIndex === this.totalRecords)) {
110
+ (this.totalRecords > this.parent.pageSettings.pageSize)
111
+ && (this.endIndex === this.totalRecords)) {
111
112
  args.startIndex = this.endIndex - this.parent.pageSettings.pageSize;
112
113
  args.endIndex = this.endIndex;
113
114
  }
@@ -505,29 +506,16 @@ var VirtualTreeContentRenderer = /** @class */ (function (_super) {
505
506
  }
506
507
  };
507
508
  VirtualTreeContentRenderer.prototype.appendContent = function (target, newChild, e) {
508
- var isFrozen = this.parent.isFrozenGrid();
509
509
  if ((this.parent.dataSource instanceof DataManager && this.parent.dataSource.dataSource.url !== undefined
510
510
  && !this.parent.dataSource.dataSource.offline && this.parent.dataSource.dataSource.url !== '') || isCountRequired(this.parent) || this.parent.isFrozenGrid()) {
511
511
  if (getValue('isExpandCollapse', e)) {
512
512
  this.isRemoteExpand = true;
513
513
  }
514
- if (isFrozen && ((isNullOrUndefined(this.requestType) && getValue('requestTypes', this).indexOf('isFrozen') === -1) ||
515
- (this.parent.enableVirtualMaskRow && this.requestType === 'virtualscroll'))) {
516
- getValue('requestTypes', this).push('isFrozen');
517
- this.requestType = 'isFrozen';
518
- }
519
514
  _super.prototype.appendContent.call(this, target, newChild, e);
520
515
  if (getValue('requestTypes', this).indexOf('isFrozen') !== -1) {
521
516
  getValue('requestTypes', this).splice(getValue('requestTypes', this).indexOf('isFrozen'), 1);
522
517
  this.requestType = this.requestType === 'isFrozen' ? undefined : this.requestType;
523
518
  }
524
- if (isFrozen && (!this.isExpandCollapse || this.translateY === 0)) {
525
- this.translateY = this.translateY < 0 ? 0 : this.translateY;
526
- getValue('virtualEle', this).adjustTable(0, this.translateY);
527
- }
528
- else {
529
- this.isExpandCollapse = false;
530
- }
531
519
  }
532
520
  else {
533
521
  var info = e.virtualInfo.sentinelInfo && e.virtualInfo.sentinelInfo.axis === 'Y' &&
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css?family=Roboto:400,500");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  @keyframes e-input-ripple {
4
3
  100% {
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css?family=Roboto:400,500");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  @keyframes e-input-ripple {
4
3
  100% {
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,900&display=swap");
2
1
  :root {
3
2
  --color-sf-black: 0, 0, 0;
4
3
  --color-sf-white: 255, 255, 255;
@@ -1,3 +1,3 @@
1
1
 
2
- @import 'ej2-base/styles/material3-dark-definition.scss';
2
+
3
3
  @import 'treegrid/material3-dark.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,900&display=swap");
2
1
  :root {
3
2
  --color-sf-black: 0, 0, 0;
4
3
  --color-sf-white: 255, 255, 255;
@@ -1,3 +1,3 @@
1
1
 
2
- @import 'ej2-base/styles/material3-definition.scss';
2
+
3
3
  @import 'treegrid/material3.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  .e-ddl.e-control-wrapper .e-ddl-icon::before {
4
3
  transform: rotate(0deg);
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  .e-ddl.e-control-wrapper .e-ddl-icon::before {
4
3
  transform: rotate(0deg);
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/bootstrap-dark-definition.scss';
1
+ @import 'ej2-base/styles/definition/bootstrap-dark.scss';
2
2
  @import 'ej2-inputs/styles/input/bootstrap-dark-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/bootstrap-dark-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/bootstrap-dark-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/bootstrap-definition.scss';
1
+ @import 'ej2-base/styles/definition/bootstrap.scss';
2
2
  @import 'ej2-inputs/styles/input/bootstrap-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/bootstrap-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/bootstrap-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/bootstrap4-definition.scss';
1
+ @import 'ej2-base/styles/definition/bootstrap4.scss';
2
2
  @import 'ej2-inputs/styles/input/bootstrap4-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/bootstrap4-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/bootstrap4-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/bootstrap5-dark-definition.scss';
1
+ @import 'ej2-base/styles/definition/bootstrap5-dark.scss';
2
2
  @import 'ej2-inputs/styles/input/bootstrap5-dark-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/bootstrap5-dark-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/bootstrap5-dark-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/bootstrap5-definition.scss';
1
+ @import 'ej2-base/styles/definition/bootstrap5.scss';
2
2
  @import 'ej2-inputs/styles/input/bootstrap5-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/bootstrap5-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/bootstrap5-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/fabric-dark-definition.scss';
1
+ @import 'ej2-base/styles/definition/fabric-dark.scss';
2
2
  @import 'ej2-inputs/styles/input/fabric-dark-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/fabric-dark-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/fabric-dark-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/fabric-definition.scss';
1
+ @import 'ej2-base/styles/definition/fabric.scss';
2
2
  @import 'ej2-inputs/styles/input/fabric-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/fabric-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/fabric-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/fluent-dark-definition.scss';
1
+ @import 'ej2-base/styles/definition/fluent-dark.scss';
2
2
  @import 'ej2-inputs/styles/input/fluent-dark-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/fluent-dark-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/fluent-dark-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/fluent-definition.scss';
1
+ @import 'ej2-base/styles/definition/fluent.scss';
2
2
  @import 'ej2-inputs/styles/input/fluent-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/fluent-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/fluent-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/highcontrast-light-definition.scss';
1
+ @import 'ej2-base/styles/definition/highcontrast-light.scss';
2
2
  @import 'ej2-inputs/styles/input/highcontrast-light-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/highcontrast-light-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/highcontrast-light-definition.scss';
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/highcontrast-definition.scss';
1
+ @import 'ej2-base/styles/definition/highcontrast.scss';
2
2
  @import 'ej2-inputs/styles/input/highcontrast-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/highcontrast-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/highcontrast-definition.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css?family=Roboto:400,500");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  @keyframes e-input-ripple {
4
3
  100% {
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/material-dark-definition.scss';
1
+ @import 'ej2-base/styles/definition/material-dark.scss';
2
2
  @import 'ej2-inputs/styles/input/material-dark-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/material-dark-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/material-dark-definition.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css?family=Roboto:400,500");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  @keyframes e-input-ripple {
4
3
  100% {
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/material-definition.scss';
1
+ @import 'ej2-base/styles/definition/material.scss';
2
2
  @import 'ej2-inputs/styles/input/material-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/material-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/material-definition.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,900&display=swap");
2
1
  :root {
3
2
  --color-sf-black: 0, 0, 0;
4
3
  --color-sf-white: 255, 255, 255;
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/material3-dark-definition.scss';
1
+
2
2
 
3
3
  @import 'ej2-inputs/styles/input/material3-dark-definition.scss';
4
4
  @import 'ej2-inputs/styles/numerictextbox/material3-dark-definition.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,900&display=swap");
2
1
  :root {
3
2
  --color-sf-black: 0, 0, 0;
4
3
  --color-sf-white: 255, 255, 255;
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/material3-definition.scss';
1
+
2
2
 
3
3
  @import 'ej2-inputs/styles/input/material3-definition.scss';
4
4
  @import 'ej2-inputs/styles/numerictextbox/material3-definition.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  .e-ddl.e-control-wrapper .e-ddl-icon::before {
4
3
  transform: rotate(0deg);
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/tailwind-dark-definition.scss';
1
+ @import 'ej2-base/styles/definition/tailwind-dark.scss';
2
2
  @import 'ej2-inputs/styles/input/tailwind-dark-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/tailwind-dark-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/tailwind-dark-definition.scss';
@@ -1,4 +1,3 @@
1
- @import url("https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700;800;900&display=swap");
2
1
  /* stylelint-disable property-no-vendor-prefix */
3
2
  .e-ddl.e-control-wrapper .e-ddl-icon::before {
4
3
  transform: rotate(0deg);
@@ -1,4 +1,4 @@
1
- @import 'ej2-base/styles/tailwind-definition.scss';
1
+ @import 'ej2-base/styles/definition/tailwind.scss';
2
2
  @import 'ej2-inputs/styles/input/tailwind-definition.scss';
3
3
  @import 'ej2-inputs/styles/numerictextbox/tailwind-definition.scss';
4
4
  @import 'ej2-buttons/styles/button/tailwind-definition.scss';
@@ -1,59 +0,0 @@
1
- import { Column, IGrid, NotifyArgs, Row, ServiceLocator } from '@syncfusion/ej2-grids';
2
- import { ColumnVirtualFreezeRenderer, VirtualFreezeHdrRenderer, VirtualFreezeRenderer } from '@syncfusion/ej2-grids';
3
- /**
4
- * VirtualTreeFreezeRenderer is used to render the virtual table within the frozen and movable content table
5
- *
6
- * @hidden
7
- */
8
- export declare class VirtualTreeFreezeRenderer extends VirtualFreezeRenderer {
9
- protected serviceLoc: ServiceLocator;
10
- constructor(parent: IGrid, locator?: ServiceLocator);
11
- /**
12
- * @returns {void}
13
- * @hidden
14
- */
15
- renderTable(): void;
16
- /**
17
- * @param {HTMLElement} target - specifies the target
18
- * @param {DocumentFragment} newChild - specifies the newChild
19
- * @param {NotifyArgs} e - specifies the notifyargs
20
- * @returns {void}
21
- * @hidden
22
- */
23
- appendContent(target: HTMLElement, newChild: DocumentFragment, e: NotifyArgs): void;
24
- /**
25
- * @param {Object[]} data - specifies the data
26
- * @param {NotifyArgs} e - specifies the notifyargs
27
- * @returns {Row<Column>[]} returns the row
28
- * @hidden
29
- */
30
- generateRows(data: Object[], e?: NotifyArgs): Row<Column>[];
31
- }
32
- /**
33
- * ColumnVirtualTreeFreezeRenderer is used to render the virtual table within the frozen and movable content table
34
- *
35
- * @hidden
36
- */
37
- export declare class ColumnVirtualTreeFreezeRenderer extends ColumnVirtualFreezeRenderer {
38
- protected serviceLoc: ServiceLocator;
39
- constructor(parent?: IGrid, locator?: ServiceLocator);
40
- /**
41
- * @returns {void}
42
- * @hidden
43
- */
44
- renderTable(): void;
45
- appendContent(target: HTMLElement, newChild: DocumentFragment, e: NotifyArgs): void;
46
- }
47
- /**
48
- * VirtualTreeFreezeHdrRenderer is used to render the virtual table within the frozen and movable header table
49
- *
50
- * @hidden
51
- */
52
- export declare class VirtualTreeFreezeHdrRenderer extends VirtualFreezeHdrRenderer {
53
- /**
54
- * @returns {void}
55
- * @hidden
56
- */
57
- renderTable(): void;
58
- protected rfshMovable(): void;
59
- }
@@ -1,163 +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
- import { ColumnFreezeContentRenderer, FreezeContentRender, FreezeRowModelGenerator, RenderType } from '@syncfusion/ej2-grids';
15
- import * as literals from '../base/constant';
16
- import { ColumnVirtualFreezeRenderer, setDebounce, VirtualFreezeHdrRenderer, VirtualFreezeRenderer } from '@syncfusion/ej2-grids';
17
- import { TreeInterSectionObserver, VirtualTreeContentRenderer } from './virtual-tree-content-render';
18
- import { getValue } from '@syncfusion/ej2-base';
19
- /**
20
- * VirtualTreeFreezeRenderer is used to render the virtual table within the frozen and movable content table
21
- *
22
- * @hidden
23
- */
24
- var VirtualTreeFreezeRenderer = /** @class */ (function (_super) {
25
- __extends(VirtualTreeFreezeRenderer, _super);
26
- function VirtualTreeFreezeRenderer(parent, locator) {
27
- var _this = _super.call(this, parent, locator) || this;
28
- _this.addEventListener();
29
- return _this;
30
- }
31
- /**
32
- * @returns {void}
33
- * @hidden
34
- */
35
- VirtualTreeFreezeRenderer.prototype.renderTable = function () {
36
- this.freezeRowGenerator = new FreezeRowModelGenerator(this.parent);
37
- this.virtualRenderer = new VirtualTreeContentRenderer(this.parent, this.serviceLoc);
38
- this.virtualRenderer.header = this.serviceLoc.getService('rendererFactory')
39
- .getRenderer(RenderType.Header).virtualHdrRenderer;
40
- FreezeContentRender.prototype.renderTable.call(this);
41
- this.virtualRenderer.setPanel(this.parent.getContent());
42
- this.scrollbar = this.parent.getContent().querySelector('.e-movablescrollbar');
43
- var movableCont = this.getMovableContent();
44
- var minHeight = this.parent.height;
45
- this.virtualRenderer.virtualEle.content = this.virtualRenderer.content = this.getPanel().querySelector('.' + literals.content);
46
- this.virtualRenderer.virtualEle.content.style.overflowX = 'hidden';
47
- this.virtualRenderer.virtualEle.renderFrozenWrapper(minHeight);
48
- this.virtualRenderer.virtualEle.renderFrozenPlaceHolder();
49
- if (this.parent.enableColumnVirtualization) {
50
- this.virtualRenderer.virtualEle.movableContent = this.virtualRenderer.movableContent
51
- = this.getPanel().querySelector('.' + literals.movableContent);
52
- this.virtualRenderer.virtualEle.renderMovableWrapper(minHeight);
53
- this.virtualRenderer.virtualEle.renderMovablePlaceHolder();
54
- var tbl = movableCont.querySelector('table');
55
- this.virtualRenderer.virtualEle.movableTable = tbl;
56
- this.virtualRenderer.virtualEle.movableWrapper.appendChild(tbl);
57
- movableCont.appendChild(this.virtualRenderer.virtualEle.movableWrapper);
58
- movableCont.appendChild(this.virtualRenderer.virtualEle.movablePlaceholder);
59
- }
60
- this.virtualRenderer.virtualEle.wrapper.appendChild(this.getFrozenContent());
61
- this.virtualRenderer.virtualEle.wrapper.appendChild(movableCont);
62
- this.virtualRenderer.virtualEle.table = this.getTable();
63
- setDebounce(this.parent, this.virtualRenderer, this.scrollbar, this.getMovableContent());
64
- };
65
- /**
66
- * @param {HTMLElement} target - specifies the target
67
- * @param {DocumentFragment} newChild - specifies the newChild
68
- * @param {NotifyArgs} e - specifies the notifyargs
69
- * @returns {void}
70
- * @hidden
71
- */
72
- VirtualTreeFreezeRenderer.prototype.appendContent = function (target, newChild, e) {
73
- getValue('observer', this.virtualRenderer).options.debounceEvent = false;
74
- this.virtualRenderer['observers'] = new TreeInterSectionObserver(getValue('observer', this.virtualRenderer).element, getValue('observer', this.virtualRenderer).options, getValue('observer', this.virtualRenderer).movableEle);
75
- this.virtualRenderer['contents'] = this.getPanel().firstChild;
76
- _super.prototype.appendContent.call(this, target, newChild, e);
77
- };
78
- /**
79
- * @param {Object[]} data - specifies the data
80
- * @param {NotifyArgs} e - specifies the notifyargs
81
- * @returns {Row<Column>[]} returns the row
82
- * @hidden
83
- */
84
- VirtualTreeFreezeRenderer.prototype.generateRows = function (data, e) {
85
- return _super.prototype.generateRows.call(this, data, e);
86
- };
87
- return VirtualTreeFreezeRenderer;
88
- }(VirtualFreezeRenderer));
89
- export { VirtualTreeFreezeRenderer };
90
- /**
91
- * ColumnVirtualTreeFreezeRenderer is used to render the virtual table within the frozen and movable content table
92
- *
93
- * @hidden
94
- */
95
- var ColumnVirtualTreeFreezeRenderer = /** @class */ (function (_super) {
96
- __extends(ColumnVirtualTreeFreezeRenderer, _super);
97
- function ColumnVirtualTreeFreezeRenderer(parent, locator) {
98
- var _this = _super.call(this, parent, locator) || this;
99
- _this.serviceLoc = locator;
100
- _this.eventListener('on');
101
- return _this;
102
- }
103
- /**
104
- * @returns {void}
105
- * @hidden
106
- */
107
- ColumnVirtualTreeFreezeRenderer.prototype.renderTable = function () {
108
- this.virtualRenderer = new VirtualTreeContentRenderer(this.parent, this.serviceLoc);
109
- this.virtualRenderer.header = this.serviceLoc.getService('rendererFactory')
110
- .getRenderer(RenderType.Header).virtualHdrRenderer;
111
- this.freezeRowGenerator = new FreezeRowModelGenerator(this.parent);
112
- ColumnFreezeContentRenderer.prototype.renderTable.call(this);
113
- this.virtualRenderer.setPanel(this.parent.getContent());
114
- this.scrollbar = this.parent.getContent().querySelector('.e-movablescrollbar');
115
- var frozenRightCont = this.getFrozenRightContent();
116
- var frzCont = this.getFrozenContent();
117
- var movableCont = this.getMovableContent();
118
- if (this.parent.getFrozenMode() === 'Right') {
119
- frzCont = frozenRightCont;
120
- }
121
- this.virtualRenderer.virtualEle.content = this.virtualRenderer.content = this.getPanel().querySelector('.' + literals.content);
122
- this.virtualRenderer.virtualEle.content.style.overflowX = 'hidden';
123
- var minHeight = this.parent.height;
124
- this.virtualRenderer.virtualEle.renderFrozenWrapper(minHeight);
125
- this.virtualRenderer.virtualEle.renderFrozenPlaceHolder();
126
- _super.prototype['renderVirtualFrozenLeft'].call(this, frzCont, movableCont);
127
- _super.prototype['renderVirtualFrozenRight'].call(this, frzCont, movableCont);
128
- _super.prototype['renderVirtualFrozenLeftRight'].call(this, frzCont, movableCont, frozenRightCont);
129
- this.virtualRenderer.virtualEle.table = this.getTable();
130
- setDebounce(this.parent, this.virtualRenderer, this.scrollbar, this.getMovableContent());
131
- };
132
- ColumnVirtualTreeFreezeRenderer.prototype.appendContent = function (target, newChild, e) {
133
- getValue('observer', this.virtualRenderer).options.debounceEvent = false;
134
- this.virtualRenderer['observers'] = new TreeInterSectionObserver(getValue('observer', this.virtualRenderer).element, getValue('observer', this.virtualRenderer).options, getValue('observer', this.virtualRenderer).movableEle);
135
- this.virtualRenderer['contents'] = this.getPanel().firstChild;
136
- _super.prototype.appendContent.call(this, target, newChild, e);
137
- };
138
- return ColumnVirtualTreeFreezeRenderer;
139
- }(ColumnVirtualFreezeRenderer));
140
- export { ColumnVirtualTreeFreezeRenderer };
141
- /**
142
- * VirtualTreeFreezeHdrRenderer is used to render the virtual table within the frozen and movable header table
143
- *
144
- * @hidden
145
- */
146
- var VirtualTreeFreezeHdrRenderer = /** @class */ (function (_super) {
147
- __extends(VirtualTreeFreezeHdrRenderer, _super);
148
- function VirtualTreeFreezeHdrRenderer() {
149
- return _super !== null && _super.apply(this, arguments) || this;
150
- }
151
- /**
152
- * @returns {void}
153
- * @hidden
154
- */
155
- VirtualTreeFreezeHdrRenderer.prototype.renderTable = function () {
156
- _super.prototype.renderTable.call(this);
157
- };
158
- VirtualTreeFreezeHdrRenderer.prototype.rfshMovable = function () {
159
- _super.prototype.rfshMovable.call(this);
160
- };
161
- return VirtualTreeFreezeHdrRenderer;
162
- }(VirtualFreezeHdrRenderer));
163
- export { VirtualTreeFreezeHdrRenderer };