@progress/kendo-vue-scheduler 10.2.0-develop.11 → 10.2.0-develop.12

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 (156) hide show
  1. package/Scheduler.d.ts +157 -56
  2. package/Scheduler.js +1 -1
  3. package/Scheduler.mjs +242 -214
  4. package/components/EventOverviewPopover.d.ts +62 -0
  5. package/components/EventOverviewPopover.js +8 -0
  6. package/components/EventOverviewPopover.mjs +191 -0
  7. package/components/MoreEventsPopover.d.ts +3 -1
  8. package/components/MoreEventsPopover.js +1 -1
  9. package/components/MoreEventsPopover.mjs +31 -27
  10. package/components/SchedulerActionButtons.js +1 -1
  11. package/components/SchedulerActionButtons.mjs +1 -0
  12. package/components/SchedulerForm.d.ts +412 -2
  13. package/components/SchedulerForm.js +1 -1
  14. package/components/SchedulerForm.mjs +162 -60
  15. package/components/SchedulerQuickCreateForm.d.ts +118 -0
  16. package/components/SchedulerQuickCreateForm.js +8 -0
  17. package/components/SchedulerQuickCreateForm.mjs +249 -0
  18. package/constants/main.d.ts +2 -0
  19. package/constants/main.js +1 -1
  20. package/constants/main.mjs +10 -9
  21. package/dist/cdn/js/kendo-vue-scheduler.js +1 -1
  22. package/editors/KeepResetCustomEventsDialog.d.ts +31 -0
  23. package/editors/KeepResetCustomEventsDialog.js +8 -0
  24. package/editors/KeepResetCustomEventsDialog.mjs +72 -0
  25. package/editors/SchedulerFormEditor.d.ts +151 -52
  26. package/editors/SchedulerFormEditor.js +1 -1
  27. package/editors/SchedulerFormEditor.mjs +192 -139
  28. package/editors/SchedulerRecurrenceDialog.d.ts +2 -2
  29. package/editors/SchedulerRecurrenceDialog.js +1 -1
  30. package/editors/SchedulerRecurrenceDialog.mjs +126 -131
  31. package/editors/ZonedSplitDateTime.d.ts +32 -3
  32. package/editors/ZonedSplitDateTime.js +1 -1
  33. package/editors/ZonedSplitDateTime.mjs +112 -47
  34. package/hooks/useCloseOnAnchorScrollOut.d.ts +10 -0
  35. package/hooks/useCloseOnAnchorScrollOut.js +8 -0
  36. package/hooks/useCloseOnAnchorScrollOut.mjs +43 -0
  37. package/hooks/useCustomEventsConfirmation.d.ts +20 -0
  38. package/hooks/useCustomEventsConfirmation.js +8 -0
  39. package/hooks/useCustomEventsConfirmation.mjs +48 -0
  40. package/hooks/useDeferredClick.d.ts +12 -0
  41. package/hooks/useDeferredClick.js +8 -0
  42. package/hooks/useDeferredClick.mjs +22 -0
  43. package/hooks/useExclusivePopover.d.ts +26 -0
  44. package/hooks/useExclusivePopover.js +8 -0
  45. package/hooks/useExclusivePopover.mjs +30 -0
  46. package/hooks/useRecurrenceSummary.d.ts +3 -0
  47. package/hooks/useRecurrenceSummary.js +1 -1
  48. package/hooks/useRecurrenceSummary.mjs +68 -41
  49. package/index.d.mts +4 -2
  50. package/index.d.ts +4 -2
  51. package/index.js +1 -1
  52. package/index.mjs +83 -78
  53. package/items/SchedulerEditItem.d.ts +116 -12
  54. package/items/SchedulerEditItem.js +1 -1
  55. package/items/SchedulerEditItem.mjs +212 -131
  56. package/items/SchedulerItem.d.ts +2 -1
  57. package/items/SchedulerItem.js +1 -1
  58. package/items/SchedulerItem.mjs +28 -23
  59. package/items/SchedulerProportionalViewItem.d.ts +1 -0
  60. package/items/SchedulerProportionalViewItem.js +1 -1
  61. package/items/SchedulerProportionalViewItem.mjs +83 -68
  62. package/items/SchedulerViewItem.d.ts +1 -0
  63. package/items/SchedulerViewItem.js +1 -1
  64. package/items/SchedulerViewItem.mjs +84 -75
  65. package/items/hooks/use-drag-item.js +1 -1
  66. package/items/hooks/use-drag-item.mjs +49 -48
  67. package/items/hooks/use-form-item.d.ts +1 -1
  68. package/items/hooks/use-remove-item.d.ts +1 -1
  69. package/items/hooks/use-resize-item.js +1 -1
  70. package/items/hooks/use-resize-item.mjs +74 -65
  71. package/messages/main.d.ts +42 -0
  72. package/messages/main.js +1 -1
  73. package/messages/main.mjs +303 -275
  74. package/models/InternalDataAction.d.ts +13 -0
  75. package/models/SchedulerView.d.ts +1 -1
  76. package/package-metadata.js +1 -1
  77. package/package-metadata.mjs +2 -2
  78. package/package.json +13 -12
  79. package/recurrence/RecurrenceEditor.js +1 -1
  80. package/recurrence/RecurrenceEditor.mjs +42 -42
  81. package/recurrence/common.d.ts +10 -0
  82. package/recurrence/common.js +1 -1
  83. package/recurrence/common.mjs +39 -35
  84. package/services/itemsService.d.ts +5 -2
  85. package/services/itemsService.js +1 -1
  86. package/services/itemsService.mjs +46 -33
  87. package/services/occurrenceService.js +1 -1
  88. package/services/occurrenceService.mjs +18 -18
  89. package/slots/SchedulerEditSlot.d.ts +70 -8
  90. package/slots/SchedulerEditSlot.js +1 -1
  91. package/slots/SchedulerEditSlot.mjs +222 -141
  92. package/slots/SchedulerSlot.js +1 -1
  93. package/slots/SchedulerSlot.mjs +20 -16
  94. package/slots/SchedulerViewSlot.d.ts +3 -0
  95. package/slots/SchedulerViewSlot.js +1 -1
  96. package/slots/SchedulerViewSlot.mjs +21 -15
  97. package/tasks/SchedulerEditTask.d.ts +13 -2
  98. package/tasks/SchedulerEditTask.js +1 -1
  99. package/tasks/SchedulerEditTask.mjs +45 -30
  100. package/utils/main.d.ts +27 -0
  101. package/utils/main.js +1 -1
  102. package/utils/main.mjs +172 -136
  103. package/views/agenda/AgendaView.d.ts +6 -2
  104. package/views/agenda/AgendaView.js +1 -1
  105. package/views/agenda/AgendaView.mjs +31 -29
  106. package/views/agenda/AgendaViewBody.d.ts +3 -3
  107. package/views/agenda/AgendaViewBody.js +1 -1
  108. package/views/agenda/AgendaViewBody.mjs +31 -29
  109. package/views/common/SchedulerDrag.d.ts +4 -2
  110. package/views/common/SchedulerDrag.js +1 -1
  111. package/views/common/SchedulerDrag.mjs +8 -7
  112. package/views/common/SchedulerResize.d.ts +4 -2
  113. package/views/common/SchedulerResize.js +1 -1
  114. package/views/common/SchedulerResize.mjs +14 -12
  115. package/views/common/VerticalResourceIterator.d.ts +3 -3
  116. package/views/common/VerticalResourceIterator.js +1 -1
  117. package/views/common/VerticalResourceIterator.mjs +34 -33
  118. package/views/day/DayView.d.ts +2 -0
  119. package/views/day/DayView.js +1 -1
  120. package/views/day/DayView.mjs +9 -7
  121. package/views/day/DayViewAllDaySlots.d.ts +7 -5
  122. package/views/day/DayViewAllDaySlots.js +1 -1
  123. package/views/day/DayViewAllDaySlots.mjs +24 -21
  124. package/views/day/DayViewMiddleRow.d.ts +7 -5
  125. package/views/day/DayViewMiddleRow.js +1 -1
  126. package/views/day/DayViewMiddleRow.mjs +18 -13
  127. package/views/day/DayViewVerticalRow.d.ts +7 -5
  128. package/views/day/DayViewVerticalRow.js +1 -1
  129. package/views/day/DayViewVerticalRow.mjs +23 -17
  130. package/views/day/DayViewVerticalSlotsRow.d.ts +7 -5
  131. package/views/day/DayViewVerticalSlotsRow.js +1 -1
  132. package/views/day/DayViewVerticalSlotsRow.mjs +34 -29
  133. package/views/day/MultiDayView.d.ts +13 -7
  134. package/views/day/MultiDayView.js +1 -1
  135. package/views/day/MultiDayView.mjs +108 -95
  136. package/views/month/MonthView.d.ts +15 -4
  137. package/views/month/MonthView.js +1 -1
  138. package/views/month/MonthView.mjs +105 -68
  139. package/views/month/MonthViewBody.d.ts +3 -3
  140. package/views/month/MonthViewBody.js +1 -1
  141. package/views/month/MonthViewBody.mjs +18 -16
  142. package/views/time/MultiDayTimelineView.d.ts +6 -4
  143. package/views/time/MultiDayTimelineView.js +1 -1
  144. package/views/time/MultiDayTimelineView.mjs +64 -63
  145. package/views/time/TimelineView.d.ts +2 -0
  146. package/views/time/TimelineView.js +1 -1
  147. package/views/time/TimelineView.mjs +5 -3
  148. package/views/time/TimelineViewBody.d.ts +7 -5
  149. package/views/time/TimelineViewBody.js +1 -1
  150. package/views/time/TimelineViewBody.mjs +29 -27
  151. package/views/week/WeekView.d.ts +2 -0
  152. package/views/week/WeekView.js +1 -1
  153. package/views/week/WeekView.mjs +11 -10
  154. package/views/week/WorkWeekView.d.ts +2 -0
  155. package/views/week/WorkWeekView.js +1 -1
  156. package/views/week/WorkWeekView.mjs +17 -16
@@ -5,17 +5,19 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { defineComponent as a, createVNode as s } from "vue";
8
+ import { defineComponent as a, createVNode as n } from "vue";
9
9
  import { MultiDayView as e } from "./MultiDayView.mjs";
10
- import { dayViewTitle as r, messages as n } from "../../messages/main.mjs";
10
+ import { dayViewTitle as r, messages as s } from "../../messages/main.mjs";
11
11
  import { provideLocalizationService as p } from "@progress/kendo-vue-intl";
12
12
  import { Day as o } from "@progress/kendo-date-math";
13
- const h = /* @__PURE__ */ a({
13
+ import { emitDataAction as l } from "../../utils/main.mjs";
14
+ const y = /* @__PURE__ */ a({
14
15
  name: "KendoDayView",
15
16
  emits: {
16
17
  dataaction: null
17
18
  },
18
19
  props: {
20
+ onDataAction: Function,
19
21
  name: {
20
22
  type: String,
21
23
  default: "day"
@@ -106,8 +108,8 @@ const h = /* @__PURE__ */ a({
106
108
  }
107
109
  },
108
110
  render() {
109
- const i = p(this).toLanguageString(r, n[r]);
110
- return s(e, {
111
+ const i = p(this).toLanguageString(r, s[r]);
112
+ return n(e, {
111
113
  name: this.$props.name,
112
114
  dateRange: this.$props.dateRange,
113
115
  step: this.$props.step,
@@ -139,10 +141,10 @@ const h = /* @__PURE__ */ a({
139
141
  },
140
142
  methods: {
141
143
  handleDataAction(t) {
142
- this.$emit("dataaction", t);
144
+ l(this, t);
143
145
  }
144
146
  }
145
147
  });
146
148
  export {
147
- h as DayView
149
+ y as DayView
148
150
  };
@@ -17,7 +17,7 @@ export interface DayViewAllDaySlotsProps {
17
17
  workWeekStart: number;
18
18
  workWeekEnd: number;
19
19
  editable?: boolean | object;
20
- onDataaction: Function;
20
+ onDataAction: (action: DataAction) => void;
21
21
  }
22
22
  /** @hidden */
23
23
  declare const DayViewAllDaySlots: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
@@ -32,7 +32,7 @@ declare const DayViewAllDaySlots: import('vue').DefineComponent<import('vue').Ex
32
32
  type: PropType<boolean | object>;
33
33
  default: boolean;
34
34
  };
35
- onDataaction: PropType<Function>;
35
+ onDataAction: PropType<(action: DataAction) => void>;
36
36
  }>, {}, {
37
37
  ksSlots: {
38
38
  cSlots: any;
@@ -42,7 +42,7 @@ declare const DayViewAllDaySlots: import('vue').DefineComponent<import('vue').Ex
42
42
  }, {
43
43
  handleDataAction(action: DataAction): void;
44
44
  calculateRanges(daySlots: any, groupIndex: number, dayRanges: any): any;
45
- }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
45
+ }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, "dataaction"[], "dataaction", import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
46
46
  slotRender: PropType<any>;
47
47
  viewSlot: PropType<any>;
48
48
  dayRanges: PropType<any[]>;
@@ -54,8 +54,10 @@ declare const DayViewAllDaySlots: import('vue').DefineComponent<import('vue').Ex
54
54
  type: PropType<boolean | object>;
55
55
  default: boolean;
56
56
  };
57
- onDataaction: PropType<Function>;
58
- }>> & Readonly<{}>, {
57
+ onDataAction: PropType<(action: DataAction) => void>;
58
+ }>> & Readonly<{
59
+ onDataaction?: (...args: any[]) => any;
60
+ }>, {
59
61
  editable: boolean | object;
60
62
  }, {}, {}, {}, string, () => {
61
63
  ksSlots: any;
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("vue"),i=require("../../slots/SchedulerEditSlot.js"),d=a.defineComponent({name:"KendoDayViewAllDaySlots",props:{slotRender:[String,Function,Object],viewSlot:[String,Function,Object],dayRanges:Array,daySlots:Array,numberOfDays:Number,workWeekStart:Number,workWeekEnd:Number,editable:{type:[Boolean,Object],default:!1},onDataaction:Function},inject:{ri:{default:null},ks:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const t=this.daySlots,e=this.groupIndex!==void 0?this.groupIndex:this.ri.groupIndex;return{ksSlots:{cSlots:this.calculateRanges(t,e,this.dayRanges)}}},watch:{currentCellSlots(t){this.ksSlots.cSlots=t}},computed:{currentCellSlots(){const t=this.daySlots,e=this.groupIndex!==void 0?this.groupIndex:this.ri.groupIndex;return this.calculateRanges(t,e,this.dayRanges)}},render(){const{numberOfDays:t,workWeekStart:e,workWeekEnd:r}=this.$props,s=this.ri.groupIndex;return a.createVNode("div",{key:s,class:"k-scheduler-row"},[this.currentCellSlots.map(function(n,o,l){return a.createVNode(i.SchedulerEditSlot,{index:o,onDataaction:this.handleDataAction,form:this.$props.form,slotRender:this.$props.slotRender,viewSlot:this.$props.viewSlot,row:0,col:this.ks.orientation==="horizontal"?l.length*(s||0)+o:o,isWorkDay:0<=n.zonedStart.getDay()+(t-e)&&(n.zonedStart.getDay()+(t-e))%t<=r+(t-e),expandable:!0,editable:this.$props.editable},null)},this)])},methods:{handleDataAction(t){this.$emit("dataaction",t)},calculateRanges(t,e,r){return r.map(function(s,n){return t.filter(o=>o.group.index===e&&o.range.index===n)}).flat()}}});exports.DayViewAllDaySlots=d;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("vue"),u=require("../../slots/SchedulerEditSlot.js"),c=require("../../utils/main.js"),h=a.defineComponent({name:"KendoDayViewAllDaySlots",emits:["dataaction"],props:{slotRender:[String,Function,Object],viewSlot:[String,Function,Object],dayRanges:Array,daySlots:Array,numberOfDays:Number,workWeekStart:Number,workWeekEnd:Number,editable:{type:[Boolean,Object],default:!1},onDataAction:Function},inject:{ri:{default:null},ks:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const t=this.daySlots,e=this.groupIndex!==void 0?this.groupIndex:this.ri.groupIndex;return{ksSlots:{cSlots:this.calculateRanges(t,e,this.dayRanges)}}},watch:{currentCellSlots(t){this.ksSlots.cSlots=t}},computed:{currentCellSlots(){const t=this.daySlots,e=this.groupIndex!==void 0?this.groupIndex:this.ri.groupIndex;return this.calculateRanges(t,e,this.dayRanges)}},render(){var n;const t=((n=this.ks)==null?void 0:n.editSlot)||u.SchedulerEditSlot,{numberOfDays:e,workWeekStart:o,workWeekEnd:i}=this.$props,r=this.ri.groupIndex;return a.createVNode("div",{key:r,class:"k-scheduler-row"},[this.currentCellSlots.map(function(l,s,d){return a.createVNode(t,{index:s,onDataaction:this.handleDataAction,form:this.$props.form,slotRender:this.$props.slotRender,viewSlot:this.$props.viewSlot,row:0,col:this.ks.orientation==="horizontal"?d.length*(r||0)+s:s,isWorkDay:0<=l.zonedStart.getDay()+(e-o)&&(l.zonedStart.getDay()+(e-o))%e<=i+(e-o),expandable:!0,editable:this.$props.editable},null)},this)])},methods:{handleDataAction(t){c.emitDataAction(this,t)},calculateRanges(t,e,o){return o.map(function(i,r){return t.filter(n=>n.group.index===e&&n.range.index===r)}).flat()}}});exports.DayViewAllDaySlots=h;
@@ -5,10 +5,12 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { defineComponent as l, createVNode as a } from "vue";
9
- import { SchedulerEditSlot as d } from "../../slots/SchedulerEditSlot.mjs";
10
- const h = /* @__PURE__ */ l({
8
+ import { defineComponent as u, createVNode as l } from "vue";
9
+ import { SchedulerEditSlot as c } from "../../slots/SchedulerEditSlot.mjs";
10
+ import { emitDataAction as h } from "../../utils/main.mjs";
11
+ const m = /* @__PURE__ */ u({
11
12
  name: "KendoDayViewAllDaySlots",
13
+ emits: ["dataaction"],
12
14
  props: {
13
15
  slotRender: [String, Function, Object],
14
16
  viewSlot: [String, Function, Object],
@@ -21,7 +23,7 @@ const h = /* @__PURE__ */ l({
21
23
  type: [Boolean, Object],
22
24
  default: !1
23
25
  },
24
- onDataaction: Function
26
+ onDataAction: Function
25
27
  },
26
28
  inject: {
27
29
  ri: {
@@ -59,24 +61,25 @@ const h = /* @__PURE__ */ l({
59
61
  }
60
62
  },
61
63
  render() {
62
- const {
63
- numberOfDays: t,
64
- workWeekStart: e,
65
- workWeekEnd: r
66
- } = this.$props, s = this.ri.groupIndex;
67
- return a("div", {
68
- key: s,
64
+ var n;
65
+ const t = ((n = this.ks) == null ? void 0 : n.editSlot) || c, {
66
+ numberOfDays: e,
67
+ workWeekStart: o,
68
+ workWeekEnd: a
69
+ } = this.$props, r = this.ri.groupIndex;
70
+ return l("div", {
71
+ key: r,
69
72
  class: "k-scheduler-row"
70
- }, [this.currentCellSlots.map(function(n, o, i) {
71
- return a(d, {
72
- index: o,
73
+ }, [this.currentCellSlots.map(function(i, s, d) {
74
+ return l(t, {
75
+ index: s,
73
76
  onDataaction: this.handleDataAction,
74
77
  form: this.$props.form,
75
78
  slotRender: this.$props.slotRender,
76
79
  viewSlot: this.$props.viewSlot,
77
80
  row: 0,
78
- col: this.ks.orientation === "horizontal" ? i.length * (s || 0) + o : o,
79
- isWorkDay: 0 <= n.zonedStart.getDay() + (t - e) && (n.zonedStart.getDay() + (t - e)) % t <= r + (t - e),
81
+ col: this.ks.orientation === "horizontal" ? d.length * (r || 0) + s : s,
82
+ isWorkDay: 0 <= i.zonedStart.getDay() + (e - o) && (i.zonedStart.getDay() + (e - o)) % e <= a + (e - o),
80
83
  expandable: !0,
81
84
  editable: this.$props.editable
82
85
  }, null);
@@ -84,15 +87,15 @@ const h = /* @__PURE__ */ l({
84
87
  },
85
88
  methods: {
86
89
  handleDataAction(t) {
87
- this.$emit("dataaction", t);
90
+ h(this, t);
88
91
  },
89
- calculateRanges(t, e, r) {
90
- return r.map(function(s, n) {
91
- return t.filter((o) => o.group.index === e && o.range.index === n);
92
+ calculateRanges(t, e, o) {
93
+ return o.map(function(a, r) {
94
+ return t.filter((n) => n.group.index === e && n.range.index === r);
92
95
  }).flat();
93
96
  }
94
97
  }
95
98
  });
96
99
  export {
97
- h as DayViewAllDaySlots
100
+ m as DayViewAllDaySlots
98
101
  };
@@ -22,7 +22,7 @@ export interface DayViewMiddleRowProps {
22
22
  workDayEnd: Date;
23
23
  workWeekStart: number;
24
24
  workWeekEnd: number;
25
- onDataaction: Function;
25
+ onDataAction: (action: DataAction) => void;
26
26
  }
27
27
  /** @hidden */
28
28
  declare const DayViewMiddleRow: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
@@ -44,7 +44,7 @@ declare const DayViewMiddleRow: import('vue').DefineComponent<import('vue').Extr
44
44
  workDayEnd: PropType<Date>;
45
45
  workWeekStart: PropType<number>;
46
46
  workWeekEnd: PropType<number>;
47
- onDataaction: PropType<Function>;
47
+ onDataAction: PropType<(action: DataAction) => void>;
48
48
  }>, {}, {
49
49
  ksSlots: {
50
50
  cSlots: any;
@@ -54,7 +54,7 @@ declare const DayViewMiddleRow: import('vue').DefineComponent<import('vue').Extr
54
54
  }, {
55
55
  handleDataAction(action: DataAction): void;
56
56
  calculateRanges(timeSlots: any, groupIndex: number, timeRanges: any, root: any): any;
57
- }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
57
+ }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, "dataaction"[], "dataaction", import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
58
58
  editable: PropType<boolean | object>;
59
59
  slotRender: PropType<any>;
60
60
  viewSlot: PropType<any>;
@@ -73,8 +73,10 @@ declare const DayViewMiddleRow: import('vue').DefineComponent<import('vue').Extr
73
73
  workDayEnd: PropType<Date>;
74
74
  workWeekStart: PropType<number>;
75
75
  workWeekEnd: PropType<number>;
76
- onDataaction: PropType<Function>;
77
- }>> & Readonly<{}>, {
76
+ onDataAction: PropType<(action: DataAction) => void>;
77
+ }>> & Readonly<{
78
+ onDataaction?: (...args: any[]) => any;
79
+ }>, {
78
80
  slotDivisions: number;
79
81
  }, {}, {}, {}, string, () => {
80
82
  ksSlots: any;
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("vue"),l=require("@progress/kendo-vue-common"),d=require("../../constants/main.js"),u=require("../../slots/SchedulerEditSlot.js"),c=require("../../utils/main.js"),m=i.defineComponent({name:"KendoDayViewMiddleRow",props:{editable:[Object,Boolean],slotRender:[String,Function,Object],viewSlot:[String,Function,Object],timeRanges:Array,timeSlots:Array,slotDivisions:{type:Number,default:2},rootIndex:{type:Number},root:Object,numberOfDays:Number,workDayStart:Date,workDayEnd:Date,workWeekStart:Number,workWeekEnd:Number,onDataaction:Function},inject:{ri:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const e=this.timeSlots,t=this.ri.groupIndex,o=this.root;return{ksSlots:{cSlots:this.calculateRanges(e,t,this.timeRanges,o)}}},watch:{currentCellSlots(e){this.ksSlots.cSlots=e}},computed:{currentCellSlots(){const e=this.timeSlots,t=this.ri.groupIndex,o=this.root;return this.calculateRanges(e,t,this.timeRanges,o)}},render(){const e=this.$props.editSlot||u.SchedulerEditSlot,t=this,o=t.numberOfDays+t.workWeekStart;return i.createVNode("div",{class:l.classNames("k-scheduler-row",{"k-middle-row":(this.rootIndex+1)%this.slotDivisions!==0})},[this.currentCellSlots.map(function(r,s){return i.createVNode(e,{index:s,onDataaction:this.handleDataAction,slotRender:this.$props.slotRender,viewSlot:this.$props.viewSlot,form:this.$props.form,row:this.rootIndex+d.GRID_OFFSET,col:this.timeRanges.length*(this.ri.groupIndex||0)+r.range.index,isWorkHour:c.isInTimeRange(r.zonedStart,t.workDayStart,t.workDayEnd),isWorkDay:0<=r.zonedStart.getDay()+(t.numberOfDays-o)&&(r.zonedStart.getDay()+(t.numberOfDays-o))%t.numberOfDays<=t.workWeekEnd+(t.numberOfDays-o),editable:t.$props.editable},null)},t)])},methods:{handleDataAction(e){this.$emit("dataaction",e)},calculateRanges(e,t,o,r){return o.map(function(s,a){return e.filter(n=>n.index===r.index&&n.range.index===a&&n.group.index===t)}).flat()}}});exports.DayViewMiddleRow=m;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("vue"),d=require("@progress/kendo-vue-common"),u=require("../../constants/main.js"),c=require("../../slots/SchedulerEditSlot.js"),l=require("../../utils/main.js"),m=a.defineComponent({name:"KendoDayViewMiddleRow",emits:["dataaction"],props:{editable:[Object,Boolean],slotRender:[String,Function,Object],viewSlot:[String,Function,Object],timeRanges:Array,timeSlots:Array,slotDivisions:{type:Number,default:2},rootIndex:{type:Number},root:Object,numberOfDays:Number,workDayStart:Date,workDayEnd:Date,workWeekStart:Number,workWeekEnd:Number,onDataAction:Function},inject:{ks:{default:null},ri:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const e=this.timeSlots,t=this.ri.groupIndex,o=this.root;return{ksSlots:{cSlots:this.calculateRanges(e,t,this.timeRanges,o)}}},watch:{currentCellSlots(e){this.ksSlots.cSlots=e}},computed:{currentCellSlots(){const e=this.timeSlots,t=this.ri.groupIndex,o=this.root;return this.calculateRanges(e,t,this.timeRanges,o)}},render(){var n;const e=this.$props.editSlot||((n=this.ks)==null?void 0:n.editSlot)||c.SchedulerEditSlot,t=this,o=t.numberOfDays+t.workWeekStart;return a.createVNode("div",{class:d.classNames("k-scheduler-row",{"k-middle-row":(this.rootIndex+1)%this.slotDivisions!==0})},[this.currentCellSlots.map(function(r,i){return a.createVNode(e,{index:i,onDataaction:this.handleDataAction,slotRender:this.$props.slotRender,viewSlot:this.$props.viewSlot,form:this.$props.form,row:this.rootIndex+u.GRID_OFFSET,col:this.timeRanges.length*(this.ri.groupIndex||0)+r.range.index,isWorkHour:l.isInTimeRange(r.zonedStart,t.workDayStart,t.workDayEnd),isWorkDay:0<=r.zonedStart.getDay()+(t.numberOfDays-o)&&(r.zonedStart.getDay()+(t.numberOfDays-o))%t.numberOfDays<=t.workWeekEnd+(t.numberOfDays-o),editable:t.$props.editable},null)},t)])},methods:{handleDataAction(e){l.emitDataAction(this,e)},calculateRanges(e,t,o,n){return o.map(function(r,i){return e.filter(s=>s.index===n.index&&s.range.index===i&&s.group.index===t)}).flat()}}});exports.DayViewMiddleRow=m;
@@ -5,13 +5,14 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { defineComponent as l, createVNode as s } from "vue";
8
+ import { defineComponent as l, createVNode as a } from "vue";
9
9
  import { classNames as d } from "@progress/kendo-vue-common";
10
10
  import { GRID_OFFSET as u } from "../../constants/main.mjs";
11
11
  import { SchedulerEditSlot as c } from "../../slots/SchedulerEditSlot.mjs";
12
- import { isInTimeRange as m } from "../../utils/main.mjs";
13
- const k = /* @__PURE__ */ l({
12
+ import { emitDataAction as m, isInTimeRange as h } from "../../utils/main.mjs";
13
+ const g = /* @__PURE__ */ l({
14
14
  name: "KendoDayViewMiddleRow",
15
+ emits: ["dataaction"],
15
16
  props: {
16
17
  editable: [Object, Boolean],
17
18
  slotRender: [String, Function, Object],
@@ -31,9 +32,12 @@ const k = /* @__PURE__ */ l({
31
32
  workDayEnd: Date,
32
33
  workWeekStart: Number,
33
34
  workWeekEnd: Number,
34
- onDataaction: Function
35
+ onDataAction: Function
35
36
  },
36
37
  inject: {
38
+ ks: {
39
+ default: null
40
+ },
37
41
  ri: {
38
42
  default: null
39
43
  },
@@ -66,13 +70,14 @@ const k = /* @__PURE__ */ l({
66
70
  }
67
71
  },
68
72
  render() {
69
- const e = this.$props.editSlot || c, t = this, o = t.numberOfDays + t.workWeekStart;
70
- return s("div", {
73
+ var n;
74
+ const e = this.$props.editSlot || ((n = this.ks) == null ? void 0 : n.editSlot) || c, t = this, o = t.numberOfDays + t.workWeekStart;
75
+ return a("div", {
71
76
  class: d("k-scheduler-row", {
72
77
  "k-middle-row": (this.rootIndex + 1) % this.slotDivisions !== 0
73
78
  })
74
79
  }, [this.currentCellSlots.map(function(r, i) {
75
- return s(e, {
80
+ return a(e, {
76
81
  index: i,
77
82
  onDataaction: this.handleDataAction,
78
83
  slotRender: this.$props.slotRender,
@@ -80,7 +85,7 @@ const k = /* @__PURE__ */ l({
80
85
  form: this.$props.form,
81
86
  row: this.rootIndex + u,
82
87
  col: this.timeRanges.length * (this.ri.groupIndex || 0) + r.range.index,
83
- isWorkHour: m(r.zonedStart, t.workDayStart, t.workDayEnd),
88
+ isWorkHour: h(r.zonedStart, t.workDayStart, t.workDayEnd),
84
89
  isWorkDay: 0 <= r.zonedStart.getDay() + (t.numberOfDays - o) && (r.zonedStart.getDay() + (t.numberOfDays - o)) % t.numberOfDays <= t.workWeekEnd + (t.numberOfDays - o),
85
90
  editable: t.$props.editable
86
91
  }, null);
@@ -88,15 +93,15 @@ const k = /* @__PURE__ */ l({
88
93
  },
89
94
  methods: {
90
95
  handleDataAction(e) {
91
- this.$emit("dataaction", e);
96
+ m(this, e);
92
97
  },
93
- calculateRanges(e, t, o, r) {
94
- return o.map(function(i, a) {
95
- return e.filter((n) => n.index === r.index && n.range.index === a && n.group.index === t);
98
+ calculateRanges(e, t, o, n) {
99
+ return o.map(function(r, i) {
100
+ return e.filter((s) => s.index === n.index && s.range.index === i && s.group.index === t);
96
101
  }).flat();
97
102
  }
98
103
  }
99
104
  });
100
105
  export {
101
- k as DayViewMiddleRow
106
+ g as DayViewMiddleRow
102
107
  };
@@ -13,7 +13,7 @@ export interface DayViewVerticalRowProps {
13
13
  daySlots: any[];
14
14
  dayRanges: any[];
15
15
  timeSlots: any[];
16
- onDataaction: (action: DataAction) => void;
16
+ onDataAction: (action: DataAction) => void;
17
17
  }
18
18
  /** @hidden */
19
19
  declare const DayViewVerticalRow: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
@@ -21,7 +21,7 @@ declare const DayViewVerticalRow: import('vue').DefineComponent<import('vue').Ex
21
21
  dayRanges: PropType<any[]>;
22
22
  daySlots: PropType<any[]>;
23
23
  timeSlots: PropType<any[]>;
24
- onDataaction: PropType<(action: DataAction) => void>;
24
+ onDataAction: PropType<(action: DataAction) => void>;
25
25
  }>, {}, {
26
26
  ksSlots: {
27
27
  cSlots: any;
@@ -31,13 +31,15 @@ declare const DayViewVerticalRow: import('vue').DefineComponent<import('vue').Ex
31
31
  }, {
32
32
  handleDataAction(action: DataAction): void;
33
33
  calculateRanges(daySlots: any, groupIndex: number, dayRanges: any): any;
34
- }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
34
+ }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, "dataaction"[], "dataaction", import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
35
35
  editable: PropType<boolean | object>;
36
36
  dayRanges: PropType<any[]>;
37
37
  daySlots: PropType<any[]>;
38
38
  timeSlots: PropType<any[]>;
39
- onDataaction: PropType<(action: DataAction) => void>;
40
- }>> & Readonly<{}>, {}, {}, {}, {}, string, () => {
39
+ onDataAction: PropType<(action: DataAction) => void>;
40
+ }>> & Readonly<{
41
+ onDataaction?: (...args: any[]) => any;
42
+ }>, {}, {}, {}, {}, string, () => {
41
43
  ksSlots: any;
42
44
  }, true, {}, any>;
43
45
  export { DayViewVerticalRow };
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("vue"),i=require("../../constants/main.js"),c=require("../../slots/SchedulerEditSlot.js"),d=require("./DayViewAllDayRowContent.js"),u=0,p=s.defineComponent({name:"KendoDayViewVerticalRow",props:{editable:[Object,Boolean],dayRanges:Array,daySlots:Array,timeSlots:Array,onDataaction:Function},inject:{ri:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const t=this.daySlots,e=this.ri.groupIndex;return{ksSlots:{cSlots:this.calculateRanges(t,e,this.dayRanges)}}},watch:{currentCellSlots(t){this.ksSlots.cSlots=t}},computed:{currentCellSlots(){const t=this.daySlots,e=this.ri.groupIndex;return this.calculateRanges(t,e,this.dayRanges)}},render(){const t=this.$props.editSlot||c.SchedulerEditSlot,e=this.ri.groupIndex,{timeSlots:n}=this.$props;return s.createVNode("div",{class:"k-scheduler-row"},[s.createVNode(d.DayViewAllDayRowContent,{groupIndex:e},null),this.currentCellSlots.map(function(a,o){const r=n.filter(l=>l.group.index===e&&l.range.index===u).length;return s.createVNode(t,{slotRender:this.$props.slotRender,viewSlot:this.$props.viewSlot,form:this.$props.form,index:o,onDataaction:this.handleDataAction,className:"k-scheduler-alldays-slot",row:r*(e||0)+(e||0)*i.GRID_OFFSET,col:o,expandable:!0,editable:this.$props.editable},null)},this)])},methods:{handleDataAction(t){this.$emit("dataaction",t)},calculateRanges(t,e,n){return n.map(function(a,o){return t.filter(r=>r.group.index===e&&r.range.index===o)}).flat()}}});exports.DayViewVerticalRow=p;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("vue"),c=require("../../constants/main.js"),d=require("../../slots/SchedulerEditSlot.js"),u=require("./DayViewAllDayRowContent.js"),h=require("../../utils/main.js"),p=0,S=s.defineComponent({name:"KendoDayViewVerticalRow",emits:["dataaction"],props:{editable:[Object,Boolean],dayRanges:Array,daySlots:Array,timeSlots:Array,onDataAction:Function},inject:{ks:{default:null},ri:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const t=this.daySlots,e=this.ri.groupIndex;return{ksSlots:{cSlots:this.calculateRanges(t,e,this.dayRanges)}}},watch:{currentCellSlots(t){this.ksSlots.cSlots=t}},computed:{currentCellSlots(){const t=this.daySlots,e=this.ri.groupIndex;return this.calculateRanges(t,e,this.dayRanges)}},render(){var r;const t=this.$props.editSlot||((r=this.ks)==null?void 0:r.editSlot)||d.SchedulerEditSlot,e=this.ri.groupIndex,{timeSlots:n}=this.$props;return s.createVNode("div",{class:"k-scheduler-row"},[s.createVNode(u.DayViewAllDayRowContent,{groupIndex:e},null),this.currentCellSlots.map(function(l,o){const i=n.filter(a=>a.group.index===e&&a.range.index===p).length;return s.createVNode(t,{slotRender:this.$props.slotRender,viewSlot:this.$props.viewSlot,form:this.$props.form,index:o,onDataaction:this.handleDataAction,className:"k-scheduler-alldays-slot",row:i*(e||0)+(e||0)*c.GRID_OFFSET,col:o,expandable:!0,editable:this.$props.editable},null)},this)])},methods:{handleDataAction(t){h.emitDataAction(this,t)},calculateRanges(t,e,n){return n.map(function(r,l){return t.filter(o=>o.group.index===e&&o.range.index===l)}).flat()}}});exports.DayViewVerticalRow=S;
@@ -5,20 +5,25 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { defineComponent as i, createVNode as n } from "vue";
9
- import { GRID_OFFSET as d } from "../../constants/main.mjs";
10
- import { SchedulerEditSlot as c } from "../../slots/SchedulerEditSlot.mjs";
11
- import { DayViewAllDayRowContent as u } from "./DayViewAllDayRowContent.mjs";
12
- const p = 0, f = /* @__PURE__ */ i({
8
+ import { defineComponent as d, createVNode as l } from "vue";
9
+ import { GRID_OFFSET as c } from "../../constants/main.mjs";
10
+ import { SchedulerEditSlot as u } from "../../slots/SchedulerEditSlot.mjs";
11
+ import { DayViewAllDayRowContent as p } from "./DayViewAllDayRowContent.mjs";
12
+ import { emitDataAction as h } from "../../utils/main.mjs";
13
+ const S = 0, R = /* @__PURE__ */ d({
13
14
  name: "KendoDayViewVerticalRow",
15
+ emits: ["dataaction"],
14
16
  props: {
15
17
  editable: [Object, Boolean],
16
18
  dayRanges: Array,
17
19
  daySlots: Array,
18
20
  timeSlots: Array,
19
- onDataaction: Function
21
+ onDataAction: Function
20
22
  },
21
23
  inject: {
24
+ ks: {
25
+ default: null
26
+ },
22
27
  ri: {
23
28
  default: null
24
29
  },
@@ -51,23 +56,24 @@ const p = 0, f = /* @__PURE__ */ i({
51
56
  }
52
57
  },
53
58
  render() {
54
- const t = this.$props.editSlot || c, e = this.ri.groupIndex, {
59
+ var r;
60
+ const t = this.$props.editSlot || ((r = this.ks) == null ? void 0 : r.editSlot) || u, e = this.ri.groupIndex, {
55
61
  timeSlots: s
56
62
  } = this.$props;
57
- return n("div", {
63
+ return l("div", {
58
64
  class: "k-scheduler-row"
59
- }, [n(u, {
65
+ }, [l(p, {
60
66
  groupIndex: e
61
- }, null), this.currentCellSlots.map(function(a, o) {
62
- const r = s.filter((l) => l.group.index === e && l.range.index === p).length;
63
- return n(t, {
67
+ }, null), this.currentCellSlots.map(function(n, o) {
68
+ const i = s.filter((a) => a.group.index === e && a.range.index === S).length;
69
+ return l(t, {
64
70
  slotRender: this.$props.slotRender,
65
71
  viewSlot: this.$props.viewSlot,
66
72
  form: this.$props.form,
67
73
  index: o,
68
74
  onDataaction: this.handleDataAction,
69
75
  className: "k-scheduler-alldays-slot",
70
- row: r * (e || 0) + (e || 0) * d,
76
+ row: i * (e || 0) + (e || 0) * c,
71
77
  col: o,
72
78
  expandable: !0,
73
79
  editable: this.$props.editable
@@ -76,15 +82,15 @@ const p = 0, f = /* @__PURE__ */ i({
76
82
  },
77
83
  methods: {
78
84
  handleDataAction(t) {
79
- this.$emit("dataaction", t);
85
+ h(this, t);
80
86
  },
81
87
  calculateRanges(t, e, s) {
82
- return s.map(function(a, o) {
83
- return t.filter((r) => r.group.index === e && r.range.index === o);
88
+ return s.map(function(r, n) {
89
+ return t.filter((o) => o.group.index === e && o.range.index === n);
84
90
  }).flat();
85
91
  }
86
92
  }
87
93
  });
88
94
  export {
89
- f as DayViewVerticalRow
95
+ R as DayViewVerticalRow
90
96
  };
@@ -25,7 +25,7 @@ export interface DayViewVerticalSlotsRowProps {
25
25
  workDayEnd: Date;
26
26
  workWeekStart: number;
27
27
  workWeekEnd: number;
28
- onDataaction: Function;
28
+ onDataAction: (action: DataAction) => void;
29
29
  }
30
30
  /** @hidden */
31
31
  declare const DayViewVerticalSlotsRow: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
@@ -51,7 +51,7 @@ declare const DayViewVerticalSlotsRow: import('vue').DefineComponent<import('vue
51
51
  workDayEnd: PropType<Date>;
52
52
  workWeekStart: PropType<number>;
53
53
  workWeekEnd: PropType<number>;
54
- onDataaction: PropType<Function>;
54
+ onDataAction: PropType<(action: DataAction) => void>;
55
55
  }>, {}, {
56
56
  ksSlots: {
57
57
  cSlots: any;
@@ -61,7 +61,7 @@ declare const DayViewVerticalSlotsRow: import('vue').DefineComponent<import('vue
61
61
  }, {
62
62
  handleDataAction(action: DataAction): void;
63
63
  calculateRanges(timeSlots: any, groupIndex: number, timeRanges: any, root: any): any;
64
- }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
64
+ }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, "dataaction"[], "dataaction", import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
65
65
  currentTimeMarker: {
66
66
  type: PropType<boolean>;
67
67
  default: boolean;
@@ -84,8 +84,10 @@ declare const DayViewVerticalSlotsRow: import('vue').DefineComponent<import('vue
84
84
  workDayEnd: PropType<Date>;
85
85
  workWeekStart: PropType<number>;
86
86
  workWeekEnd: PropType<number>;
87
- onDataaction: PropType<Function>;
88
- }>> & Readonly<{}>, {
87
+ onDataAction: PropType<(action: DataAction) => void>;
88
+ }>> & Readonly<{
89
+ onDataaction?: (...args: any[]) => any;
90
+ }>, {
89
91
  slotDivisions: number;
90
92
  currentTimeMarker: boolean;
91
93
  }, {}, {}, {}, string, () => {
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),S=require("../../constants/main.js"),c=require("../../utils/main.js"),x=require("../../slots/SchedulerEditSlot.js"),R=require("./DayViewRowContent.js"),b=require("../../components/CurrentTimeMarker.js"),f=require("../../components/CurrentTimeMarkerArrow.js"),I=o.defineComponent({name:"KendoDayViewVerticalSlotsRow",props:{currentTimeMarker:{type:Boolean,default:!0},slotRender:[String,Function,Object],viewSlot:[String,Function,Object],editable:[Object,Boolean],groupIndex:Number,root:Object,rootIndex:Number,filtered:Array,slotDivisions:{type:Number,default:2},timeSlots:Array,timeRanges:Array,numberOfDays:Number,workDayStart:Date,workDayEnd:Date,workWeekStart:Number,workWeekEnd:Number,onDataaction:Function},inject:{ri:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const e=this.timeSlots,t=this.root,r=this.groupIndex;return{ksSlots:{cSlots:this.calculateRanges(e,r,this.timeRanges,t)}}},watch:{currentCellSlots(e){this.ksSlots.cSlots=e}},computed:{currentCellSlots(){const e=this.timeSlots,t=this.root,r=this.groupIndex;return this.calculateRanges(e,r,this.timeRanges,t)}},render(){const e=this.$props.editSlot||x.SchedulerEditSlot,t=this.groupIndex,r=this,{root:n,rootIndex:a,slotDivisions:s,filtered:i,workDayStart:m,workDayEnd:h,numberOfDays:l,workWeekStart:d,workWeekEnd:g,viewSlot:p,renderSlot:w,form:k,editable:D}=this.$props;return o.createVNode("div",{class:"k-scheduler-row",key:n.index},[o.createVNode(R.DayViewRowContent,{contentSlot:n,isMaster:a%s===0,isLast:(a+1)%s===0,timeHeaderCell:this.$props.timeHeaderCell},null),this.currentCellSlots.map(function(u,y){return o.createVNode(e,{slotRender:w,viewSlot:p,form:k,onDataaction:r.handleDataAction,index:y,row:i.length*(t||0)+a+(t||0)*S.GRID_OFFSET+S.GRID_OFFSET,col:u.range.index,editable:D,isWorkHour:c.isInTimeRange(u.zonedStart,m,h),isWorkDay:0<=u.zonedStart.getDay()+(l-d)&&(u.zonedStart.getDay()+(l-d))%l<=g+(l-d)},null)},!0),this.$props.currentTimeMarker&&c.intersects(c.first(this.timeRanges).start,c.last(this.timeRanges).end,new Date,new Date,!0)&&[o.createVNode(f.CurrentTimeMarkerArrow,{groupIndex:t},null),o.createVNode(b.CurrentTimeMarker,{groupIndex:t},null)]])},methods:{handleDataAction(e){this.$emit("dataaction",e)},calculateRanges(e,t,r,n){return r.map(function(a,s){return e.filter(i=>i.index===n.index&&i.group.index===t&&i.range.index===s)}).flat()}}});exports.DayViewVerticalSlotsRow=I;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("vue"),m=require("../../constants/main.js"),s=require("../../utils/main.js"),x=require("../../slots/SchedulerEditSlot.js"),R=require("./DayViewRowContent.js"),b=require("../../components/CurrentTimeMarker.js"),I=require("../../components/CurrentTimeMarkerArrow.js"),V=o.defineComponent({name:"KendoDayViewVerticalSlotsRow",emits:["dataaction"],props:{currentTimeMarker:{type:Boolean,default:!0},slotRender:[String,Function,Object],viewSlot:[String,Function,Object],editable:[Object,Boolean],groupIndex:Number,root:Object,rootIndex:Number,filtered:Array,slotDivisions:{type:Number,default:2},timeSlots:Array,timeRanges:Array,numberOfDays:Number,workDayStart:Date,workDayEnd:Date,workWeekStart:Number,workWeekEnd:Number,onDataAction:Function},inject:{ks:{default:null},ri:{default:null},setSlots:{default:null}},provide(){return{ksSlots:this.ksSlots}},data(){const e=this.timeSlots,t=this.root,r=this.groupIndex;return{ksSlots:{cSlots:this.calculateRanges(e,r,this.timeRanges,t)}}},watch:{currentCellSlots(e){this.ksSlots.cSlots=e}},computed:{currentCellSlots(){const e=this.timeSlots,t=this.root,r=this.groupIndex;return this.calculateRanges(e,r,this.timeRanges,t)}},render(){var S;const e=this.$props.editSlot||((S=this.ks)==null?void 0:S.editSlot)||x.SchedulerEditSlot,t=this.groupIndex,r=this,{root:n,rootIndex:a,slotDivisions:l,filtered:i,workDayStart:h,workDayEnd:g,numberOfDays:u,workWeekStart:d,workWeekEnd:k,viewSlot:p,renderSlot:w,form:D,editable:y}=this.$props;return o.createVNode("div",{class:"k-scheduler-row",key:n.index},[o.createVNode(R.DayViewRowContent,{contentSlot:n,isMaster:a%l===0,isLast:(a+1)%l===0,timeHeaderCell:this.$props.timeHeaderCell},null),this.currentCellSlots.map(function(c,f){return o.createVNode(e,{slotRender:w,viewSlot:p,form:D,onDataaction:r.handleDataAction,index:f,row:i.length*(t||0)+a+(t||0)*m.GRID_OFFSET+m.GRID_OFFSET,col:c.range.index,editable:y,isWorkHour:s.isInTimeRange(c.zonedStart,h,g),isWorkDay:0<=c.zonedStart.getDay()+(u-d)&&(c.zonedStart.getDay()+(u-d))%u<=k+(u-d)},null)},!0),this.$props.currentTimeMarker&&s.intersects(s.first(this.timeRanges).start,s.last(this.timeRanges).end,new Date,new Date,!0)&&[o.createVNode(I.CurrentTimeMarkerArrow,{groupIndex:t},null),o.createVNode(b.CurrentTimeMarker,{groupIndex:t},null)]])},methods:{handleDataAction(e){s.emitDataAction(this,e)},calculateRanges(e,t,r,n){return r.map(function(a,l){return e.filter(i=>i.index===n.index&&i.group.index===t&&i.range.index===l)}).flat()}}});exports.DayViewVerticalSlotsRow=V;
@@ -5,15 +5,16 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { defineComponent as D, createVNode as i } from "vue";
9
- import { GRID_OFFSET as c } from "../../constants/main.mjs";
10
- import { isInTimeRange as x, intersects as y, last as b, first as R } from "../../utils/main.mjs";
11
- import { SchedulerEditSlot as I } from "../../slots/SchedulerEditSlot.mjs";
12
- import { DayViewRowContent as C } from "./DayViewRowContent.mjs";
13
- import { CurrentTimeMarker as v } from "../../components/CurrentTimeMarker.mjs";
14
- import { CurrentTimeMarkerArrow as E } from "../../components/CurrentTimeMarkerArrow.mjs";
15
- const F = /* @__PURE__ */ D({
8
+ import { defineComponent as x, createVNode as i } from "vue";
9
+ import { GRID_OFFSET as m } from "../../constants/main.mjs";
10
+ import { emitDataAction as y, isInTimeRange as b, intersects as R, last as I, first as C } from "../../utils/main.mjs";
11
+ import { SchedulerEditSlot as A } from "../../slots/SchedulerEditSlot.mjs";
12
+ import { DayViewRowContent as v } from "./DayViewRowContent.mjs";
13
+ import { CurrentTimeMarker as E } from "../../components/CurrentTimeMarker.mjs";
14
+ import { CurrentTimeMarkerArrow as N } from "../../components/CurrentTimeMarkerArrow.mjs";
15
+ const $ = /* @__PURE__ */ x({
16
16
  name: "KendoDayViewVerticalSlotsRow",
17
+ emits: ["dataaction"],
17
18
  props: {
18
19
  currentTimeMarker: {
19
20
  type: Boolean,
@@ -37,9 +38,12 @@ const F = /* @__PURE__ */ D({
37
38
  workDayEnd: Date,
38
39
  workWeekStart: Number,
39
40
  workWeekEnd: Number,
40
- onDataaction: Function
41
+ onDataAction: Function
41
42
  },
42
43
  inject: {
44
+ ks: {
45
+ default: null
46
+ },
43
47
  ri: {
44
48
  default: null
45
49
  },
@@ -72,51 +76,52 @@ const F = /* @__PURE__ */ D({
72
76
  }
73
77
  },
74
78
  render() {
75
- const t = this.$props.editSlot || I, e = this.groupIndex, r = this, {
79
+ var c;
80
+ const t = this.$props.editSlot || ((c = this.ks) == null ? void 0 : c.editSlot) || A, e = this.groupIndex, r = this, {
76
81
  root: o,
77
82
  rootIndex: s,
78
83
  slotDivisions: a,
79
84
  filtered: n,
80
- workDayStart: m,
81
- workDayEnd: S,
85
+ workDayStart: S,
86
+ workDayEnd: p,
82
87
  numberOfDays: l,
83
88
  workWeekStart: u,
84
- workWeekEnd: p,
85
- viewSlot: h,
86
- renderSlot: g,
87
- form: k,
88
- editable: f
89
+ workWeekEnd: h,
90
+ viewSlot: g,
91
+ renderSlot: k,
92
+ form: f,
93
+ editable: D
89
94
  } = this.$props;
90
95
  return i("div", {
91
96
  class: "k-scheduler-row",
92
97
  key: o.index
93
- }, [i(C, {
98
+ }, [i(v, {
94
99
  contentSlot: o,
95
100
  isMaster: s % a === 0,
96
101
  isLast: (s + 1) % a === 0,
97
102
  timeHeaderCell: this.$props.timeHeaderCell
98
103
  }, null), this.currentCellSlots.map(function(d, w) {
99
104
  return i(t, {
100
- slotRender: g,
101
- viewSlot: h,
102
- form: k,
105
+ slotRender: k,
106
+ viewSlot: g,
107
+ form: f,
103
108
  onDataaction: r.handleDataAction,
104
109
  index: w,
105
- row: n.length * (e || 0) + s + (e || 0) * c + c,
110
+ row: n.length * (e || 0) + s + (e || 0) * m + m,
106
111
  col: d.range.index,
107
- editable: f,
108
- isWorkHour: x(d.zonedStart, m, S),
109
- isWorkDay: 0 <= d.zonedStart.getDay() + (l - u) && (d.zonedStart.getDay() + (l - u)) % l <= p + (l - u)
112
+ editable: D,
113
+ isWorkHour: b(d.zonedStart, S, p),
114
+ isWorkDay: 0 <= d.zonedStart.getDay() + (l - u) && (d.zonedStart.getDay() + (l - u)) % l <= h + (l - u)
110
115
  }, null);
111
- }, !0), this.$props.currentTimeMarker && y(R(this.timeRanges).start, b(this.timeRanges).end, /* @__PURE__ */ new Date(), /* @__PURE__ */ new Date(), !0) && [i(E, {
116
+ }, !0), this.$props.currentTimeMarker && R(C(this.timeRanges).start, I(this.timeRanges).end, /* @__PURE__ */ new Date(), /* @__PURE__ */ new Date(), !0) && [i(N, {
112
117
  groupIndex: e
113
- }, null), i(v, {
118
+ }, null), i(E, {
114
119
  groupIndex: e
115
120
  }, null)]]);
116
121
  },
117
122
  methods: {
118
123
  handleDataAction(t) {
119
- this.$emit("dataaction", t);
124
+ y(this, t);
120
125
  },
121
126
  calculateRanges(t, e, r, o) {
122
127
  return r.map(function(s, a) {
@@ -126,5 +131,5 @@ const F = /* @__PURE__ */ D({
126
131
  }
127
132
  });
128
133
  export {
129
- F as DayViewVerticalSlotsRow
134
+ $ as DayViewVerticalSlotsRow
130
135
  };