@primeui/scheduler-core 0.0.1-alpha.1 → 1.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. package/dist/{overlay-BYM9B6nC.d.mts → appointment-slots-DCiNFFed.d.mts} +2 -13
  2. package/dist/calendar/index.mjs +1 -1
  3. package/dist/{chunk-NMX4BW42.mjs → chunks/chunk-2YXHUV2A.mjs} +2 -2
  4. package/dist/{chunk-6PK5WSKT.mjs → chunks/chunk-56LJ2UG5.mjs} +3 -3
  5. package/dist/{chunk-FIBAZFC4.mjs → chunks/chunk-6Q5FR4PN.mjs} +1 -1
  6. package/dist/{chunk-NX46LPLF.mjs → chunks/chunk-BJFVXDZC.mjs} +2 -2
  7. package/dist/{chunk-ZUKUKGNK.mjs → chunks/chunk-DIYUG3BH.mjs} +7 -7
  8. package/dist/{chunk-TNKJPFGI.mjs → chunks/chunk-F2LYNUXG.mjs} +1 -1
  9. package/dist/{chunk-KQGRXTP5.mjs → chunks/chunk-HF32DKZY.mjs} +26 -270
  10. package/dist/chunks/chunk-HWGXSE6Q.mjs +269 -0
  11. package/dist/{chunk-HPC5B3AR.mjs → chunks/chunk-JCNXNPGM.mjs} +3 -3
  12. package/dist/{chunk-W2SJW3QQ.mjs → chunks/chunk-L6WPLJOO.mjs} +21 -50
  13. package/dist/{chunk-6OZAPQZ5.mjs → chunks/chunk-LMZ2J5Z5.mjs} +3 -3
  14. package/dist/{chunk-F5W5HD7S.mjs → chunks/chunk-LYPP7W7B.mjs} +79 -7
  15. package/dist/{chunk-6VYWVIGM.mjs → chunks/chunk-QBTFRSZM.mjs} +5 -5
  16. package/dist/{chunk-NZGJN7HG.mjs → chunks/chunk-RM6OQCEO.mjs} +2 -2
  17. package/dist/{chunk-2THQAZ26.mjs → chunks/chunk-URRTAW2Q.mjs} +7 -54
  18. package/dist/{chunk-WFUJWDST.mjs → chunks/chunk-XQAYO7CQ.mjs} +1 -1
  19. package/dist/controllers/index.d.mts +3 -3
  20. package/dist/controllers/index.mjs +946 -13
  21. package/dist/event/index.mjs +8 -8
  22. package/dist/index.d.mts +6 -13
  23. package/dist/index.mjs +32 -34
  24. package/dist/interaction/index.d.mts +2 -63
  25. package/dist/interaction/index.mjs +9 -9
  26. package/dist/month/index.mjs +6 -6
  27. package/dist/resource/index.mjs +1 -1
  28. package/dist/time-grid/index.d.mts +9 -2
  29. package/dist/time-grid/index.mjs +12 -13
  30. package/dist/timeline/index.d.mts +11 -1
  31. package/dist/timeline/index.mjs +7 -6
  32. package/dist/{touch-BhsMWsjf.d.mts → touch-B6xcJlyY.d.mts} +1 -1
  33. package/dist/utils/index.d.mts +2 -27
  34. package/dist/utils/index.mjs +16 -17
  35. package/dist/views/index.mjs +8 -8
  36. package/dist/views/timeline/index.mjs +4 -4
  37. package/dist/year/index.mjs +6 -6
  38. package/package.json +58 -3
  39. package/dist/chunk-5N4ZOBJV.mjs +0 -866
  40. package/dist/chunk-AAVM7UCG.mjs +0 -100
  41. /package/dist/{chunk-DYW6WUHE.mjs → chunks/chunk-6OTDPEJM.mjs} +0 -0
  42. /package/dist/{chunk-UMAMDBU4.mjs → chunks/chunk-73ID2V6E.mjs} +0 -0
  43. /package/dist/{chunk-C7ADJGNV.mjs → chunks/chunk-7TCZNLG7.mjs} +0 -0
  44. /package/dist/{chunk-5KORIWDT.mjs → chunks/chunk-AZRI6PHU.mjs} +0 -0
  45. /package/dist/{chunk-XUBQ2IQS.mjs → chunks/chunk-B4YDYPVO.mjs} +0 -0
  46. /package/dist/{chunk-SYJ5O4KH.mjs → chunks/chunk-IJH6YR4N.mjs} +0 -0
  47. /package/dist/{chunk-QDMZBJDV.mjs → chunks/chunk-P7CIUMQZ.mjs} +0 -0
  48. /package/dist/{chunk-2B3YLWHA.mjs → chunks/chunk-UKD2NVDC.mjs} +0 -0
  49. /package/dist/{chunk-QR2SVYAD.mjs → chunks/chunk-XMU4WSAX.mjs} +0 -0
@@ -1,6 +1,6 @@
1
- import { parseRRule } from './chunk-FIBAZFC4.mjs';
2
- import { timeStringToMinutes } from './chunk-WFUJWDST.mjs';
3
- import { createSchedulerDateFormatter, formatTimeRange } from './chunk-TNKJPFGI.mjs';
1
+ import { parseRRule } from './chunk-6Q5FR4PN.mjs';
2
+ import { timeStringToMinutes } from './chunk-XQAYO7CQ.mjs';
3
+ import { createSchedulerDateFormatter, formatTimeRange } from './chunk-F2LYNUXG.mjs';
4
4
 
5
5
  // src/utils/blocked-intervals.ts
6
6
  function parseDate(date) {
@@ -1,11 +1,11 @@
1
- import { hasSelection, canDropEventWithResourceConstraints } from './chunk-NX46LPLF.mjs';
2
- import { getView } from './chunk-ZUKUKGNK.mjs';
3
- import { canSelect, isRangeWithinBusinessHours } from './chunk-HPC5B3AR.mjs';
4
- import { parseRRule, serializeRRule, expandRRule } from './chunk-FIBAZFC4.mjs';
5
- import { getTimezoneOffset, getDatePartsInTimezone, isValidTimezone, createDateInTimezone } from './chunk-QDMZBJDV.mjs';
6
- import { startOfDay, endOfDay } from './chunk-WFUJWDST.mjs';
7
- import { createSchedulerDateFormatter } from './chunk-TNKJPFGI.mjs';
8
- import { resolveSchedulerCalendarModeForView, getSchedulerCalendarAdapter } from './chunk-DYW6WUHE.mjs';
1
+ import { hasSelection, canDropEventWithResourceConstraints } from './chunk-BJFVXDZC.mjs';
2
+ import { getView } from './chunk-DIYUG3BH.mjs';
3
+ import { canSelect, isRangeWithinBusinessHours } from './chunk-JCNXNPGM.mjs';
4
+ import { parseRRule, serializeRRule, expandRRule } from './chunk-6Q5FR4PN.mjs';
5
+ import { isValidTimezone, getTimezoneOffset, getDatePartsInTimezone, createDateInTimezone } from './chunk-P7CIUMQZ.mjs';
6
+ import { startOfDay, endOfDay } from './chunk-XQAYO7CQ.mjs';
7
+ import { createSchedulerDateFormatter } from './chunk-F2LYNUXG.mjs';
8
+ import { resolveSchedulerCalendarModeForView, getSchedulerCalendarAdapter } from './chunk-6OTDPEJM.mjs';
9
9
 
10
10
  // src/utils/locale.ts
11
11
  var defaultText = {
@@ -1041,12 +1041,13 @@ function formatOffsetForICS(offsetMinutes) {
1041
1041
  return `${sign}${hours}${minutes}`;
1042
1042
  }
1043
1043
  function generateVTimezone(timezone) {
1044
+ if (!isValidTimezone(timezone)) return [];
1044
1045
  if (timezone === "UTC") {
1045
1046
  return ["BEGIN:VTIMEZONE", "TZID:UTC", "BEGIN:STANDARD", "DTSTART:19700101T000000", "TZOFFSETFROM:+0000", "TZOFFSETTO:+0000", "END:STANDARD", "END:VTIMEZONE"];
1046
1047
  }
1047
1048
  const lines = [];
1048
1049
  lines.push("BEGIN:VTIMEZONE");
1049
- lines.push(`TZID:${timezone}`);
1050
+ lines.push(`TZID:${sanitizeICSParamValue(timezone)}`);
1050
1051
  const jan = new Date((/* @__PURE__ */ new Date()).getFullYear(), 0, 15);
1051
1052
  const jul = new Date((/* @__PURE__ */ new Date()).getFullYear(), 6, 15);
1052
1053
  const janOffset = getTimezoneOffset(jan, timezone);
@@ -1076,7 +1077,10 @@ function generateVTimezone(timezone) {
1076
1077
  return lines;
1077
1078
  }
1078
1079
  function escapeICSText(text) {
1079
- return text.replace(/\\/g, "\\\\").replace(/;/g, "\\;").replace(/,/g, "\\,").replace(/\n/g, "\\n");
1080
+ return text.replace(/\\/g, "\\\\").replace(/;/g, "\\;").replace(/,/g, "\\,").replace(/\r\n|\r|\n/g, "\\n");
1081
+ }
1082
+ function sanitizeICSParamValue(value) {
1083
+ return value.replace(/[\r\n";:,]/g, "");
1080
1084
  }
1081
1085
  function foldICSLine(line) {
1082
1086
  const maxLength = 75;
@@ -1346,7 +1350,7 @@ function exportToIcal(events, options = {}) {
1346
1350
  const now = /* @__PURE__ */ new Date();
1347
1351
  lines.push(`DTSTAMP:${formatDateToICS(now)}`);
1348
1352
  const start = toDate(event.start);
1349
- const eventTz = event.timezone;
1353
+ const eventTz = event.timezone && isValidTimezone(event.timezone) ? event.timezone : void 0;
1350
1354
  const recurrenceId = entry.recurrenceId;
1351
1355
  if (recurrenceId) {
1352
1356
  const recurrenceDate = toDate(recurrenceId);
@@ -1418,11 +1422,11 @@ function exportToIcal(events, options = {}) {
1418
1422
  }
1419
1423
  }
1420
1424
  if (event.metadata?.organizer) {
1421
- lines.push(foldICSLine(`ORGANIZER:${String(event.metadata.organizer)}`));
1425
+ lines.push(foldICSLine(`ORGANIZER:${escapeICSText(String(event.metadata.organizer))}`));
1422
1426
  }
1423
1427
  if (event.metadata?.attendees && Array.isArray(event.metadata.attendees)) {
1424
1428
  for (const attendee of event.metadata.attendees) {
1425
- lines.push(foldICSLine(`ATTENDEE:${attendee}`));
1429
+ lines.push(foldICSLine(`ATTENDEE:${escapeICSText(String(attendee))}`));
1426
1430
  }
1427
1431
  }
1428
1432
  if (event.metadata?.status) {
@@ -1438,10 +1442,11 @@ function exportToIcal(events, options = {}) {
1438
1442
  }
1439
1443
  }
1440
1444
  if (event.className) {
1441
- lines.push(foldICSLine(`CATEGORIES:${event.className}`));
1445
+ const categories = event.className.split(",").map((c) => escapeICSText(c.trim())).join(",");
1446
+ lines.push(foldICSLine(`CATEGORIES:${categories}`));
1442
1447
  }
1443
1448
  if (event.metadata?.url) {
1444
- lines.push(foldICSLine(`URL:${String(event.metadata.url)}`));
1449
+ lines.push(foldICSLine(`URL:${escapeICSText(String(event.metadata.url))}`));
1445
1450
  }
1446
1451
  lines.push("END:VEVENT");
1447
1452
  }
@@ -3618,40 +3623,6 @@ function resolvePrintRuntimeState(input) {
3618
3623
  };
3619
3624
  }
3620
3625
 
3621
- // src/utils/print-session.controller.ts
3622
- function resolvePrintSession(input) {
3623
- const runtime = resolvePrintRuntimeState({
3624
- view: input.view,
3625
- options: input.options,
3626
- pageChromeContext: input.pageChromeContext
3627
- });
3628
- return {
3629
- orientation: runtime.orientation,
3630
- scaleMode: runtime.scaleMode,
3631
- scaleFactor: runtime.scaleFactor,
3632
- pageChromeState: runtime.pageChromeState,
3633
- pageStyleRule: resolvePrintPageStyleRule(runtime.orientation)
3634
- };
3635
- }
3636
- function getIdlePrintSessionState() {
3637
- return {
3638
- orientation: "portrait",
3639
- scaleMode: "standard",
3640
- scaleFactor: 1,
3641
- pageChromeState: null,
3642
- pageStyleRule: ""
3643
- };
3644
- }
3645
- function resolvePrintColorAction(colorOption, hadColorClass) {
3646
- if (colorOption === true) {
3647
- return { type: "set", restoreAction: hadColorClass ? "add" : "remove" };
3648
- }
3649
- if (colorOption === false) {
3650
- return { type: "unset", restoreAction: hadColorClass ? "add" : "remove" };
3651
- }
3652
- return { type: "none" };
3653
- }
3654
-
3655
3626
  // src/utils/view-runtime.ts
3656
3627
  var DATE_GROUPING_VIEWS = /* @__PURE__ */ new Set(["dateWeek", "dateMonth"]);
3657
3628
  var TIMELINE_LIKE_VIEWS = /* @__PURE__ */ new Set(["timelineDay", "timelineWeek", "timelineMonth", "timelineYear", "resourceTimelineDay", "resourceTimelineWeek", "resourceTimelineMonth"]);
@@ -3922,4 +3893,4 @@ function sortMorePopoverEvents(events) {
3922
3893
  });
3923
3894
  }
3924
3895
 
3925
- export { DEFAULT_ADAPTIVE_OPTIONS, DEFAULT_AUTO_HEIGHT_OPTIONS, DEFAULT_STACKING_OPTIONS, DENSITY_CONFIGS, applyImportMerge, assignEventLanes, buildImportValidationReport, calculateAutoHeight, calculateCellRenderingInfo, calculateMaxOverlappingEvents, calculateResourceRowAutoHeight, calculateTimelineRowHeight, calculateWeekViewAutoHeight, canSelectForView, clampPrintScaleFactor, createAdaptiveRenderingState, defaultSchedulerText, detectImportFormat, exportScheduler, exportToCsv, exportToIcal, exportToJson, exportToPdf, exportToXlsx, formatPrintDate, formatPrintDateTime, formatPrintRange, getAutoHeightClasses, getAvailableLocales, getDefaultFirstDayOfWeek, getDensityCSSVars, getDensityClasses, getDensityConfig, getDensityFromContainerWidth, getEventDensityClasses, getIdlePrintSessionState, getLocaleConfig, getMoreText, getSchedulerText, getSchedulerWeekendToggleView, getStackedEventStyle, getStackingClasses, getVisibleEvents, importFromCsv, importFromIcal, importFromJson, importScheduler, isDirectTimeSelectionView, isRTL, isResourceLikeView, isTimedCreateView, isTimelineLikeView, normalizeAdaptiveOptions, normalizeAutoHeightOptions, normalizeStackingOptions, preparePdfData, prepareXlsxData, previewImportMerge, registerLocale, resolveCalendarViewRange, resolveClickCreateEnd, resolveCurrentViewRange, resolveDaysOfWeekForView, resolveEventDensity, resolveGroupedLaneGeometry, resolvePrintColorAction, resolvePrintFilters, resolvePrintOrientation, resolvePrintPageChromeState, resolvePrintPageStyleRule, resolvePrintRuntimeState, resolvePrintScale, resolvePrintSession, resolveSchedulerText, resolveSelectionEmitOutcome, resolveTimedColumnTextMode, resolveTimelineDefaultTextMode, sortMorePopoverEvents, toDateOnlyString, validateImportResult };
3896
+ export { DEFAULT_ADAPTIVE_OPTIONS, DEFAULT_AUTO_HEIGHT_OPTIONS, DEFAULT_STACKING_OPTIONS, DENSITY_CONFIGS, applyImportMerge, assignEventLanes, buildImportValidationReport, calculateAutoHeight, calculateCellRenderingInfo, calculateMaxOverlappingEvents, calculateResourceRowAutoHeight, calculateTimelineRowHeight, calculateWeekViewAutoHeight, canSelectForView, clampPrintScaleFactor, createAdaptiveRenderingState, defaultSchedulerText, detectImportFormat, exportScheduler, exportToCsv, exportToIcal, exportToJson, exportToPdf, exportToXlsx, formatPrintDate, formatPrintDateTime, formatPrintRange, getAutoHeightClasses, getAvailableLocales, getDefaultFirstDayOfWeek, getDensityCSSVars, getDensityClasses, getDensityConfig, getDensityFromContainerWidth, getEventDensityClasses, getLocaleConfig, getMoreText, getSchedulerText, getSchedulerWeekendToggleView, getStackedEventStyle, getStackingClasses, getVisibleEvents, importFromCsv, importFromIcal, importFromJson, importScheduler, isDirectTimeSelectionView, isRTL, isResourceLikeView, isTimedCreateView, isTimelineLikeView, normalizeAdaptiveOptions, normalizeAutoHeightOptions, normalizeStackingOptions, preparePdfData, prepareXlsxData, previewImportMerge, registerLocale, resolveCalendarViewRange, resolveClickCreateEnd, resolveCurrentViewRange, resolveDaysOfWeekForView, resolveEventDensity, resolveGroupedLaneGeometry, resolvePrintFilters, resolvePrintOrientation, resolvePrintPageChromeState, resolvePrintPageStyleRule, resolvePrintRuntimeState, resolvePrintScale, resolveSchedulerText, resolveSelectionEmitOutcome, resolveTimedColumnTextMode, resolveTimelineDefaultTextMode, sortMorePopoverEvents, toDateOnlyString, validateImportResult };
@@ -1,6 +1,6 @@
1
- import { getLocalTimezone, convertEventsToTimezone } from './chunk-QDMZBJDV.mjs';
2
- import { formatGregorianYear, formatGregorianMonthTitle, formatGregorianWeekday, formatGregorianDayNumber, toDateString } from './chunk-WFUJWDST.mjs';
3
- import { getSchedulerCalendarAdapter } from './chunk-DYW6WUHE.mjs';
1
+ import { getLocalTimezone, convertEventsToTimezone } from './chunk-P7CIUMQZ.mjs';
2
+ import { formatGregorianYear, formatGregorianMonthTitle, formatGregorianWeekday, formatGregorianDayNumber, toDateString } from './chunk-XQAYO7CQ.mjs';
3
+ import { getSchedulerCalendarAdapter } from './chunk-6OTDPEJM.mjs';
4
4
 
5
5
  // src/year/view-model.ts
6
6
  function toDate(value) {
@@ -1,10 +1,82 @@
1
- import { positionEventsForDay, getAllDayEventsForDay, positionAllDayEventsForWeek } from './chunk-6VYWVIGM.mjs';
2
- import { parseEvents, getTimedEventsForDayAndResource, eventMatchesResource } from './chunk-2B3YLWHA.mjs';
3
- import { getTimedBusinessHoursOverlays, getTimedBlockedIntervalsOverlays } from './chunk-AAVM7UCG.mjs';
4
- import { getAppointmentSlotIndicators, getAppointmentSlotOverlays } from './chunk-NZGJN7HG.mjs';
5
- import { getDatePartsInTimezone } from './chunk-QDMZBJDV.mjs';
6
- import { timeStringToMinutes, startOfDay, toDateString } from './chunk-WFUJWDST.mjs';
7
- import { resolveSchedulerCalendarModeForView, getSchedulerCalendarAdapter } from './chunk-DYW6WUHE.mjs';
1
+ import { positionEventsForDay, getAllDayEventsForDay, positionAllDayEventsForWeek } from './chunk-QBTFRSZM.mjs';
2
+ import { parseEvents, getTimedEventsForDayAndResource, eventMatchesResource } from './chunk-UKD2NVDC.mjs';
3
+ import { getAppointmentSlotIndicators, getAppointmentSlotOverlays } from './chunk-RM6OQCEO.mjs';
4
+ import { normalizeBusinessHours, getBlockedIntervalsForDay } from './chunk-JCNXNPGM.mjs';
5
+ import { getDatePartsInTimezone } from './chunk-P7CIUMQZ.mjs';
6
+ import { timeStringToMinutes, startOfDay, toDateString, minutesToPixels } from './chunk-XQAYO7CQ.mjs';
7
+ import { resolveSchedulerCalendarModeForView, getSchedulerCalendarAdapter } from './chunk-6OTDPEJM.mjs';
8
+
9
+ // src/utils/overlay.ts
10
+ function getTimedBusinessHoursOverlays(date, businessHours, slotMinTime, slotMaxTime, slotDuration, slotHeight) {
11
+ const configs = normalizeBusinessHours(businessHours);
12
+ if (configs.length === 0) return [];
13
+ const dayOfWeek = date.getDay();
14
+ const config = configs.find((c) => c.daysOfWeek.includes(dayOfWeek));
15
+ const overlays = [];
16
+ const slotMinMinutes = timeStringToMinutes(slotMinTime);
17
+ const slotMaxMinutes = timeStringToMinutes(slotMaxTime);
18
+ const pushOverlay = (startMinutes, endMinutes) => {
19
+ const clampedStart = Math.max(startMinutes, slotMinMinutes);
20
+ const clampedEnd = Math.min(endMinutes, slotMaxMinutes);
21
+ if (clampedStart >= clampedEnd) return;
22
+ const top = minutesToPixels(clampedStart - slotMinMinutes, slotDuration, slotHeight);
23
+ const height = minutesToPixels(clampedEnd - clampedStart, slotDuration, slotHeight);
24
+ overlays.push({
25
+ position: "absolute",
26
+ top: top === 0 ? "0" : `${top}px`,
27
+ left: "0",
28
+ right: "0",
29
+ height: `${height}px`,
30
+ pointerEvents: "none",
31
+ zIndex: "0"
32
+ });
33
+ };
34
+ if (!config) {
35
+ pushOverlay(slotMinMinutes, slotMaxMinutes);
36
+ return overlays;
37
+ }
38
+ const businessStartMinutes = timeStringToMinutes(config.startTime);
39
+ const businessEndMinutes = timeStringToMinutes(config.endTime);
40
+ pushOverlay(slotMinMinutes, businessStartMinutes);
41
+ pushOverlay(businessEndMinutes, slotMaxMinutes);
42
+ return overlays;
43
+ }
44
+ function getTimedBlockedIntervalsOverlays(date, blockedIntervals, slotMinTime, slotMaxTime, slotDuration, slotHeight, resourceId) {
45
+ if (!blockedIntervals) return [];
46
+ const intervals = getBlockedIntervalsForDay(blockedIntervals, date, resourceId);
47
+ if (intervals.length === 0) return [];
48
+ const overlays = [];
49
+ const slotMinMinutes = timeStringToMinutes(slotMinTime);
50
+ const slotMaxMinutes = timeStringToMinutes(slotMaxTime);
51
+ for (const interval of intervals) {
52
+ const intervalStartMinutes = interval.start.getHours() * 60 + interval.start.getMinutes();
53
+ const intervalEndMinutes = interval.end.getHours() * 60 + interval.end.getMinutes();
54
+ const clampedStart = Math.max(intervalStartMinutes, slotMinMinutes);
55
+ const clampedEnd = Math.min(intervalEndMinutes, slotMaxMinutes);
56
+ if (clampedStart >= clampedEnd) continue;
57
+ const top = minutesToPixels(clampedStart - slotMinMinutes, slotDuration, slotHeight);
58
+ const height = minutesToPixels(clampedEnd - clampedStart, slotDuration, slotHeight);
59
+ const style = {
60
+ position: "absolute",
61
+ top: `${top}px`,
62
+ left: "0",
63
+ right: "0",
64
+ height: `${height}px`,
65
+ pointerEvents: "none",
66
+ zIndex: "2"
67
+ };
68
+ if (interval.background) {
69
+ style.background = interval.background;
70
+ }
71
+ overlays.push({
72
+ style,
73
+ title: interval.title,
74
+ className: interval.className,
75
+ interval
76
+ });
77
+ }
78
+ return overlays;
79
+ }
8
80
 
9
81
  // src/time-grid/view-model.ts
10
82
  var RESOURCE_VIEWS = ["resourceDay", "resourceWeek"];
@@ -1,8 +1,8 @@
1
- import { filterEventsForDay, sortEvents, eventsOverlap, getEventStartMinutes, getEventEndMinutes } from './chunk-2B3YLWHA.mjs';
2
- import { isSchedulerAutoTextColor, markSchedulerAutoTextColor, filterEventsByCategory, getEventCategoryStyle, calculateContrastTextColor } from './chunk-C7ADJGNV.mjs';
3
- import { resolveSchedulerEventSurfaceColor } from './chunk-5KORIWDT.mjs';
4
- import { parseRRule, serializeRRule, expandRRule } from './chunk-FIBAZFC4.mjs';
5
- import { getLocalTimezone, convertEventsToTimezone } from './chunk-QDMZBJDV.mjs';
1
+ import { filterEventsForDay, sortEvents, eventsOverlap, getEventStartMinutes, getEventEndMinutes } from './chunk-UKD2NVDC.mjs';
2
+ import { isSchedulerAutoTextColor, markSchedulerAutoTextColor, filterEventsByCategory, getEventCategoryStyle, calculateContrastTextColor } from './chunk-7TCZNLG7.mjs';
3
+ import { resolveSchedulerEventSurfaceColor } from './chunk-AZRI6PHU.mjs';
4
+ import { parseRRule, serializeRRule, expandRRule } from './chunk-6Q5FR4PN.mjs';
5
+ import { getLocalTimezone, convertEventsToTimezone } from './chunk-P7CIUMQZ.mjs';
6
6
 
7
7
  // src/event/event-list.ts
8
8
  function upsertEventById(eventList, event) {
@@ -1,5 +1,5 @@
1
- import { startOfDay, timeStringToMinutes, addDays, minutesToPixels } from './chunk-WFUJWDST.mjs';
2
- import { createSchedulerDateFormatter, formatTimeRange } from './chunk-TNKJPFGI.mjs';
1
+ import { startOfDay, timeStringToMinutes, addDays, minutesToPixels } from './chunk-XQAYO7CQ.mjs';
2
+ import { createSchedulerDateFormatter, formatTimeRange } from './chunk-F2LYNUXG.mjs';
3
3
 
4
4
  // src/utils/appointment-slots.ts
5
5
  var DEFAULT_APPOINTMENT_SLOTS_OPTIONS = {
@@ -1,9 +1,9 @@
1
- import { canDropEventWithResourceConstraints, getResourceCapacity } from './chunk-NX46LPLF.mjs';
2
- import { getEventStart, moveEventTo, getEventEnd, resizeEventBy } from './chunk-2B3YLWHA.mjs';
3
- import { addDays, addYears, addMonths, parseTimeString, timeStringToMinutes, isSameDay, startOfWeek } from './chunk-WFUJWDST.mjs';
4
- import { formatTime, formatTimeRange, createSchedulerDateFormatter } from './chunk-TNKJPFGI.mjs';
5
- import { differenceInCalendarDays, addCalendarDaysToDate, resolveSchedulerCalendarModeForView, getSchedulerCalendarAdapter } from './chunk-DYW6WUHE.mjs';
6
- import { findResourceById } from './chunk-QR2SVYAD.mjs';
1
+ import { canDropEventWithResourceConstraints, getResourceCapacity } from './chunk-BJFVXDZC.mjs';
2
+ import { getEventStart, moveEventTo, getEventEnd, resizeEventBy } from './chunk-UKD2NVDC.mjs';
3
+ import { addDays, addYears, addMonths, parseTimeString, timeStringToMinutes, isSameDay, startOfWeek } from './chunk-XQAYO7CQ.mjs';
4
+ import { formatTime, formatTimeRange, createSchedulerDateFormatter } from './chunk-F2LYNUXG.mjs';
5
+ import { differenceInCalendarDays, addCalendarDaysToDate, resolveSchedulerCalendarModeForView, getSchedulerCalendarAdapter } from './chunk-6OTDPEJM.mjs';
6
+ import { findResourceById } from './chunk-XMU4WSAX.mjs';
7
7
 
8
8
  // src/interaction/drag.ts
9
9
  var DEFAULT_DRAG_MIN_DISTANCE = 5;
@@ -1552,53 +1552,6 @@ function buildResourceCapacityMap(input) {
1552
1552
  return output;
1553
1553
  }
1554
1554
 
1555
- // src/interaction/scheduler-actions.controller.ts
1556
- function resolveGlobalKeyAction(ctx) {
1557
- if (ctx.key === "Escape") {
1558
- if (ctx.morePopoverVisible) return { type: "dismiss-more-popover" };
1559
- if (ctx.popoverVisible) return { type: "dismiss-popover" };
1560
- if (ctx.quickInfoVisible) return { type: "dismiss-quickinfo" };
1561
- }
1562
- if (!ctx.isInsideRoot) return { type: "none" };
1563
- if (ctx.focusedEventId && (ctx.key === "Enter" || ctx.key === " ")) {
1564
- return { type: "activate-event", eventId: ctx.focusedEventId };
1565
- }
1566
- if (ctx.focusedEventId && ctx.key === "Escape") {
1567
- return { type: "escape-event-focus" };
1568
- }
1569
- if (ctx.isEditableElement) return { type: "none" };
1570
- if ((ctx.key === "Delete" || ctx.key === "Backspace") && ctx.selectedEventCount > 0) {
1571
- return { type: "delete-events" };
1572
- }
1573
- if (ctx.altKey && ctx.key >= "1" && ctx.key <= "9") {
1574
- const index = parseInt(ctx.key) - 1;
1575
- if (index < ctx.availableViewCount) {
1576
- return { type: "switch-view", viewIndex: index };
1577
- }
1578
- return { type: "none" };
1579
- }
1580
- const hasModifier = ctx.ctrlKey || ctx.metaKey;
1581
- if (hasModifier && ctx.key === "ArrowLeft") return { type: "navigate", direction: "prev" };
1582
- if (hasModifier && ctx.key === "ArrowRight") return { type: "navigate", direction: "next" };
1583
- if (hasModifier && ctx.key.toLowerCase() === "t") return { type: "go-today" };
1584
- if (!ctx.eventSelectionEnabled) return { type: "none" };
1585
- if (hasModifier && ctx.key.toLowerCase() === "a") return { type: "select-all" };
1586
- if (ctx.key === "Escape" && ctx.selectedEventCount > 0) {
1587
- return { type: "clear-event-selection" };
1588
- }
1589
- return { type: "none" };
1590
- }
1591
- function resolveOutsideClickAction(ctx) {
1592
- if (!ctx.isOutside || ctx.isDragging) {
1593
- return { clearFocus: false, clearDateSelection: false, clearEventSelection: false };
1594
- }
1595
- return {
1596
- clearFocus: ctx.hasFocus,
1597
- clearDateSelection: ctx.unselectOnOutsideClick && ctx.hasDateSelection,
1598
- clearEventSelection: ctx.unselectOnOutsideClick && ctx.eventSelectionEnabled && ctx.hasEventSelection
1599
- };
1600
- }
1601
-
1602
1555
  // src/interaction/multi-drag.ts
1603
1556
  function getTimeOfDayMs(date) {
1604
1557
  return (date.getHours() * 3600 + date.getMinutes() * 60 + date.getSeconds()) * 1e3;
@@ -1666,4 +1619,4 @@ function isEventResizableWithPermission(event, globalEditable, eventDurationEdit
1666
1619
  return isPermissionAllowed(resolver, { action: "resize", event, view });
1667
1620
  }
1668
1621
 
1669
- export { DEFAULT_DRAG_MIN_DISTANCE, DEFAULT_OVERSCAN, DEFAULT_SNAP_DURATION, RESIZE_HANDLE_SIZE, RESOURCE_VIEWS, VIRTUAL_THRESHOLD, applyDeltaToEvent, applyEventSelection, applyResizeToEvent, buildResourceCapacityMap, calculateDayDelta, calculateDragDelta, calculateNewEventTimes, calculateNewFocusedDate, calculateTimeDelta, calculateTotalWidth, calculateVirtualRange, calculateVisibleEvents, clampTime, clampTimeToSlotBounds, clearEventSelection, computeColumnTimedMultiDragOffsets, computeDayMultiDragOffsets, computeTimedMultiDragOffsets, createChunkedCells, createDragAutoScroller, createDragState, createResizeState, createSchedulerEventDropCandidate, createVirtualScrollState, dedupeConflicts, detectResizeEdge, evaluateDropConflict, evaluateResourceConflictDecision, eventBelongsToResource, filterEventsByPermission, filterVisibleIdsByResource, findCellForDate, findOverlappingEvents, formatEventDate, formatEventDuration, formatEventTimeRange, formatTimeToken, getCellAtPosition, getDayIndexFromX, getDayOffset, getDefaultFocusDate, getDefaultFocusDateForDay, getDefaultFocusDateForMonth, getDefaultFocusDateForWeek, getDefaultFocusDateForYear, getDisplayedMonthFromGrid, getEndOfWeek, getEndOfWeekForFocus, getEstimatedScrollPosition, getInlineEditTimeValue, getKeyboardAction, getNavigationDirectionForDay, getNavigationDirectionForMonth, getNavigationDirectionForWeek, getNavigationDirectionForYear, getPeriodNavigationDirection, getPointerCoords, getResizeCursor, getSchedulerEventDropDelta, getSchedulerTimedInteractionDeltaMs, getSchedulerTimedResizePreview, getSchedulerTimelineResizePreview, getScrollPositionForDate, getScrollPositionForNow, getSelectedEventsForMultiDrag, getStartOfWeek, getStartOfWeekForFocus, getTimeFromYPosition, getTimeOfDayMs, getVisibleChunks, getYPositionFromTime, handleKeyboardNavigation, hasInlineTimeChanged, invertSelection, isDateInDayView, isDateInMonthView, isDateInVisibleRange, isDateInWeekView, isDateInYearView, isEventDraggable, isEventDraggableWithPermission, isEventResizable, isEventResizableWithPermission, isMultiDragCandidate, isPermissionAllowed, isResourceView, normalizeEventSelectionOptions, normalizeInlineEditOptions, normalizeQuickInfoOptions, parseInlineEditTimeValue, parseInlineTimeToken, processConflictDecision, projectEventsWithCandidate, resolveAutoScrollDelta, resolveCapacityExceededPayloads, resolveGlobalKeyAction, resolveOutsideClickAction, resolveResourceConflictRuntime, selectAllVisibleEvents, shouldUseVirtualScrolling, snapTime, snapTimeToSlot, snapToSlot, toValidDate, updateConflictedEventIds, updateDragState, updateResizeState, updateVirtualScrollState, validateDragPosition, validateResize };
1622
+ export { DEFAULT_DRAG_MIN_DISTANCE, DEFAULT_OVERSCAN, DEFAULT_SNAP_DURATION, RESIZE_HANDLE_SIZE, RESOURCE_VIEWS, VIRTUAL_THRESHOLD, applyDeltaToEvent, applyEventSelection, applyResizeToEvent, buildResourceCapacityMap, calculateDayDelta, calculateDragDelta, calculateNewEventTimes, calculateNewFocusedDate, calculateTimeDelta, calculateTotalWidth, calculateVirtualRange, calculateVisibleEvents, clampTime, clampTimeToSlotBounds, clearEventSelection, computeColumnTimedMultiDragOffsets, computeDayMultiDragOffsets, computeTimedMultiDragOffsets, createChunkedCells, createDragAutoScroller, createDragState, createResizeState, createSchedulerEventDropCandidate, createVirtualScrollState, dedupeConflicts, detectResizeEdge, evaluateDropConflict, evaluateResourceConflictDecision, eventBelongsToResource, filterEventsByPermission, filterVisibleIdsByResource, findCellForDate, findOverlappingEvents, formatEventDate, formatEventDuration, formatEventTimeRange, formatTimeToken, getCellAtPosition, getDayIndexFromX, getDayOffset, getDefaultFocusDate, getDefaultFocusDateForDay, getDefaultFocusDateForMonth, getDefaultFocusDateForWeek, getDefaultFocusDateForYear, getDisplayedMonthFromGrid, getEndOfWeek, getEndOfWeekForFocus, getEstimatedScrollPosition, getInlineEditTimeValue, getKeyboardAction, getNavigationDirectionForDay, getNavigationDirectionForMonth, getNavigationDirectionForWeek, getNavigationDirectionForYear, getPeriodNavigationDirection, getPointerCoords, getResizeCursor, getSchedulerEventDropDelta, getSchedulerTimedInteractionDeltaMs, getSchedulerTimedResizePreview, getSchedulerTimelineResizePreview, getScrollPositionForDate, getScrollPositionForNow, getSelectedEventsForMultiDrag, getStartOfWeek, getStartOfWeekForFocus, getTimeFromYPosition, getTimeOfDayMs, getVisibleChunks, getYPositionFromTime, handleKeyboardNavigation, hasInlineTimeChanged, invertSelection, isDateInDayView, isDateInMonthView, isDateInVisibleRange, isDateInWeekView, isDateInYearView, isEventDraggable, isEventDraggableWithPermission, isEventResizable, isEventResizableWithPermission, isMultiDragCandidate, isPermissionAllowed, isResourceView, normalizeEventSelectionOptions, normalizeInlineEditOptions, normalizeQuickInfoOptions, parseInlineEditTimeValue, parseInlineTimeToken, processConflictDecision, projectEventsWithCandidate, resolveAutoScrollDelta, resolveCapacityExceededPayloads, resolveResourceConflictRuntime, selectAllVisibleEvents, shouldUseVirtualScrolling, snapTime, snapTimeToSlot, snapToSlot, toValidDate, updateConflictedEventIds, updateDragState, updateResizeState, updateVirtualScrollState, validateDragPosition, validateResize };
@@ -1,4 +1,4 @@
1
- import { createSchedulerDateFormatter } from './chunk-TNKJPFGI.mjs';
1
+ import { createSchedulerDateFormatter } from './chunk-F2LYNUXG.mjs';
2
2
 
3
3
  // src/utils/date.ts
4
4
  function getMonthDays(year, month) {
@@ -2,8 +2,8 @@ import { SchedulerEvent, DragDelta, EventDragState, EventResizeState, SchedulerV
2
2
  import { S as SchedulerGridCell } from '../date-D_CjQPmM.mjs';
3
3
  import { P as ParsedEvent } from '../event.utils-QSNdd-3W.mjs';
4
4
  import { SchedulerCalendarInteractionOptions } from '../calendar/index.mjs';
5
- import { d as SchedulerPointerInput, e as SchedulerRectInput } from '../touch-BhsMWsjf.mjs';
6
- export { r as getTimeFromYPosition, s as getYPositionFromTime } from '../touch-BhsMWsjf.mjs';
5
+ import { S as SchedulerPointerInput, a as SchedulerRectInput } from '../touch-B6xcJlyY.mjs';
6
+ export { g as getTimeFromYPosition, b as getYPositionFromTime } from '../touch-B6xcJlyY.mjs';
7
7
  import '@primeui/scheduler-types/date';
8
8
  import '../display-format-CLVvRt4I.mjs';
9
9
  import '@internationalized/date';
@@ -299,7 +299,7 @@ interface TimelineResizeEndResult {
299
299
  declare function detectResizeEdgeForTimeline(relativeX: number, elementWidth: number, threshold?: number): 'start' | 'end' | null;
300
300
  declare function createTimelineDragState(event: SchedulerEvent, startX: number, startY: number, offsetX: number, offsetY: number): EventDragState;
301
301
  declare function updateTimelineDragState(state: EventDragState, currentX: number, currentY: number, minDistance?: number): EventDragState;
302
- declare function calculateTimelineDragDelta(state: EventDragState, context: Pick<TimelineDragContext, 'viewStart' | 'viewEnd' | 'totalWidth' | 'slotDuration' | 'snapDuration' | 'minTimeMinutes' | 'maxTimeMinutes'>): DragDelta;
302
+ declare function calculateTimelineDragDelta(state: EventDragState, context: Pick<TimelineDragContext, 'viewStart' | 'viewEnd' | 'totalWidth' | 'slotDuration' | 'snapDuration' | 'minTimeMinutes' | 'maxTimeMinutes' | 'calendar' | 'locale' | 'view'>): DragDelta;
303
303
  declare function processTimelineDragMove(state: EventDragState, mouseX: number, mouseY: number, context: TimelineDragContext, minDistance?: number): TimelineDragMoveResult;
304
304
  declare function finalizeTimelineDrag(state: EventDragState, delta: DragDelta, context: Pick<TimelineDragContext, 'eventOverlap' | 'parsedEvents' | 'overlapPolicy' | 'allEvents' | 'targetResourceId' | 'targetResourceIds' | 'calendar' | 'locale' | 'view'>): TimelineDragEndResult;
305
305
  interface TimelineResizeState extends Omit<EventResizeState, 'edge'> {