@syncfusion/ej2-schedule 22.1.36 → 22.2.5

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 (33) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/ej2-schedule.min.js +2 -2
  3. package/dist/ej2-schedule.umd.min.js +2 -2
  4. package/dist/ej2-schedule.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-schedule.es2015.js +29 -11
  6. package/dist/es6/ej2-schedule.es2015.js.map +1 -1
  7. package/dist/es6/ej2-schedule.es5.js +29 -11
  8. package/dist/es6/ej2-schedule.es5.js.map +1 -1
  9. package/dist/global/ej2-schedule.min.js +2 -2
  10. package/dist/global/ej2-schedule.min.js.map +1 -1
  11. package/dist/global/index.d.ts +1 -1
  12. package/package.json +15 -15
  13. package/src/recurrence-editor/recurrence-editor.js +3 -6
  14. package/src/schedule/actions/crud.js +1 -1
  15. package/src/schedule/base/schedule-model.d.ts +27 -38
  16. package/src/schedule/base/schedule.d.ts +27 -38
  17. package/src/schedule/base/schedule.js +1 -0
  18. package/src/schedule/base/util.d.ts +6 -0
  19. package/src/schedule/base/util.js +20 -1
  20. package/src/schedule/models/event-settings-model.d.ts +6 -0
  21. package/src/schedule/models/event-settings.d.ts +6 -0
  22. package/src/schedule/models/group-model.d.ts +3 -0
  23. package/src/schedule/models/group.d.ts +3 -0
  24. package/src/schedule/models/header-rows-model.d.ts +3 -0
  25. package/src/schedule/models/header-rows.d.ts +3 -0
  26. package/src/schedule/models/quick-info-templates-model.d.ts +15 -6
  27. package/src/schedule/models/quick-info-templates.d.ts +15 -6
  28. package/src/schedule/models/time-scale-model.d.ts +8 -2
  29. package/src/schedule/models/time-scale.d.ts +8 -2
  30. package/src/schedule/models/views-model.d.ts +24 -0
  31. package/src/schedule/models/views.d.ts +24 -0
  32. package/src/schedule/popups/event-window.js +1 -1
  33. package/src/schedule/popups/quick-popups.js +2 -1
@@ -358,6 +358,10 @@ function getDateFromString(date) {
358
358
  return date.indexOf('Date') !== -1 ? new Date(parseInt(date.match(/\d+/g).toString(), 10)) :
359
359
  date.indexOf('T') !== -1 ? new Date(date) : new Date(date.replace(/-/g, '/'));
360
360
  }
361
+ /** @private */
362
+ let scrollWidth = null;
363
+ /** @private */
364
+ let pixelRatio = window.devicePixelRatio || window.screen.availWidth / document.documentElement.clientWidth;
361
365
  /**
362
366
  * Method to get scrollbar width
363
367
  *
@@ -365,6 +369,9 @@ function getDateFromString(date) {
365
369
  * @private
366
370
  */
367
371
  function getScrollBarWidth() {
372
+ if (scrollWidth !== null) {
373
+ return scrollWidth;
374
+ }
368
375
  const divNode = createElement('div');
369
376
  let value = 0;
370
377
  divNode.style.cssText = 'width:100px;height: 100px;overflow: scroll;position: absolute;top: -9999px;';
@@ -373,7 +380,19 @@ function getScrollBarWidth() {
373
380
  Math.ceil(devicePixelRatio % 1) : Math.floor(devicePixelRatio % 1) : 0;
374
381
  value = (divNode.offsetWidth - divNode.clientWidth - ratio) | 0;
375
382
  document.body.removeChild(divNode);
376
- return value;
383
+ return scrollWidth = value;
384
+ }
385
+ /**
386
+ * Method to reset scrollbar width
387
+ *
388
+ * @private
389
+ */
390
+ function resetScrollbarWidth() {
391
+ const zoomPixelRatio = window.devicePixelRatio || window.screen.availWidth / document.documentElement.clientWidth;
392
+ if (pixelRatio != zoomPixelRatio) {
393
+ scrollWidth = null;
394
+ pixelRatio = zoomPixelRatio;
395
+ }
377
396
  }
378
397
  /**
379
398
  * Method to find the index from data collection
@@ -10134,7 +10153,8 @@ class QuickPopups {
10134
10153
  this.dialogEvent = event;
10135
10154
  }
10136
10155
  this.quickPopupHide();
10137
- if (isNullOrUndefined(event) || (!isNullOrUndefined(event) && event.action !== 'escape')) {
10156
+ if (isNullOrUndefined(event) || (!isNullOrUndefined(event) && event.action !== 'escape') ||
10157
+ (this.parent.inlineModule && this.parent.element.querySelector('.' + INLINE_APPOINTMENT_CLASS))) {
10138
10158
  this.parent.eventBase.focusElement();
10139
10159
  }
10140
10160
  }
@@ -10684,7 +10704,7 @@ let RecurrenceEditor = class RecurrenceEditor extends Component {
10684
10704
  value: VALUEFIELD
10685
10705
  },
10686
10706
  placeholder: this.localeObj.getConstant(REPEAT),
10687
- htmlAttributes: { 'title': this.localeObj.getConstant(REPEAT), role: 'option' },
10707
+ htmlAttributes: { 'title': this.localeObj.getConstant(REPEAT) },
10688
10708
  change: (args) => {
10689
10709
  self.setProperties({ selectedType: this.frequencies.indexOf(args.value) }, false);
10690
10710
  self.element.querySelector('.' + REPEATCONTENT).innerHTML =
@@ -10706,7 +10726,6 @@ let RecurrenceEditor = class RecurrenceEditor extends Component {
10706
10726
  text: TEXTFIELD,
10707
10727
  value: VALUEFIELD
10708
10728
  },
10709
- htmlAttributes: { role: 'option' },
10710
10729
  change: (args) => {
10711
10730
  self.freshOnEndForm();
10712
10731
  self.updateEndOnForm(args.value);
@@ -10724,7 +10743,6 @@ let RecurrenceEditor = class RecurrenceEditor extends Component {
10724
10743
  text: TEXTFIELD,
10725
10744
  value: VALUEFIELD
10726
10745
  },
10727
- htmlAttributes: { role: 'option' },
10728
10746
  index: 1,
10729
10747
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
10730
10748
  change: (args) => {
@@ -10744,7 +10762,6 @@ let RecurrenceEditor = class RecurrenceEditor extends Component {
10744
10762
  text: TEXTFIELD,
10745
10763
  value: VALUEFIELD
10746
10764
  },
10747
- htmlAttributes: { role: 'option' },
10748
10765
  enableRtl: this.enableRtl,
10749
10766
  index: 7,
10750
10767
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
@@ -11042,7 +11059,7 @@ let RecurrenceEditor = class RecurrenceEditor extends Component {
11042
11059
  '<input type="text" tabindex="0" class="' + REPEATELEMENT +
11043
11060
  '"label="' + REPEATELEMENT.substr(2) + '" />' +
11044
11061
  '</div><div class="' + INPUTWARAPPER + ' ' +
11045
- INTERVALCLASS + ' ' + FORMRIGHT + '"><table class="' + RECURRENCETABLE + ' ' + REPEATCONTENTWRAPPER + '"><tr>' +
11062
+ INTERVALCLASS + ' ' + FORMRIGHT + '"><table class="' + RECURRENCETABLE + ' ' + REPEATCONTENTWRAPPER + '" role="none"><tr>' +
11046
11063
  '<td><input type="text" tabindex="0" id="' + this.element.id + '_' + REPEATINTERVAL + '" class="' + REPEATINTERVAL +
11047
11064
  '"title="' + this.localeObj.getConstant('repeatEvery') + '" /></td>' +
11048
11065
  '<td><span class="' + REPEATCONTENT + '"></span></td>' +
@@ -11062,7 +11079,7 @@ let RecurrenceEditor = class RecurrenceEditor extends Component {
11062
11079
  this.localeObj.getConstant('yearExpander') + '"/>' +
11063
11080
  '</div>' +
11064
11081
  '<div class="' + MONETHEXPANDERWRAPPER + '">' +
11065
- '<table class="' + RECURRENCETABLE + ' ' + MONETHEXPANDWRAPPER + '"><tr><td>' +
11082
+ '<table class="' + RECURRENCETABLE + ' ' + MONETHEXPANDWRAPPER + '" role="none"><tr><td>' +
11066
11083
  '<div class="' + INPUTWARAPPER + ' ' + MONTHEXPANDERCHECKBOXWRAPPER + '">' +
11067
11084
  '<input class="' + MONTHEXPANDERELEMENT + '"title="' + this.localeObj.getConstant('monthExpander') + '" type="radio">' +
11068
11085
  '</div></td>' +
@@ -11951,7 +11968,7 @@ class EventWindow {
11951
11968
  query = (e.text !== '') ? query.where('Text', 'contains', e.text, true) : query;
11952
11969
  e.updateData(this.parent.timezoneDataSource, query);
11953
11970
  },
11954
- htmlAttributes: { 'title': this.getFieldLabel(value), 'name': fieldName, role: 'option' },
11971
+ htmlAttributes: { 'title': this.getFieldLabel(value), 'name': fieldName },
11955
11972
  floatLabelType: 'Always',
11956
11973
  placeholder: this.getFieldLabel(value),
11957
11974
  popupHeight: '230px'
@@ -14355,7 +14372,7 @@ class Crud {
14355
14372
  editParams.deletedRecords = editParams.deletedRecords.concat(followData.follow);
14356
14373
  }
14357
14374
  if (isSpanned) {
14358
- followData.occurrence = followData.occurrence.filter((eventObj) => eventObj[fields.recurrenceID] === childEvent[fields.id]);
14375
+ followData.occurrence = followData.occurrence.filter((eventObj) => eventObj[fields.recurrenceID] === parentEvent[fields.id]);
14359
14376
  }
14360
14377
  editParams.deletedRecords = editParams.deletedRecords.concat(followData.occurrence);
14361
14378
  }
@@ -17132,6 +17149,7 @@ let Schedule = class Schedule extends Component {
17132
17149
  if (this.quickPopup) {
17133
17150
  this.quickPopup.onClosePopup();
17134
17151
  }
17152
+ resetScrollbarWidth();
17135
17153
  if (this.currentView === 'Month' || ((this.currentView !== 'Agenda' && this.currentView !== 'MonthAgenda')
17136
17154
  && !this.activeViewOptions.timeScale.enable) || this.activeView.isTimelineView()) {
17137
17155
  this.activeView.resetColWidth();
@@ -26902,5 +26920,5 @@ class Print {
26902
26920
  * Export Schedule components
26903
26921
  */
26904
26922
 
26905
- export { Schedule, cellClick, cellDoubleClick, moreEventsClick, select, hover, actionBegin, actionComplete, actionFailure, navigating, renderCell, eventClick, eventRendered, dataBinding, dataBound, popupOpen, popupClose, dragStart, drag, dragStop, resizeStart, resizing, resizeStop, inlineClick, cellSelect, initialLoad, initialEnd, print$1 as print, dataReady, eventsLoaded, contentReady, scroll, virtualScroll, scrollUiUpdate, uiUpdate, documentClick, cellMouseDown, WEEK_LENGTH, DEFAULT_WEEKS, MS_PER_DAY, MS_PER_MINUTE, getElementHeightFromClass, getElementWidthFromClass, getTranslateY, getTranslateX, getWeekFirstDate, getWeekLastDate, firstDateOfMonth, lastDateOfMonth, getWeekNumber, getWeekMiddleDate, setTime, resetTime, getDateInMs, getDateCount, addDays, addMonths, addYears, getStartEndHours, getMaxDays, getDaysCount, getDateFromString, getScrollBarWidth, findIndexInData, getOuterHeight, removeChildren, isDaylightSavingTime, getUniversalTime, isMobile, isIPadDevice, capitalizeFirstWord, Resize, DragAndDrop, HeaderRenderer, ViewBase, Day, Week, WorkWeek, Month, Year, Agenda, MonthAgenda, TimelineViews, TimelineMonth, TimelineYear, Timezone, timezoneData, ICalendarExport, ICalendarImport, ExcelExport, Print, RecurrenceEditor, generateSummary, generate, getDateFromRecurrenceDateString, extractObjectFromRule, getCalendarUtil, getRecurrenceStringFromDate, Gregorian, Islamic };
26923
+ export { Schedule, cellClick, cellDoubleClick, moreEventsClick, select, hover, actionBegin, actionComplete, actionFailure, navigating, renderCell, eventClick, eventRendered, dataBinding, dataBound, popupOpen, popupClose, dragStart, drag, dragStop, resizeStart, resizing, resizeStop, inlineClick, cellSelect, initialLoad, initialEnd, print$1 as print, dataReady, eventsLoaded, contentReady, scroll, virtualScroll, scrollUiUpdate, uiUpdate, documentClick, cellMouseDown, WEEK_LENGTH, DEFAULT_WEEKS, MS_PER_DAY, MS_PER_MINUTE, getElementHeightFromClass, getElementWidthFromClass, getTranslateY, getTranslateX, getWeekFirstDate, getWeekLastDate, firstDateOfMonth, lastDateOfMonth, getWeekNumber, getWeekMiddleDate, setTime, resetTime, getDateInMs, getDateCount, addDays, addMonths, addYears, getStartEndHours, getMaxDays, getDaysCount, getDateFromString, getScrollBarWidth, resetScrollbarWidth, findIndexInData, getOuterHeight, removeChildren, isDaylightSavingTime, getUniversalTime, isMobile, isIPadDevice, capitalizeFirstWord, Resize, DragAndDrop, HeaderRenderer, ViewBase, Day, Week, WorkWeek, Month, Year, Agenda, MonthAgenda, TimelineViews, TimelineMonth, TimelineYear, Timezone, timezoneData, ICalendarExport, ICalendarImport, ExcelExport, Print, RecurrenceEditor, generateSummary, generate, getDateFromRecurrenceDateString, extractObjectFromRule, getCalendarUtil, getRecurrenceStringFromDate, Gregorian, Islamic };
26906
26924
  //# sourceMappingURL=ej2-schedule.es2015.js.map