@syncfusion/ej2-gantt 21.1.38 → 21.1.41
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 +14 -0
- package/dist/ej2-gantt.min.js +2 -2
- 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 +47 -15
- package/dist/es6/ej2-gantt.es2015.js.map +1 -1
- package/dist/es6/ej2-gantt.es5.js +47 -15
- 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 +15 -15
- package/src/gantt/actions/context-menu.js +1 -1
- package/src/gantt/actions/dependency.js +1 -1
- package/src/gantt/actions/dialog-edit.js +1 -0
- package/src/gantt/actions/edit.js +7 -1
- package/src/gantt/base/date-processor.js +2 -2
- package/src/gantt/base/gantt.d.ts +1 -0
- package/src/gantt/base/gantt.js +3 -1
- package/src/gantt/base/task-processor.d.ts +1 -1
- package/src/gantt/base/task-processor.js +29 -4
- package/src/gantt/renderer/chart-rows.js +0 -4
- package/src/gantt/renderer/nonworking-day.js +3 -1
- package/styles/bootstrap-dark.css +1 -0
- package/styles/bootstrap.css +1 -0
- package/styles/bootstrap4.css +1 -0
- package/styles/bootstrap5-dark.css +1 -0
- package/styles/bootstrap5.css +1 -0
- package/styles/fabric-dark.css +1 -0
- package/styles/fabric.css +1 -0
- package/styles/fluent-dark.css +0 -3
- package/styles/fluent.css +0 -3
- package/styles/gantt/_layout.scss +0 -8
- package/styles/gantt/bootstrap-dark.css +1 -0
- package/styles/gantt/bootstrap.css +1 -0
- package/styles/gantt/bootstrap4.css +1 -0
- package/styles/gantt/bootstrap5-dark.css +1 -0
- package/styles/gantt/bootstrap5.css +1 -0
- package/styles/gantt/fabric-dark.css +1 -0
- package/styles/gantt/fabric.css +1 -0
- package/styles/gantt/fluent-dark.css +0 -3
- package/styles/gantt/fluent.css +0 -3
- package/styles/gantt/highcontrast-light.css +1 -0
- package/styles/gantt/highcontrast.css +1 -0
- package/styles/gantt/material-dark.css +1 -0
- package/styles/gantt/material.css +1 -0
- package/styles/gantt/tailwind-dark.css +1 -0
- package/styles/gantt/tailwind.css +1 -0
- package/styles/highcontrast-light.css +1 -0
- package/styles/highcontrast.css +1 -0
- package/styles/material-dark.css +1 -0
- package/styles/material.css +1 -0
- package/styles/tailwind-dark.css +1 -0
- package/styles/tailwind.css +1 -0
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 21.1.
|
|
3
|
+
* version : 21.1.41
|
|
4
4
|
* Copyright Syncfusion Inc. 2001 - 2020. All rights reserved.
|
|
5
5
|
* Use of this code is subject to the terms of our license.
|
|
6
6
|
* A copy of the current license can be obtained at any time by e-mailing
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_from": "@syncfusion/ej2-gantt@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-gantt@21.1.
|
|
3
|
+
"_id": "@syncfusion/ej2-gantt@21.1.38",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512-
|
|
5
|
+
"_integrity": "sha512-mG35i/xS8soHV61BHzK07yFe9rxWl3ubEOVZKB/oLV6xaUYnu6oUy8ggzePCuxcVBh5SfJ+Zvx8sgtr9Xjzgng==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-gantt",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"/@syncfusion/ej2-react-gantt",
|
|
24
24
|
"/@syncfusion/ej2-vue-gantt"
|
|
25
25
|
],
|
|
26
|
-
"_resolved": "https://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-21.1.
|
|
27
|
-
"_shasum": "
|
|
26
|
+
"_resolved": "https://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-gantt/-/ej2-gantt-21.1.38.tgz",
|
|
27
|
+
"_shasum": "32d68324bade49301890fb65cf019d4904462d33",
|
|
28
28
|
"_spec": "@syncfusion/ej2-gantt@*",
|
|
29
29
|
"_where": "/jenkins/workspace/elease-automation_release_21.1.1/packages/included",
|
|
30
30
|
"author": {
|
|
@@ -35,20 +35,20 @@
|
|
|
35
35
|
},
|
|
36
36
|
"bundleDependencies": false,
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@syncfusion/ej2-base": "~21.1.
|
|
38
|
+
"@syncfusion/ej2-base": "~21.1.40",
|
|
39
39
|
"@syncfusion/ej2-buttons": "~21.1.37",
|
|
40
|
-
"@syncfusion/ej2-calendars": "~21.1.
|
|
40
|
+
"@syncfusion/ej2-calendars": "~21.1.41",
|
|
41
41
|
"@syncfusion/ej2-data": "~21.1.38",
|
|
42
|
-
"@syncfusion/ej2-dropdowns": "~21.1.
|
|
43
|
-
"@syncfusion/ej2-grids": "~21.1.
|
|
44
|
-
"@syncfusion/ej2-inputs": "~21.1.
|
|
42
|
+
"@syncfusion/ej2-dropdowns": "~21.1.41",
|
|
43
|
+
"@syncfusion/ej2-grids": "~21.1.41",
|
|
44
|
+
"@syncfusion/ej2-inputs": "~21.1.39",
|
|
45
45
|
"@syncfusion/ej2-layouts": "~21.1.37",
|
|
46
|
-
"@syncfusion/ej2-lists": "~21.1.
|
|
47
|
-
"@syncfusion/ej2-navigations": "~21.1.
|
|
46
|
+
"@syncfusion/ej2-lists": "~21.1.41",
|
|
47
|
+
"@syncfusion/ej2-navigations": "~21.1.39",
|
|
48
48
|
"@syncfusion/ej2-notifications": "~21.1.37",
|
|
49
|
-
"@syncfusion/ej2-popups": "~21.1.
|
|
50
|
-
"@syncfusion/ej2-richtexteditor": "~21.1.
|
|
51
|
-
"@syncfusion/ej2-treegrid": "~21.1.
|
|
49
|
+
"@syncfusion/ej2-popups": "~21.1.41",
|
|
50
|
+
"@syncfusion/ej2-richtexteditor": "~21.1.41",
|
|
51
|
+
"@syncfusion/ej2-treegrid": "~21.1.41"
|
|
52
52
|
},
|
|
53
53
|
"deprecated": false,
|
|
54
54
|
"description": "Essential JS 2 Gantt Component",
|
|
@@ -73,6 +73,6 @@
|
|
|
73
73
|
"url": "git+https://github.com/syncfusion/ej2-gantt.git"
|
|
74
74
|
},
|
|
75
75
|
"typings": "index.d.ts",
|
|
76
|
-
"version": "21.1.
|
|
76
|
+
"version": "21.1.41",
|
|
77
77
|
"sideEffects": false
|
|
78
78
|
}
|
|
@@ -281,7 +281,7 @@ var ContextMenu = /** @class */ (function () {
|
|
|
281
281
|
splitTaskDuration = Math.ceil(currentTaskDifference / this.parent.timelineSettings.timelineUnitSize);
|
|
282
282
|
splitTaskDuration -= 1;
|
|
283
283
|
}
|
|
284
|
-
var contextMenuClickDate = this.parent.dataOperation.getEndDate(startDate, splitTaskDuration, this.
|
|
284
|
+
var contextMenuClickDate = this.parent.dataOperation.getEndDate(startDate, splitTaskDuration, (this.parent.timelineSettings.bottomTier.unit !== "None") ? this.parent.timelineSettings.bottomTier.unit.toLocaleLowerCase() : this.parent.timelineSettings.topTier.unit.toLocaleLowerCase(), this.rowData, false);
|
|
285
285
|
return contextMenuClickDate;
|
|
286
286
|
};
|
|
287
287
|
ContextMenu.prototype.contextMenuBeforeOpen = function (args) {
|
|
@@ -477,7 +477,7 @@ var Dependency = /** @class */ (function () {
|
|
|
477
477
|
this.dateValidateModule.calculateEndDate(childGanttRecord);
|
|
478
478
|
}
|
|
479
479
|
this.parent.dataOperation.updateWidthLeft(childGanttRecord);
|
|
480
|
-
if (!this.parent.isLoad && childGanttRecord.parentItem && this.parent.isInPredecessorValidation &&
|
|
480
|
+
if (!this.parent.isLoad && !this.parent.isFromOnPropertyChange && childGanttRecord.parentItem && this.parent.isInPredecessorValidation &&
|
|
481
481
|
this.parent.getParentTask(childGanttRecord.parentItem).ganttProperties.isAutoSchedule) {
|
|
482
482
|
if (this.parentIds.indexOf(childGanttRecord.parentItem.uniqueID) === -1) {
|
|
483
483
|
this.parentIds.push(childGanttRecord.parentItem.uniqueID);
|
|
@@ -1860,6 +1860,7 @@ var DialogEdit = /** @class */ (function () {
|
|
|
1860
1860
|
DialogEdit.prototype.renderNotesTab = function (itemName) {
|
|
1861
1861
|
var ganttObj = this.parent;
|
|
1862
1862
|
var inputModel = this.beforeOpenArgs[itemName];
|
|
1863
|
+
inputModel.enableHtmlSanitizer = this.parent.enableHtmlSanitizer;
|
|
1863
1864
|
var ganttProp = this.editedRecord.ganttProperties;
|
|
1864
1865
|
var divElement = this.createDivElement('', ganttObj.element.id + '' + itemName + 'TabContainer');
|
|
1865
1866
|
RichTextEditor.Inject(RTEToolbar, Link, HtmlEditor, QuickToolbar, Count);
|
|
@@ -1124,7 +1124,13 @@ var Edit = /** @class */ (function () {
|
|
|
1124
1124
|
}
|
|
1125
1125
|
else if (isNullOrUndefined(previousData)) {
|
|
1126
1126
|
calcEndDate = previousStartDate;
|
|
1127
|
-
this.
|
|
1127
|
+
var initialData = this.parent.initialLoadData[childRecords[i].index];
|
|
1128
|
+
if (this.parent.isLoad) {
|
|
1129
|
+
this.calculateDateByRoundOffDuration(initialData, calcEndDate);
|
|
1130
|
+
}
|
|
1131
|
+
else {
|
|
1132
|
+
this.calculateDateByRoundOffDuration(childRecords[i], calcEndDate);
|
|
1133
|
+
}
|
|
1128
1134
|
if (this.parent.isOnEdit && this.validatedChildItems.indexOf(childRecords[i]) === -1) {
|
|
1129
1135
|
this.validatedChildItems.push(childRecords[i]);
|
|
1130
1136
|
}
|
|
@@ -400,10 +400,10 @@ var DateProcessor = /** @class */ (function () {
|
|
|
400
400
|
*/
|
|
401
401
|
DateProcessor.prototype.getDurationAsSeconds = function (duration, durationUnit) {
|
|
402
402
|
var value = 0;
|
|
403
|
-
if (!durationUnit || durationUnit === 'day') {
|
|
403
|
+
if (!durationUnit || durationUnit.toLocaleLowerCase() === 'day') {
|
|
404
404
|
value = this.parent.secondsPerDay * duration;
|
|
405
405
|
}
|
|
406
|
-
else if (durationUnit === 'hour') {
|
|
406
|
+
else if (durationUnit.toLocaleLowerCase() === 'hour') {
|
|
407
407
|
value = duration * 3600;
|
|
408
408
|
}
|
|
409
409
|
else {
|
|
@@ -93,6 +93,7 @@ export declare class Gantt extends Component<HTMLElement> implements INotifyProp
|
|
|
93
93
|
scrollLeftValue: any;
|
|
94
94
|
isToolBarClick: any;
|
|
95
95
|
isLocaleChanged: boolean;
|
|
96
|
+
initialLoadData: Object;
|
|
96
97
|
previousGanttColumns: ColumnModel[];
|
|
97
98
|
/** @hidden */
|
|
98
99
|
topBottomHeader: any;
|
package/src/gantt/base/gantt.js
CHANGED
|
@@ -728,6 +728,9 @@ var Gantt = /** @class */ (function (_super) {
|
|
|
728
728
|
* @private
|
|
729
729
|
*/
|
|
730
730
|
Gantt.prototype.renderGantt = function (isChange) {
|
|
731
|
+
if (isChange) {
|
|
732
|
+
this.isFromOnPropertyChange = isChange;
|
|
733
|
+
}
|
|
731
734
|
// predecessor calculation
|
|
732
735
|
if (this.predecessorModule && this.taskFields.dependency) {
|
|
733
736
|
this.predecessorModule['parentIds'] = [];
|
|
@@ -742,7 +745,6 @@ var Gantt = /** @class */ (function (_super) {
|
|
|
742
745
|
this.timelineModule.validateTimelineProp();
|
|
743
746
|
}
|
|
744
747
|
if (isChange) {
|
|
745
|
-
this.isFromOnPropertyChange = isChange;
|
|
746
748
|
if (this.enableValidation) {
|
|
747
749
|
this.dataOperation.updateGanttData();
|
|
748
750
|
}
|
|
@@ -187,7 +187,7 @@ export declare class TaskProcessor extends DateProcessor {
|
|
|
187
187
|
* @returns {number} .
|
|
188
188
|
* @private
|
|
189
189
|
*/
|
|
190
|
-
getTaskWidth(startDate: Date, endDate: Date): number;
|
|
190
|
+
getTaskWidth(startDate: Date, endDate: Date, ganttData?: ITaskData): number;
|
|
191
191
|
/**
|
|
192
192
|
* Get task left value
|
|
193
193
|
*
|
|
@@ -213,6 +213,7 @@ var TaskProcessor = /** @class */ (function (_super) {
|
|
|
213
213
|
*/
|
|
214
214
|
TaskProcessor.prototype.prepareDataSource = function (data) {
|
|
215
215
|
this.prepareRecordCollection(data, 0);
|
|
216
|
+
this.parent.initialLoadData = extend({}, {}, this.parent.flatData, true);
|
|
216
217
|
// Method to maintain the shared task uniqueIds
|
|
217
218
|
if (this.parent.viewType === 'ResourceView') {
|
|
218
219
|
this.calculateSharedTaskUniqueIds();
|
|
@@ -1041,7 +1042,7 @@ var TaskProcessor = /** @class */ (function (_super) {
|
|
|
1041
1042
|
return 0;
|
|
1042
1043
|
}
|
|
1043
1044
|
else {
|
|
1044
|
-
return this.getTaskWidth(sDate, eDate);
|
|
1045
|
+
return this.getTaskWidth(sDate, eDate, ganttProp);
|
|
1045
1046
|
}
|
|
1046
1047
|
};
|
|
1047
1048
|
TaskProcessor.prototype.getTaskbarHeight = function () {
|
|
@@ -1155,13 +1156,29 @@ var TaskProcessor = /** @class */ (function (_super) {
|
|
|
1155
1156
|
* @returns {number} .
|
|
1156
1157
|
* @private
|
|
1157
1158
|
*/
|
|
1158
|
-
TaskProcessor.prototype.getTaskWidth = function (startDate, endDate) {
|
|
1159
|
+
TaskProcessor.prototype.getTaskWidth = function (startDate, endDate, ganttData) {
|
|
1159
1160
|
var sDate = new Date(startDate.getTime());
|
|
1160
1161
|
var eDate = new Date(endDate.getTime());
|
|
1161
1162
|
var tierMode = this.parent.timelineModule.bottomTier !== 'None' ? this.parent.timelineModule.bottomTier :
|
|
1162
1163
|
this.parent.timelineModule.topTier;
|
|
1164
|
+
var isValid = false;
|
|
1165
|
+
var modifiedsDate = new Date(startDate.getTime());
|
|
1166
|
+
var hour = 0;
|
|
1167
|
+
if (ganttData && ganttData.durationUnit == 'hour') {
|
|
1168
|
+
modifiedsDate = new Date(modifiedsDate.getTime() + ganttData.duration * 60 * 60 * 1000);
|
|
1169
|
+
}
|
|
1170
|
+
if (ganttData && ganttData.durationUnit == 'minute') {
|
|
1171
|
+
modifiedsDate = new Date(modifiedsDate.getTime() + ganttData.duration * 60 * 60 * 60 * 1000);
|
|
1172
|
+
}
|
|
1173
|
+
for (var i = 0; i < this.parent.dayWorkingTime.length; i++) {
|
|
1174
|
+
hour = hour + this.parent.dayWorkingTime[i].to - this.parent.dayWorkingTime[i].from;
|
|
1175
|
+
}
|
|
1176
|
+
var dateDiff = modifiedsDate.getTime() - sDate.getTime();
|
|
1163
1177
|
if (tierMode === 'Day') {
|
|
1164
|
-
if (
|
|
1178
|
+
if ((Math.floor((dateDiff / (1000 * 60 * 60)) % 24) >= hour || dateDiff === 0)) {
|
|
1179
|
+
isValid = true;
|
|
1180
|
+
}
|
|
1181
|
+
if (this.getSecondsInDecimal(sDate) === this.parent.defaultStartTime && isValid) {
|
|
1165
1182
|
sDate.setHours(0, 0, 0, 0);
|
|
1166
1183
|
}
|
|
1167
1184
|
if (this.getSecondsInDecimal(eDate) === this.parent.defaultEndTime) {
|
|
@@ -1171,11 +1188,19 @@ var TaskProcessor = /** @class */ (function (_super) {
|
|
|
1171
1188
|
eDate.setHours(0, 0, 0, 0);
|
|
1172
1189
|
}
|
|
1173
1190
|
}
|
|
1191
|
+
else {
|
|
1192
|
+
isValid = true;
|
|
1193
|
+
}
|
|
1174
1194
|
if ((sDate).getTime() === (eDate).getTime()) {
|
|
1175
1195
|
return (this.parent.perDayWidth);
|
|
1176
1196
|
}
|
|
1177
1197
|
else {
|
|
1178
|
-
|
|
1198
|
+
if (isValid) {
|
|
1199
|
+
return ((this.getTimeDifference(sDate, eDate) / (1000 * 60 * 60 * 24)) * this.parent.perDayWidth);
|
|
1200
|
+
}
|
|
1201
|
+
else {
|
|
1202
|
+
return ((this.getTimeDifference(sDate, eDate) / (1000 * 60 * 60 * hour)) * this.parent.perDayWidth);
|
|
1203
|
+
}
|
|
1179
1204
|
}
|
|
1180
1205
|
};
|
|
1181
1206
|
/**
|
|
@@ -1412,7 +1412,6 @@ var ChartRows = /** @class */ (function (_super) {
|
|
|
1412
1412
|
}
|
|
1413
1413
|
if (this.templateData.hasChildRecords) {
|
|
1414
1414
|
var parentTaskbarTemplateNode = this.getParentTaskbarNode(i, taskbarContainerNode);
|
|
1415
|
-
var milestoneTemplateNode = this.getMilestoneNode(i, taskbarContainerNode);
|
|
1416
1415
|
if (!this.templateData.ganttProperties.isAutoSchedule) {
|
|
1417
1416
|
var manualTaskbar = this.getManualTaskbar();
|
|
1418
1417
|
if (!isNullOrUndefined(manualTaskbar[0])) {
|
|
@@ -1427,9 +1426,6 @@ var ChartRows = /** @class */ (function (_super) {
|
|
|
1427
1426
|
if (parentTaskbarTemplateNode && parentTaskbarTemplateNode.length > 0) {
|
|
1428
1427
|
taskbarContainerNode[0].appendChild([].slice.call(parentTaskbarTemplateNode)[0]);
|
|
1429
1428
|
}
|
|
1430
|
-
else if (milestoneTemplateNode && milestoneTemplateNode.length > 0) {
|
|
1431
|
-
taskbarContainerNode[0].appendChild([].slice.call(milestoneTemplateNode)[0]);
|
|
1432
|
-
}
|
|
1433
1429
|
if (this.parent.renderBaseline && this.templateData.ganttProperties.baselineStartDate &&
|
|
1434
1430
|
this.templateData.ganttProperties.baselineEndDate) {
|
|
1435
1431
|
taskBaselineTemplateNode = ((this.templateData.ganttProperties.baselineStartDate.getTime() === this.templateData.ganttProperties.baselineEndDate.getTime()) || ((!isNullOrUndefined(this.templateData.ganttProperties.baselineStartDate) && !isNullOrUndefined(this.templateData.ganttProperties.startDate) && (this.templateData.ganttProperties.baselineStartDate.getTime() === this.templateData.ganttProperties.startDate.getTime()))
|
|
@@ -168,12 +168,14 @@ var NonWorkingDay = /** @class */ (function () {
|
|
|
168
168
|
};
|
|
169
169
|
NonWorkingDay.prototype.updateHolidayLabelHeight = function () {
|
|
170
170
|
var height = this.parent.getContentHeight();
|
|
171
|
+
var gantttable = document.getElementById("ganttContainer");
|
|
171
172
|
// eslint-disable-next-line
|
|
172
173
|
var toolbarHeight = 0;
|
|
173
174
|
if (!isNullOrUndefined(this.parent.toolbarModule) && !isNullOrUndefined(this.parent.toolbarModule.element)) {
|
|
174
175
|
toolbarHeight = this.parent.toolbarModule.element.offsetHeight;
|
|
175
176
|
}
|
|
176
|
-
var viewportHeight = this.parent.
|
|
177
|
+
var viewportHeight = (this.parent.height === 'auto') ? gantttable.offsetHeight - toolbarHeight - this.parent.ganttChartModule.chartTimelineContainer.offsetHeight :
|
|
178
|
+
this.parent.ganttHeight - toolbarHeight - this.parent.ganttChartModule.chartTimelineContainer.offsetHeight;
|
|
177
179
|
var top = (viewportHeight < height) ? viewportHeight / 2 : height / 2;
|
|
178
180
|
var labels = this.holidayContainer.querySelectorAll('.' + cls.holidayLabel);
|
|
179
181
|
for (var i = 0; i < labels.length; i++) {
|
package/styles/bootstrap.css
CHANGED
package/styles/bootstrap4.css
CHANGED
package/styles/bootstrap5.css
CHANGED
package/styles/fabric-dark.css
CHANGED
package/styles/fabric.css
CHANGED
package/styles/fluent-dark.css
CHANGED
package/styles/fluent.css
CHANGED
|
@@ -1320,14 +1320,6 @@
|
|
|
1320
1320
|
outline-offset: 2px;
|
|
1321
1321
|
}
|
|
1322
1322
|
}
|
|
1323
|
-
.e-dialog.e-filter-popup {
|
|
1324
|
-
.e-footer-content {
|
|
1325
|
-
|
|
1326
|
-
@if ($skin-name =='FluentUI') {
|
|
1327
|
-
padding-top: 0;
|
|
1328
|
-
}
|
|
1329
|
-
}
|
|
1330
|
-
}
|
|
1331
1323
|
}
|
|
1332
1324
|
|
|
1333
1325
|
.e-gantt-dialog .e-tab .e-tab-header {
|
package/styles/gantt/fabric.css
CHANGED
package/styles/gantt/fluent.css
CHANGED
package/styles/highcontrast.css
CHANGED
package/styles/material-dark.css
CHANGED
package/styles/material.css
CHANGED
package/styles/tailwind-dark.css
CHANGED