@syncfusion/ej2-schedule 33.1.44 → 33.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.
- 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 +17 -27
- package/dist/es6/ej2-schedule.es2015.js.map +1 -1
- package/dist/es6/ej2-schedule.es5.js +17 -27
- 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 +7 -7
- package/src/schedule/actions/action-base.js +1 -1
- package/src/schedule/actions/resize.js +14 -25
- package/src/schedule/event-renderer/timeline-view.js +2 -1
|
@@ -9523,7 +9523,8 @@ var TimelineEvent = /** @__PURE__ @class */ (function (_super) {
|
|
|
9523
9523
|
return (width > spannedWidth) ? width - spannedWidth : width - startWidth;
|
|
9524
9524
|
};
|
|
9525
9525
|
TimelineEvent.prototype.getEndTimeOfLastSlot = function (startHour, endHour, interval) {
|
|
9526
|
-
var
|
|
9526
|
+
var dstOffset = ((endHour.getTimezoneOffset() - startHour.getTimezoneOffset()) * MS_PER_MINUTE);
|
|
9527
|
+
var minutesInDay = (endHour.getTime() - startHour.getTime() - dstOffset) / MS_PER_MINUTE;
|
|
9527
9528
|
var lastSlotEndMinutes = Math.floor(minutesInDay / interval) * interval;
|
|
9528
9529
|
var lastSlotEndTime = new Date(startHour);
|
|
9529
9530
|
lastSlotEndTime.setMinutes(lastSlotEndMinutes);
|
|
@@ -21761,7 +21762,7 @@ var ActionBase = /** @__PURE__ @class */ (function () {
|
|
|
21761
21762
|
var startHour = this.parent.activeView.getStartHour();
|
|
21762
21763
|
var intervalInMS = MS_PER_MINUTE * this.actionObj.interval;
|
|
21763
21764
|
dateInMS += (startHour.getHours() * 60 + startHour.getMinutes()) * MS_PER_MINUTE + startHour.getSeconds() * 1000;
|
|
21764
|
-
dateInMS = dateInMS + ((date.getTime() - dateInMS) / intervalInMS) * intervalInMS;
|
|
21765
|
+
dateInMS = dateInMS + Math.floor((date.getTime() - dateInMS) / intervalInMS) * intervalInMS;
|
|
21765
21766
|
return new Date(dateInMS);
|
|
21766
21767
|
};
|
|
21767
21768
|
ActionBase.prototype.getContentAreaDimension = function () {
|
|
@@ -22540,20 +22541,24 @@ var Resize = /** @__PURE__ @class */ (function (_super) {
|
|
|
22540
22541
|
offsetValue += (this.parent.getElementWidth(this.actionObj.clone) - this.actionObj.cellWidth);
|
|
22541
22542
|
}
|
|
22542
22543
|
cellIndex = !isTimelineMonth ? Math.round(offsetValue / (this.parent.getElementWidth(tr) / noOfDays)) :
|
|
22543
|
-
Math.floor(offsetValue /
|
|
22544
|
+
Math.floor(offsetValue / (this.parent.getElementWidth(tr) / noOfDays));
|
|
22544
22545
|
cellIndex = isLeft ? cellIndex : isTimelineMonth ? cellIndex + 1 : cellIndex;
|
|
22545
22546
|
isLastCell = cellIndex === tdCollections.length;
|
|
22546
22547
|
cellIndex = (cellIndex < 0) ? 0 : (cellIndex >= noOfDays) ? noOfDays - 1 : cellIndex;
|
|
22547
22548
|
}
|
|
22548
22549
|
else {
|
|
22549
22550
|
var cellWidth = this.actionObj.cellWidth;
|
|
22550
|
-
cellIndex = isLeft ? Math.
|
|
22551
|
+
cellIndex = isLeft ? Math.floor(offset / this.actionObj.cellWidth) :
|
|
22551
22552
|
Math.ceil((offset + (this.parent.getElementWidth(this.actionObj.clone) - cellWidth)) / this.actionObj.cellWidth);
|
|
22552
22553
|
if (this.parent.enableRtl) {
|
|
22553
|
-
var
|
|
22554
|
-
|
|
22555
|
-
|
|
22556
|
-
|
|
22554
|
+
var cellOffsetWidth = 0;
|
|
22555
|
+
if (headerName === 'TimelineMonth' || (!this.parent.activeViewOptions.timeScale.enable &&
|
|
22556
|
+
!isTimelineMonth)) {
|
|
22557
|
+
cellOffsetWidth = this.actionObj.cellWidth;
|
|
22558
|
+
}
|
|
22559
|
+
var offsetWidth = (Math.floor(offset / this.actionObj.cellWidth) *
|
|
22560
|
+
this.actionObj.cellWidth) + (isLeft ? 0 : this.parent.getElementWidth(this.actionObj.clone) - cellOffsetWidth);
|
|
22561
|
+
cellIndex = Math.floor(offsetWidth / this.actionObj.cellWidth);
|
|
22557
22562
|
}
|
|
22558
22563
|
isLastCell = cellIndex === tdCollections.length;
|
|
22559
22564
|
cellIndex = this.getIndex(cellIndex);
|
|
@@ -22571,29 +22576,14 @@ var Resize = /** @__PURE__ @class */ (function (_super) {
|
|
|
22571
22576
|
}
|
|
22572
22577
|
else {
|
|
22573
22578
|
if (!isLeft) {
|
|
22574
|
-
|
|
22575
|
-
var pixelsPerInterval = this.actionObj.cellWidth /
|
|
22576
|
-
(this.actionObj.slotInterval / this.actionObj.interval);
|
|
22577
|
-
var numIntervals = Math.round(cloneWidth / pixelsPerInterval);
|
|
22578
|
-
cloneWidth = numIntervals * pixelsPerInterval;
|
|
22579
|
-
offset = offset + cloneWidth;
|
|
22579
|
+
offset += this.parent.getElementWidth(this.actionObj.clone);
|
|
22580
22580
|
}
|
|
22581
22581
|
var spanMinutes = Math.ceil((this.actionObj.slotInterval / this.actionObj.cellWidth) *
|
|
22582
22582
|
(offset - Math.floor(offset / this.actionObj.cellWidth) * this.actionObj.cellWidth));
|
|
22583
|
-
spanMinutes = (isLastCell || (!isLeft && spanMinutes === 0
|
|
22583
|
+
spanMinutes = (isLastCell || (!isLeft && spanMinutes === 0 && !this.parent.enableRtl)) ?
|
|
22584
|
+
this.actionObj.slotInterval : spanMinutes;
|
|
22584
22585
|
resizeTime = new Date(resizeDate.getTime());
|
|
22585
|
-
resizeTime
|
|
22586
|
-
var isCustomResizeInterval = this.actionObj.interval !== this.actionObj.slotInterval;
|
|
22587
|
-
var initialCellTime = new Date(resizeTime.getTime());
|
|
22588
|
-
var intervalInMS = this.actionObj.interval * 60000;
|
|
22589
|
-
if (intervalInMS > 0 && isCustomResizeInterval) {
|
|
22590
|
-
if (this.resizeEdges.right || this.resizeEdges.left) {
|
|
22591
|
-
var eventTime = this.resizeEdges.right ? eventEnd : eventStart;
|
|
22592
|
-
var timeDifferenceMs = initialCellTime.getTime() - eventTime.getTime();
|
|
22593
|
-
var intervalCount = Math.round(timeDifferenceMs / intervalInMS);
|
|
22594
|
-
resizeTime = new Date(eventTime.getTime() + intervalCount * intervalInMS);
|
|
22595
|
-
}
|
|
22596
|
-
}
|
|
22586
|
+
resizeTime.setMinutes(resizeTime.getMinutes() + spanMinutes);
|
|
22597
22587
|
this.updateTimePosition(resizeTime);
|
|
22598
22588
|
}
|
|
22599
22589
|
}
|