@syncfusion/ej2-gantt 19.4.41 → 19.4.42
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.
- package/CHANGELOG.md +9 -0
- package/dist/ej2-gantt.umd.min.js +2 -2
- package/dist/ej2-gantt.umd.min.js.map +1 -1
- package/dist/es6/ej2-gantt.es2015.js +18 -4
- package/dist/es6/ej2-gantt.es2015.js.map +1 -1
- package/dist/es6/ej2-gantt.es5.js +18 -4
- package/dist/es6/ej2-gantt.es5.js.map +1 -1
- package/dist/global/ej2-gantt.min.js +2 -2
- package/dist/global/ej2-gantt.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +13 -13
- package/src/gantt/actions/keyboard.js +4 -0
- package/src/gantt/base/date-processor.js +8 -1
- package/src/gantt/base/gantt-chart.js +0 -2
- package/src/gantt/base/task-processor.js +6 -1
|
@@ -483,7 +483,14 @@ var DateProcessor = /** @__PURE__ @class */ (function () {
|
|
|
483
483
|
tDuration = this.parent.editModule.taskbarEditModule.sumOfDuration(ganttProperties.segments);
|
|
484
484
|
}
|
|
485
485
|
else {
|
|
486
|
-
|
|
486
|
+
// eslint-disable-next-line
|
|
487
|
+
if (!isNullOrUndefined(ganttProperties.startDate) && !isNullOrUndefined(ganttProperties.endDate) &&
|
|
488
|
+
(ganttProperties.startDate).getTime() === (ganttProperties.endDate).getTime() && !isNullOrUndefined(ganttData.taskData[this.parent.taskFields.milestone])) {
|
|
489
|
+
tDuration = 1;
|
|
490
|
+
}
|
|
491
|
+
else {
|
|
492
|
+
tDuration = this.getDuration(ganttProperties.startDate, ganttProperties.endDate, ganttProperties.durationUnit, ganttProperties.isAutoSchedule, ganttProperties.isMilestone);
|
|
493
|
+
}
|
|
487
494
|
}
|
|
488
495
|
this.parent.setRecordValue('duration', tDuration, ganttProperties, true);
|
|
489
496
|
var col = this.parent.columnByField[this.parent.columnMapping.duration];
|
|
@@ -2628,7 +2635,12 @@ var TaskProcessor = /** @__PURE__ @class */ (function (_super) {
|
|
|
2628
2635
|
eDate.setHours(0, 0, 0, 0);
|
|
2629
2636
|
}
|
|
2630
2637
|
}
|
|
2631
|
-
|
|
2638
|
+
if ((sDate).getTime() === (eDate).getTime()) {
|
|
2639
|
+
return (this.parent.perDayWidth);
|
|
2640
|
+
}
|
|
2641
|
+
else {
|
|
2642
|
+
return ((this.getTimeDifference(sDate, eDate) / (1000 * 60 * 60 * 24)) * this.parent.perDayWidth);
|
|
2643
|
+
}
|
|
2632
2644
|
};
|
|
2633
2645
|
/**
|
|
2634
2646
|
* Get task left value
|
|
@@ -4873,8 +4885,6 @@ var GanttChart = /** @__PURE__ @class */ (function () {
|
|
|
4873
4885
|
this.parent.treeGrid.collapseAll();
|
|
4874
4886
|
}
|
|
4875
4887
|
this.isExpandAll = false;
|
|
4876
|
-
var focussedElement = this.parent.element.querySelector('.e-treegrid');
|
|
4877
|
-
focussedElement.focus();
|
|
4878
4888
|
};
|
|
4879
4889
|
/**
|
|
4880
4890
|
* Public method to expand particular level of rows.
|
|
@@ -12123,6 +12133,10 @@ var FocusModule = /** @__PURE__ @class */ (function () {
|
|
|
12123
12133
|
FocusModule.prototype.onKeyPress = function (e) {
|
|
12124
12134
|
var ganttObj = this.parent;
|
|
12125
12135
|
var expandedRecords = ganttObj.getExpandedRecords(ganttObj.currentViewData);
|
|
12136
|
+
if (isNullOrUndefined(this.parent.focusModule.getActiveElement()) && (e.action === 'expandAll' || e.action === 'collapseAll')) {
|
|
12137
|
+
var focussedElement = this.parent.element.querySelector('.e-treegrid');
|
|
12138
|
+
focussedElement.focus();
|
|
12139
|
+
}
|
|
12126
12140
|
var targetElement = this.parent.focusModule.getActiveElement();
|
|
12127
12141
|
if (e.action === 'home' || e.action === 'end' || e.action === 'downArrow' || e.action === 'upArrow' || e.action === 'delete' ||
|
|
12128
12142
|
e.action === 'rightArrow' || e.action === 'leftArrow' || e.action === 'focusTask' || e.action === 'focusSearch' ||
|