@syncfusion/ej2-schedule 20.1.48 → 20.1.55
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 +22 -0
- 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 +48 -41
- package/dist/es6/ej2-schedule.es2015.js.map +1 -1
- package/dist/es6/ej2-schedule.es5.js +48 -41
- 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/recurrence-editor/date-generator.js +7 -1
- package/src/schedule/base/schedule.js +1 -1
- package/src/schedule/event-renderer/event-base.js +3 -0
- package/src/schedule/event-renderer/month.d.ts +0 -2
- package/src/schedule/event-renderer/month.js +33 -38
- package/src/schedule/event-renderer/vertical-view.js +3 -0
- package/src/schedule/exports/calendar-export.js +1 -1
- package/styles/bootstrap-dark.css +83 -968
- package/styles/bootstrap.css +83 -967
- package/styles/bootstrap4.css +83 -990
- package/styles/bootstrap5-dark.css +83 -988
- package/styles/bootstrap5.css +83 -988
- package/styles/fabric-dark.css +83 -968
- package/styles/fabric.css +83 -970
- package/styles/fluent-dark.css +83 -968
- package/styles/fluent.css +83 -968
- package/styles/highcontrast-light.css +83 -967
- package/styles/highcontrast.css +83 -972
- package/styles/material-dark.css +83 -967
- package/styles/material.css +83 -967
- package/styles/recurrence-editor/bootstrap-dark.css +6 -94
- package/styles/recurrence-editor/bootstrap.css +6 -94
- package/styles/recurrence-editor/bootstrap4.css +6 -94
- package/styles/recurrence-editor/bootstrap5-dark.css +6 -94
- package/styles/recurrence-editor/bootstrap5.css +6 -94
- package/styles/recurrence-editor/fabric-dark.css +6 -94
- package/styles/recurrence-editor/fabric.css +6 -94
- package/styles/recurrence-editor/fluent-dark.css +6 -94
- package/styles/recurrence-editor/fluent.css +6 -94
- package/styles/recurrence-editor/highcontrast-light.css +6 -94
- package/styles/recurrence-editor/highcontrast.css +6 -94
- package/styles/recurrence-editor/material-dark.css +6 -94
- package/styles/recurrence-editor/material.css +6 -94
- package/styles/recurrence-editor/tailwind-dark.css +6 -94
- package/styles/recurrence-editor/tailwind.css +6 -94
- package/styles/schedule/bootstrap-dark.css +78 -875
- package/styles/schedule/bootstrap.css +78 -874
- package/styles/schedule/bootstrap4.css +78 -897
- package/styles/schedule/bootstrap5-dark.css +78 -895
- package/styles/schedule/bootstrap5.css +78 -895
- package/styles/schedule/fabric-dark.css +78 -875
- package/styles/schedule/fabric.css +78 -877
- package/styles/schedule/fluent-dark.css +78 -875
- package/styles/schedule/fluent.css +78 -875
- package/styles/schedule/highcontrast-light.css +78 -874
- package/styles/schedule/highcontrast.css +78 -879
- package/styles/schedule/material-dark.css +78 -874
- package/styles/schedule/material.css +78 -874
- package/styles/schedule/tailwind-dark.css +78 -895
- package/styles/schedule/tailwind.css +78 -895
- package/styles/tailwind-dark.css +83 -988
- package/styles/tailwind.css +83 -988
|
@@ -3731,6 +3731,9 @@ function dailyType(startDate, endDate, data, ruleObject) {
|
|
|
3731
3731
|
}
|
|
3732
3732
|
}
|
|
3733
3733
|
tempDate.setDate(tempDate.getDate() + interval);
|
|
3734
|
+
if (tempDate.getHours() !== startDate.getHours()) {
|
|
3735
|
+
tempDate.setHours(startDate.getHours());
|
|
3736
|
+
}
|
|
3734
3737
|
}
|
|
3735
3738
|
}
|
|
3736
3739
|
/**
|
|
@@ -3775,6 +3778,9 @@ function weeklyType(startDate, endDate, data, ruleObject) {
|
|
|
3775
3778
|
break;
|
|
3776
3779
|
}
|
|
3777
3780
|
tempDate.setDate(tempDate.getDate() + 1);
|
|
3781
|
+
if (tempDate.getHours() !== startDate.getHours()) {
|
|
3782
|
+
tempDate.setHours(startDate.getHours());
|
|
3783
|
+
}
|
|
3778
3784
|
compareTempDate = new Date(tempDate.getTime());
|
|
3779
3785
|
compareTempDate = resetTime(compareTempDate);
|
|
3780
3786
|
}
|
|
@@ -4656,7 +4662,7 @@ function insertDateCollection(state, startDate, endDate, data, ruleObject, dayDa
|
|
|
4656
4662
|
function weekCount(year, startDayOfWeek, monthCollection, week, ruleObject) {
|
|
4657
4663
|
const firstDayOfWeek = startDayOfWeek || 0;
|
|
4658
4664
|
const firstOfMonth = new Date(year, ruleObject.month[0] - 1, 1);
|
|
4659
|
-
const lastOfMonth = new Date(year, ruleObject.month[0]
|
|
4665
|
+
const lastOfMonth = new Date(year, ruleObject.month[0], 0);
|
|
4660
4666
|
const numberOfDaysInMonth = lastOfMonth.getDate();
|
|
4661
4667
|
const firstWeekDay = (firstOfMonth.getDay() - firstDayOfWeek + 7) % 7;
|
|
4662
4668
|
const used = firstWeekDay + numberOfDaysInMonth;
|
|
@@ -5609,6 +5615,9 @@ class EventBase {
|
|
|
5609
5615
|
this.parent.removeSelectedClass();
|
|
5610
5616
|
}
|
|
5611
5617
|
addClass(cells, APPOINTMENT_BORDER);
|
|
5618
|
+
if (cells.length > 0) {
|
|
5619
|
+
cells[cells.length - 1].focus();
|
|
5620
|
+
}
|
|
5612
5621
|
}
|
|
5613
5622
|
getSelectedAppointments() {
|
|
5614
5623
|
return [].slice.call(this.parent.element.querySelectorAll('.' + APPOINTMENT_BORDER + ',.' + APPOINTMENT_CLASS + ':focus'));
|
|
@@ -6777,6 +6786,9 @@ class VerticalEvent extends EventBase {
|
|
|
6777
6786
|
const currentDate = resetTime(new Date(this.dateRender[resource][dayIndex].getTime()));
|
|
6778
6787
|
const schedule = getStartEndHours(currentDate, this.startHour, this.endHour);
|
|
6779
6788
|
const isValidEvent = this.isValidEvent(eventObj, eStart, eEnd, schedule);
|
|
6789
|
+
if ((eStart.getTime() < this.parent.minDate.getTime()) || (eEnd.getTime() > this.parent.maxDate.getTime())) {
|
|
6790
|
+
return;
|
|
6791
|
+
}
|
|
6780
6792
|
if (eStart <= eEnd && isValidEvent) {
|
|
6781
6793
|
const appHeight = this.getHeight(eStart, eEnd);
|
|
6782
6794
|
if (eStart.getTime() > schedule.startHour.getTime()) {
|
|
@@ -7082,7 +7094,6 @@ class MonthEvent extends EventBase {
|
|
|
7082
7094
|
constructor(parent) {
|
|
7083
7095
|
super(parent);
|
|
7084
7096
|
this.renderedEvents = [];
|
|
7085
|
-
this.eventsRendered = [];
|
|
7086
7097
|
this.monthHeaderHeight = 0;
|
|
7087
7098
|
this.moreIndicatorHeight = 19;
|
|
7088
7099
|
this.renderType = 'day';
|
|
@@ -7196,7 +7207,6 @@ class MonthEvent extends EventBase {
|
|
|
7196
7207
|
}
|
|
7197
7208
|
renderEventsHandler(dateRender, workDays, resData) {
|
|
7198
7209
|
this.renderedEvents = [];
|
|
7199
|
-
this.eventsRendered = [];
|
|
7200
7210
|
let eventsList;
|
|
7201
7211
|
let blockList;
|
|
7202
7212
|
let resIndex = 0;
|
|
@@ -7232,11 +7242,18 @@ class MonthEvent extends EventBase {
|
|
|
7232
7242
|
const filteredDates = this.getRenderedDates(dateRender);
|
|
7233
7243
|
this.getSlotDates(workDays || this.parent.activeViewOptions.workDays);
|
|
7234
7244
|
this.processBlockEvents(blockList, resIndex, resData);
|
|
7245
|
+
let events = [];
|
|
7235
7246
|
for (const event of eventsList) {
|
|
7236
7247
|
if (this.parent.resourceBase && !resData) {
|
|
7237
7248
|
this.cssClass = this.parent.resourceBase.getCssClass(event);
|
|
7238
7249
|
}
|
|
7239
|
-
|
|
7250
|
+
events = events.concat(this.splitEvent(event, filteredDates || this.dateRender));
|
|
7251
|
+
}
|
|
7252
|
+
for (let level = 0; level < this.slots.length; level++) {
|
|
7253
|
+
this.renderedEvents = [];
|
|
7254
|
+
const slot = this.slots[level];
|
|
7255
|
+
const endDate = addDays(new Date(slot[slot.length - 1]), 1);
|
|
7256
|
+
const spannedEvents = this.filterEvents(new Date(slot[0]), endDate, events);
|
|
7240
7257
|
for (const event of spannedEvents) {
|
|
7241
7258
|
if (this.maxHeight) {
|
|
7242
7259
|
const sDate = this.parent.currentView === 'Month' ? event[this.fields.startTime] :
|
|
@@ -7532,15 +7549,11 @@ class MonthEvent extends EventBase {
|
|
|
7532
7549
|
const startTime = event[this.fields.startTime];
|
|
7533
7550
|
const endTime = event[this.fields.endTime];
|
|
7534
7551
|
const day = this.parent.getIndexOfDate(this.dateRender, resetTime(startTime));
|
|
7535
|
-
if (day < 0) {
|
|
7536
|
-
return;
|
|
7537
|
-
}
|
|
7538
|
-
if ((startTime.getTime() < this.parent.minDate.getTime()) || (endTime.getTime() > this.parent.maxDate.getTime())) {
|
|
7552
|
+
if ((day < 0) || (startTime.getTime() < this.parent.minDate.getTime()) || (endTime.getTime() > this.parent.maxDate.getTime())) {
|
|
7539
7553
|
return;
|
|
7540
7554
|
}
|
|
7541
7555
|
const overlapCount = this.getIndex(startTime);
|
|
7542
7556
|
event.Index = overlapCount;
|
|
7543
|
-
this.renderedEvents.push(extend({}, event, null, true));
|
|
7544
7557
|
const diffInDays = event.data.count;
|
|
7545
7558
|
if (startTime.getTime() <= endTime.getTime()) {
|
|
7546
7559
|
const appWidth = (diffInDays * this.cellWidth) - 5;
|
|
@@ -7549,7 +7562,7 @@ class MonthEvent extends EventBase {
|
|
|
7549
7562
|
const height = this.monthHeaderHeight + ((overlapCount + 1) * (this.eventHeight + EVENT_GAP)) + this.moreIndicatorHeight;
|
|
7550
7563
|
const enableAppRender = this.maxOrIndicator ? overlapCount < 1 ? true : false : this.cellHeight > height;
|
|
7551
7564
|
if (this.parent.rowAutoHeight || enableAppRender) {
|
|
7552
|
-
this.
|
|
7565
|
+
this.renderedEvents.push(extend({}, event, null, true));
|
|
7553
7566
|
let appointmentElement;
|
|
7554
7567
|
if (this.inlineValue) {
|
|
7555
7568
|
appointmentElement = this.parent.inlineModule.createInlineAppointmentElement();
|
|
@@ -7565,37 +7578,30 @@ class MonthEvent extends EventBase {
|
|
|
7565
7578
|
const firstChild = cellTd.parentElement.firstElementChild;
|
|
7566
7579
|
this.updateCellHeight(firstChild, height);
|
|
7567
7580
|
}
|
|
7568
|
-
else if (cellTd.querySelector('.' + MORE_INDICATOR_CLASS)) {
|
|
7569
|
-
this.renderMoreIndicators(diffInDays, day);
|
|
7570
|
-
}
|
|
7571
7581
|
}
|
|
7572
7582
|
else {
|
|
7573
|
-
|
|
7574
|
-
|
|
7575
|
-
|
|
7576
|
-
|
|
7577
|
-
|
|
7578
|
-
|
|
7579
|
-
|
|
7580
|
-
|
|
7581
|
-
|
|
7582
|
-
|
|
7583
|
-
|
|
7584
|
-
|
|
7585
|
-
|
|
7586
|
-
|
|
7587
|
-
|
|
7588
|
-
|
|
7589
|
-
|
|
7590
|
-
|
|
7591
|
-
|
|
7592
|
-
|
|
7593
|
-
|
|
7583
|
+
for (let i = 0; i < diffInDays; i++) {
|
|
7584
|
+
if (this.workCells[day + i]) {
|
|
7585
|
+
const indicator = this.workCells[day + i].querySelector('.' + MORE_INDICATOR_CLASS);
|
|
7586
|
+
if (indicator) {
|
|
7587
|
+
const count = parseInt(indicator.getAttribute('data-count'), 10) + 1;
|
|
7588
|
+
indicator.setAttribute('data-count', count.toString());
|
|
7589
|
+
indicator.innerHTML = this.getMoreIndicatorText(count);
|
|
7590
|
+
}
|
|
7591
|
+
else {
|
|
7592
|
+
const startDate = new Date(this.dateRender[day + i].getTime());
|
|
7593
|
+
const endDate = addDays(this.dateRender[day + i], 1);
|
|
7594
|
+
const groupIndex = this.workCells[day + i].getAttribute('data-group-index');
|
|
7595
|
+
const moreIndicatorElement = this.getMoreIndicatorElement(1, startDate, endDate);
|
|
7596
|
+
if (!isNullOrUndefined(groupIndex)) {
|
|
7597
|
+
moreIndicatorElement.setAttribute('data-group-index', groupIndex);
|
|
7598
|
+
}
|
|
7599
|
+
moreIndicatorElement.style.top = (this.cellHeight - this.monthHeaderHeight - this.moreIndicatorHeight) + 'px';
|
|
7600
|
+
moreIndicatorElement.style.width = this.cellWidth - 2 + 'px';
|
|
7601
|
+
this.renderElement(this.workCells[day + i], moreIndicatorElement);
|
|
7602
|
+
EventHandler.add(moreIndicatorElement, 'click', this.moreIndicatorClick, this);
|
|
7603
|
+
}
|
|
7594
7604
|
}
|
|
7595
|
-
moreIndicatorElement.style.top = (this.cellHeight - this.monthHeaderHeight - this.moreIndicatorHeight) + 'px';
|
|
7596
|
-
moreIndicatorElement.style.width = this.cellWidth - 2 + 'px';
|
|
7597
|
-
this.renderElement(this.workCells[day + i], moreIndicatorElement);
|
|
7598
|
-
EventHandler.add(moreIndicatorElement, 'click', this.moreIndicatorClick, this);
|
|
7599
7605
|
}
|
|
7600
7606
|
}
|
|
7601
7607
|
}
|
|
@@ -7630,8 +7636,8 @@ class MonthEvent extends EventBase {
|
|
|
7630
7636
|
}
|
|
7631
7637
|
getOverlapEvents(date, appointments) {
|
|
7632
7638
|
const appointmentsList = [];
|
|
7639
|
+
const dateTime = resetTime(date).getTime();
|
|
7633
7640
|
for (const app of appointments) {
|
|
7634
|
-
const dateTime = resetTime(date).getTime();
|
|
7635
7641
|
if ((resetTime(app[this.fields.startTime]).getTime() <= dateTime) &&
|
|
7636
7642
|
(resetTime(app[this.fields.endTime]).getTime() >= dateTime)) {
|
|
7637
7643
|
appointmentsList.push(app);
|
|
@@ -7715,6 +7721,7 @@ class MonthEvent extends EventBase {
|
|
|
7715
7721
|
innerHTML: this.getMoreIndicatorText(count),
|
|
7716
7722
|
attrs: {
|
|
7717
7723
|
'tabindex': '0',
|
|
7724
|
+
'data-count': count.toString(),
|
|
7718
7725
|
'data-start-date': startDate.getTime().toString(),
|
|
7719
7726
|
'data-end-date': endDate.getTime().toString(),
|
|
7720
7727
|
'role': 'list'
|
|
@@ -15750,7 +15757,7 @@ let Schedule = class Schedule extends Component {
|
|
|
15750
15757
|
};
|
|
15751
15758
|
this.trigger(navigating, navArgs, (navigationArgs) => {
|
|
15752
15759
|
if (!navigationArgs.cancel) {
|
|
15753
|
-
this.uiStateValues.isInitial =
|
|
15760
|
+
this.uiStateValues.isInitial = view.indexOf('Timeline') > -1 || this.currentView.indexOf('Timeline') > -1 ? true : this.uiStateValues.isInitial;
|
|
15754
15761
|
this.viewIndex = navigationArgs.viewIndex;
|
|
15755
15762
|
this.setProperties({ currentView: view }, true);
|
|
15756
15763
|
if (this.headerModule) {
|
|
@@ -24985,7 +24992,7 @@ class ICalendarExport {
|
|
|
24985
24992
|
const editedExDate = [];
|
|
24986
24993
|
if (eventObj[fields.recurrenceID]) {
|
|
24987
24994
|
const filter = this.filterEvents(filterCollection, fields.id, eventObj[fields.recurrenceID]);
|
|
24988
|
-
uId = filter[0].UID;
|
|
24995
|
+
uId = filter.length > 0 ? filter[0].UID : uId;
|
|
24989
24996
|
}
|
|
24990
24997
|
if (!eventObj[fields.recurrenceID] && eventObj[fields.recurrenceRule] && eventObj[fields.recurrenceException]) {
|
|
24991
24998
|
const exDate = (eventObj[fields.recurrenceException]).split(',');
|