@syncfusion/ej2-schedule 26.1.35 → 26.1.39

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.
Files changed (72) hide show
  1. package/dist/ej2-schedule.min.js +2 -2
  2. package/dist/ej2-schedule.umd.min.js +2 -2
  3. package/dist/ej2-schedule.umd.min.js.map +1 -1
  4. package/dist/es6/ej2-schedule.es2015.js +110 -47
  5. package/dist/es6/ej2-schedule.es2015.js.map +1 -1
  6. package/dist/es6/ej2-schedule.es5.js +109 -46
  7. package/dist/es6/ej2-schedule.es5.js.map +1 -1
  8. package/dist/global/ej2-schedule.min.js +2 -2
  9. package/dist/global/ej2-schedule.min.js.map +1 -1
  10. package/dist/global/index.d.ts +1 -1
  11. package/package.json +11 -11
  12. package/src/schedule/actions/crud.js +3 -1
  13. package/src/schedule/actions/resize.js +5 -0
  14. package/src/schedule/base/schedule.js +6 -3
  15. package/src/schedule/event-renderer/agenda-base.js +2 -2
  16. package/src/schedule/event-renderer/event-base.js +4 -2
  17. package/src/schedule/event-renderer/month.js +2 -1
  18. package/src/schedule/event-renderer/timeline-view.js +6 -1
  19. package/src/schedule/event-renderer/vertical-view.js +4 -4
  20. package/src/schedule/event-renderer/year.js +1 -1
  21. package/src/schedule/exports/excel-export.js +1 -1
  22. package/src/schedule/exports/print.js +10 -7
  23. package/src/schedule/popups/quick-popups.js +1 -1
  24. package/src/schedule/renderer/header-renderer.js +1 -1
  25. package/src/schedule/renderer/month.js +5 -4
  26. package/src/schedule/renderer/renderer.js +8 -2
  27. package/src/schedule/renderer/timeline-year.js +3 -3
  28. package/src/schedule/renderer/vertical-view.d.ts +1 -0
  29. package/src/schedule/renderer/vertical-view.js +21 -9
  30. package/src/schedule/renderer/view-base.d.ts +1 -0
  31. package/src/schedule/renderer/view-base.js +25 -2
  32. package/src/schedule/renderer/year.js +1 -1
  33. package/styles/bootstrap-dark.css +10 -0
  34. package/styles/bootstrap.css +10 -0
  35. package/styles/bootstrap4.css +10 -0
  36. package/styles/bootstrap5-dark.css +10 -0
  37. package/styles/bootstrap5.css +10 -0
  38. package/styles/fabric-dark.css +10 -0
  39. package/styles/fabric.css +10 -0
  40. package/styles/fluent-dark.css +10 -0
  41. package/styles/fluent.css +10 -0
  42. package/styles/fluent2.css +79 -54
  43. package/styles/highcontrast-light.css +10 -0
  44. package/styles/highcontrast.css +10 -0
  45. package/styles/material-dark.css +10 -0
  46. package/styles/material.css +10 -0
  47. package/styles/material3-dark.css +10 -0
  48. package/styles/material3.css +10 -0
  49. package/styles/recurrence-editor/fluent2.css +35 -35
  50. package/styles/schedule/_fluent2-definition.scss +3 -3
  51. package/styles/schedule/_layout.scss +12 -0
  52. package/styles/schedule/_theme.scss +4 -0
  53. package/styles/schedule/bootstrap-dark.css +10 -0
  54. package/styles/schedule/bootstrap.css +10 -0
  55. package/styles/schedule/bootstrap4.css +10 -0
  56. package/styles/schedule/bootstrap5-dark.css +10 -0
  57. package/styles/schedule/bootstrap5.css +10 -0
  58. package/styles/schedule/fabric-dark.css +10 -0
  59. package/styles/schedule/fabric.css +10 -0
  60. package/styles/schedule/fluent-dark.css +10 -0
  61. package/styles/schedule/fluent.css +10 -0
  62. package/styles/schedule/fluent2.css +79 -54
  63. package/styles/schedule/highcontrast-light.css +10 -0
  64. package/styles/schedule/highcontrast.css +10 -0
  65. package/styles/schedule/material-dark.css +10 -0
  66. package/styles/schedule/material.css +10 -0
  67. package/styles/schedule/material3-dark.css +10 -0
  68. package/styles/schedule/material3.css +10 -0
  69. package/styles/schedule/tailwind-dark.css +10 -0
  70. package/styles/schedule/tailwind.css +10 -0
  71. package/styles/tailwind-dark.css +10 -0
  72. package/styles/tailwind.css +10 -0
@@ -1188,7 +1188,7 @@ var HeaderRenderer = /** @__PURE__ @class */ (function () {
1188
1188
  };
1189
1189
  var viewName = this.parent.activeViewOptions.dateRangeTemplateName;
1190
1190
  var templateId = this.parent.element.id + '_' + viewName + 'dateRangeTemplate';
1191
- var dateTemplate = [].slice.call(this.parent.getDateRangeTemplate()(args, this.parent, 'dateRangeTemplate', templateId, false));
1191
+ var dateTemplate = [].slice.call(this.parent.getDateRangeTemplate()(args, this.parent, 'dateRangeTemplate', templateId, false, undefined, undefined, this.parent.root));
1192
1192
  append(dateTemplate, textEle);
1193
1193
  }
1194
1194
  else {
@@ -6617,7 +6617,7 @@ var EventBase = /** @__PURE__ @class */ (function () {
6617
6617
  var templateId = scheduleId + viewName + 'eventTemplate';
6618
6618
  var templateName = isResourceEventTemplate && this.parent.currentView.indexOf('Year') === -1 ?
6619
6619
  this.parent.getEventTemplateName(resIndex) : 'eventTemplate';
6620
- templateElement = this.parent.getAppointmentTemplate()(record, this.parent, templateName, templateId, false);
6620
+ templateElement = this.parent.getAppointmentTemplate()(record, this.parent, templateName, templateId, false, undefined, undefined, this.parent.root);
6621
6621
  }
6622
6622
  else {
6623
6623
  var appointmentSubject = createElement('div', { className: SUBJECT_CLASS });
@@ -6756,7 +6756,9 @@ var EventBase = /** @__PURE__ @class */ (function () {
6756
6756
  }
6757
6757
  };
6758
6758
  EventBase.prototype.updateEventMinimumDuration = function (startEndHours, startTime, endTime) {
6759
- if (startTime.getTime() < endTime.getTime()) {
6759
+ if (startTime.getTime() < endTime.getTime() || (startTime.getTime() === endTime.getTime() &&
6760
+ (startEndHours.startHour.getTime() < endTime.getTime() && startEndHours.endHour.getTime() > startTime.getTime()) &&
6761
+ this.parent.currentView.indexOf('Timeline') === -1)) {
6760
6762
  var eventDuration = (getUniversalTime(endTime) - getUniversalTime(startTime)) / MS_PER_MINUTE;
6761
6763
  if (eventDuration < this.parent.eventSettings.minimumEventDuration) {
6762
6764
  var tempEnd = new Date(startTime);
@@ -7221,7 +7223,7 @@ var VerticalEvent = /** @__PURE__ @class */ (function (_super) {
7221
7223
  var templateId = elementId + viewName + 'eventTemplate';
7222
7224
  var resIndex = this.parent.uiStateValues.isGroupAdaptive ? this.parent.uiStateValues.groupIndex : resource;
7223
7225
  var templateName = this.isResourceEventTemplate ? this.parent.getEventTemplateName(resIndex) : 'eventTemplate';
7224
- templateElement = this.parent.getAppointmentTemplate()(record, this.parent, templateName, templateId, false);
7226
+ templateElement = this.parent.getAppointmentTemplate()(record, this.parent, templateName, templateId, false, undefined, undefined, this.parent.root);
7225
7227
  }
7226
7228
  else {
7227
7229
  var appointmentSubject = createElement('div', { className: SUBJECT_CLASS });
@@ -7436,7 +7438,7 @@ var VerticalEvent = /** @__PURE__ @class */ (function (_super) {
7436
7438
  }
7437
7439
  if (eStart <= eEnd && isValidEvent && this.isWorkDayAvailable(resource, eStart)) {
7438
7440
  var appHeight = this.getHeight(eStart, eEnd);
7439
- if (eStart.getTime() > schedule.startHour.getTime()) {
7441
+ if (eStart.getTime() >= schedule.startHour.getTime()) {
7440
7442
  topValue = this.getTopValue(eStart, dayIndex, resource);
7441
7443
  }
7442
7444
  var appIndex = this.getOverlapIndex(record, dayIndex, false, resource);
@@ -7703,12 +7705,12 @@ var VerticalEvent = /** @__PURE__ @class */ (function (_super) {
7703
7705
  var rowHeight;
7704
7706
  if (this.parent.uiStateValues.expand) {
7705
7707
  target.setAttribute('title', this.parent.localeObj.getConstant('collapseAllDaySection'));
7706
- target.setAttribute('aria-label', 'Collapse section');
7708
+ target.setAttribute('aria-label', this.parent.localeObj.getConstant('collapseAllDaySection'));
7707
7709
  rowHeight = ((this.allDayLevel + 1) * this.getEventHeight()) + 4;
7708
7710
  }
7709
7711
  else {
7710
7712
  target.setAttribute('title', this.parent.localeObj.getConstant('expandAllDaySection'));
7711
- target.setAttribute('aria-label', 'Expand section');
7713
+ target.setAttribute('aria-label', this.parent.localeObj.getConstant('expandAllDaySection'));
7712
7714
  rowHeight = (3 * this.getEventHeight()) + 4;
7713
7715
  this.parent.element.querySelector('.' + DATE_HEADER_WRAP_CLASS).scrollTop = 0;
7714
7716
  }
@@ -8141,7 +8143,7 @@ var MonthEvent = /** @__PURE__ @class */ (function (_super) {
8141
8143
  var viewName = this.parent.activeViewOptions.eventTemplateName;
8142
8144
  var templateId = scheduleId + viewName + 'eventTemplate';
8143
8145
  var eventTemplate = this.isResourceEventTemplate ? this.parent.getEventTemplateName(resIndex) : 'eventTemplate';
8144
- templateElement = this.parent.getAppointmentTemplate()(eventObj, this.parent, eventTemplate, templateId, false);
8146
+ templateElement = this.parent.getAppointmentTemplate()(eventObj, this.parent, eventTemplate, templateId, false, undefined, undefined, this.parent.root);
8145
8147
  }
8146
8148
  else {
8147
8149
  var eventLocation = (record[this.fields.location] || this.parent.eventSettings.fields.location.default || '');
@@ -8270,6 +8272,7 @@ var MonthEvent = /** @__PURE__ @class */ (function (_super) {
8270
8272
  if (indicator) {
8271
8273
  var count = parseInt(indicator.getAttribute('data-count'), 10) + 1;
8272
8274
  indicator.setAttribute('data-count', count.toString());
8275
+ indicator.setAttribute('aria-label', count + ' ' + this.parent.localeObj.getConstant('moreEvents'));
8273
8276
  indicator.innerHTML = this.getMoreIndicatorText(count);
8274
8277
  }
8275
8278
  else {
@@ -8905,8 +8908,13 @@ var TimelineEvent = /** @__PURE__ @class */ (function (_super) {
8905
8908
  }
8906
8909
  };
8907
8910
  TimelineEvent.prototype.getSameDayEventsWidth = function (startDate, endDate) {
8911
+ var intervalMins = this.interval;
8912
+ if (this.slotsPerDay === 1) {
8913
+ var hoursRange = getStartEndHours(resetTime(new Date(startDate.getTime())), this.startHour, this.endHour);
8914
+ intervalMins = (hoursRange.endHour.getTime() - hoursRange.startHour.getTime()) / MS_PER_MINUTE;
8915
+ }
8908
8916
  return ((getUniversalTime(endDate) - getUniversalTime(startDate)) /
8909
- MS_PER_MINUTE * (this.cellWidth * this.slotCount) / this.interval);
8917
+ MS_PER_MINUTE * (this.cellWidth * this.slotCount) / intervalMins);
8910
8918
  };
8911
8919
  TimelineEvent.prototype.getSpannedEventsWidth = function (startDate, endDate, diffInDays) {
8912
8920
  var width = (diffInDays * this.slotsPerDay) * this.cellWidth;
@@ -9708,7 +9716,7 @@ var QuickPopups = /** @__PURE__ @class */ (function () {
9708
9716
  var templateElement = void 0;
9709
9717
  if (!isNullOrUndefined(this_1.parent.activeViewOptions.eventTemplate)) {
9710
9718
  var tempId = this_1.parent.element.id + '_' + this_1.parent.activeViewOptions.eventTemplateName + 'eventTemplate';
9711
- templateElement = this_1.parent.getAppointmentTemplate()(eventData, this_1.parent, 'eventTemplate', tempId, false);
9719
+ templateElement = this_1.parent.getAppointmentTemplate()(eventData, this_1.parent, 'eventTemplate', tempId, false, undefined, undefined, this_1.parent.root);
9712
9720
  append(templateElement, appointmentElement);
9713
9721
  }
9714
9722
  else {
@@ -14694,9 +14702,15 @@ var Render = /** @__PURE__ @class */ (function () {
14694
14702
  }
14695
14703
  };
14696
14704
  Render.prototype.updateLabelText = function (view) {
14697
- var content = this.parent.activeView.getLabelText(view);
14698
14705
  this.parent.element.setAttribute('role', 'application');
14699
- this.parent.element.setAttribute('aria-label', content);
14706
+ this.parent.element.removeAttribute('aria-labelledby');
14707
+ this.parent.element.removeAttribute('aria-label');
14708
+ if (view === 'Year') {
14709
+ this.parent.element.setAttribute('aria-label', this.parent.activeView.getLabelText(view));
14710
+ }
14711
+ else {
14712
+ this.parent.element.setAttribute('aria-labelledby', this.parent.element.id + '_table');
14713
+ }
14700
14714
  };
14701
14715
  return Render;
14702
14716
  }());
@@ -14919,7 +14933,9 @@ var Crud = /** @__PURE__ @class */ (function () {
14919
14933
  _this.parent.trigger(dataBound, null, function () {
14920
14934
  _this.parent.hideSpinner();
14921
14935
  if (_this.parent.isPrinting) {
14922
- _this.parent.notify(print, {});
14936
+ setTimeout(function () {
14937
+ _this.parent.notify(print, {});
14938
+ }, 100);
14923
14939
  }
14924
14940
  });
14925
14941
  });
@@ -18021,6 +18037,7 @@ var Schedule = /** @__PURE__ @class */ (function (_super) {
18021
18037
  subject: 'Subject',
18022
18038
  addTitle: 'Add title',
18023
18039
  moreDetails: 'More Details',
18040
+ moreEvents: 'More Events',
18024
18041
  save: 'Save',
18025
18042
  editContent: 'How would you like to change the appointment in the series?',
18026
18043
  deleteContent: 'Are you sure you want to delete this event?',
@@ -18055,6 +18072,7 @@ var Schedule = /** @__PURE__ @class */ (function (_super) {
18055
18072
  ok: 'Ok',
18056
18073
  yes: 'Yes',
18057
18074
  no: 'No',
18075
+ of: 'of',
18058
18076
  occurrence: 'Occurrence',
18059
18077
  series: 'Series',
18060
18078
  previous: 'Previous',
@@ -18626,7 +18644,7 @@ var Schedule = /** @__PURE__ @class */ (function (_super) {
18626
18644
  var scheduleId = this.element.id + '_';
18627
18645
  var viewName = this.activeViewOptions.headerIndentTemplateName;
18628
18646
  var templateId = scheduleId + viewName + 'headerIndentTemplate';
18629
- var indentTemplate = [].slice.call(this.getHeaderIndentTemplate()(data, this, 'headerIndentTemplate', templateId, false));
18647
+ var indentTemplate = [].slice.call(this.getHeaderIndentTemplate()(data, this, 'headerIndentTemplate', templateId, false, undefined, undefined, this.root));
18630
18648
  append(indentTemplate, td);
18631
18649
  }
18632
18650
  };
@@ -19158,8 +19176,9 @@ var Schedule = /** @__PURE__ @class */ (function (_super) {
19158
19176
  }
19159
19177
  var msMajorInterval = this.activeViewOptions.timeScale.interval * MS_PER_MINUTE;
19160
19178
  var msInterval = msMajorInterval / this.activeViewOptions.timeScale.slotCount;
19161
- var startIndex = Math.round((startHour.getTime() - viewStartHour.getTime()) / msInterval);
19162
- var endIndex = Math.ceil((endHour.getTime() - viewStartHour.getTime()) / msInterval);
19179
+ var offsetDiff = ((viewStartHour.getTimezoneOffset() - startHour.getTimezoneOffset()) * MS_PER_MINUTE);
19180
+ var startIndex = Math.round((startHour.getTime() - viewStartHour.getTime() + offsetDiff) / msInterval);
19181
+ var endIndex = Math.ceil((endHour.getTime() - viewStartHour.getTime() + offsetDiff) / msInterval);
19163
19182
  var tempStartIndex = startIndex;
19164
19183
  var tempEndIndex = endIndex;
19165
19184
  var cells = [];
@@ -20903,6 +20922,11 @@ var Resize = /** @__PURE__ @class */ (function (_super) {
20903
20922
  }
20904
20923
  var viewElement = _this.parent.element.querySelector('.' + CONTENT_WRAP_CLASS);
20905
20924
  _this.scrollArgs = { element: viewElement, width: viewElement.scrollWidth, height: viewElement.scrollHeight };
20925
+ // 883565 - To fix the resizing not working issue at the last column of the timeline view
20926
+ if (['Month', 'TimelineYear'].indexOf(_this.parent.currentView) < 0) {
20927
+ var scrollWidth = Math.round(_this.scrollArgs.width / _this.actionObj.cellWidth) * _this.actionObj.cellWidth;
20928
+ _this.scrollArgs.width = _this.scrollArgs.width < scrollWidth ? scrollWidth : _this.scrollArgs.width;
20929
+ }
20906
20930
  EventHandler.add(document, Browser.touchMoveEvent, _this.resizing, _this);
20907
20931
  EventHandler.add(document, Browser.touchEndEvent, _this.resizeStop, _this);
20908
20932
  });
@@ -21878,7 +21902,7 @@ var YearEvent = /** @__PURE__ @class */ (function (_super) {
21878
21902
  var eventObj = extend({}, record, null, true);
21879
21903
  if (this.parent.activeViewOptions.eventTemplate) {
21880
21904
  var templateId = this.parent.element.id + '_' + this.parent.activeViewOptions.eventTemplateName + 'eventTemplate';
21881
- templateElement = this.parent.getAppointmentTemplate()(eventObj, this.parent, 'eventTemplate', templateId, false);
21905
+ templateElement = this.parent.getAppointmentTemplate()(eventObj, this.parent, 'eventTemplate', templateId, false, undefined, undefined, this.parent.root);
21882
21906
  }
21883
21907
  else {
21884
21908
  var locationEle = (record[this.fields.location] || this.parent.eventSettings.fields.location.default || '');
@@ -23469,6 +23493,9 @@ var ViewBase = /** @__PURE__ @class */ (function () {
23469
23493
  };
23470
23494
  ViewBase.prototype.setAriaAttributes = function (table) {
23471
23495
  table.setAttribute('role', 'grid');
23496
+ if (this.parent.currentView !== 'Year') {
23497
+ table.setAttribute('id', this.parent.element.id + '_table');
23498
+ }
23472
23499
  table.setAttribute('aria-label', this.getLabelText(this.parent.currentView));
23473
23500
  };
23474
23501
  ViewBase.prototype.createColGroup = function (table, lastRow) {
@@ -23716,9 +23743,29 @@ var ViewBase = /** @__PURE__ @class */ (function () {
23716
23743
  var weekLength = type === 'next' ? WEEK_LENGTH : -WEEK_LENGTH;
23717
23744
  return addDays(this.parent.selectedDate, weekLength * this.parent.activeViewOptions.interval);
23718
23745
  };
23746
+ ViewBase.prototype.formatViewLabel = function (view, startDate, endDate) {
23747
+ var formatOptions = { type: 'date', skeleton: 'full', calendar: this.parent.getCalendarMode() };
23748
+ return this.parent.localeObj.getConstant(view) + ' ' + this.parent.localeObj.getConstant('start') + ' ' + this.parent.globalize.formatDate(startDate, formatOptions) + ' '
23749
+ + this.parent.localeObj.getConstant('endAt') + ' ' + this.parent.globalize.formatDate(endDate, formatOptions);
23750
+ };
23719
23751
  ViewBase.prototype.getLabelText = function (view) {
23720
23752
  var viewStr = view.charAt(0).toLowerCase() + view.substring(1);
23721
- return this.parent.localeObj.getConstant(viewStr) + ' of ' + capitalizeFirstWord(this.parent.globalize.formatDate(this.parent.selectedDate, { skeleton: 'long', calendar: this.parent.getCalendarMode() }), 'single');
23753
+ if (view === 'Year' || view === 'TimelineYear') {
23754
+ return this.formatViewLabel(viewStr, this.parent.activeView.getStartDate(), this.parent.activeView.getEndDate());
23755
+ }
23756
+ else {
23757
+ if (this.renderDates.length > 0) {
23758
+ if (this.parent.currentView === 'Day' || this.parent.currentView === 'TimelineDay') {
23759
+ return this.parent.localeObj.getConstant(viewStr) + ' of ' + capitalizeFirstWord(this.parent.globalize.formatDate(this.parent.selectedDate, { type: 'date', skeleton: 'full', calendar: this.parent.getCalendarMode() }), 'single');
23760
+ }
23761
+ else {
23762
+ return this.formatViewLabel(viewStr, this.renderDates[0], this.renderDates[this.renderDates.length - 1]);
23763
+ }
23764
+ }
23765
+ else {
23766
+ return '';
23767
+ }
23768
+ }
23722
23769
  };
23723
23770
  ViewBase.prototype.getDateRangeText = function () {
23724
23771
  if (this.parent.isAdaptive) {
@@ -23809,7 +23856,7 @@ var ViewBase = /** @__PURE__ @class */ (function () {
23809
23856
  var scheduleId = this.parent.element.id + '_';
23810
23857
  var viewName = this.parent.activeViewOptions.resourceHeaderTemplateName;
23811
23858
  var templateId = scheduleId + viewName + 'resourceHeaderTemplate';
23812
- var quickTemplate = [].slice.call(this.parent.getResourceHeaderTemplate()(data, this.parent, 'resourceHeaderTemplate', templateId, false));
23859
+ var quickTemplate = [].slice.call(this.parent.getResourceHeaderTemplate()(data, this.parent, 'resourceHeaderTemplate', templateId, false, undefined, undefined, this.parent.root));
23813
23860
  append(quickTemplate, tdElement);
23814
23861
  }
23815
23862
  else {
@@ -24362,7 +24409,7 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24362
24409
  templateName = 'dateHeaderTemplate';
24363
24410
  var args = { date: date, type: type };
24364
24411
  var viewName = this.parent.activeViewOptions.dateHeaderTemplateName;
24365
- cntEle = [].slice.call(this.parent.getDateHeaderTemplate()(args, this.parent, templateName, templateId + viewName + templateName, false));
24412
+ cntEle = [].slice.call(this.parent.getDateHeaderTemplate()(args, this.parent, templateName, templateId + viewName + templateName, false, undefined, undefined, this.parent.root));
24366
24413
  }
24367
24414
  else {
24368
24415
  wrapper.innerHTML = this.parent.activeView.isTimelineView() ?
@@ -24376,7 +24423,7 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24376
24423
  if (this.parent.activeViewOptions.timeScale.majorSlotTemplate) {
24377
24424
  templateName = 'majorSlotTemplate';
24378
24425
  var args = { date: date, type: type };
24379
- cntEle = [].slice.call(this.parent.getMajorSlotTemplate()(args, this.parent, templateName, templateId + templateName, false));
24426
+ cntEle = [].slice.call(this.parent.getMajorSlotTemplate()(args, this.parent, templateName, templateId + templateName, false, undefined, undefined, this.parent.root));
24380
24427
  }
24381
24428
  else {
24382
24429
  wrapper.innerHTML = "<span>" + this.getTime(date) + "</span>";
@@ -24387,7 +24434,7 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24387
24434
  if (this.parent.activeViewOptions.timeScale.minorSlotTemplate) {
24388
24435
  templateName = 'minorSlotTemplate';
24389
24436
  var args = { date: date, type: type };
24390
- cntEle = [].slice.call(this.parent.getMinorSlotTemplate()(args, this.parent, templateName, templateId + templateName, false));
24437
+ cntEle = [].slice.call(this.parent.getMinorSlotTemplate()(args, this.parent, templateName, templateId + templateName, false, undefined, undefined, this.parent.root));
24391
24438
  }
24392
24439
  else {
24393
24440
  cntEle = [].slice.call(wrapper.childNodes);
@@ -24398,7 +24445,7 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24398
24445
  var viewName = this.parent.activeViewOptions.cellTemplateName;
24399
24446
  templateName = 'cellTemplate';
24400
24447
  var args = { date: date, type: type, groupIndex: groupIndex };
24401
- cntEle = [].slice.call(this.parent.getCellTemplate()(args, this.parent, templateName, templateId + viewName + templateName, false));
24448
+ cntEle = [].slice.call(this.parent.getCellTemplate()(args, this.parent, templateName, templateId + viewName + templateName, false, undefined, undefined, this.parent.root));
24402
24449
  }
24403
24450
  break;
24404
24451
  }
@@ -24517,7 +24564,8 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24517
24564
  var appointmentExpandCollapse = createElement('div', {
24518
24565
  attrs: {
24519
24566
  'tabindex': '0', 'role': 'list',
24520
- title: this.parent.localeObj.getConstant('expandAllDaySection'), 'aria-disabled': 'false', 'aria-label': 'Expand section'
24567
+ title: this.parent.localeObj.getConstant('expandAllDaySection'), 'aria-disabled': 'false',
24568
+ 'aria-label': this.parent.localeObj.getConstant('expandAllDaySection')
24521
24569
  },
24522
24570
  className: ALLDAY_APPOINTMENT_SECTION_CLASS + ' ' + APPOINTMENT_ROW_EXPAND_CLASS + ' ' +
24523
24571
  ICON + ' ' + DISABLE_CLASS
@@ -24674,7 +24722,7 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24674
24722
  if (!this.parent.isMinMaxDate(cellDate)) {
24675
24723
  clsName.push(DISABLE_DATES);
24676
24724
  }
24677
- setTime(cellDate, getDateInMs(r.date));
24725
+ cellDate = new Date(cellDate.setHours(r.date.getHours(), r.date.getMinutes(), r.date.getSeconds(), r.date.getMilliseconds()));
24678
24726
  var type = 'workCells';
24679
24727
  if (tdData.className.indexOf(RESOURCE_PARENT_CLASS) !== -1) {
24680
24728
  clsName.push(RESOURCE_GROUP_CELLS_CLASS);
@@ -24691,7 +24739,7 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24691
24739
  var scheduleId = this.parent.element.id + '_';
24692
24740
  var viewName = this.parent.activeViewOptions.cellTemplateName;
24693
24741
  var templateId = scheduleId + viewName + 'cellTemplate';
24694
- var tooltipTemplate = [].slice.call(this.parent.getCellTemplate()(args_1, this.parent, 'cellTemplate', templateId, false));
24742
+ var tooltipTemplate = [].slice.call(this.parent.getCellTemplate()(args_1, this.parent, 'cellTemplate', templateId, false, undefined, undefined, this.parent.root));
24695
24743
  append(tooltipTemplate, ntd);
24696
24744
  }
24697
24745
  ntd.setAttribute('data-date', cellDate.getTime().toString());
@@ -24747,10 +24795,21 @@ var VerticalView = /** @__PURE__ @class */ (function (_super) {
24747
24795
  end.setMilliseconds(end.getMilliseconds() + msInterval);
24748
24796
  return end;
24749
24797
  };
24798
+ VerticalView.prototype.getStartEndHours = function (startEndTime) {
24799
+ if (!isNullOrUndefined(startEndTime) && startEndTime !== '') {
24800
+ var startEndDate = new Date(2000, 0, 0, 0);
24801
+ var timeString = startEndTime.split(':');
24802
+ if (timeString.length === 2) {
24803
+ startEndDate.setHours(parseInt(timeString[0], 10), parseInt(timeString[1], 10), 0);
24804
+ }
24805
+ return startEndDate;
24806
+ }
24807
+ return new Date(2000, 0, 0, 0);
24808
+ };
24750
24809
  VerticalView.prototype.getTimeSlotRows = function (handler) {
24751
24810
  var rows = [];
24752
- var startHour = this.getStartHour();
24753
- var endHour = this.getEndHour();
24811
+ var startHour = this.getStartEndHours(this.parent.activeViewOptions.startHour);
24812
+ var endHour = this.getStartEndHours(this.parent.activeViewOptions.endHour);
24754
24813
  var msMajorInterval = this.parent.activeViewOptions.timeScale.interval * MS_PER_MINUTE;
24755
24814
  var msInterval = msMajorInterval / this.parent.activeViewOptions.timeScale.slotCount;
24756
24815
  var length = Math.round(MS_PER_DAY / msInterval);
@@ -25304,7 +25363,7 @@ var Month = /** @__PURE__ @class */ (function (_super) {
25304
25363
  var elementId = this.parent.element.id + '_';
25305
25364
  var viewName = this.parent.activeViewOptions.dateHeaderTemplateName;
25306
25365
  var templateId = elementId + viewName + 'dateHeaderTemplate';
25307
- var dateTemplate = [].slice.call(this.parent.getDateHeaderTemplate()(cellArgs, this.parent, 'dateHeaderTemplate', templateId, false));
25366
+ var dateTemplate = [].slice.call(this.parent.getDateHeaderTemplate()(cellArgs, this.parent, 'dateHeaderTemplate', templateId, false, undefined, undefined, this.parent.root));
25308
25367
  if (dateTemplate && dateTemplate.length) {
25309
25368
  append(dateTemplate, tdEle);
25310
25369
  }
@@ -25480,7 +25539,7 @@ var Month = /** @__PURE__ @class */ (function (_super) {
25480
25539
  var scheduleId = this.parent.element.id + '_';
25481
25540
  var viewName = this.parent.activeViewOptions.cellTemplateName;
25482
25541
  var templateId = scheduleId + viewName + 'cellTemplate';
25483
- var cellTemplate = [].slice.call(this.parent.getCellTemplate()(args_1, this.parent, 'cellTemplate', templateId, false));
25542
+ var cellTemplate = [].slice.call(this.parent.getCellTemplate()(args_1, this.parent, 'cellTemplate', templateId, false, undefined, undefined, this.parent.root));
25484
25543
  append(cellTemplate, ntd);
25485
25544
  }
25486
25545
  var args = { elementType: type, element: ntd, date: data.date, groupIndex: data.groupIndex };
@@ -25497,7 +25556,7 @@ var Month = /** @__PURE__ @class */ (function (_super) {
25497
25556
  var scheduleId = this.parent.element.id + '_';
25498
25557
  var viewName = this.parent.activeViewOptions.cellHeaderTemplateName;
25499
25558
  var templateId = scheduleId + viewName + 'cellHeaderTemplate';
25500
- var cellHeaderTemplate = [].slice.call(this.parent.getCellHeaderTemplate()(args, this.parent, 'cellHeaderTemplate', templateId, false));
25559
+ var cellHeaderTemplate = [].slice.call(this.parent.getCellHeaderTemplate()(args, this.parent, 'cellHeaderTemplate', templateId, false, undefined, undefined, this.parent.root));
25501
25560
  append(cellHeaderTemplate, dateHeader);
25502
25561
  }
25503
25562
  else {
@@ -25627,7 +25686,8 @@ var Month = /** @__PURE__ @class */ (function (_super) {
25627
25686
  return this.formatDateRange(this.parent.selectedDate);
25628
25687
  };
25629
25688
  Month.prototype.getLabelText = function (view) {
25630
- return this.parent.localeObj.getConstant(view) + ' of ' + capitalizeFirstWord(this.parent.globalize.formatDate(this.parent.selectedDate, { format: 'MMMM y', calendar: this.parent.getCalendarMode() }), 'single');
25689
+ var viewStr = view.charAt(0).toLowerCase() + view.substring(1);
25690
+ return this.formatViewLabel(viewStr, this.getStartDate(), this.getEndDate());
25631
25691
  };
25632
25692
  Month.prototype.createWeekNumberElement = function (text) {
25633
25693
  var tr = createElement('tr');
@@ -25951,7 +26011,7 @@ var Year = /** @__PURE__ @class */ (function (_super) {
25951
26011
  };
25952
26012
  Year.prototype.renderTemplates = function (fn, args, tName, vName, ele) {
25953
26013
  var templateId = this.parent.element.id + '_' + vName + tName;
25954
- var template = [].slice.call(fn(args, this.parent, tName, templateId, false));
26014
+ var template = [].slice.call(fn(args, this.parent, tName, templateId, false, undefined, undefined, this.parent.root));
25955
26015
  append(template, ele);
25956
26016
  };
25957
26017
  Year.prototype.onCellClick = function (e) {
@@ -26183,7 +26243,7 @@ var AgendaBase = /** @__PURE__ @class */ (function (_super) {
26183
26243
  var scheduleId = _this.parent.element.id + '_';
26184
26244
  var viewName = _this.parent.activeViewOptions.eventTemplateName;
26185
26245
  var templateId = scheduleId + viewName + 'eventTemplate';
26186
- templateEle = _this.parent.getAppointmentTemplate()(listData[parseInt(li.toString(), 10)], _this.parent, 'eventTemplate', templateId, false);
26246
+ templateEle = _this.parent.getAppointmentTemplate()(listData[parseInt(li.toString(), 10)], _this.parent, 'eventTemplate', templateId, false, undefined, undefined, _this.parent.root);
26187
26247
  if (!isNullOrUndefined(listData[parseInt(li.toString(), 10)][fieldMapping.recurrenceRule])) {
26188
26248
  var iconClass = (listData[parseInt(li.toString(), 10)][fieldMapping.id] ===
26189
26249
  listData[parseInt(li.toString(), 10)][fieldMapping.recurrenceID]) ?
@@ -26487,7 +26547,7 @@ var AgendaBase = /** @__PURE__ @class */ (function (_super) {
26487
26547
  var scheduleId = this.parent.element.id + '_';
26488
26548
  var viewName = this.parent.activeViewOptions.dateHeaderTemplateName;
26489
26549
  var templateId = scheduleId + viewName + 'dateHeaderTemplate';
26490
- var dateTemplate = [].slice.call(this.parent.getDateHeaderTemplate()(args, this.parent, 'dateHeaderTemplate', templateId, false));
26550
+ var dateTemplate = [].slice.call(this.parent.getDateHeaderTemplate()(args, this.parent, 'dateHeaderTemplate', templateId, false, undefined, undefined, this.parent.root));
26491
26551
  append(dateTemplate, dateHeader);
26492
26552
  }
26493
26553
  else {
@@ -28189,10 +28249,10 @@ var TimelineYear = /** @__PURE__ @class */ (function (_super) {
28189
28249
  var monthId = "schedule_" + this.parent.activeViewOptions.dayHeaderTemplateName + "monthHeaderTemplate";
28190
28250
  if (type === 'dayHeaderTemplate') {
28191
28251
  args.day = this.parent.getDayNames('wide')[column % 7];
28192
- return [].slice.call(this.parent.getDayHeaderTemplate()(args, this.parent, 'dayHeaderTemplate', dayId, false));
28252
+ return [].slice.call(this.parent.getDayHeaderTemplate()(args, this.parent, 'dayHeaderTemplate', dayId, false, undefined, undefined, this.parent.root));
28193
28253
  }
28194
28254
  else {
28195
- return [].slice.call(this.parent.getMonthHeaderTemplate()(args, this.parent, 'monthHeaderTemplate', monthId, false));
28255
+ return [].slice.call(this.parent.getMonthHeaderTemplate()(args, this.parent, 'monthHeaderTemplate', monthId, false, undefined, undefined, this.parent.root));
28196
28256
  }
28197
28257
  };
28198
28258
  TimelineYear.prototype.renderCellTemplate = function (data, td) {
@@ -28206,7 +28266,7 @@ var TimelineYear = /** @__PURE__ @class */ (function (_super) {
28206
28266
  var scheduleId = this.parent.element.id + '_';
28207
28267
  var viewName = this.parent.activeViewOptions.cellTemplateName;
28208
28268
  var templateId = scheduleId + viewName + 'cellTemplate';
28209
- var cellTemplate = [].slice.call(this.parent.getCellTemplate()(args, this.parent, 'cellTemplate', templateId, false));
28269
+ var cellTemplate = [].slice.call(this.parent.getCellTemplate()(args, this.parent, 'cellTemplate', templateId, false, undefined, undefined, this.parent.root));
28210
28270
  append(cellTemplate, td);
28211
28271
  };
28212
28272
  TimelineYear.prototype.scrollToDate = function (scrollDate) {
@@ -28705,7 +28765,7 @@ var ExcelExport = /** @__PURE__ @class */ (function () {
28705
28765
  fields.forEach(function (field, n) {
28706
28766
  var columnRule = { index: n + 1, value: event[field.name] || '' };
28707
28767
  if (field.name === _this.parent.eventFields.startTime || field.name === _this.parent.eventFields.endTime) {
28708
- var styleRule = { fontSize: 12, numberFormat: 'm/d/yyyy h:mm AM/PM' };
28768
+ var styleRule = { fontSize: 12, numberFormat: 'm/d/yyyy h:mm a' };
28709
28769
  columnRule = extend({}, columnRule, { style: styleRule }, true);
28710
28770
  }
28711
28771
  columnData.push(columnRule);
@@ -28803,6 +28863,7 @@ var Print = /** @__PURE__ @class */ (function () {
28803
28863
  Schedule.Inject(Day, Week, WorkWeek, Month, Agenda, MonthAgenda, TimelineViews, TimelineMonth, Year, TimelineYear);
28804
28864
  this.printInstance = new Schedule(this.getPrintScheduleModel(printOptions));
28805
28865
  this.printInstance.isPrinting = true;
28866
+ this.printInstance.root = this.parent.root ? this.parent.root : this.parent;
28806
28867
  this.printInstance.appendTo(element);
28807
28868
  this.printInstance.on(print, this.contentReady, this);
28808
28869
  this.printWindow = window.open('', 'print', 'height=' + window.outerHeight + ',width=' + window.outerWidth + ',tabbar=no');
@@ -28836,7 +28897,7 @@ var Print = /** @__PURE__ @class */ (function () {
28836
28897
  eventSettings.dataSource = this.parent.eventsData;
28837
28898
  var eventTemplate = !isNullOrUndefined(printOptions.eventSettings) &&
28838
28899
  !isNullOrUndefined(printOptions.eventSettings.template) ? printOptions.eventSettings.template : eventSettings.template;
28839
- eventSettings.template = typeof (eventTemplate) === 'function' ? null : eventTemplate;
28900
+ eventSettings.template = !this.parent.isAngular && typeof (eventTemplate) === 'function' ? null : eventTemplate;
28840
28901
  printModel.eventSettings = eventSettings;
28841
28902
  break;
28842
28903
  }
@@ -28847,13 +28908,15 @@ var Print = /** @__PURE__ @class */ (function () {
28847
28908
  break;
28848
28909
  case 'timeScale':
28849
28910
  timeScale = isNullOrUndefined(printOptions.timeScale) ? this.parent.timeScale : printOptions.timeScale;
28850
- timeScale.majorSlotTemplate = typeof (timeScale.majorSlotTemplate) === 'function' ? null : timeScale.majorSlotTemplate;
28851
- timeScale.minorSlotTemplate = typeof (timeScale.minorSlotTemplate) === 'function' ? null : timeScale.minorSlotTemplate;
28852
- printOptions.timeScale = timeScale;
28911
+ if (!this.parent.isAngular) {
28912
+ timeScale.majorSlotTemplate = typeof (timeScale.majorSlotTemplate) === 'function' ? null : timeScale.majorSlotTemplate;
28913
+ timeScale.minorSlotTemplate = typeof (timeScale.minorSlotTemplate) === 'function' ? null : timeScale.minorSlotTemplate;
28914
+ }
28915
+ printModel.timeScale = timeScale;
28853
28916
  break;
28854
28917
  case 'views':
28855
28918
  views = isNullOrUndefined(printOptions.views) ? this.parent.views : printOptions.views;
28856
- if (views && views.length > 0 && typeof (views[0]) === 'object') {
28919
+ if (!this.parent.isAngular && views && views.length > 0 && typeof (views[0]) === 'object') {
28857
28920
  var _loop_1 = function (view) {
28858
28921
  scheduleTemplates.forEach(function (x) {
28859
28922
  if (!isNullOrUndefined(view["" + x])) {
@@ -28871,8 +28934,8 @@ var Print = /** @__PURE__ @class */ (function () {
28871
28934
  default:
28872
28935
  if (scheduleTemplates.indexOf(key) > -1) {
28873
28936
  printModel["" + key] = isNullOrUndefined(printOptions["" + key]) ?
28874
- (typeof (this.parent["" + key]) === 'function' ? null : this.parent["" + key]) :
28875
- (typeof (printOptions["" + key]) === 'function' ? null : printOptions["" + key]);
28937
+ (!this.parent.isAngular && typeof (this.parent["" + key]) === 'function' ? null : this.parent["" + key]) :
28938
+ (!this.parent.isAngular && typeof (printOptions["" + key]) === 'function' ? null : printOptions["" + key]);
28876
28939
  break;
28877
28940
  }
28878
28941
  if (scheduleEvents.indexOf(key) > -1) {