@progress/kendo-angular-dateinputs 16.0.0-develop.2 → 16.0.0-develop.20

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 (154) hide show
  1. package/calendar/calendar.component.d.ts +42 -8
  2. package/calendar/footer.component.d.ts +1 -1
  3. package/calendar/for.directive.d.ts +1 -1
  4. package/calendar/header.component.d.ts +3 -2
  5. package/calendar/horizontal-view-list.component.d.ts +4 -3
  6. package/calendar/localization/calendar-custom-messages.component.d.ts +1 -1
  7. package/calendar/localization/calendar-localized-messages.directive.d.ts +1 -1
  8. package/calendar/localization/calendar-messages.d.ts +1 -1
  9. package/calendar/localization/multiview-calendar-custom-messages.component.d.ts +1 -1
  10. package/calendar/localization/multiview-calendar-localized-messages.directive.d.ts +1 -1
  11. package/calendar/localization/multiview-calendar-messages.d.ts +1 -1
  12. package/calendar/models/cell-context.interface.d.ts +4 -0
  13. package/calendar/models/selection-range.interface.d.ts +2 -2
  14. package/calendar/models/selection.d.ts +11 -1
  15. package/calendar/multiview-calendar.component.d.ts +57 -8
  16. package/calendar/navigation.component.d.ts +1 -1
  17. package/calendar/templates/cell-template.directive.d.ts +1 -1
  18. package/calendar/templates/century-cell-template.directive.d.ts +1 -1
  19. package/calendar/templates/decade-cell-template.directive.d.ts +1 -1
  20. package/calendar/templates/footer-template.directiv/320/265.d.ts +1 -1
  21. package/calendar/templates/header-template.directive.d.ts +1 -1
  22. package/calendar/templates/header-title-template.directive.d.ts +1 -1
  23. package/calendar/templates/month-cell-template.directive.d.ts +1 -1
  24. package/calendar/templates/navigation-item-template.directive.d.ts +1 -1
  25. package/calendar/templates/weeknumber-cell-template.directive.d.ts +1 -1
  26. package/calendar/templates/year-cell-template.directive.d.ts +1 -1
  27. package/calendar/view-list.component.d.ts +9 -1
  28. package/calendar/view.component.d.ts +2 -1
  29. package/common/utils.d.ts +4 -0
  30. package/dateinput/dateinput.component.d.ts +13 -1
  31. package/dateinput/localization/dateinput-custom-messages.component.d.ts +1 -1
  32. package/dateinput/localization/dateinput-localized-messages.directive.d.ts +1 -1
  33. package/dateinput/localization/messages.d.ts +5 -1
  34. package/datepicker/datepicker.component.d.ts +7 -2
  35. package/datepicker/localization/datepicker-custom-messages.component.d.ts +1 -1
  36. package/datepicker/localization/datepicker-localized-messages.directive.d.ts +1 -1
  37. package/datepicker/localization/messages.d.ts +5 -1
  38. package/daterange/date-range-end-input.directive.d.ts +1 -1
  39. package/daterange/date-range-input.d.ts +1 -1
  40. package/daterange/date-range-popup-template.directive.d.ts +1 -1
  41. package/daterange/date-range-popup.component.d.ts +30 -2
  42. package/daterange/date-range-selection.directive.d.ts +1 -1
  43. package/daterange/date-range-start-input.directive.d.ts +1 -1
  44. package/daterange/date-range.component.d.ts +16 -1
  45. package/daterange/localization/daterange-popup-custom-messages.component.d.ts +1 -1
  46. package/daterange/localization/daterange-popup-localized-messages.directive.d.ts +1 -1
  47. package/daterange/localization/messages.d.ts +1 -1
  48. package/datetimepicker/datetimepicker.component.d.ts +12 -1
  49. package/datetimepicker/localization/datetimepicker-custom-messages.component.d.ts +1 -1
  50. package/datetimepicker/localization/localized-messages.directive.d.ts +1 -1
  51. package/datetimepicker/localization/messages.d.ts +5 -1
  52. package/esm2020/calendar/calendar-common.module.mjs +4 -4
  53. package/esm2020/calendar/calendar.component.mjs +256 -66
  54. package/esm2020/calendar/calendar.module.mjs +12 -14
  55. package/esm2020/calendar/calendars.module.mjs +5 -7
  56. package/esm2020/calendar/footer.component.mjs +6 -6
  57. package/esm2020/calendar/for.directive.mjs +3 -3
  58. package/esm2020/calendar/header.component.mjs +44 -26
  59. package/esm2020/calendar/horizontal-view-list.component.mjs +16 -12
  60. package/esm2020/calendar/localization/calendar-custom-messages.component.mjs +3 -3
  61. package/esm2020/calendar/localization/calendar-localized-messages.directive.mjs +3 -3
  62. package/esm2020/calendar/localization/calendar-messages.mjs +3 -3
  63. package/esm2020/calendar/localization/multiview-calendar-custom-messages.component.mjs +3 -3
  64. package/esm2020/calendar/localization/multiview-calendar-localized-messages.directive.mjs +3 -3
  65. package/esm2020/calendar/localization/multiview-calendar-messages.mjs +3 -3
  66. package/esm2020/calendar/models/selection.mjs +34 -1
  67. package/esm2020/calendar/multiview-calendar.component.mjs +268 -56
  68. package/esm2020/calendar/multiview-calendar.module.mjs +10 -12
  69. package/esm2020/calendar/navigation.component.mjs +8 -8
  70. package/esm2020/calendar/services/bus-view.service.mjs +3 -3
  71. package/esm2020/calendar/services/century-view.service.mjs +29 -8
  72. package/esm2020/calendar/services/decade-view.service.mjs +29 -8
  73. package/esm2020/calendar/services/disabled-dates.service.mjs +3 -3
  74. package/esm2020/calendar/services/dom.service.mjs +5 -5
  75. package/esm2020/calendar/services/month-view.service.mjs +29 -8
  76. package/esm2020/calendar/services/navigation.service.mjs +3 -3
  77. package/esm2020/calendar/services/scroll-sync.service.mjs +3 -3
  78. package/esm2020/calendar/services/selection.service.mjs +3 -3
  79. package/esm2020/calendar/services/weeknames.service.mjs +3 -3
  80. package/esm2020/calendar/services/year-view.service.mjs +29 -8
  81. package/esm2020/calendar/templates/cell-template.directive.mjs +3 -3
  82. package/esm2020/calendar/templates/century-cell-template.directive.mjs +3 -3
  83. package/esm2020/calendar/templates/decade-cell-template.directive.mjs +3 -3
  84. package/esm2020/calendar/templates/footer-template.directiv/320/265.mjs +3 -3
  85. package/esm2020/calendar/templates/header-template.directive.mjs +3 -3
  86. package/esm2020/calendar/templates/header-title-template.directive.mjs +3 -3
  87. package/esm2020/calendar/templates/month-cell-template.directive.mjs +3 -3
  88. package/esm2020/calendar/templates/navigation-item-template.directive.mjs +3 -3
  89. package/esm2020/calendar/templates/weeknumber-cell-template.directive.mjs +3 -3
  90. package/esm2020/calendar/templates/year-cell-template.directive.mjs +3 -3
  91. package/esm2020/calendar/templates.module.mjs +4 -4
  92. package/esm2020/calendar/view-list.component.mjs +31 -10
  93. package/esm2020/calendar/view.component.mjs +9 -6
  94. package/esm2020/common/adaptive.module.mjs +4 -4
  95. package/esm2020/common/utils.mjs +5 -1
  96. package/esm2020/dateinput/dateinput.component.mjs +70 -13
  97. package/esm2020/dateinput/dateinput.module.mjs +4 -4
  98. package/esm2020/dateinput/localization/dateinput-custom-messages.component.mjs +3 -3
  99. package/esm2020/dateinput/localization/dateinput-localized-messages.directive.mjs +3 -3
  100. package/esm2020/dateinput/localization/messages.mjs +5 -3
  101. package/esm2020/dateinputs.module.mjs +4 -4
  102. package/esm2020/datepicker/datepicker.component.mjs +45 -23
  103. package/esm2020/datepicker/datepicker.module.mjs +12 -14
  104. package/esm2020/datepicker/localization/datepicker-custom-messages.component.mjs +3 -3
  105. package/esm2020/datepicker/localization/datepicker-localized-messages.directive.mjs +3 -3
  106. package/esm2020/datepicker/localization/messages.mjs +5 -3
  107. package/esm2020/daterange/date-range-end-input.directive.mjs +3 -3
  108. package/esm2020/daterange/date-range-input.mjs +3 -3
  109. package/esm2020/daterange/date-range-popup-template.directive.mjs +3 -3
  110. package/esm2020/daterange/date-range-popup.component.mjs +75 -21
  111. package/esm2020/daterange/date-range-selection.directive.mjs +3 -3
  112. package/esm2020/daterange/date-range-start-input.directive.mjs +3 -3
  113. package/esm2020/daterange/date-range.component.mjs +12 -10
  114. package/esm2020/daterange/date-range.module.mjs +4 -4
  115. package/esm2020/daterange/date-range.service.mjs +3 -4
  116. package/esm2020/daterange/localization/daterange-popup-custom-messages.component.mjs +3 -3
  117. package/esm2020/daterange/localization/daterange-popup-localized-messages.directive.mjs +3 -3
  118. package/esm2020/daterange/localization/messages.mjs +3 -3
  119. package/esm2020/datetimepicker/datetimepicker.component.mjs +56 -23
  120. package/esm2020/datetimepicker/datetimepicker.module.mjs +14 -16
  121. package/esm2020/datetimepicker/localization/datetimepicker-custom-messages.component.mjs +3 -3
  122. package/esm2020/datetimepicker/localization/localized-messages.directive.mjs +3 -3
  123. package/esm2020/datetimepicker/localization/messages.mjs +5 -3
  124. package/esm2020/package-metadata.mjs +2 -2
  125. package/esm2020/timepicker/localization/messages.mjs +5 -3
  126. package/esm2020/timepicker/localization/timepicker-custom-messages.component.mjs +3 -3
  127. package/esm2020/timepicker/localization/timepicker-localized-messages.directive.mjs +3 -3
  128. package/esm2020/timepicker/localization/timeselector-custom-messages.component.mjs +3 -3
  129. package/esm2020/timepicker/localization/timeselector-localized-messages.directive.mjs +3 -3
  130. package/esm2020/timepicker/services/dayperiod.service.mjs +3 -3
  131. package/esm2020/timepicker/services/dom.service.mjs +3 -3
  132. package/esm2020/timepicker/services/hours.service.mjs +3 -3
  133. package/esm2020/timepicker/services/milliseconds.service.mjs +3 -3
  134. package/esm2020/timepicker/services/minutes.service.mjs +3 -3
  135. package/esm2020/timepicker/services/seconds.service.mjs +3 -3
  136. package/esm2020/timepicker/timelist.component.mjs +6 -6
  137. package/esm2020/timepicker/timepicker.component.mjs +42 -17
  138. package/esm2020/timepicker/timepicker.module.mjs +4 -4
  139. package/esm2020/timepicker/timeselector.component.mjs +29 -14
  140. package/esm2020/virtualization/virtualization.component.mjs +4 -4
  141. package/esm2020/virtualization/virtualization.module.mjs +4 -4
  142. package/fesm2015/progress-kendo-angular-dateinputs.mjs +1547 -763
  143. package/fesm2020/progress-kendo-angular-dateinputs.mjs +1538 -766
  144. package/package.json +17 -20
  145. package/timepicker/localization/messages.d.ts +5 -1
  146. package/timepicker/localization/timepicker-custom-messages.component.d.ts +1 -1
  147. package/timepicker/localization/timepicker-localized-messages.directive.d.ts +1 -1
  148. package/timepicker/localization/timeselector-custom-messages.component.d.ts +1 -1
  149. package/timepicker/localization/timeselector-localized-messages.directive.d.ts +1 -1
  150. package/timepicker/timelist.component.d.ts +1 -1
  151. package/timepicker/timepicker.component.d.ts +7 -1
  152. package/timepicker/timeselector.component.d.ts +2 -1
  153. package/virtualization/virtualization.component.d.ts +1 -1
  154. package/progress-kendo-angular-dateinputs.d.ts +0 -9
@@ -6,7 +6,7 @@ import { Component, ChangeDetectorRef, ChangeDetectionStrategy, ContentChild, Ev
6
6
  import { NG_VALUE_ACCESSOR, NG_VALIDATORS, NgControl } from '@angular/forms';
7
7
  import { L10N_PREFIX, LocalizationService } from '@progress/kendo-angular-l10n';
8
8
  import { cloneDate, isEqual } from '@progress/kendo-date-math';
9
- import { hasObservers, KendoInput, guid, Keys } from '@progress/kendo-angular-common';
9
+ import { hasObservers, KendoInput, guid, Keys, isObject } from '@progress/kendo-angular-common';
10
10
  import { validatePackage } from '@progress/kendo-licensing';
11
11
  import { packageMetadata } from '../package-metadata';
12
12
  import { MultiViewCalendarComponent } from './multiview-calendar.component';
@@ -28,12 +28,13 @@ import { HeaderTitleTemplateDirective } from './templates/header-title-template.
28
28
  import { NavigationItemTemplateDirective } from './templates/navigation-item-template.directive';
29
29
  import { PickerService } from '../common/picker.service';
30
30
  import { CalendarViewEnum } from './models/view.enum';
31
+ import { handleRangeSelection } from './models/selection';
31
32
  import { minValidator } from '../validators/min.validator';
32
33
  import { maxValidator } from '../validators/max.validator';
33
34
  import { MIN_DATE, MAX_DATE } from '../defaults';
34
35
  import { areDatesEqual, dateInRange, DEFAULT_SIZE, getSizeClass, getToday, hasExistingValue, last, noop } from '../util';
35
36
  import { closest } from '../common/dom-queries';
36
- import { requiresZoneOnBlur, preventDefault, isPresent, isArrowWithShiftPressed, selectors, attributeNames } from '../common/utils';
37
+ import { requiresZoneOnBlur, preventDefault, isPresent, isArrowWithShiftPressed, selectors, attributeNames, isNullOrDate } from '../common/utils';
37
38
  import { from as fromPromise } from 'rxjs';
38
39
  import { HeaderTemplateDirective } from './templates/header-template.directive';
39
40
  import { FooterTemplateDirective } from './templates/footer-template.directivе';
@@ -46,13 +47,13 @@ import * as i5 from "./services/disabled-dates.service";
46
47
  import * as i6 from "@progress/kendo-angular-l10n";
47
48
  import * as i7 from "./services/selection.service";
48
49
  import * as i8 from "../common/picker.service";
49
- import * as i9 from "./navigation.component";
50
- import * as i10 from "./view-list.component";
51
- import * as i11 from "@progress/kendo-angular-common";
52
- import * as i12 from "./multiview-calendar.component";
53
- import * as i13 from "./localization/multiview-calendar-custom-messages.component";
50
+ import * as i9 from "@angular/common";
51
+ import * as i10 from "./localization/multiview-calendar-custom-messages.component";
52
+ import * as i11 from "./multiview-calendar.component";
53
+ import * as i12 from "@progress/kendo-angular-common";
54
+ import * as i13 from "./navigation.component";
54
55
  import * as i14 from "./localization/calendar-localized-messages.directive";
55
- import * as i15 from "@angular/common";
56
+ import * as i15 from "./view-list.component";
56
57
  const BOTTOM_VIEW_DOC_LINK = 'http://www.telerik.com/kendo-angular-ui/components/dateinputs/api/CalendarComponent/#toc-bottomview';
57
58
  const TOP_VIEW_DOC_LINK = 'http://www.telerik.com/kendo-angular-ui/components/dateinputs/api/CalendarComponent/#toc-topview';
58
59
  const MIN_DOC_LINK = 'http://www.telerik.com/kendo-angular-ui/components/dateinputs/api/CalendarComponent/#toc-min';
@@ -125,15 +126,14 @@ export class CalendarComponent {
125
126
  * @default false
126
127
  */
127
128
  this.footer = false;
129
+ this._selection = 'single';
128
130
  /**
129
- * Sets the Calendar selection mode
130
- * ([see example]({% slug multiple_selection_calendar %})).
131
+ * Allows reverse selection when using `range` selection.
132
+ * If `allowReverse` is set to `true`, the component skips the validation of whether the start date is after the end date.
131
133
  *
132
- * The available values are:
133
- * * `single` (default)
134
- * * `multiple`
134
+ * @default false
135
135
  */
136
- this.selection = 'single';
136
+ this.allowReverse = false;
137
137
  /**
138
138
  * Sets or gets the `disabled` property of the Calendar and
139
139
  * determines whether the component is active
@@ -218,8 +218,10 @@ export class CalendarComponent {
218
218
  */
219
219
  this.valueChange = new EventEmitter();
220
220
  this._size = DEFAULT_SIZE;
221
+ this._activeRangeEnd = 'start';
221
222
  this.isActive = false;
222
223
  this.cellUID = guid();
224
+ this.selectionRange = { start: null, end: null };
223
225
  this.selectedDates = [];
224
226
  this._min = new Date(MIN_DATE);
225
227
  this._max = new Date(MAX_DATE);
@@ -229,14 +231,17 @@ export class CalendarComponent {
229
231
  this.onValidatorChange = noop;
230
232
  this.minValidateFn = noop;
231
233
  this.maxValidateFn = noop;
234
+ this.changes = {};
235
+ this.valueSetter = false;
236
+ this.selectionSetter = false;
232
237
  this.syncNavigation = true;
233
238
  this._type = 'infinite';
234
239
  this.domEvents = [];
235
240
  this.resolvedPromise = Promise.resolve(null);
236
241
  this.destroyed = false;
242
+ this.canHover = false;
237
243
  validatePackage(packageMetadata);
238
244
  this.id = `kendo-calendarid-${this.bus.calendarId}`;
239
- this.setClasses(element.nativeElement);
240
245
  if (this.pickerService) {
241
246
  this.pickerService.calendar = this;
242
247
  }
@@ -320,29 +325,37 @@ export class CalendarComponent {
320
325
  get max() {
321
326
  return this._max;
322
327
  }
328
+ /**
329
+ * Sets the Calendar selection mode
330
+ * ([see example]({% slug multiple_selection_calendar %})).
331
+ *
332
+ * The available values are:
333
+ * * `single` (default)
334
+ * * `multiple`
335
+ * * `range`
336
+ */
337
+ set selection(_selection) {
338
+ this._selection = _selection;
339
+ this.selectionSetter = true;
340
+ }
341
+ get selection() {
342
+ return this._selection;
343
+ }
323
344
  /**
324
345
  * Sets or gets the `value` property of the Calendar and defines the selected value of the component.
325
346
  *
326
347
  * > The `value` has to be a valid
327
348
  * [JavaScript `Date`](https://developer.mozilla.org/en/docs/Web/JavaScript/Reference/Global_Objects/Date)
328
- * instance when in `single` selection mode or an array of valid JavaScript Date instances when in `multiple` selection mode.
349
+ * instance when in `single` selection mode, an array of valid JavaScript Date instances when in `multiple` selection mode, or
350
+ * an object of type `SelectionRange` when in `range` selection mode.
329
351
  */
352
+ set value(candidate) {
353
+ this.valueSetter = true;
354
+ this._value = candidate;
355
+ }
330
356
  get value() {
331
357
  return this._value;
332
358
  }
333
- set value(candidate) {
334
- this.verifyValue(candidate);
335
- this._value = Array.isArray(candidate) ?
336
- candidate.filter(date => isPresent(date)).map(element => cloneDate(element)) :
337
- cloneDate(candidate);
338
- const selection = [].concat(candidate).filter(date => isPresent(date)).map(date => cloneDate(date));
339
- if (!areDatesEqual(selection, this.selectedDates)) {
340
- const lastSelected = last(selection);
341
- this.rangePivot = cloneDate(lastSelected);
342
- this.focusedDate = cloneDate(lastSelected) || this.focusedDate;
343
- this.selectedDates = selection;
344
- }
345
- }
346
359
  /**
347
360
  * @hidden
348
361
  */
@@ -373,7 +386,9 @@ export class CalendarComponent {
373
386
  */
374
387
  set type(type) {
375
388
  this.renderer.removeClass(this.element.nativeElement, `k-calendar-${this.type}`);
376
- this.renderer.addClass(this.element.nativeElement, `k-calendar-${type}`);
389
+ if (type === 'infinite') {
390
+ this.renderer.addClass(this.element.nativeElement, `k-calendar-${type}`);
391
+ }
377
392
  this._type = type;
378
393
  }
379
394
  get type() {
@@ -512,17 +527,23 @@ export class CalendarComponent {
512
527
  *
513
528
  */
514
529
  set size(size) {
515
- const element = this.type === 'infinite' ? this.element : this.multiViewCalendar.element;
516
- this.renderer.removeClass(element.nativeElement, getSizeClass('calendar', this.size));
517
- const newSize = size ? size : DEFAULT_SIZE;
518
- if (newSize !== 'none') {
519
- this.renderer.addClass(element.nativeElement, getSizeClass('calendar', newSize));
520
- }
521
- this._size = newSize;
530
+ this._size = size;
522
531
  }
523
532
  get size() {
524
533
  return this._size;
525
534
  }
535
+ /**
536
+ * Specify, which end of the defined selection range should be marked as active.
537
+ *
538
+ * > Value will be ignored if the selection range is undefined.
539
+ * > If range selection is used then the default value is 'start'.
540
+ */
541
+ set activeRangeEnd(_activeRangeEnd) {
542
+ this._activeRangeEnd = _activeRangeEnd;
543
+ }
544
+ get activeRangeEnd() {
545
+ return this._activeRangeEnd;
546
+ }
526
547
  get activeViewEnum() {
527
548
  const activeView = CalendarViewEnum[this.activeView];
528
549
  return activeView < this.bottomViewEnum ? this.bottomViewEnum : activeView;
@@ -541,6 +562,7 @@ export class CalendarComponent {
541
562
  return this.type === 'classic' ? undefined : this.disabled;
542
563
  }
543
564
  ngOnInit() {
565
+ this.setClasses(this.element.nativeElement);
544
566
  if (this.type === 'infinite') {
545
567
  this.dom.calculateHeights(this.element.nativeElement);
546
568
  this.scrollSyncService.configure(this.activeViewEnum);
@@ -555,26 +577,36 @@ export class CalendarComponent {
555
577
  }
556
578
  }
557
579
  ngOnChanges(changes) {
580
+ this.changes = changes;
558
581
  this.verifyChanges();
559
582
  this.bus.configure(this.bottomViewEnum, this.topViewEnum);
560
583
  this.scrollSyncService.configure(this.activeViewEnum);
561
- if (hasExistingValue(changes, 'focusedDate')) {
562
- const focusedDate = changes.focusedDate.currentValue;
584
+ }
585
+ ngDoCheck() {
586
+ if (this.valueSetter || this.selectionSetter) {
587
+ this.setValue(this.value);
588
+ this.valueSetter = false;
589
+ this.selectionSetter = false;
590
+ }
591
+ if (hasExistingValue(this.changes, 'focusedDate')) {
592
+ const focusedDate = this.changes.focusedDate.currentValue;
563
593
  this.focusedDate = dateInRange(focusedDate, this.min, this.max);
564
594
  }
565
- if (changes.navigation) {
595
+ if (this.changes.navigation) {
566
596
  this.syncNavigation = true;
567
597
  }
568
- if (changes.min || changes.max || changes.rangeValidation) {
598
+ if (this.changes.min || this.changes.max || this.changes.rangeValidation) {
569
599
  this.minValidateFn = this.rangeValidation ? minValidator(this.min) : noop;
570
600
  this.maxValidateFn = this.rangeValidation ? maxValidator(this.max) : noop;
571
601
  this.onValidatorChange();
572
602
  }
603
+ this.changes = {};
573
604
  }
574
605
  ngAfterViewInit() {
575
606
  this.setAriaActivedescendant();
576
607
  if (this.size !== 'none') {
577
608
  const element = this.type === 'infinite' ? this.element : this.multiViewCalendar.element;
609
+ this.renderer.removeClass(element.nativeElement, getSizeClass('calendar', this.size));
578
610
  this.renderer.addClass(element.nativeElement, getSizeClass('calendar', this.size));
579
611
  }
580
612
  }
@@ -602,6 +634,31 @@ export class CalendarComponent {
602
634
  }
603
635
  this.destroyed = true;
604
636
  }
637
+ /**
638
+ * @hidden
639
+ */
640
+ onCellEnter(date) {
641
+ if (this.selection === 'range' && this.canHover) {
642
+ this.ngZone.run(() => {
643
+ if (this.allowReverse) {
644
+ if (this.activeRangeEnd === 'end' && this.selectionRange.start) {
645
+ this.selectionRange = { start: this.selectionRange.start, end: date };
646
+ }
647
+ if (this.activeRangeEnd === 'start' && this.selectionRange.end) {
648
+ this.selectionRange = { start: date, end: this.selectionRange.end };
649
+ }
650
+ }
651
+ else {
652
+ if (this.activeRangeEnd === 'end' && this.selectionRange.start && date >= this.selectionRange.start) {
653
+ this.selectionRange = { start: this.selectionRange.start, end: date };
654
+ }
655
+ if (this.selectionRange.start && date < this.selectionRange.start) {
656
+ this.selectionRange = { start: this.selectionRange.start, end: null };
657
+ }
658
+ }
659
+ });
660
+ }
661
+ }
605
662
  /**
606
663
  * @hidden
607
664
  */
@@ -675,9 +732,14 @@ export class CalendarComponent {
675
732
  /**
676
733
  * @hidden
677
734
  */
678
- handleMultiViewCalendarValueChange(date, focusedDate) {
679
- const selectedDates = Array.isArray(date) ? date : [date];
680
- this.handleDateChange({ selectedDates, focusedDate });
735
+ handleMultiViewCalendarValueChange(value, focusedDate) {
736
+ if (this.selection === 'range') {
737
+ this.valueChange.emit(value);
738
+ }
739
+ else {
740
+ const selectedDates = (Array.isArray(value) ? value : [value]);
741
+ this.handleDateChange({ selectedDates, focusedDate });
742
+ }
681
743
  }
682
744
  /**
683
745
  * @hidden
@@ -701,6 +763,9 @@ export class CalendarComponent {
701
763
  if (this.disabledDatesService.isDateDisabled(this.focusedDate)) {
702
764
  return;
703
765
  }
766
+ if (this.selection === 'range') {
767
+ return;
768
+ }
704
769
  this.ngZone.run(() => {
705
770
  this.selectedDates = availableDates.map(date => cloneDate(date));
706
771
  this.value = this.parseSelectionToValue(availableDates);
@@ -813,8 +878,13 @@ export class CalendarComponent {
813
878
  */
814
879
  handleCellClick({ date, modifiers }) {
815
880
  this.focus();
816
- this.selectionService.lastClicked = date;
817
- this.performSelection(date, modifiers);
881
+ if (this.selection === 'range') {
882
+ this.performRangeSelection(date);
883
+ }
884
+ else {
885
+ this.selectionService.lastClicked = date;
886
+ this.performSelection(date, modifiers);
887
+ }
818
888
  }
819
889
  /**
820
890
  * @hidden
@@ -824,10 +894,22 @@ export class CalendarComponent {
824
894
  return;
825
895
  }
826
896
  this.ngZone.run(() => {
827
- this.handleDateChange({
828
- selectedDates: dates,
829
- focusedDate: last(dates)
830
- });
897
+ if (this.selection === 'multiple') {
898
+ this.handleDateChange({
899
+ selectedDates: dates,
900
+ focusedDate: last(dates),
901
+ });
902
+ }
903
+ if (this.selection === 'range') {
904
+ this.canHover = false;
905
+ this.activeRangeEnd = 'start';
906
+ const shouldEmitValueChange = this.selectionRange.start?.getTime() !== dates[0].getTime() ||
907
+ this.selectionRange.end?.getTime() !== last(dates).getTime();
908
+ this.value = { start: dates[0], end: last(dates) };
909
+ if (shouldEmitValueChange) {
910
+ this.valueChange.emit(this.value);
911
+ }
912
+ }
831
913
  });
832
914
  }
833
915
  /**
@@ -837,7 +919,6 @@ export class CalendarComponent {
837
919
  if (this.element.nativeElement.contains(args.relatedTarget)) {
838
920
  return;
839
921
  }
840
- ;
841
922
  this.isActive = false;
842
923
  // the injector can get the NgControl instance of the parent component (for example, the DateTimePicker)
843
924
  // and enters the zone for no reason because the parent component is still untouched
@@ -873,9 +954,11 @@ export class CalendarComponent {
873
954
  }
874
955
  }
875
956
  setClasses(element) {
876
- this.renderer.addClass(element, 'k-widget');
877
- this.renderer.addClass(element, 'k-calendar');
878
- this.renderer.addClass(element, `k-calendar-${this.type}`);
957
+ this.renderer.removeClass(element, `k-calendar-${this.type}`);
958
+ if (this.type === 'infinite') {
959
+ this.renderer.addClass(element, 'k-calendar');
960
+ this.renderer.addClass(element, `k-calendar-${this.type}`);
961
+ }
879
962
  }
880
963
  verifyChanges() {
881
964
  if (!isDevMode()) {
@@ -892,14 +975,22 @@ export class CalendarComponent {
892
975
  if (!isDevMode()) {
893
976
  return;
894
977
  }
895
- if (this.selection === 'single' && candidate && !(candidate instanceof Date)) {
896
- throw new Error(`The 'value' should be a valid JavaScript Date instance. Check ${VALUE_DOC_LINK} for possible resolution.`);
978
+ if (this.selection === 'single' && candidate && !(isNullOrDate(candidate))) {
979
+ throw new Error(`When using 'single' selection the 'value' should be a valid JavaScript Date instance. Check ${VALUE_DOC_LINK} for possible resolution.`);
897
980
  }
898
- else if (this.selection === 'multiple' && candidate && Array.isArray(candidate)) {
899
- const onlyDates = candidate.every(value => value instanceof Date);
900
- if (!onlyDates) {
901
- throw new Error(`The 'value' should be an array of valid JavaScript Date instances. Check ${VALUE_DOC_LINK} for possible resolution.`);
981
+ else if (this.selection === 'multiple' && candidate) {
982
+ if (Array.isArray(candidate)) {
983
+ const onlyDates = candidate.every(value => value instanceof Date);
984
+ if (!onlyDates) {
985
+ throw new Error(`When using 'multiple' selection the 'value' should be an array of valid JavaScript Date instances. Check ${VALUE_DOC_LINK} for possible resolution.`);
986
+ }
902
987
  }
988
+ if (Object.keys(candidate).find(k => k === 'start') && Object.keys(candidate).find(k => k === 'end')) {
989
+ throw new Error(`When using 'multiple' selection the 'value' should be an array of valid JavaScript Date instances. Check ${VALUE_DOC_LINK} for possible resolution.`);
990
+ }
991
+ }
992
+ else if (this.selection === 'range' && candidate && !(isNullOrDate(candidate['start']) && isNullOrDate(candidate['end']))) {
993
+ throw new Error(`The 'value' should be an object with start and end dates. Check ${VALUE_DOC_LINK} for possible resolution.`);
903
994
  }
904
995
  }
905
996
  bindEvents() {
@@ -952,12 +1043,17 @@ export class CalendarComponent {
952
1043
  }
953
1044
  if (args.keyCode === Keys.Enter) {
954
1045
  this.selectionService.lastClicked = this.focusedDate;
955
- this.performSelection(this.focusedDate, args);
1046
+ if (this.selection !== 'range') {
1047
+ this.performSelection(this.focusedDate, args);
1048
+ }
1049
+ else {
1050
+ this.performRangeSelection(this.focusedDate);
1051
+ }
956
1052
  }
957
1053
  if (args.keyCode === Keys.KeyT) {
958
1054
  this.focusToday();
959
1055
  }
960
- if (isArrowWithShiftPressed(args)) {
1056
+ if (isArrowWithShiftPressed(args) && this.selection !== 'range') {
961
1057
  args.anyArrow = true;
962
1058
  this.performSelection(this.focusedDate, args);
963
1059
  }
@@ -996,6 +1092,78 @@ export class CalendarComponent {
996
1092
  selection = selection || [];
997
1093
  return this.selection === 'single' ? cloneDate(last(selection)) : selection.map(date => cloneDate(date));
998
1094
  }
1095
+ setValue(candidate) {
1096
+ this.verifyValue(candidate);
1097
+ if (candidate === null) {
1098
+ this._value = null;
1099
+ this.selectedDates = [];
1100
+ this.selectionRange = { start: null, end: null };
1101
+ }
1102
+ else if (Array.isArray(candidate)) {
1103
+ this.selectionRange = { start: null, end: null };
1104
+ this._value = candidate.filter(date => isPresent(date)).map(element => cloneDate(element));
1105
+ }
1106
+ else if (isObject(candidate) && Object.keys(candidate).find(k => k === 'start') && Object.keys(candidate).find(k => k === 'end')) {
1107
+ this.selectedDates = [];
1108
+ this.selectionRange = { start: null, end: null };
1109
+ this._value = { start: null, end: null };
1110
+ this._value.start = candidate.start instanceof Date ? cloneDate(candidate.start) : null;
1111
+ this._value.end = candidate.end instanceof Date ? cloneDate(candidate.end) : null;
1112
+ this.selectionRange = Object.assign({}, this._value);
1113
+ if (this._value?.start && !this._value?.end) {
1114
+ this.activeRangeEnd = 'end';
1115
+ this.canHover = true;
1116
+ }
1117
+ if (this._value?.end && !this._value?.start) {
1118
+ this.activeRangeEnd = 'start';
1119
+ this.canHover = true;
1120
+ }
1121
+ if (this.activeRangeEnd === 'end') {
1122
+ this.focusedDate = this.selectionRange.start || this.selectionRange.end || getToday();
1123
+ }
1124
+ else {
1125
+ this.focusedDate = this.selectionRange.end || this.selectionRange.start || getToday();
1126
+ }
1127
+ }
1128
+ else {
1129
+ this.selectionRange = { start: null, end: null };
1130
+ this._value = cloneDate(candidate);
1131
+ }
1132
+ if (this.selection !== 'range') {
1133
+ const selection = [].concat(candidate).filter(date => isPresent(date)).map(date => cloneDate(date));
1134
+ if (!areDatesEqual(selection, this.selectedDates)) {
1135
+ const lastSelected = last(selection);
1136
+ this.rangePivot = cloneDate(lastSelected);
1137
+ this.focusedDate = cloneDate(lastSelected) || this.focusedDate;
1138
+ this.selectedDates = selection;
1139
+ }
1140
+ }
1141
+ }
1142
+ performRangeSelection(date) {
1143
+ const clonedRangeSelection = Object.assign({}, this.selectionRange);
1144
+ const emitValueChange = (this.activeRangeEnd === 'start' && this.value?.start?.getTime() !== date?.getTime()) ||
1145
+ (this.activeRangeEnd === 'end' && this.value?.end?.getTime() !== date?.getTime());
1146
+ this.ngZone.run(() => {
1147
+ const rangeSelection = handleRangeSelection(date, clonedRangeSelection, this.activeRangeEnd, this.allowReverse);
1148
+ this.activeRangeEnd = rangeSelection.activeRangeEnd;
1149
+ if (this.canHover && rangeSelection.activeRangeEnd === 'end' && rangeSelection.selectionRange.end?.getTime() === date.getTime()) {
1150
+ this.activeRangeEnd = 'start';
1151
+ }
1152
+ if ((this.activeRangeEnd === 'end' && rangeSelection.selectionRange.start) ||
1153
+ (this.activeRangeEnd === 'start' && rangeSelection.selectionRange.end)) {
1154
+ this.canHover = true;
1155
+ }
1156
+ else {
1157
+ this.canHover = false;
1158
+ }
1159
+ if (emitValueChange && (this.value?.start?.getTime() !== rangeSelection.selectionRange?.start?.getTime() ||
1160
+ this.value?.end?.getTime() !== rangeSelection.selectionRange?.end?.getTime())) {
1161
+ this.value = rangeSelection.selectionRange;
1162
+ this.valueChange.emit(this.value);
1163
+ }
1164
+ this.cdr.markForCheck();
1165
+ });
1166
+ }
999
1167
  performSelection(date, selectionModifiers) {
1000
1168
  const selection = this.selectionService.performSelection({
1001
1169
  date: date,
@@ -1012,8 +1180,8 @@ export class CalendarComponent {
1012
1180
  });
1013
1181
  }
1014
1182
  }
1015
- CalendarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CalendarComponent, deps: [{ token: i1.BusViewService }, { token: i2.CalendarDOMService }, { token: i0.ElementRef }, { token: i3.NavigationService }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i0.NgZone }, { token: i0.Injector }, { token: i4.ScrollSyncService }, { token: i5.DisabledDatesService }, { token: i6.LocalizationService }, { token: i7.SelectionService }, { token: i8.PickerService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
1016
- CalendarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.3.12", type: CalendarComponent, selector: "kendo-calendar", inputs: { showOtherMonthDays: "showOtherMonthDays", id: "id", focusedDate: "focusedDate", min: "min", max: "max", rangeValidation: "rangeValidation", weekDaysFormat: "weekDaysFormat", footer: "footer", selection: "selection", value: "value", disabled: "disabled", tabindex: "tabindex", tabIndex: "tabIndex", disabledDates: "disabledDates", navigation: "navigation", activeView: "activeView", bottomView: "bottomView", topView: "topView", type: "type", animateNavigation: "animateNavigation", weekNumber: "weekNumber", cellTemplateRef: ["cellTemplate", "cellTemplateRef"], monthCellTemplateRef: ["monthCellTemplate", "monthCellTemplateRef"], yearCellTemplateRef: ["yearCellTemplate", "yearCellTemplateRef"], decadeCellTemplateRef: ["decadeCellTemplate", "decadeCellTemplateRef"], centuryCellTemplateRef: ["centuryCellTemplate", "centuryCellTemplateRef"], weekNumberTemplateRef: ["weekNumberTemplate", "weekNumberTemplateRef"], headerTitleTemplateRef: ["headerTitleTemplate", "headerTitleTemplateRef"], headerTemplateRef: ["headerTemplate", "headerTemplateRef"], footerTemplateRef: ["footerTemplate", "footerTemplateRef"], navigationItemTemplateRef: ["navigationItemTemplate", "navigationItemTemplateRef"], size: "size" }, outputs: { activeViewChange: "activeViewChange", navigate: "navigate", activeViewDateChange: "activeViewDateChange", onBlur: "blur", onFocus: "focus", valueChange: "valueChange" }, host: { properties: { "class.k-week-number": "this.weekNumber", "attr.id": "this.widgetId", "attr.aria-disabled": "this.ariaDisabled", "class.k-disabled": "this.ariaDisabled" } }, providers: [
1183
+ CalendarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CalendarComponent, deps: [{ token: i1.BusViewService }, { token: i2.CalendarDOMService }, { token: i0.ElementRef }, { token: i3.NavigationService }, { token: i0.Renderer2 }, { token: i0.ChangeDetectorRef }, { token: i0.NgZone }, { token: i0.Injector }, { token: i4.ScrollSyncService }, { token: i5.DisabledDatesService }, { token: i6.LocalizationService }, { token: i7.SelectionService }, { token: i8.PickerService, optional: true }], target: i0.ɵɵFactoryTarget.Component });
1184
+ CalendarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.10", type: CalendarComponent, selector: "kendo-calendar", inputs: { showOtherMonthDays: "showOtherMonthDays", id: "id", focusedDate: "focusedDate", min: "min", max: "max", rangeValidation: "rangeValidation", weekDaysFormat: "weekDaysFormat", footer: "footer", selection: "selection", allowReverse: "allowReverse", value: "value", disabled: "disabled", tabindex: "tabindex", tabIndex: "tabIndex", disabledDates: "disabledDates", navigation: "navigation", activeView: "activeView", bottomView: "bottomView", topView: "topView", type: "type", animateNavigation: "animateNavigation", weekNumber: "weekNumber", cellTemplateRef: ["cellTemplate", "cellTemplateRef"], monthCellTemplateRef: ["monthCellTemplate", "monthCellTemplateRef"], yearCellTemplateRef: ["yearCellTemplate", "yearCellTemplateRef"], decadeCellTemplateRef: ["decadeCellTemplate", "decadeCellTemplateRef"], centuryCellTemplateRef: ["centuryCellTemplate", "centuryCellTemplateRef"], weekNumberTemplateRef: ["weekNumberTemplate", "weekNumberTemplateRef"], headerTitleTemplateRef: ["headerTitleTemplate", "headerTitleTemplateRef"], headerTemplateRef: ["headerTemplate", "headerTemplateRef"], footerTemplateRef: ["footerTemplate", "footerTemplateRef"], navigationItemTemplateRef: ["navigationItemTemplate", "navigationItemTemplateRef"], size: "size", activeRangeEnd: "activeRangeEnd" }, outputs: { activeViewChange: "activeViewChange", navigate: "navigate", activeViewDateChange: "activeViewDateChange", onBlur: "blur", onFocus: "focus", valueChange: "valueChange" }, host: { properties: { "class.k-week-number": "this.weekNumber", "attr.id": "this.widgetId", "attr.aria-disabled": "this.ariaDisabled", "class.k-disabled": "this.ariaDisabled" } }, providers: [
1017
1185
  BusViewService,
1018
1186
  CALENDAR_VALUE_ACCESSOR,
1019
1187
  CALENDAR_RANGE_VALIDATORS,
@@ -1056,7 +1224,11 @@ CalendarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", vers
1056
1224
  </kendo-calendar-navigation>
1057
1225
  <kendo-calendar-viewlist
1058
1226
  [activeView]="activeViewEnum"
1227
+ [allowReverse]="allowReverse"
1059
1228
  [showOtherMonthDays]="showOtherMonthDays"
1229
+ [activeRangeEnd]="activeRangeEnd"
1230
+ [selectionRange]="selectionRange"
1231
+ [size]="size"
1060
1232
  [isActive]="isActive"
1061
1233
  [id]="headerId"
1062
1234
  [weekDaysFormat]="weekDaysFormat"
@@ -1084,6 +1256,7 @@ CalendarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", vers
1084
1256
  (pageChange)="onPageChange()"
1085
1257
  (focusCalendar)="handleFocus()"
1086
1258
  (blurCalendar)="handleBlur($event)"
1259
+ (cellEnter)="onCellEnter($event)"
1087
1260
  >
1088
1261
  </kendo-calendar-viewlist>
1089
1262
  <kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
@@ -1094,7 +1267,11 @@ CalendarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", vers
1094
1267
  [views]="1"
1095
1268
  [min]="min"
1096
1269
  [max]="max"
1270
+ [size]="size"
1097
1271
  [id]="id"
1272
+ [activeRangeEnd]="activeRangeEnd"
1273
+ [selectionRange]="selectionRange"
1274
+ [allowReverse]="allowReverse"
1098
1275
  [disabled]="disabled"
1099
1276
  [isActive]="isActive"
1100
1277
  [showOtherMonthDays]="showOtherMonthDays"
@@ -1136,8 +1313,8 @@ CalendarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", vers
1136
1313
  </kendo-multiviewcalendar-messages>
1137
1314
  </kendo-multiviewcalendar>
1138
1315
  </ng-container>
1139
- `, isInline: true, components: [{ type: i9.NavigationComponent, selector: "kendo-calendar-navigation", inputs: ["activeView", "min", "max", "focusedDate", "templateRef"], outputs: ["valueChange", "pageChange"] }, { type: i10.ViewListComponent, selector: "kendo-calendar-viewlist", inputs: ["cellTemplateRef", "weekNumberTemplateRef", "headerTitleTemplateRef", "headerTemplateRef", "footerTemplateRef", "showOtherMonthDays", "activeView", "cellUID", "focusedDate", "isActive", "min", "max", "selectedDates", "tabIndex", "disabled", "id", "showFooter", "weekDaysFormat", "weekNumber"], outputs: ["cellClick", "weekNumberCellClick", "activeDateChange", "todayButtonClick", "pageChange", "focusCalendar", "blurCalendar", "focusedCellChange"] }, { type: i11.ResizeSensorComponent, selector: "kendo-resize-sensor", inputs: ["rateLimit"], outputs: ["resize"] }, { type: i12.MultiViewCalendarComponent, selector: "kendo-multiviewcalendar", inputs: ["showOtherMonthDays", "showCalendarHeader", "id", "focusedDate", "footer", "min", "max", "rangeValidation", "disabledDatesRangeValidation", "selection", "value", "disabled", "tabindex", "tabIndex", "weekDaysFormat", "isActive", "disabledDates", "activeView", "bottomView", "topView", "showViewHeader", "animateNavigation", "weekNumber", "activeRangeEnd", "selectionRange", "views", "orientation", "cellTemplate", "monthCellTemplate", "yearCellTemplate", "decadeCellTemplate", "centuryCellTemplate", "weekNumberTemplate", "footerTemplate", "headerTitleTemplate", "headerTemplate"], outputs: ["activeViewChange", "navigate", "cellEnter", "cellLeave", "valueChange", "blur", "focus", "focusCalendar", "onClosePopup", "onTabPress", "onShiftTabPress"], exportAs: ["kendo-multiviewcalendar"] }, { type: i13.MultiViewCalendarCustomMessagesComponent, selector: "kendo-multiviewcalendar-messages" }], directives: [{ type: i14.CalendarLocalizedMessagesDirective, selector: "[kendoCalendarLocalizedMessages]" }, { type: i15.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1140
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CalendarComponent, decorators: [{
1316
+ `, isInline: true, dependencies: [{ kind: "directive", type: i9.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i10.MultiViewCalendarCustomMessagesComponent, selector: "kendo-multiviewcalendar-messages" }, { kind: "component", type: i11.MultiViewCalendarComponent, selector: "kendo-multiviewcalendar", inputs: ["showOtherMonthDays", "showCalendarHeader", "size", "id", "focusedDate", "footer", "min", "max", "rangeValidation", "disabledDatesRangeValidation", "selection", "allowReverse", "value", "disabled", "tabindex", "tabIndex", "weekDaysFormat", "isActive", "disabledDates", "activeView", "bottomView", "topView", "showViewHeader", "animateNavigation", "weekNumber", "activeRangeEnd", "selectionRange", "views", "orientation", "cellTemplate", "monthCellTemplate", "yearCellTemplate", "decadeCellTemplate", "centuryCellTemplate", "weekNumberTemplate", "footerTemplate", "headerTitleTemplate", "headerTemplate"], outputs: ["activeViewChange", "navigate", "cellEnter", "cellLeave", "valueChange", "rangeSelectionChange", "blur", "focus", "focusCalendar", "onClosePopup", "onTabPress", "onShiftTabPress"], exportAs: ["kendo-multiviewcalendar"] }, { kind: "component", type: i12.ResizeSensorComponent, selector: "kendo-resize-sensor", inputs: ["rateLimit"], outputs: ["resize"] }, { kind: "component", type: i13.NavigationComponent, selector: "kendo-calendar-navigation", inputs: ["activeView", "min", "max", "focusedDate", "templateRef"], outputs: ["valueChange", "pageChange"] }, { kind: "directive", type: i14.CalendarLocalizedMessagesDirective, selector: "[kendoCalendarLocalizedMessages]" }, { kind: "component", type: i15.ViewListComponent, selector: "kendo-calendar-viewlist", inputs: ["allowReverse", "cellTemplateRef", "weekNumberTemplateRef", "headerTitleTemplateRef", "headerTemplateRef", "footerTemplateRef", "showOtherMonthDays", "activeView", "cellUID", "focusedDate", "isActive", "min", "max", "selectedDates", "tabIndex", "disabled", "id", "showFooter", "weekDaysFormat", "activeRangeEnd", "selectionRange", "size", "weekNumber"], outputs: ["cellEnter", "cellClick", "weekNumberCellClick", "activeDateChange", "todayButtonClick", "pageChange", "focusCalendar", "blurCalendar", "focusedCellChange"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
1317
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CalendarComponent, decorators: [{
1141
1318
  type: Component,
1142
1319
  args: [{
1143
1320
  changeDetection: ChangeDetectionStrategy.OnPush,
@@ -1187,7 +1364,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
1187
1364
  </kendo-calendar-navigation>
1188
1365
  <kendo-calendar-viewlist
1189
1366
  [activeView]="activeViewEnum"
1367
+ [allowReverse]="allowReverse"
1190
1368
  [showOtherMonthDays]="showOtherMonthDays"
1369
+ [activeRangeEnd]="activeRangeEnd"
1370
+ [selectionRange]="selectionRange"
1371
+ [size]="size"
1191
1372
  [isActive]="isActive"
1192
1373
  [id]="headerId"
1193
1374
  [weekDaysFormat]="weekDaysFormat"
@@ -1215,6 +1396,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
1215
1396
  (pageChange)="onPageChange()"
1216
1397
  (focusCalendar)="handleFocus()"
1217
1398
  (blurCalendar)="handleBlur($event)"
1399
+ (cellEnter)="onCellEnter($event)"
1218
1400
  >
1219
1401
  </kendo-calendar-viewlist>
1220
1402
  <kendo-resize-sensor (resize)="onResize()"></kendo-resize-sensor>
@@ -1225,7 +1407,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
1225
1407
  [views]="1"
1226
1408
  [min]="min"
1227
1409
  [max]="max"
1410
+ [size]="size"
1228
1411
  [id]="id"
1412
+ [activeRangeEnd]="activeRangeEnd"
1413
+ [selectionRange]="selectionRange"
1414
+ [allowReverse]="allowReverse"
1229
1415
  [disabled]="disabled"
1230
1416
  [isActive]="isActive"
1231
1417
  [showOtherMonthDays]="showOtherMonthDays"
@@ -1289,6 +1475,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
1289
1475
  type: Input
1290
1476
  }], selection: [{
1291
1477
  type: Input
1478
+ }], allowReverse: [{
1479
+ type: Input
1292
1480
  }], value: [{
1293
1481
  type: Input
1294
1482
  }], disabled: [{
@@ -1392,6 +1580,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImpo
1392
1580
  args: ['navigationItemTemplate']
1393
1581
  }], size: [{
1394
1582
  type: Input
1583
+ }], activeRangeEnd: [{
1584
+ type: Input
1395
1585
  }], navigationView: [{
1396
1586
  type: ViewChild,
1397
1587
  args: [NavigationComponent, { static: false }]
@@ -64,8 +64,8 @@ import * as i0 from "@angular/core";
64
64
  */
65
65
  export class CalendarModule {
66
66
  }
67
- CalendarModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CalendarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
68
- CalendarModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CalendarModule, declarations: [CalendarComponent,
67
+ CalendarModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CalendarModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
68
+ CalendarModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "15.2.10", ngImport: i0, type: CalendarModule, declarations: [CalendarComponent,
69
69
  NavigationComponent,
70
70
  CalendarCustomMessagesComponent,
71
71
  CalendarLocalizedMessagesDirective,
@@ -83,25 +83,23 @@ CalendarModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version:
83
83
  ViewListComponent,
84
84
  CalendarCommonModule,
85
85
  TemplatesModule] });
86
- CalendarModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CalendarModule, providers: [
86
+ CalendarModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CalendarModule, providers: [
87
87
  CalendarDOMService,
88
88
  CenturyViewService,
89
89
  DecadeViewService,
90
90
  MonthViewService,
91
91
  YearViewService,
92
92
  WeekNamesService
93
- ], imports: [[
94
- CommonModule,
95
- CalendarCommonModule,
96
- MultiViewCalendarModule,
97
- IntlModule,
98
- TemplatesModule,
99
- VirtualizationModule,
100
- EventsModule,
101
- ResizeSensorModule
102
- ], CalendarCommonModule,
93
+ ], imports: [CommonModule,
94
+ CalendarCommonModule,
95
+ MultiViewCalendarModule,
96
+ IntlModule,
97
+ TemplatesModule,
98
+ VirtualizationModule,
99
+ EventsModule,
100
+ ResizeSensorModule, CalendarCommonModule,
103
101
  TemplatesModule] });
104
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.12", ngImport: i0, type: CalendarModule, decorators: [{
102
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.10", ngImport: i0, type: CalendarModule, decorators: [{
105
103
  type: NgModule,
106
104
  args: [{
107
105
  declarations: [