@progress/kendo-vue-dateinputs 3.6.4 → 3.7.0-dev.202210250731

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 (65) hide show
  1. package/dist/cdn/js/kendo-vue-dateinputs.js +1 -1
  2. package/dist/es/calendar/components/Calendar.js +17 -48
  3. package/dist/es/calendar/components/CalendarCell.js +16 -25
  4. package/dist/es/calendar/components/CalendarHeaderTitle.js +2 -4
  5. package/dist/es/calendar/components/CalendarWeekCell.js +0 -3
  6. package/dist/es/calendar/components/Header.js +6 -17
  7. package/dist/es/calendar/components/View.js +8 -19
  8. package/dist/es/calendar/components/ViewList.js +11 -14
  9. package/dist/es/common/PickerWrap.js +0 -2
  10. package/dist/es/dateinput/DateInput.js +33 -78
  11. package/dist/es/datepicker/DatePicker.js +32 -42
  12. package/dist/es/datepicker/ToggleButton.js +0 -2
  13. package/dist/es/datepicker/models/DatePickerSettings.js +2 -1
  14. package/dist/es/daterangepicker/DateRangePicker.js +10 -43
  15. package/dist/es/datetimepicker/DateTimePicker.js +39 -53
  16. package/dist/es/datetimepicker/DateTimeSelector.js +25 -36
  17. package/dist/es/package-metadata.js +1 -1
  18. package/dist/es/timepicker/TimeList.js +16 -46
  19. package/dist/es/timepicker/TimePart.js +7 -23
  20. package/dist/es/timepicker/TimePicker.js +37 -53
  21. package/dist/es/timepicker/TimeSelector.js +16 -23
  22. package/dist/es/virtualization/Virtualization.js +4 -36
  23. package/dist/esm/calendar/components/Calendar.js +17 -48
  24. package/dist/esm/calendar/components/CalendarCell.js +16 -25
  25. package/dist/esm/calendar/components/CalendarHeaderTitle.js +2 -4
  26. package/dist/esm/calendar/components/CalendarWeekCell.js +0 -3
  27. package/dist/esm/calendar/components/Header.js +6 -17
  28. package/dist/esm/calendar/components/View.js +8 -19
  29. package/dist/esm/calendar/components/ViewList.js +11 -14
  30. package/dist/esm/common/PickerWrap.js +0 -2
  31. package/dist/esm/dateinput/DateInput.js +33 -78
  32. package/dist/esm/datepicker/DatePicker.js +32 -42
  33. package/dist/esm/datepicker/ToggleButton.js +0 -2
  34. package/dist/esm/datepicker/models/DatePickerSettings.js +2 -1
  35. package/dist/esm/daterangepicker/DateRangePicker.js +10 -43
  36. package/dist/esm/datetimepicker/DateTimePicker.js +39 -53
  37. package/dist/esm/datetimepicker/DateTimeSelector.js +25 -36
  38. package/dist/esm/package-metadata.js +1 -1
  39. package/dist/esm/timepicker/TimeList.js +16 -46
  40. package/dist/esm/timepicker/TimePart.js +7 -23
  41. package/dist/esm/timepicker/TimePicker.js +37 -53
  42. package/dist/esm/timepicker/TimeSelector.js +16 -23
  43. package/dist/esm/virtualization/Virtualization.js +4 -36
  44. package/dist/npm/calendar/components/Calendar.js +17 -62
  45. package/dist/npm/calendar/components/CalendarCell.js +18 -30
  46. package/dist/npm/calendar/components/CalendarHeaderTitle.js +4 -10
  47. package/dist/npm/calendar/components/CalendarWeekCell.js +2 -8
  48. package/dist/npm/calendar/components/Header.js +8 -30
  49. package/dist/npm/calendar/components/View.js +10 -31
  50. package/dist/npm/calendar/components/ViewList.js +13 -25
  51. package/dist/npm/common/PickerWrap.js +2 -7
  52. package/dist/npm/dateinput/DateInput.js +35 -94
  53. package/dist/npm/datepicker/DatePicker.js +34 -58
  54. package/dist/npm/datepicker/ToggleButton.js +0 -4
  55. package/dist/npm/datepicker/models/DatePickerSettings.js +2 -1
  56. package/dist/npm/daterangepicker/DateRangePicker.js +10 -56
  57. package/dist/npm/datetimepicker/DateTimePicker.js +41 -71
  58. package/dist/npm/datetimepicker/DateTimeSelector.js +27 -50
  59. package/dist/npm/package-metadata.js +1 -1
  60. package/dist/npm/timepicker/TimeList.js +16 -55
  61. package/dist/npm/timepicker/TimePart.js +9 -36
  62. package/dist/npm/timepicker/TimePicker.js +37 -67
  63. package/dist/npm/timepicker/TimeSelector.js +18 -35
  64. package/dist/npm/virtualization/Virtualization.js +4 -40
  65. package/package.json +7 -7
@@ -15,7 +15,6 @@ var VIEWS_COUNT = 5;
15
15
  /**
16
16
  * @hidden
17
17
  */
18
-
19
18
  var ViewListVue2 = {
20
19
  name: 'KendoViewList',
21
20
  inheritAttrs: false,
@@ -105,14 +104,16 @@ var ViewListVue2 = {
105
104
  created: function created() {
106
105
  this.lastView = this.$props.activeView;
107
106
  this.lastFocus = this.$props.focusedDate;
108
- this.shouldScroll = false; // this.$data.skip = this.$props.service.skip(this.$props.focusedDate, this.$props.min);
107
+ this.shouldScroll = false;
108
+ // this.$data.skip = this.$props.service.skip(this.$props.focusedDate, this.$props.min);
109
109
  // this.$data.index = this.$props.service.skip(this.$props.focusedDate, this.$props.min);
110
110
  },
111
+
111
112
  updated: function updated() {
112
113
  this.shouldScroll = false;
113
114
  this.lastView = this.$props.activeView;
114
- this.$data.lastViewsCount = this.$props.views; // this.lastFocus = this.$props.focusedDate;
115
-
115
+ this.$data.lastViewsCount = this.$props.views;
116
+ // this.lastFocus = this.$props.focusedDate;
116
117
  this.indexToScroll = undefined;
117
118
  },
118
119
  methods: {
@@ -125,7 +126,8 @@ var ViewListVue2 = {
125
126
  handleKeyDown: function handleKeyDown(event) {
126
127
  this.$emit('listkeydown', event);
127
128
  },
128
- handleVirtualizationMount: function handleVirtualizationMount(_virtualization) {// this.virtualization = virtualization;
129
+ handleVirtualizationMount: function handleVirtualizationMount(_virtualization) {
130
+ // this.virtualization = virtualization;
129
131
  // if (this.virtualization && this.table) {
130
132
  // this.table.style.transform = `translateY(${this.viewOffset}px)`;
131
133
  // const viewDate = dateInRange(this.$props.focusedDate, this.$props.min, this.$props.max);
@@ -137,7 +139,6 @@ var ViewListVue2 = {
137
139
  if (!this.$props.dom) {
138
140
  return;
139
141
  }
140
-
141
142
  var scrollableHeight = this.$props.activeView === CalendarViewEnum.month ? this.$props.dom.scrollableContentHeight : this.$props.dom.scrollableYearContentHeight;
142
143
  this._bottomOffset = scrollableHeight - this.$props.dom.viewHeight(this.$props.activeView);
143
144
  this._viewOffset = -1 * this.$props.dom.headerHeight;
@@ -146,7 +147,8 @@ var ViewListVue2 = {
146
147
  getTake: function getTake(skip, total) {
147
148
  return Math.min(total - skip, this.$props.take);
148
149
  },
149
- handleScrollAction: function handleScrollAction() {// const skip = pageAction ? pageAction.skip : this.$data.skip;
150
+ handleScrollAction: function handleScrollAction() {
151
+ // const skip = pageAction ? pageAction.skip : this.$data.skip;
150
152
  // if (this.$data.index !== index || this.$data.skip !== skip) {
151
153
  // this.$data.index = skip;
152
154
  // }
@@ -171,7 +173,6 @@ var ViewListVue2 = {
171
173
  if (isTodayClick === void 0) {
172
174
  isTodayClick = false;
173
175
  }
174
-
175
176
  var args = {
176
177
  event: event.event,
177
178
  value: cloneDate(event.value),
@@ -197,7 +198,6 @@ var ViewListVue2 = {
197
198
  if (selectionRange.start === null || selectionRange.end === null) {
198
199
  return selectionRange;
199
200
  }
200
-
201
201
  var needRotate = selectionRange.end < selectionRange.start;
202
202
  return {
203
203
  start: needRotate ? selectionRange.end : selectionRange.start,
@@ -233,7 +233,6 @@ var ViewListVue2 = {
233
233
  'k-decade': this.$props.activeView === CalendarViewEnum.decade,
234
234
  'k-century': this.$props.activeView === CalendarViewEnum.century
235
235
  });
236
-
237
236
  var buildMonthView = function buildMonthView(weekNames) {
238
237
  var that = this;
239
238
  return h("thead", {
@@ -255,7 +254,6 @@ var ViewListVue2 = {
255
254
  }, [name]);
256
255
  }, this)])]);
257
256
  };
258
-
259
257
  var buildDates = function buildDates() {
260
258
  var cellUID = this.$props.cellUID;
261
259
  return this.$props.dates.map(function (vDate) {
@@ -277,7 +275,8 @@ var ViewListVue2 = {
277
275
  on: this.v3 ? undefined : {
278
276
  "keydown": this.handleKeyDown
279
277
  }
280
- }, [this.$props.activeView === CalendarViewEnum.month && buildMonthView.call(this, this.weekNames), // @ts-ignore function children
278
+ }, [this.$props.activeView === CalendarViewEnum.month && buildMonthView.call(this, this.weekNames),
279
+ // @ts-ignore function children
281
280
  h(View, {
282
281
  key: vDate.getTime(),
283
282
  activeView: this.$props.activeView,
@@ -323,7 +322,6 @@ var ViewListVue2 = {
323
322
  })]);
324
323
  }, this);
325
324
  };
326
-
327
325
  return h("div", {
328
326
  "class": rootClassNames,
329
327
  onFocusin: this.handleFocus,
@@ -338,6 +336,5 @@ var ViewListVue2 = {
338
336
  /**
339
337
  * @hidden
340
338
  */
341
-
342
339
  var ViewList = ViewListVue2;
343
340
  export { ViewList, ViewListVue2 };
@@ -7,7 +7,6 @@ import { getDefaultSlots } from '@progress/kendo-vue-common';
7
7
  /**
8
8
  * @hidden
9
9
  */
10
-
11
10
  var PickerWrapVue2 = {
12
11
  props: {
13
12
  id: String
@@ -35,6 +34,5 @@ var PickerWrapVue2 = {
35
34
  /**
36
35
  * @hidden
37
36
  */
38
-
39
37
  var PickerWrap = PickerWrapVue2;
40
38
  export { PickerWrap, PickerWrapVue2 };
@@ -21,7 +21,6 @@ var VALIDATION_MESSAGE = 'Please enter a valid value!';
21
21
  /**
22
22
  * @hidden
23
23
  */
24
-
25
24
  var DateInputVue2 = {
26
25
  name: 'DateInput',
27
26
  model: {
@@ -166,10 +165,10 @@ var DateInputVue2 = {
166
165
  created: function created() {
167
166
  validatePackage(packageMetadata);
168
167
  var _a = this.$props,
169
- formatPlaceholder = _a.formatPlaceholder,
170
- format = _a.format,
171
- value = _a.value,
172
- defaultValue = _a.defaultValue;
168
+ formatPlaceholder = _a.formatPlaceholder,
169
+ format = _a.format,
170
+ value = _a.value,
171
+ defaultValue = _a.defaultValue;
173
172
  this.kendoDate = new KendoDate(this.intl, formatPlaceholder, format);
174
173
  this.kendoDate.setValue(null);
175
174
  this._emptyText = this.kendoDate.getTextAndFormat().text;
@@ -183,20 +182,18 @@ var DateInputVue2 = {
183
182
  if (this.$data.valueDuringOnChange !== undefined) {
184
183
  return this.$data.valueDuringOnChange;
185
184
  }
186
-
187
185
  return this.kendoDate && this.kendoDate.getDateObject();
188
186
  }
189
187
  },
190
188
  wrapperClassNames: {
191
189
  get: function get() {
192
190
  var _a;
193
-
194
191
  var isValid = !this.$data.hasMounted || !this.$props.validityStyles || this.validity().valid;
195
192
  var disabled = this.$props.disabled;
196
193
  var _b = this.$props,
197
- size = _b.size,
198
- fillMode = _b.fillMode,
199
- rounded = _b.rounded;
194
+ size = _b.size,
195
+ fillMode = _b.fillMode,
196
+ rounded = _b.rounded;
200
197
  return _a = {
201
198
  'k-dateinput': true,
202
199
  'k-input': true
@@ -211,14 +208,12 @@ var DateInputVue2 = {
211
208
  end: 0
212
209
  };
213
210
  var element = this.element();
214
-
215
211
  if (element !== null && element.selectionStart !== undefined) {
216
212
  returnValue = {
217
213
  start: element.selectionStart,
218
214
  end: element.selectionEnd
219
215
  };
220
216
  }
221
-
222
217
  return returnValue;
223
218
  },
224
219
  element: function element() {
@@ -242,7 +237,6 @@ var DateInputVue2 = {
242
237
  },
243
238
  setValidity: function setValidity() {
244
239
  var element = this.element();
245
-
246
240
  if (element && element.setCustomValidity) {
247
241
  element.setCustomValidity(this.validity().valid ? '' : this.$props.validationMessage);
248
242
  }
@@ -250,10 +244,8 @@ var DateInputVue2 = {
250
244
  spinnersMouseDown: function spinnersMouseDown(event) {
251
245
  var element = this.element();
252
246
  /* do not steal focus from input when changing value with spinners */
253
-
254
247
  event.preventDefault();
255
248
  /* manually focus the input in case the user clicks the spinners first */
256
-
257
249
  if (element && canUseDOM && document.activeElement !== element) {
258
250
  element.focus({
259
251
  preventScroll: true
@@ -262,34 +254,27 @@ var DateInputVue2 = {
262
254
  },
263
255
  elementChange: function elementChange(event) {
264
256
  var element = this.element();
265
-
266
257
  if (!element || !this.kendoDate) {
267
258
  return;
268
259
  }
269
-
270
260
  var _a = this.kendoDate.getTextAndFormat(),
271
- text = _a.text,
272
- currentFormat = _a.format;
273
-
261
+ text = _a.text,
262
+ currentFormat = _a.format;
274
263
  this.$data.currentFormat = currentFormat;
275
264
  var dateBeforeChange = this.computedValue;
276
265
  var diff = approximateStringMatching(text, this.$data.currentFormat, element.value, this.selection().start);
277
266
  var navigationOnly = diff.length === 1 && diff[0][1] === '_';
278
-
279
267
  if (!navigationOnly) {
280
268
  for (var i = 0; i < diff.length; i++) {
281
269
  this.kendoDate.parsePart(diff[i][0], diff[i][1]);
282
270
  }
283
271
  }
284
-
285
272
  if (diff.length && diff[0][0] !== '_') {
286
273
  this.setSelection(this.selectionBySymbol(diff[0][0]));
287
274
  }
288
-
289
275
  if (navigationOnly) {
290
276
  this.switchDateSegment(1);
291
277
  }
292
-
293
278
  this.triggerChange(event, dateBeforeChange);
294
279
  },
295
280
  elementClick: function elementClick(_) {
@@ -297,16 +282,13 @@ var DateInputVue2 = {
297
282
  },
298
283
  wheel: function wheel(event) {
299
284
  var element = this.element();
300
-
301
285
  if (canUseDOM && document.activeElement !== element) {
302
286
  return;
303
287
  }
304
-
305
288
  if (event.deltaY < 0) {
306
289
  event.preventDefault();
307
290
  this.increasePart(event);
308
291
  }
309
-
310
292
  if (event.deltaY > 0) {
311
293
  event.preventDefault();
312
294
  this.decreasePart(event);
@@ -324,7 +306,6 @@ var DateInputVue2 = {
324
306
  if (event.altKey) {
325
307
  return;
326
308
  }
327
-
328
309
  switch (event.keyCode) {
329
310
  case 37:
330
311
  /*
@@ -334,7 +315,6 @@ var DateInputVue2 = {
334
315
  */
335
316
  this.switchDateSegment(-1);
336
317
  break;
337
-
338
318
  case 38:
339
319
  /*
340
320
  * Key: `Up Arrow`
@@ -342,7 +322,6 @@ var DateInputVue2 = {
342
322
  */
343
323
  this.modifyDateSegmentValue(1, event);
344
324
  break;
345
-
346
325
  case 39:
347
326
  /*
348
327
  * Key: `Right Arrow`
@@ -350,7 +329,6 @@ var DateInputVue2 = {
350
329
  */
351
330
  this.switchDateSegment(1);
352
331
  break;
353
-
354
332
  case 40:
355
333
  /*
356
334
  * Key: `Down Arrow`
@@ -358,7 +336,6 @@ var DateInputVue2 = {
358
336
  */
359
337
  this.modifyDateSegmentValue(-1, event);
360
338
  break;
361
-
362
339
  default:
363
340
  /*
364
341
  * Key: any
@@ -366,7 +343,6 @@ var DateInputVue2 = {
366
343
  */
367
344
  return;
368
345
  }
369
-
370
346
  event.preventDefault();
371
347
  },
372
348
  setSelection: function setSelection(selection) {
@@ -380,11 +356,10 @@ var DateInputVue2 = {
380
356
  },
381
357
  triggerChange: function triggerChange(event, oldValue) {
382
358
  this.$data.valueDuringOnChange = this.computedValue;
383
-
384
359
  if (!isEqual(oldValue, this.computedValue)) {
385
360
  this.$emit('changemodel', this.computedValue);
386
- this.$emit('update:modelValue', this.computedValue); // isEqual works with null
387
-
361
+ this.$emit('update:modelValue', this.computedValue);
362
+ // isEqual works with null
388
363
  this.$emit('change', {
389
364
  event: event,
390
365
  value: this.computedValue,
@@ -397,27 +372,22 @@ var DateInputVue2 = {
397
372
  validity: this.validity()
398
373
  });
399
374
  }
400
-
401
375
  this.$data.valueDuringOnChange = undefined;
402
376
  },
403
377
  selectionBySymbol: function selectionBySymbol(symbol) {
404
378
  var start = -1;
405
379
  var end = 0;
406
-
407
380
  for (var i = 0; i < this.$data.currentFormat.length; i++) {
408
381
  if (this.$data.currentFormat[i] === symbol) {
409
382
  end = i + 1;
410
-
411
383
  if (start === -1) {
412
384
  start = i;
413
385
  }
414
386
  }
415
387
  }
416
-
417
388
  if (start < 0) {
418
389
  start = 0;
419
390
  }
420
-
421
391
  return {
422
392
  start: start,
423
393
  end: end
@@ -428,57 +398,45 @@ var DateInputVue2 = {
428
398
  start: index,
429
399
  end: index
430
400
  };
431
-
432
401
  for (var i = index, j = index - 1; i < this.$data.currentFormat.length || j >= 0; i++, j--) {
433
402
  if (i < this.$data.currentFormat.length && this.$data.currentFormat[i] !== '_') {
434
403
  selection = this.selectionBySymbol(this.$data.currentFormat[i]);
435
404
  break;
436
405
  }
437
-
438
406
  if (j >= 0 && this.$data.currentFormat[j] !== '_') {
439
407
  selection = this.selectionBySymbol(this.$data.currentFormat[j]);
440
408
  break;
441
409
  }
442
410
  }
443
-
444
411
  return selection;
445
412
  },
446
413
  switchDateSegment: function switchDateSegment(offset) {
447
414
  var _a = this.selection(),
448
- selectionStart = _a.start,
449
- selectionEnd = _a.end;
450
-
415
+ selectionStart = _a.start,
416
+ selectionEnd = _a.end;
451
417
  if (selectionStart < selectionEnd && this.$data.currentFormat[selectionStart] !== this.$data.currentFormat[selectionEnd - 1]) {
452
418
  this.setSelection(this.selectionByIndex(offset > 0 ? selectionStart : selectionEnd - 1));
453
419
  return;
454
420
  }
455
-
456
421
  var previousFormatSymbol = this.$data.currentFormat[selectionStart];
457
422
  var a = selectionStart + offset;
458
-
459
423
  while (a > 0 && a < this.$data.currentFormat.length) {
460
424
  if (this.$data.currentFormat[a] !== previousFormatSymbol && this.$data.currentFormat[a] !== '_') {
461
425
  break;
462
426
  }
463
-
464
427
  a += offset;
465
428
  }
466
-
467
429
  if (this.$data.currentFormat[a] === '_') {
468
430
  // no known symbol is found
469
431
  return;
470
432
  }
471
-
472
433
  var b = a;
473
-
474
434
  while (b >= 0 && b < this.$data.currentFormat.length) {
475
435
  if (this.$data.currentFormat[b] !== this.$data.currentFormat[a]) {
476
436
  break;
477
437
  }
478
-
479
438
  b += offset;
480
439
  }
481
-
482
440
  if (a > b && (b + 1 !== selectionStart || a + 1 !== selectionEnd)) {
483
441
  this.setSelection({
484
442
  start: b + 1,
@@ -495,7 +453,6 @@ var DateInputVue2 = {
495
453
  if (!this.kendoDate) {
496
454
  return;
497
455
  }
498
-
499
456
  var oldValue = this.computedValue;
500
457
  var symbol = this.$data.currentFormat[this.selection().start];
501
458
  var currentStepSymbol = this.kendoDate.symbolMap(symbol);
@@ -527,7 +484,6 @@ var DateInputVue2 = {
527
484
  if (this.$data.lastSelectedSymbol) {
528
485
  this.setSelection(this.selectionBySymbol(this.$data.lastSelectedSymbol));
529
486
  }
530
-
531
487
  this.setValidity();
532
488
  },
533
489
  // @ts-ignore
@@ -549,30 +505,27 @@ var DateInputVue2 = {
549
505
  var defaultSlot = getDefaultSlots(this);
550
506
  var localizationService = provideLocalizationService(this);
551
507
  var _a = this.$props,
552
- formatPlaceholder = _a.formatPlaceholder,
553
- format = _a.format,
554
- value = _a.value,
555
- modelValue = _a.modelValue,
556
- name = _a.name,
557
- label = _a.label,
558
- id = _a.id,
559
- ariaLabel = _a.ariaLabel,
560
- ariaExpanded = _a.ariaExpanded,
561
- ariaHasPopup = _a.ariaHasPopup,
562
- ariaRole = _a.ariaRole,
563
- ariaControls = _a.ariaControls;
508
+ formatPlaceholder = _a.formatPlaceholder,
509
+ format = _a.format,
510
+ value = _a.value,
511
+ modelValue = _a.modelValue,
512
+ name = _a.name,
513
+ label = _a.label,
514
+ id = _a.id,
515
+ ariaLabel = _a.ariaLabel,
516
+ ariaExpanded = _a.ariaExpanded,
517
+ ariaHasPopup = _a.ariaHasPopup,
518
+ ariaRole = _a.ariaRole,
519
+ ariaControls = _a.ariaControls;
564
520
  this.kendoDate.format = format;
565
521
  this.kendoDate.formatPlaceholder = formatPlaceholder;
566
522
  var currentValue = value !== undefined ? value : modelValue;
567
-
568
523
  if (currentValue !== undefined && this.computedValue !== currentValue) {
569
524
  this.kendoDate.setValue(currentValue);
570
525
  }
571
-
572
526
  var _b = this.kendoDate.getTextAndFormat(),
573
- currentText = _b.text,
574
- currentFormat = _b.format;
575
-
527
+ currentText = _b.text,
528
+ currentFormat = _b.format;
576
529
  this.$data.currentFormat = currentFormat;
577
530
  this.$data.isEmpty = currentText === this._emptyText;
578
531
  var showPlaceHolder = this.$props.placeholder !== undefined && this.$data.isEmpty && !this.$data.isFocused;
@@ -646,7 +599,8 @@ var DateInputVue2 = {
646
599
  on: this.v3 ? undefined : {
647
600
  "mousedown": this.spinnersMouseDown
648
601
  }
649
- }, [// @ts-ignore
602
+ }, [
603
+ // @ts-ignore
650
604
  h(KButton, {
651
605
  type: "button",
652
606
  attrs: this.v3 ? undefined : {
@@ -669,7 +623,8 @@ var DateInputVue2 = {
669
623
  on: this.v3 ? undefined : {
670
624
  "click": this.increasePart
671
625
  }
672
- }), // @ts-ignore
626
+ }),
627
+ // @ts-ignore
673
628
  h(KButton, {
674
629
  type: "button",
675
630
  attrs: this.v3 ? undefined : {
@@ -693,7 +648,8 @@ var DateInputVue2 = {
693
648
  "click": this.decreasePart
694
649
  }
695
650
  })])]);
696
- return label ? // @ts-ignore function children
651
+ return label ?
652
+ // @ts-ignore function children
697
653
  h(FloatingLabel, {
698
654
  label: label,
699
655
  attrs: this.v3 ? undefined : {
@@ -717,6 +673,5 @@ var DateInputVue2 = {
717
673
  /**
718
674
  * @hidden
719
675
  */
720
-
721
676
  var DateInput = DateInputVue2;
722
677
  export { DateInput, DateInputVue2 };
@@ -20,7 +20,6 @@ import { FloatingLabel } from '@progress/kendo-vue-labels';
20
20
  /**
21
21
  * @hidden
22
22
  */
23
-
24
23
  var DatePickerVue2 = {
25
24
  name: 'DatePicker',
26
25
  inject: {
@@ -183,11 +182,9 @@ var DatePickerVue2 = {
183
182
  },
184
183
  mounted: function mounted() {
185
184
  this._dateInput = getRef(this, 'dateInput');
186
-
187
185
  if (this.$refs.calendar || this.calendarRef) {
188
186
  this._calendar = getRef(this, 'calendar');
189
187
  }
190
-
191
188
  if (this.computedShow) {
192
189
  // If defaultShow is true during the initial render, the popup is not aligned.
193
190
  this.$forceUpdate();
@@ -197,7 +194,6 @@ var DatePickerVue2 = {
197
194
  if (this.$refs.calendar || this.calendarRef) {
198
195
  this._calendar = getRef(this, 'calendar');
199
196
  }
200
-
201
197
  if (this.computedShow) {
202
198
  if (this._calendar && this._calendar.$el && !this._oldShow) {
203
199
  this._calendar.focus({
@@ -211,7 +207,6 @@ var DatePickerVue2 = {
211
207
  });
212
208
  }
213
209
  }
214
-
215
210
  this.$data.shouldFocusDateInput = false;
216
211
  },
217
212
  watch: {
@@ -262,7 +257,6 @@ var DatePickerVue2 = {
262
257
  },
263
258
  createBlurTimeout: function createBlurTimeout() {
264
259
  var _this = this;
265
-
266
260
  this._blurTimeout = setTimeout(function () {
267
261
  if (_this._dateInput && canUseDOM && document.activeElement !== _this._dateInput._element) {
268
262
  _this.setShow(false);
@@ -293,7 +287,6 @@ var DatePickerVue2 = {
293
287
  if (this.computedShow === show) {
294
288
  return;
295
289
  }
296
-
297
290
  this.$data.currentShow = show;
298
291
  },
299
292
  mergeTime: function mergeTime(value) {
@@ -335,11 +328,9 @@ var DatePickerVue2 = {
335
328
  handleIconClick: function handleIconClick(event) {
336
329
  event.stopPropagation();
337
330
  event.preventDefault();
338
-
339
331
  if (this.$props.disabled) {
340
332
  return;
341
333
  }
342
-
343
334
  this.$data.shouldFocusDateInput = true;
344
335
  this.setShow(!this.computedShow);
345
336
  this.$emit('iconclick', event);
@@ -350,28 +341,24 @@ var DatePickerVue2 = {
350
341
  },
351
342
  handleKeyDown: function handleKeyDown(event) {
352
343
  var altKey = event.altKey,
353
- keyCode = event.keyCode;
354
-
344
+ keyCode = event.keyCode;
355
345
  if (keyCode === Keys.tab && this._dateInput && event.target !== this._dateInput._element) {
356
346
  event.preventDefault();
357
347
  this.$data.shouldFocusDateInput = true;
358
348
  this.setShow(false);
359
349
  return;
360
350
  }
361
-
362
351
  if (keyCode === Keys.esc) {
363
352
  this.$data.shouldFocusDateInput = true;
364
353
  this.setShow(false);
365
354
  return;
366
355
  }
367
-
368
356
  if (altKey && (keyCode === Keys.up || keyCode === Keys.down)) {
369
357
  event.preventDefault();
370
358
  event.stopPropagation();
371
359
  this.$data.shouldFocusDateInput = keyCode === Keys.up;
372
360
  this.setShow(keyCode === Keys.down);
373
361
  }
374
-
375
362
  this.$emit('keydown', event);
376
363
  }
377
364
  },
@@ -391,39 +378,39 @@ var DatePickerVue2 = {
391
378
  // @ts-ignore
392
379
  render: function render(createElement) {
393
380
  var _a;
394
-
395
381
  var h = gh || createElement;
396
382
  var defaultSlot = getDefaultSlots(this);
397
383
  var _b = this.$props,
398
- disabled = _b.disabled,
399
- tabIndex = _b.tabIndex,
400
- title = _b.title,
401
- id = _b.id,
402
- format = _b.format,
403
- formatPlaceholder = _b.formatPlaceholder,
404
- min = _b.min,
405
- max = _b.max,
406
- weekNumber = _b.weekNumber,
407
- focusedDate = _b.focusedDate,
408
- width = _b.width,
409
- name = _b.name,
410
- validationMessage = _b.validationMessage,
411
- required = _b.required,
412
- validityStyles = _b.validityStyles,
413
- size = _b.size,
414
- fillMode = _b.fillMode,
415
- rounded = _b.rounded;
384
+ disabled = _b.disabled,
385
+ tabIndex = _b.tabIndex,
386
+ title = _b.title,
387
+ id = _b.id,
388
+ format = _b.format,
389
+ formatPlaceholder = _b.formatPlaceholder,
390
+ min = _b.min,
391
+ max = _b.max,
392
+ weekNumber = _b.weekNumber,
393
+ focusedDate = _b.focusedDate,
394
+ width = _b.width,
395
+ name = _b.name,
396
+ validationMessage = _b.validationMessage,
397
+ required = _b.required,
398
+ validityStyles = _b.validityStyles,
399
+ size = _b.size,
400
+ fillMode = _b.fillMode,
401
+ rounded = _b.rounded;
416
402
  var _c = this.$props.popupSettings,
417
- popupClass = _c.popupClass,
418
- animate = _c.animate,
419
- appendTo = _c.appendTo;
403
+ popupClass = _c.popupClass,
404
+ animate = _c.animate,
405
+ appendTo = _c.appendTo;
420
406
  var show = this.computedShow;
421
407
  var value = this.computedValue;
422
408
  var sanitizedValue = value && getDate(value);
423
409
  var isValid = !this.$props.validityStyles || this.validity().valid;
424
410
  var popupClassNames = classNames('k-calendar-container k-group k-reset', popupClass);
425
411
  var toggleButton = this.$props.toggleButton ? templateRendering.call(this, this.$props.toggleButton, getListeners.call(this)) : undefined;
426
- var toggleButtonDefaultRendering = // @ts-ignore
412
+ var toggleButtonDefaultRendering =
413
+ // @ts-ignore
427
414
  h(ToggleButton, {
428
415
  type: "button",
429
416
  attrs: this.v3 ? undefined : {
@@ -459,7 +446,8 @@ var DatePickerVue2 = {
459
446
  }
460
447
  });
461
448
  var dateInput = this.$props.dateInput ? templateRendering.call(this, this.$props.dateInput, getListeners.call(this)) : undefined;
462
- var dateInputDefaultRendering = // @ts-ignore
449
+ var dateInputDefaultRendering =
450
+ // @ts-ignore
463
451
  h(DateInput, {
464
452
  ref: setRef(this, 'dateInput'),
465
453
  placeholder: this.$props.placeholder,
@@ -519,7 +507,8 @@ var DatePickerVue2 = {
519
507
  defaultRendering: dateInputDefaultRendering
520
508
  });
521
509
  var calendar = this.$props.calendar ? templateRendering.call(this, this.$props.calendar, getListeners.call(this)) : undefined;
522
- var calendarDefaultRendering = // @ts-ignore
510
+ var calendarDefaultRendering =
511
+ // @ts-ignore
523
512
  h(Calendar, {
524
513
  ref: setRef(this, 'calendar'),
525
514
  onKeydown: this.handleKeyDown,
@@ -553,7 +542,8 @@ var DatePickerVue2 = {
553
542
  defaultRendering: calendarDefaultRendering
554
543
  });
555
544
  var popup = this.$props.popup ? templateRendering.call(this, this.$props.popup, getListeners.call(this)) : undefined;
556
- var popupDefaultRendering = // @ts-ignore function children
545
+ var popupDefaultRendering =
546
+ // @ts-ignore function children
557
547
  h(Popup, {
558
548
  show: show,
559
549
  attrs: this.v3 ? undefined : {
@@ -609,7 +599,8 @@ var DatePickerVue2 = {
609
599
  onFocusin: this.handleFocus,
610
600
  onFocusout: this.handleBlur
611
601
  }, [dateInputRendering, toggleButtonRendering, popupRendering]);
612
- return this.$props.label ? // @ts-ignore function children
602
+ return this.$props.label ?
603
+ // @ts-ignore function children
613
604
  h(FloatingLabel, {
614
605
  label: this.$props.label,
615
606
  attrs: this.v3 ? undefined : {
@@ -636,6 +627,5 @@ var DatePickerVue2 = {
636
627
  /**
637
628
  * @hidden
638
629
  */
639
-
640
630
  var DatePicker = DatePickerVue2;
641
631
  export { DatePicker, DatePickerVue2 };