@progress/kendo-vue-scheduler 9.0.0-develop.1 → 9.0.0-develop.2

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.mjs CHANGED
@@ -5,28 +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 j, createVNode as o, h as f } from "vue";
9
- import { getToday as M, findMaster as p, setField as l, getField as r, toSchedulerGroups as z, getModelFields as v } from "./utils/main.mjs";
10
- import { clone as c, validatePackage as L, shouldShowValidationUI as B, getLicenseMessage as _, templateRendering as d, getListeners as D, getTemplate as V, WatermarkOverlay as U, isRtl as G } from "@progress/kendo-vue-common";
11
- import { SchedulerHeader as K } from "./components/header/SchedulerHeader.mjs";
12
- import { provideIntlService as C } from "@progress/kendo-vue-intl";
13
- import { SchedulerNavigation as q } from "./components/header/navigation/SchedulerNavigation.mjs";
14
- import { addMonths as b, addDays as S } from "@progress/kendo-date-math";
15
- import { SchedulerFooter as J } from "./components/footer/SchedulerFooter.mjs";
16
- import { ToolbarSpacer as Q } from "@progress/kendo-vue-buttons";
17
- import { NavigationDatePicker as X } from "./components/header/navigation/NavigationDatePicker.mjs";
18
- import { ViewSelectorList as Y } from "./components/header/view-selector/ViewSelectorList.mjs";
19
- import { BusinessHours as Z } from "./components/footer/bussiness-hours/BusinessHours.mjs";
20
- import { packageMetadata as w } from "./package-metadata.mjs";
21
- import { AgendaView as ee } from "./views/agenda/AgendaView.mjs";
22
- import { TimelineView as te } from "./views/time/TimelineView.mjs";
8
+ import { defineComponent as B, createVNode as n, h as w, isVNode as _ } from "vue";
9
+ import { getToday as U, findMaster as p, setField as l, getField as a, toSchedulerGroups as G, getModelFields as D } from "./utils/main.mjs";
10
+ import { canUseDOM as b, clone as c, validatePackage as K, shouldShowValidationUI as q, getLicenseMessage as J, templateRendering as d, getListeners as V, getTemplate as C, WatermarkOverlay as Q, isRtl as X } from "@progress/kendo-vue-common";
11
+ import { SchedulerHeader as Y } from "./components/header/SchedulerHeader.mjs";
12
+ import { SchedulerAdaptiveHeader as Z } from "./components/header/SchedulerAdaptiveHeader.mjs";
13
+ import { provideIntlService as S, provideLocalizationService as ee } from "@progress/kendo-vue-intl";
14
+ import { SchedulerNavigation as te } from "./components/header/navigation/SchedulerNavigation.mjs";
15
+ import { addMonths as I, addDays as y } from "@progress/kendo-date-math";
16
+ import { SchedulerFooter as ie } from "./components/footer/SchedulerFooter.mjs";
17
+ import { ToolbarSpacer as $, Button as se } from "@progress/kendo-vue-buttons";
18
+ import { NavigationDatePicker as ae } from "./components/header/navigation/NavigationDatePicker.mjs";
19
+ import { ViewSelectorList as re } from "./components/header/view-selector/ViewSelectorList.mjs";
20
+ import { BusinessHours as le } from "./components/footer/bussiness-hours/BusinessHours.mjs";
21
+ import { today as R, messages as oe } from "./messages/main.mjs";
22
+ import { packageMetadata as g } from "./package-metadata.mjs";
23
+ import { AgendaView as ne } from "./views/agenda/AgendaView.mjs";
24
+ import { TimelineView as he } from "./views/time/TimelineView.mjs";
23
25
  import { DayView as m } from "./views/day/DayView.mjs";
24
- import { WeekView as ie } from "./views/week/WeekView.mjs";
25
- import { WorkWeekView as se } from "./views/week/WorkWeekView.mjs";
26
- import { MonthView as re } from "./views/month/MonthView.mjs";
27
- import { DATA_ACTION as g } from "./constants/main.mjs";
28
- import { useEditable as ae } from "./hooks/useEditable.mjs";
29
- const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
26
+ import { WeekView as de } from "./views/week/WeekView.mjs";
27
+ import { WorkWeekView as ce } from "./views/week/WorkWeekView.mjs";
28
+ import { MonthView as ue } from "./views/month/MonthView.mjs";
29
+ import { DATA_ACTION as v } from "./constants/main.mjs";
30
+ import { useEditable as pe } from "./hooks/useEditable.mjs";
31
+ function me(e) {
32
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !_(e);
33
+ }
34
+ const P = "{0:D}", x = "{0:d}", We = /* @__PURE__ */ B({
30
35
  name: "KendoScheduler",
31
36
  emits: ["datechange", "viewchange", "datachange", "itemclick", "itemdoubleclick", "slotclick", "slotdoubleclick", "taskclick", "taskdoubleclick"],
32
37
  props: {
@@ -88,28 +93,40 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
88
93
  dialogProps: Object,
89
94
  formProps: Object,
90
95
  dateHeaderCell: [String, Function, Object],
91
- timeHeaderCell: [String, Function, Object]
96
+ timeHeaderCell: [String, Function, Object],
97
+ adaptive: {
98
+ type: Boolean,
99
+ default: !1
100
+ }
92
101
  },
93
102
  computed: {
94
103
  isRtl() {
95
104
  return this.$props.rtl !== void 0 ? this.$props.rtl : this.currentRtl;
96
105
  },
106
+ isMobile() {
107
+ return this.$props.adaptive && this.media === "mobile";
108
+ },
97
109
  wrapperClassName() {
98
110
  return {
99
111
  "k-rtl": this.isRtl,
100
- "k-scheduler": !0
112
+ "k-scheduler": !0,
113
+ "k-scheduler-mobile": this.isMobile
101
114
  };
102
115
  },
103
116
  fields() {
104
- return v(this.$props.modelFields).fields;
117
+ return D(this.$props.modelFields).fields;
105
118
  }
106
119
  },
107
120
  mounted() {
108
- this.currentRtl = G(this.$el);
121
+ this.currentRtl = X(this.$el), this.calculateMedia(), this.$props.adaptive && b && window.ResizeObserver && (this.resizeObserver = new window.ResizeObserver(this.calculateMedia), this.resizeObserver.observe(this.$el));
122
+ },
123
+ unmounted() {
124
+ this.resizeObserver && this.resizeObserver.disconnect();
109
125
  },
110
126
  provide() {
111
127
  return {
112
128
  ks: this.ks,
129
+ ksMobile: () => this.isMobile,
113
130
  setActiveViewName: this.handleActiveViewNameChange,
114
131
  setActiveDate: this.handleDateChange,
115
132
  itemDoubleClick: this.handleItemDoubleClick,
@@ -131,7 +148,7 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
131
148
  }
132
149
  },
133
150
  data() {
134
- const e = C(this), i = this.$props.date || this.$props.defaultDate, s = this.$props.view || this.$props.defaultView || this.views[0] && this.views[0].name || "day", t = this.views.find((u) => u.name === s) || this.views[0] || o(m, null, null), a = this.getViewPropValue(t, "selectedDateFormat", s) || I, n = this.getViewPropValue(t, "selectedShortDateFormat", s) || $, h = this.getViewComponentByName(s).props.dateRange.default()({
151
+ const e = S(this), i = this.$props.date || this.$props.defaultDate, s = this.$props.view || this.$props.defaultView || this.views[0] && this.views[0].name || "day", t = this.views.find((u) => u.name === s) || this.views[0] || n(m, null, null), r = this.getViewPropValue(t, "selectedDateFormat", s) || P, o = this.getViewPropValue(t, "selectedShortDateFormat", s) || x, h = this.getViewComponentByName(s).props.dateRange.default()({
135
152
  intl: e,
136
153
  date: i,
137
154
  timezone: this.$props.timezone,
@@ -140,6 +157,7 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
140
157
  workWeekEnd: this.getViewPropValue(t, "workWeekEnd", s) || (e.firstDay() + this.getViewPropValue(t, "numberOfDays", s)) % 6
141
158
  });
142
159
  return {
160
+ media: "desktop",
143
161
  ks: {
144
162
  activeViewName: s,
145
163
  currentDate: i,
@@ -150,12 +168,12 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
150
168
  },
151
169
  views: this.views,
152
170
  view: t,
153
- fields: v(this.$props.modelFields).fields,
154
- groups: z(this.$props.group, this.$props.resources),
171
+ fields: D(this.$props.modelFields).fields,
172
+ groups: G(this.$props.group, this.$props.resources),
155
173
  dateRange: h,
156
174
  orientation: this.$props.group && this.$props.group.orientation ? this.$props.group.orientation : "horizontal",
157
- dateFormat: a,
158
- shortDateFormat: n,
175
+ dateFormat: r,
176
+ shortDateFormat: o,
159
177
  scheduler: this,
160
178
  dataItems: this.dataItems
161
179
  }
@@ -179,10 +197,10 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
179
197
  }
180
198
  },
181
199
  render() {
182
- L(w), this.showLicenseWatermark = B(w), this.licenseMessage = _(w);
183
- const e = this.views.find((T) => T.name === this.ks.activeViewName) || this.views[0] || o(m, null, null), i = this.getViewPropValue(this.ks.view, "slotDuration", this.ks.activeViewName), s = d.call(this, e.header || this.$props.header, D.call(this)), t = d.call(this, e.footer || this.$props.footer, D.call(this)), a = d.call(this, e.slot || this.$props.slotRender, {}), n = d.call(this, e.viewSlot || this.$props.viewSlot, {}), h = d.call(this, e.item || this.$props.item, {}), u = d.call(this, e.viewItem || this.$props.viewItem, {}), k = d.call(this, e.task || this.$props.task, {}), y = d.call(this, e.dateHeaderCell || this.$props.dateHeaderCell, {}), R = d.call(this, e.timeHeaderCell || this.$props.timeHeaderCell, {}), P = d.call(this, e.resizeHint || this.$props.resizeHint, {});
200
+ K(g), this.showLicenseWatermark = q(g), this.licenseMessage = J(g);
201
+ const e = this.views.find((L) => L.name === this.ks.activeViewName) || this.views[0] || n(m, null, null), i = this.getViewPropValue(this.ks.view, "slotDuration", this.ks.activeViewName), s = d.call(this, e.header || this.$props.header, V.call(this)), t = d.call(this, e.footer || this.$props.footer, V.call(this)), r = d.call(this, e.slot || this.$props.slotRender, {}), o = d.call(this, e.viewSlot || this.$props.viewSlot, {}), h = d.call(this, e.item || this.$props.item, {}), u = d.call(this, e.viewItem || this.$props.viewItem, {}), k = d.call(this, e.task || this.$props.task, {}), F = d.call(this, e.dateHeaderCell || this.$props.dateHeaderCell, {}), O = d.call(this, e.timeHeaderCell || this.$props.timeHeaderCell, {}), N = d.call(this, e.resizeHint || this.$props.resizeHint, {});
184
202
  this.ks.form = d.call(this, e.form || this.$props.form, {}), this.ks.dialogProps = e.dialogProps || this.$props.dialogProps, this.ks.formProps = e.formProps || this.$props.formProps;
185
- const F = ae(e.editable !== void 0 ? e.editable : this.$props.editable), x = this.getViewComponentByName(this.ks.activeViewName || e.name), N = {
203
+ const E = pe(e.editable !== void 0 ? e.editable : this.$props.editable), M = this.getViewComponentByName(this.ks.activeViewName || e.name), H = {
186
204
  ...this.$props,
187
205
  ...this.ks.view,
188
206
  showWorkHours: this.ks.showWorkHours,
@@ -190,29 +208,33 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
190
208
  views: void 0,
191
209
  defaultDate: void 0,
192
210
  dateRange: this.ks.dateRange,
193
- slotRender: a,
194
- viewSlot: n,
211
+ slotRender: r,
212
+ viewSlot: o,
195
213
  item: h,
196
214
  viewItem: u,
197
215
  task: k,
198
- dateHeaderCell: y,
199
- timeHeaderCell: R,
200
- resizeHint: P,
201
- editable: F
202
- }, E = o(K, null, {
203
- default: () => [o(q, {
216
+ dateHeaderCell: F,
217
+ timeHeaderCell: O,
218
+ resizeHint: N,
219
+ editable: E
220
+ }, z = this.isMobile ? n(Z, {
221
+ isRtl: this.isRtl,
222
+ onPrevclick: this.handlePrevClick,
223
+ onNextclick: this.handleNextClick
224
+ }, null) : n(Y, null, {
225
+ default: () => [n(te, {
204
226
  isRtl: this.isRtl,
205
227
  onPrevclick: this.handlePrevClick,
206
228
  onNextclick: this.handleNextClick,
207
229
  onTodayclick: this.handleTodayClick
208
- }, null), o(X, {
230
+ }, null), n(ae, {
209
231
  value: this.ks.currentDate,
210
232
  onChange: this.handleDatePickerChange
211
- }, null), o(Q, null, null), o(Y, null, null)]
212
- }), O = V.call(this, {
213
- h: f,
233
+ }, null), n($, null, null), n(re, null, null)]
234
+ }), A = C.call(this, {
235
+ h: w,
214
236
  template: s,
215
- defaultRendering: E,
237
+ defaultRendering: z,
216
238
  additionalProps: {
217
239
  currentDate: this.ks.currentDate
218
240
  },
@@ -222,25 +244,31 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
222
244
  todayclick: this.handleTodayClick,
223
245
  datepickerchange: this.handleDatePickerChange
224
246
  }
225
- }), H = o(J, null, {
226
- default: () => [o(Z, {
247
+ }), f = ee(this).toLanguageString(R, oe[R]), W = n(ie, null, {
248
+ default: () => [this.isMobile && n(se, {
249
+ class: "k-scheduler-today",
250
+ tabIndex: -1,
251
+ onClick: this.handleTodayClick
252
+ }, me(f) ? f : {
253
+ default: () => [f]
254
+ }), this.isMobile && n($, null, null), n(le, {
227
255
  slotDuration: i,
228
256
  onClick: this.handleShowWorkHoursClick
229
257
  }, null)]
230
- }), W = V.call(this, {
231
- h: f,
258
+ }), T = C.call(this, {
259
+ h: w,
232
260
  template: t,
233
- defaultRendering: H,
261
+ defaultRendering: W,
234
262
  additionalProps: {
235
263
  slotDuration: i
236
264
  },
237
265
  additionalListeners: {
238
266
  showworkhoursclick: this.handleShowWorkHoursClick
239
267
  }
240
- }), A = this.showLicenseWatermark ? o(U, {
268
+ }), j = this.showLicenseWatermark ? n(Q, {
241
269
  message: this.licenseMessage
242
270
  }, null) : null;
243
- return o("div", {
271
+ return n("div", {
244
272
  id: this.$props.id,
245
273
  style: {
246
274
  height: this.$props.height + "px"
@@ -253,25 +281,25 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
253
281
  "aria-labelledby": this.$props.ariaLabelledby,
254
282
  onFocusin: this.handleFocus,
255
283
  onFocusout: this.handleBlur
256
- }, [O, f(x, {
284
+ }, [A, w(M, {
257
285
  key: this.ks.view.name,
258
286
  onDataaction: this.handleDataAction,
259
- ...N
260
- }), W, A]);
287
+ ...H
288
+ }), T, j]);
261
289
  },
262
290
  methods: {
263
291
  getViewComponentByName(e) {
264
292
  switch (e.toLowerCase()) {
265
293
  case "week":
266
- return ie;
294
+ return de;
267
295
  case "workweek":
268
- return se;
296
+ return ce;
269
297
  case "agenda":
270
- return ee;
298
+ return ne;
271
299
  case "timeline":
272
- return te;
300
+ return he;
273
301
  case "month":
274
- return re;
302
+ return ue;
275
303
  default:
276
304
  return m;
277
305
  }
@@ -303,27 +331,27 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
303
331
  if (e.series)
304
332
  if (Array.isArray(e.dataItem))
305
333
  e.dataItem.map((t) => {
306
- const a = c(p(e.dataItem, this.fields, this.dataItems)), n = c(t);
307
- l(n, this.fields.originalStart, r(a, this.fields.originalStart)), l(n, this.fields.recurrenceId, r(a, this.fields.recurrenceId)), l(n, this.fields.recurrenceExceptions, r(a, this.fields.recurrenceExceptions)), s.push(n);
334
+ const r = c(p(e.dataItem, this.fields, this.dataItems)), o = c(t);
335
+ l(o, this.fields.originalStart, a(r, this.fields.originalStart)), l(o, this.fields.recurrenceId, a(r, this.fields.recurrenceId)), l(o, this.fields.recurrenceExceptions, a(r, this.fields.recurrenceExceptions)), s.push(o);
308
336
  });
309
337
  else {
310
- const t = c(p(e.dataItem, this.fields, this.dataItems)), a = c(e.dataItem);
311
- l(a, this.fields.originalStart, r(t, this.fields.originalStart)), l(a, this.fields.recurrenceId, r(t, this.fields.recurrenceId)), l(a, this.fields.recurrenceExceptions, r(t, this.fields.recurrenceExceptions)), s.push(a);
338
+ const t = c(p(e.dataItem, this.fields, this.dataItems)), r = c(e.dataItem);
339
+ l(r, this.fields.originalStart, a(t, this.fields.originalStart)), l(r, this.fields.recurrenceId, a(t, this.fields.recurrenceId)), l(r, this.fields.recurrenceExceptions, a(t, this.fields.recurrenceExceptions)), s.push(r);
312
340
  }
313
341
  else if (Array.isArray(e.dataItem))
314
342
  e.dataItem.map((t) => {
315
- const a = r(t, this.fields.recurrenceRule) !== null && r(t, this.fields.recurrenceRule) !== void 0;
316
- if (r(t, this.fields.recurrenceId) !== null && r(t, this.fields.recurrenceId) !== void 0 && a) {
317
- const h = c(p(t, this.fields, this.dataItems)), u = r(t, this.fields.originalStart), k = r(h, this.fields.recurrenceExceptions) || [];
343
+ const r = a(t, this.fields.recurrenceRule) !== null && a(t, this.fields.recurrenceRule) !== void 0;
344
+ if (a(t, this.fields.recurrenceId) !== null && a(t, this.fields.recurrenceId) !== void 0 && r) {
345
+ const h = c(p(t, this.fields, this.dataItems)), u = a(t, this.fields.originalStart), k = a(h, this.fields.recurrenceExceptions) || [];
318
346
  l(h, this.fields.recurrenceExceptions, [...k, u]), l(t, this.fields.recurrenceRule, null), s.push(h), i.push(t);
319
347
  } else
320
348
  s.push(t);
321
349
  });
322
350
  else {
323
- const t = r(e.dataItem, this.fields.recurrenceRule) !== null && r(e.dataItem, this.fields.recurrenceRule) !== void 0;
324
- if (r(e.dataItem, this.fields.recurrenceId) !== null && r(e.dataItem, this.fields.recurrenceId) !== void 0 && t) {
325
- const n = c(p(e.dataItem, this.fields, this.dataItems)), h = r(e.dataItem, this.fields.originalStart), u = r(n, this.fields.recurrenceExceptions) || [];
326
- l(n, this.fields.recurrenceExceptions, [...u, h]), l(e.dataItem, this.fields.recurrenceRule, null), s.push(n), i.push(e.dataItem);
351
+ const t = a(e.dataItem, this.fields.recurrenceRule) !== null && a(e.dataItem, this.fields.recurrenceRule) !== void 0;
352
+ if (a(e.dataItem, this.fields.recurrenceId) !== null && a(e.dataItem, this.fields.recurrenceId) !== void 0 && t) {
353
+ const o = c(p(e.dataItem, this.fields, this.dataItems)), h = a(e.dataItem, this.fields.originalStart), u = a(o, this.fields.recurrenceExceptions) || [];
354
+ l(o, this.fields.recurrenceExceptions, [...u, h]), l(e.dataItem, this.fields.recurrenceRule, null), s.push(o), i.push(e.dataItem);
327
355
  } else
328
356
  s.push(e.dataItem);
329
357
  }
@@ -335,13 +363,13 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
335
363
  handleRemove(e) {
336
364
  const i = [], s = [];
337
365
  if (e.series) {
338
- const t = c(p(e.dataItem, this.fields, this.dataItems)), a = c(e.dataItem);
339
- l(a, this.fields.originalStart, r(t, this.fields.originalStart)), l(a, this.fields.recurrenceId, r(t, this.fields.recurrenceId)), l(a, this.fields.recurrenceRule, r(t, this.fields.recurrenceRule)), l(a, this.fields.recurrenceExceptions, r(t, this.fields.recurrenceExceptions)), s.push(a);
340
- } else if (!(r(e.dataItem, this.fields.recurrenceRule) !== null && r(e.dataItem, this.fields.recurrenceRule) !== void 0))
366
+ const t = c(p(e.dataItem, this.fields, this.dataItems)), r = c(e.dataItem);
367
+ l(r, this.fields.originalStart, a(t, this.fields.originalStart)), l(r, this.fields.recurrenceId, a(t, this.fields.recurrenceId)), l(r, this.fields.recurrenceRule, a(t, this.fields.recurrenceRule)), l(r, this.fields.recurrenceExceptions, a(t, this.fields.recurrenceExceptions)), s.push(r);
368
+ } else if (!(a(e.dataItem, this.fields.recurrenceRule) !== null && a(e.dataItem, this.fields.recurrenceRule) !== void 0))
341
369
  s.push(e.dataItem);
342
370
  else {
343
- const a = c(p(e.dataItem, this.fields, this.dataItems)), n = r(e.dataItem, this.fields.originalStart), h = r(a, this.fields.recurrenceExceptions) || [];
344
- l(a, this.fields.recurrenceExceptions, [...h, n]), l(e.dataItem, this.fields.recurrenceRule, null), i.push(a);
371
+ const r = c(p(e.dataItem, this.fields, this.dataItems)), o = a(e.dataItem, this.fields.originalStart), h = a(r, this.fields.recurrenceExceptions) || [];
372
+ l(r, this.fields.recurrenceExceptions, [...h, o]), l(e.dataItem, this.fields.recurrenceRule, null), i.push(r);
345
373
  }
346
374
  this.handleDataChange({
347
375
  updated: i,
@@ -350,13 +378,13 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
350
378
  },
351
379
  handleDataAction(e) {
352
380
  switch (e.type) {
353
- case g.create:
381
+ case v.create:
354
382
  this.handleCreate(e);
355
383
  break;
356
- case g.update:
384
+ case v.update:
357
385
  this.handleUpdate(e);
358
386
  break;
359
- case g.remove:
387
+ case v.remove:
360
388
  this.handleRemove(e);
361
389
  break;
362
390
  }
@@ -383,17 +411,17 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
383
411
  },
384
412
  handleNextClick(e) {
385
413
  e.preventDefault();
386
- const i = this.getViewPropValue(this.ks.view, "step", this.ks.activeViewName) || this.getViewPropValue(this.ks.view, "numberOfDays", this.ks.activeViewName) || 1, t = i > 27 ? b(this.ks.currentDate, Math.round(i / 27)) : S(this.ks.currentDate, i);
414
+ const i = this.getViewPropValue(this.ks.view, "step", this.ks.activeViewName) || this.getViewPropValue(this.ks.view, "numberOfDays", this.ks.activeViewName) || 1, t = i > 27 ? I(this.ks.currentDate, Math.round(i / 27)) : y(this.ks.currentDate, i);
387
415
  this.setDate(t, e);
388
416
  },
389
417
  handlePrevClick(e) {
390
418
  e.preventDefault();
391
- const i = this.getViewPropValue(this.ks.view, "step", this.ks.activeViewName) || this.getViewPropValue(this.ks.view, "numberOfDays", this.ks.activeViewName) || 1, t = i > 27 ? b(this.ks.currentDate, -Math.round(i / 27)) : S(this.ks.currentDate, -i);
419
+ const i = this.getViewPropValue(this.ks.view, "step", this.ks.activeViewName) || this.getViewPropValue(this.ks.view, "numberOfDays", this.ks.activeViewName) || 1, t = i > 27 ? I(this.ks.currentDate, -Math.round(i / 27)) : y(this.ks.currentDate, -i);
392
420
  this.setDate(t, e);
393
421
  },
394
422
  handleTodayClick(e) {
395
423
  e.preventDefault();
396
- const i = M();
424
+ const i = U();
397
425
  this.setDate(i, e);
398
426
  },
399
427
  handleShowWorkHoursClick() {
@@ -430,8 +458,8 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
430
458
  });
431
459
  },
432
460
  updatePassedState(e) {
433
- const i = C(this), s = e || this.ks.activeViewName;
434
- this.ks.activeViewName = s, this.ks.view = this.views.find((t) => t.name === s) || this.views[0] || o(m, null, null), this.ks.dateFormat = this.getViewPropValue(this.ks.view, "selectedDateFormat", s) || I, this.ks.shortDateFormat = this.getViewPropValue(this.ks.view, "selectedShortDateFormat", s) || $, this.ks.dateRange = this.getViewComponentByName(s).props.dateRange.default()({
461
+ const i = S(this), s = e || this.ks.activeViewName;
462
+ this.ks.activeViewName = s, this.ks.view = this.views.find((t) => t.name === s) || this.views[0] || n(m, null, null), this.ks.dateFormat = this.getViewPropValue(this.ks.view, "selectedDateFormat", s) || P, this.ks.shortDateFormat = this.getViewPropValue(this.ks.view, "selectedShortDateFormat", s) || x, this.ks.dateRange = this.getViewComponentByName(s).props.dateRange.default()({
435
463
  intl: i,
436
464
  date: this.ks.currentDate,
437
465
  timezone: this.$props.timezone,
@@ -439,9 +467,12 @@ const I = "{0:D}", $ = "{0:d}", ye = /* @__PURE__ */ j({
439
467
  workWeekStart: this.getViewPropValue(this.ks.view, "workWeekStart", this.ks.activeViewName) || i.firstDay(),
440
468
  workWeekEnd: this.getViewPropValue(this.ks.view, "workWeekEnd", this.ks.activeViewName) || (i.firstDay() + this.getViewPropValue(this.ks.view, "numberOfDays", this.ks.activeViewName)) % 6
441
469
  });
470
+ },
471
+ calculateMedia() {
472
+ b && window.matchMedia && (this.media = window.matchMedia("(min-width: 1024px)").matches ? "desktop" : "mobile");
442
473
  }
443
474
  }
444
475
  });
445
476
  export {
446
- ye as Scheduler
477
+ We as Scheduler
447
478
  };
@@ -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 t=require("vue"),e=require("../../../messages/main.js"),n=require("@progress/kendo-vue-buttons"),i=require("@progress/kendo-vue-common"),l=require("@progress/kendo-vue-intl"),r=require("@progress/kendo-svg-icons");function u(o){return typeof o=="function"||Object.prototype.toString.call(o)==="[object Object]"&&!t.isVNode(o)}const c=t.defineComponent({name:"KendoBusinessHours",emits:{click:null},inject:{ks:{default:null},kendoLocalizationService:{default:null}},props:{slotDuration:Number},render(){let o;const s=i.getDefaultSlots(this);return this.localization=l.provideLocalizationService(this),this.slotDuration&&this.slotDuration<1440?t.createVNode(n.ToolbarItem,{class:"k-scheduler-navigation"},{default:()=>[s||t.createVNode(n.Button,{tabIndex:-1,icon:"clock",svgIcon:r.clockIcon,onClick:this.handleShowWorkHoursClick},u(o=this.localization.toLanguageString(this.ks.showWorkHours?e.showFullDay:e.showWorkDay,e.messages[this.ks.showWorkHours?e.showFullDay:e.showWorkDay]))?o:{default:()=>[o]})]}):null},methods:{handleShowWorkHoursClick(o){this.$emit("click",o)}}});exports.BusinessHours=c;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("vue"),e=require("../../../messages/main.js"),n=require("@progress/kendo-vue-buttons"),i=require("@progress/kendo-vue-common"),l=require("@progress/kendo-vue-intl"),r=require("@progress/kendo-svg-icons");function u(o){return typeof o=="function"||Object.prototype.toString.call(o)==="[object Object]"&&!t.isVNode(o)}const c=t.defineComponent({name:"KendoBusinessHours",emits:{click:null},inject:{ks:{default:null},kendoLocalizationService:{default:null}},props:{slotDuration:Number},render(){let o;const s=i.getDefaultSlots(this);return this.localization=l.provideLocalizationService(this),this.slotDuration&&this.slotDuration<1440?t.createVNode(n.ToolbarItem,{class:"k-scheduler-navigation"},{default:()=>[s||t.createVNode(n.Button,{tabIndex:-1,class:"k-scheduler-fullday",icon:"clock",svgIcon:r.clockIcon,onClick:this.handleShowWorkHoursClick},u(o=this.localization.toLanguageString(this.ks.showWorkHours?e.showFullDay:e.showWorkDay,e.messages[this.ks.showWorkHours?e.showFullDay:e.showWorkDay]))?o:{default:()=>[o]})]}):null},methods:{handleShowWorkHoursClick(o){this.$emit("click",o)}}});exports.BusinessHours=c;
@@ -5,8 +5,8 @@
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 i, isVNode as r } from "vue";
9
- import { showFullDay as e, showWorkDay as s, messages as n } from "../../../messages/main.mjs";
8
+ import { defineComponent as l, createVNode as e, isVNode as r } from "vue";
9
+ import { showFullDay as i, showWorkDay as s, messages as n } from "../../../messages/main.mjs";
10
10
  import { ToolbarItem as a, Button as c } from "@progress/kendo-vue-buttons";
11
11
  import { getDefaultSlots as u } from "@progress/kendo-vue-common";
12
12
  import { provideLocalizationService as h } from "@progress/kendo-vue-intl";
@@ -33,15 +33,16 @@ const w = /* @__PURE__ */ l({
33
33
  render() {
34
34
  let o;
35
35
  const t = u(this);
36
- return this.localization = h(this), this.slotDuration && this.slotDuration < 1440 ? i(a, {
36
+ return this.localization = h(this), this.slotDuration && this.slotDuration < 1440 ? e(a, {
37
37
  class: "k-scheduler-navigation"
38
38
  }, {
39
- default: () => [t || i(c, {
39
+ default: () => [t || e(c, {
40
40
  tabIndex: -1,
41
+ class: "k-scheduler-fullday",
41
42
  icon: "clock",
42
43
  svgIcon: m,
43
44
  onClick: this.handleShowWorkHoursClick
44
- }, d(o = this.localization.toLanguageString(this.ks.showWorkHours ? e : s, n[this.ks.showWorkHours ? e : s])) ? o : {
45
+ }, d(o = this.localization.toLanguageString(this.ks.showWorkHours ? i : s, n[this.ks.showWorkHours ? i : s])) ? o : {
45
46
  default: () => [o]
46
47
  })]
47
48
  }) : null;
@@ -0,0 +1,44 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { PropType } from 'vue';
9
+ /**
10
+ * @hidden
11
+ */
12
+ export interface SchedulerAdaptiveHeaderProps {
13
+ isRtl?: boolean;
14
+ onPrevclick?: (e: any) => void;
15
+ onNextclick?: (e: any) => void;
16
+ onTodayclick?: (e: any) => void;
17
+ onCreateclick?: (e: any) => void;
18
+ onCalendarclick?: (e: any) => void;
19
+ onPdfclick?: (e: any) => void;
20
+ }
21
+ /**
22
+ * @hidden
23
+ */
24
+ declare const SchedulerAdaptiveHeader: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
25
+ isRtl: PropType<boolean>;
26
+ onPrevclick: PropType<(e: any) => void>;
27
+ onNextclick: PropType<(e: any) => void>;
28
+ onTodayclick: PropType<(e: any) => void>;
29
+ onCreateclick: PropType<(e: any) => void>;
30
+ onCalendarclick: PropType<(e: any) => void>;
31
+ onPdfclick: PropType<(e: any) => void>;
32
+ }>, {}, {}, {}, {
33
+ handlePrevClick(e: any): void;
34
+ handleNextClick(e: any): void;
35
+ }, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
36
+ isRtl: PropType<boolean>;
37
+ onPrevclick: PropType<(e: any) => void>;
38
+ onNextclick: PropType<(e: any) => void>;
39
+ onTodayclick: PropType<(e: any) => void>;
40
+ onCreateclick: PropType<(e: any) => void>;
41
+ onCalendarclick: PropType<(e: any) => void>;
42
+ onPdfclick: PropType<(e: any) => void>;
43
+ }>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
44
+ export { SchedulerAdaptiveHeader };
@@ -0,0 +1,8 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),t=require("@progress/kendo-vue-buttons"),a=require("@progress/kendo-vue-intl"),l=require("../../messages/main.js"),o=require("@progress/kendo-svg-icons"),u=require("./view-selector/ViewSelectorList.js");function d(n){return typeof n=="function"||Object.prototype.toString.call(n)==="[object Object]"&&!e.isVNode(n)}const v=e.defineComponent({name:"KendoSchedulerAdaptiveHeader",props:{isRtl:Boolean,onPrevclick:Function,onNextclick:Function,onTodayclick:Function,onCreateclick:Function,onCalendarclick:Function,onPdfclick:Function},inject:{ks:{default:null},kendoLocalizationService:{default:null},kendoIntlService:{default:null}},render(){const n=a.provideLocalizationService(this),s=a.provideIntlService(this),i=n.toLanguageString(l.previousTitle,l.messages[l.previousTitle]),r=n.toLanguageString(l.nextTitle,l.messages[l.nextTitle]),c=s.formatDate(this.ks.currentDate,this.ks.shortDateFormat);return e.createVNode("div",null,[e.createVNode(t.Toolbar,{overflow:"none",class:"k-scheduler-toolbar"},{default:()=>[e.createVNode(t.ButtonGroup,{class:"k-scheduler-tools"},{default:()=>[e.createVNode(t.Button,{class:"k-pdf",icon:"file-pdf",svgIcon:o.filePdfIcon,tabIndex:-1,onClick:this.$props.onPdfclick},null),e.createVNode(t.Button,{class:"k-nav-calendar",icon:"calendar",svgIcon:o.calendarIcon,tabIndex:-1,onClick:this.$props.onCalendarclick},null),e.createVNode(t.Button,{class:"k-create-event",icon:"plus",svgIcon:o.plusIcon,tabIndex:-1,onClick:this.$props.onCreateclick},null)]}),e.createVNode(t.ToolbarSpacer,null,null),e.createVNode(u.ViewSelectorList,null,null)]}),e.createVNode(t.Toolbar,{overflow:"none",class:"k-scheduler-toolbar"},{default:()=>[e.createVNode(t.Button,{class:"k-nav-prev",icon:this.isRtl?"chevron-right":"chevron-left",svgIcon:this.isRtl?o.chevronRightIcon:o.chevronLeftIcon,title:i,"aria-label":i,tabIndex:-1,onClick:this.handlePrevClick},null),e.createVNode(t.ToolbarSpacer,null,null),e.createVNode(t.Button,{class:"k-nav-current",fillMode:"flat",tabIndex:-1},d(c)?c:{default:()=>[c]}),e.createVNode(t.ToolbarSpacer,null,null),e.createVNode(t.Button,{class:"k-nav-next",icon:this.isRtl?"chevron-left":"chevron-right",svgIcon:this.isRtl?o.chevronLeftIcon:o.chevronRightIcon,title:r,"aria-label":r,tabIndex:-1,onClick:this.handleNextClick},null)]})])},methods:{handlePrevClick(n){this.$emit("prevclick",n)},handleNextClick(n){this.$emit("nextclick",n)}}});exports.SchedulerAdaptiveHeader=v;
@@ -0,0 +1,108 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { defineComponent as v, createVNode as e, isVNode as p } from "vue";
9
+ import { Toolbar as r, ButtonGroup as f, Button as t, ToolbarSpacer as o } from "@progress/kendo-vue-buttons";
10
+ import { provideLocalizationService as m, provideIntlService as I } from "@progress/kendo-vue-intl";
11
+ import { previousTitle as a, messages as s, nextTitle as u } from "../../messages/main.mjs";
12
+ import { filePdfIcon as x, calendarIcon as g, plusIcon as b, chevronRightIcon as d, chevronLeftIcon as h } from "@progress/kendo-svg-icons";
13
+ import { ViewSelectorList as C } from "./view-selector/ViewSelectorList.mjs";
14
+ function S(n) {
15
+ return typeof n == "function" || Object.prototype.toString.call(n) === "[object Object]" && !p(n);
16
+ }
17
+ const $ = /* @__PURE__ */ v({
18
+ name: "KendoSchedulerAdaptiveHeader",
19
+ props: {
20
+ isRtl: Boolean,
21
+ onPrevclick: Function,
22
+ onNextclick: Function,
23
+ onTodayclick: Function,
24
+ onCreateclick: Function,
25
+ onCalendarclick: Function,
26
+ onPdfclick: Function
27
+ },
28
+ inject: {
29
+ ks: {
30
+ default: null
31
+ },
32
+ kendoLocalizationService: {
33
+ default: null
34
+ },
35
+ kendoIntlService: {
36
+ default: null
37
+ }
38
+ },
39
+ render() {
40
+ const n = m(this), k = I(this), c = n.toLanguageString(a, s[a]), i = n.toLanguageString(u, s[u]), l = k.formatDate(this.ks.currentDate, this.ks.shortDateFormat);
41
+ return e("div", null, [e(r, {
42
+ overflow: "none",
43
+ class: "k-scheduler-toolbar"
44
+ }, {
45
+ default: () => [e(f, {
46
+ class: "k-scheduler-tools"
47
+ }, {
48
+ default: () => [e(t, {
49
+ class: "k-pdf",
50
+ icon: "file-pdf",
51
+ svgIcon: x,
52
+ tabIndex: -1,
53
+ onClick: this.$props.onPdfclick
54
+ }, null), e(t, {
55
+ class: "k-nav-calendar",
56
+ icon: "calendar",
57
+ svgIcon: g,
58
+ tabIndex: -1,
59
+ onClick: this.$props.onCalendarclick
60
+ }, null), e(t, {
61
+ class: "k-create-event",
62
+ icon: "plus",
63
+ svgIcon: b,
64
+ tabIndex: -1,
65
+ onClick: this.$props.onCreateclick
66
+ }, null)]
67
+ }), e(o, null, null), e(C, null, null)]
68
+ }), e(r, {
69
+ overflow: "none",
70
+ class: "k-scheduler-toolbar"
71
+ }, {
72
+ default: () => [e(t, {
73
+ class: "k-nav-prev",
74
+ icon: this.isRtl ? "chevron-right" : "chevron-left",
75
+ svgIcon: this.isRtl ? d : h,
76
+ title: c,
77
+ "aria-label": c,
78
+ tabIndex: -1,
79
+ onClick: this.handlePrevClick
80
+ }, null), e(o, null, null), e(t, {
81
+ class: "k-nav-current",
82
+ fillMode: "flat",
83
+ tabIndex: -1
84
+ }, S(l) ? l : {
85
+ default: () => [l]
86
+ }), e(o, null, null), e(t, {
87
+ class: "k-nav-next",
88
+ icon: this.isRtl ? "chevron-left" : "chevron-right",
89
+ svgIcon: this.isRtl ? h : d,
90
+ title: i,
91
+ "aria-label": i,
92
+ tabIndex: -1,
93
+ onClick: this.handleNextClick
94
+ }, null)]
95
+ })]);
96
+ },
97
+ methods: {
98
+ handlePrevClick(n) {
99
+ this.$emit("prevclick", n);
100
+ },
101
+ handleNextClick(n) {
102
+ this.$emit("nextclick", n);
103
+ }
104
+ }
105
+ });
106
+ export {
107
+ $ as SchedulerAdaptiveHeader
108
+ };