@syncfusion/ej2-gantt 19.4.54 → 20.1.47

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 (81) hide show
  1. package/CHANGELOG.md +33 -0
  2. package/dist/ej2-gantt.umd.min.js +2 -2
  3. package/dist/ej2-gantt.umd.min.js.map +1 -1
  4. package/dist/es6/ej2-gantt.es2015.js +257 -140
  5. package/dist/es6/ej2-gantt.es2015.js.map +1 -1
  6. package/dist/es6/ej2-gantt.es5.js +279 -148
  7. package/dist/es6/ej2-gantt.es5.js.map +1 -1
  8. package/dist/global/ej2-gantt.min.js +2 -2
  9. package/dist/global/ej2-gantt.min.js.map +1 -1
  10. package/dist/global/index.d.ts +1 -1
  11. package/package.json +18 -18
  12. package/src/gantt/actions/cell-edit.js +2 -1
  13. package/src/gantt/actions/dialog-edit.js +2 -1
  14. package/src/gantt/actions/edit.js +36 -9
  15. package/src/gantt/actions/rowdragdrop.js +37 -15
  16. package/src/gantt/actions/selection.js +3 -0
  17. package/src/gantt/base/date-processor.js +0 -1
  18. package/src/gantt/base/gantt-chart.js +36 -5
  19. package/src/gantt/base/gantt.js +15 -56
  20. package/src/gantt/base/splitter.js +1 -0
  21. package/src/gantt/base/tree-grid.js +3 -1
  22. package/src/gantt/renderer/chart-rows.js +59 -32
  23. package/src/gantt/renderer/connector-line.js +22 -18
  24. package/src/gantt/renderer/event-marker.js +1 -0
  25. package/src/gantt/renderer/nonworking-day.js +13 -6
  26. package/src/gantt/renderer/timeline.d.ts +1 -0
  27. package/src/gantt/renderer/timeline.js +40 -1
  28. package/src/gantt/renderer/tooltip.js +10 -3
  29. package/styles/bootstrap-dark.css +37 -10
  30. package/styles/bootstrap.css +37 -10
  31. package/styles/bootstrap4.css +37 -10
  32. package/styles/bootstrap5-dark.css +53 -19
  33. package/styles/bootstrap5.css +53 -19
  34. package/styles/fabric-dark.css +34 -7
  35. package/styles/fabric.css +37 -10
  36. package/styles/fluent-dark.css +1942 -0
  37. package/styles/fluent-dark.scss +1 -0
  38. package/styles/fluent.css +1942 -0
  39. package/styles/fluent.scss +1 -0
  40. package/styles/gantt/_bootstrap-dark-definition.scss +10 -2
  41. package/styles/gantt/_bootstrap-definition.scss +11 -3
  42. package/styles/gantt/_bootstrap4-definition.scss +10 -2
  43. package/styles/gantt/_bootstrap5-definition.scss +17 -9
  44. package/styles/gantt/_fabric-dark-definition.scss +8 -0
  45. package/styles/gantt/_fabric-definition.scss +10 -2
  46. package/styles/gantt/_fluent-dark-definition.scss +1 -0
  47. package/styles/gantt/_fluent-definition.scss +21 -13
  48. package/styles/gantt/_highcontrast-definition.scss +9 -1
  49. package/styles/gantt/_highcontrast-light-definition.scss +9 -1
  50. package/styles/gantt/_layout.scss +53 -2
  51. package/styles/gantt/_material-dark-definition.scss +9 -1
  52. package/styles/gantt/_material-definition.scss +10 -2
  53. package/styles/gantt/_tailwind-definition.scss +13 -5
  54. package/styles/gantt/_theme.scss +2 -5
  55. package/styles/gantt/bootstrap-dark.css +37 -10
  56. package/styles/gantt/bootstrap.css +37 -10
  57. package/styles/gantt/bootstrap4.css +37 -10
  58. package/styles/gantt/bootstrap5-dark.css +53 -19
  59. package/styles/gantt/bootstrap5.css +53 -19
  60. package/styles/gantt/fabric-dark.css +34 -7
  61. package/styles/gantt/fabric.css +37 -10
  62. package/styles/gantt/fluent-dark.css +1942 -0
  63. package/styles/gantt/fluent-dark.scss +22 -0
  64. package/styles/gantt/fluent.css +1942 -0
  65. package/styles/gantt/fluent.scss +22 -0
  66. package/styles/gantt/highcontrast-light.css +34 -7
  67. package/styles/gantt/highcontrast.css +34 -7
  68. package/styles/gantt/icons/_fluent-dark.scss +1 -0
  69. package/styles/gantt/icons/_fluent.scss +1 -1
  70. package/styles/gantt/icons/_tailwind-dark.scss +28 -29
  71. package/styles/gantt/icons/_tailwind.scss +26 -27
  72. package/styles/gantt/material-dark.css +37 -10
  73. package/styles/gantt/material.css +37 -10
  74. package/styles/gantt/tailwind-dark.css +70 -99
  75. package/styles/gantt/tailwind.css +70 -99
  76. package/styles/highcontrast-light.css +34 -7
  77. package/styles/highcontrast.css +34 -7
  78. package/styles/material-dark.css +37 -10
  79. package/styles/material.css +37 -10
  80. package/styles/tailwind-dark.css +70 -99
  81. package/styles/tailwind.css +70 -99
@@ -483,7 +483,6 @@ class DateProcessor {
483
483
  tDuration = this.parent.editModule.taskbarEditModule.sumOfDuration(ganttProperties.segments);
484
484
  }
485
485
  else {
486
- // eslint-disable-next-line
487
486
  if (!isNullOrUndefined(ganttProperties.startDate) && !isNullOrUndefined(ganttProperties.endDate) &&
488
487
  (ganttProperties.startDate).getTime() === (ganttProperties.endDate).getTime() && !isNullOrUndefined(ganttData.taskData[this.parent.taskFields.milestone])) {
489
488
  tDuration = 1;
@@ -4082,6 +4081,7 @@ class GanttChart {
4082
4081
  this.chartTimelineContainer = null;
4083
4082
  this.rangeViewContainer =
4084
4083
  createElement('div', { className: rangeContainer });
4084
+ this.rangeViewContainer.setAttribute("role", "RangeContainer");
4085
4085
  this.virtualRender = new VirtualContentRenderer(this.parent);
4086
4086
  this.addEventListener();
4087
4087
  }
@@ -4240,6 +4240,7 @@ class GanttChart {
4240
4240
  renderTimelineContainer() {
4241
4241
  this.chartTimelineContainer =
4242
4242
  createElement('div', { className: timelineHeaderContainer });
4243
+ this.chartTimelineContainer.setAttribute("role", "TimelineHeader");
4243
4244
  this.chartElement.appendChild(this.chartTimelineContainer);
4244
4245
  }
4245
4246
  /**
@@ -4279,8 +4280,19 @@ class GanttChart {
4279
4280
  //empty row height
4280
4281
  const emptydivHeight = 36;
4281
4282
  const emptyHeight = this.parent.contentHeight === 0 ? this.parent.flatData.length > 1 ? emptydivHeight : 0 : this.parent.contentHeight;
4282
- this.chartBodyContent.style.height = formatUnit(emptyHeight);
4283
- //let element: HTMLElement = this.chartTimelineContainer.querySelector('.' + cls.timelineHeaderTableContainer);
4283
+ let contentElement = this.parent.element.getElementsByClassName('e-chart-scroll-container e-content')[0];
4284
+ if (emptyHeight >= contentElement['offsetHeight']) {
4285
+ this.chartBodyContent.style.height = formatUnit(emptyHeight);
4286
+ }
4287
+ else {
4288
+ let scrollHeight = this.parent.element.getElementsByClassName('e-chart-rows-container')[0]['offsetHeight'];
4289
+ if (contentElement['offsetHeight'] >= scrollHeight) {
4290
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] - 17 + 'px';
4291
+ }
4292
+ else {
4293
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] + 'px';
4294
+ }
4295
+ } //let element: HTMLElement = this.chartTimelineContainer.querySelector('.' + cls.timelineHeaderTableContainer);
4284
4296
  this.chartBodyContent.style.width = formatUnit(this.parent.timelineModule.totalTimelineWidth);
4285
4297
  this.setVirtualHeight();
4286
4298
  this.parent.notify('updateHeight', {});
@@ -4312,7 +4324,21 @@ class GanttChart {
4312
4324
  if (this.chartBodyContent.clientHeight < this.chartBodyContainer.clientHeight) {
4313
4325
  if (lastRow) {
4314
4326
  addClass(lastRow.querySelectorAll('td'), 'e-lastrow');
4315
- this.chartBodyContent.style.height = formatUnit(this.parent.contentHeight + 1);
4327
+ const emptydivHeight = 36;
4328
+ const emptyHeight = this.parent.contentHeight === 0 ? this.parent.flatData.length > 1 ? emptydivHeight : 0 : this.parent.contentHeight;
4329
+ let contentElement = this.parent.element.getElementsByClassName('e-chart-scroll-container e-content')[0];
4330
+ if (emptyHeight >= contentElement['offsetHeight']) {
4331
+ this.chartBodyContent.style.height = formatUnit(emptyHeight);
4332
+ }
4333
+ else {
4334
+ let scrollHeight = this.parent.element.getElementsByClassName('e-chart-rows-container')[0]['offsetHeight'];
4335
+ if (contentElement['offsetHeight'] >= scrollHeight) {
4336
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] - 17 + 'px';
4337
+ }
4338
+ else {
4339
+ this.chartBodyContent.style.height = contentElement['offsetHeight'] + 'px';
4340
+ }
4341
+ }
4316
4342
  }
4317
4343
  }
4318
4344
  }
@@ -4444,7 +4470,7 @@ class GanttChart {
4444
4470
  const target = e.target;
4445
4471
  const isOnTaskbarElement = e.target.classList.contains(taskBarMainContainer)
4446
4472
  || closest(e.target, '.' + taskBarMainContainer);
4447
- if (closest(target, '.e-gantt-parent-taskbar')) {
4473
+ if (closest(target, '.e-gantt-parent-taskbar') && !this.parent.editSettings.allowEditing) {
4448
4474
  this.chartExpandCollapseRequest(e);
4449
4475
  }
4450
4476
  else if (!isOnTaskbarElement && this.parent.autoFocusTasks) {
@@ -4966,6 +4992,10 @@ class GanttChart {
4966
4992
  $target.classList.contains('e-headercell') || $target.closest('.e-segmented-taskbar')) {
4967
4993
  e.preventDefault();
4968
4994
  }
4995
+ if (isTab && $target.classList.contains('e-rowdragdrop')) {
4996
+ this.parent.treeGrid.grid.notify('key-pressed', e);
4997
+ return;
4998
+ }
4969
4999
  if ($target.classList.contains('e-rowcell') && (nextElement && nextElement.classList.contains('e-rowcell')) ||
4970
5000
  $target.classList.contains('e-headercell')) { // eslint-disable-line
4971
5001
  if (isTab) {
@@ -5008,7 +5038,7 @@ class GanttChart {
5008
5038
  else {
5009
5039
  this.manageFocus($target, 'remove', true);
5010
5040
  }
5011
- if (nextElement.classList.contains('e-rowcell')) {
5041
+ if (nextElement.classList.contains('e-rowcell') && $target.nextElementSibling) {
5012
5042
  if (!$target.classList.contains('e-rowcell')) {
5013
5043
  this.parent.treeGrid.grid.notify('key-pressed', e);
5014
5044
  const fmodule = getValue('focusModule', this.parent.treeGrid.grid);
@@ -5356,7 +5386,7 @@ class Timeline {
5356
5386
  const currentZoomingLevel = this.checkCurrentZoomingLevel();
5357
5387
  this.isZoomIn = isZoomIn;
5358
5388
  this.isZooming = true;
5359
- const currentLevel = isZoomIn ? currentZoomingLevel + 1 : currentZoomingLevel - 1;
5389
+ let currentLevel = isZoomIn ? currentZoomingLevel + 1 : currentZoomingLevel - 1;
5360
5390
  if (this.parent.toolbarModule) {
5361
5391
  if (isZoomIn) {
5362
5392
  if (currentLevel === this.parent.zoomingLevels[this.parent.zoomingLevels.length - 1].level) {
@@ -5375,6 +5405,9 @@ class Timeline {
5375
5405
  }
5376
5406
  }
5377
5407
  }
5408
+ currentLevel = this.parent.zoomingLevels.findIndex((tempLevel) => {
5409
+ return tempLevel.level === currentLevel;
5410
+ });
5378
5411
  let newTimeline = this.parent.zoomingLevels[currentLevel];
5379
5412
  const args = {
5380
5413
  requestType: isZoomIn ? 'beforeZoomIn' : 'beforeZoomOut',
@@ -6084,6 +6117,40 @@ class Timeline {
6084
6117
  } while ((startDate < endDate));
6085
6118
  return parentTh;
6086
6119
  }
6120
+ updateTimelineAfterZooming(endDate, resized) {
6121
+ let timeDiff;
6122
+ let perDayWidth;
6123
+ let totWidth;
6124
+ let contentElement = document.getElementsByClassName('e-chart-scroll-container e-content')[0];
6125
+ if (!isNullOrUndefined(contentElement)) {
6126
+ let contentWidth = contentElement['offsetWidth'];
6127
+ let contentHeight = contentElement['offsetHeight'];
6128
+ let scrollHeight = document.getElementsByClassName('e-chart-rows-container')[0]['offsetHeight'];
6129
+ timeDiff = Math.abs(this.timelineStartDate.getTime() - endDate.getTime());
6130
+ timeDiff = timeDiff / (1000 * 3600 * 24);
6131
+ if (this.bottomTier === 'None') {
6132
+ perDayWidth = this.getPerDayWidth(this.customTimelineSettings.timelineUnitSize, this.customTimelineSettings.topTier.count, this.topTier);
6133
+ }
6134
+ else {
6135
+ perDayWidth = this.getPerDayWidth(this.customTimelineSettings.timelineUnitSize, this.customTimelineSettings.bottomTier.count, this.bottomTier);
6136
+ }
6137
+ if (contentHeight < scrollHeight) {
6138
+ totWidth = (perDayWidth * timeDiff) + 17;
6139
+ }
6140
+ else {
6141
+ totWidth = (perDayWidth * timeDiff);
6142
+ }
6143
+ if (contentWidth >= totWidth) {
6144
+ let widthDiff = contentWidth - totWidth;
6145
+ widthDiff = Math.round(widthDiff / perDayWidth);
6146
+ endDate.setDate(endDate.getDate() + widthDiff);
6147
+ this.parent.timelineModule.timelineEndDate = endDate;
6148
+ if (resized) {
6149
+ this.parent.updateProjectDates(this.timelineStartDate, this.timelineEndDate, this.parent.isTimelineRoundOff);
6150
+ }
6151
+ }
6152
+ }
6153
+ }
6087
6154
  getTimelineRoundOffEndDate(date) {
6088
6155
  const tierMode = this.topTier === 'None' ? this.bottomTier : this.topTier;
6089
6156
  const endDate = new Date(date.toString());
@@ -6098,6 +6165,9 @@ class Timeline {
6098
6165
  endDate.setHours(24, 0, 0, 0);
6099
6166
  }
6100
6167
  }
6168
+ if (this.isZooming || this.parent.isLoad) {
6169
+ this.updateTimelineAfterZooming(endDate, false);
6170
+ }
6101
6171
  return endDate;
6102
6172
  }
6103
6173
  /**
@@ -6167,7 +6237,6 @@ class Timeline {
6167
6237
  }
6168
6238
  return increment;
6169
6239
  }
6170
- ;
6171
6240
  /**
6172
6241
  * Method to find header cell was weekend or not
6173
6242
  *
@@ -6746,6 +6815,8 @@ class GanttTreeGrid {
6746
6815
  renderTreeGrid() {
6747
6816
  this.composeProperties();
6748
6817
  this.bindEvents();
6818
+ const root = 'root';
6819
+ this.parent.treeGrid[root] = this.parent[root] ? this.parent[root] : this.parent;
6749
6820
  this.parent.treeGrid.appendTo(this.treeGridElement);
6750
6821
  this.wireEvents();
6751
6822
  }
@@ -6809,7 +6880,7 @@ class GanttTreeGrid {
6809
6880
  const scrollWidth = this.getScrollbarWidth();
6810
6881
  const isMobile = /Android|Mac|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);
6811
6882
  if (scrollWidth !== 0) {
6812
- content.style.cssText += 'width: calc(100% + ' + scrollWidth + 'px);';
6883
+ content.style.cssText += 'width: calc(100% + ' + (scrollWidth + 1) + 'px);';
6813
6884
  }
6814
6885
  else {
6815
6886
  content.classList.add('e-gantt-scroll-padding');
@@ -7835,7 +7906,7 @@ class ChartRows extends DateProcessor {
7835
7906
  this.milestoneHeight = 0;
7836
7907
  this.milesStoneRadius = 0;
7837
7908
  this.baselineTop = 0;
7838
- this.baselineHeight = 3;
7909
+ this.baselineHeight = 8;
7839
7910
  this.touchLeftConnectorpoint = '';
7840
7911
  this.touchRightConnectorpoint = '';
7841
7912
  this.dropSplit = false;
@@ -7917,7 +7988,7 @@ class ChartRows extends DateProcessor {
7917
7988
  * @private
7918
7989
  */
7919
7990
  getIndicatorNode(indicator) {
7920
- const templateString = '<label class="' + label + ' ' + taskIndicatorDiv + '" style="line-height:'
7991
+ const templateString = '<label class="' + label + ' ' + taskIndicatorDiv + '" role="LabelIndicator" style="line-height:'
7921
7992
  + (this.parent.rowHeight) + 'px;' +
7922
7993
  'left:' + this.getIndicatorleft(indicator.date) + 'px;"><i class="' + indicator.iconClass + '"></i> </label>';
7923
7994
  return this.createDivElement(templateString);
@@ -7946,7 +8017,7 @@ class ChartRows extends DateProcessor {
7946
8017
  let childTaskbarNode = null;
7947
8018
  const data = this.templateData;
7948
8019
  if (this.childTaskbarTemplateFunction) {
7949
- childTaskbarNode = this.childTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'TaskbarTemplate', this.getTemplateID('TaskbarTemplate'), false, undefined, rootElement[0]);
8020
+ childTaskbarNode = this.childTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'TaskbarTemplate', this.getTemplateID('TaskbarTemplate'), false, undefined, rootElement[0], this.parent.treeGrid['root']);
7950
8021
  }
7951
8022
  else {
7952
8023
  let labelString = '';
@@ -7990,9 +8061,9 @@ class ChartRows extends DateProcessor {
7990
8061
  }
7991
8062
  else {
7992
8063
  taskLabel$$1 = '<span class="' + taskLabel + '" style="line-height:' +
7993
- (this.taskBarHeight - 1) + 'px; text-align:' + (this.parent.viewType === 'ResourceView' ? 'left;' : ';') +
7994
- 'display:' + (this.parent.viewType === 'ResourceView' ? 'inline-flex;' : ';') +
7995
- 'width:' + (this.parent.viewType === 'ResourceView' ? (data.ganttProperties.width - 10) : '') + 'px; height:' +
8064
+ (this.taskBarHeight - 1) + 'px;' + (this.parent.viewType === 'ResourceView' ? 'text-align: left;' : '') +
8065
+ +(this.parent.viewType === 'ResourceView' ? 'display:inline-flex;' : '') +
8066
+ +(this.parent.viewType === 'ResourceView' ? (data.ganttProperties.width - 10) : '') + 'px; height:' +
7996
8067
  this.taskBarHeight + 'px;">' + labelString + '</span>';
7997
8068
  }
7998
8069
  }
@@ -8385,7 +8456,7 @@ class ChartRows extends DateProcessor {
8385
8456
  let milestoneNode = null;
8386
8457
  const data = this.templateData;
8387
8458
  if (this.milestoneTemplateFunction) {
8388
- milestoneNode = this.milestoneTemplateFunction(extend({ index: i }, data), this.parent, 'MilestoneTemplate', this.getTemplateID('MilestoneTemplate'), false, undefined, rootElement[0]);
8459
+ milestoneNode = this.milestoneTemplateFunction(extend({ index: i }, data), this.parent, 'MilestoneTemplate', this.getTemplateID('MilestoneTemplate'), false, undefined, rootElement[0], this.parent.treeGrid['root']);
8389
8460
  }
8390
8461
  else {
8391
8462
  const template = '<div class="' + traceMilestone + '" style="position:absolute;">' +
@@ -8409,7 +8480,7 @@ class ChartRows extends DateProcessor {
8409
8480
  */
8410
8481
  getTaskBaselineNode() {
8411
8482
  const data = this.templateData;
8412
- const template = '<div class="' + baselineBar + ' ' + '" style="margin-top:' + this.baselineTop +
8483
+ const template = '<div class="' + baselineBar + ' ' + '" role="BaselineBar" style="margin-top:' + this.baselineTop +
8413
8484
  'px;left:' + data.ganttProperties.baselineLeft + 'px;' +
8414
8485
  'width:' + data.ganttProperties.baselineWidth + 'px;height:' +
8415
8486
  this.baselineHeight + 'px;' + (this.baselineColor ? 'background-color: ' + this.baselineColor + ';' : '') + '"></div>';
@@ -8423,9 +8494,10 @@ class ChartRows extends DateProcessor {
8423
8494
  */
8424
8495
  getMilestoneBaselineNode() {
8425
8496
  const data = this.templateData;
8497
+ let baselineMilestoneHeight = this.parent.renderBaseline ? 5 : 2;
8426
8498
  const template = '<div class="' + baselineMilestoneContainer + ' ' + '" style="' +
8427
8499
  'left:' + (data.ganttProperties.baselineLeft - this.milesStoneRadius) + 'px;' +
8428
- 'margin-top:' + (-Math.floor(this.parent.rowHeight - this.milestoneMarginTop) + 2) +
8500
+ 'margin-top:' + (-Math.floor(this.parent.rowHeight - this.milestoneMarginTop) + baselineMilestoneHeight) +
8429
8501
  'px">' + '<div class="' + baselineMilestoneDiv + '">' + '<div class="' + baselineMilestoneDiv +
8430
8502
  ' ' + baselineMilestoneTop + '" ' +
8431
8503
  'style="top:' + (-this.milestoneHeight) + 'px;border-right:' + this.milesStoneRadius +
@@ -8453,10 +8525,12 @@ class ChartRows extends DateProcessor {
8453
8525
  */
8454
8526
  getLeftLabelNode(i) {
8455
8527
  const leftLabelNode = this.leftLabelContainer();
8456
- leftLabelNode[0].setAttribute('aria-label', this.generateTaskLabelAriaLabel('left'));
8528
+ if (this.generateTaskLabelAriaLabel('left') !== "") {
8529
+ leftLabelNode[0].setAttribute('aria-label', this.generateTaskLabelAriaLabel('left'));
8530
+ }
8457
8531
  let leftLabelTemplateNode = null;
8458
8532
  if (this.leftTaskLabelTemplateFunction) {
8459
- leftLabelTemplateNode = this.leftTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'LeftLabelTemplate', this.getTemplateID('LeftLabelTemplate'), false, undefined, leftLabelNode[0]);
8533
+ leftLabelTemplateNode = this.leftTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'LeftLabelTemplate', this.getTemplateID('LeftLabelTemplate'), false, undefined, leftLabelNode[0], this.parent.treeGrid['root']);
8460
8534
  }
8461
8535
  else {
8462
8536
  const field = this.parent.labelSettings.leftLabel;
@@ -8467,14 +8541,18 @@ class ChartRows extends DateProcessor {
8467
8541
  }
8468
8542
  }
8469
8543
  if (leftLabelTemplateNode && leftLabelTemplateNode.length > 0) {
8544
+ if (leftLabelTemplateNode[0]['data'] === 'null') {
8545
+ leftLabelTemplateNode[0]['data'] = '';
8546
+ }
8470
8547
  leftLabelNode[0].appendChild([].slice.call(leftLabelTemplateNode)[0]);
8471
8548
  }
8472
8549
  return leftLabelNode;
8473
8550
  }
8474
8551
  getLableText(labelString, labelDiv) {
8552
+ let leftLabelHeight = this.parent.renderBaseline ? ((this.parent.rowHeight - this.taskBarHeight) / 2) : this.taskBarMarginTop;
8475
8553
  const templateString = createElement('div', {
8476
8554
  className: labelDiv, styles: 'height:' + (this.taskBarHeight) + 'px;' +
8477
- 'margin-top:' + this.taskBarMarginTop + 'px;'
8555
+ 'margin-top:' + leftLabelHeight + 'px;'
8478
8556
  });
8479
8557
  const spanElem = createElement('span', { className: label });
8480
8558
  const property = this.parent.disableHtmlEncode ? 'textContent' : 'innerHTML';
@@ -8493,10 +8571,12 @@ class ChartRows extends DateProcessor {
8493
8571
  */
8494
8572
  getRightLabelNode(i) {
8495
8573
  const rightLabelNode = this.rightLabelContainer();
8496
- rightLabelNode[0].setAttribute('aria-label', this.generateTaskLabelAriaLabel('right'));
8574
+ if (this.generateTaskLabelAriaLabel('right') !== "") {
8575
+ rightLabelNode[0].setAttribute('aria-label', this.generateTaskLabelAriaLabel('right'));
8576
+ }
8497
8577
  let rightLabelTemplateNode = null;
8498
8578
  if (this.rightTaskLabelTemplateFunction) {
8499
- rightLabelTemplateNode = this.rightTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'RightLabelTemplate', this.getTemplateID('RightLabelTemplate'), false, undefined, rightLabelNode[0]);
8579
+ rightLabelTemplateNode = this.rightTaskLabelTemplateFunction(extend({ index: i }, this.templateData), this.parent, 'RightLabelTemplate', this.getTemplateID('RightLabelTemplate'), false, undefined, rightLabelNode[0], this.parent.treeGrid['root']);
8500
8580
  }
8501
8581
  else {
8502
8582
  const field = this.parent.labelSettings.rightLabel;
@@ -8507,6 +8587,9 @@ class ChartRows extends DateProcessor {
8507
8587
  }
8508
8588
  }
8509
8589
  if (rightLabelTemplateNode && rightLabelTemplateNode.length > 0) {
8590
+ if (rightLabelTemplateNode[0]['data'] === 'null') {
8591
+ rightLabelTemplateNode[0]['data'] = '';
8592
+ }
8510
8593
  rightLabelNode[0].appendChild([].slice.call(rightLabelTemplateNode)[0]);
8511
8594
  }
8512
8595
  return rightLabelNode;
@@ -8561,7 +8644,7 @@ class ChartRows extends DateProcessor {
8561
8644
  let parentTaskbarNode = null;
8562
8645
  const data = this.templateData;
8563
8646
  if (this.parentTaskbarTemplateFunction) {
8564
- parentTaskbarNode = this.parentTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'ParentTaskbarTemplate', this.getTemplateID('ParentTaskbarTemplate'), false, undefined, rootElement[0]);
8647
+ parentTaskbarNode = this.parentTaskbarTemplateFunction(extend({ index: i }, data), this.parent, 'ParentTaskbarTemplate', this.getTemplateID('ParentTaskbarTemplate'), false, undefined, rootElement[0], this.parent.treeGrid['root']);
8565
8648
  }
8566
8649
  else {
8567
8650
  let labelString = '';
@@ -8603,8 +8686,10 @@ class ChartRows extends DateProcessor {
8603
8686
  else {
8604
8687
  labelDiv = this.createDivElement('<span class="' +
8605
8688
  taskLabel + '" style="line-height:' +
8606
- (this.taskBarHeight - 1) + 'px; display:' + (this.parent.viewType === 'ResourceView' ? 'inline-flex;' : ';') + 'width:' +
8607
- (this.parent.viewType === 'ResourceView' ? (data.ganttProperties.width - 10) : ';') + 'px; height:' +
8689
+ (this.taskBarHeight - 1) + 'px;' + (this.parent.viewType === 'ResourceView' ? 'display:inline-flex;' : '') +
8690
+ (this.parent.viewType === 'ResourceView' ? 'width:' + (data.ganttProperties.width - 10) : '') + 'px; height:' +
8691
+ (this.taskBarHeight - 1) + 'px;' + (this.parent.viewType === 'ResourceView' ? 'display: inline-flex;' : '') +
8692
+ (this.parent.viewType === 'ResourceView' ? 'width:' + (data.ganttProperties.width - 10) : '') + 'px; height:' +
8608
8693
  this.taskBarHeight + 'px;">' + labelString + '</span>');
8609
8694
  }
8610
8695
  progressBarInnerDiv[0].appendChild([].slice.call(labelDiv)[0]);
@@ -8633,10 +8718,10 @@ class ChartRows extends DateProcessor {
8633
8718
  const className = (this.parent.gridLines === 'Horizontal' || this.parent.gridLines === 'Both') ?
8634
8719
  'e-chart-row-border' : '';
8635
8720
  table.innerHTML = '<tr class="' + this.getRowClassName(this.templateData) + ' ' + chartRow + '"' +
8636
- 'style="display:' + this.getExpandDisplayProp(this.templateData) + ';height:' +
8721
+ 'role="ChartRow" style="display:' + this.getExpandDisplayProp(this.templateData) + ';height:' +
8637
8722
  this.parent.rowHeight + 'px;">' +
8638
8723
  '<td class="' + chartRowCell + ' ' + className
8639
- + '" style="width:' + this.parent.timelineModule.totalTimelineWidth + 'px;"></td></tr>';
8724
+ + '" role="ChartCell" style="width:' + this.parent.timelineModule.totalTimelineWidth + 'px;"></td></tr>';
8640
8725
  return table.childNodes;
8641
8726
  }
8642
8727
  /**
@@ -8675,10 +8760,19 @@ class ChartRows extends DateProcessor {
8675
8760
  }
8676
8761
  isTemplate(template) {
8677
8762
  let result = false;
8763
+ for (let i = 0; i < this.parent.ganttColumns.length; i++) {
8764
+ if (template === this.parent.ganttColumns[i].field) {
8765
+ result = true;
8766
+ break;
8767
+ }
8768
+ }
8678
8769
  if (typeof template !== 'string' || template.indexOf('#') === 0 || template.indexOf('<') > -1
8679
- || template.indexOf('$') > -1) {
8770
+ || template.indexOf('$') > -1 || !result) {
8680
8771
  result = true;
8681
8772
  }
8773
+ else {
8774
+ result = false;
8775
+ }
8682
8776
  return result;
8683
8777
  }
8684
8778
  /**
@@ -8692,8 +8786,8 @@ class ChartRows extends DateProcessor {
8692
8786
  }
8693
8787
  leftLabelContainer() {
8694
8788
  const template = '<div class="' + ((this.leftTaskLabelTemplateFunction) ? leftLabelTempContainer :
8695
- leftLabelContainer) + ' ' + '" tabindex="-1" style="height:' +
8696
- (this.parent.rowHeight - 1) + 'px;width:' + this.taskNameWidth(this.templateData) + '"></div>';
8789
+ leftLabelContainer) + ' ' + '" tabindex="-1" role="LeftLabel" style="height:' +
8790
+ (this.parent.rowHeight - 2) + 'px;width:' + this.taskNameWidth(this.templateData) + '"></div>';
8697
8791
  return this.createDivElement(template);
8698
8792
  }
8699
8793
  taskbarContainer() {
@@ -8704,7 +8798,7 @@ class ChartRows extends DateProcessor {
8704
8798
  const template = '<div class="' + taskBarMainContainer + ' ' +
8705
8799
  this.parent.getUnscheduledTaskClass(data.ganttProperties) + ' ' +
8706
8800
  ((data.ganttProperties.cssClass) ? data.ganttProperties.cssClass : '') + '" ' +
8707
- ' tabindex="-1" style="' + ((data.ganttProperties.isMilestone && !manualParent) ?
8801
+ ' tabindex="-1" role="TaskBar" style="' + ((data.ganttProperties.isMilestone && !manualParent) ?
8708
8802
  ('width:' + this.milestoneHeight + 'px;height:' +
8709
8803
  this.milestoneHeight + 'px;margin-top:' + this.milestoneMarginTop + 'px;left:' + (data.ganttProperties.left -
8710
8804
  (this.milestoneHeight / 2)) + 'px;') : ('width:' + data.ganttProperties.width +
@@ -8715,26 +8809,26 @@ class ChartRows extends DateProcessor {
8715
8809
  }
8716
8810
  rightLabelContainer() {
8717
8811
  const template = '<div class="' + ((this.rightTaskLabelTemplateFunction) ? rightLabelTempContainer :
8718
- rightLabelContainer) + '" ' + ' tabindex="-1" style="left:' + this.getRightLabelLeft(this.templateData) + 'px;height:'
8719
- + (this.parent.rowHeight - 1) + 'px;"></div>';
8812
+ rightLabelContainer) + '" ' + ' tabindex="-1" role="RightLabel" style="left:' + this.getRightLabelLeft(this.templateData) + 'px; height:'
8813
+ + (this.parent.rowHeight - 2) + 'px;"></div>';
8720
8814
  return this.createDivElement(template);
8721
8815
  }
8722
8816
  childTaskbarLeftResizer() {
8723
8817
  const lResizerLeft = -(this.parent.isAdaptive ? 12 : 2);
8724
8818
  const template = '<div class="' + taskBarLeftResizer + ' ' + icon + '"' +
8725
- ' style="left:' + lResizerLeft + 'px;height:' + (this.taskBarHeight) + 'px;"></div>';
8819
+ ' role="LeftResizer" style="left:' + lResizerLeft + 'px;height:' + (this.taskBarHeight) + 'px;"></div>';
8726
8820
  return this.createDivElement(template);
8727
8821
  }
8728
8822
  childTaskbarRightResizer() {
8729
8823
  const rResizerLeft = this.parent.isAdaptive ? -2 : -10;
8730
8824
  const template = '<div class="' + taskBarRightResizer + ' ' + icon + '"' +
8731
- ' style="left:' + (this.templateData.ganttProperties.width + rResizerLeft) + 'px;' +
8825
+ ' role="RightResizer" style="left:' + (this.templateData.ganttProperties.width + rResizerLeft) + 'px;' +
8732
8826
  'height:' + (this.taskBarHeight) + 'px;"></div>';
8733
8827
  return this.createDivElement(template);
8734
8828
  }
8735
8829
  childTaskbarProgressResizer() {
8736
8830
  const template = '<div class="' + childProgressResizer + '"' +
8737
- ' style="left:' + (this.templateData.ganttProperties.progressWidth - 6) + 'px;margin-top:' +
8831
+ ' role="ProgressResizer" style="left:' + (this.templateData.ganttProperties.progressWidth - 6) + 'px;margin-top:' +
8738
8832
  (this.taskBarHeight - 4) + 'px;"><div class="' + progressBarHandler + '"' +
8739
8833
  '><div class="' + progressHandlerElement + '"></div>' +
8740
8834
  '<div class="' + progressBarHandlerAfter + '"></div></div>';
@@ -8932,10 +9026,13 @@ class ChartRows extends DateProcessor {
8932
9026
  * @private
8933
9027
  */
8934
9028
  initChartHelperPrivateVariable() {
9029
+ let taskbarHeightValue = this.parent.renderBaseline ? 0.45 : 0.62;
9030
+ let taskBarMarginTopValue = this.parent.renderBaseline ? 4 : 2;
9031
+ let milestoneHeightValue = this.parent.renderBaseline ? 1.13 : 0.82;
8935
9032
  this.baselineColor = !isNullOrUndefined(this.parent.baselineColor) &&
8936
9033
  this.parent.baselineColor !== '' ? this.parent.baselineColor : null;
8937
9034
  this.taskBarHeight = isNullOrUndefined(this.parent.taskbarHeight) || this.parent.taskbarHeight >= this.parent.rowHeight ?
8938
- Math.floor(this.parent.rowHeight * 0.62) : this.parent.taskbarHeight; // 0.62 -- Standard Ratio.
9035
+ Math.floor(this.parent.rowHeight * taskbarHeightValue) : this.parent.taskbarHeight; // 0.62 -- Standard Ratio.
8939
9036
  if (this.parent.renderBaseline) {
8940
9037
  let height;
8941
9038
  if ((this.taskBarHeight + this.baselineHeight) <= this.parent.rowHeight) {
@@ -8946,11 +9043,11 @@ class ChartRows extends DateProcessor {
8946
9043
  }
8947
9044
  this.taskBarHeight = height;
8948
9045
  }
8949
- this.milestoneHeight = Math.floor(this.taskBarHeight * 0.82); // 0.82 -- Standard Ratio.
8950
- this.taskBarMarginTop = Math.floor((this.parent.rowHeight - this.taskBarHeight) / 2);
9046
+ this.milestoneHeight = Math.floor(this.taskBarHeight * milestoneHeightValue); // 0.82 -- Standard Ratio.
9047
+ this.taskBarMarginTop = Math.floor((this.parent.rowHeight - this.taskBarHeight) / taskBarMarginTopValue);
8951
9048
  this.milestoneMarginTop = Math.floor((this.parent.rowHeight - this.milestoneHeight) / 2);
8952
9049
  this.milesStoneRadius = Math.floor((this.milestoneHeight) / 2);
8953
- this.baselineTop = -(Math.floor((this.parent.rowHeight - (this.taskBarHeight + this.taskBarMarginTop))) - 1);
9050
+ this.baselineTop = -(Math.floor((this.parent.rowHeight - (this.taskBarHeight + this.taskBarMarginTop))) - 4);
8954
9051
  this.connectorPointWidth = this.parent.isAdaptive ? Math.round(this.taskBarHeight / 2) : 8;
8955
9052
  this.connectorPointMargin = Math.floor((this.taskBarHeight / 2) - (this.connectorPointWidth / 2));
8956
9053
  }
@@ -9144,6 +9241,7 @@ class ChartRows extends DateProcessor {
9144
9241
  const indicators = this.templateData.ganttProperties.indicators;
9145
9242
  for (let indicatorIndex = 0; indicatorIndex < indicators.length; indicatorIndex++) {
9146
9243
  taskIndicatorNode = this.getIndicatorNode(indicators[indicatorIndex]);
9244
+ taskIndicatorNode[0].setAttribute('aria-label', indicators[indicatorIndex].name);
9147
9245
  if (indicators[indicatorIndex].name.indexOf('$') > -1 || indicators[indicatorIndex].name.indexOf('#') > -1) {
9148
9246
  taskIndicatorTextFunction = this.templateCompiler(indicators[indicatorIndex].name);
9149
9247
  taskIndicatorTextNode = taskIndicatorTextFunction(extend({ index: i }, this.templateData), this.parent, 'indicatorLabelText');
@@ -10362,7 +10460,7 @@ class ConnectorLine {
10362
10460
  for (let i = 0; i < childNodes.length; i++) {
10363
10461
  const innerChild = childNodes[i].childNodes;
10364
10462
  for (let j = 0; j < innerChild.length; j++) {
10365
- const ariaString = this.parent.connectorLineModule.generateAriaLabel(ariaConnector[i]);
10463
+ const ariaString = 'Connector Line ' + this.parent.connectorLineModule.generateAriaLabel(ariaConnector[i]);
10366
10464
  innerChild[j].setAttribute('aria-label', ariaString);
10367
10465
  }
10368
10466
  }
@@ -10619,7 +10717,11 @@ class ConnectorLine {
10619
10717
  let connectorContainer = '';
10620
10718
  const isVirtual = this.parent.virtualScrollModule && this.parent.enableVirtualization;
10621
10719
  const connectorLine$$1 = this.getPosition(data, this.getParentPosition(data), height);
10622
- const heightValue = isVirtual ? connectorLine$$1.height : height;
10720
+ let isMilestoneValue = 0;
10721
+ if (this.parent.renderBaseline) {
10722
+ isMilestoneValue = (data.milestoneParent && data.milestoneChild) ? 0 : data.milestoneParent ? -5 : data.milestoneChild ? 5 : 0;
10723
+ }
10724
+ const heightValue = isVirtual ? connectorLine$$1.height : (height + isMilestoneValue);
10623
10725
  if (this.getParentPosition(data)) {
10624
10726
  connectorContainer = '<div id="ConnectorLine' + data.connectorLineId + '" style="background-color:black">';
10625
10727
  let div = '<div class="' + connectorLineContainer +
@@ -10647,7 +10749,7 @@ class ConnectorLine {
10647
10749
  this.getBorderStyles('top', this.lineStroke) + 'position:relative;"></div>';
10648
10750
  if (this.getParentPosition(data) === 'FSType1') {
10649
10751
  div = div + 'left:' + (data.parentLeft + data.parentWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10650
- ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
10752
+ ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10651
10753
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FSType1">';
10652
10754
  div = div + eLine;
10653
10755
  div = div + 'left:' + (isMilestoneParent ? -1 : 0) + 'px;width:' + (isMilestoneParent ?
@@ -10668,7 +10770,7 @@ class ConnectorLine {
10668
10770
  }
10669
10771
  if (this.getParentPosition(data) === 'FSType2') {
10670
10772
  div = div + 'left:' + data.parentLeft + 'px;top:' + (isVirtual ? connectorLine$$1.top : ((data.parentIndex * data.rowHeight) +
10671
- this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
10773
+ this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10672
10774
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FSType2">';
10673
10775
  div = div + eLine;
10674
10776
  div = div + 'left:' + (isMilestoneParent ? data.parentWidth - 1 : data.parentWidth) + 'px;width:' +
@@ -10699,7 +10801,7 @@ class ConnectorLine {
10699
10801
  }
10700
10802
  if (this.getParentPosition(data) === 'FSType3') {
10701
10803
  div = div + 'left:' + (data.childLeft - 20) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10702
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1))) + 'px;' +
10804
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10703
10805
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FSType3">';
10704
10806
  div = div + rightArrow;
10705
10807
  div = div + 'left:10px;' + this.getBorderStyles('left', 10) +
@@ -10729,7 +10831,7 @@ class ConnectorLine {
10729
10831
  }
10730
10832
  if (this.getParentPosition(data) === 'FSType4') {
10731
10833
  div = div + 'left:' + (data.parentLeft + data.parentWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10732
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
10834
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10733
10835
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FSType4">';
10734
10836
  div = div + rightArrow;
10735
10837
  div = div + 'left:' + (data.childLeft - (data.parentLeft + data.parentWidth + 10)) + 'px;' +
@@ -10755,7 +10857,7 @@ class ConnectorLine {
10755
10857
  }
10756
10858
  if (this.getParentPosition(data) === 'SSType4') {
10757
10859
  div = div + 'left:' + (data.parentLeft - 10) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10758
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
10860
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10759
10861
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="SSType4">';
10760
10862
  div = div + rightArrow;
10761
10863
  div = div + 'left:' + (data.childLeft - data.parentLeft) + 'px;' + duplicateStingTwo;
@@ -10768,7 +10870,7 @@ class ConnectorLine {
10768
10870
  }
10769
10871
  if (this.getParentPosition(data) === 'SSType3') {
10770
10872
  div = div + 'left:' + (data.childLeft - 20) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10771
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
10873
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10772
10874
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="SSType3">';
10773
10875
  div = div + rightArrow;
10774
10876
  div = div + 'left:10px;' + duplicateStingTwo;
@@ -10781,7 +10883,7 @@ class ConnectorLine {
10781
10883
  }
10782
10884
  if (this.getParentPosition(data) === 'SSType2') {
10783
10885
  div = div + 'left:' + setInnerElementLeftSSType2 + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10784
- ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1))) + 'px;' +
10886
+ ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10785
10887
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="SSType2">';
10786
10888
  div = div + eLine;
10787
10889
  div = div + 'width:' + (setInnerChildWidthSSType2 + 1) + 'px;' +
@@ -10802,7 +10904,7 @@ class ConnectorLine {
10802
10904
  if (this.getParentPosition(data) === 'SSType1') {
10803
10905
  div = div + 'left:' + (data.childLeft - 20) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10804
10906
  ((data.parentIndex * data.rowHeight) +
10805
- this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1))) + 'px;' +
10907
+ this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10806
10908
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="SSType1">';
10807
10909
  div = div + eLine;
10808
10910
  div = div + 'width:' + (data.parentLeft - data.childLeft + 21) + 'px;' +
@@ -10819,7 +10921,7 @@ class ConnectorLine {
10819
10921
  }
10820
10922
  if (this.getParentPosition(data) === 'FFType1') {
10821
10923
  div = div + 'left:' + (data.childLeft + data.childWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10822
- ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1))) + 'px;' +
10924
+ ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10823
10925
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FFType1">';
10824
10926
  div = div + eLine;
10825
10927
  div = div + 'left:' + (isMilestoneParent ? (((data.parentLeft + data.parentWidth) -
@@ -10843,7 +10945,7 @@ class ConnectorLine {
10843
10945
  }
10844
10946
  if (this.getParentPosition(data) === 'FFType2') {
10845
10947
  div = div + 'left:' + (data.parentLeft + data.parentWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10846
- ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1))) + 'px;' +
10948
+ ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10847
10949
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FFType2">';
10848
10950
  div = div + eLine;
10849
10951
  div = div + (isMilestoneParent ? 'left:-1px;' : '') + 'width:' +
@@ -10869,7 +10971,7 @@ class ConnectorLine {
10869
10971
  }
10870
10972
  if (this.getParentPosition(data) === 'FFType3') {
10871
10973
  div = div + 'left:' + (data.childLeft + data.childWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10872
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
10974
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10873
10975
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FFType3">';
10874
10976
  div = div + duplicateStingOne;
10875
10977
  div = div + eLine;
@@ -10892,7 +10994,7 @@ class ConnectorLine {
10892
10994
  }
10893
10995
  if (this.getParentPosition(data) === 'FFType4') {
10894
10996
  div = div + 'left:' + (data.parentLeft + data.parentWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10895
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
10997
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10896
10998
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="FFType4">';
10897
10999
  div = div + leftArrow;
10898
11000
  div = div + ('left:' + ((data.childLeft + data.childWidth) -
@@ -10921,7 +11023,7 @@ class ConnectorLine {
10921
11023
  }
10922
11024
  if (this.getParentPosition(data) === 'SFType4') {
10923
11025
  div = div + 'left:' + (data.parentLeft - 10) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10924
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;width:1px;' +
11026
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;width:1px;' +
10925
11027
  'height:' + heightValue + 'px;position:absolute" data-connectortype="SFType4">';
10926
11028
  div = div + duplicateStingFour + 'top:' + (-5 - this.lineStroke + (this.lineStroke - 1)) + 'px;' +
10927
11029
  'border-bottom-width:' + (5 + this.lineStroke) +
@@ -10949,7 +11051,7 @@ class ConnectorLine {
10949
11051
  }
10950
11052
  if (this.getParentPosition(data) === 'SFType3') {
10951
11053
  div = div + 'left:' + (data.childLeft + data.childWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10952
- ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
11054
+ ((data.childIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10953
11055
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="SFType3">';
10954
11056
  div = div + duplicateStingOne;
10955
11057
  div = div + eLine;
@@ -10967,7 +11069,7 @@ class ConnectorLine {
10967
11069
  }
10968
11070
  if (this.getParentPosition(data) === 'SFType1') {
10969
11071
  div = div + 'left:' + (data.parentLeft - 10) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10970
- ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1))) + 'px;' +
11072
+ ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestone) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10971
11073
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="SFType1">';
10972
11074
  div = div + eLine;
10973
11075
  div = div + 'width:11px;' + this.getBorderStyles('top', this.lineStroke) + 'position:relative;"></div>';
@@ -10992,7 +11094,7 @@ class ConnectorLine {
10992
11094
  }
10993
11095
  if (this.getParentPosition(data) === 'SFType2') {
10994
11096
  div = div + 'left:' + (data.childLeft + data.childWidth) + 'px;top:' + (isVirtual ? connectorLine$$1.top :
10995
- ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1))) + 'px;' +
11097
+ ((data.parentIndex * data.rowHeight) + this.getTaskbarMidpoint(isMilestoneParent) - (this.lineStroke - 1) - isMilestoneValue)) + 'px;' +
10996
11098
  'width:1px;height:' + heightValue + 'px;position:absolute" data-connectortype="SFType2">';
10997
11099
  div = div + eLine;
10998
11100
  div = div + 'left:' + (((data.parentLeft) - (data.childLeft + data.childWidth)) - 10) +
@@ -11234,6 +11336,7 @@ class Splitter$1 {
11234
11336
  this.splitterObject.paneSettings[1].size = null;
11235
11337
  this.splitterObject.paneSettings[1].size = this.getSpliterPositionInPercentage(this.splitterPreviousPositionChart);
11236
11338
  }
11339
+ this.parent.timelineModule.updateTimelineAfterZooming(this.parent.timelineModule.timelineEndDate, true);
11237
11340
  callBackPromise.resolve(splitterResizedArgs);
11238
11341
  });
11239
11342
  return callBackPromise;
@@ -11515,6 +11618,7 @@ class Tooltip$1 {
11515
11618
  * @returns {void} .
11516
11619
  */
11517
11620
  updateTooltipPosition(args) {
11621
+ args.element.style.visibility = 'visible';
11518
11622
  if (isNullOrUndefined(this.tooltipMouseEvent) || args.target.classList.contains('e-notes-info')) {
11519
11623
  return;
11520
11624
  }
@@ -11544,7 +11648,6 @@ class Tooltip$1 {
11544
11648
  tooltipPositionY = tooltipPositionY + 10;
11545
11649
  }
11546
11650
  args.element.style.top = tooltipPositionY + 'px';
11547
- args.element.style.visibility = 'visible';
11548
11651
  }
11549
11652
  /**
11550
11653
  * Method to get mouse pointor position
@@ -11586,9 +11689,16 @@ class Tooltip$1 {
11586
11689
  switch (elementType) {
11587
11690
  case 'milestone':
11588
11691
  {
11589
- const sDate = !isNullOrUndefined(data.startDate) ? '<tr><td class = "e-gantt-tooltip-label"> Date</td><td>:</td>' +
11692
+ let milestoneStartDate;
11693
+ if (args.target.className.includes('e-baseline-gantt-milestone') && !isNullOrUndefined(data.baselineStartDate)) {
11694
+ milestoneStartDate = data.baselineStartDate;
11695
+ }
11696
+ else if (!isNullOrUndefined(data.startDate)) {
11697
+ milestoneStartDate = data.startDate;
11698
+ }
11699
+ const sDate = !isNullOrUndefined(milestoneStartDate) ? '<tr><td class = "e-gantt-tooltip-label"> Date</td><td>:</td>' +
11590
11700
  '<td class = "e-gantt-tooltip-value">' +
11591
- this.parent.getFormatedDate(data.startDate, this.parent.getDateFormat()) + '</td></tr>' : '';
11701
+ this.parent.getFormatedDate(milestoneStartDate, this.parent.getDateFormat()) + '</td></tr>' : '';
11592
11702
  content$$1 = '<table class = "e-gantt-tooltiptable"><tbody>' +
11593
11703
  taskName + sDate + '</tbody></table>';
11594
11704
  break;
@@ -12313,25 +12423,7 @@ let Gantt = class Gantt extends Component {
12313
12423
  * @returns {void} .
12314
12424
  */
12315
12425
  calculateDimensions() {
12316
- let settingsHeight;
12317
- if (typeof (this.height) !== 'number' && this.height.indexOf('%') !== -1 && (this.element.parentElement &&
12318
- !this.element.parentElement.style.height || this.element.parentElement.style.height.indexOf('%') !== -1)) {
12319
- let ganttHeight;
12320
- if (this.element.parentElement.style.height.indexOf('%') == -1) {
12321
- ganttHeight = Number(this.height.split("%")[0]);
12322
- }
12323
- else {
12324
- ganttHeight = Number(this.element.parentElement.style.height.split("%")[0]);
12325
- }
12326
- ganttHeight = (ganttHeight * window.innerHeight) / 100;
12327
- if (this.height === '100%') {
12328
- ganttHeight = ganttHeight - 16;
12329
- }
12330
- settingsHeight = this.validateDimentionValue(ganttHeight);
12331
- }
12332
- else {
12333
- settingsHeight = this.validateDimentionValue(this.height);
12334
- }
12426
+ let settingsHeight = this.validateDimentionValue(this.height);
12335
12427
  let settingsWidth = this.validateDimentionValue(this.width);
12336
12428
  if (!isNullOrUndefined(this.width) && typeof (this.width) === 'string' && this.width.indexOf('%') !== -1) {
12337
12429
  settingsWidth = this.width;
@@ -12474,40 +12566,6 @@ let Gantt = class Gantt extends Component {
12474
12566
  */
12475
12567
  windowResize() {
12476
12568
  if (!isNullOrUndefined(this.element)) {
12477
- let settingsHeight;
12478
- if (this.height.indexOf('%') !== -1) {
12479
- let ganttHeight = Number(this.height.split("%")[0]);
12480
- if (this.element.parentElement && (this.element.parentElement.style.height)) {
12481
- let containerHeight;
12482
- if (this.element.parentElement.style.height.indexOf('%') == -1) {
12483
- containerHeight = Number(this.element.parentElement.style.height.split("px")[0]);
12484
- ganttHeight = (ganttHeight * containerHeight) / 100;
12485
- }
12486
- else {
12487
- containerHeight = Number(this.element.parentElement.style.height.split("%")[0]);
12488
- ganttHeight = (window.innerHeight * containerHeight) / 100;
12489
- }
12490
- }
12491
- else {
12492
- ganttHeight = Number(this.height.split("%")[0]);
12493
- ganttHeight = (ganttHeight * window.innerHeight) / 100;
12494
- }
12495
- if (this.height === '100%') {
12496
- ganttHeight = ganttHeight - 16;
12497
- }
12498
- let toolbarHeight = 0;
12499
- if (!isNullOrUndefined(this.toolbarModule) && !isNullOrUndefined(this.toolbarModule.element)) {
12500
- toolbarHeight = this.toolbarModule.element.offsetHeight;
12501
- }
12502
- let contentHeight = ganttHeight - this.ganttChartModule.chartTimelineContainer.offsetHeight - toolbarHeight;
12503
- settingsHeight = this.validateDimentionValue(ganttHeight);
12504
- this.element.style.height = settingsHeight;
12505
- this.element.querySelectorAll('.e-content')[0]['style'].height = contentHeight + 'px';
12506
- this.element.querySelectorAll('.e-content')[2]['style'].height = contentHeight + 'px';
12507
- }
12508
- else {
12509
- settingsHeight = this.validateDimentionValue(this.height);
12510
- }
12511
12569
  this.updateContentHeight();
12512
12570
  this.ganttChartModule.updateWidthAndHeight(); // Updating chart scroll conatiner height for row mismatch
12513
12571
  this.treeGridModule.ensureScrollBar();
@@ -12852,6 +12910,18 @@ let Gantt = class Gantt extends Component {
12852
12910
  * @private
12853
12911
  */
12854
12912
  treeDataBound(args) {
12913
+ this.element.getElementsByClassName('e-chart-root-container')[0]['style'].height = '100%';
12914
+ let gridHeight = this.element.getElementsByClassName('e-gridcontent')[0]['style'].height;
12915
+ let timelineContainer = this.element.getElementsByClassName('e-timeline-header-container')[0]['offsetHeight'];
12916
+ gridHeight = 'calc(100% - ' + timelineContainer + 'px)';
12917
+ // eslint-disable-next-line
12918
+ this.element.getElementsByClassName('e-chart-scroll-container e-content')[0]['style'].height = 'calc(100% - ' + timelineContainer + 'px)';
12919
+ if (!isNullOrUndefined(this.toolbarModule) && !isNullOrUndefined(this.toolbarModule.element)) {
12920
+ this.splitterElement.style.height = 'calc(100% - ' + this.toolbarModule.element.offsetHeight + 'px)';
12921
+ }
12922
+ else {
12923
+ this.splitterElement.style.height = '100%';
12924
+ }
12855
12925
  if (this.isLoad) {
12856
12926
  this.updateCurrentViewData();
12857
12927
  if (!this.enableVirtualization) {
@@ -12871,8 +12941,7 @@ let Gantt = class Gantt extends Component {
12871
12941
  removeClass(this.treeGrid.element.querySelectorAll('.e-headercell'), timelineSingleHeaderOuterDiv);
12872
12942
  removeClass(this.treeGrid.element.querySelectorAll('.e-columnheader'), timelineSingleHeaderOuterDiv);
12873
12943
  }
12874
- this.treeGrid.height = this.ganttHeight - toolbarHeight -
12875
- this.treeGrid.grid.getHeaderContent().offsetHeight;
12944
+ this.treeGrid.height = '100%';
12876
12945
  this.notify('tree-grid-created', {});
12877
12946
  this.createGanttPopUpElement();
12878
12947
  this.hideSpinner();
@@ -13382,7 +13451,7 @@ let Gantt = class Gantt extends Component {
13382
13451
  */
13383
13452
  updateGridLineContainerHeight() {
13384
13453
  if (this.chartVerticalLineContainer) {
13385
- this.chartVerticalLineContainer.style.height = formatUnit(this.getContentHeight());
13454
+ this.chartVerticalLineContainer.style.height = formatUnit(this.contentHeight);
13386
13455
  }
13387
13456
  }
13388
13457
  /**
@@ -15290,7 +15359,8 @@ class CellEdit {
15290
15359
  args.cancel = true;
15291
15360
  return;
15292
15361
  }
15293
- if (data.hasChildRecords && (field === taskSettings.endDate || field === taskSettings.duration
15362
+ if (data.hasChildRecords && ((field === taskSettings.endDate && ((!isNullOrUndefined(data['isManual']) &&
15363
+ data['isManual'] == false) || this.parent.taskMode == 'Auto')) || field === taskSettings.duration
15294
15364
  || field === taskSettings.dependency || field === taskSettings.progress
15295
15365
  || field === taskSettings.work || field === 'taskType')) {
15296
15366
  args.cancel = true;
@@ -19386,7 +19456,8 @@ class DialogEdit {
19386
19456
  disabled = true;
19387
19457
  }
19388
19458
  if (this.editedRecord.hasChildRecords) {
19389
- if (column.field === this.parent.taskFields.endDate || column.field === this.parent.taskFields.duration ||
19459
+ if ((column.field === this.parent.taskFields.endDate && ((!isNullOrUndefined(this.editedRecord['isManual']) &&
19460
+ this.editedRecord['isManual'] == false) || this.parent.taskMode == 'Auto')) || column.field === this.parent.taskFields.duration ||
19390
19461
  column.field === this.parent.taskFields.progress || column.field === this.parent.taskFields.work ||
19391
19462
  column.field === 'taskType') {
19392
19463
  disabled = true;
@@ -23180,7 +23251,15 @@ class Edit$2 {
23180
23251
  }
23181
23252
  /* data Source update */
23182
23253
  if (!isNullOrUndefined(parentItem)) {
23183
- childIndex = parentItem.childRecords.indexOf(this.addRowSelectedItem);
23254
+ if (rowPosition == 'Above') {
23255
+ childIndex = parentItem.childRecords.indexOf(this.addRowSelectedItem);
23256
+ }
23257
+ else if (rowPosition == 'Below') {
23258
+ childIndex = parentItem.childRecords.indexOf(this.addRowSelectedItem) + 1;
23259
+ }
23260
+ else {
23261
+ childIndex = parentItem.childRecords.length;
23262
+ }
23184
23263
  /*Child collection update*/
23185
23264
  parentItem.childRecords.splice(childIndex, 0, record);
23186
23265
  if ((this.parent.dataSource instanceof DataManager &&
@@ -23188,12 +23267,9 @@ class Edit$2 {
23188
23267
  !isNullOrUndefined(this.parent.dataSource)) {
23189
23268
  const child = this.parent.taskFields.child;
23190
23269
  if (parentItem.taskData[child] && parentItem.taskData[child].length > 0) {
23191
- if (rowPosition === 'Above') {
23270
+ if (rowPosition === 'Above' || rowPosition === 'Below') {
23192
23271
  parentItem.taskData[child].splice(childIndex, 0, record.taskData);
23193
23272
  }
23194
- else if (rowPosition === 'Below') {
23195
- parentItem.taskData[child].splice(childIndex + 1, 0, record.taskData);
23196
- }
23197
23273
  else {
23198
23274
  parentItem.taskData[child].push(record.taskData);
23199
23275
  }
@@ -23261,9 +23337,21 @@ class Edit$2 {
23261
23337
  refreshRecordInImmutableMode() {
23262
23338
  for (let i = 0; i < this.parent.modifiedRecords.length; i++) {
23263
23339
  const originalData = this.parent.modifiedRecords[i];
23264
- const dataId = this.parent.viewType === 'ProjectView' ?
23265
- originalData.ganttProperties.taskId : originalData.ganttProperties.rowUniqueID;
23266
- this.parent.treeGrid.grid.setRowData(dataId, originalData);
23340
+ let treeIndex = this.parent.allowRowDragAndDrop ? 1 : 0;
23341
+ let uniqueTaskID = this.parent.taskFields.id;
23342
+ var originalIndex = this.parent.currentViewData.findIndex((data) => {
23343
+ return (data[uniqueTaskID] == originalData[uniqueTaskID]);
23344
+ });
23345
+ if (this.parent.treeGrid.getRows()[originalIndex]) {
23346
+ this.parent.treeGrid.renderModule.cellRender({
23347
+ data: originalData, cell: this.parent.treeGrid.getRows()[originalIndex].cells[this.parent.treeColumnIndex + treeIndex],
23348
+ column: this.parent.treeGrid.grid.getColumns()[this.parent.treeColumnIndex],
23349
+ requestType: 'rowDragAndDrop'
23350
+ });
23351
+ this.parent.treeGrid.renderModule.RowModifier({
23352
+ data: originalData, row: this.parent.treeGrid.getRows()[originalIndex], rowHeight: this.parent.rowHeight
23353
+ });
23354
+ }
23267
23355
  }
23268
23356
  }
23269
23357
  /**
@@ -23640,6 +23728,9 @@ class Edit$2 {
23640
23728
  }
23641
23729
  this.addSuccess(args);
23642
23730
  args = this.constructTaskAddedEventArgs(cAddedRecord, args.modifiedRecords, 'add');
23731
+ if (this.dialogModule.isAddNewResource && !this.parent.isEdit && this.parent.taskFields.work) {
23732
+ this.parent.dataOperation.updateWorkWithDuration(cAddedRecord[0]);
23733
+ }
23643
23734
  this.parent.trigger('actionComplete', args);
23644
23735
  if (this.dialogModule.dialog && !this.dialogModule.dialogObj.isDestroyed) {
23645
23736
  this.dialogModule.dialogObj.hide();
@@ -24014,15 +24105,18 @@ class Edit$2 {
24014
24105
  if (this.dropPosition === 'topSegment' || this.dropPosition === 'bottomSegment') {
24015
24106
  draggedRec[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.parentID];
24016
24107
  draggedRec.taskData[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.parentID];
24108
+ draggedRec.ganttProperties['parentId'] = droppedRec[this.parent.taskFields.parentID];
24017
24109
  }
24018
24110
  else {
24019
24111
  draggedRec[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.id];
24020
24112
  draggedRec.taskData[this.parent.taskFields.parentID] = droppedRec[this.parent.taskFields.id];
24113
+ draggedRec.ganttProperties['parentId'] = droppedRec[this.parent.taskFields.id];
24021
24114
  }
24022
24115
  }
24023
24116
  else {
24024
24117
  draggedRec[this.parent.taskFields.parentID] = null;
24025
24118
  draggedRec.taskData[this.parent.taskFields.parentID] = null;
24119
+ draggedRec.ganttProperties['parentId'] = null;
24026
24120
  }
24027
24121
  }
24028
24122
  }
@@ -24875,6 +24969,9 @@ class Selection$1 {
24875
24969
  this.addRemoveClass(index);
24876
24970
  this.selectedRowIndexes = extend([], this.getSelectedRowIndexes(), [], true);
24877
24971
  this.parent.setProperties({ selectedRowIndex: -1 }, true);
24972
+ if (this.selectedRowIndexes.length === 1) {
24973
+ this.parent.setProperties({ selectedRowIndex: this.selectedRowIndexes[0] }, true);
24974
+ }
24878
24975
  if (!isNullOrUndefined(this.parent.toolbarModule)) {
24879
24976
  this.parent.toolbarModule.refreshToolbarItems();
24880
24977
  }
@@ -25743,6 +25840,7 @@ class NonWorkingDay {
25743
25840
  this.nonworkingContainer = createElement('div', {
25744
25841
  className: nonworkingContainer
25745
25842
  });
25843
+ this.nonworkingContainer.setAttribute("role", "NonWorkingDays");
25746
25844
  this.parent.ganttChartModule.chartBodyContent.appendChild(this.nonworkingContainer);
25747
25845
  }
25748
25846
  }
@@ -25780,8 +25878,11 @@ class NonWorkingDay {
25780
25878
  let toDate;
25781
25879
  const container = createElement('div');
25782
25880
  const height = this.parent.contentHeight;
25783
- const scrollElement = this.parent.ganttChartModule.scrollElement;
25784
- const viewportHeight = parseInt(scrollElement.style.height, 10);
25881
+ let toolbarHeight = 0;
25882
+ if (!isNullOrUndefined(this.parent.toolbarModule)) {
25883
+ toolbarHeight = this.parent.toolbarModule.element.offsetHeight;
25884
+ }
25885
+ const viewportHeight = this.parent.ganttHeight - toolbarHeight - this.parent.ganttChartModule.chartTimelineContainer.offsetHeight;
25785
25886
  for (let i = 0; i < this.parent.holidays.length; i++) {
25786
25887
  if (this.parent.holidays[i].from && this.parent.holidays[i].to) {
25787
25888
  fromDate = this.parent.dateValidationModule.getDateFromFormat(this.parent.holidays[i].from);
@@ -25874,9 +25975,12 @@ class NonWorkingDay {
25874
25975
  return container;
25875
25976
  }
25876
25977
  updateHolidayLabelHeight() {
25877
- const height = this.parent.contentHeight;
25878
- const scrollElement = this.parent.ganttChartModule.scrollElement;
25879
- const viewportHeight = parseInt(scrollElement.style.height, 10);
25978
+ const height = this.parent.getContentHeight();
25979
+ let toolbarHeight = 0;
25980
+ if (!isNullOrUndefined(this.parent.toolbarModule) && !isNullOrUndefined(this.parent.toolbarModule.element)) {
25981
+ toolbarHeight = this.parent.toolbarModule.element.offsetHeight;
25982
+ }
25983
+ const viewportHeight = this.parent.ganttHeight - toolbarHeight - this.parent.ganttChartModule.chartTimelineContainer.offsetHeight;
25880
25984
  const top = (viewportHeight < height) ? viewportHeight / 2 : height / 2;
25881
25985
  const labels = this.holidayContainer.querySelectorAll('.' + holidayLabel);
25882
25986
  for (let i = 0; i < labels.length; i++) {
@@ -25932,6 +26036,7 @@ class EventMarker$1 {
25932
26036
  this.eventMarkersContainer = createElement('div', {
25933
26037
  className: eventMarkersContainer
25934
26038
  });
26039
+ this.eventMarkersContainer.setAttribute("role", "EventMarker");
25935
26040
  this.parent.ganttChartModule.chartBodyContent.appendChild(this.eventMarkersContainer);
25936
26041
  }
25937
26042
  this.eventMarkersContainer.innerHTML = '';
@@ -27102,19 +27207,31 @@ class RowDD$1 {
27102
27207
  let data = gObj.flatData;
27103
27208
  let startIndex;
27104
27209
  let endIndex;
27210
+ let ganttData = this.parent.dataSource;
27211
+ let uniqueTaskID = this.parent.taskFields.id;
27105
27212
  if (draggedRecord.index < droppedRecord.index) {
27106
27213
  startIndex = draggedRecord.index;
27107
- endIndex = droppedRecord.index;
27214
+ for (let i = 0; i < ganttData.length; i++) {
27215
+ let currentData = this.parent.currentViewData.filter(function (e) {
27216
+ return e[uniqueTaskID] === ganttData[i][uniqueTaskID];
27217
+ })[0];
27218
+ if (currentData.index > droppedRecord.index) {
27219
+ endIndex = currentData.index;
27220
+ break;
27221
+ }
27222
+ }
27108
27223
  }
27109
27224
  else {
27110
27225
  startIndex = droppedRecord.index;
27111
- let rootChildRecord = draggedRecord;
27112
- if (rootChildRecord.childRecords.length > 0) {
27113
- do {
27114
- rootChildRecord = rootChildRecord.childRecords[rootChildRecord.childRecords.length - 1];
27115
- } while (rootChildRecord.childRecords.length > 0);
27226
+ for (let i = 0; i < ganttData.length; i++) {
27227
+ let currentData = this.parent.currentViewData.filter(function (e) {
27228
+ return e[uniqueTaskID] === ganttData[i][uniqueTaskID];
27229
+ })[0];
27230
+ if (currentData.index > draggedRecord.index) {
27231
+ endIndex = currentData.index;
27232
+ break;
27233
+ }
27116
27234
  }
27117
- endIndex = rootChildRecord.index;
27118
27235
  }
27119
27236
  for (let i = startIndex; i <= endIndex; i++) {
27120
27237
  if (!isNullOrUndefined(data[i])) {