@syncfusion/ej2-gantt 22.2.12 → 23.1.38

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 (126) hide show
  1. package/CHANGELOG.md +197 -164
  2. package/dist/ej2-gantt.min.js +3 -3
  3. package/dist/ej2-gantt.umd.min.js +3 -3
  4. package/dist/ej2-gantt.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-gantt.es2015.js +973 -280
  6. package/dist/es6/ej2-gantt.es2015.js.map +1 -1
  7. package/dist/es6/ej2-gantt.es5.js +1011 -302
  8. package/dist/es6/ej2-gantt.es5.js.map +1 -1
  9. package/dist/global/ej2-gantt.min.js +3 -3
  10. package/dist/global/ej2-gantt.min.js.map +1 -1
  11. package/dist/global/index.d.ts +2 -2
  12. package/package.json +21 -21
  13. package/src/gantt/actions/cell-edit.js +4 -1
  14. package/src/gantt/actions/connector-line-edit.js +48 -6
  15. package/src/gantt/actions/critical-path.d.ts +2 -0
  16. package/src/gantt/actions/critical-path.js +79 -61
  17. package/src/gantt/actions/dependency.d.ts +1 -0
  18. package/src/gantt/actions/dependency.js +92 -31
  19. package/src/gantt/actions/dialog-edit.js +28 -8
  20. package/src/gantt/actions/edit.js +18 -8
  21. package/src/gantt/actions/pdf-export.d.ts +4 -1
  22. package/src/gantt/actions/pdf-export.js +36 -3
  23. package/src/gantt/actions/rowdragdrop.js +10 -2
  24. package/src/gantt/actions/selection.js +22 -5
  25. package/src/gantt/actions/taskbar-edit.js +58 -38
  26. package/src/gantt/actions/toolbar.js +8 -0
  27. package/src/gantt/base/date-processor.js +1 -1
  28. package/src/gantt/base/gantt-chart.d.ts +1 -0
  29. package/src/gantt/base/gantt-chart.js +85 -6
  30. package/src/gantt/base/gantt-model.d.ts +7 -0
  31. package/src/gantt/base/gantt.d.ts +6 -0
  32. package/src/gantt/base/gantt.js +78 -16
  33. package/src/gantt/base/interface.d.ts +14 -0
  34. package/src/gantt/base/splitter.js +1 -0
  35. package/src/gantt/base/task-processor.d.ts +4 -4
  36. package/src/gantt/base/task-processor.js +75 -25
  37. package/src/gantt/base/tree-grid.js +19 -10
  38. package/src/gantt/export/export-helper.d.ts +5 -1
  39. package/src/gantt/export/export-helper.js +150 -3
  40. package/src/gantt/export/pdf-base/pdf-grid-table.js +2 -2
  41. package/src/gantt/export/pdf-base/pdf-style/gantt-theme.js +8 -0
  42. package/src/gantt/export/pdf-base/treegrid-layouter.js +3 -1
  43. package/src/gantt/export/pdf-connector-line.js +3 -1
  44. package/src/gantt/export/pdf-gantt.js +6 -0
  45. package/src/gantt/export/pdf-taskbar.d.ts +13 -0
  46. package/src/gantt/export/pdf-taskbar.js +39 -5
  47. package/src/gantt/export/pdf-timeline.js +17 -8
  48. package/src/gantt/export/pdf-treegrid.js +3 -3
  49. package/src/gantt/models/task-fields-model.d.ts +7 -0
  50. package/src/gantt/models/task-fields.d.ts +6 -0
  51. package/src/gantt/models/task-fields.js +3 -0
  52. package/src/gantt/renderer/chart-rows.d.ts +1 -1
  53. package/src/gantt/renderer/chart-rows.js +44 -34
  54. package/src/gantt/renderer/connector-line.js +52 -11
  55. package/src/gantt/renderer/edit-tooltip.js +2 -1
  56. package/src/gantt/renderer/timeline.js +16 -9
  57. package/src/gantt/renderer/tooltip.js +5 -5
  58. package/styles/bootstrap-dark.css +44 -100
  59. package/styles/bootstrap.css +44 -100
  60. package/styles/bootstrap4.css +44 -100
  61. package/styles/bootstrap5-dark.css +44 -100
  62. package/styles/bootstrap5.css +44 -100
  63. package/styles/fabric-dark.css +44 -100
  64. package/styles/fabric.css +44 -100
  65. package/styles/fluent-dark.css +44 -100
  66. package/styles/fluent.css +44 -100
  67. package/styles/gantt/_layout.scss +44 -31
  68. package/styles/gantt/_theme.scss +104 -98
  69. package/styles/gantt/bootstrap-dark.css +44 -100
  70. package/styles/gantt/bootstrap-dark.scss +1 -1
  71. package/styles/gantt/bootstrap.css +44 -100
  72. package/styles/gantt/bootstrap.scss +1 -1
  73. package/styles/gantt/bootstrap4.css +44 -100
  74. package/styles/gantt/bootstrap4.scss +1 -1
  75. package/styles/gantt/bootstrap5-dark.css +44 -100
  76. package/styles/gantt/bootstrap5-dark.scss +1 -1
  77. package/styles/gantt/bootstrap5.css +44 -100
  78. package/styles/gantt/bootstrap5.scss +1 -1
  79. package/styles/gantt/fabric-dark.css +44 -100
  80. package/styles/gantt/fabric-dark.scss +1 -1
  81. package/styles/gantt/fabric.css +44 -100
  82. package/styles/gantt/fabric.scss +1 -1
  83. package/styles/gantt/fluent-dark.css +44 -100
  84. package/styles/gantt/fluent-dark.scss +1 -1
  85. package/styles/gantt/fluent.css +44 -100
  86. package/styles/gantt/fluent.scss +1 -1
  87. package/styles/gantt/highcontrast-light.css +40 -100
  88. package/styles/gantt/highcontrast-light.scss +1 -1
  89. package/styles/gantt/highcontrast.css +44 -100
  90. package/styles/gantt/highcontrast.scss +1 -1
  91. package/styles/gantt/icons/_bootstrap-dark.scss +4 -0
  92. package/styles/gantt/icons/_bootstrap.scss +4 -0
  93. package/styles/gantt/icons/_bootstrap4.scss +4 -0
  94. package/styles/gantt/icons/_bootstrap5.scss +4 -0
  95. package/styles/gantt/icons/_fabric-dark.scss +4 -0
  96. package/styles/gantt/icons/_fabric.scss +4 -0
  97. package/styles/gantt/icons/_fluent.scss +4 -0
  98. package/styles/gantt/icons/_fusionnew.scss +4 -0
  99. package/styles/gantt/icons/_highcontrast.scss +4 -0
  100. package/styles/gantt/icons/_material-dark.scss +4 -0
  101. package/styles/gantt/icons/_material.scss +4 -0
  102. package/styles/gantt/icons/_material3.scss +4 -0
  103. package/styles/gantt/icons/_tailwind-dark.scss +4 -0
  104. package/styles/gantt/icons/_tailwind.scss +4 -0
  105. package/styles/gantt/material-dark.css +44 -101
  106. package/styles/gantt/material-dark.scss +1 -1
  107. package/styles/gantt/material.css +44 -101
  108. package/styles/gantt/material.scss +1 -1
  109. package/styles/gantt/material3-dark.css +45 -102
  110. package/styles/gantt/material3-dark.scss +1 -1
  111. package/styles/gantt/material3.css +45 -102
  112. package/styles/gantt/material3.scss +1 -1
  113. package/styles/gantt/tailwind-dark.css +44 -101
  114. package/styles/gantt/tailwind-dark.scss +1 -1
  115. package/styles/gantt/tailwind.css +44 -101
  116. package/styles/gantt/tailwind.scss +1 -1
  117. package/styles/highcontrast-light.css +40 -100
  118. package/styles/highcontrast.css +44 -100
  119. package/styles/material-dark.css +44 -101
  120. package/styles/material.css +44 -101
  121. package/styles/material3-dark.css +45 -102
  122. package/styles/material3-dark.scss +1 -1
  123. package/styles/material3.css +45 -102
  124. package/styles/material3.scss +1 -1
  125. package/styles/tailwind-dark.css +44 -101
  126. package/styles/tailwind.css +44 -101
@@ -1,6 +1,6 @@
1
1
  import { PointF, PdfColor, PdfPen, PdfSolidBrush, PdfStandardFont, PdfStringFormat, PdfVerticalAlignment, PdfTextAlignment, PdfWordWrapType } from '@syncfusion/ej2-pdf-export';
2
2
  import { extend, isNullOrUndefined } from '@syncfusion/ej2-base';
3
- import { pixelToPoint } from '../base/utils';
3
+ import { pixelToPoint, pointToPixel } from '../base/utils';
4
4
  /**
5
5
  */
6
6
  var PdfTimeline = /** @class */ (function () {
@@ -23,7 +23,7 @@ var PdfTimeline = /** @class */ (function () {
23
23
  * @returns {void}
24
24
  */
25
25
  PdfTimeline.prototype.drawTimeline = function (page, startPoint, detail) {
26
- var remainWidth = Math.floor(detail.totalWidth);
26
+ var remainWidth = pointToPixel(Math.floor(detail.totalWidth));
27
27
  var renderWidth = 0;
28
28
  this.topTierPoint.x = startPoint.x;
29
29
  this.topTierPoint.y = startPoint.y;
@@ -51,7 +51,7 @@ var PdfTimeline = /** @class */ (function () {
51
51
  //Primary header Event Arguments
52
52
  /* eslint-disable-next-line */
53
53
  this.triggerQueryTimelinecell(page, this.topTierPoint.x, this.topTierPoint.y, this.topTierHeight, renderWidth, pHeader.value, true);
54
- this.topTierPoint.x += pixelToPoint(renderWidth);
54
+ this.topTierPoint.x += renderWidth;
55
55
  remainWidth -= renderWidth;
56
56
  if (isCompleted) {
57
57
  this.topTierIndex++;
@@ -77,7 +77,7 @@ var PdfTimeline = /** @class */ (function () {
77
77
  //Secondary header Event Arguments
78
78
  /* eslint-disable-next-line */
79
79
  this.triggerQueryTimelinecell(page, this.bottomTierPoint.x, this.bottomTierPoint.y, this.bottomTierHeight, width, secondHeader.value, false);
80
- this.bottomTierPoint.x = this.bottomTierPoint.x + pixelToPoint(width);
80
+ this.bottomTierPoint.x = this.bottomTierPoint.x + width;
81
81
  remainWidth -= width;
82
82
  secondHeader.completedWidth = width;
83
83
  if (isCompleted) {
@@ -108,7 +108,7 @@ var PdfTimeline = /** @class */ (function () {
108
108
  //Primary header Event Arguments
109
109
  /* eslint-disable-next-line */
110
110
  this.triggerQueryTimelinecell(page, this.topTierPoint.x, this.topTierPoint.y, this.topTierHeight, pHeader.completedWidth, pHeader.value, true);
111
- this.topTierPoint.x += pixelToPoint(pHeader.completedWidth);
111
+ this.topTierPoint.x += pHeader.completedWidth;
112
112
  }
113
113
  }
114
114
  }
@@ -121,7 +121,7 @@ var PdfTimeline = /** @class */ (function () {
121
121
  //Secondary header Event Arguments
122
122
  /* eslint-disable-next-line */
123
123
  this.triggerQueryTimelinecell(page, this.bottomTierPoint.x, this.bottomTierPoint.y, this.bottomTierHeight, secondHeader.width, secondHeader.value, false);
124
- this.bottomTierPoint.x = this.bottomTierPoint.x + pixelToPoint(secondHeader.width);
124
+ this.bottomTierPoint.x = this.bottomTierPoint.x + secondHeader.width;
125
125
  }
126
126
  }
127
127
  }
@@ -168,7 +168,10 @@ var PdfTimeline = /** @class */ (function () {
168
168
  var e = eventArgs.timelineCell;
169
169
  var rectPen = new PdfPen(eventArgs.timelineCell.borderColor);
170
170
  var rectBrush = new PdfSolidBrush(eventArgs.timelineCell.backgroundColor);
171
- graphics.drawRectangle(rectPen, rectBrush, x, y, pixelToPoint(width), pixelToPoint(height));
171
+ graphics.drawRectangle(rectPen, rectBrush, x, y, width, pixelToPoint(height));
172
+ if (!isTopTier && (this.parent.gridLines == "Both" || this.parent.gridLines == "Vertical")) {
173
+ graphics.drawRectangle(rectPen, rectBrush, x, y + pixelToPoint(height), width, page.getClientSize().height);
174
+ }
172
175
  var font = new PdfStandardFont(ganttStyle.fontFamily, e.fontSize, e.fontStyle);
173
176
  if (ganttStyle.font) {
174
177
  font = ganttStyle.font;
@@ -177,7 +180,13 @@ var PdfTimeline = /** @class */ (function () {
177
180
  var pLeft = ganttStyle.timeline.padding ? eventArgs.timelineCell.padding.left : 0;
178
181
  var pTop = ganttStyle.timeline.padding ? eventArgs.timelineCell.padding.top : 0;
179
182
  /* eslint-disable-next-line */
180
- graphics.drawString(eventArgs.value, font, null, textBrush, x + pLeft, y + pTop, pixelToPoint(width), pixelToPoint(height), e.format);
183
+ if (isTopTier) {
184
+ x = x + pLeft + 4;
185
+ }
186
+ else {
187
+ x = x + pLeft;
188
+ }
189
+ graphics.drawString(eventArgs.value, font, null, textBrush, x, y + pTop, pixelToPoint(width), pixelToPoint(height), e.format);
181
190
  };
182
191
  return PdfTimeline;
183
192
  }());
@@ -267,12 +267,15 @@ var PdfTreeGrid = /** @class */ (function (_super) {
267
267
  colSpan = cell.columnSpan;
268
268
  currentCellIndex = j;
269
269
  cell.isCellMergeStart = true;
270
+ var totalColumnWidth = this.columns.columns[currentCellIndex].width;
270
271
  //Set Column merges.
271
272
  while (colSpan > 1) {
272
273
  currentCellIndex++;
273
274
  row.cells.getCell(currentCellIndex).isCellMergeContinue = true;
274
275
  colSpan--;
276
+ totalColumnWidth += this.columns.columns[currentCellIndex].width;
275
277
  }
278
+ cell.width = totalColumnWidth;
276
279
  }
277
280
  else if (cell.columnSpan === 1 && cell.rowSpan > 1) {
278
281
  rowSpan = cell.rowSpan;
@@ -337,15 +340,12 @@ var PdfTreeGrid = /** @class */ (function (_super) {
337
340
  colSpan = cell.columnSpan;
338
341
  currentCellIndex = j;
339
342
  cell.isCellMergeStart = true;
340
- var totalColumnWidth = this.columns.columns[currentCellIndex].width;
341
343
  //set Column merges.
342
344
  while (colSpan > 1) {
343
345
  currentCellIndex++;
344
346
  row.cells.getCell(currentCellIndex).isCellMergeContinue = true;
345
347
  colSpan--;
346
- totalColumnWidth += this.columns.columns[currentCellIndex].width;
347
348
  }
348
- cell.width = totalColumnWidth;
349
349
  }
350
350
  else if (cell.columnSpan === 1 && cell.rowSpan > 1) {
351
351
  rowSpan = cell.rowSpan;
@@ -26,6 +26,13 @@ export interface TaskFieldsModel {
26
26
  */
27
27
  parentID?: string;
28
28
 
29
+ /**
30
+ * Gets or sets a field name of data object in data source that specifies whether the current record has child records.
31
+ *
32
+ * @default null
33
+ */
34
+ hasChildMapping?: string;
35
+
29
36
  /**
30
37
  * To map start date of task from data source.
31
38
  *
@@ -21,6 +21,12 @@ export declare class TaskFields extends ChildProperty<TaskFields> {
21
21
  * @default null
22
22
  */
23
23
  parentID: string;
24
+ /**
25
+ * Gets or sets a field name of data object in data source that specifies whether the current record has child records.
26
+ *
27
+ * @default null
28
+ */
29
+ hasChildMapping: string;
24
30
  /**
25
31
  * To map start date of task from data source.
26
32
  *
@@ -35,6 +35,9 @@ var TaskFields = /** @class */ (function (_super) {
35
35
  __decorate([
36
36
  Property(null)
37
37
  ], TaskFields.prototype, "parentID", void 0);
38
+ __decorate([
39
+ Property(null)
40
+ ], TaskFields.prototype, "hasChildMapping", void 0);
38
41
  __decorate([
39
42
  Property(null)
40
43
  ], TaskFields.prototype, "startDate", void 0);
@@ -11,7 +11,7 @@ export declare class ChartRows extends DateProcessor {
11
11
  taskBarHeight: number;
12
12
  milestoneHeight: number;
13
13
  private milesStoneRadius;
14
- private baselineTop;
14
+ baselineTop: number;
15
15
  baselineHeight: number;
16
16
  private baselineColor;
17
17
  private parentTaskbarTemplateFunction;
@@ -305,16 +305,16 @@ var ChartRows = /** @class */ (function (_super) {
305
305
  return splitTasks;
306
306
  };
307
307
  ChartRows.prototype.getSplitTaskbarLeftResizerNode = function () {
308
- var lResizerLeft = -(this.parent.isAdaptive ? 12 : 2);
308
+ var lResizerLeft = (!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? 5 : -2;
309
309
  var template = '<div class="' + cls.taskBarLeftResizer + ' ' + cls.icon + '"' +
310
- ' style="' + (this.parent.enableRtl ? 'right:' : 'left:') + lResizerLeft + 'px;height:' + (this.taskBarHeight) + 'px;"></div>';
310
+ ' style="' + (this.parent.enableRtl ? 'right:' : 'left:') + lResizerLeft + 'px;height:' + (this.taskBarHeight) + 'px;z-index:1"></div>';
311
311
  return template;
312
312
  };
313
313
  ChartRows.prototype.getSplitTaskbarRightResizerNode = function (segment) {
314
- var rResizerLeft = this.parent.isAdaptive ? -2 : -10;
314
+ var rResizerLeft = (!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? -17 : -10;
315
315
  var template = '<div class="' + cls.taskBarRightResizer + ' ' + cls.icon + '"' +
316
316
  ' style="' + (this.parent.enableRtl ? 'right:' : 'left:') + (segment.width + rResizerLeft) + 'px;' +
317
- 'height:' + (this.taskBarHeight) + 'px;"></div>';
317
+ 'height:' + (this.taskBarHeight) + 'px;z-index:1"></div>';
318
318
  return template;
319
319
  };
320
320
  ChartRows.prototype.getSplitProgressResizerNode = function (segment) {
@@ -639,7 +639,7 @@ var ChartRows = /** @class */ (function (_super) {
639
639
  }
640
640
  else {
641
641
  var template = '<div class="' + cls.traceMilestone + '" style="width:' + ((this.parent.renderBaseline ? this.taskBarHeight : this.taskBarHeight - 6)) + 'px;height:' +
642
- ((this.parent.renderBaseline ? this.taskBarHeight : this.taskBarHeight - 6)) + 'px;position:absolute;transform: rotate(45deg);top:' + (this.parent.rowHeight > 40 ? 0 : 1) + 'px;left:' + 1 + 'px;"> </div>';
642
+ ((this.parent.renderBaseline ? this.taskBarHeight : this.taskBarHeight - 6)) + 'px;position:absolute;transform: rotate(45deg);left:' + 1 + 'px;"> </div>';
643
643
  milestoneNode = this.createDivElement(template);
644
644
  }
645
645
  return milestoneNode;
@@ -669,7 +669,7 @@ var ChartRows = /** @class */ (function (_super) {
669
669
  var baselineMilestoneHeight = this.parent.renderBaseline ? 5 : 2;
670
670
  var template = '<div class="' + cls.baselineMilestoneContainer + '" style="width:' + ((this.parent.renderBaseline ? this.taskBarHeight : this.taskBarHeight - 10)) + 'px;height:' +
671
671
  ((this.parent.renderBaseline ? this.taskBarHeight : this.taskBarHeight - 10)) + 'px;position:absolute;transform:rotate(45deg);' + (this.parent.enableRtl ? 'right:' : 'left:') + (this.parent.enableRtl ? (data.ganttProperties.left -
672
- (this.milestoneHeight / 2) + 3) : (data.ganttProperties.left - (this.milestoneHeight / 2) + 1)) + 'px;' + (this.baselineColor ? 'background-color: ' + this.baselineColor + ';' : '') + 'margin-top:' + ((-Math.floor(this.parent.rowHeight - this.milestoneMarginTop) + baselineMilestoneHeight) + 2) + 'px"> </div>';
672
+ (this.milestoneHeight / 2) + 3) : (data.ganttProperties.baselineLeft - (this.milestoneHeight / 2) + 1)) + 'px;' + (this.baselineColor ? 'background-color: ' + this.baselineColor + ';' : '') + 'margin-top:' + ((-Math.floor(this.parent.rowHeight - this.milestoneMarginTop) + baselineMilestoneHeight) + 2) + 'px"> </div>';
673
673
  return this.createDivElement(template);
674
674
  };
675
675
  /**
@@ -1017,16 +1017,16 @@ var ChartRows = /** @class */ (function (_super) {
1017
1017
  return this.createDivElement(template);
1018
1018
  };
1019
1019
  ChartRows.prototype.childTaskbarLeftResizer = function () {
1020
- var lResizerLeft = -(this.parent.isAdaptive ? 12 : 2);
1020
+ var lResizerLeft = (!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? 5 : -2;
1021
1021
  var template = '<div class="' + cls.taskBarLeftResizer + ' ' + cls.icon + '"' +
1022
- 'style="' + (this.parent.enableRtl ? 'right:' : 'left:') + lResizerLeft + 'px;height:' + (this.taskBarHeight) + 'px;"></div>';
1022
+ 'style="' + (this.parent.enableRtl ? 'right:' : 'left:') + lResizerLeft + 'px;height:' + (this.taskBarHeight) + 'px;z-index:1"></div>';
1023
1023
  return this.createDivElement(template);
1024
1024
  };
1025
1025
  ChartRows.prototype.childTaskbarRightResizer = function () {
1026
- var rResizerLeft = this.parent.isAdaptive ? -2 : -10;
1026
+ var rResizerLeft = (!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? -17 : -10;
1027
1027
  var template = '<div class="' + cls.taskBarRightResizer + ' ' + cls.icon + '"' +
1028
1028
  'style="' + (this.parent.enableRtl ? 'right:' : 'left:') + (this.templateData.ganttProperties.width + rResizerLeft) + 'px;' +
1029
- 'height:' + (this.taskBarHeight) + 'px;"></div>';
1029
+ 'height:' + (this.taskBarHeight) + 'px;z-index:1"></div>';
1030
1030
  return this.createDivElement(template);
1031
1031
  };
1032
1032
  ChartRows.prototype.childTaskbarProgressResizer = function () {
@@ -1040,8 +1040,10 @@ var ChartRows = /** @class */ (function (_super) {
1040
1040
  };
1041
1041
  ChartRows.prototype.getLeftPointNode = function () {
1042
1042
  var data = this.templateData;
1043
- var pointerLeft = -((this.parent.isAdaptive ? 14 : 2) + this.connectorPointWidth);
1044
- var mileStoneLeft = -(this.connectorPointWidth + 2);
1043
+ var left = (!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? 12 : 0;
1044
+ var mileStoneLeftValue = (!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? 6 : 3;
1045
+ var pointerLeft = -(3 + this.connectorPointWidth + left);
1046
+ var mileStoneLeft = -(this.connectorPointWidth + 4 + mileStoneLeftValue);
1045
1047
  var pointerTop = Math.floor(this.milesStoneRadius - (this.connectorPointWidth / 2));
1046
1048
  var marginTop;
1047
1049
  if ((!this.templateData.ganttProperties.isAutoSchedule && this.templateData.hasChildRecords) && this.parent.allowParentDependency) {
@@ -1060,7 +1062,8 @@ var ChartRows = /** @class */ (function (_super) {
1060
1062
  };
1061
1063
  ChartRows.prototype.getRightPointNode = function () {
1062
1064
  var data = this.templateData;
1063
- var pointerRight = this.parent.isAdaptive ? 10 : -2;
1065
+ var right = (!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? -12 : 0;
1066
+ var pointerRight = -(3 + right);
1064
1067
  var pointerTop = Math.floor(this.milesStoneRadius - (this.connectorPointWidth / 2));
1065
1068
  var marginTop;
1066
1069
  if ((!this.templateData.ganttProperties.isAutoSchedule && this.templateData.hasChildRecords) && this.parent.allowParentDependency) {
@@ -1070,7 +1073,7 @@ var ChartRows = /** @class */ (function (_super) {
1070
1073
  marginTop = 'margin-top:' + this.connectorPointMargin + 'px';
1071
1074
  }
1072
1075
  var template = '<div class="' + cls.rightConnectorPointOuterDiv + '" style="' +
1073
- ((data.ganttProperties.isMilestone) ? ('left:' + (this.milestoneHeight - 2) + 'px;margin-top:' +
1076
+ ((data.ganttProperties.isMilestone) ? ('left:' + ((!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? (this.milestoneHeight + 5) : this.milestoneHeight - 2) + 'px;margin-top:' +
1074
1077
  pointerTop + 'px;') : ('left:' + (data.ganttProperties.width + pointerRight) + 'px;' + marginTop + ';')) + '">' +
1075
1078
  '<div class="' + cls.connectorPointRight + ' ' + this.parent.getUnscheduledTaskClass(data.ganttProperties) +
1076
1079
  '" style="width:' + this.connectorPointWidth + 'px;height:' + this.connectorPointWidth + 'px;">' +
@@ -1243,7 +1246,7 @@ var ChartRows = /** @class */ (function (_super) {
1243
1246
  * @private
1244
1247
  */
1245
1248
  ChartRows.prototype.initChartHelperPrivateVariable = function () {
1246
- var taskbarHeightValue = this.parent.renderBaseline ? 0.45 : 0.62;
1249
+ var taskbarHeightValue = this.parent.renderBaseline ? 0.45 : ((!isNullOrUndefined(document.body.className) && document.body.className.includes("e-bigger")) ? 0.7 : 0.62);
1247
1250
  var taskBarMarginTopValue = this.parent.renderBaseline ? 4 : 2;
1248
1251
  var milestoneHeightValue = this.parent.renderBaseline ? 1.13 : 0.82;
1249
1252
  this.baselineColor = !isNullOrUndefined(this.parent.baselineColor) &&
@@ -1265,8 +1268,8 @@ var ChartRows = /** @class */ (function (_super) {
1265
1268
  this.milestoneMarginTop = Math.floor((this.parent.rowHeight - this.milestoneHeight) / 2);
1266
1269
  this.milesStoneRadius = Math.floor((this.milestoneHeight) / 2);
1267
1270
  this.baselineTop = -(Math.floor((this.parent.rowHeight - (this.taskBarHeight + this.taskBarMarginTop))) - 4);
1268
- this.connectorPointWidth = this.parent.isAdaptive ? Math.round(this.taskBarHeight / 2) : 10;
1269
- this.connectorPointMargin = Math.floor((this.taskBarHeight / 2) - (this.connectorPointWidth / 2)) - 1;
1271
+ this.connectorPointWidth = this.parent.isAdaptive ? Math.round(this.taskBarHeight / 2) : 8;
1272
+ this.connectorPointMargin = Math.floor((this.taskBarHeight / 2) - (this.connectorPointWidth / 2));
1270
1273
  };
1271
1274
  /**
1272
1275
  * Function used to refresh Gantt rows.
@@ -1552,11 +1555,24 @@ var ChartRows = /** @class */ (function (_super) {
1552
1555
  * @private
1553
1556
  */
1554
1557
  ChartRows.prototype.setAriaRowIndex = function (tempTemplateData, tRow) {
1558
+ var _this = this;
1555
1559
  var dataSource = this.parent.treeGrid.getCurrentViewRecords();
1556
1560
  var visualData = this.parent.virtualScrollModule && this.parent.enableVirtualization ?
1557
1561
  getValue('virtualScrollModule.visualData', this.parent.treeGrid) : dataSource;
1558
- var index = visualData.indexOf(tempTemplateData);
1559
- tRow.setAttribute('aria-rowindex', index.toString());
1562
+ var index;
1563
+ if (!this.parent.loadChildOnDemand && this.parent.taskFields.hasChildMapping) {
1564
+ var gridData = this.parent.treeGrid.grid.contentModule['rows'];
1565
+ var data = gridData.filter(function (x) {
1566
+ if (x['data'][_this.parent.taskFields.id] === tempTemplateData.ganttProperties.taskId) {
1567
+ return x;
1568
+ }
1569
+ })[0];
1570
+ tRow.setAttribute('aria-rowindex', data['index'].toString());
1571
+ }
1572
+ else {
1573
+ index = visualData.indexOf(tempTemplateData);
1574
+ tRow.setAttribute('aria-rowindex', index.toString());
1575
+ }
1560
1576
  };
1561
1577
  /**
1562
1578
  * To trigger query taskbar info event.
@@ -1628,7 +1644,7 @@ var ChartRows = /** @class */ (function (_super) {
1628
1644
  getComputedStyle(taskbarElement.querySelector(classCollections[0])).backgroundColor;
1629
1645
  args.taskbarBorderColor = isNullOrUndefined(childTask) ? null : taskbarElement.classList.contains(cls.traceChildTaskBar) ?
1630
1646
  getComputedStyle(taskbarElement).backgroundColor :
1631
- getComputedStyle(taskbarElement.querySelector(classCollections[0])).borderColor;
1647
+ getComputedStyle(taskbarElement.querySelector(classCollections[0])).outlineColor;
1632
1648
  args.progressBarBgColor = isNullOrUndefined(progressTask) ? null :
1633
1649
  taskbarElement.classList.contains(cls.traceChildProgressBar) ?
1634
1650
  getComputedStyle(taskbarElement).backgroundColor :
@@ -1677,7 +1693,7 @@ var ChartRows = /** @class */ (function (_super) {
1677
1693
  */
1678
1694
  ChartRows.prototype.updateQueryTaskbarInfoArgs = function (args, rowElement, taskBarElement) {
1679
1695
  var trElement = args.rowElement;
1680
- var taskbarElement = args.taskbarElement;
1696
+ var taskbarElement = this.parent.enableVirtualization ? args.rowElement : args.taskbarElement;
1681
1697
  var classCollections = this.getClassName(args);
1682
1698
  var segmentRowElement;
1683
1699
  if (args.data.ganttProperties.segments && args.data.ganttProperties.segments.length > 0) {
@@ -1698,18 +1714,6 @@ var ChartRows = /** @class */ (function (_super) {
1698
1714
  }
1699
1715
  }
1700
1716
  else if (taskbarElement) {
1701
- if (taskbarElement && this.parent.enableVirtualization && !args.data.expanded) {
1702
- var childElement = trElement.querySelector('.' + cls.collapseParent);
1703
- if (childElement) {
1704
- for (var i = 0; i < childElement.childNodes.length; i++) {
1705
- var taskbar = childElement.childNodes[i];
1706
- var mainTaskbar = taskbar.querySelector('.' + cls.traceChildTaskBar);
1707
- if (mainTaskbar) {
1708
- mainTaskbar.style.backgroundColor = args.taskbarBgColor;
1709
- }
1710
- }
1711
- }
1712
- }
1713
1717
  if (taskbarElement.querySelector(classCollections[0]) &&
1714
1718
  getComputedStyle(taskbarElement.querySelector(classCollections[0])).backgroundColor !== args.taskbarBgColor) {
1715
1719
  taskbarElement.querySelector(classCollections[0]).style.backgroundColor = args.taskbarBgColor;
@@ -1932,7 +1936,9 @@ var ChartRows = /** @class */ (function (_super) {
1932
1936
  this.triggerQueryTaskbarInfoByIndex(tr, data);
1933
1937
  }
1934
1938
  var dataId = this.parent.viewType === 'ProjectView' ? data.ganttProperties.taskId : data.ganttProperties.rowUniqueID;
1935
- this.parent.treeGrid.grid.setRowData(dataId, data);
1939
+ if (!this.parent.ganttChartModule.isExpandAll && !this.parent.ganttChartModule.isCollapseAll) {
1940
+ this.parent.treeGrid.grid.setRowData(dataId, data);
1941
+ }
1936
1942
  if (this.parent.viewType === 'ResourceView' && data.hasChildRecords && !data.expanded && this.parent.enableMultiTaskbar && !this.parent.allowTaskbarOverlap) {
1937
1943
  this.updateDragDropRecords(selectedItem, tr);
1938
1944
  }
@@ -1956,6 +1962,10 @@ var ChartRows = /** @class */ (function (_super) {
1956
1962
  addClass([cloneElement], 'collpse-parent-border');
1957
1963
  var id = tRow.querySelector('.' + cls.taskBarMainContainer).getAttribute('rowUniqueId');
1958
1964
  var ganttData = this.parent.getRecordByID(id);
1965
+ var mainTaskbar = (cloneElement.querySelector('.e-gantt-child-taskbar'));
1966
+ if (this.parent.queryTaskbarInfo) {
1967
+ this.triggerQueryTaskbarInfoByIndex(mainTaskbar, ganttData);
1968
+ }
1959
1969
  var zIndex = "";
1960
1970
  if (ganttData && !isNullOrUndefined(ganttData.ganttProperties.eOverlapIndex)) {
1961
1971
  zIndex = (ganttData.ganttProperties.eOverlapIndex).toString();
@@ -10,6 +10,7 @@ var ConnectorLine = /** @class */ (function () {
10
10
  this.transform = '';
11
11
  this.connectorLinePath = '';
12
12
  this.arrowPath = '';
13
+ this.taskLineValue = 0;
13
14
  this.expandedRecords = [];
14
15
  this.parent = ganttObj;
15
16
  this.dependencyViewContainer =
@@ -57,7 +58,7 @@ var ConnectorLine = /** @class */ (function () {
57
58
  };
58
59
  ConnectorLine.prototype.getTaskbarMidpoint = function (isMilestone) {
59
60
  return Math.floor(isMilestone ?
60
- (this.parent.chartRowsModule.milestoneMarginTop + (this.parent.chartRowsModule.milestoneHeight / 2)) + 1 :
61
+ (this.parent.chartRowsModule.milestoneMarginTop + (this.parent.chartRowsModule.milestoneHeight / 2)) :
61
62
  (this.parent.chartRowsModule.taskBarMarginTop + (this.parent.chartRowsModule.taskBarHeight / 2))) + 1;
62
63
  };
63
64
  /**
@@ -71,14 +72,45 @@ var ConnectorLine = /** @class */ (function () {
71
72
  */
72
73
  ConnectorLine.prototype.createConnectorLineObject = function (parentGanttData, childGanttData, predecessor) {
73
74
  var connectorObj = {};
74
- var updatedRecords = this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport ?
75
- this.parent.flatData : this.expandedRecords;
76
- var parentIndex = updatedRecords.indexOf(parentGanttData);
77
- var childIndex = updatedRecords.indexOf(childGanttData);
75
+ var updatedRecords;
76
+ if (this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport && this.parent.pdfExportModule.helper.exportProps &&
77
+ this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings && this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings.isFitToWidth) {
78
+ updatedRecords = this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport ?
79
+ this.parent.pdfExportModule.helper.beforeSinglePageExport['cloneFlatData'] : this.expandedRecords;
80
+ }
81
+ else {
82
+ updatedRecords = this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport ?
83
+ this.parent.flatData : this.expandedRecords;
84
+ }
85
+ var parentIndex;
86
+ var childIndex;
87
+ if (this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport && this.parent.pdfExportModule.helper.exportProps &&
88
+ this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings && this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings.isFitToWidth) {
89
+ var parentData = this.parent.flatData.filter(function (data) {
90
+ return data.ganttProperties.taskId.toString() == parentGanttData.ganttProperties.taskId.toString();
91
+ })[0];
92
+ var childData = this.parent.flatData.filter(function (data) {
93
+ return data.ganttProperties.taskId.toString() == childGanttData.ganttProperties.taskId.toString();
94
+ })[0];
95
+ parentIndex = parentData.index;
96
+ childIndex = childData.index;
97
+ }
98
+ else {
99
+ parentIndex = updatedRecords.indexOf(parentGanttData);
100
+ childIndex = updatedRecords.indexOf(childGanttData);
101
+ }
78
102
  var parentGanttRecord = parentGanttData.ganttProperties;
79
103
  var childGanttRecord = childGanttData.ganttProperties;
80
- var currentData = this.parent.virtualScrollModule && this.parent.enableVirtualization ?
81
- this.parent.currentViewData : this.parent.getExpandedRecords(this.parent.currentViewData);
104
+ var currentData;
105
+ if (this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport && this.parent.pdfExportModule.helper.exportProps &&
106
+ this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings && this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings.isFitToWidth) {
107
+ currentData = this.parent.virtualScrollModule && this.parent.enableVirtualization ?
108
+ this.parent.pdfExportModule.helper.beforeSinglePageExport['cloneFlatData'] : this.parent.getExpandedRecords(this.parent.pdfExportModule.helper.beforeSinglePageExport['cloneFlatData']);
109
+ }
110
+ else {
111
+ currentData = this.parent.virtualScrollModule && this.parent.enableVirtualization ?
112
+ this.parent.currentViewData : this.parent.getExpandedRecords(this.parent.currentViewData);
113
+ }
82
114
  connectorObj.parentIndexInCurrentView = currentData.indexOf(parentGanttData);
83
115
  connectorObj.childIndexInCurrentView = currentData.indexOf(childGanttData);
84
116
  var isVirtualScroll = this.parent.virtualScrollModule && this.parent.enableVirtualization;
@@ -818,10 +850,10 @@ var ConnectorLine = /** @class */ (function () {
818
850
  * @private
819
851
  */
820
852
  ConnectorLine.prototype.getConnectorLineTooltipInnerTd = function (fromTaskName, fromPredecessorText, toTaskName, toPredecessorText) {
821
- var innerTd = '<tr id="fromPredecessor"><td style="padding: 4px;">' + this.parent.localeObj.getConstant('from') + '</td><td> ';
853
+ var innerTd = '<tr id="fromPredecessor"><td style="padding: 4px;width: 30px;">' + this.parent.localeObj.getConstant('from') + '</td><td> ';
822
854
  innerTd = innerTd + fromTaskName + ' </td><td style="padding: 2px;"> ' + this.parent.localeObj.getConstant(fromPredecessorText) + ' </td> </tr>';
823
855
  innerTd = innerTd + '<tr id="toPredecessor"><td style="padding: 4px;">' + this.parent.localeObj.getConstant('to') + '</td><td> ' + toTaskName;
824
- innerTd = innerTd + ' </td><td style="padding: 2px;"> ' + this.parent.localeObj.getConstant(toPredecessorText) + ' </td></tr></tbody><table>';
856
+ innerTd = innerTd + ' </td><td style="padding: 2px;width: 30px;"> ' + this.parent.localeObj.getConstant(toPredecessorText) + ' </td></tr></tbody><table>';
825
857
  return innerTd;
826
858
  };
827
859
  /**
@@ -864,8 +896,17 @@ var ConnectorLine = /** @class */ (function () {
864
896
  if (isNullOrUndefined(id)) {
865
897
  return null;
866
898
  }
867
- return this.parent.viewType === 'ResourceView' ? this.parent.flatData[this.parent.getTaskIds().indexOf('T' + id.toString())] :
868
- this.parent.flatData[this.parent.ids.indexOf(id.toString())];
899
+ if (this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport && this.parent.pdfExportModule.helper.exportProps &&
900
+ this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings && this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings.isFitToWidth) {
901
+ var a = this.parent.pdfExportModule.helper.beforeSinglePageExport['cloneFlatData'].filter(function (data) {
902
+ return data.ganttProperties.taskId.toString() === id.toString();
903
+ })[0];
904
+ return a;
905
+ }
906
+ else {
907
+ return this.parent.viewType === 'ResourceView' ? this.parent.flatData[this.parent.getTaskIds().indexOf('T' + id.toString())] :
908
+ this.parent.flatData[this.parent.ids.indexOf(id.toString())];
909
+ }
869
910
  };
870
911
  /**
871
912
  * Method to remove connector line from DOM
@@ -50,6 +50,7 @@ var EditTooltip = /** @class */ (function () {
50
50
  * @returns {void} .
51
51
  */
52
52
  EditTooltip.prototype.updateTooltipPosition = function (args) {
53
+ args.element.style.visibility = 'visible';
53
54
  var parentWithZoomStyle = this.parent.element.closest('[style*="zoom"]');
54
55
  if (isNullOrUndefined(parentWithZoomStyle)) {
55
56
  var containerPosition = this.parent.getOffsetRect(this.parent.chartPane);
@@ -59,8 +60,8 @@ var EditTooltip = /** @class */ (function () {
59
60
  tooltipPositionX += leftEnd - (tooltipPositionX + args.element.offsetWidth);
60
61
  }
61
62
  args.element.style.left = tooltipPositionX + 'px';
63
+ args.element.style.visibility = 'visible';
62
64
  }
63
- args.element.style.visibility = 'visible';
64
65
  };
65
66
  /**
66
67
  * To show/hide taskbar edit tooltip.
@@ -74,7 +74,9 @@ var Timeline = /** @class */ (function () {
74
74
  */
75
75
  Timeline.prototype.refreshTimelineByTimeSpan = function () {
76
76
  this.validateTimelineProp();
77
- this.parent.ganttChartModule.chartTimelineContainer.innerHTML = '';
77
+ if (!this.parent.pdfExportModule || (this.parent.pdfExportModule && !this.parent.pdfExportModule.isPdfExport) || (this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport && this.parent.pdfExportModule.helper.exportProps && !this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings.isFitToWidth)) {
78
+ this.parent.ganttChartModule.chartTimelineContainer.innerHTML = '';
79
+ }
78
80
  this.createTimelineSeries();
79
81
  };
80
82
  /**
@@ -391,7 +393,10 @@ var Timeline = /** @class */ (function () {
391
393
  this.customTimelineSettings.topTier.format = this.validateFormat(this.topTier, this.customTimelineSettings.topTier.format);
392
394
  this.customTimelineSettings.weekStartDay = this.customTimelineSettings.weekStartDay >= 0 &&
393
395
  this.customTimelineSettings.weekStartDay <= 6 ? this.customTimelineSettings.weekStartDay : 0;
394
- this.checkCurrentZoomingLevel();
396
+ if (!(this.parent.pdfExportModule && this.parent.pdfExportModule.helper.exportProps &&
397
+ this.parent.pdfExportModule.isPdfExport && this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings.isFitToWidth)) {
398
+ this.checkCurrentZoomingLevel();
399
+ }
395
400
  };
396
401
  /**
397
402
  * To find the current zooming level of the Gantt control.
@@ -638,13 +643,15 @@ var Timeline = /** @class */ (function () {
638
643
  table = createElement('table', { className: cls.timelineHeaderTableContainer, styles: 'display: block;' });
639
644
  thead = createElement('thead', { className: cls.timelineHeaderTableBody, styles: 'display:block; border-collapse:collapse' });
640
645
  tr = createElement('tr', { innerHTML: this.createTimelineTemplate(tier) });
641
- td = createElement('th');
642
- div = createElement('div', { styles: 'width: 20px' });
643
- td.appendChild(div);
644
- tr.appendChild(td);
645
- thead.appendChild(tr);
646
- table.appendChild(thead);
647
- this.parent.ganttChartModule.chartTimelineContainer.appendChild(table);
646
+ if (!this.parent.pdfExportModule || (this.parent.pdfExportModule && !this.parent.pdfExportModule.isPdfExport) || (this.parent.pdfExportModule && this.parent.pdfExportModule.isPdfExport && this.parent.pdfExportModule.helper.exportProps && !this.parent.pdfExportModule.helper.exportProps.fitToWidthSettings.isFitToWidth)) {
647
+ td = createElement('th');
648
+ div = createElement('div', { styles: 'width: 20px' });
649
+ td.appendChild(div);
650
+ tr.appendChild(td);
651
+ thead.appendChild(tr);
652
+ table.appendChild(thead);
653
+ this.parent.ganttChartModule.chartTimelineContainer.appendChild(table);
654
+ }
648
655
  tier = 'bottomTier';
649
656
  tr = null;
650
657
  }
@@ -88,8 +88,8 @@ var Tooltip = /** @class */ (function () {
88
88
  if (taskbarTemplateNode) {
89
89
  append(taskbarTemplateNode, tooltipTemplate);
90
90
  }
91
- argsData.content = this.toolTipObj.content = taskbarTemplateNode ? tooltipTemplate :
92
- parent.tooltipModule.getTooltipContent((data.ganttProperties.isMilestone ? 'milestone' : 'taskbar'), data, parent, args);
91
+ argsData.content = this.toolTipObj.content = taskbarTemplateNode ? tooltipTemplate : data ?
92
+ parent.tooltipModule.getTooltipContent((data.ganttProperties.isMilestone ? 'milestone' : 'taskbar'), data, parent, args) : "";
93
93
  }
94
94
  else if (args.target.classList.contains('e-baseline-bar') ||
95
95
  args.target.classList.contains('e-baseline-gantt-milestone')) {
@@ -101,8 +101,8 @@ var Tooltip = /** @class */ (function () {
101
101
  if (baseLineTemplateNode) {
102
102
  append(baseLineTemplateNode, baselineTemplate);
103
103
  }
104
- argsData.content = this.toolTipObj.content = baseLineTemplateNode ? baselineTemplate :
105
- parent.tooltipModule.getTooltipContent((data.ganttProperties.isMilestone ? 'milestone' : 'baseline'), data, parent, args);
104
+ argsData.content = this.toolTipObj.content = baseLineTemplateNode ? baselineTemplate : data ?
105
+ parent.tooltipModule.getTooltipContent((data.ganttProperties.isMilestone ? 'milestone' : 'baseline'), data, parent, args) : "";
106
106
  }
107
107
  else if (args.target.classList.contains('e-event-markers')) {
108
108
  argsData.content = this.toolTipObj.content = parent.tooltipModule.getTooltipContent('marker', data, parent, args);
@@ -169,7 +169,7 @@ var Tooltip = /** @class */ (function () {
169
169
  // eslint-disable-next-line
170
170
  Tooltip.prototype.tooltipCloseHandler = function (args) {
171
171
  this.tooltipMouseEvent = null;
172
- if (!this.parent.isAdaptive) {
172
+ if (!this.parent.isAdaptive && !isNullOrUndefined(this.currentTarget)) {
173
173
  EventHandler.remove(this.currentTarget, 'mousemove', this.mouseMoveHandler);
174
174
  }
175
175
  this.currentTarget = null;