@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.
- package/Scheduler.d.ts +157 -56
- package/Scheduler.js +1 -1
- package/Scheduler.mjs +242 -214
- package/components/EventOverviewPopover.d.ts +62 -0
- package/components/EventOverviewPopover.js +8 -0
- package/components/EventOverviewPopover.mjs +191 -0
- package/components/MoreEventsPopover.d.ts +3 -1
- package/components/MoreEventsPopover.js +1 -1
- package/components/MoreEventsPopover.mjs +31 -27
- package/components/SchedulerActionButtons.js +1 -1
- package/components/SchedulerActionButtons.mjs +1 -0
- package/components/SchedulerForm.d.ts +412 -2
- package/components/SchedulerForm.js +1 -1
- package/components/SchedulerForm.mjs +162 -60
- package/components/SchedulerQuickCreateForm.d.ts +118 -0
- package/components/SchedulerQuickCreateForm.js +8 -0
- package/components/SchedulerQuickCreateForm.mjs +249 -0
- package/constants/main.d.ts +2 -0
- package/constants/main.js +1 -1
- package/constants/main.mjs +10 -9
- package/dist/cdn/js/kendo-vue-scheduler.js +1 -1
- package/editors/KeepResetCustomEventsDialog.d.ts +31 -0
- package/editors/KeepResetCustomEventsDialog.js +8 -0
- package/editors/KeepResetCustomEventsDialog.mjs +72 -0
- package/editors/SchedulerFormEditor.d.ts +151 -52
- package/editors/SchedulerFormEditor.js +1 -1
- package/editors/SchedulerFormEditor.mjs +192 -139
- package/editors/SchedulerRecurrenceDialog.d.ts +2 -2
- package/editors/SchedulerRecurrenceDialog.js +1 -1
- package/editors/SchedulerRecurrenceDialog.mjs +126 -131
- package/editors/ZonedSplitDateTime.d.ts +32 -3
- package/editors/ZonedSplitDateTime.js +1 -1
- package/editors/ZonedSplitDateTime.mjs +112 -47
- package/hooks/useCloseOnAnchorScrollOut.d.ts +10 -0
- package/hooks/useCloseOnAnchorScrollOut.js +8 -0
- package/hooks/useCloseOnAnchorScrollOut.mjs +43 -0
- package/hooks/useCustomEventsConfirmation.d.ts +20 -0
- package/hooks/useCustomEventsConfirmation.js +8 -0
- package/hooks/useCustomEventsConfirmation.mjs +48 -0
- package/hooks/useDeferredClick.d.ts +12 -0
- package/hooks/useDeferredClick.js +8 -0
- package/hooks/useDeferredClick.mjs +22 -0
- package/hooks/useExclusivePopover.d.ts +26 -0
- package/hooks/useExclusivePopover.js +8 -0
- package/hooks/useExclusivePopover.mjs +30 -0
- package/hooks/useRecurrenceSummary.d.ts +3 -0
- package/hooks/useRecurrenceSummary.js +1 -1
- package/hooks/useRecurrenceSummary.mjs +68 -41
- package/index.d.mts +4 -2
- package/index.d.ts +4 -2
- package/index.js +1 -1
- package/index.mjs +83 -78
- package/items/SchedulerEditItem.d.ts +116 -12
- package/items/SchedulerEditItem.js +1 -1
- package/items/SchedulerEditItem.mjs +212 -131
- package/items/SchedulerItem.d.ts +2 -1
- package/items/SchedulerItem.js +1 -1
- package/items/SchedulerItem.mjs +28 -23
- package/items/SchedulerProportionalViewItem.d.ts +1 -0
- package/items/SchedulerProportionalViewItem.js +1 -1
- package/items/SchedulerProportionalViewItem.mjs +83 -68
- package/items/SchedulerViewItem.d.ts +1 -0
- package/items/SchedulerViewItem.js +1 -1
- package/items/SchedulerViewItem.mjs +84 -75
- package/items/hooks/use-drag-item.js +1 -1
- package/items/hooks/use-drag-item.mjs +49 -48
- package/items/hooks/use-form-item.d.ts +1 -1
- package/items/hooks/use-remove-item.d.ts +1 -1
- package/items/hooks/use-resize-item.js +1 -1
- package/items/hooks/use-resize-item.mjs +74 -65
- package/messages/main.d.ts +42 -0
- package/messages/main.js +1 -1
- package/messages/main.mjs +303 -275
- package/models/InternalDataAction.d.ts +13 -0
- package/models/SchedulerView.d.ts +1 -1
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +13 -12
- package/recurrence/RecurrenceEditor.js +1 -1
- package/recurrence/RecurrenceEditor.mjs +42 -42
- package/recurrence/common.d.ts +10 -0
- package/recurrence/common.js +1 -1
- package/recurrence/common.mjs +39 -35
- package/services/itemsService.d.ts +5 -2
- package/services/itemsService.js +1 -1
- package/services/itemsService.mjs +46 -33
- package/services/occurrenceService.js +1 -1
- package/services/occurrenceService.mjs +18 -18
- package/slots/SchedulerEditSlot.d.ts +70 -8
- package/slots/SchedulerEditSlot.js +1 -1
- package/slots/SchedulerEditSlot.mjs +222 -141
- package/slots/SchedulerSlot.js +1 -1
- package/slots/SchedulerSlot.mjs +20 -16
- package/slots/SchedulerViewSlot.d.ts +3 -0
- package/slots/SchedulerViewSlot.js +1 -1
- package/slots/SchedulerViewSlot.mjs +21 -15
- package/tasks/SchedulerEditTask.d.ts +13 -2
- package/tasks/SchedulerEditTask.js +1 -1
- package/tasks/SchedulerEditTask.mjs +45 -30
- package/utils/main.d.ts +27 -0
- package/utils/main.js +1 -1
- package/utils/main.mjs +172 -136
- package/views/agenda/AgendaView.d.ts +6 -2
- package/views/agenda/AgendaView.js +1 -1
- package/views/agenda/AgendaView.mjs +31 -29
- package/views/agenda/AgendaViewBody.d.ts +3 -3
- package/views/agenda/AgendaViewBody.js +1 -1
- package/views/agenda/AgendaViewBody.mjs +31 -29
- package/views/common/SchedulerDrag.d.ts +4 -2
- package/views/common/SchedulerDrag.js +1 -1
- package/views/common/SchedulerDrag.mjs +8 -7
- package/views/common/SchedulerResize.d.ts +4 -2
- package/views/common/SchedulerResize.js +1 -1
- package/views/common/SchedulerResize.mjs +14 -12
- package/views/common/VerticalResourceIterator.d.ts +3 -3
- package/views/common/VerticalResourceIterator.js +1 -1
- package/views/common/VerticalResourceIterator.mjs +34 -33
- package/views/day/DayView.d.ts +2 -0
- package/views/day/DayView.js +1 -1
- package/views/day/DayView.mjs +9 -7
- package/views/day/DayViewAllDaySlots.d.ts +7 -5
- package/views/day/DayViewAllDaySlots.js +1 -1
- package/views/day/DayViewAllDaySlots.mjs +24 -21
- package/views/day/DayViewMiddleRow.d.ts +7 -5
- package/views/day/DayViewMiddleRow.js +1 -1
- package/views/day/DayViewMiddleRow.mjs +18 -13
- package/views/day/DayViewVerticalRow.d.ts +7 -5
- package/views/day/DayViewVerticalRow.js +1 -1
- package/views/day/DayViewVerticalRow.mjs +23 -17
- package/views/day/DayViewVerticalSlotsRow.d.ts +7 -5
- package/views/day/DayViewVerticalSlotsRow.js +1 -1
- package/views/day/DayViewVerticalSlotsRow.mjs +34 -29
- package/views/day/MultiDayView.d.ts +13 -7
- package/views/day/MultiDayView.js +1 -1
- package/views/day/MultiDayView.mjs +108 -95
- package/views/month/MonthView.d.ts +15 -4
- package/views/month/MonthView.js +1 -1
- package/views/month/MonthView.mjs +105 -68
- package/views/month/MonthViewBody.d.ts +3 -3
- package/views/month/MonthViewBody.js +1 -1
- package/views/month/MonthViewBody.mjs +18 -16
- package/views/time/MultiDayTimelineView.d.ts +6 -4
- package/views/time/MultiDayTimelineView.js +1 -1
- package/views/time/MultiDayTimelineView.mjs +64 -63
- package/views/time/TimelineView.d.ts +2 -0
- package/views/time/TimelineView.js +1 -1
- package/views/time/TimelineView.mjs +5 -3
- package/views/time/TimelineViewBody.d.ts +7 -5
- package/views/time/TimelineViewBody.js +1 -1
- package/views/time/TimelineViewBody.mjs +29 -27
- package/views/week/WeekView.d.ts +2 -0
- package/views/week/WeekView.js +1 -1
- package/views/week/WeekView.mjs +11 -10
- package/views/week/WorkWeekView.d.ts +2 -0
- package/views/week/WorkWeekView.js +1 -1
- package/views/week/WorkWeekView.mjs +17 -16
|
@@ -5,26 +5,33 @@
|
|
|
5
5
|
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
|
-
import { defineComponent as
|
|
9
|
-
import { DATA_ACTION as
|
|
10
|
-
import { Keys as
|
|
11
|
-
import { SchedulerViewItem as
|
|
12
|
-
import { SchedulerDrag as
|
|
13
|
-
import { SchedulerResize as
|
|
14
|
-
import { FORM_ITEM_ACTION as
|
|
15
|
-
import { SHOW_OCCURRENCE_DIALOG_ACTION as s, showOccurrenceDialogReducer as
|
|
16
|
-
import { REMOVE_ITEM_ACTION as
|
|
17
|
-
import { SHOW_REMOVE_DIALOG_ACTION as
|
|
18
|
-
import { DRAG_ITEM_ACTION as a, useDragItem as
|
|
19
|
-
import { RESIZE_ITEM_ACTION as r, useResizeItem as
|
|
20
|
-
import { SERIES_ACTION as
|
|
21
|
-
import { ITEMS_SELECT_ACTION as
|
|
22
|
-
import { compareSlots as
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
|
|
8
|
+
import { defineComponent as C, createVNode as u, h as k, Fragment as $, inject as w, shallowRef as E, watch as M } from "vue";
|
|
9
|
+
import { DATA_ACTION as S } from "../constants/main.mjs";
|
|
10
|
+
import { Keys as p, clone as F, getDefaultSlots as B, getTemplate as _ } from "@progress/kendo-vue-common";
|
|
11
|
+
import { SchedulerViewItem as T } from "./SchedulerViewItem.mjs";
|
|
12
|
+
import { SchedulerDrag as x } from "../views/common/SchedulerDrag.mjs";
|
|
13
|
+
import { SchedulerResize as K } from "../views/common/SchedulerResize.mjs";
|
|
14
|
+
import { FORM_ITEM_ACTION as n } from "./hooks/use-form-item.mjs";
|
|
15
|
+
import { SHOW_OCCURRENCE_DIALOG_ACTION as s, showOccurrenceDialogReducer as N } from "./hooks/use-show-occurrence-dialog.mjs";
|
|
16
|
+
import { REMOVE_ITEM_ACTION as c } from "./hooks/use-remove-item.mjs";
|
|
17
|
+
import { SHOW_REMOVE_DIALOG_ACTION as l, showRemoveDialogReducer as j } from "./hooks/use-show-remove-item-dialog.mjs";
|
|
18
|
+
import { DRAG_ITEM_ACTION as a, useDragItem as P } from "./hooks/use-drag-item.mjs";
|
|
19
|
+
import { RESIZE_ITEM_ACTION as r, useResizeItem as V } from "./hooks/use-resize-item.mjs";
|
|
20
|
+
import { SERIES_ACTION as m, seriesReducer as U } from "./hooks/use-series.mjs";
|
|
21
|
+
import { ITEMS_SELECT_ACTION as h } from "../hooks/use-items-selection.mjs";
|
|
22
|
+
import { compareSlots as v, emitDataAction as A, findMaster as H, compareItems as Y } from "../utils/main.mjs";
|
|
23
|
+
import { EventOverviewPopover as X } from "../components/EventOverviewPopover.mjs";
|
|
24
|
+
import { useDeferredClick as L } from "../hooks/useDeferredClick.mjs";
|
|
25
|
+
import { useExclusivePopover as G } from "../hooks/useExclusivePopover.mjs";
|
|
26
|
+
import { CUSTOM_EVENTS_CANCEL_KEY as W, useCustomEventsConfirmation as Z } from "../hooks/useCustomEventsConfirmation.mjs";
|
|
27
|
+
import { KeepResetCustomEventsDialog as q } from "../editors/KeepResetCustomEventsDialog.mjs";
|
|
28
|
+
import { SLOTS_FOCUS_ACTION as g } from "../hooks/use-slots-focus.mjs";
|
|
29
|
+
import { ITEMS_FOCUS_ACTION as D } from "../hooks/use-items-focus.mjs";
|
|
30
|
+
import { useEditable as J } from "../hooks/useEditable.mjs";
|
|
31
|
+
const Se = /* @__PURE__ */ C({
|
|
26
32
|
name: "KendoSchedulerEditItem",
|
|
27
33
|
inheritAttrs: !1,
|
|
34
|
+
emits: ["dataaction", "serieschange", "removeitemchange", "showoccurrencedialogchange", "showremovedialogchange", "formitemchange", "dragitemchange", "resizeitemchange", "focus", "mousedown", "mouseup", "click", "doubleclick", "removeclick", "press", "drag", "release", "resizepress", "resizestartdrag", "resizeenddrag", "resizerelease", "formsubmit", "cancel", "occurrenceclick", "seriesclick", "keydown", "keyup", "removeconfirm"],
|
|
28
35
|
props: {
|
|
29
36
|
tabIndex: {
|
|
30
37
|
type: Number,
|
|
@@ -90,7 +97,7 @@ const te = /* @__PURE__ */ A({
|
|
|
90
97
|
ignoreIsAllDay: Boolean,
|
|
91
98
|
itemRef: Object,
|
|
92
99
|
onRemoveclick: Function,
|
|
93
|
-
|
|
100
|
+
onDataAction: Function,
|
|
94
101
|
onFormItemChange: Function,
|
|
95
102
|
onDragitemchange: Function,
|
|
96
103
|
onResizeitemchange: Function
|
|
@@ -112,6 +119,24 @@ const te = /* @__PURE__ */ A({
|
|
|
112
119
|
default: null
|
|
113
120
|
}
|
|
114
121
|
},
|
|
122
|
+
setup(t) {
|
|
123
|
+
const e = Z(), i = w("ks", null), o = w("ksEventOverview", null), y = E(null), f = E(null), I = L(), d = () => {
|
|
124
|
+
y.value = null;
|
|
125
|
+
}, R = () => (o == null ? void 0 : o()) !== !1, O = (z, b = t.dataItem) => {
|
|
126
|
+
f.value = z.target.element, y.value = b;
|
|
127
|
+
};
|
|
128
|
+
return M([() => i == null ? void 0 : i.currentDate, () => i == null ? void 0 : i.activeViewName], () => {
|
|
129
|
+
I.cancel(), d();
|
|
130
|
+
}), G(() => !!y.value, d), {
|
|
131
|
+
...e,
|
|
132
|
+
overviewItem: y,
|
|
133
|
+
overviewAnchor: f,
|
|
134
|
+
deferredOverview: I,
|
|
135
|
+
dismissOverview: d,
|
|
136
|
+
openOverview: O,
|
|
137
|
+
overviewEnabled: R
|
|
138
|
+
};
|
|
139
|
+
},
|
|
115
140
|
provide() {
|
|
116
141
|
return {
|
|
117
142
|
ei: this.ei,
|
|
@@ -123,7 +148,8 @@ const te = /* @__PURE__ */ A({
|
|
|
123
148
|
ksRemoveDialogCancel: this.handleRemoveDialogCancel,
|
|
124
149
|
ksDeleteItem: this.handleDeleteItem,
|
|
125
150
|
ksFormDelete: this.handleFormDelete,
|
|
126
|
-
ksIsSeries: () => this.compSeries === !0
|
|
151
|
+
ksIsSeries: () => this.compSeries === !0,
|
|
152
|
+
[W]: this.cancelCustomEventsOnBack
|
|
127
153
|
};
|
|
128
154
|
},
|
|
129
155
|
data() {
|
|
@@ -179,32 +205,32 @@ const te = /* @__PURE__ */ A({
|
|
|
179
205
|
},
|
|
180
206
|
actionsReducerMap() {
|
|
181
207
|
return {
|
|
182
|
-
[
|
|
183
|
-
[
|
|
184
|
-
[
|
|
185
|
-
[
|
|
186
|
-
[
|
|
187
|
-
[
|
|
188
|
-
[
|
|
189
|
-
[
|
|
190
|
-
[
|
|
191
|
-
[
|
|
192
|
-
[
|
|
193
|
-
[
|
|
194
|
-
[
|
|
195
|
-
[
|
|
196
|
-
[
|
|
197
|
-
[
|
|
208
|
+
[m.set]: this.dispatchSeries,
|
|
209
|
+
[m.toggle]: this.dispatchSeries,
|
|
210
|
+
[m.reset]: this.dispatchSeries,
|
|
211
|
+
[h.select]: this.dispatchItemSelection,
|
|
212
|
+
[h.add]: this.dispatchItemSelection,
|
|
213
|
+
[h.remove]: this.dispatchItemSelection,
|
|
214
|
+
[h.reset]: this.dispatchItemSelection,
|
|
215
|
+
[h.selectNext]: this.dispatchItemSelection,
|
|
216
|
+
[h.selectPrev]: this.dispatchItemSelection,
|
|
217
|
+
[n.set]: this.dispatchFormItem,
|
|
218
|
+
[n.setMaster]: this.dispatchFormItem,
|
|
219
|
+
[n.reset]: this.dispatchFormItem,
|
|
220
|
+
[n.complete]: this.dispatchFormItem,
|
|
221
|
+
[c.set]: this.dispatchRemoveItem,
|
|
222
|
+
[c.reset]: this.dispatchRemoveItem,
|
|
223
|
+
[c.complete]: this.dispatchRemoveItem,
|
|
198
224
|
[s.close]: this.dispatchShowOccurrenceDialog,
|
|
199
225
|
[s.open]: this.dispatchShowOccurrenceDialog,
|
|
200
226
|
[s.set]: this.dispatchShowOccurrenceDialog,
|
|
201
227
|
[s.toggle]: this.dispatchShowOccurrenceDialog,
|
|
202
228
|
[s.reset]: this.dispatchShowOccurrenceDialog,
|
|
203
|
-
[
|
|
204
|
-
[
|
|
205
|
-
[
|
|
206
|
-
[
|
|
207
|
-
[
|
|
229
|
+
[l.close]: this.dispatchShowRemoveDialog,
|
|
230
|
+
[l.open]: this.dispatchShowRemoveDialog,
|
|
231
|
+
[l.set]: this.dispatchShowRemoveDialog,
|
|
232
|
+
[l.toggle]: this.dispatchShowRemoveDialog,
|
|
233
|
+
[l.reset]: this.dispatchShowRemoveDialog,
|
|
208
234
|
[a.start]: this.dispatchDragItem,
|
|
209
235
|
[a.drag]: this.dispatchDragItem,
|
|
210
236
|
[a.complete]: this.dispatchDragItem,
|
|
@@ -223,21 +249,21 @@ const te = /* @__PURE__ */ A({
|
|
|
223
249
|
[r.completeSeries]: this.dispatchResizeItem,
|
|
224
250
|
[r.set]: this.dispatchResizeItem,
|
|
225
251
|
[r.reset]: this.dispatchResizeItem,
|
|
226
|
-
[
|
|
227
|
-
[
|
|
228
|
-
[
|
|
229
|
-
[
|
|
230
|
-
[
|
|
231
|
-
[
|
|
252
|
+
[D.next]: this.dispatchViewItemsFocus,
|
|
253
|
+
[D.prev]: this.dispatchViewItemsFocus,
|
|
254
|
+
[g.left]: this.dispatchViewSlotsFocus,
|
|
255
|
+
[g.right]: this.dispatchViewSlotsFocus,
|
|
256
|
+
[g.up]: this.dispatchViewSlotsFocus,
|
|
257
|
+
[g.down]: this.dispatchViewSlotsFocus,
|
|
232
258
|
null: () => {
|
|
233
259
|
}
|
|
234
260
|
};
|
|
235
261
|
}
|
|
236
262
|
},
|
|
237
263
|
render() {
|
|
238
|
-
const t =
|
|
239
|
-
let
|
|
240
|
-
const
|
|
264
|
+
const t = B(this), e = this.$props.drag || x, i = this.$props.resize || K, o = !!(this.bv.selectedItems && this.bv.selectedItems.some((d) => Y(d, this, this.ignoreIsAllDay)));
|
|
265
|
+
let y;
|
|
266
|
+
const f = u(T, {
|
|
241
267
|
ignoreIsAllDay: this.ignoreIsAllDay,
|
|
242
268
|
item: this.item,
|
|
243
269
|
uid: this.uid,
|
|
@@ -280,7 +306,7 @@ const te = /* @__PURE__ */ A({
|
|
|
280
306
|
resizeItem: this.compResizeItem,
|
|
281
307
|
removeItem: this.compRemoveItem,
|
|
282
308
|
itemRef: this.item,
|
|
283
|
-
selected:
|
|
309
|
+
selected: o,
|
|
284
310
|
tabIndex: this.currentTabIndex,
|
|
285
311
|
onKeydown: this.handleKeyDown,
|
|
286
312
|
onKeyup: this.handleKeyUp,
|
|
@@ -298,10 +324,10 @@ const te = /* @__PURE__ */ A({
|
|
|
298
324
|
onResizestartdrag: this.handleResizeStartDrag,
|
|
299
325
|
onResizerelease: this.handleResizeRelease
|
|
300
326
|
}, null);
|
|
301
|
-
|
|
302
|
-
h:
|
|
327
|
+
y = _.call(this, {
|
|
328
|
+
h: k,
|
|
303
329
|
template: this.$props.viewItem,
|
|
304
|
-
defaultRendering:
|
|
330
|
+
defaultRendering: f,
|
|
305
331
|
defaultSlots: t,
|
|
306
332
|
additionalListeners: {
|
|
307
333
|
// keydown: this.handleKeyDown,
|
|
@@ -324,9 +350,26 @@ const te = /* @__PURE__ */ A({
|
|
|
324
350
|
resizestartdrag: this.handleResizeStartDrag,
|
|
325
351
|
resizerelease: this.handleResizeRelease
|
|
326
352
|
}
|
|
327
|
-
})
|
|
353
|
+
});
|
|
354
|
+
const I = this.overviewItem && J(this.$props.editable);
|
|
355
|
+
return u($, null, [y, this.showCustomEventsDialog && u(q, {
|
|
356
|
+
onKeep: this.handleCustomEventsKeep,
|
|
357
|
+
onReset: this.handleCustomEventsReset,
|
|
358
|
+
onCancel: this.handleCustomEventsCancel
|
|
359
|
+
}, null), I ? u(X, {
|
|
360
|
+
show: !0,
|
|
361
|
+
anchor: this.overviewAnchor,
|
|
362
|
+
dataItem: this.overviewItem,
|
|
363
|
+
fields: this.ks.fields,
|
|
364
|
+
isRecurring: !!this.$props.isRecurring,
|
|
365
|
+
canEdit: I.edit && !this.$props.readonly,
|
|
366
|
+
canRemove: I.remove && !this.$props.readonly,
|
|
367
|
+
onClose: this.handleOverviewClose,
|
|
368
|
+
onEdit: this.handleOverviewEdit,
|
|
369
|
+
onDelete: this.handleOverviewDelete
|
|
370
|
+
}, null) : null, this.compDragItem && this.$props.editable.drag && (Array.isArray(this.compDragItem) ? this.compDragItem.map((d, R) => u(e, {
|
|
328
371
|
key: R,
|
|
329
|
-
dataItem:
|
|
372
|
+
dataItem: d,
|
|
330
373
|
ignoreIsAllDay: this.ignoreIsAllDay,
|
|
331
374
|
vertical: this.vertical,
|
|
332
375
|
viewItem: this.$props.viewItem,
|
|
@@ -337,9 +380,9 @@ const te = /* @__PURE__ */ A({
|
|
|
337
380
|
vertical: this.vertical,
|
|
338
381
|
viewItem: this.$props.viewItem,
|
|
339
382
|
item: this.$props.item
|
|
340
|
-
}, null)), this.compResizeItem && this.$props.editable.resize && (Array.isArray(this.compResizeItem) ? this.compResizeItem.map((
|
|
383
|
+
}, null)), this.compResizeItem && this.$props.editable.resize && (Array.isArray(this.compResizeItem) ? this.compResizeItem.map((d, R) => u(i, {
|
|
341
384
|
key: R,
|
|
342
|
-
dataItem:
|
|
385
|
+
dataItem: d,
|
|
343
386
|
format: this.format,
|
|
344
387
|
ignoreIsAllDay: this.ignoreIsAllDay,
|
|
345
388
|
vertical: this.vertical,
|
|
@@ -355,8 +398,34 @@ const te = /* @__PURE__ */ A({
|
|
|
355
398
|
}, null))]);
|
|
356
399
|
},
|
|
357
400
|
methods: {
|
|
401
|
+
handleOverviewClose() {
|
|
402
|
+
var t;
|
|
403
|
+
this.dismissOverview(), (t = this.overviewAnchor) == null || t.focus({
|
|
404
|
+
preventScroll: !0
|
|
405
|
+
});
|
|
406
|
+
},
|
|
407
|
+
handleOverviewEdit(t) {
|
|
408
|
+
this.dismissOverview(), t !== void 0 && this.dispatchSeries({
|
|
409
|
+
type: m.set,
|
|
410
|
+
payload: t
|
|
411
|
+
}), this.dispatchFormItem({
|
|
412
|
+
type: t ? n.setMaster : n.set,
|
|
413
|
+
payload: this.$props.dataItem
|
|
414
|
+
});
|
|
415
|
+
},
|
|
416
|
+
handleOverviewDelete(t) {
|
|
417
|
+
this.dismissOverview(), t !== void 0 && this.dispatchSeries({
|
|
418
|
+
type: m.set,
|
|
419
|
+
payload: t
|
|
420
|
+
}), this.dispatchRemoveItem({
|
|
421
|
+
type: c.set,
|
|
422
|
+
payload: this.$props.dataItem
|
|
423
|
+
}), this.dispatchShowRemoveDialog({
|
|
424
|
+
type: l.open
|
|
425
|
+
});
|
|
426
|
+
},
|
|
358
427
|
dispatchSeries(t, e) {
|
|
359
|
-
const i =
|
|
428
|
+
const i = U(this.compSeries, t);
|
|
360
429
|
this.currentSeries = i, this.$emit("serieschange", i);
|
|
361
430
|
},
|
|
362
431
|
dispatchItemSelection(t, e) {
|
|
@@ -365,15 +434,15 @@ const te = /* @__PURE__ */ A({
|
|
|
365
434
|
dispatchRemoveItem(t, e) {
|
|
366
435
|
let i;
|
|
367
436
|
switch (t.type) {
|
|
368
|
-
case
|
|
437
|
+
case c.set:
|
|
369
438
|
i = t.payload;
|
|
370
439
|
break;
|
|
371
|
-
case
|
|
440
|
+
case c.reset:
|
|
372
441
|
i = null;
|
|
373
442
|
break;
|
|
374
|
-
case
|
|
375
|
-
this.compRemoveItem && this
|
|
376
|
-
type:
|
|
443
|
+
case c.complete:
|
|
444
|
+
this.compRemoveItem && A(this, {
|
|
445
|
+
type: S.remove,
|
|
377
446
|
series: this.compSeries,
|
|
378
447
|
dataItem: this.compRemoveItem
|
|
379
448
|
}), i = null;
|
|
@@ -385,18 +454,18 @@ const te = /* @__PURE__ */ A({
|
|
|
385
454
|
this.currentRemoveItem = i, this.$emit("removeitemchange", i);
|
|
386
455
|
},
|
|
387
456
|
dispatchShowOccurrenceDialog(t, e) {
|
|
388
|
-
const i =
|
|
457
|
+
const i = N(this.compShowOccurrenceDialog, t);
|
|
389
458
|
this.currentShowOccurrenceDialog = i, this.$emit("showoccurrencedialogchange", i);
|
|
390
459
|
},
|
|
391
460
|
dispatchShowRemoveDialog(t, e) {
|
|
392
|
-
const i =
|
|
461
|
+
const i = j(this.compShowRemoveDialog, t);
|
|
393
462
|
this.currentShowRemoveDialog = i, this.$emit("showremovedialogchange", i);
|
|
394
463
|
},
|
|
395
464
|
dispatchDragItem(t, e) {
|
|
396
|
-
|
|
465
|
+
P.call(this, t);
|
|
397
466
|
},
|
|
398
467
|
dispatchResizeItem(t, e) {
|
|
399
|
-
|
|
468
|
+
V.call(this, t, e);
|
|
400
469
|
},
|
|
401
470
|
dispatchViewSlotsFocus(t, e) {
|
|
402
471
|
this.dispatchFocusedSlots(t, e);
|
|
@@ -407,21 +476,26 @@ const te = /* @__PURE__ */ A({
|
|
|
407
476
|
dispatchFormItem(t, e) {
|
|
408
477
|
let i;
|
|
409
478
|
switch (t.type) {
|
|
410
|
-
case
|
|
479
|
+
case n.set:
|
|
411
480
|
i = t.payload;
|
|
412
481
|
break;
|
|
413
|
-
case
|
|
482
|
+
case n.reset:
|
|
414
483
|
i = null;
|
|
415
484
|
break;
|
|
416
|
-
case
|
|
417
|
-
i =
|
|
485
|
+
case n.setMaster:
|
|
486
|
+
i = F(H(t.payload, this.ks.fields, this.ks.dataItems));
|
|
418
487
|
break;
|
|
419
|
-
case
|
|
420
|
-
this.compFormItem
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
424
|
-
|
|
488
|
+
case n.complete:
|
|
489
|
+
if (this.compFormItem) {
|
|
490
|
+
A(this, {
|
|
491
|
+
type: S.update,
|
|
492
|
+
series: this.compSeries,
|
|
493
|
+
dataItem: t.payload
|
|
494
|
+
}, void 0, () => {
|
|
495
|
+
this.currentFormItem = null, this.$emit("formitemchange", null);
|
|
496
|
+
});
|
|
497
|
+
return;
|
|
498
|
+
}
|
|
425
499
|
break;
|
|
426
500
|
default:
|
|
427
501
|
i = this.compFormItem;
|
|
@@ -479,13 +553,16 @@ const te = /* @__PURE__ */ A({
|
|
|
479
553
|
item: this
|
|
480
554
|
}));
|
|
481
555
|
}
|
|
482
|
-
this.$emit("click", t)
|
|
556
|
+
if (this.$emit("click", t), this.overviewEnabled()) {
|
|
557
|
+
const e = this.$props.dataItem;
|
|
558
|
+
this.deferredOverview.schedule(() => this.openOverview(t, e));
|
|
559
|
+
}
|
|
483
560
|
},
|
|
484
561
|
handleDoubleClick(t) {
|
|
485
|
-
if (this.onDoubleClickAction) {
|
|
562
|
+
if (this.deferredOverview.cancel(), this.dismissOverview(), this.onDoubleClickAction) {
|
|
486
563
|
const e = this.onDoubleClickAction(t, this.$props), i = this;
|
|
487
|
-
e && (Array.isArray(e) ? e.filter(Boolean).map((
|
|
488
|
-
...
|
|
564
|
+
e && (Array.isArray(e) ? e.filter(Boolean).map((o) => o && i.actionsReducerMap[o.type]({
|
|
565
|
+
...o,
|
|
489
566
|
item: i.dataItem
|
|
490
567
|
}, t)) : i.actionsReducerMap[e.type]({
|
|
491
568
|
...e,
|
|
@@ -612,7 +689,7 @@ const te = /* @__PURE__ */ A({
|
|
|
612
689
|
this.$emit("formsubmit", t);
|
|
613
690
|
},
|
|
614
691
|
handleCancel(t) {
|
|
615
|
-
if (this.onCancelAction) {
|
|
692
|
+
if (this.clearCustomEvents(), this.onCancelAction) {
|
|
616
693
|
const e = this.onCancelAction(t, this.$props);
|
|
617
694
|
e && (Array.isArray(e) ? e.filter(Boolean).map((i) => i && this.actionsReducerMap[i.type]({
|
|
618
695
|
...i,
|
|
@@ -651,6 +728,10 @@ const te = /* @__PURE__ */ A({
|
|
|
651
728
|
this.$emit("seriesclick", t);
|
|
652
729
|
},
|
|
653
730
|
handleKeyDown(t) {
|
|
731
|
+
if (this.overviewEnabled() && (t.event.key === "Enter" || t.event.keyCode === p.enter)) {
|
|
732
|
+
t.event.preventDefault(), this.openOverview(t), this.$emit("keydown", t);
|
|
733
|
+
return;
|
|
734
|
+
}
|
|
654
735
|
if (this.onKeyDownAction) {
|
|
655
736
|
const e = this.onKeyDownAction(t, this.$props);
|
|
656
737
|
e && (Array.isArray(e) ? e.filter(Boolean).map((i) => i && this.actionsReducerMap[i.type]({
|
|
@@ -690,35 +771,35 @@ const te = /* @__PURE__ */ A({
|
|
|
690
771
|
this.$emit("removeconfirm", t);
|
|
691
772
|
},
|
|
692
773
|
handleDeleteItem(t) {
|
|
693
|
-
this
|
|
694
|
-
type:
|
|
774
|
+
A(this, {
|
|
775
|
+
type: S.remove,
|
|
695
776
|
series: this.compSeries,
|
|
696
777
|
dataItem: t
|
|
697
778
|
});
|
|
698
779
|
},
|
|
699
780
|
handleFormDelete(t) {
|
|
700
781
|
this.dispatchRemoveItem({
|
|
701
|
-
type:
|
|
782
|
+
type: c.set,
|
|
702
783
|
payload: t
|
|
703
784
|
}, null), this.dispatchShowRemoveDialog({
|
|
704
|
-
type:
|
|
785
|
+
type: l.open
|
|
705
786
|
}, null);
|
|
706
787
|
},
|
|
707
788
|
handleRemoveDialogCancel(t) {
|
|
708
789
|
this.compFormItem ? (this.dispatchRemoveItem({
|
|
709
|
-
type:
|
|
790
|
+
type: c.reset
|
|
710
791
|
}, null), this.dispatchShowRemoveDialog({
|
|
711
|
-
type:
|
|
792
|
+
type: l.close
|
|
712
793
|
}, null)) : this.handleCancel(t);
|
|
713
794
|
},
|
|
714
795
|
onClickAction(t, e) {
|
|
715
796
|
return [{
|
|
716
|
-
type: t.event.metaKey || t.event.ctrlKey ? this.compSelected && !this.compDragItem && !this.compResizeItem ?
|
|
797
|
+
type: t.event.metaKey || t.event.ctrlKey ? this.compSelected && !this.compDragItem && !this.compResizeItem ? h.remove : h.add : h.select
|
|
717
798
|
}];
|
|
718
799
|
},
|
|
719
800
|
onDoubleClickAction(t, e) {
|
|
720
801
|
return e.editable ? [{
|
|
721
|
-
type:
|
|
802
|
+
type: n.set,
|
|
722
803
|
payload: e.dataItem
|
|
723
804
|
}, e.isRecurring && {
|
|
724
805
|
type: s.open
|
|
@@ -726,12 +807,12 @@ const te = /* @__PURE__ */ A({
|
|
|
726
807
|
},
|
|
727
808
|
onRemoveClickAction(t, e) {
|
|
728
809
|
return e.editable ? [{
|
|
729
|
-
type:
|
|
810
|
+
type: c.set,
|
|
730
811
|
payload: e.dataItem
|
|
731
812
|
}, e.isRecurring ? {
|
|
732
813
|
type: s.open
|
|
733
814
|
} : {
|
|
734
|
-
type:
|
|
815
|
+
type: l.open
|
|
735
816
|
}] : [];
|
|
736
817
|
},
|
|
737
818
|
onPressAction(t, e) {
|
|
@@ -816,23 +897,23 @@ const te = /* @__PURE__ */ A({
|
|
|
816
897
|
}];
|
|
817
898
|
if (this.compFormItem)
|
|
818
899
|
return [{
|
|
819
|
-
type:
|
|
900
|
+
type: m.set,
|
|
820
901
|
payload: !1
|
|
821
902
|
}, {
|
|
822
|
-
type:
|
|
903
|
+
type: n.set,
|
|
823
904
|
payload: e.dataItem
|
|
824
905
|
}, {
|
|
825
906
|
type: s.close
|
|
826
907
|
}];
|
|
827
908
|
if (this.compRemoveItem)
|
|
828
909
|
return [{
|
|
829
|
-
type:
|
|
910
|
+
type: m.set,
|
|
830
911
|
payload: !1
|
|
831
912
|
}, {
|
|
832
|
-
type:
|
|
913
|
+
type: c.set,
|
|
833
914
|
payload: e.dataItem
|
|
834
915
|
}, {
|
|
835
|
-
type:
|
|
916
|
+
type: l.open
|
|
836
917
|
}, {
|
|
837
918
|
type: s.close
|
|
838
919
|
}];
|
|
@@ -852,23 +933,23 @@ const te = /* @__PURE__ */ A({
|
|
|
852
933
|
}];
|
|
853
934
|
if (this.compFormItem)
|
|
854
935
|
return [{
|
|
855
|
-
type:
|
|
936
|
+
type: m.set,
|
|
856
937
|
payload: !0
|
|
857
938
|
}, {
|
|
858
|
-
type:
|
|
939
|
+
type: n.setMaster,
|
|
859
940
|
payload: e.dataItem
|
|
860
941
|
}, {
|
|
861
942
|
type: s.close
|
|
862
943
|
}];
|
|
863
944
|
if (this.compRemoveItem)
|
|
864
945
|
return [{
|
|
865
|
-
type:
|
|
946
|
+
type: m.set,
|
|
866
947
|
payload: !0
|
|
867
948
|
}, {
|
|
868
|
-
type:
|
|
949
|
+
type: c.set,
|
|
869
950
|
payload: e.dataItem
|
|
870
951
|
}, {
|
|
871
|
-
type:
|
|
952
|
+
type: l.open
|
|
872
953
|
}, {
|
|
873
954
|
type: s.close
|
|
874
955
|
}];
|
|
@@ -876,50 +957,50 @@ const te = /* @__PURE__ */ A({
|
|
|
876
957
|
onKeyDownAction(t, e) {
|
|
877
958
|
let i;
|
|
878
959
|
switch (t.event.keyCode) {
|
|
879
|
-
case
|
|
960
|
+
case p.enter:
|
|
880
961
|
return [{
|
|
881
|
-
type:
|
|
962
|
+
type: n.set,
|
|
882
963
|
payload: e.dataItem
|
|
883
964
|
}, e.isRecurring && {
|
|
884
965
|
type: s.open
|
|
885
966
|
}];
|
|
886
|
-
case
|
|
967
|
+
case p.tab:
|
|
887
968
|
return [{
|
|
888
|
-
type: t.event.shiftKey ?
|
|
969
|
+
type: t.event.shiftKey ? D.prev : D.next,
|
|
889
970
|
ignoreIsAllDay: e.ignoreIsAllDay
|
|
890
971
|
}, {
|
|
891
|
-
type: t.event.shiftKey ?
|
|
972
|
+
type: t.event.shiftKey ? h.selectPrev : h.selectNext,
|
|
892
973
|
ignoreIsAllDay: e.ignoreIsAllDay
|
|
893
974
|
}];
|
|
894
|
-
case
|
|
895
|
-
return i = this.bv.slots.find((
|
|
896
|
-
type:
|
|
975
|
+
case p.up:
|
|
976
|
+
return i = this.bv.slots.find((o) => v(o.cSlot, e.slots[0])), [!!(e.slots.length && i) && {
|
|
977
|
+
type: g.up,
|
|
897
978
|
slot: i
|
|
898
979
|
}];
|
|
899
|
-
case
|
|
900
|
-
return i = this.bv.slots.find((
|
|
901
|
-
type:
|
|
980
|
+
case p.right:
|
|
981
|
+
return i = this.bv.slots.find((o) => v(o.cSlot, e.slots[0])), [!!(e.slots.length && i) && {
|
|
982
|
+
type: g.right,
|
|
902
983
|
slot: i
|
|
903
984
|
}];
|
|
904
|
-
case
|
|
905
|
-
return i = this.bv.slots.find((
|
|
906
|
-
type:
|
|
985
|
+
case p.down:
|
|
986
|
+
return i = this.bv.slots.find((o) => v(o.cSlot, e.slots[e.slots.length - 1])), [!!(e.slots.length && i) && {
|
|
987
|
+
type: g.down,
|
|
907
988
|
slot: i
|
|
908
989
|
}];
|
|
909
|
-
case
|
|
910
|
-
return i = this.bv.slots.find((
|
|
911
|
-
type:
|
|
990
|
+
case p.left:
|
|
991
|
+
return i = this.bv.slots.find((o) => v(o.cSlot.cSlot, e.slots[0])), [!!(e.slots.length && i) && {
|
|
992
|
+
type: g.left,
|
|
912
993
|
slot: i
|
|
913
994
|
}];
|
|
914
|
-
case
|
|
915
|
-
case
|
|
995
|
+
case p.delete:
|
|
996
|
+
case p.backspace:
|
|
916
997
|
return [{
|
|
917
|
-
type:
|
|
998
|
+
type: c.set,
|
|
918
999
|
payload: e.dataItem
|
|
919
1000
|
}, e.isRecurring ? {
|
|
920
1001
|
type: s.open
|
|
921
1002
|
} : {
|
|
922
|
-
type:
|
|
1003
|
+
type: l.open
|
|
923
1004
|
}];
|
|
924
1005
|
default:
|
|
925
1006
|
return;
|
|
@@ -927,30 +1008,30 @@ const te = /* @__PURE__ */ A({
|
|
|
927
1008
|
},
|
|
928
1009
|
onFormSubmitAction(t) {
|
|
929
1010
|
return {
|
|
930
|
-
type:
|
|
1011
|
+
type: n.complete,
|
|
931
1012
|
payload: t.value
|
|
932
1013
|
};
|
|
933
1014
|
},
|
|
934
1015
|
onRemoveConfirmAction() {
|
|
935
1016
|
return [{
|
|
936
|
-
type:
|
|
1017
|
+
type: c.complete
|
|
937
1018
|
}, {
|
|
938
1019
|
type: s.close
|
|
939
1020
|
}];
|
|
940
1021
|
},
|
|
941
1022
|
onCancelAction() {
|
|
942
1023
|
return [{
|
|
943
|
-
type:
|
|
1024
|
+
type: m.reset
|
|
944
1025
|
}, {
|
|
945
|
-
type:
|
|
1026
|
+
type: c.reset
|
|
946
1027
|
}, {
|
|
947
|
-
type:
|
|
1028
|
+
type: n.reset
|
|
948
1029
|
}, {
|
|
949
1030
|
type: a.reset
|
|
950
1031
|
}, {
|
|
951
1032
|
type: r.reset
|
|
952
1033
|
}, {
|
|
953
|
-
type:
|
|
1034
|
+
type: l.reset
|
|
954
1035
|
}, {
|
|
955
1036
|
type: s.reset
|
|
956
1037
|
}];
|
|
@@ -958,5 +1039,5 @@ const te = /* @__PURE__ */ A({
|
|
|
958
1039
|
}
|
|
959
1040
|
});
|
|
960
1041
|
export {
|
|
961
|
-
|
|
1042
|
+
Se as SchedulerEditItem
|
|
962
1043
|
};
|
package/items/SchedulerItem.d.ts
CHANGED
|
@@ -267,9 +267,10 @@ declare const SchedulerItem: import('vue').DefineComponent<import('vue').Extract
|
|
|
267
267
|
itemClassName(): {
|
|
268
268
|
[x: number]: any;
|
|
269
269
|
'k-event': boolean;
|
|
270
|
+
'k-event-all-day': boolean;
|
|
270
271
|
'k-selected': any;
|
|
271
272
|
'k-readonly': boolean;
|
|
272
|
-
'k-event-drag-hint':
|
|
273
|
+
'k-event-drag-hint': boolean;
|
|
273
274
|
'k-scheduler-marquee': any;
|
|
274
275
|
'k-marquee': any;
|
|
275
276
|
'k-first': boolean;
|