@syncfusion/ej2-schedule 21.1.41 → 21.2.4
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 +10 -0
- package/dist/ej2-schedule.min.js +2 -2
- package/dist/ej2-schedule.umd.min.js +2 -2
- package/dist/ej2-schedule.umd.min.js.map +1 -1
- package/dist/es6/ej2-schedule.es2015.js +45 -8
- package/dist/es6/ej2-schedule.es2015.js.map +1 -1
- package/dist/es6/ej2-schedule.es5.js +47 -9
- package/dist/es6/ej2-schedule.es5.js.map +1 -1
- package/dist/global/ej2-schedule.min.js +2 -2
- package/dist/global/ej2-schedule.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +15 -15
- package/src/schedule/actions/action-base.js +7 -1
- package/src/schedule/actions/drag.js +11 -6
- package/src/schedule/event-renderer/timeline-view.d.ts +1 -0
- package/src/schedule/event-renderer/timeline-view.js +28 -1
- package/src/schedule/renderer/renderer.js +1 -1
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 21.
|
|
3
|
+
* version : 21.2.4
|
|
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-schedule@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-schedule@21.
|
|
3
|
+
"_id": "@syncfusion/ej2-schedule@21.2.3",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512-
|
|
5
|
+
"_integrity": "sha512-iBQZrY80nX2tK6NN+/2FzLObcxL0QT+lykvtOE/FXSmTSvAaotT1s0xrP9moLkrA1oLJVTzavM327S43XI2oEA==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-schedule",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -23,8 +23,8 @@
|
|
|
23
23
|
"/@syncfusion/ej2-react-schedule",
|
|
24
24
|
"/@syncfusion/ej2-vue-schedule"
|
|
25
25
|
],
|
|
26
|
-
"_resolved": "https://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-schedule/-/ej2-schedule-21.
|
|
27
|
-
"_shasum": "
|
|
26
|
+
"_resolved": "https://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-schedule/-/ej2-schedule-21.2.3.tgz",
|
|
27
|
+
"_shasum": "c6a62a12ee170e5e23a379e118d441e53850832c",
|
|
28
28
|
"_spec": "@syncfusion/ej2-schedule@*",
|
|
29
29
|
"_where": "/jenkins/workspace/elease-automation_release_21.1.1/packages/included",
|
|
30
30
|
"author": {
|
|
@@ -35,16 +35,16 @@
|
|
|
35
35
|
},
|
|
36
36
|
"bundleDependencies": false,
|
|
37
37
|
"dependencies": {
|
|
38
|
-
"@syncfusion/ej2-base": "~21.
|
|
39
|
-
"@syncfusion/ej2-buttons": "~21.
|
|
40
|
-
"@syncfusion/ej2-calendars": "~21.
|
|
41
|
-
"@syncfusion/ej2-data": "~21.
|
|
42
|
-
"@syncfusion/ej2-dropdowns": "~21.
|
|
43
|
-
"@syncfusion/ej2-excel-export": "~21.
|
|
44
|
-
"@syncfusion/ej2-inputs": "~21.
|
|
45
|
-
"@syncfusion/ej2-lists": "~21.
|
|
46
|
-
"@syncfusion/ej2-navigations": "~21.
|
|
47
|
-
"@syncfusion/ej2-popups": "~21.
|
|
38
|
+
"@syncfusion/ej2-base": "~21.2.3",
|
|
39
|
+
"@syncfusion/ej2-buttons": "~21.2.3",
|
|
40
|
+
"@syncfusion/ej2-calendars": "~21.2.4",
|
|
41
|
+
"@syncfusion/ej2-data": "~21.2.4",
|
|
42
|
+
"@syncfusion/ej2-dropdowns": "~21.2.4",
|
|
43
|
+
"@syncfusion/ej2-excel-export": "~21.2.4",
|
|
44
|
+
"@syncfusion/ej2-inputs": "~21.2.4",
|
|
45
|
+
"@syncfusion/ej2-lists": "~21.2.3",
|
|
46
|
+
"@syncfusion/ej2-navigations": "~21.2.4",
|
|
47
|
+
"@syncfusion/ej2-popups": "~21.2.4"
|
|
48
48
|
},
|
|
49
49
|
"deprecated": false,
|
|
50
50
|
"description": "Flexible scheduling library with more built-in features and enhanced customization options similar to outlook and google calendar, allowing the users to plan and manage their appointments with efficient data-binding support.",
|
|
@@ -73,6 +73,6 @@
|
|
|
73
73
|
"url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
|
|
74
74
|
},
|
|
75
75
|
"typings": "index.d.ts",
|
|
76
|
-
"version": "21.
|
|
76
|
+
"version": "21.2.4",
|
|
77
77
|
"sideEffects": false
|
|
78
78
|
}
|
|
@@ -333,6 +333,9 @@ var ActionBase = /** @class */ (function () {
|
|
|
333
333
|
};
|
|
334
334
|
ActionBase.prototype.dynamicYearlyEventsRendering = function (event, isResize) {
|
|
335
335
|
if (isResize === void 0) { isResize = false; }
|
|
336
|
+
if (!isNullOrUndefined(this.parent.eventDragArea)) {
|
|
337
|
+
return;
|
|
338
|
+
}
|
|
336
339
|
var appWidth = this.actionObj.cellWidth - 7;
|
|
337
340
|
if (isResize && (this.resizeEdges.left || this.resizeEdges.right)) {
|
|
338
341
|
appWidth = this.actionObj.cellWidth * event.count;
|
|
@@ -404,6 +407,9 @@ var ActionBase = /** @class */ (function () {
|
|
|
404
407
|
};
|
|
405
408
|
ActionBase.prototype.dynamicEventsRendering = function (event) {
|
|
406
409
|
var _this = this;
|
|
410
|
+
if (!isNullOrUndefined(this.parent.eventDragArea)) {
|
|
411
|
+
return;
|
|
412
|
+
}
|
|
407
413
|
var dateRender = this.parent.activeView.renderDates;
|
|
408
414
|
var workCells = [].slice.call(this.parent.element.querySelectorAll('.' + cls.WORK_CELLS_CLASS));
|
|
409
415
|
var workDays = this.parent.activeViewOptions.workDays;
|
|
@@ -440,7 +446,7 @@ var ActionBase = /** @class */ (function () {
|
|
|
440
446
|
this.monthEvent.applyResourceColor(appointmentElement, event_1, 'backgroundColor', groupOrder);
|
|
441
447
|
setStyleAttribute(appointmentElement, { 'width': appWidth + 'px', 'border': '0px', 'pointer-events': 'none' });
|
|
442
448
|
var cellTd = workCells[parseInt(day.toString(), 10)];
|
|
443
|
-
if (cellTd
|
|
449
|
+
if (cellTd) {
|
|
444
450
|
this.monthEvent.renderElement(cellTd, appointmentElement, true);
|
|
445
451
|
this.actionObj.cloneElement.push(appointmentElement);
|
|
446
452
|
}
|
|
@@ -965,10 +965,12 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
965
965
|
}
|
|
966
966
|
}
|
|
967
967
|
var event = this.getUpdatedEvent(this.actionObj.start, this.actionObj.end, this.actionObj.event);
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
var
|
|
971
|
-
|
|
968
|
+
if (isNullOrUndefined(this.parent.eventDragArea)) {
|
|
969
|
+
var eventWrappers = [].slice.call(this.parent.element.querySelectorAll('.' + cls.CLONE_ELEMENT_CLASS));
|
|
970
|
+
for (var _i = 0, eventWrappers_1 = eventWrappers; _i < eventWrappers_1.length; _i++) {
|
|
971
|
+
var wrapper = eventWrappers_1[_i];
|
|
972
|
+
remove(wrapper);
|
|
973
|
+
}
|
|
972
974
|
}
|
|
973
975
|
if (this.multiData && this.multiData.length > 0) {
|
|
974
976
|
var startTime = util.resetTime(new Date(event[this.parent.eventFields.startTime]));
|
|
@@ -1068,9 +1070,12 @@ var DragAndDrop = /** @class */ (function (_super) {
|
|
|
1068
1070
|
}
|
|
1069
1071
|
else {
|
|
1070
1072
|
if (this.isCursorAhead || cursorDrag) {
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
+
var minutes = this.isTimelineDayProcess ? MINUTES_PER_DAY : this.actionObj.slotInterval;
|
|
1074
|
+
eventStart.setMinutes(eventStart.getMinutes() + minutes);
|
|
1073
1075
|
eventStart.setMilliseconds(-(eventDuration));
|
|
1076
|
+
if (eventStart.getTime() === util.resetTime(eventStart).getTime() && eventStart.getMinutes() === 0 && eventDuration === 0) {
|
|
1077
|
+
eventStart.setMinutes(-minutes);
|
|
1078
|
+
}
|
|
1074
1079
|
}
|
|
1075
1080
|
else {
|
|
1076
1081
|
eventStart.setMinutes(eventStart.getMinutes() -
|
|
@@ -25,6 +25,7 @@ export declare class TimelineEvent extends MonthEvent {
|
|
|
25
25
|
renderEvents(event: Record<string, any>, resIndex: number, appointmentsList?: Record<string, any>[]): void;
|
|
26
26
|
private renderTimelineMoreIndicator;
|
|
27
27
|
updateCellHeight(cell: HTMLElement, height: number): void;
|
|
28
|
+
private adjustAppointments;
|
|
28
29
|
private getFirstChild;
|
|
29
30
|
updateBlockElements(): void;
|
|
30
31
|
getStartTime(event: Record<string, any>, eventData: Record<string, any>): Date;
|
|
@@ -197,10 +197,21 @@ var TimelineEvent = /** @class */ (function (_super) {
|
|
|
197
197
|
'width': appWidth + 'px', 'left': appLeft + 'px', 'right': appRight + 'px', 'top': appTop + 'px'
|
|
198
198
|
});
|
|
199
199
|
this.wireAppointmentEvents(appointmentElement, event);
|
|
200
|
-
this.renderEventElement(event, appointmentElement, cellTd);
|
|
201
200
|
if (this.parent.rowAutoHeight) {
|
|
201
|
+
var conWrap = this.parent.element.querySelector('.' + cls.CONTENT_WRAP_CLASS);
|
|
202
|
+
var conWidth = conWrap.getBoundingClientRect().width;
|
|
203
|
+
var isWithoutScroll = conWrap.offsetHeight === conWrap.clientHeight &&
|
|
204
|
+
conWrap.offsetWidth === conWrap.clientWidth;
|
|
205
|
+
this.renderEventElement(event, appointmentElement, cellTd);
|
|
202
206
|
var firstChild = this.getFirstChild(resIndex);
|
|
203
207
|
this.updateCellHeight(firstChild, height);
|
|
208
|
+
if (isWithoutScroll &&
|
|
209
|
+
(conWrap.offsetWidth > conWrap.clientWidth || conWidth !== conWrap.getBoundingClientRect().width)) {
|
|
210
|
+
this.adjustAppointments(conWidth);
|
|
211
|
+
}
|
|
212
|
+
}
|
|
213
|
+
else {
|
|
214
|
+
this.renderEventElement(event, appointmentElement, cellTd);
|
|
204
215
|
}
|
|
205
216
|
}
|
|
206
217
|
else {
|
|
@@ -292,6 +303,22 @@ var TimelineEvent = /** @class */ (function (_super) {
|
|
|
292
303
|
}
|
|
293
304
|
}
|
|
294
305
|
};
|
|
306
|
+
TimelineEvent.prototype.adjustAppointments = function (conWidth) {
|
|
307
|
+
var _this = this;
|
|
308
|
+
var tr = this.parent.element.querySelector('.' + cls.CONTENT_TABLE_CLASS + ' tbody tr');
|
|
309
|
+
this.cellWidth = this.workCells[0].getBoundingClientRect().width;
|
|
310
|
+
var currentPercentage = (this.cellWidth * tr.children.length) / (conWidth / 100);
|
|
311
|
+
var apps = [].slice.call(this.parent.element.querySelectorAll('.' + cls.APPOINTMENT_CLASS));
|
|
312
|
+
apps.forEach(function (app) {
|
|
313
|
+
if (_this.parent.enableRtl && app.style.right !== '0px') {
|
|
314
|
+
app.style.right = ((parseFloat(app.style.right) / 100) * currentPercentage) + 'px';
|
|
315
|
+
}
|
|
316
|
+
else if (app.style.left !== '0px') {
|
|
317
|
+
app.style.left = ((parseFloat(app.style.left) / 100) * currentPercentage) + 'px';
|
|
318
|
+
}
|
|
319
|
+
app.style.width = ((parseFloat(app.style.width) / 100) * currentPercentage) + 'px';
|
|
320
|
+
});
|
|
321
|
+
};
|
|
295
322
|
TimelineEvent.prototype.getFirstChild = function (index) {
|
|
296
323
|
var query = '.' + cls.CONTENT_TABLE_CLASS + ' tbody td';
|
|
297
324
|
var groupIndex = '';
|
|
@@ -91,7 +91,7 @@ var Render = /** @class */ (function () {
|
|
|
91
91
|
this.parent.virtualScrollModule.destroy();
|
|
92
92
|
this.parent.virtualScrollModule = null;
|
|
93
93
|
}
|
|
94
|
-
if ((['Agenda', 'Year'].indexOf(this.parent.currentView) === -1 ||
|
|
94
|
+
if ((['Agenda', 'MonthAgenda', 'Year', 'TimelineYear'].indexOf(this.parent.currentView) === -1 ||
|
|
95
95
|
(this.parent.currentView === 'TimelineYear' && this.parent.activeViewOptions.orientation === 'Vertical'))
|
|
96
96
|
&& this.parent.activeViewOptions.allowVirtualScrolling
|
|
97
97
|
&& this.parent.activeViewOptions.group.resources.length > 0 && !this.parent.uiStateValues.isGroupAdaptive) {
|