@mantine-vue/schedule 2.1.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.
- package/README.md +21 -0
- package/cjs/index.cjs +4198 -0
- package/cjs/index.cjs.map +1 -0
- package/esm/index.mjs +4106 -0
- package/esm/index.mjs.map +1 -0
- package/lib/component-props.d.ts +265 -0
- package/lib/components/CurrentTimeIndicator/CurrentTimeIndicator.d.ts +114 -0
- package/lib/components/CurrentTimeIndicator/index.d.ts +1 -0
- package/lib/components/DayView/DayView.d.ts +212 -0
- package/lib/components/DayView/get-day-view-events/get-day-positioned-events.d.ts +15 -0
- package/lib/components/DayView/get-day-view-events/get-day-view-events.d.ts +15 -0
- package/lib/components/DayView/index.d.ts +3 -0
- package/lib/components/DragContext/DragContext.d.ts +11 -0
- package/lib/components/DragContext/index.d.ts +1 -0
- package/lib/components/MobileMonthView/MobileMonthView.d.ts +171 -0
- package/lib/components/MobileMonthView/get-mobile-month-view-events.d.ts +8 -0
- package/lib/components/MobileMonthView/index.d.ts +1 -0
- package/lib/components/MonthView/MonthView.d.ts +174 -0
- package/lib/components/MonthView/get-month-view-events/add-event-to-day-groups.d.ts +14 -0
- package/lib/components/MonthView/get-month-view-events/calculate-event-position-in-week.d.ts +18 -0
- package/lib/components/MonthView/get-month-view-events/find-available-row.d.ts +10 -0
- package/lib/components/MonthView/get-month-view-events/get-month-positioned-events.d.ts +31 -0
- package/lib/components/MonthView/get-month-view-events/get-month-view-events.d.ts +16 -0
- package/lib/components/MonthView/get-month-view-events/get-weeks-in-range.d.ts +13 -0
- package/lib/components/MonthView/get-renderable-month-event-segments.d.ts +16 -0
- package/lib/components/MonthView/index.d.ts +4 -0
- package/lib/components/MoreEvents/MoreEvents.d.ts +65 -0
- package/lib/components/MoreEvents/index.d.ts +1 -0
- package/lib/components/Schedule/Schedule.d.ts +134 -0
- package/lib/components/Schedule/index.d.ts +1 -0
- package/lib/components/ScheduleEvent/ScheduleEvent.d.ts +88 -0
- package/lib/components/ScheduleEvent/index.d.ts +1 -0
- package/lib/components/ScheduleHeader/HeaderControl/index.d.ts +2 -0
- package/lib/components/ScheduleHeader/MonthYearSelect/index.d.ts +2 -0
- package/lib/components/ScheduleHeader/ScheduleHeader.d.ts +364 -0
- package/lib/components/ScheduleHeader/ScheduleHeaderBase.d.ts +72 -0
- package/lib/components/ScheduleHeader/ViewSelect/index.d.ts +2 -0
- package/lib/components/ScheduleHeader/index.d.ts +2 -0
- package/lib/components/WeekView/WeekView.d.ts +294 -0
- package/lib/components/WeekView/get-week-label/get-week-label.d.ts +13 -0
- package/lib/components/WeekView/get-week-view-events/assign-event-rows.d.ts +2 -0
- package/lib/components/WeekView/get-week-view-events/calculate-all-day-event-offset.d.ts +11 -0
- package/lib/components/WeekView/get-week-view-events/calculate-all-day-event-width.d.ts +12 -0
- package/lib/components/WeekView/get-week-view-events/calculate-event-days.d.ts +9 -0
- package/lib/components/WeekView/get-week-view-events/calculate-regular-event-overlaps.d.ts +2 -0
- package/lib/components/WeekView/get-week-view-events/filter-week-view-events.d.ts +14 -0
- package/lib/components/WeekView/get-week-view-events/find-available-column.d.ts +9 -0
- package/lib/components/WeekView/get-week-view-events/get-event-end-date.d.ts +3 -0
- package/lib/components/WeekView/get-week-view-events/get-hanging-status.d.ts +9 -0
- package/lib/components/WeekView/get-week-view-events/get-week-positioned-events.d.ts +26 -0
- package/lib/components/WeekView/get-week-view-events/get-week-view-events.d.ts +7 -0
- package/lib/components/WeekView/index.d.ts +4 -0
- package/lib/components/YearView/YearView.d.ts +151 -0
- package/lib/components/YearView/get-year-view-events/get-year-view-events.d.ts +8 -0
- package/lib/components/YearView/index.d.ts +1 -0
- package/lib/components/keyboard-navigation.d.ts +7 -0
- package/lib/components/shared.d.ts +161 -0
- package/lib/components/use-slot-drag-select.d.ts +28 -0
- package/lib/hooks/use-event-resize.d.ts +31 -0
- package/lib/index.d.mts +15 -0
- package/lib/index.d.ts +15 -0
- package/lib/labels.d.ts +25 -0
- package/lib/test-utils.d.ts +7 -0
- package/lib/types.d.ts +141 -0
- package/lib/utils/calculate-drop-time/calculate-drop-time.d.ts +22 -0
- package/lib/utils/calculate-month-drop-date/calculate-month-drop-date.d.ts +14 -0
- package/lib/utils/clamp-interval-minutes/clamp-interval-minutes.d.ts +2 -0
- package/lib/utils/expand-recurring-events/expand-recurring-events.d.ts +10 -0
- package/lib/utils/format-date/format-date.d.ts +8 -0
- package/lib/utils/get-business-hours-mod/get-business-hours-mod.d.ts +26 -0
- package/lib/utils/get-current-time-position/get-current-time-position.d.ts +10 -0
- package/lib/utils/get-day-position/get-day-position.d.ts +17 -0
- package/lib/utils/get-day-time-intervals/get-day-time-intervals.d.ts +19 -0
- package/lib/utils/get-end-of-week/get-end-of-week.d.ts +3 -0
- package/lib/utils/get-month-days/get-month-days.d.ts +8 -0
- package/lib/utils/get-month-range/get-month-range.d.ts +13 -0
- package/lib/utils/get-months-by-quarter/get-months-by-quarter.d.ts +2 -0
- package/lib/utils/get-months-list/get-months-list.d.ts +11 -0
- package/lib/utils/get-start-of-week/get-start-of-week.d.ts +7 -0
- package/lib/utils/get-visible-events/get-visible-events.d.ts +9 -0
- package/lib/utils/get-week-days/get-week-days.d.ts +13 -0
- package/lib/utils/get-week-number/get-week-number.d.ts +2 -0
- package/lib/utils/get-weekdays-names/get-weekdays-names.d.ts +9 -0
- package/lib/utils/get-years-list/get-years-list.d.ts +6 -0
- package/lib/utils/index.d.ts +41 -0
- package/lib/utils/is-after-min-date/is-after-min-date.d.ts +2 -0
- package/lib/utils/is-all-day-event/is-all-day-event.d.ts +7 -0
- package/lib/utils/is-before-max-date/is-before-max-date.d.ts +2 -0
- package/lib/utils/is-event-in-time-range/is-event-in-time-range.d.ts +8 -0
- package/lib/utils/is-events-overlap/is-events-overlap.d.ts +3 -0
- package/lib/utils/is-in-time-range/is-in-time-range.d.ts +9 -0
- package/lib/utils/is-multiday-event/is-multiday-event.d.ts +2 -0
- package/lib/utils/is-same-month/is-same-month.d.ts +2 -0
- package/lib/utils/is-within-week/is-within-week.d.ts +8 -0
- package/lib/utils/next-week/next-week.d.ts +2 -0
- package/lib/utils/parse-time-string/parse-time-string.d.ts +6 -0
- package/lib/utils/previous-week/previous-week.d.ts +2 -0
- package/lib/utils/sort-events/sort-events.d.ts +3 -0
- package/lib/utils/to-date-string/to-date-string.d.ts +2 -0
- package/lib/utils/to-time-string/to-time-string.d.ts +2 -0
- package/lib/utils/validate-event/validate-event.d.ts +2 -0
- package/package.json +53 -0
- package/styles.css +2087 -0
- package/styles.layer.css +2089 -0
|
@@ -0,0 +1,294 @@
|
|
|
1
|
+
import { type CSSProperties, type PropType, type SlotsType, type VNodeChild } from 'vue';
|
|
2
|
+
import type { WeekViewProps } from '../../component-props';
|
|
3
|
+
import type { DateLabelFormat, DateStringValue, DayOfWeek } from '../../types';
|
|
4
|
+
import { type EventSlots } from '../shared';
|
|
5
|
+
export interface WeekViewSlots extends EventSlots {
|
|
6
|
+
/** Scoped alternative to the `renderWeekLabel` prop */
|
|
7
|
+
weekLabel?: (props: {
|
|
8
|
+
weekStart: DateStringValue;
|
|
9
|
+
weekEnd: DateStringValue;
|
|
10
|
+
}) => VNodeChild;
|
|
11
|
+
}
|
|
12
|
+
export declare const WeekView: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
13
|
+
withCurrentTimeIndicator: {
|
|
14
|
+
type: BooleanConstructor;
|
|
15
|
+
default: boolean;
|
|
16
|
+
};
|
|
17
|
+
forceCurrentTimeIndicator: BooleanConstructor;
|
|
18
|
+
firstDayOfWeek: {
|
|
19
|
+
type: PropType<DayOfWeek>;
|
|
20
|
+
default: number;
|
|
21
|
+
};
|
|
22
|
+
weekdayFormat: {
|
|
23
|
+
type: PropType<DateLabelFormat>;
|
|
24
|
+
default: string;
|
|
25
|
+
};
|
|
26
|
+
dayFormat: {
|
|
27
|
+
type: PropType<DateLabelFormat>;
|
|
28
|
+
default: string;
|
|
29
|
+
};
|
|
30
|
+
withWeekNumber: {
|
|
31
|
+
type: BooleanConstructor;
|
|
32
|
+
default: boolean;
|
|
33
|
+
};
|
|
34
|
+
withAllDaySlots: {
|
|
35
|
+
type: BooleanConstructor;
|
|
36
|
+
default: boolean;
|
|
37
|
+
};
|
|
38
|
+
withWeekNumbers: {
|
|
39
|
+
type: BooleanConstructor;
|
|
40
|
+
default: undefined;
|
|
41
|
+
};
|
|
42
|
+
withAllDaySlot: {
|
|
43
|
+
type: BooleanConstructor;
|
|
44
|
+
default: undefined;
|
|
45
|
+
};
|
|
46
|
+
allDaySlotsHeight: {
|
|
47
|
+
type: PropType<CSSProperties["height"]>;
|
|
48
|
+
default: number;
|
|
49
|
+
};
|
|
50
|
+
maxAllDayEvents: {
|
|
51
|
+
type: NumberConstructor;
|
|
52
|
+
default: number;
|
|
53
|
+
};
|
|
54
|
+
weekendDays: {
|
|
55
|
+
type: PropType<DayOfWeek[]>;
|
|
56
|
+
default: () => number[];
|
|
57
|
+
};
|
|
58
|
+
withWeekendDays: {
|
|
59
|
+
type: BooleanConstructor;
|
|
60
|
+
default: boolean;
|
|
61
|
+
};
|
|
62
|
+
weekLabelFormat: {
|
|
63
|
+
type: PropType<DateLabelFormat>;
|
|
64
|
+
default: string;
|
|
65
|
+
};
|
|
66
|
+
renderWeekLabel: PropType<WeekViewProps["renderWeekLabel"]>;
|
|
67
|
+
startTime: {
|
|
68
|
+
type: StringConstructor;
|
|
69
|
+
default: string;
|
|
70
|
+
};
|
|
71
|
+
endTime: {
|
|
72
|
+
type: StringConstructor;
|
|
73
|
+
default: string;
|
|
74
|
+
};
|
|
75
|
+
intervalMinutes: {
|
|
76
|
+
type: NumberConstructor;
|
|
77
|
+
default: number;
|
|
78
|
+
};
|
|
79
|
+
slotLabelFormat: {
|
|
80
|
+
type: PropType<DateLabelFormat>;
|
|
81
|
+
default: string;
|
|
82
|
+
};
|
|
83
|
+
withCurrentTimeBubble: {
|
|
84
|
+
type: BooleanConstructor;
|
|
85
|
+
default: boolean;
|
|
86
|
+
};
|
|
87
|
+
getCurrentTime: PropType<() => import("../..").AnyDateValue>;
|
|
88
|
+
slotHeight: {
|
|
89
|
+
type: PropType<CSSProperties["height"]>;
|
|
90
|
+
default: number;
|
|
91
|
+
};
|
|
92
|
+
highlightBusinessHours: BooleanConstructor;
|
|
93
|
+
businessHours: PropType<import("../..").BusinessHoursValue>;
|
|
94
|
+
withEventsDragAndDrop: BooleanConstructor;
|
|
95
|
+
onEventDrop: PropType<(data: import("../../component-props").EventDropData) => void>;
|
|
96
|
+
canDragEvent: PropType<(event: import("../..").ScheduleEventData) => boolean>;
|
|
97
|
+
onEventDragStart: PropType<(event: import("../..").ScheduleEventData) => void>;
|
|
98
|
+
onEventDragEnd: PropType<() => void>;
|
|
99
|
+
onTimeSlotClick: PropType<(data: import("../../component-props").TimeSlotClickData) => void>;
|
|
100
|
+
onAllDaySlotClick: PropType<(date: DateStringValue, nativeEvent: MouseEvent) => void>;
|
|
101
|
+
withDragSlotSelect: BooleanConstructor;
|
|
102
|
+
onSlotDragEnd: FunctionConstructor;
|
|
103
|
+
startScrollTime: StringConstructor;
|
|
104
|
+
onExternalEventDrop: FunctionConstructor;
|
|
105
|
+
withEventResize: BooleanConstructor;
|
|
106
|
+
onEventResize: PropType<(data: import("../../component-props").EventDropData) => void>;
|
|
107
|
+
canResizeEvent: PropType<(event: import("../..").ScheduleEventData) => boolean>;
|
|
108
|
+
date: {
|
|
109
|
+
type: PropType<Date | DateStringValue>;
|
|
110
|
+
required: boolean;
|
|
111
|
+
};
|
|
112
|
+
onDateChange: PropType<(date: DateStringValue) => void>;
|
|
113
|
+
events: PropType<import("../..").ScheduleEventData[]>;
|
|
114
|
+
locale: StringConstructor;
|
|
115
|
+
radius: PropType<string | number>;
|
|
116
|
+
labels: ObjectConstructor;
|
|
117
|
+
mode: {
|
|
118
|
+
type: PropType<import("../..").ScheduleMode>;
|
|
119
|
+
default: string;
|
|
120
|
+
};
|
|
121
|
+
withHeader: {
|
|
122
|
+
type: BooleanConstructor;
|
|
123
|
+
default: boolean;
|
|
124
|
+
};
|
|
125
|
+
onViewChange: PropType<(view: import("../..").ScheduleViewLevel) => void>;
|
|
126
|
+
previousControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
127
|
+
nextControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
128
|
+
todayControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
129
|
+
viewSelectProps: ObjectConstructor;
|
|
130
|
+
renderEventBody: PropType<import("../ScheduleEvent").RenderEventBody>;
|
|
131
|
+
renderEvent: PropType<import("../ScheduleEvent").RenderEvent>;
|
|
132
|
+
onEventClick: PropType<(event: import("../..").ScheduleEventData, nativeEvent: MouseEvent) => void>;
|
|
133
|
+
recurrenceExpansionLimit: {
|
|
134
|
+
type: NumberConstructor;
|
|
135
|
+
default: number;
|
|
136
|
+
};
|
|
137
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
138
|
+
[key: string]: any;
|
|
139
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
140
|
+
withCurrentTimeIndicator: {
|
|
141
|
+
type: BooleanConstructor;
|
|
142
|
+
default: boolean;
|
|
143
|
+
};
|
|
144
|
+
forceCurrentTimeIndicator: BooleanConstructor;
|
|
145
|
+
firstDayOfWeek: {
|
|
146
|
+
type: PropType<DayOfWeek>;
|
|
147
|
+
default: number;
|
|
148
|
+
};
|
|
149
|
+
weekdayFormat: {
|
|
150
|
+
type: PropType<DateLabelFormat>;
|
|
151
|
+
default: string;
|
|
152
|
+
};
|
|
153
|
+
dayFormat: {
|
|
154
|
+
type: PropType<DateLabelFormat>;
|
|
155
|
+
default: string;
|
|
156
|
+
};
|
|
157
|
+
withWeekNumber: {
|
|
158
|
+
type: BooleanConstructor;
|
|
159
|
+
default: boolean;
|
|
160
|
+
};
|
|
161
|
+
withAllDaySlots: {
|
|
162
|
+
type: BooleanConstructor;
|
|
163
|
+
default: boolean;
|
|
164
|
+
};
|
|
165
|
+
withWeekNumbers: {
|
|
166
|
+
type: BooleanConstructor;
|
|
167
|
+
default: undefined;
|
|
168
|
+
};
|
|
169
|
+
withAllDaySlot: {
|
|
170
|
+
type: BooleanConstructor;
|
|
171
|
+
default: undefined;
|
|
172
|
+
};
|
|
173
|
+
allDaySlotsHeight: {
|
|
174
|
+
type: PropType<CSSProperties["height"]>;
|
|
175
|
+
default: number;
|
|
176
|
+
};
|
|
177
|
+
maxAllDayEvents: {
|
|
178
|
+
type: NumberConstructor;
|
|
179
|
+
default: number;
|
|
180
|
+
};
|
|
181
|
+
weekendDays: {
|
|
182
|
+
type: PropType<DayOfWeek[]>;
|
|
183
|
+
default: () => number[];
|
|
184
|
+
};
|
|
185
|
+
withWeekendDays: {
|
|
186
|
+
type: BooleanConstructor;
|
|
187
|
+
default: boolean;
|
|
188
|
+
};
|
|
189
|
+
weekLabelFormat: {
|
|
190
|
+
type: PropType<DateLabelFormat>;
|
|
191
|
+
default: string;
|
|
192
|
+
};
|
|
193
|
+
renderWeekLabel: PropType<WeekViewProps["renderWeekLabel"]>;
|
|
194
|
+
startTime: {
|
|
195
|
+
type: StringConstructor;
|
|
196
|
+
default: string;
|
|
197
|
+
};
|
|
198
|
+
endTime: {
|
|
199
|
+
type: StringConstructor;
|
|
200
|
+
default: string;
|
|
201
|
+
};
|
|
202
|
+
intervalMinutes: {
|
|
203
|
+
type: NumberConstructor;
|
|
204
|
+
default: number;
|
|
205
|
+
};
|
|
206
|
+
slotLabelFormat: {
|
|
207
|
+
type: PropType<DateLabelFormat>;
|
|
208
|
+
default: string;
|
|
209
|
+
};
|
|
210
|
+
withCurrentTimeBubble: {
|
|
211
|
+
type: BooleanConstructor;
|
|
212
|
+
default: boolean;
|
|
213
|
+
};
|
|
214
|
+
getCurrentTime: PropType<() => import("../..").AnyDateValue>;
|
|
215
|
+
slotHeight: {
|
|
216
|
+
type: PropType<CSSProperties["height"]>;
|
|
217
|
+
default: number;
|
|
218
|
+
};
|
|
219
|
+
highlightBusinessHours: BooleanConstructor;
|
|
220
|
+
businessHours: PropType<import("../..").BusinessHoursValue>;
|
|
221
|
+
withEventsDragAndDrop: BooleanConstructor;
|
|
222
|
+
onEventDrop: PropType<(data: import("../../component-props").EventDropData) => void>;
|
|
223
|
+
canDragEvent: PropType<(event: import("../..").ScheduleEventData) => boolean>;
|
|
224
|
+
onEventDragStart: PropType<(event: import("../..").ScheduleEventData) => void>;
|
|
225
|
+
onEventDragEnd: PropType<() => void>;
|
|
226
|
+
onTimeSlotClick: PropType<(data: import("../../component-props").TimeSlotClickData) => void>;
|
|
227
|
+
onAllDaySlotClick: PropType<(date: DateStringValue, nativeEvent: MouseEvent) => void>;
|
|
228
|
+
withDragSlotSelect: BooleanConstructor;
|
|
229
|
+
onSlotDragEnd: FunctionConstructor;
|
|
230
|
+
startScrollTime: StringConstructor;
|
|
231
|
+
onExternalEventDrop: FunctionConstructor;
|
|
232
|
+
withEventResize: BooleanConstructor;
|
|
233
|
+
onEventResize: PropType<(data: import("../../component-props").EventDropData) => void>;
|
|
234
|
+
canResizeEvent: PropType<(event: import("../..").ScheduleEventData) => boolean>;
|
|
235
|
+
date: {
|
|
236
|
+
type: PropType<Date | DateStringValue>;
|
|
237
|
+
required: boolean;
|
|
238
|
+
};
|
|
239
|
+
onDateChange: PropType<(date: DateStringValue) => void>;
|
|
240
|
+
events: PropType<import("../..").ScheduleEventData[]>;
|
|
241
|
+
locale: StringConstructor;
|
|
242
|
+
radius: PropType<string | number>;
|
|
243
|
+
labels: ObjectConstructor;
|
|
244
|
+
mode: {
|
|
245
|
+
type: PropType<import("../..").ScheduleMode>;
|
|
246
|
+
default: string;
|
|
247
|
+
};
|
|
248
|
+
withHeader: {
|
|
249
|
+
type: BooleanConstructor;
|
|
250
|
+
default: boolean;
|
|
251
|
+
};
|
|
252
|
+
onViewChange: PropType<(view: import("../..").ScheduleViewLevel) => void>;
|
|
253
|
+
previousControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
254
|
+
nextControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
255
|
+
todayControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
256
|
+
viewSelectProps: ObjectConstructor;
|
|
257
|
+
renderEventBody: PropType<import("../ScheduleEvent").RenderEventBody>;
|
|
258
|
+
renderEvent: PropType<import("../ScheduleEvent").RenderEvent>;
|
|
259
|
+
onEventClick: PropType<(event: import("../..").ScheduleEventData, nativeEvent: MouseEvent) => void>;
|
|
260
|
+
recurrenceExpansionLimit: {
|
|
261
|
+
type: NumberConstructor;
|
|
262
|
+
default: number;
|
|
263
|
+
};
|
|
264
|
+
}>> & Readonly<{}>, {
|
|
265
|
+
mode: import("../..").ScheduleMode;
|
|
266
|
+
firstDayOfWeek: DayOfWeek;
|
|
267
|
+
weekendDays: DayOfWeek[];
|
|
268
|
+
withWeekNumbers: boolean;
|
|
269
|
+
weekdayFormat: DateLabelFormat;
|
|
270
|
+
startTime: string;
|
|
271
|
+
endTime: string;
|
|
272
|
+
intervalMinutes: number;
|
|
273
|
+
withWeekendDays: boolean;
|
|
274
|
+
slotHeight: import("csstype").Property.Height<string | number> | undefined;
|
|
275
|
+
highlightBusinessHours: boolean;
|
|
276
|
+
withHeader: boolean;
|
|
277
|
+
recurrenceExpansionLimit: number;
|
|
278
|
+
withEventsDragAndDrop: boolean;
|
|
279
|
+
withDragSlotSelect: boolean;
|
|
280
|
+
withEventResize: boolean;
|
|
281
|
+
withAllDaySlot: boolean;
|
|
282
|
+
maxAllDayEvents: number;
|
|
283
|
+
slotLabelFormat: DateLabelFormat;
|
|
284
|
+
withCurrentTimeIndicator: boolean;
|
|
285
|
+
withCurrentTimeBubble: boolean;
|
|
286
|
+
weekLabelFormat: DateLabelFormat;
|
|
287
|
+
forceCurrentTimeIndicator: boolean;
|
|
288
|
+
dayFormat: DateLabelFormat;
|
|
289
|
+
withWeekNumber: boolean;
|
|
290
|
+
withAllDaySlots: boolean;
|
|
291
|
+
allDaySlotsHeight: import("csstype").Property.Height<string | number> | undefined;
|
|
292
|
+
}, SlotsType<WeekViewSlots>, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
293
|
+
export type { WeekViewProps };
|
|
294
|
+
export type WeekViewStylesNames = 'weekView' | 'weekViewRoot' | 'weekViewHeader' | 'weekViewInner' | 'weekViewAllDaySlotsEvents' | 'weekViewAllDaySlots' | 'weekViewAllDaySlotsList' | 'weekViewAllDaySlot' | 'weekViewAllDaySlotsLabel' | 'weekViewScrollArea' | 'weekViewCorner' | 'weekViewSlotLabels' | 'weekViewSlotLabel' | 'weekViewDayLabel' | 'weekViewDayWeekday' | 'weekViewDay' | 'weekViewDayNumber' | 'weekViewDaySlot' | 'weekViewDaySlots' | 'weekViewWeekLabel' | 'weekViewWeekNumber' | 'weekViewBackgroundEvent';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { VNodeChild } from 'vue';
|
|
2
|
+
import { DateLabelFormat, DateStringValue } from '../../../types';
|
|
3
|
+
interface GetWeekLabelInput {
|
|
4
|
+
weekdays: Date[] | string[];
|
|
5
|
+
locale: string;
|
|
6
|
+
weekLabelFormat: DateLabelFormat;
|
|
7
|
+
renderWeekLabel?: (params: {
|
|
8
|
+
weekStart: DateStringValue;
|
|
9
|
+
weekEnd: DateStringValue;
|
|
10
|
+
}) => VNodeChild;
|
|
11
|
+
}
|
|
12
|
+
export declare function getWeekLabel({ weekdays, locale, weekLabelFormat, renderWeekLabel, }: GetWeekLabelInput): VNodeChild;
|
|
13
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Dayjs } from 'dayjs';
|
|
2
|
+
import { DateStringValue } from '../../../types';
|
|
3
|
+
interface CalculateAllDayEventOffsetInput {
|
|
4
|
+
eventStartDate: Dayjs;
|
|
5
|
+
weekStartDate: Dayjs;
|
|
6
|
+
weekDays: DateStringValue[];
|
|
7
|
+
visibleDaysCount: number;
|
|
8
|
+
hangingStart: boolean;
|
|
9
|
+
}
|
|
10
|
+
export declare function calculateAllDayEventOffset({ eventStartDate, weekStartDate, weekDays, visibleDaysCount, hangingStart, }: CalculateAllDayEventOffsetInput): number;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Dayjs } from 'dayjs';
|
|
2
|
+
import { DateStringValue } from '../../../types';
|
|
3
|
+
interface CalculateAllDayEventWidthInput {
|
|
4
|
+
eventStartDate: Dayjs;
|
|
5
|
+
actualEndDate: Dayjs;
|
|
6
|
+
weekStartDate: Dayjs;
|
|
7
|
+
weekEndDate: Dayjs;
|
|
8
|
+
weekDays: DateStringValue[];
|
|
9
|
+
visibleDaysCount: number;
|
|
10
|
+
}
|
|
11
|
+
export declare function calculateAllDayEventWidth({ eventStartDate, actualEndDate, weekStartDate, weekEndDate, weekDays, visibleDaysCount, }: CalculateAllDayEventWidthInput): number;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Dayjs } from 'dayjs';
|
|
2
|
+
import { DateStringValue, ScheduleEventData } from '../../../types';
|
|
3
|
+
interface CalculateEventDaysInput {
|
|
4
|
+
event: ScheduleEventData;
|
|
5
|
+
weekDays: DateStringValue[];
|
|
6
|
+
actualEndDate: Dayjs;
|
|
7
|
+
}
|
|
8
|
+
export declare function calculateEventDays({ event, weekDays, actualEndDate }: CalculateEventDaysInput): string[];
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { AnyDateValue, DayOfWeek, ScheduleEventData } from '../../../types';
|
|
2
|
+
export interface FilterWeekViewEventsInput {
|
|
3
|
+
/** Date (week start) at which events are positioned, used to check if events are all-day */
|
|
4
|
+
date: AnyDateValue;
|
|
5
|
+
/** List of all events that belong to the given week, extra events must be filtered out before passing to the function */
|
|
6
|
+
events: ScheduleEventData[] | undefined;
|
|
7
|
+
/** Start time of the week view, used to calculate event positions */
|
|
8
|
+
startTime?: string;
|
|
9
|
+
/** End time of the week view, used to calculate event positions */
|
|
10
|
+
endTime?: string;
|
|
11
|
+
/** First day of the week, 0 - Sunday, 1 - Monday, etc., used to calculate events positions */
|
|
12
|
+
firstDayOfWeek?: DayOfWeek;
|
|
13
|
+
}
|
|
14
|
+
export declare function filterWeekViewEvents({ date, events, startTime, endTime, firstDayOfWeek, }: FilterWeekViewEventsInput): ScheduleEventData[];
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { DateStringValue, ScheduleEventData } from '../../../types';
|
|
2
|
+
interface FindAvailableColumnInput {
|
|
3
|
+
columns: Map<string, ScheduleEventData[]>;
|
|
4
|
+
event: ScheduleEventData;
|
|
5
|
+
allDay: boolean;
|
|
6
|
+
allWeekDays: DateStringValue[];
|
|
7
|
+
}
|
|
8
|
+
export declare function findAvailableColumn(input: FindAvailableColumnInput): number;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Dayjs } from 'dayjs';
|
|
2
|
+
import { DateStringValue } from '../../../types';
|
|
3
|
+
interface GetHangingStatusInput {
|
|
4
|
+
eventStartDate: Dayjs;
|
|
5
|
+
actualEndDate: Dayjs;
|
|
6
|
+
weekDays: DateStringValue[];
|
|
7
|
+
}
|
|
8
|
+
export declare function getHangingStatus({ eventStartDate, actualEndDate, weekDays, }: GetHangingStatusInput): 'start' | 'end' | 'both' | 'none';
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { AnyDateValue, DateStringValue, DayOfWeek, ScheduleEventData, WeekPositionedEventData } from '../../../types';
|
|
2
|
+
export interface GetWeekPositionedEventsInput {
|
|
3
|
+
/** Date (week start) at which events are positioned, used to check if events are all-day */
|
|
4
|
+
date: AnyDateValue;
|
|
5
|
+
/** List of all events that belong to the given week, extra events must be filtered out before passing to the function */
|
|
6
|
+
events: ScheduleEventData[];
|
|
7
|
+
/** Start time of the week view, used to calculate event positions */
|
|
8
|
+
startTime?: string;
|
|
9
|
+
/** End time of the week view, used to calculate event positions */
|
|
10
|
+
endTime?: string;
|
|
11
|
+
/** Number of minutes per time slot, used to align the canvas to whole slots */
|
|
12
|
+
intervalMinutes?: number;
|
|
13
|
+
/** First day of the week, 0 - Sunday, 1 - Monday, etc., used to calculate events positions */
|
|
14
|
+
firstDayOfWeek?: DayOfWeek;
|
|
15
|
+
/** Indices of weekend days, 0-6, where 0 is Sunday and 6 is Saturday */
|
|
16
|
+
weekendDays?: DayOfWeek[];
|
|
17
|
+
/** If set to false, weekend days are hidden @default true */
|
|
18
|
+
withWeekendDays?: boolean;
|
|
19
|
+
}
|
|
20
|
+
/** Events grouped by week day date (YYYY-MM-DD 00:00:00) and by columns */
|
|
21
|
+
export interface GroupedWeekEvents {
|
|
22
|
+
allDayEvents: WeekPositionedEventData[];
|
|
23
|
+
regularEvents: Record<DateStringValue, WeekPositionedEventData[]>;
|
|
24
|
+
backgroundEvents: Record<DateStringValue, WeekPositionedEventData[]>;
|
|
25
|
+
}
|
|
26
|
+
export declare function getWeekPositionedEvents({ date, events, startTime, endTime, intervalMinutes, firstDayOfWeek, weekendDays, withWeekendDays, }: GetWeekPositionedEventsInput): GroupedWeekEvents;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ScheduleEventData } from '../../../types';
|
|
2
|
+
import { GetWeekPositionedEventsInput, GroupedWeekEvents } from './get-week-positioned-events';
|
|
3
|
+
interface GetWeekViewEventsInput extends Omit<GetWeekPositionedEventsInput, 'events'> {
|
|
4
|
+
events: ScheduleEventData[] | undefined;
|
|
5
|
+
}
|
|
6
|
+
export declare function getWeekViewEvents(input: GetWeekViewEventsInput): GroupedWeekEvents;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
import { type PropType } from 'vue';
|
|
2
|
+
import type { YearViewProps } from '../../component-props';
|
|
3
|
+
import type { DateLabelFormat, DayOfWeek, ScheduleEventData } from '../../types';
|
|
4
|
+
export declare const YearView: import("vue").DefineComponent<import("vue").ExtractPropTypes<{
|
|
5
|
+
firstDayOfWeek: {
|
|
6
|
+
type: PropType<DayOfWeek>;
|
|
7
|
+
default: number;
|
|
8
|
+
};
|
|
9
|
+
weekdayFormat: {
|
|
10
|
+
type: PropType<DateLabelFormat>;
|
|
11
|
+
default: string;
|
|
12
|
+
};
|
|
13
|
+
weekendDays: {
|
|
14
|
+
type: PropType<DayOfWeek[]>;
|
|
15
|
+
default: () => number[];
|
|
16
|
+
};
|
|
17
|
+
withWeekNumbers: BooleanConstructor;
|
|
18
|
+
withWeekDays: {
|
|
19
|
+
type: BooleanConstructor;
|
|
20
|
+
default: boolean;
|
|
21
|
+
};
|
|
22
|
+
consistentWeeks: BooleanConstructor;
|
|
23
|
+
highlightToday: {
|
|
24
|
+
type: BooleanConstructor;
|
|
25
|
+
default: boolean;
|
|
26
|
+
};
|
|
27
|
+
withOutsideDays: {
|
|
28
|
+
type: BooleanConstructor;
|
|
29
|
+
default: boolean;
|
|
30
|
+
};
|
|
31
|
+
monthsListFormat: {
|
|
32
|
+
type: PropType<DateLabelFormat>;
|
|
33
|
+
default: string;
|
|
34
|
+
};
|
|
35
|
+
getDayProps: PropType<YearViewProps["getDayProps"]>;
|
|
36
|
+
getWeekNumberProps: PropType<YearViewProps["getWeekNumberProps"]>;
|
|
37
|
+
onDayClick: PropType<YearViewProps["onDayClick"]>;
|
|
38
|
+
onMonthClick: PropType<YearViewProps["onMonthClick"]>;
|
|
39
|
+
onWeekNumberClick: PropType<YearViewProps["onWeekNumberClick"]>;
|
|
40
|
+
date: {
|
|
41
|
+
type: PropType<Date | import("../..").DateStringValue>;
|
|
42
|
+
required: boolean;
|
|
43
|
+
};
|
|
44
|
+
onDateChange: PropType<(date: import("../..").DateStringValue) => void>;
|
|
45
|
+
events: PropType<ScheduleEventData[]>;
|
|
46
|
+
locale: StringConstructor;
|
|
47
|
+
radius: PropType<string | number>;
|
|
48
|
+
labels: ObjectConstructor;
|
|
49
|
+
mode: {
|
|
50
|
+
type: PropType<import("../..").ScheduleMode>;
|
|
51
|
+
default: string;
|
|
52
|
+
};
|
|
53
|
+
withHeader: {
|
|
54
|
+
type: BooleanConstructor;
|
|
55
|
+
default: boolean;
|
|
56
|
+
};
|
|
57
|
+
onViewChange: PropType<(view: import("../..").ScheduleViewLevel) => void>;
|
|
58
|
+
previousControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
59
|
+
nextControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
60
|
+
todayControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
61
|
+
viewSelectProps: ObjectConstructor;
|
|
62
|
+
renderEventBody: PropType<import("../ScheduleEvent").RenderEventBody>;
|
|
63
|
+
renderEvent: PropType<import("../ScheduleEvent").RenderEvent>;
|
|
64
|
+
onEventClick: PropType<(event: ScheduleEventData, nativeEvent: MouseEvent) => void>;
|
|
65
|
+
recurrenceExpansionLimit: {
|
|
66
|
+
type: NumberConstructor;
|
|
67
|
+
default: number;
|
|
68
|
+
};
|
|
69
|
+
}>, () => import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
|
|
70
|
+
[key: string]: any;
|
|
71
|
+
}>, {}, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
72
|
+
firstDayOfWeek: {
|
|
73
|
+
type: PropType<DayOfWeek>;
|
|
74
|
+
default: number;
|
|
75
|
+
};
|
|
76
|
+
weekdayFormat: {
|
|
77
|
+
type: PropType<DateLabelFormat>;
|
|
78
|
+
default: string;
|
|
79
|
+
};
|
|
80
|
+
weekendDays: {
|
|
81
|
+
type: PropType<DayOfWeek[]>;
|
|
82
|
+
default: () => number[];
|
|
83
|
+
};
|
|
84
|
+
withWeekNumbers: BooleanConstructor;
|
|
85
|
+
withWeekDays: {
|
|
86
|
+
type: BooleanConstructor;
|
|
87
|
+
default: boolean;
|
|
88
|
+
};
|
|
89
|
+
consistentWeeks: BooleanConstructor;
|
|
90
|
+
highlightToday: {
|
|
91
|
+
type: BooleanConstructor;
|
|
92
|
+
default: boolean;
|
|
93
|
+
};
|
|
94
|
+
withOutsideDays: {
|
|
95
|
+
type: BooleanConstructor;
|
|
96
|
+
default: boolean;
|
|
97
|
+
};
|
|
98
|
+
monthsListFormat: {
|
|
99
|
+
type: PropType<DateLabelFormat>;
|
|
100
|
+
default: string;
|
|
101
|
+
};
|
|
102
|
+
getDayProps: PropType<YearViewProps["getDayProps"]>;
|
|
103
|
+
getWeekNumberProps: PropType<YearViewProps["getWeekNumberProps"]>;
|
|
104
|
+
onDayClick: PropType<YearViewProps["onDayClick"]>;
|
|
105
|
+
onMonthClick: PropType<YearViewProps["onMonthClick"]>;
|
|
106
|
+
onWeekNumberClick: PropType<YearViewProps["onWeekNumberClick"]>;
|
|
107
|
+
date: {
|
|
108
|
+
type: PropType<Date | import("../..").DateStringValue>;
|
|
109
|
+
required: boolean;
|
|
110
|
+
};
|
|
111
|
+
onDateChange: PropType<(date: import("../..").DateStringValue) => void>;
|
|
112
|
+
events: PropType<ScheduleEventData[]>;
|
|
113
|
+
locale: StringConstructor;
|
|
114
|
+
radius: PropType<string | number>;
|
|
115
|
+
labels: ObjectConstructor;
|
|
116
|
+
mode: {
|
|
117
|
+
type: PropType<import("../..").ScheduleMode>;
|
|
118
|
+
default: string;
|
|
119
|
+
};
|
|
120
|
+
withHeader: {
|
|
121
|
+
type: BooleanConstructor;
|
|
122
|
+
default: boolean;
|
|
123
|
+
};
|
|
124
|
+
onViewChange: PropType<(view: import("../..").ScheduleViewLevel) => void>;
|
|
125
|
+
previousControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
126
|
+
nextControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
127
|
+
todayControlProps: PropType<import("../../component-props").NativeButtonProps>;
|
|
128
|
+
viewSelectProps: ObjectConstructor;
|
|
129
|
+
renderEventBody: PropType<import("../ScheduleEvent").RenderEventBody>;
|
|
130
|
+
renderEvent: PropType<import("../ScheduleEvent").RenderEvent>;
|
|
131
|
+
onEventClick: PropType<(event: ScheduleEventData, nativeEvent: MouseEvent) => void>;
|
|
132
|
+
recurrenceExpansionLimit: {
|
|
133
|
+
type: NumberConstructor;
|
|
134
|
+
default: number;
|
|
135
|
+
};
|
|
136
|
+
}>> & Readonly<{}>, {
|
|
137
|
+
mode: import("../..").ScheduleMode;
|
|
138
|
+
firstDayOfWeek: DayOfWeek;
|
|
139
|
+
weekendDays: DayOfWeek[];
|
|
140
|
+
consistentWeeks: boolean;
|
|
141
|
+
highlightToday: boolean;
|
|
142
|
+
withWeekNumbers: boolean;
|
|
143
|
+
weekdayFormat: DateLabelFormat;
|
|
144
|
+
monthsListFormat: DateLabelFormat;
|
|
145
|
+
withOutsideDays: boolean;
|
|
146
|
+
withHeader: boolean;
|
|
147
|
+
recurrenceExpansionLimit: number;
|
|
148
|
+
withWeekDays: boolean;
|
|
149
|
+
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
|
150
|
+
export type { YearViewProps };
|
|
151
|
+
export type YearViewStylesNames = 'yearView' | 'yearViewMonths' | 'yearViewMonth' | 'yearViewWeekdays' | 'yearViewWeek' | 'yearViewWeekNumber' | 'yearViewWeekday' | 'yearViewWeekdaysCorner' | 'yearViewDay' | 'yearViewMonthCaption' | 'yearViewDayIndicators' | 'yearViewDayIndicator';
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { AnyDateValue, DateStringValue, ScheduleEventData } from '../../../types';
|
|
2
|
+
export type GroupedEvents = Record<DateStringValue, ScheduleEventData[]>;
|
|
3
|
+
interface GetYearViewEventsInput {
|
|
4
|
+
date: AnyDateValue;
|
|
5
|
+
events: ScheduleEventData[] | undefined;
|
|
6
|
+
}
|
|
7
|
+
export declare function getYearViewEvents({ date, events }: GetYearViewEventsInput): GroupedEvents;
|
|
8
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from './YearView';
|