@syncfusion/ej2-gantt 20.2.43 → 20.2.46

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 (69) hide show
  1. package/CHANGELOG.md +30 -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 +91 -46
  5. package/dist/es6/ej2-gantt.es2015.js.map +1 -1
  6. package/dist/es6/ej2-gantt.es5.js +91 -46
  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 +3 -0
  13. package/src/gantt/actions/critical-path.js +2 -8
  14. package/src/gantt/actions/edit.js +1 -1
  15. package/src/gantt/actions/rowdragdrop.js +2 -2
  16. package/src/gantt/base/date-processor.js +1 -1
  17. package/src/gantt/base/gantt-chart.js +17 -3
  18. package/src/gantt/base/gantt.d.ts +1 -0
  19. package/src/gantt/base/gantt.js +46 -26
  20. package/src/gantt/base/splitter.js +3 -1
  21. package/src/gantt/base/task-processor.js +4 -1
  22. package/src/gantt/renderer/chart-rows.js +12 -3
  23. package/src/gantt/renderer/timeline.js +1 -1
  24. package/styles/bootstrap-dark.css +4 -4
  25. package/styles/bootstrap.css +4 -4
  26. package/styles/bootstrap4.css +4 -4
  27. package/styles/bootstrap5-dark.css +4 -4
  28. package/styles/bootstrap5.css +4 -4
  29. package/styles/fabric-dark.css +4 -4
  30. package/styles/fabric.css +4 -4
  31. package/styles/fluent-dark.css +4 -4
  32. package/styles/fluent.css +4 -4
  33. package/styles/gantt/_layout.scss +9 -19
  34. package/styles/gantt/_theme.scss +1 -19
  35. package/styles/gantt/bootstrap-dark.css +4 -4
  36. package/styles/gantt/bootstrap.css +4 -4
  37. package/styles/gantt/bootstrap4.css +4 -4
  38. package/styles/gantt/bootstrap5-dark.css +4 -4
  39. package/styles/gantt/bootstrap5.css +4 -4
  40. package/styles/gantt/fabric-dark.css +4 -4
  41. package/styles/gantt/fabric.css +4 -4
  42. package/styles/gantt/fluent-dark.css +4 -4
  43. package/styles/gantt/fluent.css +4 -4
  44. package/styles/gantt/highcontrast-light.css +4 -4
  45. package/styles/gantt/highcontrast.css +4 -4
  46. package/styles/gantt/icons/_bootstrap-dark.scss +3 -3
  47. package/styles/gantt/icons/_bootstrap.scss +3 -3
  48. package/styles/gantt/icons/_bootstrap4.scss +5 -5
  49. package/styles/gantt/icons/_bootstrap5.scss +3 -3
  50. package/styles/gantt/icons/_fabric-dark.scss +3 -3
  51. package/styles/gantt/icons/_fabric.scss +3 -3
  52. package/styles/gantt/icons/_fluent.scss +3 -3
  53. package/styles/gantt/icons/_fusionnew.scss +3 -3
  54. package/styles/gantt/icons/_highcontrast.scss +3 -3
  55. package/styles/gantt/icons/_material-dark.scss +3 -3
  56. package/styles/gantt/icons/_material.scss +3 -3
  57. package/styles/gantt/icons/_material3.scss +3 -3
  58. package/styles/gantt/icons/_tailwind-dark.scss +3 -3
  59. package/styles/gantt/icons/_tailwind.scss +3 -3
  60. package/styles/gantt/material-dark.css +4 -4
  61. package/styles/gantt/material.css +4 -4
  62. package/styles/gantt/tailwind-dark.css +4 -4
  63. package/styles/gantt/tailwind.css +4 -4
  64. package/styles/highcontrast-light.css +4 -4
  65. package/styles/highcontrast.css +4 -4
  66. package/styles/material-dark.css +4 -4
  67. package/styles/material.css +4 -4
  68. package/styles/tailwind-dark.css +4 -4
  69. package/styles/tailwind.css +4 -4
@@ -367,7 +367,7 @@ var DateProcessor = /** @__PURE__ @class */ (function () {
367
367
  if (hour < this.parent.defaultStartTime) {
368
368
  this.setTime(this.parent.defaultStartTime, cloneDate);
369
369
  }
370
- else if (hour >= this.parent.defaultEndTime) {
370
+ else if (hour > this.parent.defaultEndTime) {
371
371
  cloneDate.setDate(cloneDate.getDate() + 1);
372
372
  this.setTime(this.parent.defaultStartTime, cloneDate);
373
373
  }
@@ -1890,7 +1890,10 @@ var TaskProcessor = /** @__PURE__ @class */ (function (_super) {
1890
1890
  this.setTime(this.parent.defaultEndTime, baselineEndDate);
1891
1891
  }
1892
1892
  if ((ganttProperties.baselineStartDate && baselineEndDate &&
1893
- (ganttProperties.baselineStartDate.getTime() > baselineEndDate.getTime())) || ganttProperties.isMilestone) {
1893
+ (ganttProperties.baselineStartDate.getTime() > baselineEndDate.getTime())) ||
1894
+ ((!isNullOrUndefined(ganttProperties.baselineStartDate) && !isNullOrUndefined(ganttProperties.startDate) && (ganttProperties.baselineStartDate.getTime() === ganttProperties.startDate.getTime()))
1895
+ && (!isNullOrUndefined(baselineEndDate) && !isNullOrUndefined(ganttProperties.endDate) && (baselineEndDate.toLocaleDateString() === ganttProperties.endDate.toLocaleDateString())) &&
1896
+ ganttProperties.isMilestone)) {
1894
1897
  baselineEndDate = ganttProperties.baselineStartDate;
1895
1898
  }
1896
1899
  this.parent.setRecordValue('baselineEndDate', this.checkBaselineEndDate(baselineEndDate, ganttProperties), ganttProperties, true);
@@ -4868,7 +4871,7 @@ var GanttChart = /** @__PURE__ @class */ (function () {
4868
4871
  * @private
4869
4872
  */
4870
4873
  GanttChart.prototype.expandedGanttRow = function (args) {
4871
- if (isNullOrUndefined(args['gridRow']) && this.parent.enableVirtualization) {
4874
+ if ((isNullOrUndefined(args['gridRow']) && this.parent.enableVirtualization) || isNullOrUndefined(args['chartRow'])) {
4872
4875
  return;
4873
4876
  }
4874
4877
  var record = getValue('data', args);
@@ -5113,7 +5116,7 @@ var GanttChart = /** @__PURE__ @class */ (function () {
5113
5116
  if (isTab) {
5114
5117
  if (this.parent.editSettings.allowNextRowEdit) {
5115
5118
  var rowData = this.parent.currentViewData[this.focusedRowIndex];
5116
- var columnName = this.parent.ganttColumns[nextElement.getAttribute('aria-colindex')].field;
5119
+ var columnName = this.parent.ganttColumns[nextElement.getAttribute('data-colindex')].field;
5117
5120
  if (rowData.hasChildRecords) {
5118
5121
  if (columnName === this.parent.taskFields.endDate || columnName ===
5119
5122
  this.parent.taskFields.duration || columnName === this.parent.taskFields.dependency ||
@@ -5127,7 +5130,9 @@ var GanttChart = /** @__PURE__ @class */ (function () {
5127
5130
  }
5128
5131
  else {
5129
5132
  this.parent.treeGrid.grid.notify('key-pressed', e);
5130
- this.parent.treeGrid.editCell(this.focusedRowIndex, columnName); // eslint-disable-line
5133
+ if (isInEditedState) {
5134
+ this.parent.treeGrid.editCell(this.focusedRowIndex, columnName); // eslint-disable-line
5135
+ }
5131
5136
  }
5132
5137
  }
5133
5138
  else {
@@ -5347,6 +5352,18 @@ var GanttChart = /** @__PURE__ @class */ (function () {
5347
5352
  childElement = element;
5348
5353
  }
5349
5354
  }
5355
+ if (element.classList.contains('e-right-label-temp-container') || element.classList.contains('e-left-label-temp-container') || element.classList.contains('e-indicator-span')) {
5356
+ if (focus === 'add') {
5357
+ element.setAttribute('tabIndex', '0');
5358
+ addClass([element], 'e-active-container');
5359
+ element.focus();
5360
+ }
5361
+ else {
5362
+ removeClass([element], 'e-active-container');
5363
+ element.setAttribute('tabIndex', '-1');
5364
+ element.blur();
5365
+ }
5366
+ }
5350
5367
  if (focus === 'add' && !isNullOrUndefined(childElement)) {
5351
5368
  element.setAttribute('tabIndex', '0');
5352
5369
  addClass([childElement], 'e-active-container');
@@ -6328,7 +6345,7 @@ var Timeline = /** @__PURE__ @class */ (function () {
6328
6345
  endDate.setHours(24, 0, 0, 0);
6329
6346
  }
6330
6347
  }
6331
- if (this.isZooming || this.parent.isLoad) {
6348
+ if ((this.isZooming || this.parent.isLoad) && isNullOrUndefined(this.parent.projectEndDate)) {
6332
6349
  this.updateTimelineAfterZooming(endDate, false);
6333
6350
  }
6334
6351
  return endDate;
@@ -9708,7 +9725,10 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9708
9725
  }
9709
9726
  if (this.parent.renderBaseline && this.templateData.ganttProperties.baselineStartDate &&
9710
9727
  this.templateData.ganttProperties.baselineEndDate) {
9711
- taskBaselineTemplateNode = this.getTaskBaselineNode();
9728
+ taskBaselineTemplateNode = ((!isNullOrUndefined(this.templateData.ganttProperties.baselineStartDate) && !isNullOrUndefined(this.templateData.ganttProperties.startDate) && (this.templateData.ganttProperties.baselineStartDate.getTime() === this.templateData.ganttProperties.startDate.getTime()))
9729
+ && (!isNullOrUndefined(this.templateData.ganttProperties.baselineEndDate) && !isNullOrUndefined(this.templateData.ganttProperties.endDate) && (this.templateData.ganttProperties.baselineEndDate.toLocaleDateString() === this.templateData.ganttProperties.endDate.toLocaleDateString())) &&
9730
+ this.templateData.ganttProperties.isMilestone)
9731
+ ? this.getMilestoneBaselineNode() : this.getTaskBaselineNode();
9712
9732
  }
9713
9733
  }
9714
9734
  else if (this.templateData.ganttProperties.isMilestone) {
@@ -9718,7 +9738,10 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9718
9738
  }
9719
9739
  if (this.parent.renderBaseline && this.templateData.ganttProperties.baselineStartDate &&
9720
9740
  this.templateData.ganttProperties.baselineEndDate) {
9721
- taskBaselineTemplateNode = this.getMilestoneBaselineNode();
9741
+ taskBaselineTemplateNode = ((!isNullOrUndefined(this.templateData.ganttProperties.baselineStartDate) && !isNullOrUndefined(this.templateData.ganttProperties.startDate) && (this.templateData.ganttProperties.baselineStartDate.getTime() === this.templateData.ganttProperties.startDate.getTime()))
9742
+ && (!isNullOrUndefined(this.templateData.ganttProperties.baselineEndDate) && !isNullOrUndefined(this.templateData.ganttProperties.endDate) && (this.templateData.ganttProperties.baselineEndDate.toLocaleDateString() === this.templateData.ganttProperties.endDate.toLocaleDateString())) &&
9743
+ this.templateData.ganttProperties.isMilestone)
9744
+ ? this.getMilestoneBaselineNode() : this.getTaskBaselineNode();
9722
9745
  }
9723
9746
  }
9724
9747
  else {
@@ -9763,7 +9786,10 @@ var ChartRows = /** @__PURE__ @class */ (function (_super) {
9763
9786
  }
9764
9787
  if (this.parent.renderBaseline && this.templateData.ganttProperties.baselineStartDate &&
9765
9788
  this.templateData.ganttProperties.baselineEndDate) {
9766
- taskBaselineTemplateNode = this.getTaskBaselineNode();
9789
+ taskBaselineTemplateNode = ((!isNullOrUndefined(this.templateData.ganttProperties.baselineStartDate) && !isNullOrUndefined(this.templateData.ganttProperties.startDate) && (this.templateData.ganttProperties.baselineStartDate.getTime() === this.templateData.ganttProperties.startDate.getTime()))
9790
+ && (!isNullOrUndefined(this.templateData.ganttProperties.baselineEndDate) && !isNullOrUndefined(this.templateData.ganttProperties.endDate) && (this.templateData.ganttProperties.baselineEndDate.toLocaleDateString() === this.templateData.ganttProperties.endDate.toLocaleDateString())) &&
9791
+ this.templateData.ganttProperties.isMilestone)
9792
+ ? this.getMilestoneBaselineNode() : this.getTaskBaselineNode();
9767
9793
  }
9768
9794
  }
9769
9795
  if (!this.templateData.hasChildRecords) {
@@ -11905,7 +11931,9 @@ var Splitter$1 = /** @__PURE__ @class */ (function () {
11905
11931
  _this.splitterObject.paneSettings[1].size = null;
11906
11932
  _this.splitterObject.paneSettings[1].size = _this.getSpliterPositionInPercentage(_this.splitterPreviousPositionChart);
11907
11933
  }
11908
- _this.parent.timelineModule.updateTimelineAfterZooming(_this.parent.timelineModule.timelineEndDate, true);
11934
+ if (isNullOrUndefined(_this.parent.projectEndDate)) {
11935
+ _this.parent.timelineModule.updateTimelineAfterZooming(_this.parent.timelineModule.timelineEndDate, true);
11936
+ }
11909
11937
  callBackPromise.resolve(splitterResizedArgs);
11910
11938
  });
11911
11939
  return callBackPromise;
@@ -13140,6 +13168,16 @@ var Gantt = /** @__PURE__ @class */ (function (_super) {
13140
13168
  this.renderChartVerticalLines();
13141
13169
  }
13142
13170
  };
13171
+ Gantt.prototype.removeCriticalPathStyles = function () {
13172
+ var ganttChartElement = this.ganttChartModule.chartElement;
13173
+ removeClass(ganttChartElement.querySelectorAll('.e-gantt-child-taskbar-inner-div'), criticalChildTaskBarInnerDiv);
13174
+ removeClass(ganttChartElement.querySelectorAll('.e-gantt-child-progressbar-inner-div'), criticalChildProgressBarInnerDiv);
13175
+ removeClass(ganttChartElement.querySelectorAll('.e-milestone-top'), criticalMilestoneTop);
13176
+ removeClass(ganttChartElement.querySelectorAll('.e-milestone-bottom'), criticalMilestoneBottom);
13177
+ removeClass(this.element.querySelectorAll('.e-line'), criticalConnectorLine);
13178
+ removeClass(this.element.querySelectorAll('.e-connector-line-right-arrow'), criticalConnectorLineRightArrow);
13179
+ removeClass(this.element.querySelectorAll('.e-connector-line-left-arrow'), criticalConnectorLineLeftArrow);
13180
+ };
13143
13181
  Gantt.prototype.wireEvents = function () {
13144
13182
  if (this.allowKeyboard) {
13145
13183
  this.keyboardModule = new KeyboardEvents(this.element, {
@@ -13303,139 +13341,140 @@ var Gantt = /** @__PURE__ @class */ (function (_super) {
13303
13341
  * @private
13304
13342
  */
13305
13343
  Gantt.prototype.getZoomingLevels = function () {
13344
+ var _WeekStartDay = this.timelineSettings.weekStartDay;
13306
13345
  var zoomingLevels = [
13307
13346
  {
13308
13347
  topTier: { unit: 'Year', format: 'yyyy', count: 50 },
13309
13348
  bottomTier: { unit: 'Year', format: 'yyyy', count: 10 }, timelineUnitSize: 99, level: 0,
13310
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13349
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13311
13350
  },
13312
13351
  {
13313
13352
  topTier: { unit: 'Year', format: 'yyyy', count: 20 },
13314
13353
  bottomTier: { unit: 'Year', format: 'yyyy', count: 5 }, timelineUnitSize: 99, level: 1,
13315
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13354
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13316
13355
  },
13317
13356
  {
13318
13357
  topTier: { unit: 'Year', format: 'yyyy', count: 5 },
13319
13358
  bottomTier: { unit: 'Year', format: 'yyyy', count: 1 }, timelineUnitSize: 99, level: 2,
13320
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13359
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13321
13360
  },
13322
13361
  {
13323
13362
  topTier: { unit: 'Year', format: 'MMM, yy', count: 1 },
13324
13363
  bottomTier: {
13325
13364
  unit: 'Month', formatter: this.displayHalfValue, count: 6
13326
13365
  }, timelineUnitSize: 66, level: 3,
13327
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13366
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13328
13367
  },
13329
13368
  {
13330
13369
  topTier: { unit: 'Year', format: 'MMM, yy', count: 1 },
13331
13370
  bottomTier: {
13332
13371
  unit: 'Month', formatter: this.displayHalfValue, count: 6
13333
13372
  }, timelineUnitSize: 99, level: 4,
13334
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13373
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13335
13374
  },
13336
13375
  {
13337
13376
  topTier: { unit: 'Year', format: 'MMM, yy', count: 1 },
13338
13377
  bottomTier: {
13339
13378
  unit: 'Month', formatter: this.displayQuarterValue, count: 3
13340
13379
  }, timelineUnitSize: 66, level: 5,
13341
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13380
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13342
13381
  },
13343
13382
  {
13344
13383
  topTier: { unit: 'Year', format: 'yyyy', count: 1 },
13345
13384
  bottomTier: {
13346
13385
  unit: 'Month', formatter: this.displayQuarterValue, count: 3
13347
13386
  }, timelineUnitSize: 99, level: 6,
13348
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13387
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13349
13388
  },
13350
13389
  {
13351
13390
  topTier: { unit: 'Year', format: 'yyyy', count: 1 },
13352
13391
  bottomTier: { unit: 'Month', format: 'MMM yyyy', count: 1 }, timelineUnitSize: 99, level: 7,
13353
- timelineViewMode: 'Year', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13392
+ timelineViewMode: 'Year', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13354
13393
  },
13355
13394
  {
13356
13395
  topTier: { unit: 'Month', format: 'MMM, yy', count: 1 },
13357
13396
  bottomTier: { unit: 'Week', format: 'dd', count: 1 }, timelineUnitSize: 33, level: 8,
13358
- timelineViewMode: 'Month', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13397
+ timelineViewMode: 'Month', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13359
13398
  },
13360
13399
  {
13361
13400
  topTier: { unit: 'Month', format: 'MMM, yyyy', count: 1 },
13362
13401
  bottomTier: { unit: 'Week', format: 'dd MMM', count: 1 }, timelineUnitSize: 66, level: 9,
13363
- timelineViewMode: 'Month', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13402
+ timelineViewMode: 'Month', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13364
13403
  },
13365
13404
  {
13366
13405
  topTier: { unit: 'Month', format: 'MMM, yyyy', count: 1 },
13367
13406
  bottomTier: { unit: 'Week', format: 'dd MMM', count: 1 }, timelineUnitSize: 99, level: 10,
13368
- timelineViewMode: 'Month', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13407
+ timelineViewMode: 'Month', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13369
13408
  },
13370
13409
  {
13371
13410
  topTier: { unit: 'Week', format: 'MMM dd, yyyy', count: 1 },
13372
13411
  bottomTier: { unit: 'Day', format: 'd', count: 1 }, timelineUnitSize: 33, level: 11,
13373
- timelineViewMode: 'Week', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13412
+ timelineViewMode: 'Week', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13374
13413
  },
13375
13414
  {
13376
13415
  topTier: { unit: 'Week', format: 'MMM dd, yyyy', count: 1 },
13377
13416
  bottomTier: { unit: 'Day', format: 'd', count: 1 }, timelineUnitSize: 66, level: 12,
13378
- timelineViewMode: 'Week', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13417
+ timelineViewMode: 'Week', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13379
13418
  },
13380
13419
  {
13381
13420
  topTier: { unit: 'Week', format: 'MMM dd, yyyy', count: 1 },
13382
13421
  bottomTier: { unit: 'Day', format: 'd', count: 1 }, timelineUnitSize: 99, level: 13,
13383
- timelineViewMode: 'Week', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13422
+ timelineViewMode: 'Week', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13384
13423
  },
13385
13424
  {
13386
13425
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13387
13426
  bottomTier: { unit: 'Hour', format: 'hh a', count: 12 }, timelineUnitSize: 66, level: 14,
13388
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13427
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13389
13428
  },
13390
13429
  {
13391
13430
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13392
13431
  bottomTier: { unit: 'Hour', format: 'hh a', count: 12 }, timelineUnitSize: 99, level: 15,
13393
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13432
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13394
13433
  },
13395
13434
  {
13396
13435
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13397
13436
  bottomTier: { unit: 'Hour', format: 'hh a', count: 6 }, timelineUnitSize: 66, level: 16,
13398
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13437
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13399
13438
  },
13400
13439
  {
13401
13440
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13402
13441
  bottomTier: { unit: 'Hour', format: 'hh a', count: 6 }, timelineUnitSize: 99, level: 17,
13403
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13442
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13404
13443
  },
13405
13444
  {
13406
13445
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13407
13446
  bottomTier: { unit: 'Hour', format: 'hh a', count: 2 }, timelineUnitSize: 66, level: 18,
13408
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13447
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13409
13448
  },
13410
13449
  {
13411
13450
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13412
13451
  bottomTier: { unit: 'Hour', format: 'hh a', count: 2 }, timelineUnitSize: 99, level: 19,
13413
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13452
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13414
13453
  },
13415
13454
  {
13416
13455
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13417
13456
  bottomTier: { unit: 'Hour', format: 'hh a', count: 1 }, timelineUnitSize: 66, level: 20,
13418
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13457
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13419
13458
  },
13420
13459
  {
13421
13460
  topTier: { unit: 'Day', format: 'E dd yyyy', count: 1 },
13422
13461
  bottomTier: { unit: 'Hour', format: 'hh a', count: 1 }, timelineUnitSize: 99, level: 21,
13423
- timelineViewMode: 'Day', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13462
+ timelineViewMode: 'Day', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13424
13463
  },
13425
13464
  {
13426
13465
  topTier: { unit: 'Hour', format: 'ddd MMM, h a', count: 1 },
13427
13466
  bottomTier: { unit: 'Minutes', format: 'mm', count: 30 }, timelineUnitSize: 66, level: 22,
13428
- timelineViewMode: 'Hour', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13467
+ timelineViewMode: 'Hour', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13429
13468
  },
13430
13469
  {
13431
13470
  topTier: { unit: 'Hour', format: 'ddd MMM, h a', count: 1 },
13432
13471
  bottomTier: { unit: 'Minutes', format: 'mm', count: 15 }, timelineUnitSize: 66, level: 23,
13433
- timelineViewMode: 'Hour', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13472
+ timelineViewMode: 'Hour', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13434
13473
  },
13435
13474
  {
13436
13475
  topTier: { unit: 'Hour', format: 'ddd MMM, h a', count: 1 },
13437
13476
  bottomTier: { unit: 'Minutes', format: 'mm', count: 1 }, timelineUnitSize: 66, level: 24,
13438
- timelineViewMode: 'Hour', weekStartDay: 0, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13477
+ timelineViewMode: 'Hour', weekStartDay: _WeekStartDay, updateTimescaleView: true, weekendBackground: null, showTooltip: true
13439
13478
  }
13440
13479
  ];
13441
13480
  return zoomingLevels;
@@ -13682,9 +13721,18 @@ var Gantt = /** @__PURE__ @class */ (function (_super) {
13682
13721
  }
13683
13722
  break;
13684
13723
  case 'timezone':
13685
- case 'enableCriticalPath':
13686
13724
  this.dataOperation.checkDataBinding(true);
13687
13725
  break;
13726
+ case 'enableCriticalPath':
13727
+ if (this.enableCriticalPath && this.criticalPathModule) {
13728
+ this.criticalPathModule.showCriticalPath(this.enableCriticalPath);
13729
+ var criticalModule = this.criticalPathModule;
13730
+ this.criticalPathModule.criticalConnectorLine(criticalModule.criticalPathCollection, criticalModule.detailPredecessorCollection, true, criticalModule.predecessorCollectionTaskIds);
13731
+ }
13732
+ else {
13733
+ this.removeCriticalPathStyles();
13734
+ }
13735
+ break;
13688
13736
  case 'filterSettings':
13689
13737
  this.treeGrid.filterSettings = getActualProperties(this.filterSettings);
13690
13738
  this.treeGrid.dataBind();
@@ -16224,6 +16272,9 @@ var CellEdit = /** @__PURE__ @class */ (function () {
16224
16272
  this.parent.editModule.endEditAction(args);
16225
16273
  }
16226
16274
  this.isCellEdit = false;
16275
+ if (!isNullOrUndefined(this.parent.editModule.cellEditModule.editedColumn)) {
16276
+ this.parent.editModule.cellEditModule.editedColumn = null;
16277
+ }
16227
16278
  if (!isNullOrUndefined(this.parent.toolbarModule)) {
16228
16279
  this.parent.toolbarModule.refreshToolbarItems();
16229
16280
  }
@@ -24403,7 +24454,7 @@ var Edit$2 = /** @__PURE__ @class */ (function () {
24403
24454
  else {
24404
24455
  if (_this.parent.viewType === 'ProjectView') {
24405
24456
  if ((rowPosition === 'Top' || rowPosition === 'Bottom') ||
24406
- ((rowPosition === 'Above' || rowPosition === 'Below' || rowPosition === 'Child') && !args.data.parentItem)) {
24457
+ ((rowPosition === 'Above' || rowPosition === 'Below' || rowPosition === 'Child') || isNullOrUndefined(rowPosition) && !args.data.parentItem)) {
24407
24458
  if (args.data instanceof Array) {
24408
24459
  _this.updateRealDataSource(args.data, rowPosition);
24409
24460
  }
@@ -27759,10 +27810,7 @@ var CriticalPath = /** @__PURE__ @class */ (function () {
27759
27810
  /* eslint-disable-next-line */
27760
27811
  CriticalPath.prototype.criticalConnectorLine = function (criticalPathIds, collection, condition, collectionTaskId) {
27761
27812
  var ganttChartElement = this.parent.ganttChartModule.chartElement;
27762
- removeClass(ganttChartElement.querySelectorAll('.e-gantt-child-taskbar-inner-div'), criticalChildTaskBarInnerDiv);
27763
- removeClass(ganttChartElement.querySelectorAll('.e-gantt-child-progressbar-inner-div'), criticalChildProgressBarInnerDiv);
27764
- removeClass(ganttChartElement.querySelectorAll('.e-milestone-top'), criticalMilestoneTop);
27765
- removeClass(ganttChartElement.querySelectorAll('.e-milestone-bottom'), criticalMilestoneBottom);
27813
+ this.parent.removeCriticalPathStyles();
27766
27814
  for (var i = 0; i < criticalPathIds.length; i++) {
27767
27815
  var criticalData = void 0;
27768
27816
  if (this.parent.viewType === 'ProjectView') {
@@ -27797,9 +27845,6 @@ var CriticalPath = /** @__PURE__ @class */ (function () {
27797
27845
  }
27798
27846
  }
27799
27847
  }
27800
- removeClass(this.parent.element.querySelectorAll('.e-line'), criticalConnectorLine);
27801
- removeClass(this.parent.element.querySelectorAll('.e-connector-line-right-arrow'), criticalConnectorLineRightArrow);
27802
- removeClass(this.parent.element.querySelectorAll('.e-connector-line-left-arrow'), criticalConnectorLineLeftArrow);
27803
27848
  if (collection.length !== 0) {
27804
27849
  var index = 0;
27805
27850
  var currentdata = void 0;
@@ -28896,7 +28941,7 @@ var RowDD$1 = /** @__PURE__ @class */ (function () {
28896
28941
  var currentData = this_1.parent.currentViewData.filter(function (e) {
28897
28942
  return e[uniqueTaskID_1] === ganttData_1[i_1][uniqueTaskID_1];
28898
28943
  })[0];
28899
- if (currentData.index > droppedRecord.index) {
28944
+ if (currentData && currentData.index > droppedRecord.index) {
28900
28945
  endIndex = currentData.index;
28901
28946
  return "break";
28902
28947
  }
@@ -28913,7 +28958,7 @@ var RowDD$1 = /** @__PURE__ @class */ (function () {
28913
28958
  var currentData = this_1.parent.currentViewData.filter(function (e) {
28914
28959
  return e[uniqueTaskID_1] === ganttData_1[i_2][uniqueTaskID_1];
28915
28960
  })[0];
28916
- if (currentData.index > draggedRecord.index) {
28961
+ if (currentData && currentData.index > draggedRecord.index) {
28917
28962
  endIndex = currentData.index;
28918
28963
  return "break";
28919
28964
  }