@super-calendar/core 2.16.0 → 2.18.0

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.
@@ -1,8 +1,12 @@
1
1
  import { Locale } from "date-fns";
2
- /** The view the calendar renders: a day-column grid (`day`, `3days`, `week`, `custom`), the `month` grid, or the `schedule` list. */
3
- type CalendarMode = "day" | "3days" | "week" | "custom" | "month" | "schedule" | "year";
4
- /** The time-grid modes (day-column views, excluding month and schedule). */
5
- type TimeGridMode = Exclude<CalendarMode, "month" | "schedule" | "year">;
2
+ /**
3
+ * The view the calendar renders: a day-column grid (`day`, `3days`, `week`,
4
+ * `custom`), the `month` grid, consecutive week rows (`multiweek`), the
5
+ * `schedule` list, or the `year` overview.
6
+ */
7
+ type CalendarMode = "day" | "3days" | "week" | "custom" | "month" | "multiweek" | "schedule" | "year";
8
+ /** The time-grid modes (day-column views, excluding the month, multi-week, schedule, and year views). */
9
+ type TimeGridMode = Exclude<CalendarMode, "month" | "multiweek" | "schedule" | "year">;
6
10
  /**
7
11
  * The minimal shape every calendar event must have. Layout (positioning,
8
12
  * overlap resolution, paging) only ever reads `start`/`end`; `title` is used by
@@ -79,6 +83,13 @@ interface RecurrenceRule {
79
83
  * the event's time of day. Omit to repeat on the start date's own weekday.
80
84
  */
81
85
  weekdays?: WeekStartsOn[];
86
+ /**
87
+ * For `weekly` rules with `weekdays`: the day a week starts on (0 = Sunday …
88
+ * 6 = Saturday). It decides which of the `weekdays` share a week, so it only
89
+ * changes the result when `interval` is greater than 1. Default 1 (Monday),
90
+ * as in RFC 5545. Maps to iCal `WKST`.
91
+ */
92
+ weekStartsOn?: WeekStartsOn;
82
93
  /**
83
94
  * For `monthly`/`yearly`: repeat on the Nth weekday of the period instead of the
84
95
  * start date's day-of-month — e.g. `{ week: 3, weekday: 1 }` is the 3rd Monday.
@@ -323,7 +334,11 @@ interface UseDateRangeOptions extends DateSelectionConstraints {
323
334
  }
324
335
  /** The seven dates of the week containing `date`, starting on `weekStartsOn`. */
325
336
  declare const getWeekDays: (date: Date, weekStartsOn: WeekStartsOn) => Date[];
326
- /** How many day columns a time-grid mode shows. `custom` uses `numberOfDays`. */
337
+ /**
338
+ * How many day columns a time-grid mode shows. `custom` uses `numberOfDays`.
339
+ * Throws a `RangeError` for `multiweek`, which has week rows instead of day
340
+ * columns; use `buildMultiWeekGrid` for it.
341
+ */
327
342
  declare const viewDayCount: (mode: CalendarMode, numberOfDays?: number) => number;
328
343
  /**
329
344
  * Days in the inclusive span from `weekStartsOn` to `weekEndsOn` (1–7),
@@ -336,6 +351,7 @@ declare const weekDaysCount: (weekStartsOn: WeekStartsOn, weekEndsOn: WeekStarts
336
351
  * (honouring `weekStartsOn`). `custom` with a `weekEndsOn` spans the partial week
337
352
  * from `weekStartsOn` to `weekEndsOn` (anchored to `date`'s week, paging by week);
338
353
  * otherwise every mode shows `viewDayCount` consecutive days starting at `date`.
354
+ * Throws a `RangeError` for `multiweek` (see `viewDayCount`).
339
355
  */
340
356
  declare const getViewDays: (mode: CalendarMode, date: Date, weekStartsOn: WeekStartsOn, numberOfDays?: number, isRTL?: boolean, weekEndsOn?: WeekStartsOn, hiddenDays?: number[]) => Date[];
341
357
  /**
@@ -356,8 +372,12 @@ declare const buildMonthWeeks: (month: Date, weekStartsOn: WeekStartsOn, { showS
356
372
  declare const filterHiddenDays: (days: Date[], hiddenDays?: number[]) => Date[];
357
373
  /** True when `date` is a Saturday or Sunday. */
358
374
  declare const isWeekend: (date: Date) => boolean;
359
- /** True when `date` falls on the current calendar day. */
360
- declare const getIsToday: (date: Date) => boolean;
375
+ /**
376
+ * True when `date` falls on the current calendar day. Pass `today` to compare
377
+ * against that day instead of the device clock, e.g. the result of
378
+ * `nowInTimeZone` for a calendar displayed in another time zone.
379
+ */
380
+ declare const getIsToday: (date: Date, today?: Date) => boolean;
361
381
  /** True when `a` and `b` are the same calendar day (ignoring the time of day). */
362
382
  declare const isSameCalendarDay: (a: Date, b: Date) => boolean;
363
383
  /** Minutes elapsed since midnight (0–1439). */
@@ -366,8 +386,10 @@ declare const minutesIntoDay: (date: Date) => number;
366
386
  declare const getYearMonths: (date: Date) => Date[];
367
387
  /**
368
388
  * True when two time ranges overlap. Edges touching (one ends exactly when the
369
- * next begins) do not count as an overlap. Compares absolute instants, so events
370
- * at the same wall-clock time on different days do not overlap.
389
+ * next begins) do not count as an overlap. A zero-length range occupies its own
390
+ * instant: it overlaps a range that contains that instant or starts at it, and
391
+ * another zero-length range at the same instant. Compares absolute instants, so
392
+ * events at the same wall-clock time on different days do not overlap.
371
393
  */
372
394
  declare function eventsOverlap(aStart: Date, aEnd: Date, bStart: Date, bEnd: Date): boolean;
373
395
  /**
@@ -435,8 +457,8 @@ declare function resolveDraggedBounds(start: Date, end: Date, deltaStartMinutes:
435
457
  } | null;
436
458
  /**
437
459
  * The all-day range swept out between two day cells of the month grid, ordered
438
- * whichever way the sweep ran: `start` is midnight of the first day and `end` is
439
- * midnight after the last, so a one-day sweep still yields a usable event. Shared
460
+ * whichever way the sweep ran: `start` is the first local day's start and `end` is
461
+ * the next day's start after the last, so a one-day sweep yields a usable event. Shared
440
462
  * by both renderers so a month drag-to-create means the same thing on each.
441
463
  */
442
464
  declare function monthCreateRange(anchor: Date, hover: Date): {
@@ -586,8 +608,8 @@ interface EventAccessibilityLabelContext {
586
608
  */
587
609
  type EventAccessibilityLabeler<T = unknown> = (event: CalendarEvent<T>, context: EventAccessibilityLabelContext) => string;
588
610
  /**
589
- * Month cells and the all-day lane show a single clipped line; timed-grid titles
590
- * (`undefined`) wrap to fill the box.
611
+ * Month and multi-week cells and the all-day lane show a single clipped line;
612
+ * timed-grid titles (`undefined`) wrap to fill the box.
591
613
  */
592
614
  declare function titleNumberOfLines(mode: CalendarMode, isAllDay: boolean): number | undefined;
593
615
  /**
@@ -595,7 +617,7 @@ declare function titleNumberOfLines(mode: CalendarMode, isAllDay: boolean): numb
595
617
  * none should show. Timed events get their `start - end` range. An all-day event
596
618
  * gets the literal "All day" in the schedule (which has no all-day lane to
597
619
  * signal it positionally) and nothing on the day/week grid (the lane already
598
- * does). Month cells and `showTime={false}` always return `null`.
620
+ * does). Month and multi-week cells and `showTime={false}` always return `null`.
599
621
  */
600
622
  declare function eventTimeLabel(args: {
601
623
  mode: CalendarMode;
@@ -954,6 +976,11 @@ interface UseMonthGridOptions extends DateSelectionConstraints {
954
976
  selectedRange?: DateRange;
955
977
  /** A date-fns locale for the weekday labels. */
956
978
  locale?: Locale;
979
+ /**
980
+ * The calendar day flagged `isToday`. Defaults to the device's current day;
981
+ * pass `nowInTimeZone(now, timeZone)` for a grid shown in another time zone.
982
+ */
983
+ today?: Date;
957
984
  }
958
985
  /**
959
986
  * Pure month-grid builder: the weeks and weekday headers for `month`, each day
@@ -961,13 +988,81 @@ interface UseMonthGridOptions extends DateSelectionConstraints {
961
988
  * data outside React; inside a component prefer {@link useMonthGrid}.
962
989
  */
963
990
  declare function buildMonthGrid(month: Date, options?: UseMonthGridOptions): MonthGrid;
991
+ /** Options for {@link buildMultiWeekGrid}. */
992
+ interface MultiWeekGridOptions extends Omit<UseMonthGridOptions, "showSixWeeks"> {
993
+ /**
994
+ * How many consecutive full weeks to show. A positive whole number; default 2.
995
+ * Other values throw a `RangeError`.
996
+ */
997
+ numberOfWeeks?: number;
998
+ }
999
+ /**
1000
+ * A day in a multi-week grid. Every day of the grid belongs to the requested
1001
+ * period, so it carries no month-membership flag.
1002
+ */
1003
+ type MultiWeekGridDay = Omit<MonthGridDay, "isCurrentMonth">;
1004
+ /** One week row of a {@link MultiWeekGrid}. */
1005
+ interface MultiWeekGridWeek {
1006
+ /** The week's first calendar day as `yyyy-MM-dd`, before hidden days are removed. */
1007
+ id: string;
1008
+ /** The row's days in display order, without hidden weekdays. */
1009
+ days: MultiWeekGridDay[];
1010
+ }
1011
+ /** A half-open local calendar interval, `[start, endExclusive)`. */
1012
+ interface MultiWeekGridInterval {
1013
+ /** Midnight of the first day. */
1014
+ start: Date;
1015
+ /** Midnight after the last day. */
1016
+ endExclusive: Date;
1017
+ }
1018
+ /** The rows, weekday headers, and date bounds of a multi-week grid. */
1019
+ interface MultiWeekGrid {
1020
+ /** Every calendar day of the requested weeks, independent of hidden weekdays and RTL. */
1021
+ period: MultiWeekGridInterval;
1022
+ /** From the earliest to the latest displayed day; hidden days inside it stay hidden. */
1023
+ visibleRange: MultiWeekGridInterval;
1024
+ /** The week rows, oldest first. */
1025
+ weeks: MultiWeekGridWeek[];
1026
+ /** The weekday header cells, in display order. */
1027
+ weekdays: MonthGridWeekday[];
1028
+ }
1029
+ /**
1030
+ * Pure multi-week builder: `numberOfWeeks` consecutive full calendar weeks,
1031
+ * starting with the week that contains `date` (aligned back to `weekStartsOn`).
1032
+ * Each day carries the same selection, disabled, today, and weekend state as
1033
+ * {@link buildMonthGrid}. Hidden weekdays shrink the rows without changing the
1034
+ * period; `isRTL` reverses each row's display order.
1035
+ *
1036
+ * The result is fully materialized, so its size grows with `numberOfWeeks`.
1037
+ *
1038
+ * @throws RangeError when `date` is invalid, `numberOfWeeks` is not a positive
1039
+ * safe integer, or the last week falls outside the range `Date` can represent.
1040
+ */
1041
+ declare function buildMultiWeekGrid(date: Date, options?: MultiWeekGridOptions): MultiWeekGrid;
1042
+ /** Options for {@link expandRecurringEvents}. */
1043
+ interface ExpandRecurringEventsOptions {
1044
+ /**
1045
+ * The IANA time zone whose wall clock the rules repeat on (e.g.
1046
+ * `"America/New_York"`). A timed event keeps its clock time in that zone across
1047
+ * the zone's DST changes, and its weekday, month-day and exception rules read
1048
+ * that zone's calendar. An exception that reads the event's own time of day
1049
+ * there (or equals one of the `rdates`) drops the occurrence at that instant;
1050
+ * any other exception at midnight, on the device or in the zone, drops its
1051
+ * whole day. Omit it to repeat on the device's clock. All-day events
1052
+ * name calendar days, so they always repeat on the device's calendar.
1053
+ */
1054
+ timeZone?: string;
1055
+ }
964
1056
  /**
965
1057
  * Materialise recurring events into concrete occurrences overlapping
966
1058
  * `[rangeStart, rangeEnd]`. Non-recurring events pass through untouched, so the
967
1059
  * result is ready to hand to `<Calendar events={...} />`. Each occurrence keeps
968
1060
  * the original event's duration and fields (minus `recurrence`).
1061
+ *
1062
+ * Pass `timeZone` to repeat timed events on that zone's wall clock instead of
1063
+ * the device's. `rangeStart` and `rangeEnd` are real instants either way.
969
1064
  */
970
- declare function expandRecurringEvents<T>(events: CalendarEvent<T>[], rangeStart: Date, rangeEnd: Date): CalendarEvent<T>[];
1065
+ declare function expandRecurringEvents<T>(events: CalendarEvent<T>[], rangeStart: Date, rangeEnd: Date, { timeZone }?: ExpandRecurringEventsOptions): CalendarEvent<T>[];
971
1066
  /**
972
1067
  * Reinterpret an instant as its wall-clock time in `timeZone`, returned as a
973
1068
  * device-local `Date` whose fields (hours, minutes, …) read back as that zone's
@@ -979,18 +1074,79 @@ declare function expandRecurringEvents<T>(events: CalendarEvent<T>[], rangeStart
979
1074
  * original UTC instant, so don't round-trip it back to a real time.
980
1075
  */
981
1076
  declare function toZonedTime(date: Date, timeZone: string): Date;
1077
+ /**
1078
+ * The current instant, or the fixed `now` when given, as the wall clock of
1079
+ * `timeZone` (see {@link toZonedTime}). Without a `timeZone` it is the instant
1080
+ * itself, read on the device clock. Compare calendar days against it to find
1081
+ * "today" for a calendar displayed in another time zone.
1082
+ */
1083
+ declare function nowInTimeZone(now?: Date, timeZone?: string): Date;
982
1084
  /**
983
1085
  * The inverse of {@link toZonedTime}: given a wall-clock time in `timeZone`,
984
1086
  * return the absolute UTC instant. Pass the wall clock as a `Date` whose **UTC**
985
1087
  * fields hold the components (e.g. `new Date(Date.UTC(y, m, d, h, min))`). Used to
986
- * resolve iCal `TZID` times; DST-correct via a two-pass offset (ambiguous
987
- * fall-back times resolve to the post-transition offset).
1088
+ * resolve iCal `TZID` times; DST-correct via a two-pass offset. A time in the
1089
+ * hour a spring-forward change skips names no instant; it resolves the same
1090
+ * distance after the skipped hour (02:30 becomes 03:30), as a device clock does.
988
1091
  */
989
1092
  declare function zonedTimeToUtc(wallClock: Date, timeZone: string): Date;
990
1093
  /**
991
- * Map every event's `start`/`end` through {@link toZonedTime} so the calendar
992
- * displays them in `timeZone`. Other fields are preserved. Memoize the result
993
- * (e.g. with `useMemo`) since it allocates new dates.
1094
+ * The inverse of {@link toZonedTime}: the real instant for a date whose
1095
+ * device-local fields hold a wall-clock time in `timeZone`, such as a date a
1096
+ * calendar displaying that zone reports. DST-correct via {@link zonedTimeToUtc}.
1097
+ */
1098
+ declare function fromZonedTime(date: Date, timeZone: string): Date;
1099
+ /**
1100
+ * Shift every timed event's `start`/`end` through {@link toZonedTime} so the
1101
+ * calendar displays them in `timeZone`. Other fields are preserved. All-day
1102
+ * events (see `isAllDayEvent`) name calendar days, not instants, so they are
1103
+ * returned as they are and stay on their days. Memoize the result (e.g. with
1104
+ * `useMemo`) since it allocates new dates.
994
1105
  */
995
1106
  declare function eventsInTimeZone<T>(events: CalendarEvent<T>[], timeZone: string): CalendarEvent<T>[];
996
- export { cellRangeFromDrag as $, loadEventSource as A, nextDateRange as At, eventAccessibilityLabel as B, BusinessHoursBand as Bt, groupEventsByDay as C, DateSelectionConstraints as Ct, wallClockHours as D, isDateSelectable as Dt, layoutDayEvents as E, daySelectionState as Et, EventAccessibilityLabelContext as F, rangeBandKind as Ft, monthEventCapacity as G, CreateGhostArgs as Gt, eventTimeLabel as H, CalendarEvent as Ht, EventAccessibilityLabeler as I, CalendarColors as It, titleNumberOfLines as J, RecurrenceFrequency as Jt, monthVisibleCount as K, EventKeyExtractor as Kt, EventChipLayout as L, darkColors as Lt, ToICalendarOptions as M, RangeBandKind as Mt, parseICalendar as N, bandRounding as Nt, EventSource as O, isRangeEndpoint as Ot, toICalendar as P, dayBadgeKind as Pt, resolveCalendarLabels as Q, WeekStartsOn as Qt, MIN_BOX_HEIGHT_FOR_TIME as R, lightColors as Rt, eventDayKeys as S, DateRange as St, isBackgroundEvent as T, UseDateRangeOptions as Tt, formatHour as U, CalendarHandle as Ut, eventChipLayout as V, BusinessHoursValue as Vt, isTimeVisibleAtHeight as W, CalendarMode as Wt, dayAccessibilityLabel as X, ScrollToTimeOptions as Xt, CalendarLabels as Y, RecurrenceRule as Yt, defaultCalendarLabels as Z, TimeGridMode as Zt, backgroundBandsForDay as _, isWeekend as _t, MonthEventSegment as a, overlapsOtherEvents as at, compareDayEvents as b, weekDaysCount as bt, MonthGridWeek as c, shiftMinutes as ct, UseMonthGridOptions as d, filterHiddenDays as dt, clampMoveStartMinutes as et, WeekdayFormat as f, getIsToday as ft, PositionedEvent as g, isSameCalendarDay as gt, weekdayFormatToken as h, getYearMonths as ht, expandRecurringEvents as i, movedClockSpan as it, ICalEvent as j, DayBadgeKind as jt, EventSourceOptions as k, isWithinDateRange as kt, MonthGridWeekday as l, snapDeltaMinutes as lt, layoutMonthWeek as m, getWeekDays as mt, toZonedTime as n, monthCreateRange as nt, MonthGrid as o, pageStepDays as ot, buildMonthGrid as p, getViewDays as pt, titleEllipsizeMode as q, ICalendarEvent as qt, zonedTimeToUtc as r, monthDropBounds as rt, MonthGridDay as s, resolveDraggedBounds as st, eventsInTimeZone as t, eventsOverlap as tt, MonthWeekEvents as u, buildMonthWeeks as ut, clockHoursBetween as v, minutesIntoDay as vt, isAllDayEvent as w, DaySelectionState as wt, drawnEnd as x, CalendarSelection as xt, closedHourBands as y, viewDayCount as yt, MonthEventCapacity as z, BusinessHours as zt };
1107
+ /**
1108
+ * The event a display copy made by {@link eventsInTimeZone} stands for, with its
1109
+ * real `start` and `end`. Any other event is returned as it is. Use it in the
1110
+ * callbacks of a view that displays zoned events, to get back the event you
1111
+ * passed in.
1112
+ */
1113
+ declare function zonedEventSource<T>(event: CalendarEvent<T>): CalendarEvent<T>;
1114
+ /** Options for {@link zonedDragBounds}. */
1115
+ interface ZonedDragBoundsOptions {
1116
+ /**
1117
+ * Keep the event's real elapsed duration when the drag moved both edges, as a
1118
+ * time-grid move does: the start is read off the zone's wall clock and the end
1119
+ * follows it, so a move across a DST change in the zone doesn't stretch or
1120
+ * shrink the event. Leave it off for a month-grid drop, which keeps the clock
1121
+ * time of both edges.
1122
+ */
1123
+ keepDuration?: boolean;
1124
+ }
1125
+ /**
1126
+ * Convert the bounds a view reports for a dragged event back to real instants.
1127
+ * `event` is the displayed event the view passed to `onDragEvent`, and `start`
1128
+ * / `end` the bounds it reported. For a display copy made by
1129
+ * {@link eventsInTimeZone}, each bound is read as a wall-clock time in that
1130
+ * zone, following the zone's own DST changes; an edge the drag left alone keeps
1131
+ * the source event's exact instant. Bounds of any other event (an all-day
1132
+ * event, or one that was never shifted) are returned unchanged.
1133
+ *
1134
+ * Returns `null` when the reported span doesn't survive the conversion: an edge
1135
+ * dropped into the hour a spring-forward change skips moves to after it, which
1136
+ * can leave the event ending at or before its start. Reject such a drop.
1137
+ */
1138
+ declare function zonedDragBounds<T>(event: CalendarEvent<T>, start: Date, end: Date, { keepDuration }?: ZonedDragBoundsOptions): {
1139
+ start: Date;
1140
+ end: Date;
1141
+ } | null;
1142
+ /**
1143
+ * Convert a wall-clock range a view reports in `timeZone` (a created event, for
1144
+ * example) to real instants. Returns `null` when the span doesn't survive the
1145
+ * conversion: a time in the hour a spring-forward change skips moves to after
1146
+ * it, which can leave the range ending at or before its start.
1147
+ */
1148
+ declare function fromZonedRange(start: Date, end: Date, timeZone: string): {
1149
+ start: Date;
1150
+ end: Date;
1151
+ } | null;
1152
+ export { eventAccessibilityLabel as $, BusinessHoursBand as $t, backgroundBandsForDay as A, isWeekend as At, wallClockHours as B, isDateSelectable as Bt, MonthWeekEvents as C, buildMonthWeeks as Ct, layoutMonthWeek as D, getWeekDays as Dt, buildMonthGrid as E, getViewDays as Et, eventDayKeys as F, DateRange as Ft, ToICalendarOptions as G, RangeBandKind as Gt, EventSourceOptions as H, isWithinDateRange as Ht, groupEventsByDay as I, DateSelectionConstraints as It, EventAccessibilityLabelContext as J, rangeBandKind as Jt, parseICalendar as K, bandRounding as Kt, isAllDayEvent as L, DaySelectionState as Lt, closedHourBands as M, viewDayCount as Mt, compareDayEvents as N, weekDaysCount as Nt, weekdayFormatToken as O, getYearMonths as Ot, drawnEnd as P, CalendarSelection as Pt, MonthEventCapacity as Q, BusinessHours as Qt, isBackgroundEvent as R, UseDateRangeOptions as Rt, MonthGridWeekday as S, snapDeltaMinutes as St, WeekdayFormat as T, getIsToday as Tt, loadEventSource as U, nextDateRange as Ut, EventSource as V, isRangeEndpoint as Vt, ICalEvent as W, DayBadgeKind as Wt, EventChipLayout as X, darkColors as Xt, EventAccessibilityLabeler as Y, CalendarColors as Yt, MIN_BOX_HEIGHT_FOR_TIME as Z, lightColors as Zt, buildMultiWeekGrid as _, movedClockSpan as _t, nowInTimeZone as a, EventKeyExtractor as an, monthVisibleCount as at, MonthGridDay as b, resolveDraggedBounds as bt, zonedEventSource as c, RecurrenceRule as cn, CalendarLabels as ct, expandRecurringEvents as d, WeekStartsOn as dn, resolveCalendarLabels as dt, BusinessHoursValue as en, eventChipLayout as et, MultiWeekGrid as f, cellRangeFromDrag as ft, MultiWeekGridWeek as g, monthDropBounds as gt, MultiWeekGridOptions as h, monthCreateRange as ht, fromZonedTime as i, CreateGhostArgs as in, monthEventCapacity as it, clockHoursBetween as j, minutesIntoDay as jt, PositionedEvent as k, isSameCalendarDay as kt, zonedTimeToUtc as l, ScrollToTimeOptions as ln, dayAccessibilityLabel as lt, MultiWeekGridInterval as m, eventsOverlap as mt, eventsInTimeZone as n, CalendarHandle as nn, formatHour as nt, toZonedTime as o, ICalendarEvent as on, titleEllipsizeMode as ot, MultiWeekGridDay as p, clampMoveStartMinutes as pt, toICalendar as q, dayBadgeKind as qt, fromZonedRange as r, CalendarMode as rn, isTimeVisibleAtHeight as rt, zonedDragBounds as s, RecurrenceFrequency as sn, titleNumberOfLines as st, ZonedDragBoundsOptions as t, CalendarEvent as tn, eventTimeLabel as tt, ExpandRecurringEventsOptions as u, TimeGridMode as un, defaultCalendarLabels as ut, MonthEventSegment as v, overlapsOtherEvents as vt, UseMonthGridOptions as w, filterHiddenDays as wt, MonthGridWeek as x, shiftMinutes as xt, MonthGrid as y, pageStepDays as yt, layoutDayEvents as z, daySelectionState as zt };
@@ -1,8 +1,12 @@
1
1
  import { Locale } from "date-fns";
2
- /** The view the calendar renders: a day-column grid (`day`, `3days`, `week`, `custom`), the `month` grid, or the `schedule` list. */
3
- type CalendarMode = "day" | "3days" | "week" | "custom" | "month" | "schedule" | "year";
4
- /** The time-grid modes (day-column views, excluding month and schedule). */
5
- type TimeGridMode = Exclude<CalendarMode, "month" | "schedule" | "year">;
2
+ /**
3
+ * The view the calendar renders: a day-column grid (`day`, `3days`, `week`,
4
+ * `custom`), the `month` grid, consecutive week rows (`multiweek`), the
5
+ * `schedule` list, or the `year` overview.
6
+ */
7
+ type CalendarMode = "day" | "3days" | "week" | "custom" | "month" | "multiweek" | "schedule" | "year";
8
+ /** The time-grid modes (day-column views, excluding the month, multi-week, schedule, and year views). */
9
+ type TimeGridMode = Exclude<CalendarMode, "month" | "multiweek" | "schedule" | "year">;
6
10
  /**
7
11
  * The minimal shape every calendar event must have. Layout (positioning,
8
12
  * overlap resolution, paging) only ever reads `start`/`end`; `title` is used by
@@ -79,6 +83,13 @@ interface RecurrenceRule {
79
83
  * the event's time of day. Omit to repeat on the start date's own weekday.
80
84
  */
81
85
  weekdays?: WeekStartsOn[];
86
+ /**
87
+ * For `weekly` rules with `weekdays`: the day a week starts on (0 = Sunday …
88
+ * 6 = Saturday). It decides which of the `weekdays` share a week, so it only
89
+ * changes the result when `interval` is greater than 1. Default 1 (Monday),
90
+ * as in RFC 5545. Maps to iCal `WKST`.
91
+ */
92
+ weekStartsOn?: WeekStartsOn;
82
93
  /**
83
94
  * For `monthly`/`yearly`: repeat on the Nth weekday of the period instead of the
84
95
  * start date's day-of-month — e.g. `{ week: 3, weekday: 1 }` is the 3rd Monday.
@@ -323,7 +334,11 @@ interface UseDateRangeOptions extends DateSelectionConstraints {
323
334
  }
324
335
  /** The seven dates of the week containing `date`, starting on `weekStartsOn`. */
325
336
  declare const getWeekDays: (date: Date, weekStartsOn: WeekStartsOn) => Date[];
326
- /** How many day columns a time-grid mode shows. `custom` uses `numberOfDays`. */
337
+ /**
338
+ * How many day columns a time-grid mode shows. `custom` uses `numberOfDays`.
339
+ * Throws a `RangeError` for `multiweek`, which has week rows instead of day
340
+ * columns; use `buildMultiWeekGrid` for it.
341
+ */
327
342
  declare const viewDayCount: (mode: CalendarMode, numberOfDays?: number) => number;
328
343
  /**
329
344
  * Days in the inclusive span from `weekStartsOn` to `weekEndsOn` (1–7),
@@ -336,6 +351,7 @@ declare const weekDaysCount: (weekStartsOn: WeekStartsOn, weekEndsOn: WeekStarts
336
351
  * (honouring `weekStartsOn`). `custom` with a `weekEndsOn` spans the partial week
337
352
  * from `weekStartsOn` to `weekEndsOn` (anchored to `date`'s week, paging by week);
338
353
  * otherwise every mode shows `viewDayCount` consecutive days starting at `date`.
354
+ * Throws a `RangeError` for `multiweek` (see `viewDayCount`).
339
355
  */
340
356
  declare const getViewDays: (mode: CalendarMode, date: Date, weekStartsOn: WeekStartsOn, numberOfDays?: number, isRTL?: boolean, weekEndsOn?: WeekStartsOn, hiddenDays?: number[]) => Date[];
341
357
  /**
@@ -356,8 +372,12 @@ declare const buildMonthWeeks: (month: Date, weekStartsOn: WeekStartsOn, { showS
356
372
  declare const filterHiddenDays: (days: Date[], hiddenDays?: number[]) => Date[];
357
373
  /** True when `date` is a Saturday or Sunday. */
358
374
  declare const isWeekend: (date: Date) => boolean;
359
- /** True when `date` falls on the current calendar day. */
360
- declare const getIsToday: (date: Date) => boolean;
375
+ /**
376
+ * True when `date` falls on the current calendar day. Pass `today` to compare
377
+ * against that day instead of the device clock, e.g. the result of
378
+ * `nowInTimeZone` for a calendar displayed in another time zone.
379
+ */
380
+ declare const getIsToday: (date: Date, today?: Date) => boolean;
361
381
  /** True when `a` and `b` are the same calendar day (ignoring the time of day). */
362
382
  declare const isSameCalendarDay: (a: Date, b: Date) => boolean;
363
383
  /** Minutes elapsed since midnight (0–1439). */
@@ -366,8 +386,10 @@ declare const minutesIntoDay: (date: Date) => number;
366
386
  declare const getYearMonths: (date: Date) => Date[];
367
387
  /**
368
388
  * True when two time ranges overlap. Edges touching (one ends exactly when the
369
- * next begins) do not count as an overlap. Compares absolute instants, so events
370
- * at the same wall-clock time on different days do not overlap.
389
+ * next begins) do not count as an overlap. A zero-length range occupies its own
390
+ * instant: it overlaps a range that contains that instant or starts at it, and
391
+ * another zero-length range at the same instant. Compares absolute instants, so
392
+ * events at the same wall-clock time on different days do not overlap.
371
393
  */
372
394
  declare function eventsOverlap(aStart: Date, aEnd: Date, bStart: Date, bEnd: Date): boolean;
373
395
  /**
@@ -435,8 +457,8 @@ declare function resolveDraggedBounds(start: Date, end: Date, deltaStartMinutes:
435
457
  } | null;
436
458
  /**
437
459
  * The all-day range swept out between two day cells of the month grid, ordered
438
- * whichever way the sweep ran: `start` is midnight of the first day and `end` is
439
- * midnight after the last, so a one-day sweep still yields a usable event. Shared
460
+ * whichever way the sweep ran: `start` is the first local day's start and `end` is
461
+ * the next day's start after the last, so a one-day sweep yields a usable event. Shared
440
462
  * by both renderers so a month drag-to-create means the same thing on each.
441
463
  */
442
464
  declare function monthCreateRange(anchor: Date, hover: Date): {
@@ -586,8 +608,8 @@ interface EventAccessibilityLabelContext {
586
608
  */
587
609
  type EventAccessibilityLabeler<T = unknown> = (event: CalendarEvent<T>, context: EventAccessibilityLabelContext) => string;
588
610
  /**
589
- * Month cells and the all-day lane show a single clipped line; timed-grid titles
590
- * (`undefined`) wrap to fill the box.
611
+ * Month and multi-week cells and the all-day lane show a single clipped line;
612
+ * timed-grid titles (`undefined`) wrap to fill the box.
591
613
  */
592
614
  declare function titleNumberOfLines(mode: CalendarMode, isAllDay: boolean): number | undefined;
593
615
  /**
@@ -595,7 +617,7 @@ declare function titleNumberOfLines(mode: CalendarMode, isAllDay: boolean): numb
595
617
  * none should show. Timed events get their `start - end` range. An all-day event
596
618
  * gets the literal "All day" in the schedule (which has no all-day lane to
597
619
  * signal it positionally) and nothing on the day/week grid (the lane already
598
- * does). Month cells and `showTime={false}` always return `null`.
620
+ * does). Month and multi-week cells and `showTime={false}` always return `null`.
599
621
  */
600
622
  declare function eventTimeLabel(args: {
601
623
  mode: CalendarMode;
@@ -954,6 +976,11 @@ interface UseMonthGridOptions extends DateSelectionConstraints {
954
976
  selectedRange?: DateRange;
955
977
  /** A date-fns locale for the weekday labels. */
956
978
  locale?: Locale;
979
+ /**
980
+ * The calendar day flagged `isToday`. Defaults to the device's current day;
981
+ * pass `nowInTimeZone(now, timeZone)` for a grid shown in another time zone.
982
+ */
983
+ today?: Date;
957
984
  }
958
985
  /**
959
986
  * Pure month-grid builder: the weeks and weekday headers for `month`, each day
@@ -961,13 +988,81 @@ interface UseMonthGridOptions extends DateSelectionConstraints {
961
988
  * data outside React; inside a component prefer {@link useMonthGrid}.
962
989
  */
963
990
  declare function buildMonthGrid(month: Date, options?: UseMonthGridOptions): MonthGrid;
991
+ /** Options for {@link buildMultiWeekGrid}. */
992
+ interface MultiWeekGridOptions extends Omit<UseMonthGridOptions, "showSixWeeks"> {
993
+ /**
994
+ * How many consecutive full weeks to show. A positive whole number; default 2.
995
+ * Other values throw a `RangeError`.
996
+ */
997
+ numberOfWeeks?: number;
998
+ }
999
+ /**
1000
+ * A day in a multi-week grid. Every day of the grid belongs to the requested
1001
+ * period, so it carries no month-membership flag.
1002
+ */
1003
+ type MultiWeekGridDay = Omit<MonthGridDay, "isCurrentMonth">;
1004
+ /** One week row of a {@link MultiWeekGrid}. */
1005
+ interface MultiWeekGridWeek {
1006
+ /** The week's first calendar day as `yyyy-MM-dd`, before hidden days are removed. */
1007
+ id: string;
1008
+ /** The row's days in display order, without hidden weekdays. */
1009
+ days: MultiWeekGridDay[];
1010
+ }
1011
+ /** A half-open local calendar interval, `[start, endExclusive)`. */
1012
+ interface MultiWeekGridInterval {
1013
+ /** Midnight of the first day. */
1014
+ start: Date;
1015
+ /** Midnight after the last day. */
1016
+ endExclusive: Date;
1017
+ }
1018
+ /** The rows, weekday headers, and date bounds of a multi-week grid. */
1019
+ interface MultiWeekGrid {
1020
+ /** Every calendar day of the requested weeks, independent of hidden weekdays and RTL. */
1021
+ period: MultiWeekGridInterval;
1022
+ /** From the earliest to the latest displayed day; hidden days inside it stay hidden. */
1023
+ visibleRange: MultiWeekGridInterval;
1024
+ /** The week rows, oldest first. */
1025
+ weeks: MultiWeekGridWeek[];
1026
+ /** The weekday header cells, in display order. */
1027
+ weekdays: MonthGridWeekday[];
1028
+ }
1029
+ /**
1030
+ * Pure multi-week builder: `numberOfWeeks` consecutive full calendar weeks,
1031
+ * starting with the week that contains `date` (aligned back to `weekStartsOn`).
1032
+ * Each day carries the same selection, disabled, today, and weekend state as
1033
+ * {@link buildMonthGrid}. Hidden weekdays shrink the rows without changing the
1034
+ * period; `isRTL` reverses each row's display order.
1035
+ *
1036
+ * The result is fully materialized, so its size grows with `numberOfWeeks`.
1037
+ *
1038
+ * @throws RangeError when `date` is invalid, `numberOfWeeks` is not a positive
1039
+ * safe integer, or the last week falls outside the range `Date` can represent.
1040
+ */
1041
+ declare function buildMultiWeekGrid(date: Date, options?: MultiWeekGridOptions): MultiWeekGrid;
1042
+ /** Options for {@link expandRecurringEvents}. */
1043
+ interface ExpandRecurringEventsOptions {
1044
+ /**
1045
+ * The IANA time zone whose wall clock the rules repeat on (e.g.
1046
+ * `"America/New_York"`). A timed event keeps its clock time in that zone across
1047
+ * the zone's DST changes, and its weekday, month-day and exception rules read
1048
+ * that zone's calendar. An exception that reads the event's own time of day
1049
+ * there (or equals one of the `rdates`) drops the occurrence at that instant;
1050
+ * any other exception at midnight, on the device or in the zone, drops its
1051
+ * whole day. Omit it to repeat on the device's clock. All-day events
1052
+ * name calendar days, so they always repeat on the device's calendar.
1053
+ */
1054
+ timeZone?: string;
1055
+ }
964
1056
  /**
965
1057
  * Materialise recurring events into concrete occurrences overlapping
966
1058
  * `[rangeStart, rangeEnd]`. Non-recurring events pass through untouched, so the
967
1059
  * result is ready to hand to `<Calendar events={...} />`. Each occurrence keeps
968
1060
  * the original event's duration and fields (minus `recurrence`).
1061
+ *
1062
+ * Pass `timeZone` to repeat timed events on that zone's wall clock instead of
1063
+ * the device's. `rangeStart` and `rangeEnd` are real instants either way.
969
1064
  */
970
- declare function expandRecurringEvents<T>(events: CalendarEvent<T>[], rangeStart: Date, rangeEnd: Date): CalendarEvent<T>[];
1065
+ declare function expandRecurringEvents<T>(events: CalendarEvent<T>[], rangeStart: Date, rangeEnd: Date, { timeZone }?: ExpandRecurringEventsOptions): CalendarEvent<T>[];
971
1066
  /**
972
1067
  * Reinterpret an instant as its wall-clock time in `timeZone`, returned as a
973
1068
  * device-local `Date` whose fields (hours, minutes, …) read back as that zone's
@@ -979,18 +1074,79 @@ declare function expandRecurringEvents<T>(events: CalendarEvent<T>[], rangeStart
979
1074
  * original UTC instant, so don't round-trip it back to a real time.
980
1075
  */
981
1076
  declare function toZonedTime(date: Date, timeZone: string): Date;
1077
+ /**
1078
+ * The current instant, or the fixed `now` when given, as the wall clock of
1079
+ * `timeZone` (see {@link toZonedTime}). Without a `timeZone` it is the instant
1080
+ * itself, read on the device clock. Compare calendar days against it to find
1081
+ * "today" for a calendar displayed in another time zone.
1082
+ */
1083
+ declare function nowInTimeZone(now?: Date, timeZone?: string): Date;
982
1084
  /**
983
1085
  * The inverse of {@link toZonedTime}: given a wall-clock time in `timeZone`,
984
1086
  * return the absolute UTC instant. Pass the wall clock as a `Date` whose **UTC**
985
1087
  * fields hold the components (e.g. `new Date(Date.UTC(y, m, d, h, min))`). Used to
986
- * resolve iCal `TZID` times; DST-correct via a two-pass offset (ambiguous
987
- * fall-back times resolve to the post-transition offset).
1088
+ * resolve iCal `TZID` times; DST-correct via a two-pass offset. A time in the
1089
+ * hour a spring-forward change skips names no instant; it resolves the same
1090
+ * distance after the skipped hour (02:30 becomes 03:30), as a device clock does.
988
1091
  */
989
1092
  declare function zonedTimeToUtc(wallClock: Date, timeZone: string): Date;
990
1093
  /**
991
- * Map every event's `start`/`end` through {@link toZonedTime} so the calendar
992
- * displays them in `timeZone`. Other fields are preserved. Memoize the result
993
- * (e.g. with `useMemo`) since it allocates new dates.
1094
+ * The inverse of {@link toZonedTime}: the real instant for a date whose
1095
+ * device-local fields hold a wall-clock time in `timeZone`, such as a date a
1096
+ * calendar displaying that zone reports. DST-correct via {@link zonedTimeToUtc}.
1097
+ */
1098
+ declare function fromZonedTime(date: Date, timeZone: string): Date;
1099
+ /**
1100
+ * Shift every timed event's `start`/`end` through {@link toZonedTime} so the
1101
+ * calendar displays them in `timeZone`. Other fields are preserved. All-day
1102
+ * events (see `isAllDayEvent`) name calendar days, not instants, so they are
1103
+ * returned as they are and stay on their days. Memoize the result (e.g. with
1104
+ * `useMemo`) since it allocates new dates.
994
1105
  */
995
1106
  declare function eventsInTimeZone<T>(events: CalendarEvent<T>[], timeZone: string): CalendarEvent<T>[];
996
- export { cellRangeFromDrag as $, loadEventSource as A, nextDateRange as At, eventAccessibilityLabel as B, BusinessHoursBand as Bt, groupEventsByDay as C, DateSelectionConstraints as Ct, wallClockHours as D, isDateSelectable as Dt, layoutDayEvents as E, daySelectionState as Et, EventAccessibilityLabelContext as F, rangeBandKind as Ft, monthEventCapacity as G, CreateGhostArgs as Gt, eventTimeLabel as H, CalendarEvent as Ht, EventAccessibilityLabeler as I, CalendarColors as It, titleNumberOfLines as J, RecurrenceFrequency as Jt, monthVisibleCount as K, EventKeyExtractor as Kt, EventChipLayout as L, darkColors as Lt, ToICalendarOptions as M, RangeBandKind as Mt, parseICalendar as N, bandRounding as Nt, EventSource as O, isRangeEndpoint as Ot, toICalendar as P, dayBadgeKind as Pt, resolveCalendarLabels as Q, WeekStartsOn as Qt, MIN_BOX_HEIGHT_FOR_TIME as R, lightColors as Rt, eventDayKeys as S, DateRange as St, isBackgroundEvent as T, UseDateRangeOptions as Tt, formatHour as U, CalendarHandle as Ut, eventChipLayout as V, BusinessHoursValue as Vt, isTimeVisibleAtHeight as W, CalendarMode as Wt, dayAccessibilityLabel as X, ScrollToTimeOptions as Xt, CalendarLabels as Y, RecurrenceRule as Yt, defaultCalendarLabels as Z, TimeGridMode as Zt, backgroundBandsForDay as _, isWeekend as _t, MonthEventSegment as a, overlapsOtherEvents as at, compareDayEvents as b, weekDaysCount as bt, MonthGridWeek as c, shiftMinutes as ct, UseMonthGridOptions as d, filterHiddenDays as dt, clampMoveStartMinutes as et, WeekdayFormat as f, getIsToday as ft, PositionedEvent as g, isSameCalendarDay as gt, weekdayFormatToken as h, getYearMonths as ht, expandRecurringEvents as i, movedClockSpan as it, ICalEvent as j, DayBadgeKind as jt, EventSourceOptions as k, isWithinDateRange as kt, MonthGridWeekday as l, snapDeltaMinutes as lt, layoutMonthWeek as m, getWeekDays as mt, toZonedTime as n, monthCreateRange as nt, MonthGrid as o, pageStepDays as ot, buildMonthGrid as p, getViewDays as pt, titleEllipsizeMode as q, ICalendarEvent as qt, zonedTimeToUtc as r, monthDropBounds as rt, MonthGridDay as s, resolveDraggedBounds as st, eventsInTimeZone as t, eventsOverlap as tt, MonthWeekEvents as u, buildMonthWeeks as ut, clockHoursBetween as v, minutesIntoDay as vt, isAllDayEvent as w, DaySelectionState as wt, drawnEnd as x, CalendarSelection as xt, closedHourBands as y, viewDayCount as yt, MonthEventCapacity as z, BusinessHours as zt };
1107
+ /**
1108
+ * The event a display copy made by {@link eventsInTimeZone} stands for, with its
1109
+ * real `start` and `end`. Any other event is returned as it is. Use it in the
1110
+ * callbacks of a view that displays zoned events, to get back the event you
1111
+ * passed in.
1112
+ */
1113
+ declare function zonedEventSource<T>(event: CalendarEvent<T>): CalendarEvent<T>;
1114
+ /** Options for {@link zonedDragBounds}. */
1115
+ interface ZonedDragBoundsOptions {
1116
+ /**
1117
+ * Keep the event's real elapsed duration when the drag moved both edges, as a
1118
+ * time-grid move does: the start is read off the zone's wall clock and the end
1119
+ * follows it, so a move across a DST change in the zone doesn't stretch or
1120
+ * shrink the event. Leave it off for a month-grid drop, which keeps the clock
1121
+ * time of both edges.
1122
+ */
1123
+ keepDuration?: boolean;
1124
+ }
1125
+ /**
1126
+ * Convert the bounds a view reports for a dragged event back to real instants.
1127
+ * `event` is the displayed event the view passed to `onDragEvent`, and `start`
1128
+ * / `end` the bounds it reported. For a display copy made by
1129
+ * {@link eventsInTimeZone}, each bound is read as a wall-clock time in that
1130
+ * zone, following the zone's own DST changes; an edge the drag left alone keeps
1131
+ * the source event's exact instant. Bounds of any other event (an all-day
1132
+ * event, or one that was never shifted) are returned unchanged.
1133
+ *
1134
+ * Returns `null` when the reported span doesn't survive the conversion: an edge
1135
+ * dropped into the hour a spring-forward change skips moves to after it, which
1136
+ * can leave the event ending at or before its start. Reject such a drop.
1137
+ */
1138
+ declare function zonedDragBounds<T>(event: CalendarEvent<T>, start: Date, end: Date, { keepDuration }?: ZonedDragBoundsOptions): {
1139
+ start: Date;
1140
+ end: Date;
1141
+ } | null;
1142
+ /**
1143
+ * Convert a wall-clock range a view reports in `timeZone` (a created event, for
1144
+ * example) to real instants. Returns `null` when the span doesn't survive the
1145
+ * conversion: a time in the hour a spring-forward change skips moves to after
1146
+ * it, which can leave the range ending at or before its start.
1147
+ */
1148
+ declare function fromZonedRange(start: Date, end: Date, timeZone: string): {
1149
+ start: Date;
1150
+ end: Date;
1151
+ } | null;
1152
+ export { eventAccessibilityLabel as $, BusinessHoursBand as $t, backgroundBandsForDay as A, isWeekend as At, wallClockHours as B, isDateSelectable as Bt, MonthWeekEvents as C, buildMonthWeeks as Ct, layoutMonthWeek as D, getWeekDays as Dt, buildMonthGrid as E, getViewDays as Et, eventDayKeys as F, DateRange as Ft, ToICalendarOptions as G, RangeBandKind as Gt, EventSourceOptions as H, isWithinDateRange as Ht, groupEventsByDay as I, DateSelectionConstraints as It, EventAccessibilityLabelContext as J, rangeBandKind as Jt, parseICalendar as K, bandRounding as Kt, isAllDayEvent as L, DaySelectionState as Lt, closedHourBands as M, viewDayCount as Mt, compareDayEvents as N, weekDaysCount as Nt, weekdayFormatToken as O, getYearMonths as Ot, drawnEnd as P, CalendarSelection as Pt, MonthEventCapacity as Q, BusinessHours as Qt, isBackgroundEvent as R, UseDateRangeOptions as Rt, MonthGridWeekday as S, snapDeltaMinutes as St, WeekdayFormat as T, getIsToday as Tt, loadEventSource as U, nextDateRange as Ut, EventSource as V, isRangeEndpoint as Vt, ICalEvent as W, DayBadgeKind as Wt, EventChipLayout as X, darkColors as Xt, EventAccessibilityLabeler as Y, CalendarColors as Yt, MIN_BOX_HEIGHT_FOR_TIME as Z, lightColors as Zt, buildMultiWeekGrid as _, movedClockSpan as _t, nowInTimeZone as a, EventKeyExtractor as an, monthVisibleCount as at, MonthGridDay as b, resolveDraggedBounds as bt, zonedEventSource as c, RecurrenceRule as cn, CalendarLabels as ct, expandRecurringEvents as d, WeekStartsOn as dn, resolveCalendarLabels as dt, BusinessHoursValue as en, eventChipLayout as et, MultiWeekGrid as f, cellRangeFromDrag as ft, MultiWeekGridWeek as g, monthDropBounds as gt, MultiWeekGridOptions as h, monthCreateRange as ht, fromZonedTime as i, CreateGhostArgs as in, monthEventCapacity as it, clockHoursBetween as j, minutesIntoDay as jt, PositionedEvent as k, isSameCalendarDay as kt, zonedTimeToUtc as l, ScrollToTimeOptions as ln, dayAccessibilityLabel as lt, MultiWeekGridInterval as m, eventsOverlap as mt, eventsInTimeZone as n, CalendarHandle as nn, formatHour as nt, toZonedTime as o, ICalendarEvent as on, titleEllipsizeMode as ot, MultiWeekGridDay as p, clampMoveStartMinutes as pt, toICalendar as q, dayBadgeKind as qt, fromZonedRange as r, CalendarMode as rn, isTimeVisibleAtHeight as rt, zonedDragBounds as s, RecurrenceFrequency as sn, titleNumberOfLines as st, ZonedDragBoundsOptions as t, CalendarEvent as tn, eventTimeLabel as tt, ExpandRecurringEventsOptions as u, TimeGridMode as un, defaultCalendarLabels as ut, MonthEventSegment as v, overlapsOtherEvents as vt, UseMonthGridOptions as w, filterHiddenDays as wt, MonthGridWeek as x, shiftMinutes as xt, MonthGrid as y, pageStepDays as yt, layoutDayEvents as z, daySelectionState as zt };
@@ -1,2 +1,2 @@
1
- import { $ as cellRangeFromDrag, A as loadEventSource, At as nextDateRange, B as eventAccessibilityLabel, Bt as BusinessHoursBand, C as groupEventsByDay, Ct as DateSelectionConstraints, D as wallClockHours, Dt as isDateSelectable, E as layoutDayEvents, Et as daySelectionState, F as EventAccessibilityLabelContext, Ft as rangeBandKind, G as monthEventCapacity, Gt as CreateGhostArgs, H as eventTimeLabel, Ht as CalendarEvent, I as EventAccessibilityLabeler, It as CalendarColors, J as titleNumberOfLines, Jt as RecurrenceFrequency, K as monthVisibleCount, Kt as EventKeyExtractor, L as EventChipLayout, Lt as darkColors, M as ToICalendarOptions, Mt as RangeBandKind, N as parseICalendar, Nt as bandRounding, O as EventSource, Ot as isRangeEndpoint, P as toICalendar, Pt as dayBadgeKind, Q as resolveCalendarLabels, Qt as WeekStartsOn, R as MIN_BOX_HEIGHT_FOR_TIME, Rt as lightColors, S as eventDayKeys, St as DateRange, T as isBackgroundEvent, Tt as UseDateRangeOptions, U as formatHour, Ut as CalendarHandle, V as eventChipLayout, Vt as BusinessHoursValue, W as isTimeVisibleAtHeight, Wt as CalendarMode, X as dayAccessibilityLabel, Xt as ScrollToTimeOptions, Y as CalendarLabels, Yt as RecurrenceRule, Z as defaultCalendarLabels, Zt as TimeGridMode, _ as backgroundBandsForDay, _t as isWeekend, a as MonthEventSegment, at as overlapsOtherEvents, b as compareDayEvents, bt as weekDaysCount, c as MonthGridWeek, ct as shiftMinutes, d as UseMonthGridOptions, dt as filterHiddenDays, et as clampMoveStartMinutes, f as WeekdayFormat, ft as getIsToday, g as PositionedEvent, gt as isSameCalendarDay, h as weekdayFormatToken, ht as getYearMonths, i as expandRecurringEvents, it as movedClockSpan, j as ICalEvent, jt as DayBadgeKind, k as EventSourceOptions, kt as isWithinDateRange, l as MonthGridWeekday, lt as snapDeltaMinutes, m as layoutMonthWeek, mt as getWeekDays, n as toZonedTime, nt as monthCreateRange, o as MonthGrid, ot as pageStepDays, p as buildMonthGrid, pt as getViewDays, q as titleEllipsizeMode, qt as ICalendarEvent, r as zonedTimeToUtc, rt as monthDropBounds, s as MonthGridDay, st as resolveDraggedBounds, t as eventsInTimeZone, tt as eventsOverlap, u as MonthWeekEvents, ut as buildMonthWeeks, v as clockHoursBetween, vt as minutesIntoDay, w as isAllDayEvent, wt as DaySelectionState, x as drawnEnd, xt as CalendarSelection, y as closedHourBands, yt as viewDayCount, z as MonthEventCapacity, zt as BusinessHours } from "./timezone-d6EaWlvP.mjs";
2
- export { BusinessHours, BusinessHoursBand, BusinessHoursValue, CalendarColors, CalendarEvent, CalendarHandle, CalendarLabels, CalendarMode, CalendarSelection, CreateGhostArgs, DateRange, DateSelectionConstraints, DayBadgeKind, DaySelectionState, EventAccessibilityLabelContext, EventAccessibilityLabeler, EventChipLayout, EventKeyExtractor, EventSource, EventSourceOptions, ICalEvent, ICalendarEvent, MIN_BOX_HEIGHT_FOR_TIME, MonthEventCapacity, MonthEventSegment, MonthGrid, MonthGridDay, MonthGridWeek, MonthGridWeekday, MonthWeekEvents, PositionedEvent, RangeBandKind, RecurrenceFrequency, RecurrenceRule, ScrollToTimeOptions, TimeGridMode, ToICalendarOptions, UseDateRangeOptions, UseMonthGridOptions, WeekStartsOn, WeekdayFormat, backgroundBandsForDay, bandRounding, buildMonthGrid, buildMonthWeeks, cellRangeFromDrag, clampMoveStartMinutes, clockHoursBetween, closedHourBands, compareDayEvents, darkColors, dayAccessibilityLabel, dayBadgeKind, daySelectionState, defaultCalendarLabels, drawnEnd, eventAccessibilityLabel, eventChipLayout, eventDayKeys, eventTimeLabel, eventsInTimeZone, eventsOverlap, expandRecurringEvents, filterHiddenDays, formatHour, getIsToday, getViewDays, getWeekDays, getYearMonths, groupEventsByDay, isAllDayEvent, isBackgroundEvent, isDateSelectable, isRangeEndpoint, isSameCalendarDay, isTimeVisibleAtHeight, isWeekend, isWithinDateRange, layoutDayEvents, layoutMonthWeek, lightColors, loadEventSource, minutesIntoDay, monthCreateRange, monthDropBounds, monthEventCapacity, monthVisibleCount, movedClockSpan, nextDateRange, overlapsOtherEvents, pageStepDays, parseICalendar, rangeBandKind, resolveCalendarLabels, resolveDraggedBounds, shiftMinutes, snapDeltaMinutes, titleEllipsizeMode, titleNumberOfLines, toICalendar, toZonedTime, viewDayCount, wallClockHours, weekDaysCount, weekdayFormatToken, zonedTimeToUtc };
1
+ import { $ as eventAccessibilityLabel, $t as BusinessHoursBand, A as backgroundBandsForDay, At as isWeekend, B as wallClockHours, Bt as isDateSelectable, C as MonthWeekEvents, Ct as buildMonthWeeks, D as layoutMonthWeek, Dt as getWeekDays, E as buildMonthGrid, Et as getViewDays, F as eventDayKeys, Ft as DateRange, G as ToICalendarOptions, Gt as RangeBandKind, H as EventSourceOptions, Ht as isWithinDateRange, I as groupEventsByDay, It as DateSelectionConstraints, J as EventAccessibilityLabelContext, Jt as rangeBandKind, K as parseICalendar, Kt as bandRounding, L as isAllDayEvent, Lt as DaySelectionState, M as closedHourBands, Mt as viewDayCount, N as compareDayEvents, Nt as weekDaysCount, O as weekdayFormatToken, Ot as getYearMonths, P as drawnEnd, Pt as CalendarSelection, Q as MonthEventCapacity, Qt as BusinessHours, R as isBackgroundEvent, Rt as UseDateRangeOptions, S as MonthGridWeekday, St as snapDeltaMinutes, T as WeekdayFormat, Tt as getIsToday, U as loadEventSource, Ut as nextDateRange, V as EventSource, Vt as isRangeEndpoint, W as ICalEvent, Wt as DayBadgeKind, X as EventChipLayout, Xt as darkColors, Y as EventAccessibilityLabeler, Yt as CalendarColors, Z as MIN_BOX_HEIGHT_FOR_TIME, Zt as lightColors, _ as buildMultiWeekGrid, _t as movedClockSpan, a as nowInTimeZone, an as EventKeyExtractor, at as monthVisibleCount, b as MonthGridDay, bt as resolveDraggedBounds, c as zonedEventSource, cn as RecurrenceRule, ct as CalendarLabels, d as expandRecurringEvents, dn as WeekStartsOn, dt as resolveCalendarLabels, en as BusinessHoursValue, et as eventChipLayout, f as MultiWeekGrid, ft as cellRangeFromDrag, g as MultiWeekGridWeek, gt as monthDropBounds, h as MultiWeekGridOptions, ht as monthCreateRange, i as fromZonedTime, in as CreateGhostArgs, it as monthEventCapacity, j as clockHoursBetween, jt as minutesIntoDay, k as PositionedEvent, kt as isSameCalendarDay, l as zonedTimeToUtc, ln as ScrollToTimeOptions, lt as dayAccessibilityLabel, m as MultiWeekGridInterval, mt as eventsOverlap, n as eventsInTimeZone, nn as CalendarHandle, nt as formatHour, o as toZonedTime, on as ICalendarEvent, ot as titleEllipsizeMode, p as MultiWeekGridDay, pt as clampMoveStartMinutes, q as toICalendar, qt as dayBadgeKind, r as fromZonedRange, rn as CalendarMode, rt as isTimeVisibleAtHeight, s as zonedDragBounds, sn as RecurrenceFrequency, st as titleNumberOfLines, t as ZonedDragBoundsOptions, tn as CalendarEvent, tt as eventTimeLabel, u as ExpandRecurringEventsOptions, un as TimeGridMode, ut as defaultCalendarLabels, v as MonthEventSegment, vt as overlapsOtherEvents, w as UseMonthGridOptions, wt as filterHiddenDays, x as MonthGridWeek, xt as shiftMinutes, y as MonthGrid, yt as pageStepDays, z as layoutDayEvents, zt as daySelectionState } from "./timezone-BY2vQwRx.mjs";
2
+ export { BusinessHours, BusinessHoursBand, BusinessHoursValue, CalendarColors, CalendarEvent, CalendarHandle, CalendarLabels, CalendarMode, CalendarSelection, CreateGhostArgs, DateRange, DateSelectionConstraints, DayBadgeKind, DaySelectionState, EventAccessibilityLabelContext, EventAccessibilityLabeler, EventChipLayout, EventKeyExtractor, EventSource, EventSourceOptions, ExpandRecurringEventsOptions, ICalEvent, ICalendarEvent, MIN_BOX_HEIGHT_FOR_TIME, MonthEventCapacity, MonthEventSegment, MonthGrid, MonthGridDay, MonthGridWeek, MonthGridWeekday, MonthWeekEvents, MultiWeekGrid, MultiWeekGridDay, MultiWeekGridInterval, MultiWeekGridOptions, MultiWeekGridWeek, PositionedEvent, RangeBandKind, RecurrenceFrequency, RecurrenceRule, ScrollToTimeOptions, TimeGridMode, ToICalendarOptions, UseDateRangeOptions, UseMonthGridOptions, WeekStartsOn, WeekdayFormat, ZonedDragBoundsOptions, backgroundBandsForDay, bandRounding, buildMonthGrid, buildMonthWeeks, buildMultiWeekGrid, cellRangeFromDrag, clampMoveStartMinutes, clockHoursBetween, closedHourBands, compareDayEvents, darkColors, dayAccessibilityLabel, dayBadgeKind, daySelectionState, defaultCalendarLabels, drawnEnd, eventAccessibilityLabel, eventChipLayout, eventDayKeys, eventTimeLabel, eventsInTimeZone, eventsOverlap, expandRecurringEvents, filterHiddenDays, formatHour, fromZonedRange, fromZonedTime, getIsToday, getViewDays, getWeekDays, getYearMonths, groupEventsByDay, isAllDayEvent, isBackgroundEvent, isDateSelectable, isRangeEndpoint, isSameCalendarDay, isTimeVisibleAtHeight, isWeekend, isWithinDateRange, layoutDayEvents, layoutMonthWeek, lightColors, loadEventSource, minutesIntoDay, monthCreateRange, monthDropBounds, monthEventCapacity, monthVisibleCount, movedClockSpan, nextDateRange, nowInTimeZone, overlapsOtherEvents, pageStepDays, parseICalendar, rangeBandKind, resolveCalendarLabels, resolveDraggedBounds, shiftMinutes, snapDeltaMinutes, titleEllipsizeMode, titleNumberOfLines, toICalendar, toZonedTime, viewDayCount, wallClockHours, weekDaysCount, weekdayFormatToken, zonedDragBounds, zonedEventSource, zonedTimeToUtc };