@progress/kendo-vue-scheduler 3.1.0-dev.202203011833 → 3.1.1

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 (108) hide show
  1. package/dist/cdn/js/kendo-vue-scheduler.js +2 -2
  2. package/dist/es/Scheduler.d.ts +1 -1
  3. package/dist/es/Scheduler.js +129 -683
  4. package/dist/es/components/ShowMoreItemsButton.js +1 -2
  5. package/dist/es/components/footer/bussiness-hours/{BussinessHours.d.ts → BusinessHours.d.ts} +1 -0
  6. package/dist/es/components/footer/bussiness-hours/BusinessHours.js +88 -0
  7. package/dist/es/components/header/navigation/NavigationDatePicker.js +2 -3
  8. package/dist/es/components/header/navigation/SchedulerNavigation.js +319 -3
  9. package/dist/es/components/header/view-selector/SchedulerViewSelector.js +4 -3
  10. package/dist/es/components/header/view-selector/ViewSelectorItem.js +5 -7
  11. package/dist/es/components/header/view-selector/ViewSelectorList.js +19 -13
  12. package/dist/es/context/SchedulerResourceIteratorContext.js +2 -2
  13. package/dist/es/items/SchedulerEditItem.js +10 -9
  14. package/dist/es/items/SchedulerItem.d.ts +2 -0
  15. package/dist/es/items/SchedulerItem.js +111 -29
  16. package/dist/es/items/SchedulerViewItem.js +80 -92
  17. package/dist/es/main.d.ts +5 -1
  18. package/dist/es/main.js +5 -11
  19. package/dist/es/package-metadata.js +1 -1
  20. package/dist/es/slots/SchedulerEditSlot.js +23 -9
  21. package/dist/es/slots/SchedulerSlot.d.ts +4 -0
  22. package/dist/es/slots/SchedulerSlot.js +96 -21
  23. package/dist/es/slots/SchedulerViewSlot.d.ts +1 -1
  24. package/dist/es/slots/SchedulerViewSlot.js +53 -30
  25. package/dist/es/tasks/SchedulerEditTask.js +56 -49
  26. package/dist/es/tasks/SchedulerTask.js +57 -4
  27. package/dist/es/tasks/SchedulerViewTask.js +17 -22
  28. package/dist/es/views/agenda/AgendaView.js +18 -9
  29. package/dist/es/views/agenda/AgendaViewBody.d.ts +1 -0
  30. package/dist/es/views/agenda/AgendaViewBody.js +2 -1
  31. package/dist/es/views/common/VerticalResourceIterator.d.ts +1 -0
  32. package/dist/es/views/common/VerticalResourceIterator.js +104 -17
  33. package/dist/es/views/day/DayView.js +9 -3
  34. package/dist/es/views/day/DayViewAllDaySlots.d.ts +1 -0
  35. package/dist/es/views/day/DayViewAllDaySlots.js +3 -2
  36. package/dist/es/views/day/DayViewMiddleRow.js +12 -9
  37. package/dist/es/views/day/DayViewVerticalRow.d.ts +41 -0
  38. package/dist/es/views/day/DayViewVerticalRow.js +101 -0
  39. package/dist/es/views/day/DayViewVerticalSlotsRow.d.ts +50 -0
  40. package/dist/es/views/day/DayViewVerticalSlotsRow.js +132 -0
  41. package/dist/es/views/day/MultiDayView.d.ts +1 -1
  42. package/dist/es/views/day/MultiDayView.js +167 -284
  43. package/dist/es/views/month/MonthView.d.ts +1 -1
  44. package/dist/es/views/month/MonthView.js +56 -65
  45. package/dist/es/views/month/MonthViewBody.d.ts +2 -0
  46. package/dist/es/views/month/MonthViewBody.js +36 -51
  47. package/dist/es/views/time/MultiDayTimelineView.d.ts +2 -2
  48. package/dist/es/views/time/MultiDayTimelineView.js +52 -41
  49. package/dist/es/views/time/TimelineView.js +9 -3
  50. package/dist/es/views/time/TimelineViewBody.d.ts +2 -0
  51. package/dist/es/views/time/TimelineViewBody.js +6 -2
  52. package/dist/es/views/week/WeekView.js +9 -3
  53. package/dist/es/views/week/WorkWeekView.js +9 -3
  54. package/dist/npm/Scheduler.d.ts +1 -1
  55. package/dist/npm/Scheduler.js +127 -683
  56. package/dist/npm/components/ShowMoreItemsButton.js +1 -2
  57. package/dist/npm/components/footer/bussiness-hours/{BussinessHours.d.ts → BusinessHours.d.ts} +1 -0
  58. package/dist/npm/components/footer/bussiness-hours/BusinessHours.js +102 -0
  59. package/dist/npm/components/header/navigation/NavigationDatePicker.js +2 -3
  60. package/dist/npm/components/header/navigation/SchedulerNavigation.js +323 -4
  61. package/dist/npm/components/header/view-selector/SchedulerViewSelector.js +5 -3
  62. package/dist/npm/components/header/view-selector/ViewSelectorItem.js +6 -7
  63. package/dist/npm/components/header/view-selector/ViewSelectorList.js +21 -13
  64. package/dist/npm/context/SchedulerResourceIteratorContext.js +2 -2
  65. package/dist/npm/items/SchedulerEditItem.js +10 -9
  66. package/dist/npm/items/SchedulerItem.d.ts +2 -0
  67. package/dist/npm/items/SchedulerItem.js +111 -29
  68. package/dist/npm/items/SchedulerViewItem.js +81 -92
  69. package/dist/npm/main.d.ts +5 -1
  70. package/dist/npm/main.js +9 -11
  71. package/dist/npm/package-metadata.js +1 -1
  72. package/dist/npm/slots/SchedulerEditSlot.js +23 -9
  73. package/dist/npm/slots/SchedulerSlot.d.ts +4 -0
  74. package/dist/npm/slots/SchedulerSlot.js +96 -20
  75. package/dist/npm/slots/SchedulerViewSlot.d.ts +1 -1
  76. package/dist/npm/slots/SchedulerViewSlot.js +52 -29
  77. package/dist/npm/tasks/SchedulerEditTask.js +57 -49
  78. package/dist/npm/tasks/SchedulerTask.js +57 -3
  79. package/dist/npm/tasks/SchedulerViewTask.js +17 -21
  80. package/dist/npm/views/agenda/AgendaView.js +18 -9
  81. package/dist/npm/views/agenda/AgendaViewBody.d.ts +1 -0
  82. package/dist/npm/views/agenda/AgendaViewBody.js +2 -1
  83. package/dist/npm/views/common/VerticalResourceIterator.d.ts +1 -0
  84. package/dist/npm/views/common/VerticalResourceIterator.js +107 -17
  85. package/dist/npm/views/day/DayView.js +9 -3
  86. package/dist/npm/views/day/DayViewAllDaySlots.d.ts +1 -0
  87. package/dist/npm/views/day/DayViewAllDaySlots.js +3 -2
  88. package/dist/npm/views/day/DayViewMiddleRow.js +12 -9
  89. package/dist/npm/views/day/DayViewVerticalRow.d.ts +41 -0
  90. package/dist/npm/views/day/DayViewVerticalRow.js +113 -0
  91. package/dist/npm/views/day/DayViewVerticalSlotsRow.d.ts +50 -0
  92. package/dist/npm/views/day/DayViewVerticalSlotsRow.js +145 -0
  93. package/dist/npm/views/day/MultiDayView.d.ts +1 -1
  94. package/dist/npm/views/day/MultiDayView.js +168 -285
  95. package/dist/npm/views/month/MonthView.d.ts +1 -1
  96. package/dist/npm/views/month/MonthView.js +56 -65
  97. package/dist/npm/views/month/MonthViewBody.d.ts +2 -0
  98. package/dist/npm/views/month/MonthViewBody.js +36 -52
  99. package/dist/npm/views/time/MultiDayTimelineView.d.ts +2 -2
  100. package/dist/npm/views/time/MultiDayTimelineView.js +52 -41
  101. package/dist/npm/views/time/TimelineView.js +9 -3
  102. package/dist/npm/views/time/TimelineViewBody.d.ts +2 -0
  103. package/dist/npm/views/time/TimelineViewBody.js +6 -2
  104. package/dist/npm/views/week/WeekView.js +9 -3
  105. package/dist/npm/views/week/WorkWeekView.js +9 -3
  106. package/package.json +12 -12
  107. package/dist/es/components/footer/bussiness-hours/BussinessHours.js +0 -33
  108. package/dist/npm/components/footer/bussiness-hours/BussinessHours.js +0 -44
@@ -33,18 +33,16 @@ import * as Vue from 'vue';
33
33
  var allVue = Vue;
34
34
  var gh = allVue.h;
35
35
  import { getModelFields, getField, findMaster, setField, toSchedulerGroups, getToday } from './utils';
36
- import { clone, getListeners, templateRendering } from '@progress/kendo-vue-common';
36
+ import { clone, getListeners, getTemplate, templateRendering } from '@progress/kendo-vue-common';
37
37
  import { provideIntlService, provideLocalizationService } from '@progress/kendo-vue-intl';
38
38
  import { SchedulerHeader } from './components/header/SchedulerHeader';
39
39
  import { SchedulerNavigation } from './components/header/navigation/SchedulerNavigation';
40
40
  import { SchedulerViewSelector } from './components/header/view-selector/SchedulerViewSelector';
41
41
  import { addDays, addMonths } from '@progress/kendo-date-math';
42
42
  import { SchedulerFooter } from './components/footer/SchedulerFooter';
43
- import { Button, ToolbarSpacer, ButtonGroup } from '@progress/kendo-vue-buttons';
44
- import { showFullDay, showWorkDay, messages, today, previousTitle, nextTitle } from './messages';
43
+ import { ToolbarSpacer } from '@progress/kendo-vue-buttons';
45
44
  import { NavigationDatePicker } from './components/header/navigation/NavigationDatePicker';
46
- import { ViewSelectorList } from './components/header/view-selector/ViewSelectorList';
47
- import { BusinessHours } from './components/footer/bussiness-hours/BussinessHours';
45
+ import { BusinessHours } from './components/footer/bussiness-hours/BusinessHours';
48
46
  import { DayView } from './views/day/DayView'; // import { SchedulerFormProps } from './editors/SchedulerFormEditor';
49
47
 
50
48
  import { validatePackage } from '@progress/kendo-vue-common';
@@ -106,7 +104,10 @@ var SchedulerVue2 = {
106
104
  default: new Date()
107
105
  },
108
106
  header: [String, Function, Object],
109
- footer: [String, Function, Object]
107
+ footer: [String, Function, Object],
108
+ slotRender: [String, Function, Object],
109
+ item: [String, Function, Object],
110
+ task: [String, Function, Object]
110
111
  },
111
112
  computed: {
112
113
  wrapperClassName: function wrapperClassName() {
@@ -126,7 +127,13 @@ var SchedulerVue2 = {
126
127
  return {
127
128
  ks: this.ks,
128
129
  setActiveViewName: this.handleActiveViewNameChange,
129
- setActiveDate: this.handleDateChange
130
+ setActiveDate: this.handleDateChange,
131
+ itemDoubleClick: this.handleItemDoubleClick,
132
+ itemClick: this.handleItemClick,
133
+ slotDoubleClick: this.handleSlotDoubleClick,
134
+ slotClick: this.handleSlotClick,
135
+ taskDoubleClick: this.handleTaskDoubleClick,
136
+ taskClick: this.handleTaskClick
130
137
  };
131
138
  },
132
139
  data: function data() {
@@ -200,11 +207,11 @@ var SchedulerVue2 = {
200
207
  return currentView.name === _this.ks.activeViewName;
201
208
  }) || this.views[0] || h(DayView);
202
209
  var slotDuration = this.getViewPropValue(this.ks.view, 'slotDuration', this.ks.activeViewName);
203
- var todayText = this.localization.toLanguageString(today, messages[today]);
204
- var previousText = this.localization.toLanguageString(previousTitle, messages[previousTitle]);
205
- var nextText = this.localization.toLanguageString(nextTitle, messages[nextTitle]);
206
- var heaeder = templateRendering.call(this, view.header || this.$props.header, getListeners.call(this));
210
+ var header = templateRendering.call(this, view.header || this.$props.header, getListeners.call(this));
207
211
  var footer = templateRendering.call(this, view.footer || this.$props.footer, getListeners.call(this));
212
+ var slotRender = templateRendering.call(this, view.slot || this.$props.slotRender, {});
213
+ var item = templateRendering.call(this, view.item || this.$props.item, {});
214
+ var task = templateRendering.call(this, view.task || this.$props.task, {});
208
215
  var ViewSelector = SchedulerViewSelector;
209
216
  var viewComponent = this.getViewComponentByName(this.ks.activeViewName || view.name);
210
217
 
@@ -213,329 +220,25 @@ var SchedulerVue2 = {
213
220
  dataItems: undefined,
214
221
  views: undefined,
215
222
  defaultDate: undefined,
216
- dateRange: this.ks.dateRange
223
+ dateRange: this.ks.dateRange,
224
+ slotRender: slotRender,
225
+ item: item,
226
+ task: task
217
227
  });
218
228
 
219
- return h("div", {
220
- id: this.$props.id,
221
- attrs: this.v3 ? undefined : {
222
- id: this.$props.id,
223
- tabIndex: this.$props.tabIndex // Aria
224
- // dir={dir}
225
- ,
226
- role: this.$props.role,
227
- "aria-label": this.$props.ariaLabel,
228
- "aria-labelledby": this.$props.ariaLabelledby // Handlers
229
-
230
- },
231
- style: {
232
- height: this.$props.height + 'px'
233
- },
234
- "class": this.wrapperClassName,
235
- tabIndex: this.$props.tabIndex,
236
- role: this.$props.role,
237
- "aria-label": this.$props.ariaLabel,
238
- "aria-labelledby": this.$props.ariaLabelledby,
239
- onFocusin: this.handleFocus,
240
- on: this.v3 ? undefined : {
241
- "focusin": this.handleFocus,
242
- "focusout": this.handleBlur
243
- },
244
- onFocusout: this.handleBlur
245
- }, [// @ts-ignore function children
229
+ var headerRender;
230
+ var headerRenderDefaultRendering = // @ts-ignore function children
246
231
  h(SchedulerHeader, this.v3 ? function () {
247
- return [// @ts-ignore function children
248
- h(SchedulerNavigation, _this2.v3 ? function () {
249
- return [// @ts-ignore function children
250
- h(ButtonGroup, {
251
- "class": "k-scheduler-navigation"
252
- }, _this2.v3 ? function () {
253
- return [// @ts-ignore function children
254
- h(Button, {
255
- role: "button",
256
- attrs: _this2.v3 ? undefined : {
257
- role: "button",
258
- tabIndex: -1,
259
- title: todayText,
260
- "aria-label": todayText
261
- },
262
- tabIndex: -1,
263
- title: todayText,
264
- "aria-label": todayText,
265
- onClick: _this2.handleTodayClick,
266
- on: _this2.v3 ? undefined : {
267
- "click": _this2.handleTodayClick
268
- }
269
- }, _this2.v3 ? function () {
270
- return [todayText];
271
- } : [todayText]), // @ts-ignore function children
272
- h(Button, {
273
- role: "button",
274
- attrs: _this2.v3 ? undefined : {
275
- role: "button",
276
- tabIndex: -1,
277
- title: previousText,
278
- "aria-label": previousText
279
- },
280
- tabIndex: -1,
281
- "class": "k-button-icon",
282
- title: previousText,
283
- "aria-label": previousText,
284
- onClick: _this2.handlePrevClick,
285
- on: _this2.v3 ? undefined : {
286
- "click": _this2.handlePrevClick
287
- }
288
- }, _this2.v3 ? function () {
289
- return [h("span", {
290
- "class": "k-button-text"
291
- }, [h("span", {
292
- "class": "k-icon k-i-arrow-60-left"
293
- })])];
294
- } : [h("span", {
295
- "class": "k-button-text"
296
- }, [h("span", {
297
- "class": "k-icon k-i-arrow-60-left"
298
- })])]), // @ts-ignore function children
299
- h(Button, {
300
- role: "button",
301
- attrs: _this2.v3 ? undefined : {
302
- role: "button",
303
- tabIndex: -1,
304
- title: nextText,
305
- "aria-label": nextText
306
- },
307
- tabIndex: -1,
308
- "class": "k-button-icon",
309
- title: nextText,
310
- "aria-label": nextText,
311
- onClick: _this2.handleNextClick,
312
- on: _this2.v3 ? undefined : {
313
- "click": _this2.handleNextClick
314
- }
315
- }, _this2.v3 ? function () {
316
- return [h("span", {
317
- "class": "k-button-text"
318
- }, [h("span", {
319
- "class": "k-icon k-i-arrow-60-right"
320
- })])];
321
- } : [h("span", {
322
- "class": "k-button-text"
323
- }, [h("span", {
324
- "class": "k-icon k-i-arrow-60-right"
325
- })])])];
326
- } : [h(Button, {
327
- role: "button",
328
- attrs: _this2.v3 ? undefined : {
329
- role: "button",
330
- tabIndex: -1,
331
- title: todayText,
332
- "aria-label": todayText
333
- },
334
- tabIndex: -1,
335
- title: todayText,
336
- "aria-label": todayText,
337
- onClick: _this2.handleTodayClick,
338
- on: _this2.v3 ? undefined : {
339
- "click": _this2.handleTodayClick
340
- }
341
- }, _this2.v3 ? function () {
342
- return [todayText];
343
- } : [todayText]), h(Button, {
344
- role: "button",
345
- attrs: _this2.v3 ? undefined : {
346
- role: "button",
347
- tabIndex: -1,
348
- title: previousText,
349
- "aria-label": previousText
350
- },
351
- tabIndex: -1,
352
- "class": "k-button-icon",
353
- title: previousText,
354
- "aria-label": previousText,
355
- onClick: _this2.handlePrevClick,
356
- on: _this2.v3 ? undefined : {
357
- "click": _this2.handlePrevClick
358
- }
359
- }, _this2.v3 ? function () {
360
- return [h("span", {
361
- "class": "k-button-text"
362
- }, [h("span", {
363
- "class": "k-icon k-i-arrow-60-left"
364
- })])];
365
- } : [h("span", {
366
- "class": "k-button-text"
367
- }, [h("span", {
368
- "class": "k-icon k-i-arrow-60-left"
369
- })])]), h(Button, {
370
- role: "button",
371
- attrs: _this2.v3 ? undefined : {
372
- role: "button",
373
- tabIndex: -1,
374
- title: nextText,
375
- "aria-label": nextText
376
- },
377
- tabIndex: -1,
378
- "class": "k-button-icon",
379
- title: nextText,
380
- "aria-label": nextText,
381
- onClick: _this2.handleNextClick,
382
- on: _this2.v3 ? undefined : {
383
- "click": _this2.handleNextClick
384
- }
385
- }, _this2.v3 ? function () {
386
- return [h("span", {
387
- "class": "k-button-text"
388
- }, [h("span", {
389
- "class": "k-icon k-i-arrow-60-right"
390
- })])];
391
- } : [h("span", {
392
- "class": "k-button-text"
393
- }, [h("span", {
394
- "class": "k-icon k-i-arrow-60-right"
395
- })])])])];
396
- } : [h(ButtonGroup, {
397
- "class": "k-scheduler-navigation"
398
- }, _this2.v3 ? function () {
399
- return [h(Button, {
400
- role: "button",
401
- attrs: _this2.v3 ? undefined : {
402
- role: "button",
403
- tabIndex: -1,
404
- title: todayText,
405
- "aria-label": todayText
406
- },
407
- tabIndex: -1,
408
- title: todayText,
409
- "aria-label": todayText,
410
- onClick: _this2.handleTodayClick,
411
- on: _this2.v3 ? undefined : {
412
- "click": _this2.handleTodayClick
413
- }
414
- }, _this2.v3 ? function () {
415
- return [todayText];
416
- } : [todayText]), h(Button, {
417
- role: "button",
418
- attrs: _this2.v3 ? undefined : {
419
- role: "button",
420
- tabIndex: -1,
421
- title: previousText,
422
- "aria-label": previousText
423
- },
424
- tabIndex: -1,
425
- "class": "k-button-icon",
426
- title: previousText,
427
- "aria-label": previousText,
428
- onClick: _this2.handlePrevClick,
429
- on: _this2.v3 ? undefined : {
430
- "click": _this2.handlePrevClick
431
- }
432
- }, _this2.v3 ? function () {
433
- return [h("span", {
434
- "class": "k-button-text"
435
- }, [h("span", {
436
- "class": "k-icon k-i-arrow-60-left"
437
- })])];
438
- } : [h("span", {
439
- "class": "k-button-text"
440
- }, [h("span", {
441
- "class": "k-icon k-i-arrow-60-left"
442
- })])]), h(Button, {
443
- role: "button",
444
- attrs: _this2.v3 ? undefined : {
445
- role: "button",
446
- tabIndex: -1,
447
- title: nextText,
448
- "aria-label": nextText
449
- },
450
- tabIndex: -1,
451
- "class": "k-button-icon",
452
- title: nextText,
453
- "aria-label": nextText,
454
- onClick: _this2.handleNextClick,
455
- on: _this2.v3 ? undefined : {
456
- "click": _this2.handleNextClick
457
- }
458
- }, _this2.v3 ? function () {
459
- return [h("span", {
460
- "class": "k-button-text"
461
- }, [h("span", {
462
- "class": "k-icon k-i-arrow-60-right"
463
- })])];
464
- } : [h("span", {
465
- "class": "k-button-text"
466
- }, [h("span", {
467
- "class": "k-icon k-i-arrow-60-right"
468
- })])])];
469
- } : [h(Button, {
470
- role: "button",
471
- attrs: _this2.v3 ? undefined : {
472
- role: "button",
473
- tabIndex: -1,
474
- title: todayText,
475
- "aria-label": todayText
476
- },
477
- tabIndex: -1,
478
- title: todayText,
479
- "aria-label": todayText,
480
- onClick: _this2.handleTodayClick,
232
+ return [h(SchedulerNavigation, {
233
+ onPrevclick: _this2.handlePrevClick,
481
234
  on: _this2.v3 ? undefined : {
482
- "click": _this2.handleTodayClick
483
- }
484
- }, _this2.v3 ? function () {
485
- return [todayText];
486
- } : [todayText]), h(Button, {
487
- role: "button",
488
- attrs: _this2.v3 ? undefined : {
489
- role: "button",
490
- tabIndex: -1,
491
- title: previousText,
492
- "aria-label": previousText
493
- },
494
- tabIndex: -1,
495
- "class": "k-button-icon",
496
- title: previousText,
497
- "aria-label": previousText,
498
- onClick: _this2.handlePrevClick,
499
- on: _this2.v3 ? undefined : {
500
- "click": _this2.handlePrevClick
501
- }
502
- }, _this2.v3 ? function () {
503
- return [h("span", {
504
- "class": "k-button-text"
505
- }, [h("span", {
506
- "class": "k-icon k-i-arrow-60-left"
507
- })])];
508
- } : [h("span", {
509
- "class": "k-button-text"
510
- }, [h("span", {
511
- "class": "k-icon k-i-arrow-60-left"
512
- })])]), h(Button, {
513
- role: "button",
514
- attrs: _this2.v3 ? undefined : {
515
- role: "button",
516
- tabIndex: -1,
517
- title: nextText,
518
- "aria-label": nextText
235
+ "prevclick": _this2.handlePrevClick,
236
+ "nextclick": _this2.handleNextClick,
237
+ "todayclick": _this2.handleTodayClick
519
238
  },
520
- tabIndex: -1,
521
- "class": "k-button-icon",
522
- title: nextText,
523
- "aria-label": nextText,
524
- onClick: _this2.handleNextClick,
525
- on: _this2.v3 ? undefined : {
526
- "click": _this2.handleNextClick
527
- }
528
- }, _this2.v3 ? function () {
529
- return [h("span", {
530
- "class": "k-button-text"
531
- }, [h("span", {
532
- "class": "k-icon k-i-arrow-60-right"
533
- })])];
534
- } : [h("span", {
535
- "class": "k-button-text"
536
- }, [h("span", {
537
- "class": "k-icon k-i-arrow-60-right"
538
- })])])])]), h(NavigationDatePicker, {
239
+ onNextclick: _this2.handleNextClick,
240
+ onTodayclick: _this2.handleTodayClick
241
+ }), h(NavigationDatePicker, {
539
242
  value: _this2.ks.currentDate,
540
243
  attrs: _this2.v3 ? undefined : {
541
244
  value: _this2.ks.currentDate
@@ -544,297 +247,17 @@ var SchedulerVue2 = {
544
247
  on: _this2.v3 ? undefined : {
545
248
  "change": _this2.handleDatePickerChange
546
249
  }
547
- }), h(ToolbarSpacer), // @ts-ignore function children
548
- h(ViewSelector, _this2.v3 ? function () {
549
- return [h(ViewSelectorList)];
550
- } : [h(ViewSelectorList)])];
551
- } : [h(SchedulerNavigation, _this2.v3 ? function () {
552
- return [h(ButtonGroup, {
553
- "class": "k-scheduler-navigation"
554
- }, _this2.v3 ? function () {
555
- return [h(Button, {
556
- role: "button",
557
- attrs: _this2.v3 ? undefined : {
558
- role: "button",
559
- tabIndex: -1,
560
- title: todayText,
561
- "aria-label": todayText
562
- },
563
- tabIndex: -1,
564
- title: todayText,
565
- "aria-label": todayText,
566
- onClick: _this2.handleTodayClick,
567
- on: _this2.v3 ? undefined : {
568
- "click": _this2.handleTodayClick
569
- }
570
- }, _this2.v3 ? function () {
571
- return [todayText];
572
- } : [todayText]), h(Button, {
573
- role: "button",
574
- attrs: _this2.v3 ? undefined : {
575
- role: "button",
576
- tabIndex: -1,
577
- title: previousText,
578
- "aria-label": previousText
579
- },
580
- tabIndex: -1,
581
- "class": "k-button-icon",
582
- title: previousText,
583
- "aria-label": previousText,
584
- onClick: _this2.handlePrevClick,
585
- on: _this2.v3 ? undefined : {
586
- "click": _this2.handlePrevClick
587
- }
588
- }, _this2.v3 ? function () {
589
- return [h("span", {
590
- "class": "k-button-text"
591
- }, [h("span", {
592
- "class": "k-icon k-i-arrow-60-left"
593
- })])];
594
- } : [h("span", {
595
- "class": "k-button-text"
596
- }, [h("span", {
597
- "class": "k-icon k-i-arrow-60-left"
598
- })])]), h(Button, {
599
- role: "button",
600
- attrs: _this2.v3 ? undefined : {
601
- role: "button",
602
- tabIndex: -1,
603
- title: nextText,
604
- "aria-label": nextText
605
- },
606
- tabIndex: -1,
607
- "class": "k-button-icon",
608
- title: nextText,
609
- "aria-label": nextText,
610
- onClick: _this2.handleNextClick,
611
- on: _this2.v3 ? undefined : {
612
- "click": _this2.handleNextClick
613
- }
614
- }, _this2.v3 ? function () {
615
- return [h("span", {
616
- "class": "k-button-text"
617
- }, [h("span", {
618
- "class": "k-icon k-i-arrow-60-right"
619
- })])];
620
- } : [h("span", {
621
- "class": "k-button-text"
622
- }, [h("span", {
623
- "class": "k-icon k-i-arrow-60-right"
624
- })])])];
625
- } : [h(Button, {
626
- role: "button",
627
- attrs: _this2.v3 ? undefined : {
628
- role: "button",
629
- tabIndex: -1,
630
- title: todayText,
631
- "aria-label": todayText
632
- },
633
- tabIndex: -1,
634
- title: todayText,
635
- "aria-label": todayText,
636
- onClick: _this2.handleTodayClick,
637
- on: _this2.v3 ? undefined : {
638
- "click": _this2.handleTodayClick
639
- }
640
- }, _this2.v3 ? function () {
641
- return [todayText];
642
- } : [todayText]), h(Button, {
643
- role: "button",
644
- attrs: _this2.v3 ? undefined : {
645
- role: "button",
646
- tabIndex: -1,
647
- title: previousText,
648
- "aria-label": previousText
649
- },
650
- tabIndex: -1,
651
- "class": "k-button-icon",
652
- title: previousText,
653
- "aria-label": previousText,
654
- onClick: _this2.handlePrevClick,
655
- on: _this2.v3 ? undefined : {
656
- "click": _this2.handlePrevClick
657
- }
658
- }, _this2.v3 ? function () {
659
- return [h("span", {
660
- "class": "k-button-text"
661
- }, [h("span", {
662
- "class": "k-icon k-i-arrow-60-left"
663
- })])];
664
- } : [h("span", {
665
- "class": "k-button-text"
666
- }, [h("span", {
667
- "class": "k-icon k-i-arrow-60-left"
668
- })])]), h(Button, {
669
- role: "button",
670
- attrs: _this2.v3 ? undefined : {
671
- role: "button",
672
- tabIndex: -1,
673
- title: nextText,
674
- "aria-label": nextText
675
- },
676
- tabIndex: -1,
677
- "class": "k-button-icon",
678
- title: nextText,
679
- "aria-label": nextText,
680
- onClick: _this2.handleNextClick,
681
- on: _this2.v3 ? undefined : {
682
- "click": _this2.handleNextClick
683
- }
684
- }, _this2.v3 ? function () {
685
- return [h("span", {
686
- "class": "k-button-text"
687
- }, [h("span", {
688
- "class": "k-icon k-i-arrow-60-right"
689
- })])];
690
- } : [h("span", {
691
- "class": "k-button-text"
692
- }, [h("span", {
693
- "class": "k-icon k-i-arrow-60-right"
694
- })])])])];
695
- } : [h(ButtonGroup, {
696
- "class": "k-scheduler-navigation"
697
- }, _this2.v3 ? function () {
698
- return [h(Button, {
699
- role: "button",
700
- attrs: _this2.v3 ? undefined : {
701
- role: "button",
702
- tabIndex: -1,
703
- title: todayText,
704
- "aria-label": todayText
705
- },
706
- tabIndex: -1,
707
- title: todayText,
708
- "aria-label": todayText,
709
- onClick: _this2.handleTodayClick,
710
- on: _this2.v3 ? undefined : {
711
- "click": _this2.handleTodayClick
712
- }
713
- }, _this2.v3 ? function () {
714
- return [todayText];
715
- } : [todayText]), h(Button, {
716
- role: "button",
717
- attrs: _this2.v3 ? undefined : {
718
- role: "button",
719
- tabIndex: -1,
720
- title: previousText,
721
- "aria-label": previousText
722
- },
723
- tabIndex: -1,
724
- "class": "k-button-icon",
725
- title: previousText,
726
- "aria-label": previousText,
727
- onClick: _this2.handlePrevClick,
728
- on: _this2.v3 ? undefined : {
729
- "click": _this2.handlePrevClick
730
- }
731
- }, _this2.v3 ? function () {
732
- return [h("span", {
733
- "class": "k-button-text"
734
- }, [h("span", {
735
- "class": "k-icon k-i-arrow-60-left"
736
- })])];
737
- } : [h("span", {
738
- "class": "k-button-text"
739
- }, [h("span", {
740
- "class": "k-icon k-i-arrow-60-left"
741
- })])]), h(Button, {
742
- role: "button",
743
- attrs: _this2.v3 ? undefined : {
744
- role: "button",
745
- tabIndex: -1,
746
- title: nextText,
747
- "aria-label": nextText
748
- },
749
- tabIndex: -1,
750
- "class": "k-button-icon",
751
- title: nextText,
752
- "aria-label": nextText,
753
- onClick: _this2.handleNextClick,
754
- on: _this2.v3 ? undefined : {
755
- "click": _this2.handleNextClick
756
- }
757
- }, _this2.v3 ? function () {
758
- return [h("span", {
759
- "class": "k-button-text"
760
- }, [h("span", {
761
- "class": "k-icon k-i-arrow-60-right"
762
- })])];
763
- } : [h("span", {
764
- "class": "k-button-text"
765
- }, [h("span", {
766
- "class": "k-icon k-i-arrow-60-right"
767
- })])])];
768
- } : [h(Button, {
769
- role: "button",
770
- attrs: _this2.v3 ? undefined : {
771
- role: "button",
772
- tabIndex: -1,
773
- title: todayText,
774
- "aria-label": todayText
775
- },
776
- tabIndex: -1,
777
- title: todayText,
778
- "aria-label": todayText,
779
- onClick: _this2.handleTodayClick,
780
- on: _this2.v3 ? undefined : {
781
- "click": _this2.handleTodayClick
782
- }
783
- }, _this2.v3 ? function () {
784
- return [todayText];
785
- } : [todayText]), h(Button, {
786
- role: "button",
787
- attrs: _this2.v3 ? undefined : {
788
- role: "button",
789
- tabIndex: -1,
790
- title: previousText,
791
- "aria-label": previousText
792
- },
793
- tabIndex: -1,
794
- "class": "k-button-icon",
795
- title: previousText,
796
- "aria-label": previousText,
797
- onClick: _this2.handlePrevClick,
250
+ }), h(ToolbarSpacer), h(ViewSelector)];
251
+ } : [h(SchedulerNavigation, {
252
+ onPrevclick: _this2.handlePrevClick,
798
253
  on: _this2.v3 ? undefined : {
799
- "click": _this2.handlePrevClick
800
- }
801
- }, _this2.v3 ? function () {
802
- return [h("span", {
803
- "class": "k-button-text"
804
- }, [h("span", {
805
- "class": "k-icon k-i-arrow-60-left"
806
- })])];
807
- } : [h("span", {
808
- "class": "k-button-text"
809
- }, [h("span", {
810
- "class": "k-icon k-i-arrow-60-left"
811
- })])]), h(Button, {
812
- role: "button",
813
- attrs: _this2.v3 ? undefined : {
814
- role: "button",
815
- tabIndex: -1,
816
- title: nextText,
817
- "aria-label": nextText
254
+ "prevclick": _this2.handlePrevClick,
255
+ "nextclick": _this2.handleNextClick,
256
+ "todayclick": _this2.handleTodayClick
818
257
  },
819
- tabIndex: -1,
820
- "class": "k-button-icon",
821
- title: nextText,
822
- "aria-label": nextText,
823
- onClick: _this2.handleNextClick,
824
- on: _this2.v3 ? undefined : {
825
- "click": _this2.handleNextClick
826
- }
827
- }, _this2.v3 ? function () {
828
- return [h("span", {
829
- "class": "k-button-text"
830
- }, [h("span", {
831
- "class": "k-icon k-i-arrow-60-right"
832
- })])];
833
- } : [h("span", {
834
- "class": "k-button-text"
835
- }, [h("span", {
836
- "class": "k-icon k-i-arrow-60-right"
837
- })])])])]), h(NavigationDatePicker, {
258
+ onNextclick: _this2.handleNextClick,
259
+ onTodayclick: _this2.handleTodayClick
260
+ }), h(NavigationDatePicker, {
838
261
  value: _this2.ks.currentDate,
839
262
  attrs: _this2.v3 ? undefined : {
840
263
  value: _this2.ks.currentDate
@@ -843,85 +266,90 @@ var SchedulerVue2 = {
843
266
  on: _this2.v3 ? undefined : {
844
267
  "change": _this2.handleDatePickerChange
845
268
  }
846
- }), h(ToolbarSpacer), h(ViewSelector, _this2.v3 ? function () {
847
- return [h(ViewSelectorList)];
848
- } : [h(ViewSelectorList)])]), view && h(viewComponent, __assign({
849
- key: this.ks.view.name,
850
- onDataaction: this.handleDataAction,
851
- on: this.v3 ? undefined : {
852
- 'dataaction': this.handleDataAction
269
+ }), h(ToolbarSpacer), h(ViewSelector)]);
270
+ headerRender = getTemplate.call(this, {
271
+ h: h,
272
+ template: header,
273
+ defaultRendering: headerRenderDefaultRendering,
274
+ additionalProps: {
275
+ currentDate: this.ks.currentDate
853
276
  },
854
- props: this.v3 ? undefined : viewProps
855
- }, viewProps)), // @ts-ignore function children
277
+ additionalListeners: {
278
+ prevclick: this.handlePrevClick,
279
+ nextclick: this.handleNextClick,
280
+ todayclick: this.handleTodayClick,
281
+ datepickerchange: this.handleDatePickerChange
282
+ }
283
+ });
284
+ var footerRender;
285
+ var footerRenderDefaultRendering = // @ts-ignore function children
856
286
  h(SchedulerFooter, this.v3 ? function () {
857
- return [slotDuration && slotDuration < 24 * 60 && // @ts-ignore function children
858
- h(BusinessHours, _this2.v3 ? function () {
859
- return [// @ts-ignore function children
860
- h(Button, {
861
- tabIndex: -1,
862
- attrs: _this2.v3 ? undefined : {
863
- tabIndex: -1
864
- },
865
- onClick: _this2.handleShowWorkHoursClick,
866
- on: _this2.v3 ? undefined : {
867
- "click": _this2.handleShowWorkHoursClick
868
- }
869
- }, _this2.v3 ? function () {
870
- return [h("span", {
871
- "class": "k-icon k-i-clock"
872
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])];
873
- } : [h("span", {
874
- "class": "k-icon k-i-clock"
875
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])])];
876
- } : [h(Button, {
877
- tabIndex: -1,
878
- attrs: _this2.v3 ? undefined : {
879
- tabIndex: -1
880
- },
881
- onClick: _this2.handleShowWorkHoursClick,
882
- on: _this2.v3 ? undefined : {
883
- "click": _this2.handleShowWorkHoursClick
884
- }
885
- }, _this2.v3 ? function () {
886
- return [h("span", {
887
- "class": "k-icon k-i-clock"
888
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])];
889
- } : [h("span", {
890
- "class": "k-icon k-i-clock"
891
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])])])];
892
- } : [slotDuration && slotDuration < 24 * 60 && h(BusinessHours, _this2.v3 ? function () {
893
- return [h(Button, {
894
- tabIndex: -1,
287
+ return [// @ts-ignore function children
288
+ h(BusinessHours, {
289
+ slotDuration: slotDuration,
895
290
  attrs: _this2.v3 ? undefined : {
896
- tabIndex: -1
291
+ slotDuration: slotDuration
897
292
  },
898
293
  onClick: _this2.handleShowWorkHoursClick,
899
294
  on: _this2.v3 ? undefined : {
900
295
  "click": _this2.handleShowWorkHoursClick
901
296
  }
902
- }, _this2.v3 ? function () {
903
- return [h("span", {
904
- "class": "k-icon k-i-clock"
905
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])];
906
- } : [h("span", {
907
- "class": "k-icon k-i-clock"
908
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])])];
909
- } : [h(Button, {
910
- tabIndex: -1,
297
+ })];
298
+ } : [h(BusinessHours, {
299
+ slotDuration: slotDuration,
911
300
  attrs: _this2.v3 ? undefined : {
912
- tabIndex: -1
301
+ slotDuration: slotDuration
913
302
  },
914
303
  onClick: _this2.handleShowWorkHoursClick,
915
304
  on: _this2.v3 ? undefined : {
916
305
  "click": _this2.handleShowWorkHoursClick
917
306
  }
918
- }, _this2.v3 ? function () {
919
- return [h("span", {
920
- "class": "k-icon k-i-clock"
921
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])];
922
- } : [h("span", {
923
- "class": "k-icon k-i-clock"
924
- }), "\xA0", _this2.localization.toLanguageString(_this2.ks.showWorkHours ? showFullDay : showWorkDay, messages[_this2.ks.showWorkHours ? showFullDay : showWorkDay])])])])]);
307
+ })]);
308
+ footerRender = getTemplate.call(this, {
309
+ h: h,
310
+ template: footer,
311
+ defaultRendering: footerRenderDefaultRendering,
312
+ additionalProps: {
313
+ slotDuration: slotDuration
314
+ },
315
+ additionalListeners: {
316
+ showworkhoursclick: this.handleShowWorkHoursClick
317
+ }
318
+ });
319
+ return h("div", {
320
+ id: this.$props.id,
321
+ attrs: this.v3 ? undefined : {
322
+ id: this.$props.id,
323
+ tabIndex: this.$props.tabIndex // Aria
324
+ // dir={dir}
325
+ ,
326
+ role: this.$props.role,
327
+ "aria-label": this.$props.ariaLabel,
328
+ "aria-labelledby": this.$props.ariaLabelledby // Handlers
329
+
330
+ },
331
+ style: {
332
+ height: this.$props.height + 'px'
333
+ },
334
+ "class": this.wrapperClassName,
335
+ tabIndex: this.$props.tabIndex,
336
+ role: this.$props.role,
337
+ "aria-label": this.$props.ariaLabel,
338
+ "aria-labelledby": this.$props.ariaLabelledby,
339
+ onFocusin: this.handleFocus,
340
+ on: this.v3 ? undefined : {
341
+ "focusin": this.handleFocus,
342
+ "focusout": this.handleBlur
343
+ },
344
+ onFocusout: this.handleBlur
345
+ }, [headerRender, view && h(viewComponent, __assign({
346
+ key: this.ks.view.name,
347
+ onDataaction: this.handleDataAction,
348
+ on: this.v3 ? undefined : {
349
+ 'dataaction': this.handleDataAction
350
+ },
351
+ props: this.v3 ? undefined : viewProps
352
+ }, viewProps)), footerRender]);
925
353
  },
926
354
  methods: {
927
355
  getViewComponentByName: function getViewComponentByName(viewName) {
@@ -1139,6 +567,24 @@ var SchedulerVue2 = {
1139
567
  this.$el.style.boxShadow = '';
1140
568
  }
1141
569
  },
570
+ handleItemClick: function handleItemClick(args) {
571
+ this.$emit('itemclick', args);
572
+ },
573
+ handleItemDoubleClick: function handleItemDoubleClick(args) {
574
+ this.$emit('itemdoubleclick', args);
575
+ },
576
+ handleSlotClick: function handleSlotClick(args) {
577
+ this.$emit('slotclick', args);
578
+ },
579
+ handleSlotDoubleClick: function handleSlotDoubleClick(args) {
580
+ this.$emit('slotdoubleclick', args);
581
+ },
582
+ handleTaskClick: function handleTaskClick(args) {
583
+ this.$emit('taskclick', args);
584
+ },
585
+ handleTaskDoubleClick: function handleTaskDoubleClick(args) {
586
+ this.$emit('taskdoubleclick', args);
587
+ },
1142
588
  setDate: function setDate(newDate, event) {
1143
589
  this.ks.currentDate = newDate;
1144
590
  this.updatePassedState();