@reservi/preact 2.0.0-beta.0 → 2.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +16 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +144 -4
- package/dist/index.js +2695 -602
- package/dist/index.js.map +1 -1
- package/package.json +3 -2
package/dist/index.js
CHANGED
|
@@ -1,18 +1,58 @@
|
|
|
1
|
-
import { render as
|
|
2
|
-
import { getLocaleText as
|
|
3
|
-
import { dayGridPlugin as
|
|
4
|
-
import {
|
|
1
|
+
import { render as At, h as ke } from "preact";
|
|
2
|
+
import { getLocaleText as W, dl as g, timeStringToMinutes as X, computeDrop as ht, pxToSnappedMinutes as It, computeResize as $t, resolveBusinessHours as xe, isWithinBusinessHours as Pe, THEME_TOKEN_VARS as Ae, themeToStyle as Ie, CalendarApi as $e, eventsToICS as je } from "@reservi/core";
|
|
3
|
+
import { dayGridPlugin as On, definePlugin as Tn, defineTheme as En, eventsToICS as Mn, listPlugin as Cn, multiMonthPlugin as kn, parseICS as xn, resourcePlugin as Pn, themeToStyle as An, timeGridPlugin as In, timelinePlugin as $n } from "@reservi/core";
|
|
4
|
+
import { jsx as u, jsxs as C } from "preact/jsx-runtime";
|
|
5
5
|
import "@preact/signals";
|
|
6
|
-
import { useRef as F, useState as
|
|
7
|
-
function
|
|
8
|
-
return
|
|
6
|
+
import { useRef as F, useLayoutEffect as jt, useState as V, useEffect as H } from "preact/hooks";
|
|
7
|
+
function hn(t) {
|
|
8
|
+
return { __rsvHost: !0, node: t };
|
|
9
9
|
}
|
|
10
|
-
function
|
|
11
|
-
return
|
|
10
|
+
function Fe(t) {
|
|
11
|
+
return typeof t == "object" && t !== null && t.__rsvHost === !0;
|
|
12
12
|
}
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
function B(t, e, r, n) {
|
|
14
|
+
if (!t) return r;
|
|
15
|
+
const a = t(e);
|
|
16
|
+
return a === void 0 ? r : Fe(a) ? n ? /* @__PURE__ */ u(He, { bridge: n, node: a.node }) : r : a;
|
|
17
|
+
}
|
|
18
|
+
let Re = 0;
|
|
19
|
+
function He({ bridge: t, node: e }) {
|
|
20
|
+
const r = F("");
|
|
21
|
+
r.current || (r.current = `rsv-host-${++Re}`);
|
|
22
|
+
const n = F(null), a = F(e);
|
|
23
|
+
a.current = e;
|
|
24
|
+
const o = F(!1);
|
|
25
|
+
return jt(() => {
|
|
26
|
+
const d = n.current;
|
|
27
|
+
if (!d) return;
|
|
28
|
+
const i = r.current;
|
|
29
|
+
return o.current = !0, t.mount(i, d, a.current), () => {
|
|
30
|
+
o.current = !1, t.unmount(i);
|
|
31
|
+
};
|
|
32
|
+
}, []), jt(() => {
|
|
33
|
+
o.current && t.update(r.current, e);
|
|
34
|
+
}), /* @__PURE__ */ u("div", { "data-rsv": "host", ref: n });
|
|
35
|
+
}
|
|
36
|
+
function K(...t) {
|
|
37
|
+
return t.filter(Boolean).join(" ");
|
|
38
|
+
}
|
|
39
|
+
const Ft = /* @__PURE__ */ new WeakSet();
|
|
40
|
+
function U(t, e, r) {
|
|
41
|
+
if (!t || !e) return;
|
|
42
|
+
const n = t;
|
|
43
|
+
Ft.has(n) || (Ft.add(n), e(Object.assign(r(), { el: n })));
|
|
44
|
+
}
|
|
45
|
+
function Le(t, e) {
|
|
46
|
+
if (!t.length) return null;
|
|
47
|
+
const r = [...t].sort((a, o) => a.breakpoint - o.breakpoint);
|
|
48
|
+
let n = r[0].view;
|
|
49
|
+
for (const a of r)
|
|
50
|
+
e >= a.breakpoint && (n = a.view);
|
|
51
|
+
return n;
|
|
52
|
+
}
|
|
53
|
+
const rt = { prev: "‹", next: "›" }, Ne = /* @__PURE__ */ new Set(["", "title", "today", "prev", "next"]), Be = /month|year/i, nt = (t) => String(t).padStart(2, "0");
|
|
54
|
+
function Ke() {
|
|
55
|
+
return /* @__PURE__ */ C(
|
|
16
56
|
"svg",
|
|
17
57
|
{
|
|
18
58
|
"data-rsv": "title-icon",
|
|
@@ -26,158 +66,158 @@ function ft() {
|
|
|
26
66
|
"stroke-linejoin": "round",
|
|
27
67
|
"aria-hidden": "true",
|
|
28
68
|
children: [
|
|
29
|
-
/* @__PURE__ */
|
|
30
|
-
/* @__PURE__ */
|
|
31
|
-
/* @__PURE__ */
|
|
32
|
-
/* @__PURE__ */
|
|
69
|
+
/* @__PURE__ */ u("rect", { x: "1", y: "2.5", width: "12", height: "10.5", rx: "1.5" }),
|
|
70
|
+
/* @__PURE__ */ u("line", { x1: "1", y1: "5.5", x2: "13", y2: "5.5" }),
|
|
71
|
+
/* @__PURE__ */ u("line", { x1: "4.5", y1: "1", x2: "4.5", y2: "3.5" }),
|
|
72
|
+
/* @__PURE__ */ u("line", { x1: "9.5", y1: "1", x2: "9.5", y2: "3.5" })
|
|
33
73
|
]
|
|
34
74
|
}
|
|
35
75
|
);
|
|
36
76
|
}
|
|
37
|
-
function
|
|
77
|
+
function Ye(t) {
|
|
38
78
|
var r;
|
|
39
|
-
if ((r =
|
|
40
|
-
const
|
|
41
|
-
return
|
|
79
|
+
if ((r = t.views) != null && r.length) return t.views;
|
|
80
|
+
const e = t.headerToolbar;
|
|
81
|
+
return e ? [e.start, e.center, e.end].filter((n) => !!n).flatMap((n) => n.split(/\s+/)).flatMap((n) => n.split(",")).filter((n) => !Ne.has(n)) : [];
|
|
42
82
|
}
|
|
43
|
-
function
|
|
44
|
-
var
|
|
45
|
-
const
|
|
83
|
+
function Ve({ api: t, title: e, activeView: r, options: n }) {
|
|
84
|
+
var P, O, A, j, L;
|
|
85
|
+
const a = W(n.locale), o = (O = (P = n.slots) == null ? void 0 : P.toolbarStart) == null ? void 0 : O.call(P), d = (j = (A = n.slots) == null ? void 0 : A.toolbarEnd) == null ? void 0 : j.call(A), i = Ye(n), s = Be.test(r), l = n.firstDay ?? a.firstDay, c = F(null), [y, T] = V(!1), v = g.toDate(t.getDate()), f = g.toDate(n.now ? g.from(n.now) : g.now()), [p, h] = V(v.getFullYear()), [w, D] = V(v.getMonth()), M = new Intl.DateTimeFormat(n.locale, { month: "short" }), k = new Intl.DateTimeFormat(n.locale, { month: "long" }), m = new Intl.DateTimeFormat(n.locale, { weekday: "short" }), x = Array.from(
|
|
46
86
|
{ length: 12 },
|
|
47
|
-
(
|
|
48
|
-
),
|
|
49
|
-
const
|
|
50
|
-
|
|
51
|
-
},
|
|
52
|
-
const
|
|
53
|
-
|
|
54
|
-
},
|
|
55
|
-
|
|
56
|
-
};
|
|
57
|
-
|
|
58
|
-
const
|
|
59
|
-
(
|
|
60
|
-
},
|
|
61
|
-
|
|
87
|
+
(S, I) => M.format(new Date(2020, I, 1))
|
|
88
|
+
), R = () => {
|
|
89
|
+
const S = g.toDate(t.getDate());
|
|
90
|
+
h(S.getFullYear()), D(S.getMonth()), T(!0);
|
|
91
|
+
}, $ = (S) => {
|
|
92
|
+
const I = p * 12 + w + S;
|
|
93
|
+
h(Math.floor(I / 12)), D((I % 12 + 12) % 12);
|
|
94
|
+
}, b = (S) => {
|
|
95
|
+
t.gotoDate(S), T(!1);
|
|
96
|
+
};
|
|
97
|
+
H(() => {
|
|
98
|
+
const S = (N) => {
|
|
99
|
+
(N.ctrlKey || N.metaKey) && (N.key === "m" || N.key === "M") ? (N.preventDefault(), R()) : N.key === "Escape" && T(!1);
|
|
100
|
+
}, I = (N) => {
|
|
101
|
+
c.current && !c.current.contains(N.target) && T(!1);
|
|
62
102
|
};
|
|
63
|
-
return document.addEventListener("keydown",
|
|
64
|
-
document.removeEventListener("keydown",
|
|
103
|
+
return document.addEventListener("keydown", S), document.addEventListener("mousedown", I), () => {
|
|
104
|
+
document.removeEventListener("keydown", S), document.removeEventListener("mousedown", I);
|
|
65
105
|
};
|
|
66
106
|
}, []);
|
|
67
|
-
const
|
|
107
|
+
const E = (() => {
|
|
68
108
|
if (s) return { cells: [], dows: [] };
|
|
69
|
-
const
|
|
70
|
-
return { cells:
|
|
109
|
+
const S = g.from(`${p}-${nt(w + 1)}-01`), I = (g.dayOfWeek(S) - l + 7) % 7, N = g.subtract(S, { days: I }), xt = Array.from({ length: 42 }, (Pt, Ce) => g.toDate(g.add(N, { days: Ce }))), Me = xt.slice(0, 7).map((Pt) => m.format(Pt));
|
|
110
|
+
return { cells: xt, dows: Me };
|
|
71
111
|
})();
|
|
72
|
-
return /* @__PURE__ */
|
|
73
|
-
/* @__PURE__ */
|
|
74
|
-
/* @__PURE__ */
|
|
75
|
-
/* @__PURE__ */
|
|
76
|
-
/* @__PURE__ */
|
|
112
|
+
return /* @__PURE__ */ C("div", { "data-rsv": "toolbar-wrap", class: K((L = n.classNames) == null ? void 0 : L.toolbar), ref: c, children: [
|
|
113
|
+
/* @__PURE__ */ C("div", { "data-rsv": "toolbar", children: [
|
|
114
|
+
/* @__PURE__ */ u("div", { "data-rsv": "toolbar-section", "data-rsv-area": "start", children: o }),
|
|
115
|
+
/* @__PURE__ */ C("div", { "data-rsv": "toolbar-section", "data-rsv-area": "nav", children: [
|
|
116
|
+
/* @__PURE__ */ u(
|
|
77
117
|
"button",
|
|
78
118
|
{
|
|
79
119
|
type: "button",
|
|
80
120
|
"data-rsv": "button",
|
|
81
|
-
title:
|
|
82
|
-
"aria-label":
|
|
83
|
-
onClick: () =>
|
|
84
|
-
children:
|
|
121
|
+
title: a.todayHint,
|
|
122
|
+
"aria-label": a.todayHint,
|
|
123
|
+
onClick: () => t.today(),
|
|
124
|
+
children: a.today
|
|
85
125
|
}
|
|
86
126
|
),
|
|
87
|
-
/* @__PURE__ */
|
|
127
|
+
/* @__PURE__ */ u(
|
|
88
128
|
"button",
|
|
89
129
|
{
|
|
90
130
|
type: "button",
|
|
91
131
|
"data-rsv": "button",
|
|
92
132
|
"data-rsv-nav": "prev",
|
|
93
|
-
title:
|
|
94
|
-
"aria-label":
|
|
95
|
-
onClick: () =>
|
|
96
|
-
children:
|
|
133
|
+
title: a.prevHint,
|
|
134
|
+
"aria-label": a.prevHint,
|
|
135
|
+
onClick: () => t.prev(),
|
|
136
|
+
children: rt.prev
|
|
97
137
|
}
|
|
98
138
|
),
|
|
99
|
-
/* @__PURE__ */
|
|
100
|
-
/* @__PURE__ */
|
|
139
|
+
/* @__PURE__ */ C("div", { "data-rsv": "datepicker-anchor", children: [
|
|
140
|
+
/* @__PURE__ */ C(
|
|
101
141
|
"button",
|
|
102
142
|
{
|
|
103
143
|
type: "button",
|
|
104
144
|
"data-rsv": "title",
|
|
105
145
|
"aria-haspopup": "dialog",
|
|
106
|
-
"aria-expanded":
|
|
107
|
-
title: `${
|
|
108
|
-
onClick: () =>
|
|
146
|
+
"aria-expanded": y,
|
|
147
|
+
title: `${e} · Ctrl+M`,
|
|
148
|
+
onClick: () => y ? T(!1) : R(),
|
|
109
149
|
children: [
|
|
110
|
-
/* @__PURE__ */
|
|
111
|
-
|
|
150
|
+
/* @__PURE__ */ u(Ke, {}),
|
|
151
|
+
e
|
|
112
152
|
]
|
|
113
153
|
}
|
|
114
154
|
),
|
|
115
|
-
|
|
155
|
+
y && /* @__PURE__ */ C(
|
|
116
156
|
"div",
|
|
117
157
|
{
|
|
118
158
|
"data-rsv": "datepicker",
|
|
119
159
|
"data-rsv-mode": s ? "month" : "day",
|
|
120
160
|
role: "dialog",
|
|
121
|
-
"aria-label":
|
|
161
|
+
"aria-label": e,
|
|
122
162
|
children: [
|
|
123
|
-
/* @__PURE__ */
|
|
124
|
-
/* @__PURE__ */
|
|
163
|
+
/* @__PURE__ */ C("div", { "data-rsv": "dp-head", children: [
|
|
164
|
+
/* @__PURE__ */ u(
|
|
125
165
|
"button",
|
|
126
166
|
{
|
|
127
167
|
type: "button",
|
|
128
168
|
"data-rsv": "dp-nav",
|
|
129
|
-
"aria-label":
|
|
130
|
-
onClick: () => s ?
|
|
131
|
-
children:
|
|
169
|
+
"aria-label": a.prev,
|
|
170
|
+
onClick: () => s ? h((S) => S - 1) : $(-1),
|
|
171
|
+
children: rt.prev
|
|
132
172
|
}
|
|
133
173
|
),
|
|
134
|
-
/* @__PURE__ */
|
|
135
|
-
/* @__PURE__ */
|
|
174
|
+
/* @__PURE__ */ u("span", { "data-rsv": "dp-label", children: s ? p : `${k.format(new Date(p, w, 1))} ${p}` }),
|
|
175
|
+
/* @__PURE__ */ u(
|
|
136
176
|
"button",
|
|
137
177
|
{
|
|
138
178
|
type: "button",
|
|
139
179
|
"data-rsv": "dp-nav",
|
|
140
|
-
"aria-label":
|
|
141
|
-
onClick: () => s ?
|
|
142
|
-
children:
|
|
180
|
+
"aria-label": a.next,
|
|
181
|
+
onClick: () => s ? h((S) => S + 1) : $(1),
|
|
182
|
+
children: rt.next
|
|
143
183
|
}
|
|
144
184
|
)
|
|
145
185
|
] }),
|
|
146
|
-
s ? /* @__PURE__ */
|
|
186
|
+
s ? /* @__PURE__ */ u("div", { "data-rsv": "dp-grid", children: x.map((S, I) => /* @__PURE__ */ u(
|
|
147
187
|
"button",
|
|
148
188
|
{
|
|
149
189
|
type: "button",
|
|
150
190
|
"data-rsv": "dp-month",
|
|
151
191
|
"data-active": String(
|
|
152
|
-
|
|
192
|
+
p === v.getFullYear() && I === v.getMonth()
|
|
153
193
|
),
|
|
154
194
|
"data-today": String(
|
|
155
|
-
|
|
195
|
+
p === f.getFullYear() && I === f.getMonth()
|
|
156
196
|
),
|
|
157
|
-
onClick: () =>
|
|
158
|
-
children:
|
|
197
|
+
onClick: () => b(`${p}-${nt(I + 1)}-01`),
|
|
198
|
+
children: S
|
|
159
199
|
},
|
|
160
|
-
|
|
161
|
-
)) }) : /* @__PURE__ */
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
const
|
|
165
|
-
return /* @__PURE__ */
|
|
200
|
+
S
|
|
201
|
+
)) }) : /* @__PURE__ */ C("div", { "data-rsv": "dp-days", children: [
|
|
202
|
+
E.dows.map((S, I) => /* @__PURE__ */ u("div", { "data-rsv": "dp-dow", children: S }, `dow-${I}`)),
|
|
203
|
+
E.cells.map((S) => {
|
|
204
|
+
const I = `${S.getFullYear()}-${nt(S.getMonth() + 1)}-${nt(S.getDate())}`;
|
|
205
|
+
return /* @__PURE__ */ u(
|
|
166
206
|
"button",
|
|
167
207
|
{
|
|
168
208
|
type: "button",
|
|
169
209
|
"data-rsv": "dp-day",
|
|
170
|
-
"data-other": String(
|
|
210
|
+
"data-other": String(S.getMonth() !== w),
|
|
171
211
|
"data-active": String(
|
|
172
|
-
|
|
212
|
+
S.getFullYear() === v.getFullYear() && S.getMonth() === v.getMonth() && S.getDate() === v.getDate()
|
|
173
213
|
),
|
|
174
214
|
"data-today": String(
|
|
175
|
-
|
|
215
|
+
S.getFullYear() === f.getFullYear() && S.getMonth() === f.getMonth() && S.getDate() === f.getDate()
|
|
176
216
|
),
|
|
177
|
-
onClick: () =>
|
|
178
|
-
children:
|
|
217
|
+
onClick: () => b(I),
|
|
218
|
+
children: S.getDate()
|
|
179
219
|
},
|
|
180
|
-
|
|
220
|
+
I
|
|
181
221
|
);
|
|
182
222
|
})
|
|
183
223
|
] })
|
|
@@ -185,233 +225,1949 @@ function bt({ api: a, title: t, activeView: r, options: e }) {
|
|
|
185
225
|
}
|
|
186
226
|
)
|
|
187
227
|
] }),
|
|
188
|
-
/* @__PURE__ */
|
|
228
|
+
/* @__PURE__ */ u(
|
|
189
229
|
"button",
|
|
190
230
|
{
|
|
191
231
|
type: "button",
|
|
192
232
|
"data-rsv": "button",
|
|
193
233
|
"data-rsv-nav": "next",
|
|
194
|
-
title:
|
|
195
|
-
"aria-label":
|
|
196
|
-
onClick: () =>
|
|
197
|
-
children:
|
|
234
|
+
title: a.nextHint,
|
|
235
|
+
"aria-label": a.nextHint,
|
|
236
|
+
onClick: () => t.next(),
|
|
237
|
+
children: rt.next
|
|
198
238
|
}
|
|
199
239
|
)
|
|
200
240
|
] }),
|
|
201
|
-
/* @__PURE__ */
|
|
202
|
-
|
|
203
|
-
|
|
241
|
+
/* @__PURE__ */ C("div", { "data-rsv": "toolbar-section", "data-rsv-area": "end", children: [
|
|
242
|
+
d,
|
|
243
|
+
n.onAddClick && /* @__PURE__ */ C(
|
|
204
244
|
"button",
|
|
205
245
|
{
|
|
206
246
|
type: "button",
|
|
207
247
|
"data-rsv": "button",
|
|
208
248
|
"data-rsv-variant": "primary",
|
|
209
|
-
onClick:
|
|
249
|
+
onClick: n.onAddClick,
|
|
210
250
|
children: [
|
|
211
|
-
/* @__PURE__ */
|
|
212
|
-
|
|
251
|
+
/* @__PURE__ */ u("span", { "data-rsv": "add-icon", "aria-hidden": "true", children: "+" }),
|
|
252
|
+
n.addButtonText
|
|
213
253
|
]
|
|
214
254
|
}
|
|
215
255
|
)
|
|
216
256
|
] })
|
|
217
257
|
] }),
|
|
218
|
-
|
|
258
|
+
i.length > 0 && /* @__PURE__ */ u("div", { "data-rsv": "toolbar-views", role: "tablist", children: i.map((S) => /* @__PURE__ */ u(
|
|
219
259
|
"button",
|
|
220
260
|
{
|
|
221
261
|
type: "button",
|
|
222
262
|
"data-rsv": "view-tab",
|
|
223
263
|
role: "tab",
|
|
224
|
-
"aria-selected":
|
|
225
|
-
"data-active": String(
|
|
226
|
-
|
|
227
|
-
|
|
264
|
+
"aria-selected": S === r,
|
|
265
|
+
"data-active": String(S === r),
|
|
266
|
+
title: a.viewHint(a.views[S] ?? S),
|
|
267
|
+
onClick: () => t.changeView(S),
|
|
268
|
+
children: a.views[S] ?? S
|
|
228
269
|
},
|
|
229
|
-
|
|
270
|
+
S
|
|
230
271
|
)) })
|
|
231
272
|
] });
|
|
232
273
|
}
|
|
233
|
-
function
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
274
|
+
function st(t) {
|
|
275
|
+
return t < 10 ? `0${t}` : String(t);
|
|
276
|
+
}
|
|
277
|
+
function We(t) {
|
|
278
|
+
const e = (Math.round(t) % 1440 + 1440) % 1440;
|
|
279
|
+
return `${st(Math.floor(e / 60))}:${st(e % 60)}`;
|
|
280
|
+
}
|
|
281
|
+
function Ge(t) {
|
|
282
|
+
const e = Math.max(0, Math.round(t));
|
|
283
|
+
return `${st(Math.floor(e / 60))}:${st(e % 60)}:00`;
|
|
284
|
+
}
|
|
285
|
+
function ct(t, e) {
|
|
286
|
+
if (!e) return null;
|
|
287
|
+
const r = new Intl.DateTimeFormat(t, e);
|
|
288
|
+
return (n) => r.format(n);
|
|
289
|
+
}
|
|
290
|
+
function dt(t, e, r) {
|
|
291
|
+
if (e === !1) return null;
|
|
292
|
+
const n = new Intl.DateTimeFormat(t, e ?? r);
|
|
293
|
+
return (a) => n.format(a);
|
|
294
|
+
}
|
|
295
|
+
function ee(t, e) {
|
|
296
|
+
t.trigger("navLinkDay", { date: e });
|
|
297
|
+
const r = t.hasView("timeGridDay") ? "timeGridDay" : t.hasView("dayGridDay") ? "dayGridDay" : null;
|
|
298
|
+
r && (t.gotoDate(g.toISOString(e)), t.changeView(r));
|
|
299
|
+
}
|
|
300
|
+
const at = 1440, Ue = {
|
|
301
|
+
moveLeft: ["ArrowLeft"],
|
|
302
|
+
moveRight: ["ArrowRight"],
|
|
303
|
+
moveUp: ["ArrowUp"],
|
|
304
|
+
moveDown: ["ArrowDown"],
|
|
305
|
+
activate: ["Enter", " "]
|
|
306
|
+
};
|
|
307
|
+
function ze(t, e) {
|
|
308
|
+
const r = Object.entries(Ue);
|
|
309
|
+
for (const [n, a] of r)
|
|
310
|
+
if (((e == null ? void 0 : e[n]) ?? a).includes(t)) return n;
|
|
311
|
+
return null;
|
|
312
|
+
}
|
|
313
|
+
function re(t, e) {
|
|
314
|
+
const { api: r, event: n, kind: a } = e, o = X(e.snap ?? "00:30"), d = ze(t.key, e.shortcuts);
|
|
315
|
+
if (!d) return;
|
|
316
|
+
if (d === "activate") {
|
|
317
|
+
t.preventDefault(), r.trigger("eventClick", { event: n });
|
|
318
|
+
return;
|
|
319
|
+
}
|
|
320
|
+
let i = 0;
|
|
321
|
+
switch (d) {
|
|
322
|
+
case "moveLeft":
|
|
323
|
+
i = -at;
|
|
245
324
|
break;
|
|
246
|
-
case "
|
|
247
|
-
|
|
325
|
+
case "moveRight":
|
|
326
|
+
i = at;
|
|
248
327
|
break;
|
|
249
|
-
case "
|
|
250
|
-
|
|
328
|
+
case "moveUp":
|
|
329
|
+
i = a === "timeGrid" ? -o : -at * 7;
|
|
251
330
|
break;
|
|
252
|
-
case "
|
|
253
|
-
|
|
331
|
+
case "moveDown":
|
|
332
|
+
i = a === "timeGrid" ? o : at * 7;
|
|
254
333
|
break;
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
334
|
+
}
|
|
335
|
+
t.preventDefault();
|
|
336
|
+
const s = ht(n.start, n.end, i, g);
|
|
337
|
+
if (r.moveEvent(n.id, s.start, s.end)) {
|
|
338
|
+
const l = r.getEventById(n.id);
|
|
339
|
+
l && r.trigger("eventDrop", { event: l });
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
function qe(t, e) {
|
|
343
|
+
var n;
|
|
344
|
+
const r = document.elementFromPoint(t, e);
|
|
345
|
+
return ((n = r == null ? void 0 : r.closest('[data-rsv="day"]')) == null ? void 0 : n.dataset.date) ?? null;
|
|
346
|
+
}
|
|
347
|
+
function Xe(t, e) {
|
|
348
|
+
if (t.target.closest('[data-rsv="event"], [data-rsv="more-anchor"], [data-nav-link="true"]'))
|
|
349
|
+
return;
|
|
350
|
+
const { api: n } = e;
|
|
351
|
+
let a = e.startDate, o = !1;
|
|
352
|
+
const d = (s) => {
|
|
353
|
+
const l = qe(s.clientX, s.clientY);
|
|
354
|
+
l && l !== e.startDate && (o = !0), l && (a = l);
|
|
355
|
+
}, i = () => {
|
|
356
|
+
var T;
|
|
357
|
+
if (document.removeEventListener("pointermove", d), document.removeEventListener("pointerup", i), !o) return;
|
|
358
|
+
(T = e.onRangeSelect) == null || T.call(e);
|
|
359
|
+
const s = g.from(e.startDate), l = g.from(a), [c, y] = g.isBefore(s, l) ? [s, l] : [l, s];
|
|
360
|
+
n.select(g.toISOString(c), g.toISOString(g.add(y, { days: 1 })));
|
|
361
|
+
};
|
|
362
|
+
document.addEventListener("pointermove", d), document.addEventListener("pointerup", i);
|
|
363
|
+
}
|
|
364
|
+
function _e(t) {
|
|
365
|
+
if (Array.isArray(t)) return t;
|
|
366
|
+
}
|
|
367
|
+
function Ze(t, e) {
|
|
368
|
+
var r = t == null ? null : typeof Symbol < "u" && t[Symbol.iterator] || t["@@iterator"];
|
|
369
|
+
if (r != null) {
|
|
370
|
+
var n, a, o, d, i = [], s = !0, l = !1;
|
|
371
|
+
try {
|
|
372
|
+
if (o = (r = r.call(t)).next, e !== 0) for (; !(s = (n = o.call(r)).done) && (i.push(n.value), i.length !== e); s = !0) ;
|
|
373
|
+
} catch (c) {
|
|
374
|
+
l = !0, a = c;
|
|
375
|
+
} finally {
|
|
376
|
+
try {
|
|
377
|
+
if (!s && r.return != null && (d = r.return(), Object(d) !== d)) return;
|
|
378
|
+
} finally {
|
|
379
|
+
if (l) throw a;
|
|
380
|
+
}
|
|
381
|
+
}
|
|
382
|
+
return i;
|
|
383
|
+
}
|
|
384
|
+
}
|
|
385
|
+
function bt(t, e) {
|
|
386
|
+
(e == null || e > t.length) && (e = t.length);
|
|
387
|
+
for (var r = 0, n = Array(e); r < e; r++) n[r] = t[r];
|
|
388
|
+
return n;
|
|
389
|
+
}
|
|
390
|
+
function ne(t, e) {
|
|
391
|
+
if (t) {
|
|
392
|
+
if (typeof t == "string") return bt(t, e);
|
|
393
|
+
var r = {}.toString.call(t).slice(8, -1);
|
|
394
|
+
return r === "Object" && t.constructor && (r = t.constructor.name), r === "Map" || r === "Set" ? Array.from(t) : r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r) ? bt(t, e) : void 0;
|
|
395
|
+
}
|
|
396
|
+
}
|
|
397
|
+
function Je() {
|
|
398
|
+
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
399
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
400
|
+
}
|
|
401
|
+
function ae(t, e) {
|
|
402
|
+
return _e(t) || Ze(t, e) || ne(t, e) || Je();
|
|
403
|
+
}
|
|
404
|
+
var ft = {}, Z = {}, Rt;
|
|
405
|
+
function oe() {
|
|
406
|
+
if (Rt) return Z;
|
|
407
|
+
Rt = 1, Object.defineProperty(Z, "__esModule", { value: !0 }), Z.bind = void 0;
|
|
408
|
+
function t(e, r) {
|
|
409
|
+
var n = r.type, a = r.listener, o = r.options;
|
|
410
|
+
return e.addEventListener(n, a, o), function() {
|
|
411
|
+
e.removeEventListener(n, a, o);
|
|
412
|
+
};
|
|
413
|
+
}
|
|
414
|
+
return Z.bind = t, Z;
|
|
415
|
+
}
|
|
416
|
+
var G = {}, Ht;
|
|
417
|
+
function Qe() {
|
|
418
|
+
if (Ht) return G;
|
|
419
|
+
Ht = 1;
|
|
420
|
+
var t = G && G.__assign || function() {
|
|
421
|
+
return t = Object.assign || function(o) {
|
|
422
|
+
for (var d, i = 1, s = arguments.length; i < s; i++) {
|
|
423
|
+
d = arguments[i];
|
|
424
|
+
for (var l in d) Object.prototype.hasOwnProperty.call(d, l) && (o[l] = d[l]);
|
|
425
|
+
}
|
|
426
|
+
return o;
|
|
427
|
+
}, t.apply(this, arguments);
|
|
428
|
+
};
|
|
429
|
+
Object.defineProperty(G, "__esModule", { value: !0 }), G.bindAll = void 0;
|
|
430
|
+
var e = /* @__PURE__ */ oe();
|
|
431
|
+
function r(o) {
|
|
432
|
+
if (!(typeof o > "u"))
|
|
433
|
+
return typeof o == "boolean" ? {
|
|
434
|
+
capture: o
|
|
435
|
+
} : o;
|
|
436
|
+
}
|
|
437
|
+
function n(o, d) {
|
|
438
|
+
if (d == null)
|
|
439
|
+
return o;
|
|
440
|
+
var i = t(t({}, o), { options: t(t({}, r(d)), r(o.options)) });
|
|
441
|
+
return i;
|
|
442
|
+
}
|
|
443
|
+
function a(o, d, i) {
|
|
444
|
+
var s = d.map(function(l) {
|
|
445
|
+
var c = n(l, i);
|
|
446
|
+
return (0, e.bind)(o, c);
|
|
447
|
+
});
|
|
448
|
+
return function() {
|
|
449
|
+
s.forEach(function(c) {
|
|
450
|
+
return c();
|
|
451
|
+
});
|
|
452
|
+
};
|
|
453
|
+
}
|
|
454
|
+
return G.bindAll = a, G;
|
|
455
|
+
}
|
|
456
|
+
var Lt;
|
|
457
|
+
function tr() {
|
|
458
|
+
return Lt || (Lt = 1, (function(t) {
|
|
459
|
+
Object.defineProperty(t, "__esModule", { value: !0 }), t.bindAll = t.bind = void 0;
|
|
460
|
+
var e = /* @__PURE__ */ oe();
|
|
461
|
+
Object.defineProperty(t, "bind", { enumerable: !0, get: function() {
|
|
462
|
+
return e.bind;
|
|
463
|
+
} });
|
|
464
|
+
var r = /* @__PURE__ */ Qe();
|
|
465
|
+
Object.defineProperty(t, "bindAll", { enumerable: !0, get: function() {
|
|
466
|
+
return r.bindAll;
|
|
467
|
+
} });
|
|
468
|
+
})(ft)), ft;
|
|
469
|
+
}
|
|
470
|
+
var _ = /* @__PURE__ */ tr(), ie = "data-pdnd-honey-pot";
|
|
471
|
+
function se(t) {
|
|
472
|
+
return t instanceof Element && t.hasAttribute(ie);
|
|
473
|
+
}
|
|
474
|
+
function de(t) {
|
|
475
|
+
var e = document.elementsFromPoint(t.x, t.y), r = ae(e, 2), n = r[0], a = r[1];
|
|
476
|
+
return n ? se(n) ? a ?? null : n : null;
|
|
477
|
+
}
|
|
478
|
+
function Q(t) {
|
|
479
|
+
"@babel/helpers - typeof";
|
|
480
|
+
return Q = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(e) {
|
|
481
|
+
return typeof e;
|
|
482
|
+
} : function(e) {
|
|
483
|
+
return e && typeof Symbol == "function" && e.constructor === Symbol && e !== Symbol.prototype ? "symbol" : typeof e;
|
|
484
|
+
}, Q(t);
|
|
485
|
+
}
|
|
486
|
+
function er(t, e) {
|
|
487
|
+
if (Q(t) != "object" || !t) return t;
|
|
488
|
+
var r = t[Symbol.toPrimitive];
|
|
489
|
+
if (r !== void 0) {
|
|
490
|
+
var n = r.call(t, e);
|
|
491
|
+
if (Q(n) != "object") return n;
|
|
492
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
493
|
+
}
|
|
494
|
+
return (e === "string" ? String : Number)(t);
|
|
495
|
+
}
|
|
496
|
+
function rr(t) {
|
|
497
|
+
var e = er(t, "string");
|
|
498
|
+
return Q(e) == "symbol" ? e : e + "";
|
|
499
|
+
}
|
|
500
|
+
function ut(t, e, r) {
|
|
501
|
+
return (e = rr(e)) in t ? Object.defineProperty(t, e, {
|
|
502
|
+
value: r,
|
|
503
|
+
enumerable: !0,
|
|
504
|
+
configurable: !0,
|
|
505
|
+
writable: !0
|
|
506
|
+
}) : t[e] = r, t;
|
|
507
|
+
}
|
|
508
|
+
var le = 2147483647, ce = {
|
|
509
|
+
inset: "unset",
|
|
510
|
+
border: "none",
|
|
511
|
+
padding: 0,
|
|
512
|
+
margin: 0,
|
|
513
|
+
overflow: "visible",
|
|
514
|
+
color: "inherit",
|
|
515
|
+
background: "transparent",
|
|
516
|
+
width: "auto",
|
|
517
|
+
height: "auto"
|
|
518
|
+
};
|
|
519
|
+
function z(t) {
|
|
520
|
+
var e = null;
|
|
521
|
+
return function() {
|
|
522
|
+
if (!e) {
|
|
523
|
+
for (var n = arguments.length, a = new Array(n), o = 0; o < n; o++)
|
|
524
|
+
a[o] = arguments[o];
|
|
525
|
+
var d = t.apply(this, a);
|
|
526
|
+
e = {
|
|
527
|
+
result: d
|
|
528
|
+
};
|
|
529
|
+
}
|
|
530
|
+
return e.result;
|
|
531
|
+
};
|
|
532
|
+
}
|
|
533
|
+
var q = z(function() {
|
|
534
|
+
return typeof HTMLElement < "u" && typeof HTMLElement.prototype.showPopover == "function";
|
|
535
|
+
});
|
|
536
|
+
function Nt(t, e) {
|
|
537
|
+
var r = Object.keys(t);
|
|
538
|
+
if (Object.getOwnPropertySymbols) {
|
|
539
|
+
var n = Object.getOwnPropertySymbols(t);
|
|
540
|
+
e && (n = n.filter(function(a) {
|
|
541
|
+
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
542
|
+
})), r.push.apply(r, n);
|
|
543
|
+
}
|
|
544
|
+
return r;
|
|
545
|
+
}
|
|
546
|
+
function Bt(t) {
|
|
547
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
548
|
+
var r = arguments[e] != null ? arguments[e] : {};
|
|
549
|
+
e % 2 ? Nt(Object(r), !0).forEach(function(n) {
|
|
550
|
+
ut(t, n, r[n]);
|
|
551
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : Nt(Object(r)).forEach(function(n) {
|
|
552
|
+
Object.defineProperty(t, n, Object.getOwnPropertyDescriptor(r, n));
|
|
553
|
+
});
|
|
554
|
+
}
|
|
555
|
+
return t;
|
|
556
|
+
}
|
|
557
|
+
var tt = 2, Kt = tt / 2;
|
|
558
|
+
function nr(t) {
|
|
559
|
+
return {
|
|
560
|
+
x: Math.floor(t.x),
|
|
561
|
+
y: Math.floor(t.y)
|
|
562
|
+
};
|
|
563
|
+
}
|
|
564
|
+
function ar(t) {
|
|
565
|
+
return {
|
|
566
|
+
x: t.x - Kt,
|
|
567
|
+
y: t.y - Kt
|
|
568
|
+
};
|
|
569
|
+
}
|
|
570
|
+
function or(t) {
|
|
571
|
+
return {
|
|
572
|
+
x: Math.max(t.x, 0),
|
|
573
|
+
y: Math.max(t.y, 0)
|
|
574
|
+
};
|
|
575
|
+
}
|
|
576
|
+
function ir(t) {
|
|
577
|
+
return {
|
|
578
|
+
x: Math.min(t.x, window.innerWidth - tt),
|
|
579
|
+
y: Math.min(t.y, window.innerHeight - tt)
|
|
580
|
+
};
|
|
581
|
+
}
|
|
582
|
+
function Yt(t) {
|
|
583
|
+
var e = t.client, r = ir(or(ar(nr(e))));
|
|
584
|
+
return DOMRect.fromRect({
|
|
585
|
+
x: r.x,
|
|
586
|
+
y: r.y,
|
|
587
|
+
width: tt,
|
|
588
|
+
height: tt
|
|
589
|
+
});
|
|
590
|
+
}
|
|
591
|
+
function Vt(t) {
|
|
592
|
+
var e = t.clientRect;
|
|
593
|
+
return {
|
|
594
|
+
left: "".concat(e.left, "px"),
|
|
595
|
+
top: "".concat(e.top, "px"),
|
|
596
|
+
width: "".concat(e.width, "px"),
|
|
597
|
+
height: "".concat(e.height, "px")
|
|
598
|
+
};
|
|
599
|
+
}
|
|
600
|
+
function sr(t) {
|
|
601
|
+
var e = t.client, r = t.clientRect;
|
|
602
|
+
return (
|
|
603
|
+
// is within horizontal bounds
|
|
604
|
+
e.x >= r.x && e.x <= r.x + r.width && // is within vertical bounds
|
|
605
|
+
e.y >= r.y && e.y <= r.y + r.height
|
|
606
|
+
);
|
|
607
|
+
}
|
|
608
|
+
function dr(t) {
|
|
609
|
+
var e = t.initial, r = document.createElement("div");
|
|
610
|
+
r.setAttribute(ie, "true"), q() && r.setAttribute("popover", "manual");
|
|
611
|
+
var n = Yt({
|
|
612
|
+
client: e
|
|
613
|
+
});
|
|
614
|
+
Object.assign(r.style, Bt(Bt({
|
|
615
|
+
position: "fixed"
|
|
616
|
+
}, q() ? (
|
|
617
|
+
// needs to come first as it has 'inset: unset' which
|
|
618
|
+
// needs to be overridden by our top / left values
|
|
619
|
+
ce
|
|
620
|
+
) : {
|
|
621
|
+
// Fallback: using maximum possible z-index so that this element
|
|
622
|
+
// will always be on top of other positioned content.
|
|
623
|
+
zIndex: le
|
|
624
|
+
}), {}, {
|
|
625
|
+
// Setting a background color explicitly to avoid any inherited styles.
|
|
626
|
+
// Looks like this could be `opacity: 0`, but worried that _might_
|
|
627
|
+
// cause the element to be ignored on some platforms.
|
|
628
|
+
// When debugging, set backgroundColor to something like "red".
|
|
629
|
+
backgroundColor: "transparent",
|
|
630
|
+
// Being explicit to avoid inheriting styles
|
|
631
|
+
padding: 0,
|
|
632
|
+
margin: 0,
|
|
633
|
+
boxSizing: "border-box",
|
|
634
|
+
// We want this element to absorb pointer events,
|
|
635
|
+
// it's kind of the whole point 😉
|
|
636
|
+
pointerEvents: "auto"
|
|
637
|
+
}, Vt({
|
|
638
|
+
clientRect: n
|
|
639
|
+
}))), document.body.appendChild(r), q() && r.showPopover();
|
|
640
|
+
var a = _.bind(window, {
|
|
641
|
+
type: "pointermove",
|
|
642
|
+
listener: function(d) {
|
|
643
|
+
var i = {
|
|
644
|
+
x: d.clientX,
|
|
645
|
+
y: d.clientY
|
|
646
|
+
};
|
|
647
|
+
n = Yt({
|
|
648
|
+
client: i
|
|
649
|
+
}), Object.assign(r.style, Vt({
|
|
650
|
+
clientRect: n
|
|
651
|
+
}));
|
|
652
|
+
},
|
|
653
|
+
// using capture so we are less likely to be impacted by event stopping
|
|
654
|
+
options: {
|
|
655
|
+
capture: !0
|
|
656
|
+
}
|
|
657
|
+
});
|
|
658
|
+
return function(d) {
|
|
659
|
+
var i = d.current;
|
|
660
|
+
if (a(), sr({
|
|
661
|
+
client: i,
|
|
662
|
+
clientRect: n
|
|
663
|
+
})) {
|
|
664
|
+
r.remove();
|
|
260
665
|
return;
|
|
666
|
+
}
|
|
667
|
+
function s() {
|
|
668
|
+
l(), r.remove();
|
|
669
|
+
}
|
|
670
|
+
var l = _.bindAll(window, [
|
|
671
|
+
{
|
|
672
|
+
type: "pointerdown",
|
|
673
|
+
listener: s
|
|
674
|
+
},
|
|
675
|
+
{
|
|
676
|
+
type: "pointermove",
|
|
677
|
+
listener: s
|
|
678
|
+
},
|
|
679
|
+
{
|
|
680
|
+
type: "focusin",
|
|
681
|
+
listener: s
|
|
682
|
+
},
|
|
683
|
+
{
|
|
684
|
+
type: "focusout",
|
|
685
|
+
listener: s
|
|
686
|
+
},
|
|
687
|
+
// a 'pointerdown' should happen before 'dragstart', but just being super safe
|
|
688
|
+
{
|
|
689
|
+
type: "dragstart",
|
|
690
|
+
listener: s
|
|
691
|
+
},
|
|
692
|
+
// if the user has dragged something out of the window
|
|
693
|
+
// and then is dragging something back into the window
|
|
694
|
+
// the first events we will see are "dragenter" (and then "dragover").
|
|
695
|
+
// So if we see any of these we need to clear the post drag fix.
|
|
696
|
+
{
|
|
697
|
+
type: "dragenter",
|
|
698
|
+
listener: s
|
|
699
|
+
},
|
|
700
|
+
{
|
|
701
|
+
type: "dragover",
|
|
702
|
+
listener: s
|
|
703
|
+
}
|
|
704
|
+
// Not adding a "wheel" event listener, as "wheel" by itself does not
|
|
705
|
+
// resolve the bug.
|
|
706
|
+
], {
|
|
707
|
+
// Using `capture` so less likely to be impacted by other code stopping events
|
|
708
|
+
capture: !0
|
|
709
|
+
});
|
|
710
|
+
};
|
|
711
|
+
}
|
|
712
|
+
function lr() {
|
|
713
|
+
var t = null;
|
|
714
|
+
function e() {
|
|
715
|
+
return t = null, _.bind(window, {
|
|
716
|
+
type: "pointermove",
|
|
717
|
+
listener: function(a) {
|
|
718
|
+
t = {
|
|
719
|
+
x: a.clientX,
|
|
720
|
+
y: a.clientY
|
|
721
|
+
};
|
|
722
|
+
},
|
|
723
|
+
// listening for pointer move in capture phase
|
|
724
|
+
// so we are less likely to be impacted by events being stopped.
|
|
725
|
+
options: {
|
|
726
|
+
capture: !0
|
|
727
|
+
}
|
|
728
|
+
});
|
|
729
|
+
}
|
|
730
|
+
function r() {
|
|
731
|
+
var n = null;
|
|
732
|
+
return function(o) {
|
|
733
|
+
var d = o.eventName, i = o.payload;
|
|
734
|
+
if (d === "onDragStart") {
|
|
735
|
+
var s = i.location.initial.input, l = t ?? {
|
|
736
|
+
x: s.clientX,
|
|
737
|
+
y: s.clientY
|
|
738
|
+
};
|
|
739
|
+
n = dr({
|
|
740
|
+
initial: l
|
|
741
|
+
});
|
|
742
|
+
}
|
|
743
|
+
if (d === "onDrop") {
|
|
744
|
+
var c, y = i.location.current.input;
|
|
745
|
+
(c = n) === null || c === void 0 || c({
|
|
746
|
+
current: {
|
|
747
|
+
x: y.clientX,
|
|
748
|
+
y: y.clientY
|
|
749
|
+
}
|
|
750
|
+
}), n = null, t = null;
|
|
751
|
+
}
|
|
752
|
+
};
|
|
753
|
+
}
|
|
754
|
+
return {
|
|
755
|
+
bindEvents: e,
|
|
756
|
+
getOnPostDispatch: r
|
|
757
|
+
};
|
|
758
|
+
}
|
|
759
|
+
function cr(t) {
|
|
760
|
+
if (Array.isArray(t)) return bt(t);
|
|
761
|
+
}
|
|
762
|
+
function ur(t) {
|
|
763
|
+
if (typeof Symbol < "u" && t[Symbol.iterator] != null || t["@@iterator"] != null) return Array.from(t);
|
|
764
|
+
}
|
|
765
|
+
function vr() {
|
|
766
|
+
throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
767
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
768
|
+
}
|
|
769
|
+
function ue(t) {
|
|
770
|
+
return cr(t) || ur(t) || ne(t) || vr();
|
|
771
|
+
}
|
|
772
|
+
var fr = z(function() {
|
|
773
|
+
return process.env.NODE_ENV === "test" ? !1 : navigator.userAgent.includes("Firefox");
|
|
774
|
+
}), vt = z(function() {
|
|
775
|
+
if (process.env.NODE_ENV === "test")
|
|
776
|
+
return !1;
|
|
777
|
+
var e = navigator, r = e.userAgent;
|
|
778
|
+
return r.includes("AppleWebKit") && !r.includes("Chrome");
|
|
779
|
+
});
|
|
780
|
+
function gr(t) {
|
|
781
|
+
return "nodeName" in t;
|
|
782
|
+
}
|
|
783
|
+
function mr(t) {
|
|
784
|
+
return gr(t) && t.ownerDocument !== document;
|
|
785
|
+
}
|
|
786
|
+
var wt = {
|
|
787
|
+
isLeavingWindow: Symbol("leaving"),
|
|
788
|
+
isEnteringWindow: Symbol("entering")
|
|
789
|
+
};
|
|
790
|
+
(function() {
|
|
791
|
+
if (typeof window > "u" || process.env.NODE_ENV === "test" || !vt())
|
|
792
|
+
return;
|
|
793
|
+
function e() {
|
|
794
|
+
return {
|
|
795
|
+
enterCount: 0,
|
|
796
|
+
isOverWindow: !1
|
|
797
|
+
};
|
|
798
|
+
}
|
|
799
|
+
var r = e();
|
|
800
|
+
function n() {
|
|
801
|
+
r = e();
|
|
802
|
+
}
|
|
803
|
+
_.bindAll(
|
|
804
|
+
window,
|
|
805
|
+
[{
|
|
806
|
+
type: "dragstart",
|
|
807
|
+
listener: function() {
|
|
808
|
+
r.enterCount = 0, r.isOverWindow = !0;
|
|
809
|
+
}
|
|
810
|
+
}, {
|
|
811
|
+
type: "drop",
|
|
812
|
+
listener: n
|
|
813
|
+
}, {
|
|
814
|
+
type: "dragend",
|
|
815
|
+
listener: n
|
|
816
|
+
}, {
|
|
817
|
+
type: "dragenter",
|
|
818
|
+
listener: function(o) {
|
|
819
|
+
!r.isOverWindow && r.enterCount === 0 && (o[wt.isEnteringWindow] = !0), r.isOverWindow = !0, r.enterCount++;
|
|
820
|
+
}
|
|
821
|
+
}, {
|
|
822
|
+
type: "dragleave",
|
|
823
|
+
listener: function(o) {
|
|
824
|
+
r.enterCount--, r.isOverWindow && r.enterCount === 0 && (o[wt.isLeavingWindow] = !0, r.isOverWindow = !1);
|
|
825
|
+
}
|
|
826
|
+
}],
|
|
827
|
+
// using `capture: true` so that adding event listeners
|
|
828
|
+
// in bubble phase will have the correct symbols
|
|
829
|
+
{
|
|
830
|
+
capture: !0
|
|
831
|
+
}
|
|
832
|
+
);
|
|
833
|
+
})();
|
|
834
|
+
function yr(t) {
|
|
835
|
+
var e = t.dragLeave;
|
|
836
|
+
return vt() ? e.hasOwnProperty(wt.isLeavingWindow) : !1;
|
|
837
|
+
}
|
|
838
|
+
function pr(t) {
|
|
839
|
+
var e = t.dragLeave, r = e.type, n = e.relatedTarget;
|
|
840
|
+
return r !== "dragleave" ? !1 : vt() ? yr({
|
|
841
|
+
dragLeave: e
|
|
842
|
+
}) : n == null ? !0 : fr() ? mr(n) : n instanceof HTMLIFrameElement;
|
|
843
|
+
}
|
|
844
|
+
function hr(t) {
|
|
845
|
+
var e = t.onDragEnd;
|
|
846
|
+
return [
|
|
847
|
+
// ## Detecting drag ending for removed draggables
|
|
848
|
+
//
|
|
849
|
+
// If a draggable element is removed during a drag and the user drops:
|
|
850
|
+
// 1. if over a valid drop target: we get a "drop" event to know the drag is finished
|
|
851
|
+
// 2. if not over a valid drop target (or cancelled): we get nothing
|
|
852
|
+
// The "dragend" event will not fire on the source draggable if it has been
|
|
853
|
+
// removed from the DOM.
|
|
854
|
+
// So we need to figure out if a drag operation has finished by looking at other events
|
|
855
|
+
// We can do this by looking at other events
|
|
856
|
+
// ### First detection: "pointermove" events
|
|
857
|
+
// 1. "pointermove" events cannot fire during a drag and drop operation
|
|
858
|
+
// according to the spec. So if we get a "pointermove" it means that
|
|
859
|
+
// the drag and drop operations has finished. So if we get a "pointermove"
|
|
860
|
+
// we know that the drag is over
|
|
861
|
+
// 2. 🦊😤 Drag and drop operations are _supposed_ to suppress
|
|
862
|
+
// other pointer events. However, firefox will allow a few
|
|
863
|
+
// pointer event to get through after a drag starts.
|
|
864
|
+
// The most I've seen is 3
|
|
865
|
+
{
|
|
866
|
+
type: "pointermove",
|
|
867
|
+
listener: /* @__PURE__ */ (function() {
|
|
868
|
+
var r = 0;
|
|
869
|
+
return function() {
|
|
870
|
+
if (r < 20) {
|
|
871
|
+
r++;
|
|
872
|
+
return;
|
|
873
|
+
}
|
|
874
|
+
e();
|
|
875
|
+
};
|
|
876
|
+
})()
|
|
877
|
+
},
|
|
878
|
+
// ### Second detection: "pointerdown" events
|
|
879
|
+
// If we receive this event then we know that a drag operation has finished
|
|
880
|
+
// and potentially another one is about to start.
|
|
881
|
+
// Note: `pointerdown` fires on all browsers / platforms before "dragstart"
|
|
882
|
+
{
|
|
883
|
+
type: "pointerdown",
|
|
884
|
+
listener: e
|
|
885
|
+
}
|
|
886
|
+
];
|
|
887
|
+
}
|
|
888
|
+
function J(t) {
|
|
889
|
+
return {
|
|
890
|
+
altKey: t.altKey,
|
|
891
|
+
button: t.button,
|
|
892
|
+
buttons: t.buttons,
|
|
893
|
+
ctrlKey: t.ctrlKey,
|
|
894
|
+
metaKey: t.metaKey,
|
|
895
|
+
shiftKey: t.shiftKey,
|
|
896
|
+
clientX: t.clientX,
|
|
897
|
+
clientY: t.clientY,
|
|
898
|
+
pageX: t.pageX,
|
|
899
|
+
pageY: t.pageY
|
|
900
|
+
};
|
|
901
|
+
}
|
|
902
|
+
var br = function(e) {
|
|
903
|
+
var r = [], n = null, a = function() {
|
|
904
|
+
for (var d = arguments.length, i = new Array(d), s = 0; s < d; s++)
|
|
905
|
+
i[s] = arguments[s];
|
|
906
|
+
r = i, !n && (n = requestAnimationFrame(function() {
|
|
907
|
+
n = null, e.apply(void 0, r);
|
|
908
|
+
}));
|
|
909
|
+
};
|
|
910
|
+
return a.cancel = function() {
|
|
911
|
+
n && (cancelAnimationFrame(n), n = null);
|
|
912
|
+
}, a;
|
|
913
|
+
}, gt = br(function(t) {
|
|
914
|
+
return t();
|
|
915
|
+
}), ot = /* @__PURE__ */ (function() {
|
|
916
|
+
var t = null;
|
|
917
|
+
function e(n) {
|
|
918
|
+
var a = requestAnimationFrame(function() {
|
|
919
|
+
t = null, n();
|
|
920
|
+
});
|
|
921
|
+
t = {
|
|
922
|
+
frameId: a,
|
|
923
|
+
fn: n
|
|
924
|
+
};
|
|
261
925
|
}
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
}
|
|
269
|
-
|
|
270
|
-
function
|
|
271
|
-
var e
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
926
|
+
function r() {
|
|
927
|
+
t && (cancelAnimationFrame(t.frameId), t.fn(), t = null);
|
|
928
|
+
}
|
|
929
|
+
return {
|
|
930
|
+
schedule: e,
|
|
931
|
+
flush: r
|
|
932
|
+
};
|
|
933
|
+
})();
|
|
934
|
+
function wr(t) {
|
|
935
|
+
var e = t.source, r = t.initial, n = t.dispatchEvent, a = {
|
|
936
|
+
dropTargets: []
|
|
937
|
+
};
|
|
938
|
+
function o(i) {
|
|
939
|
+
n(i), a = {
|
|
940
|
+
dropTargets: i.payload.location.current.dropTargets
|
|
941
|
+
};
|
|
942
|
+
}
|
|
943
|
+
var d = {
|
|
944
|
+
start: function(s) {
|
|
945
|
+
var l = s.nativeSetDragImage, c = {
|
|
946
|
+
current: r,
|
|
947
|
+
previous: a,
|
|
948
|
+
initial: r
|
|
949
|
+
};
|
|
950
|
+
o({
|
|
951
|
+
eventName: "onGenerateDragPreview",
|
|
952
|
+
payload: {
|
|
953
|
+
source: e,
|
|
954
|
+
location: c,
|
|
955
|
+
nativeSetDragImage: l
|
|
956
|
+
}
|
|
957
|
+
}), ot.schedule(function() {
|
|
958
|
+
o({
|
|
959
|
+
eventName: "onDragStart",
|
|
960
|
+
payload: {
|
|
961
|
+
source: e,
|
|
962
|
+
location: c
|
|
963
|
+
}
|
|
964
|
+
});
|
|
965
|
+
});
|
|
966
|
+
},
|
|
967
|
+
dragUpdate: function(s) {
|
|
968
|
+
var l = s.current;
|
|
969
|
+
ot.flush(), gt.cancel(), o({
|
|
970
|
+
eventName: "onDropTargetChange",
|
|
971
|
+
payload: {
|
|
972
|
+
source: e,
|
|
973
|
+
location: {
|
|
974
|
+
initial: r,
|
|
975
|
+
previous: a,
|
|
976
|
+
current: l
|
|
977
|
+
}
|
|
978
|
+
}
|
|
979
|
+
});
|
|
980
|
+
},
|
|
981
|
+
drag: function(s) {
|
|
982
|
+
var l = s.current;
|
|
983
|
+
gt(function() {
|
|
984
|
+
ot.flush();
|
|
985
|
+
var c = {
|
|
986
|
+
initial: r,
|
|
987
|
+
previous: a,
|
|
988
|
+
current: l
|
|
989
|
+
};
|
|
990
|
+
o({
|
|
991
|
+
eventName: "onDrag",
|
|
992
|
+
payload: {
|
|
993
|
+
source: e,
|
|
994
|
+
location: c
|
|
995
|
+
}
|
|
996
|
+
});
|
|
997
|
+
});
|
|
998
|
+
},
|
|
999
|
+
drop: function(s) {
|
|
1000
|
+
var l = s.current, c = s.updatedSourcePayload;
|
|
1001
|
+
ot.flush(), gt.cancel(), o({
|
|
1002
|
+
eventName: "onDrop",
|
|
1003
|
+
payload: {
|
|
1004
|
+
source: c ?? e,
|
|
1005
|
+
location: {
|
|
1006
|
+
current: l,
|
|
1007
|
+
previous: a,
|
|
1008
|
+
initial: r
|
|
1009
|
+
}
|
|
1010
|
+
}
|
|
1011
|
+
});
|
|
1012
|
+
}
|
|
1013
|
+
};
|
|
1014
|
+
return d;
|
|
1015
|
+
}
|
|
1016
|
+
var Dt = {
|
|
1017
|
+
isActive: !1
|
|
1018
|
+
};
|
|
1019
|
+
function ve() {
|
|
1020
|
+
return !Dt.isActive;
|
|
1021
|
+
}
|
|
1022
|
+
function Dr(t) {
|
|
1023
|
+
return t.dataTransfer ? t.dataTransfer.setDragImage.bind(t.dataTransfer) : null;
|
|
1024
|
+
}
|
|
1025
|
+
function Sr(t) {
|
|
1026
|
+
var e = t.current, r = t.next;
|
|
1027
|
+
if (e.length !== r.length)
|
|
1028
|
+
return !0;
|
|
1029
|
+
for (var n = 0; n < e.length; n++)
|
|
1030
|
+
if (e[n].element !== r[n].element)
|
|
1031
|
+
return !0;
|
|
1032
|
+
return !1;
|
|
1033
|
+
}
|
|
1034
|
+
function Or(t) {
|
|
1035
|
+
var e = t.event, r = t.dragType, n = t.getDropTargetsOver, a = t.dispatchEvent;
|
|
1036
|
+
if (!ve())
|
|
299
1037
|
return;
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
e
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
1038
|
+
var o = Tr({
|
|
1039
|
+
event: e,
|
|
1040
|
+
dragType: r,
|
|
1041
|
+
getDropTargetsOver: n
|
|
1042
|
+
});
|
|
1043
|
+
Dt.isActive = !0;
|
|
1044
|
+
var d = {
|
|
1045
|
+
current: o
|
|
1046
|
+
};
|
|
1047
|
+
mt({
|
|
1048
|
+
event: e,
|
|
1049
|
+
current: o.dropTargets
|
|
1050
|
+
});
|
|
1051
|
+
var i = wr({
|
|
1052
|
+
source: r.payload,
|
|
1053
|
+
dispatchEvent: a,
|
|
1054
|
+
initial: o
|
|
1055
|
+
});
|
|
1056
|
+
function s(v) {
|
|
1057
|
+
var f = Sr({
|
|
1058
|
+
current: d.current.dropTargets,
|
|
1059
|
+
next: v.dropTargets
|
|
1060
|
+
});
|
|
1061
|
+
d.current = v, f && i.dragUpdate({
|
|
1062
|
+
current: d.current
|
|
1063
|
+
});
|
|
1064
|
+
}
|
|
1065
|
+
function l(v) {
|
|
1066
|
+
var f = J(v), p = se(v.target) ? de({
|
|
1067
|
+
x: f.clientX,
|
|
1068
|
+
y: f.clientY
|
|
1069
|
+
}) : v.target, h = n({
|
|
1070
|
+
target: p,
|
|
1071
|
+
input: f,
|
|
1072
|
+
source: r.payload,
|
|
1073
|
+
current: d.current.dropTargets
|
|
1074
|
+
});
|
|
1075
|
+
h.length && (v.preventDefault(), mt({
|
|
1076
|
+
event: v,
|
|
1077
|
+
current: h
|
|
1078
|
+
})), s({
|
|
1079
|
+
dropTargets: h,
|
|
1080
|
+
input: f
|
|
1081
|
+
});
|
|
1082
|
+
}
|
|
1083
|
+
function c() {
|
|
1084
|
+
d.current.dropTargets.length && s({
|
|
1085
|
+
dropTargets: [],
|
|
1086
|
+
input: d.current.input
|
|
1087
|
+
}), i.drop({
|
|
1088
|
+
current: d.current,
|
|
1089
|
+
updatedSourcePayload: null
|
|
1090
|
+
}), y();
|
|
1091
|
+
}
|
|
1092
|
+
function y() {
|
|
1093
|
+
Dt.isActive = !1, T();
|
|
1094
|
+
}
|
|
1095
|
+
var T = _.bindAll(
|
|
1096
|
+
window,
|
|
1097
|
+
[{
|
|
1098
|
+
// 👋 Note: we are repurposing the `dragover` event as our `drag` event
|
|
1099
|
+
// this is because firefox does not publish pointer coordinates during
|
|
1100
|
+
// a `drag` event, but does for every other type of drag event
|
|
1101
|
+
// `dragover` fires on all elements that are being dragged over
|
|
1102
|
+
// Because we are binding to `window` - our `dragover` is effectively the same as a `drag`
|
|
1103
|
+
// 🦊😤
|
|
1104
|
+
type: "dragover",
|
|
1105
|
+
listener: function(f) {
|
|
1106
|
+
l(f), i.drag({
|
|
1107
|
+
current: d.current
|
|
1108
|
+
});
|
|
1109
|
+
}
|
|
1110
|
+
}, {
|
|
1111
|
+
type: "dragenter",
|
|
1112
|
+
listener: l
|
|
1113
|
+
}, {
|
|
1114
|
+
type: "dragleave",
|
|
1115
|
+
listener: function(f) {
|
|
1116
|
+
pr({
|
|
1117
|
+
dragLeave: f
|
|
1118
|
+
}) && (s({
|
|
1119
|
+
input: d.current.input,
|
|
1120
|
+
dropTargets: []
|
|
1121
|
+
}), r.startedFrom === "external" && c());
|
|
1122
|
+
}
|
|
1123
|
+
}, {
|
|
1124
|
+
// A "drop" can only happen if the browser allowed the drop
|
|
1125
|
+
type: "drop",
|
|
1126
|
+
listener: function(f) {
|
|
1127
|
+
if (d.current = {
|
|
1128
|
+
dropTargets: d.current.dropTargets,
|
|
1129
|
+
input: J(f)
|
|
1130
|
+
}, !d.current.dropTargets.length) {
|
|
1131
|
+
c();
|
|
1132
|
+
return;
|
|
1133
|
+
}
|
|
1134
|
+
f.preventDefault(), mt({
|
|
1135
|
+
event: f,
|
|
1136
|
+
current: d.current.dropTargets
|
|
1137
|
+
}), i.drop({
|
|
1138
|
+
current: d.current,
|
|
1139
|
+
// When dropping something native, we need to extract the latest
|
|
1140
|
+
// `.items` from the "drop" event as it is now accessible
|
|
1141
|
+
updatedSourcePayload: r.type === "external" ? r.getDropPayload(f) : null
|
|
1142
|
+
}), y();
|
|
1143
|
+
}
|
|
1144
|
+
}, {
|
|
1145
|
+
// "dragend" fires when on the drag source (eg a draggable element)
|
|
1146
|
+
// when the drag is finished.
|
|
1147
|
+
// "dragend" will fire after "drop" (if there was a successful drop)
|
|
1148
|
+
// "dragend" does not fire if the draggable source has been removed during the drag
|
|
1149
|
+
// or for external drag sources (eg files)
|
|
1150
|
+
// This "dragend" listener will not fire if there was a successful drop
|
|
1151
|
+
// as we will have already removed the event listener
|
|
1152
|
+
type: "dragend",
|
|
1153
|
+
listener: function(f) {
|
|
1154
|
+
d.current = {
|
|
1155
|
+
dropTargets: d.current.dropTargets,
|
|
1156
|
+
input: J(f)
|
|
1157
|
+
}, c();
|
|
1158
|
+
}
|
|
1159
|
+
}].concat(ue(hr({
|
|
1160
|
+
onDragEnd: c
|
|
1161
|
+
}))),
|
|
1162
|
+
// Once we have started a managed drag operation it is important that we see / own all drag events
|
|
1163
|
+
// We got one adoption bug pop up where some code was stopping (`event.stopPropagation()`)
|
|
1164
|
+
// all "drop" events in the bubble phase on the `document.body`.
|
|
1165
|
+
// This meant that we never saw the "drop" event.
|
|
1166
|
+
{
|
|
1167
|
+
capture: !0
|
|
1168
|
+
}
|
|
1169
|
+
);
|
|
1170
|
+
i.start({
|
|
1171
|
+
nativeSetDragImage: Dr(e)
|
|
1172
|
+
});
|
|
1173
|
+
}
|
|
1174
|
+
function mt(t) {
|
|
1175
|
+
var e, r = t.event, n = t.current, a = (e = n[0]) === null || e === void 0 ? void 0 : e.dropEffect;
|
|
1176
|
+
a != null && r.dataTransfer && (r.dataTransfer.dropEffect = a);
|
|
1177
|
+
}
|
|
1178
|
+
function Tr(t) {
|
|
1179
|
+
var e = t.event, r = t.dragType, n = t.getDropTargetsOver, a = J(e);
|
|
1180
|
+
if (r.startedFrom === "external")
|
|
1181
|
+
return {
|
|
1182
|
+
input: a,
|
|
1183
|
+
dropTargets: []
|
|
1184
|
+
};
|
|
1185
|
+
var o = n({
|
|
1186
|
+
input: a,
|
|
1187
|
+
source: r.payload,
|
|
1188
|
+
target: e.target,
|
|
1189
|
+
current: []
|
|
1190
|
+
});
|
|
1191
|
+
return {
|
|
1192
|
+
input: a,
|
|
1193
|
+
dropTargets: o
|
|
1194
|
+
};
|
|
1195
|
+
}
|
|
1196
|
+
var Wt = {
|
|
1197
|
+
canStart: ve,
|
|
1198
|
+
start: Or
|
|
1199
|
+
}, St = /* @__PURE__ */ new Map();
|
|
1200
|
+
function Er(t) {
|
|
1201
|
+
var e = t.typeKey, r = t.mount, n = St.get(e);
|
|
1202
|
+
if (n)
|
|
1203
|
+
return n.usageCount++, n;
|
|
1204
|
+
var a = {
|
|
1205
|
+
typeKey: e,
|
|
1206
|
+
unmount: r(),
|
|
1207
|
+
usageCount: 1
|
|
1208
|
+
};
|
|
1209
|
+
return St.set(e, a), a;
|
|
1210
|
+
}
|
|
1211
|
+
function Mr(t) {
|
|
1212
|
+
var e = Er(t);
|
|
1213
|
+
return function() {
|
|
1214
|
+
e.usageCount--, !(e.usageCount > 0) && (e.unmount(), St.delete(t.typeKey));
|
|
1215
|
+
};
|
|
1216
|
+
}
|
|
1217
|
+
function Et() {
|
|
1218
|
+
for (var t = arguments.length, e = new Array(t), r = 0; r < t; r++)
|
|
1219
|
+
e[r] = arguments[r];
|
|
1220
|
+
return function() {
|
|
1221
|
+
e.forEach(function(a) {
|
|
1222
|
+
return a();
|
|
1223
|
+
});
|
|
1224
|
+
};
|
|
1225
|
+
}
|
|
1226
|
+
function fe(t, e) {
|
|
1227
|
+
var r = e.attribute, n = e.value;
|
|
1228
|
+
return t.setAttribute(r, n), function() {
|
|
1229
|
+
return t.removeAttribute(r);
|
|
1230
|
+
};
|
|
1231
|
+
}
|
|
1232
|
+
function Gt(t, e) {
|
|
1233
|
+
var r = Object.keys(t);
|
|
1234
|
+
if (Object.getOwnPropertySymbols) {
|
|
1235
|
+
var n = Object.getOwnPropertySymbols(t);
|
|
1236
|
+
e && (n = n.filter(function(a) {
|
|
1237
|
+
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
1238
|
+
})), r.push.apply(r, n);
|
|
1239
|
+
}
|
|
1240
|
+
return r;
|
|
1241
|
+
}
|
|
1242
|
+
function Y(t) {
|
|
1243
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
1244
|
+
var r = arguments[e] != null ? arguments[e] : {};
|
|
1245
|
+
e % 2 ? Gt(Object(r), !0).forEach(function(n) {
|
|
1246
|
+
ut(t, n, r[n]);
|
|
1247
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : Gt(Object(r)).forEach(function(n) {
|
|
1248
|
+
Object.defineProperty(t, n, Object.getOwnPropertyDescriptor(r, n));
|
|
1249
|
+
});
|
|
1250
|
+
}
|
|
1251
|
+
return t;
|
|
1252
|
+
}
|
|
1253
|
+
function yt(t, e) {
|
|
1254
|
+
var r = typeof Symbol < "u" && t[Symbol.iterator] || t["@@iterator"];
|
|
1255
|
+
if (!r) {
|
|
1256
|
+
if (Array.isArray(t) || (r = Cr(t)) || e) {
|
|
1257
|
+
r && (t = r);
|
|
1258
|
+
var n = 0, a = function() {
|
|
1259
|
+
};
|
|
1260
|
+
return { s: a, n: function() {
|
|
1261
|
+
return n >= t.length ? { done: !0 } : { done: !1, value: t[n++] };
|
|
1262
|
+
}, e: function(l) {
|
|
1263
|
+
throw l;
|
|
1264
|
+
}, f: a };
|
|
1265
|
+
}
|
|
1266
|
+
throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
1267
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
1268
|
+
}
|
|
1269
|
+
var o, d = !0, i = !1;
|
|
1270
|
+
return { s: function() {
|
|
1271
|
+
r = r.call(t);
|
|
1272
|
+
}, n: function() {
|
|
1273
|
+
var l = r.next();
|
|
1274
|
+
return d = l.done, l;
|
|
1275
|
+
}, e: function(l) {
|
|
1276
|
+
i = !0, o = l;
|
|
1277
|
+
}, f: function() {
|
|
1278
|
+
try {
|
|
1279
|
+
d || r.return == null || r.return();
|
|
1280
|
+
} finally {
|
|
1281
|
+
if (i) throw o;
|
|
1282
|
+
}
|
|
1283
|
+
} };
|
|
1284
|
+
}
|
|
1285
|
+
function Cr(t, e) {
|
|
1286
|
+
if (t) {
|
|
1287
|
+
if (typeof t == "string") return Ut(t, e);
|
|
1288
|
+
var r = {}.toString.call(t).slice(8, -1);
|
|
1289
|
+
return r === "Object" && t.constructor && (r = t.constructor.name), r === "Map" || r === "Set" ? Array.from(t) : r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r) ? Ut(t, e) : void 0;
|
|
1290
|
+
}
|
|
1291
|
+
}
|
|
1292
|
+
function Ut(t, e) {
|
|
1293
|
+
(e == null || e > t.length) && (e = t.length);
|
|
1294
|
+
for (var r = 0, n = Array(e); r < e; r++) n[r] = t[r];
|
|
1295
|
+
return n;
|
|
1296
|
+
}
|
|
1297
|
+
function pt(t) {
|
|
1298
|
+
return t.slice(0).reverse();
|
|
1299
|
+
}
|
|
1300
|
+
function kr(t) {
|
|
1301
|
+
var e = t.typeKey, r = t.defaultDropEffect, n = /* @__PURE__ */ new WeakMap(), a = "data-drop-target-for-".concat(e), o = "[".concat(a, "]");
|
|
1302
|
+
function d(v) {
|
|
1303
|
+
return n.set(v.element, v), function() {
|
|
1304
|
+
return n.delete(v.element);
|
|
1305
|
+
};
|
|
1306
|
+
}
|
|
1307
|
+
function i(v) {
|
|
1308
|
+
if (process.env.NODE_ENV !== "production") {
|
|
1309
|
+
var f = n.get(v.element);
|
|
1310
|
+
f && console.warn("You have already registered a [".concat(e, "] dropTarget on the same element"), {
|
|
1311
|
+
existing: f,
|
|
1312
|
+
proposed: v
|
|
1313
|
+
}), v.element instanceof HTMLIFrameElement && console.warn(`
|
|
1314
|
+
We recommend not registering <iframe> elements as drop targets
|
|
1315
|
+
as it can result in some strange browser event ordering.
|
|
1316
|
+
`.replace(/\s{2,}/g, " ").trim());
|
|
1317
|
+
}
|
|
1318
|
+
var p = Et(fe(v.element, {
|
|
1319
|
+
attribute: a,
|
|
1320
|
+
value: "true"
|
|
1321
|
+
}), d(v));
|
|
1322
|
+
return z(p);
|
|
1323
|
+
}
|
|
1324
|
+
function s(v) {
|
|
1325
|
+
var f, p, h, w, D = v.source, M = v.target, k = v.input, m = v.result, x = m === void 0 ? [] : m;
|
|
1326
|
+
if (M == null)
|
|
1327
|
+
return x;
|
|
1328
|
+
if (!(M instanceof Element))
|
|
1329
|
+
return M instanceof Node ? s({
|
|
1330
|
+
source: D,
|
|
1331
|
+
target: M.parentElement,
|
|
1332
|
+
input: k,
|
|
1333
|
+
result: x
|
|
1334
|
+
}) : x;
|
|
1335
|
+
var R = M.closest(o);
|
|
1336
|
+
if (R == null)
|
|
1337
|
+
return x;
|
|
1338
|
+
var $ = n.get(R);
|
|
1339
|
+
if ($ == null)
|
|
1340
|
+
return x;
|
|
1341
|
+
var b = {
|
|
1342
|
+
input: k,
|
|
1343
|
+
source: D,
|
|
1344
|
+
element: $.element
|
|
1345
|
+
};
|
|
1346
|
+
if ($.canDrop && !$.canDrop(b))
|
|
1347
|
+
return s({
|
|
1348
|
+
source: D,
|
|
1349
|
+
target: $.element.parentElement,
|
|
1350
|
+
input: k,
|
|
1351
|
+
result: x
|
|
1352
|
+
});
|
|
1353
|
+
var E = (f = (p = $.getData) === null || p === void 0 ? void 0 : p.call($, b)) !== null && f !== void 0 ? f : {}, P = (h = (w = $.getDropEffect) === null || w === void 0 ? void 0 : w.call($, b)) !== null && h !== void 0 ? h : r, O = {
|
|
1354
|
+
data: E,
|
|
1355
|
+
element: $.element,
|
|
1356
|
+
dropEffect: P,
|
|
1357
|
+
// we are collecting _actual_ drop targets, so these are
|
|
1358
|
+
// being applied _not_ due to stickiness
|
|
1359
|
+
isActiveDueToStickiness: !1
|
|
1360
|
+
};
|
|
1361
|
+
return s({
|
|
1362
|
+
source: D,
|
|
1363
|
+
target: $.element.parentElement,
|
|
1364
|
+
input: k,
|
|
1365
|
+
// Using bubble ordering. Same ordering as `event.getPath()`
|
|
1366
|
+
result: [].concat(ue(x), [O])
|
|
1367
|
+
});
|
|
1368
|
+
}
|
|
1369
|
+
function l(v) {
|
|
1370
|
+
var f = v.eventName, p = v.payload, h = yt(p.location.current.dropTargets), w;
|
|
1371
|
+
try {
|
|
1372
|
+
for (h.s(); !(w = h.n()).done; ) {
|
|
1373
|
+
var D, M = w.value, k = n.get(M.element), m = Y(Y({}, p), {}, {
|
|
1374
|
+
self: M
|
|
1375
|
+
});
|
|
1376
|
+
k == null || (D = k[f]) === null || D === void 0 || D.call(
|
|
1377
|
+
k,
|
|
1378
|
+
// I cannot seem to get the types right here.
|
|
1379
|
+
// TS doesn't seem to like that one event can need `nativeSetDragImage`
|
|
1380
|
+
// @ts-expect-error
|
|
1381
|
+
m
|
|
1382
|
+
);
|
|
1383
|
+
}
|
|
1384
|
+
} catch (x) {
|
|
1385
|
+
h.e(x);
|
|
1386
|
+
} finally {
|
|
1387
|
+
h.f();
|
|
1388
|
+
}
|
|
1389
|
+
}
|
|
1390
|
+
var c = {
|
|
1391
|
+
onGenerateDragPreview: l,
|
|
1392
|
+
onDrag: l,
|
|
1393
|
+
onDragStart: l,
|
|
1394
|
+
onDrop: l,
|
|
1395
|
+
onDropTargetChange: function(f) {
|
|
1396
|
+
var p = f.payload, h = new Set(p.location.current.dropTargets.map(function(I) {
|
|
1397
|
+
return I.element;
|
|
1398
|
+
})), w = /* @__PURE__ */ new Set(), D = yt(p.location.previous.dropTargets), M;
|
|
1399
|
+
try {
|
|
1400
|
+
for (D.s(); !(M = D.n()).done; ) {
|
|
1401
|
+
var k, m = M.value;
|
|
1402
|
+
w.add(m.element);
|
|
1403
|
+
var x = n.get(m.element), R = h.has(m.element), $ = Y(Y({}, p), {}, {
|
|
1404
|
+
self: m
|
|
1405
|
+
});
|
|
1406
|
+
if (x == null || (k = x.onDropTargetChange) === null || k === void 0 || k.call(x, $), !R) {
|
|
1407
|
+
var b;
|
|
1408
|
+
x == null || (b = x.onDragLeave) === null || b === void 0 || b.call(x, $);
|
|
1409
|
+
}
|
|
1410
|
+
}
|
|
1411
|
+
} catch (I) {
|
|
1412
|
+
D.e(I);
|
|
1413
|
+
} finally {
|
|
1414
|
+
D.f();
|
|
1415
|
+
}
|
|
1416
|
+
var E = yt(p.location.current.dropTargets), P;
|
|
1417
|
+
try {
|
|
1418
|
+
for (E.s(); !(P = E.n()).done; ) {
|
|
1419
|
+
var O, A, j = P.value;
|
|
1420
|
+
if (!w.has(j.element)) {
|
|
1421
|
+
var L = Y(Y({}, p), {}, {
|
|
1422
|
+
self: j
|
|
1423
|
+
}), S = n.get(j.element);
|
|
1424
|
+
S == null || (O = S.onDropTargetChange) === null || O === void 0 || O.call(S, L), S == null || (A = S.onDragEnter) === null || A === void 0 || A.call(S, L);
|
|
1425
|
+
}
|
|
1426
|
+
}
|
|
1427
|
+
} catch (I) {
|
|
1428
|
+
E.e(I);
|
|
1429
|
+
} finally {
|
|
1430
|
+
E.f();
|
|
1431
|
+
}
|
|
1432
|
+
}
|
|
1433
|
+
};
|
|
1434
|
+
function y(v) {
|
|
1435
|
+
c[v.eventName](v);
|
|
1436
|
+
}
|
|
1437
|
+
function T(v) {
|
|
1438
|
+
var f = v.source, p = v.target, h = v.input, w = v.current, D = s({
|
|
1439
|
+
source: f,
|
|
1440
|
+
target: p,
|
|
1441
|
+
input: h
|
|
1442
|
+
});
|
|
1443
|
+
if (D.length >= w.length)
|
|
1444
|
+
return D;
|
|
1445
|
+
for (var M = pt(w), k = pt(D), m = [], x = 0; x < M.length; x++) {
|
|
1446
|
+
var R, $ = M[x], b = k[x];
|
|
1447
|
+
if (b != null) {
|
|
1448
|
+
m.push(b);
|
|
1449
|
+
continue;
|
|
1450
|
+
}
|
|
1451
|
+
var E = m[x - 1], P = M[x - 1];
|
|
1452
|
+
if ((E == null ? void 0 : E.element) !== (P == null ? void 0 : P.element))
|
|
1453
|
+
break;
|
|
1454
|
+
var O = n.get($.element);
|
|
1455
|
+
if (!O)
|
|
1456
|
+
break;
|
|
1457
|
+
var A = {
|
|
1458
|
+
input: h,
|
|
1459
|
+
source: f,
|
|
1460
|
+
element: O.element
|
|
1461
|
+
};
|
|
1462
|
+
if (O.canDrop && !O.canDrop(A) || !((R = O.getIsSticky) !== null && R !== void 0 && R.call(O, A)))
|
|
1463
|
+
break;
|
|
1464
|
+
m.push(Y(Y({}, $), {}, {
|
|
1465
|
+
// making it clear to consumers this drop target is active due to stickiness
|
|
1466
|
+
isActiveDueToStickiness: !0
|
|
1467
|
+
}));
|
|
1468
|
+
}
|
|
1469
|
+
return pt(m);
|
|
1470
|
+
}
|
|
1471
|
+
return {
|
|
1472
|
+
dropTargetForConsumers: i,
|
|
1473
|
+
getIsOver: T,
|
|
1474
|
+
dispatchEvent: y
|
|
1475
|
+
};
|
|
1476
|
+
}
|
|
1477
|
+
function xr(t, e) {
|
|
1478
|
+
var r = typeof Symbol < "u" && t[Symbol.iterator] || t["@@iterator"];
|
|
1479
|
+
if (!r) {
|
|
1480
|
+
if (Array.isArray(t) || (r = Pr(t)) || e) {
|
|
1481
|
+
r && (t = r);
|
|
1482
|
+
var n = 0, a = function() {
|
|
1483
|
+
};
|
|
1484
|
+
return { s: a, n: function() {
|
|
1485
|
+
return n >= t.length ? { done: !0 } : { done: !1, value: t[n++] };
|
|
1486
|
+
}, e: function(l) {
|
|
1487
|
+
throw l;
|
|
1488
|
+
}, f: a };
|
|
1489
|
+
}
|
|
1490
|
+
throw new TypeError(`Invalid attempt to iterate non-iterable instance.
|
|
1491
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
1492
|
+
}
|
|
1493
|
+
var o, d = !0, i = !1;
|
|
1494
|
+
return { s: function() {
|
|
1495
|
+
r = r.call(t);
|
|
1496
|
+
}, n: function() {
|
|
1497
|
+
var l = r.next();
|
|
1498
|
+
return d = l.done, l;
|
|
1499
|
+
}, e: function(l) {
|
|
1500
|
+
i = !0, o = l;
|
|
1501
|
+
}, f: function() {
|
|
1502
|
+
try {
|
|
1503
|
+
d || r.return == null || r.return();
|
|
1504
|
+
} finally {
|
|
1505
|
+
if (i) throw o;
|
|
1506
|
+
}
|
|
1507
|
+
} };
|
|
1508
|
+
}
|
|
1509
|
+
function Pr(t, e) {
|
|
1510
|
+
if (t) {
|
|
1511
|
+
if (typeof t == "string") return zt(t, e);
|
|
1512
|
+
var r = {}.toString.call(t).slice(8, -1);
|
|
1513
|
+
return r === "Object" && t.constructor && (r = t.constructor.name), r === "Map" || r === "Set" ? Array.from(t) : r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r) ? zt(t, e) : void 0;
|
|
1514
|
+
}
|
|
1515
|
+
}
|
|
1516
|
+
function zt(t, e) {
|
|
1517
|
+
(e == null || e > t.length) && (e = t.length);
|
|
1518
|
+
for (var r = 0, n = Array(e); r < e; r++) n[r] = t[r];
|
|
1519
|
+
return n;
|
|
1520
|
+
}
|
|
1521
|
+
function qt(t, e) {
|
|
1522
|
+
var r = Object.keys(t);
|
|
1523
|
+
if (Object.getOwnPropertySymbols) {
|
|
1524
|
+
var n = Object.getOwnPropertySymbols(t);
|
|
1525
|
+
e && (n = n.filter(function(a) {
|
|
1526
|
+
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
1527
|
+
})), r.push.apply(r, n);
|
|
1528
|
+
}
|
|
1529
|
+
return r;
|
|
1530
|
+
}
|
|
1531
|
+
function Ar(t) {
|
|
1532
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
1533
|
+
var r = arguments[e] != null ? arguments[e] : {};
|
|
1534
|
+
e % 2 ? qt(Object(r), !0).forEach(function(n) {
|
|
1535
|
+
ut(t, n, r[n]);
|
|
1536
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : qt(Object(r)).forEach(function(n) {
|
|
1537
|
+
Object.defineProperty(t, n, Object.getOwnPropertyDescriptor(r, n));
|
|
1538
|
+
});
|
|
1539
|
+
}
|
|
1540
|
+
return t;
|
|
1541
|
+
}
|
|
1542
|
+
function Ir() {
|
|
1543
|
+
var t = /* @__PURE__ */ new Set(), e = null;
|
|
1544
|
+
function r(o) {
|
|
1545
|
+
e && (!o.canMonitor || o.canMonitor(e.canMonitorArgs)) && e.active.add(o);
|
|
1546
|
+
}
|
|
1547
|
+
function n(o) {
|
|
1548
|
+
var d = Ar({}, o);
|
|
1549
|
+
t.add(d), r(d);
|
|
1550
|
+
function i() {
|
|
1551
|
+
t.delete(d), e && e.active.delete(d);
|
|
1552
|
+
}
|
|
1553
|
+
return z(i);
|
|
1554
|
+
}
|
|
1555
|
+
function a(o) {
|
|
1556
|
+
var d = o.eventName, i = o.payload;
|
|
1557
|
+
if (d === "onGenerateDragPreview") {
|
|
1558
|
+
e = {
|
|
1559
|
+
canMonitorArgs: {
|
|
1560
|
+
initial: i.location.initial,
|
|
1561
|
+
source: i.source
|
|
1562
|
+
},
|
|
1563
|
+
active: /* @__PURE__ */ new Set()
|
|
1564
|
+
};
|
|
1565
|
+
var s = xr(t), l;
|
|
1566
|
+
try {
|
|
1567
|
+
for (s.s(); !(l = s.n()).done; ) {
|
|
1568
|
+
var c = l.value;
|
|
1569
|
+
r(c);
|
|
1570
|
+
}
|
|
1571
|
+
} catch (h) {
|
|
1572
|
+
s.e(h);
|
|
1573
|
+
} finally {
|
|
1574
|
+
s.f();
|
|
1575
|
+
}
|
|
1576
|
+
}
|
|
1577
|
+
if (e) {
|
|
1578
|
+
for (var y = Array.from(e.active), T = 0, v = y; T < v.length; T++) {
|
|
1579
|
+
var f = v[T];
|
|
1580
|
+
if (e.active.has(f)) {
|
|
1581
|
+
var p;
|
|
1582
|
+
(p = f[d]) === null || p === void 0 || p.call(f, i);
|
|
1583
|
+
}
|
|
1584
|
+
}
|
|
1585
|
+
d === "onDrop" && (e.active.clear(), e = null);
|
|
1586
|
+
}
|
|
1587
|
+
}
|
|
1588
|
+
return {
|
|
1589
|
+
dispatchEvent: a,
|
|
1590
|
+
monitorForConsumers: n
|
|
1591
|
+
};
|
|
1592
|
+
}
|
|
1593
|
+
function $r(t) {
|
|
1594
|
+
var e = t.typeKey, r = t.mount, n = t.dispatchEventToSource, a = t.onPostDispatch, o = t.defaultDropEffect, d = Ir(), i = kr({
|
|
1595
|
+
typeKey: e,
|
|
1596
|
+
defaultDropEffect: o
|
|
1597
|
+
});
|
|
1598
|
+
function s(y) {
|
|
1599
|
+
n == null || n(y), i.dispatchEvent(y), d.dispatchEvent(y), a == null || a(y);
|
|
1600
|
+
}
|
|
1601
|
+
function l(y) {
|
|
1602
|
+
var T = y.event, v = y.dragType;
|
|
1603
|
+
Wt.start({
|
|
1604
|
+
event: T,
|
|
1605
|
+
dragType: v,
|
|
1606
|
+
getDropTargetsOver: i.getIsOver,
|
|
1607
|
+
dispatchEvent: s
|
|
1608
|
+
});
|
|
1609
|
+
}
|
|
1610
|
+
function c() {
|
|
1611
|
+
function y() {
|
|
1612
|
+
var T = {
|
|
1613
|
+
canStart: Wt.canStart,
|
|
1614
|
+
start: l
|
|
1615
|
+
};
|
|
1616
|
+
return r(T);
|
|
1617
|
+
}
|
|
1618
|
+
return Mr({
|
|
1619
|
+
typeKey: e,
|
|
1620
|
+
mount: y
|
|
1621
|
+
});
|
|
1622
|
+
}
|
|
1623
|
+
return {
|
|
1624
|
+
registerUsage: c,
|
|
1625
|
+
dropTarget: i.dropTargetForConsumers,
|
|
1626
|
+
monitor: d.monitorForConsumers
|
|
1627
|
+
};
|
|
1628
|
+
}
|
|
1629
|
+
var jr = z(function() {
|
|
1630
|
+
return navigator.userAgent.toLocaleLowerCase().includes("android");
|
|
1631
|
+
}), Fr = "pdnd:android-fallback", Xt = "text/plain", Rr = "text/uri-list", Hr = "application/vnd.pdnd", et = /* @__PURE__ */ new WeakMap();
|
|
1632
|
+
function Lr(t) {
|
|
1633
|
+
return et.set(t.element, t), function() {
|
|
1634
|
+
et.delete(t.element);
|
|
1635
|
+
};
|
|
1636
|
+
}
|
|
1637
|
+
var _t = lr(), Mt = $r({
|
|
1638
|
+
typeKey: "element",
|
|
1639
|
+
defaultDropEffect: "move",
|
|
1640
|
+
mount: function(e) {
|
|
1641
|
+
return Et(_t.bindEvents(), _.bind(document, {
|
|
1642
|
+
type: "dragstart",
|
|
1643
|
+
listener: function(n) {
|
|
1644
|
+
var a, o, d, i, s, l;
|
|
1645
|
+
if (e.canStart(n) && !n.defaultPrevented) {
|
|
1646
|
+
if (!n.dataTransfer) {
|
|
1647
|
+
process.env.NODE_ENV !== "production" && console.warn(`
|
|
1648
|
+
It appears as though you have are not testing DragEvents correctly.
|
|
1649
|
+
|
|
1650
|
+
- If you are unit testing, ensure you have polyfilled DragEvent.
|
|
1651
|
+
- If you are browser testing, ensure you are dispatching drag events correctly.
|
|
1652
|
+
|
|
1653
|
+
Please see our testing guides for more information:
|
|
1654
|
+
https://atlassian.design/components/pragmatic-drag-and-drop/core-package/testing
|
|
1655
|
+
`.replace(/ {2}/g, ""));
|
|
1656
|
+
return;
|
|
1657
|
+
}
|
|
1658
|
+
var c = n.target;
|
|
1659
|
+
if (c instanceof HTMLElement) {
|
|
1660
|
+
var y = et.get(c);
|
|
1661
|
+
if (y) {
|
|
1662
|
+
var T = J(n), v = {
|
|
1663
|
+
element: y.element,
|
|
1664
|
+
dragHandle: (a = y.dragHandle) !== null && a !== void 0 ? a : null,
|
|
1665
|
+
input: T
|
|
1666
|
+
};
|
|
1667
|
+
if (y.canDrag && !y.canDrag(v)) {
|
|
1668
|
+
n.preventDefault();
|
|
1669
|
+
return;
|
|
1670
|
+
}
|
|
1671
|
+
if (y.dragHandle) {
|
|
1672
|
+
var f = de({
|
|
1673
|
+
x: T.clientX,
|
|
1674
|
+
y: T.clientY
|
|
1675
|
+
});
|
|
1676
|
+
if (!y.dragHandle.contains(f)) {
|
|
1677
|
+
n.preventDefault();
|
|
1678
|
+
return;
|
|
1679
|
+
}
|
|
1680
|
+
}
|
|
1681
|
+
var p = (o = (d = y.getInitialDataForExternal) === null || d === void 0 ? void 0 : d.call(y, v)) !== null && o !== void 0 ? o : null;
|
|
1682
|
+
if (p)
|
|
1683
|
+
for (var h = 0, w = Object.entries(p); h < w.length; h++) {
|
|
1684
|
+
var D = ae(w[h], 2), M = D[0], k = D[1];
|
|
1685
|
+
n.dataTransfer.setData(M, k ?? "");
|
|
1686
|
+
}
|
|
1687
|
+
jr() && !n.dataTransfer.types.includes(Xt) && !n.dataTransfer.types.includes(Rr) && n.dataTransfer.setData(Xt, Fr), n.dataTransfer.setData(Hr, "");
|
|
1688
|
+
var m = {
|
|
1689
|
+
element: y.element,
|
|
1690
|
+
dragHandle: (i = y.dragHandle) !== null && i !== void 0 ? i : null,
|
|
1691
|
+
data: (s = (l = y.getInitialData) === null || l === void 0 ? void 0 : l.call(y, v)) !== null && s !== void 0 ? s : {}
|
|
1692
|
+
}, x = {
|
|
1693
|
+
type: "element",
|
|
1694
|
+
payload: m,
|
|
1695
|
+
startedFrom: "internal"
|
|
1696
|
+
};
|
|
1697
|
+
e.start({
|
|
1698
|
+
event: n,
|
|
1699
|
+
dragType: x
|
|
1700
|
+
});
|
|
1701
|
+
}
|
|
1702
|
+
}
|
|
1703
|
+
}
|
|
1704
|
+
}
|
|
1705
|
+
}));
|
|
1706
|
+
},
|
|
1707
|
+
dispatchEventToSource: function(e) {
|
|
1708
|
+
var r, n, a = e.eventName, o = e.payload;
|
|
1709
|
+
(r = et.get(o.source.element)) === null || r === void 0 || (n = r[a]) === null || n === void 0 || n.call(
|
|
1710
|
+
r,
|
|
1711
|
+
// I cannot seem to get the types right here.
|
|
1712
|
+
// TS doesn't seem to like that one event can need `nativeSetDragImage`
|
|
1713
|
+
// @ts-expect-error
|
|
1714
|
+
o
|
|
1715
|
+
);
|
|
1716
|
+
},
|
|
1717
|
+
onPostDispatch: _t.getOnPostDispatch()
|
|
1718
|
+
}), ge = Mt.dropTarget, Ct = Mt.monitor;
|
|
1719
|
+
function Nr(t) {
|
|
1720
|
+
if (process.env.NODE_ENV !== "production" && t.dragHandle && !t.element.contains(t.dragHandle) && console.warn("Drag handle element must be contained in draggable element", {
|
|
1721
|
+
element: t.element,
|
|
1722
|
+
dragHandle: t.dragHandle
|
|
1723
|
+
}), process.env.NODE_ENV !== "production") {
|
|
1724
|
+
var e = et.get(t.element);
|
|
1725
|
+
e && console.warn("You have already registered a `draggable` on the same element", {
|
|
1726
|
+
existing: e,
|
|
1727
|
+
proposed: t
|
|
1728
|
+
});
|
|
1729
|
+
}
|
|
1730
|
+
var r = Et(
|
|
1731
|
+
// making the draggable register the adapter rather than drop targets
|
|
1732
|
+
// this is because you *must* have a draggable element to start a drag
|
|
1733
|
+
// but you _might_ not have any drop targets immediately
|
|
1734
|
+
// (You might create drop targets async)
|
|
1735
|
+
Mt.registerUsage(),
|
|
1736
|
+
Lr(t),
|
|
1737
|
+
fe(t.element, {
|
|
1738
|
+
attribute: "draggable",
|
|
1739
|
+
value: "true"
|
|
1740
|
+
})
|
|
1741
|
+
);
|
|
1742
|
+
return z(r);
|
|
1743
|
+
}
|
|
1744
|
+
function Zt(t, e) {
|
|
1745
|
+
var r = Object.keys(t);
|
|
1746
|
+
if (Object.getOwnPropertySymbols) {
|
|
1747
|
+
var n = Object.getOwnPropertySymbols(t);
|
|
1748
|
+
e && (n = n.filter(function(a) {
|
|
1749
|
+
return Object.getOwnPropertyDescriptor(t, a).enumerable;
|
|
1750
|
+
})), r.push.apply(r, n);
|
|
1751
|
+
}
|
|
1752
|
+
return r;
|
|
1753
|
+
}
|
|
1754
|
+
function Jt(t) {
|
|
1755
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
1756
|
+
var r = arguments[e] != null ? arguments[e] : {};
|
|
1757
|
+
e % 2 ? Zt(Object(r), !0).forEach(function(n) {
|
|
1758
|
+
ut(t, n, r[n]);
|
|
1759
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(r)) : Zt(Object(r)).forEach(function(n) {
|
|
1760
|
+
Object.defineProperty(t, n, Object.getOwnPropertyDescriptor(r, n));
|
|
1761
|
+
});
|
|
1762
|
+
}
|
|
1763
|
+
return t;
|
|
1764
|
+
}
|
|
1765
|
+
function Br() {
|
|
1766
|
+
return {
|
|
1767
|
+
x: 0,
|
|
1768
|
+
y: 0
|
|
1769
|
+
};
|
|
1770
|
+
}
|
|
1771
|
+
function Kr(t) {
|
|
1772
|
+
var e = t.render, r = t.nativeSetDragImage, n = t.getOffset, a = n === void 0 ? Br : n, o = document.createElement("div");
|
|
1773
|
+
q() && o.setAttribute("popover", "manual"), Object.assign(o.style, Jt(Jt({
|
|
1774
|
+
// Ensuring we don't cause reflow when adding the element to the page
|
|
1775
|
+
// Using `position:fixed` rather than `position:absolute` so we are
|
|
1776
|
+
// positioned on the current viewport.
|
|
1777
|
+
// `position:fixed` also creates a new stacking context, so we don't need to do that here
|
|
1778
|
+
position: "fixed"
|
|
1779
|
+
}, q() ? (
|
|
1780
|
+
// needs to come first as it has 'inset: unset' which
|
|
1781
|
+
// needs to be overridden by our top / left values
|
|
1782
|
+
ce
|
|
1783
|
+
) : {
|
|
1784
|
+
// Fallback: using maximum possible z-index so that this element
|
|
1785
|
+
// will always be on top of other positioned content.
|
|
1786
|
+
zIndex: le
|
|
1787
|
+
}), {}, {
|
|
1788
|
+
// According to `mdn`, the element can be offscreen:
|
|
1789
|
+
// https://developer.mozilla.org/en-US/docs/Web/API/DataTransfer/setDragImage#imgelement
|
|
1790
|
+
//
|
|
1791
|
+
// However, that information does not appear in the specs:
|
|
1792
|
+
// https://html.spec.whatwg.org/multipage/dnd.html#dom-datatransfer-setdragimage-dev
|
|
1793
|
+
//
|
|
1794
|
+
// If the element is _completely_ offscreen, Safari@17.1 will cancel the drag
|
|
1795
|
+
top: 0,
|
|
1796
|
+
left: 0,
|
|
1797
|
+
// Avoiding any additional events caused by the new element (being super safe)
|
|
1798
|
+
pointerEvents: "none"
|
|
1799
|
+
})), document.body.append(o), q() && o.showPopover();
|
|
1800
|
+
var d = e({
|
|
1801
|
+
container: o
|
|
1802
|
+
});
|
|
1803
|
+
queueMicrotask(function() {
|
|
1804
|
+
var l = a({
|
|
1805
|
+
container: o
|
|
1806
|
+
});
|
|
1807
|
+
if (vt()) {
|
|
1808
|
+
var c = o.getBoundingClientRect();
|
|
1809
|
+
if (c.width === 0)
|
|
1810
|
+
return;
|
|
1811
|
+
o.style.left = "-".concat(c.width - 1e-4, "px");
|
|
1812
|
+
}
|
|
1813
|
+
r == null || r(o, l.x, l.y);
|
|
1814
|
+
});
|
|
1815
|
+
function i() {
|
|
1816
|
+
s(), d == null || d(), document.body.removeChild(o);
|
|
1817
|
+
}
|
|
1818
|
+
var s = Ct({
|
|
1819
|
+
// Remove portal in the dragstart event so that the user will never see it
|
|
1820
|
+
onDragStart: i,
|
|
1821
|
+
// Backup: remove portal when the drop finishes (this would be an error case)
|
|
1822
|
+
onDrop: i
|
|
1823
|
+
});
|
|
1824
|
+
}
|
|
1825
|
+
function Yr(t) {
|
|
1826
|
+
var e = t.element, r = t.input;
|
|
1827
|
+
return function(a) {
|
|
1828
|
+
var o = a.container, d = e.getBoundingClientRect(), i = o.getBoundingClientRect(), s = Math.min(
|
|
1829
|
+
// difference
|
|
1830
|
+
r.clientX - d.x,
|
|
1831
|
+
// don't let the difference be more than the width of the container,
|
|
1832
|
+
// otherwise the pointer will be off the preview
|
|
1833
|
+
i.width
|
|
1834
|
+
), l = Math.min(
|
|
1835
|
+
// difference
|
|
1836
|
+
r.clientY - d.y,
|
|
1837
|
+
// don't let the difference be more than the height of the container,
|
|
1838
|
+
// otherwise the pointer will be off the preview
|
|
1839
|
+
i.height
|
|
1840
|
+
);
|
|
1841
|
+
return {
|
|
1842
|
+
x: s,
|
|
1843
|
+
y: l
|
|
1844
|
+
};
|
|
1845
|
+
};
|
|
1846
|
+
}
|
|
1847
|
+
let me = 0;
|
|
1848
|
+
function lt() {
|
|
1849
|
+
me = Date.now();
|
|
1850
|
+
}
|
|
1851
|
+
function ye(t = 300) {
|
|
1852
|
+
return Date.now() - me < t;
|
|
1853
|
+
}
|
|
1854
|
+
const kt = "rsv-timegrid-event", pe = "rsv-timegrid-col";
|
|
1855
|
+
function he(t, e, r) {
|
|
1856
|
+
return r ? Nr({
|
|
1857
|
+
element: t,
|
|
1858
|
+
getInitialData: () => ({ [kt]: !0, id: e.id }),
|
|
1859
|
+
onGenerateDragPreview({ location: n, nativeSetDragImage: a }) {
|
|
1860
|
+
Kr({
|
|
1861
|
+
nativeSetDragImage: a,
|
|
1862
|
+
getOffset: Yr({ element: t, input: n.current.input }),
|
|
1863
|
+
render({ container: o }) {
|
|
1864
|
+
const d = t.cloneNode(!0);
|
|
1865
|
+
d.setAttribute("data-rsv-drag-preview", "true"), d.style.width = `${t.offsetWidth}px`, d.style.height = `${t.offsetHeight}px`, o.appendChild(d);
|
|
1866
|
+
}
|
|
1867
|
+
});
|
|
1868
|
+
}
|
|
1869
|
+
}) : () => {
|
|
1870
|
+
};
|
|
1871
|
+
}
|
|
1872
|
+
function Vr(t) {
|
|
1873
|
+
return ge({
|
|
1874
|
+
element: t,
|
|
1875
|
+
canDrop: ({ source: e }) => e.data[kt] === !0,
|
|
1876
|
+
getData: ({ element: e }) => ({
|
|
1877
|
+
[pe]: !0,
|
|
1878
|
+
dayIndex: Number(e.dataset.rsvDayIndex ?? 0)
|
|
1879
|
+
})
|
|
1880
|
+
});
|
|
1881
|
+
}
|
|
1882
|
+
function Wr(t, e, r, n) {
|
|
1883
|
+
const a = t.getBoundingClientRect(), o = r.maxMinutes - r.minMinutes;
|
|
1884
|
+
if (a.height === 0 || o <= 0) return r.minMinutes;
|
|
1885
|
+
const d = r.minMinutes + (e - a.top) / a.height * o, i = Math.max(r.minMinutes, Math.min(r.maxMinutes, d));
|
|
1886
|
+
return Math.round(i / n) * n;
|
|
1887
|
+
}
|
|
1888
|
+
function Ot(t, e) {
|
|
1889
|
+
return g.diff(t, e, "minute");
|
|
1890
|
+
}
|
|
1891
|
+
function Gr(t, e, r) {
|
|
1892
|
+
const n = g.add(g.startOf(t, "day"), { minutes: e });
|
|
1893
|
+
if (Ot(n, r.start) === 0) return null;
|
|
1894
|
+
const a = r.end ? Ot(r.start, r.end) : 0;
|
|
1895
|
+
return {
|
|
1896
|
+
start: n,
|
|
1897
|
+
end: r.end ? g.add(n, { minutes: a }) : null
|
|
1898
|
+
};
|
|
1899
|
+
}
|
|
1900
|
+
function Ur({
|
|
1901
|
+
api: t,
|
|
1902
|
+
getModel: e,
|
|
1903
|
+
snap: r,
|
|
1904
|
+
onPreview: n,
|
|
1905
|
+
onDragging: a
|
|
1906
|
+
}) {
|
|
1907
|
+
const o = X(r ?? "00:15") || 15, d = (i) => {
|
|
1908
|
+
const s = i.current.dropTargets.find((c) => c.data[pe] === !0);
|
|
1909
|
+
if (!s) return null;
|
|
1910
|
+
const l = Wr(
|
|
1911
|
+
s.element,
|
|
1912
|
+
i.current.input.clientY,
|
|
1913
|
+
e(),
|
|
1914
|
+
o
|
|
1915
|
+
);
|
|
1916
|
+
return { target: s, inicio: l };
|
|
1917
|
+
};
|
|
1918
|
+
return Ct({
|
|
1919
|
+
canMonitor: ({ source: i }) => i.data[kt] === !0,
|
|
1920
|
+
onDragStart: ({ source: i }) => {
|
|
1921
|
+
lt(), a(String(i.data.id));
|
|
1922
|
+
},
|
|
1923
|
+
onDrag: ({ source: i, location: s }) => {
|
|
1924
|
+
const l = d(s);
|
|
1925
|
+
if (!l) return;
|
|
1926
|
+
const c = t.getEventById(String(i.data.id));
|
|
1927
|
+
if (!c) return;
|
|
1928
|
+
const y = c.end ? Math.max(o, Ot(c.start, c.end)) : o;
|
|
1929
|
+
n({
|
|
1930
|
+
dayIndex: Number(l.target.data.dayIndex),
|
|
1931
|
+
startMin: l.inicio,
|
|
1932
|
+
endMin: l.inicio + y
|
|
1933
|
+
});
|
|
1934
|
+
},
|
|
1935
|
+
onDrop: ({ source: i, location: s }) => {
|
|
1936
|
+
var v;
|
|
1937
|
+
lt(), n(null), a(null);
|
|
1938
|
+
const l = d(s);
|
|
1939
|
+
if (!l) return;
|
|
1940
|
+
const c = t.getEventById(String(i.data.id));
|
|
1941
|
+
if (!c) return;
|
|
1942
|
+
const y = (v = e().days[Number(l.target.data.dayIndex)]) == null ? void 0 : v.date;
|
|
1943
|
+
if (!y) return;
|
|
1944
|
+
const T = Gr(y, l.inicio, c);
|
|
1945
|
+
if (T && t.moveEvent(c.id, T.start, T.end)) {
|
|
1946
|
+
const f = t.getEventById(c.id);
|
|
1947
|
+
f && t.trigger("eventDrop", { event: f });
|
|
1948
|
+
}
|
|
1949
|
+
}
|
|
1950
|
+
});
|
|
1951
|
+
}
|
|
1952
|
+
const be = "rsv-timegrid-event", we = "rsv-daygrid-day";
|
|
1953
|
+
function zr(t, e) {
|
|
1954
|
+
const r = g.diff(g.startOf(e.start, "day"), g.startOf(t, "day"), "day");
|
|
1955
|
+
return r === 0 ? null : {
|
|
1956
|
+
start: g.add(e.start, { days: r }),
|
|
1957
|
+
end: e.end ? g.add(e.end, { days: r }) : null
|
|
1958
|
+
};
|
|
1959
|
+
}
|
|
1960
|
+
function qr(t) {
|
|
1961
|
+
return ge({
|
|
1962
|
+
element: t,
|
|
1963
|
+
canDrop: ({ source: e }) => e.data[be] === !0,
|
|
1964
|
+
// Sin capturas: la fecha se lee del DOM al soltar, porque Preact reutiliza
|
|
1965
|
+
// la celda al navegar de mes.
|
|
1966
|
+
getData: ({ element: e }) => ({
|
|
1967
|
+
[we]: !0,
|
|
1968
|
+
fechaISO: e.dataset.date ?? ""
|
|
1969
|
+
})
|
|
1970
|
+
});
|
|
1971
|
+
}
|
|
1972
|
+
function Xr({
|
|
1973
|
+
api: t,
|
|
1974
|
+
onPreview: e,
|
|
1975
|
+
onDragging: r
|
|
1976
|
+
}) {
|
|
1977
|
+
const n = (a) => a.current.dropTargets.find((o) => o.data[we] === !0) ?? null;
|
|
1978
|
+
return Ct({
|
|
1979
|
+
canMonitor: ({ source: a }) => a.data[be] === !0,
|
|
1980
|
+
onDragStart: ({ source: a }) => {
|
|
1981
|
+
lt(), r(String(a.data.id));
|
|
1982
|
+
},
|
|
1983
|
+
onDrag: ({ location: a }) => {
|
|
1984
|
+
const o = n(a);
|
|
1985
|
+
e(o ? String(o.data.fechaISO) : null);
|
|
1986
|
+
},
|
|
1987
|
+
onDrop: ({ source: a, location: o }) => {
|
|
1988
|
+
lt(), e(null), r(null);
|
|
1989
|
+
const d = n(o);
|
|
1990
|
+
if (!d) return;
|
|
1991
|
+
const i = t.getEventById(String(a.data.id));
|
|
1992
|
+
if (!i) return;
|
|
1993
|
+
const s = zr(g.from(String(d.data.fechaISO)), i);
|
|
1994
|
+
if (s && t.moveEvent(i.id, s.start, s.end)) {
|
|
1995
|
+
const l = t.getEventById(i.id);
|
|
1996
|
+
l && t.trigger("eventDrop", { event: l });
|
|
1997
|
+
}
|
|
1998
|
+
}
|
|
1999
|
+
});
|
|
2000
|
+
}
|
|
2001
|
+
function De({ api: t, model: e, options: r }) {
|
|
2002
|
+
var v;
|
|
2003
|
+
const n = r.locale ?? "en", a = { type: t.getView().type }, o = dt(n, r.dayHeaderFormat, { weekday: "short" }), d = ((v = e.weeks[0]) == null ? void 0 : v.days) ?? [], i = r.weekNumbers === !0, [s, l] = V(null), [c, y] = V(null), T = F(/* @__PURE__ */ new Map());
|
|
2004
|
+
return H(
|
|
2005
|
+
() => Xr({ api: t, onPreview: l, onDragging: y }),
|
|
2006
|
+
[t]
|
|
2007
|
+
), H(() => {
|
|
2008
|
+
const f = T.current;
|
|
2009
|
+
return () => {
|
|
2010
|
+
for (const p of f.values()) p();
|
|
2011
|
+
f.clear();
|
|
2012
|
+
};
|
|
2013
|
+
}, []), /* @__PURE__ */ C(
|
|
318
2014
|
"div",
|
|
319
2015
|
{
|
|
320
2016
|
"data-rsv": "daygrid",
|
|
321
|
-
"data-weeknumbers": String(
|
|
322
|
-
style: `--rsv-cols:${
|
|
2017
|
+
"data-weeknumbers": String(i),
|
|
2018
|
+
style: `--rsv-cols:${e.columnCount}`,
|
|
323
2019
|
children: [
|
|
324
|
-
/* @__PURE__ */
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
var
|
|
328
|
-
const
|
|
329
|
-
|
|
2020
|
+
/* @__PURE__ */ C("div", { "data-rsv": "daygrid-header", role: "row", children: [
|
|
2021
|
+
i && /* @__PURE__ */ u("div", { "data-rsv": "daygrid-weeknum-header", role: "columnheader" }),
|
|
2022
|
+
d.map((f) => {
|
|
2023
|
+
var D, M;
|
|
2024
|
+
const p = g.toDate(f.date), h = o ? o(p) : "", w = {
|
|
2025
|
+
date: p,
|
|
2026
|
+
text: h,
|
|
2027
|
+
dayOfWeek: f.dayOfWeek,
|
|
2028
|
+
dayNumber: g.dayOfMonth(f.date),
|
|
2029
|
+
isToday: f.isToday,
|
|
2030
|
+
view: a
|
|
2031
|
+
};
|
|
2032
|
+
return /* @__PURE__ */ u(
|
|
2033
|
+
"div",
|
|
2034
|
+
{
|
|
2035
|
+
"data-rsv": "daygrid-dow",
|
|
2036
|
+
role: "columnheader",
|
|
2037
|
+
"data-dow": String(f.dayOfWeek),
|
|
2038
|
+
class: K((D = r.classNames) == null ? void 0 : D.dayHeader),
|
|
2039
|
+
ref: (k) => {
|
|
2040
|
+
var m;
|
|
2041
|
+
return U(k, (m = r.hooks) == null ? void 0 : m.dayHeaderDidMount, () => w);
|
|
2042
|
+
},
|
|
2043
|
+
children: B((M = r.slots) == null ? void 0 : M.dayHeaderContent, w, h, r.hostBridge)
|
|
2044
|
+
},
|
|
2045
|
+
f.dayOfWeek
|
|
2046
|
+
);
|
|
330
2047
|
})
|
|
331
2048
|
] }),
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
2049
|
+
e.weeks.map((f, p) => /* @__PURE__ */ C("div", { "data-rsv": "daygrid-week", role: "row", children: [
|
|
2050
|
+
i && /* @__PURE__ */ u("div", { "data-rsv": "daygrid-weeknum", role: "rowheader", children: f.weekNumber }),
|
|
2051
|
+
f.days.map((h) => /* @__PURE__ */ u(
|
|
2052
|
+
_r,
|
|
2053
|
+
{
|
|
2054
|
+
api: t,
|
|
2055
|
+
cell: h,
|
|
2056
|
+
options: r,
|
|
2057
|
+
view: a,
|
|
2058
|
+
dropActivo: s === g.toISOString(h.date),
|
|
2059
|
+
limpiezaDias: T,
|
|
2060
|
+
idArrastrado: c
|
|
2061
|
+
},
|
|
2062
|
+
g.toISOString(h.date)
|
|
2063
|
+
))
|
|
2064
|
+
] }, p))
|
|
336
2065
|
]
|
|
337
2066
|
}
|
|
338
2067
|
);
|
|
339
2068
|
}
|
|
340
|
-
function
|
|
341
|
-
api:
|
|
342
|
-
cell:
|
|
343
|
-
options: r
|
|
2069
|
+
function _r({
|
|
2070
|
+
api: t,
|
|
2071
|
+
cell: e,
|
|
2072
|
+
options: r,
|
|
2073
|
+
view: n,
|
|
2074
|
+
dropActivo: a,
|
|
2075
|
+
limpiezaDias: o,
|
|
2076
|
+
idArrastrado: d
|
|
344
2077
|
}) {
|
|
345
|
-
var
|
|
346
|
-
const
|
|
2078
|
+
var D, M, k;
|
|
2079
|
+
const i = g.toDate(e.date), s = g.dayOfMonth(e.date), l = r.navLinks ? /* @__PURE__ */ u(
|
|
347
2080
|
"a",
|
|
348
2081
|
{
|
|
349
2082
|
"data-rsv": "day-number",
|
|
350
2083
|
"data-nav-link": "true",
|
|
351
2084
|
role: "link",
|
|
352
2085
|
tabIndex: 0,
|
|
353
|
-
|
|
354
|
-
|
|
2086
|
+
title: W(r.locale).navLinkHint(
|
|
2087
|
+
new Intl.DateTimeFormat(r.locale, { dateStyle: "long" }).format(i)
|
|
2088
|
+
),
|
|
2089
|
+
onClick: (m) => {
|
|
2090
|
+
m.stopPropagation(), ee(t, e.date);
|
|
355
2091
|
},
|
|
356
|
-
children:
|
|
357
|
-
}
|
|
358
|
-
) : /* @__PURE__ */
|
|
359
|
-
(
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
2092
|
+
children: s
|
|
2093
|
+
}
|
|
2094
|
+
) : /* @__PURE__ */ u("span", { "data-rsv": "day-number", children: s }), c = { date: i, dayNumber: s, isToday: e.isToday, isOther: e.isOther, view: n }, y = B(
|
|
2095
|
+
(D = r.slots) == null ? void 0 : D.dayCellContent,
|
|
2096
|
+
c,
|
|
2097
|
+
l,
|
|
2098
|
+
r.hostBridge
|
|
2099
|
+
), [T, v] = V(!1), f = g.toISOString(e.date), p = F(!1), h = () => {
|
|
2100
|
+
if (p.current) {
|
|
2101
|
+
p.current = !1;
|
|
365
2102
|
return;
|
|
366
2103
|
}
|
|
367
|
-
|
|
368
|
-
},
|
|
369
|
-
|
|
370
|
-
date:
|
|
371
|
-
allEvents: [...
|
|
372
|
-
hiddenEvents:
|
|
2104
|
+
r.selectConstraint === "businessHours" && !e.isBusiness || (t.trigger("dateClick", { date: e.date }), r.selectable && t.select(f, g.toISOString(g.add(e.date, { days: 1 }))));
|
|
2105
|
+
}, w = (m) => {
|
|
2106
|
+
m.stopPropagation(), v(!0), t.trigger("moreLinkClick", {
|
|
2107
|
+
date: e.date,
|
|
2108
|
+
allEvents: [...e.events, ...e.hiddenEvents],
|
|
2109
|
+
hiddenEvents: e.hiddenEvents
|
|
373
2110
|
});
|
|
374
2111
|
};
|
|
375
|
-
return /* @__PURE__ */
|
|
2112
|
+
return /* @__PURE__ */ C(
|
|
376
2113
|
"div",
|
|
377
2114
|
{
|
|
378
2115
|
"data-rsv": "day",
|
|
379
2116
|
role: "gridcell",
|
|
380
|
-
"data-date":
|
|
381
|
-
"data-
|
|
382
|
-
"data-
|
|
383
|
-
"data-
|
|
384
|
-
"data-
|
|
385
|
-
"data-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
2117
|
+
"data-date": f,
|
|
2118
|
+
"data-rsv-drop": a ? "true" : void 0,
|
|
2119
|
+
"data-today": String(e.isToday),
|
|
2120
|
+
"data-other": String(e.isOther),
|
|
2121
|
+
"data-weekend": String(e.isWeekend),
|
|
2122
|
+
"data-business": String(e.isBusiness),
|
|
2123
|
+
"data-selected": String(e.isSelected),
|
|
2124
|
+
class: K((M = r.classNames) == null ? void 0 : M.day),
|
|
2125
|
+
ref: (m) => {
|
|
2126
|
+
var x;
|
|
2127
|
+
U(m, (x = r.hooks) == null ? void 0 : x.dayCellDidMount, () => c), !(!m || o.current.has(m)) && o.current.set(m, qr(m));
|
|
2128
|
+
},
|
|
2129
|
+
onClick: h,
|
|
2130
|
+
onPointerDown: r.selectable ? (m) => Xe(m, {
|
|
2131
|
+
api: t,
|
|
2132
|
+
startDate: f,
|
|
390
2133
|
onRangeSelect: () => {
|
|
391
|
-
|
|
2134
|
+
p.current = !0;
|
|
392
2135
|
}
|
|
393
2136
|
}) : void 0,
|
|
394
2137
|
children: [
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
2138
|
+
y,
|
|
2139
|
+
e.events.filter((m) => m.display !== "none").map((m) => /* @__PURE__ */ u(
|
|
2140
|
+
Se,
|
|
398
2141
|
{
|
|
399
|
-
api:
|
|
400
|
-
event:
|
|
2142
|
+
api: t,
|
|
2143
|
+
event: m,
|
|
401
2144
|
options: r,
|
|
402
|
-
|
|
2145
|
+
view: n,
|
|
2146
|
+
arrastrandose: d === m.id
|
|
403
2147
|
},
|
|
404
|
-
|
|
2148
|
+
m.id
|
|
405
2149
|
)),
|
|
406
|
-
|
|
407
|
-
/* @__PURE__ */
|
|
408
|
-
|
|
409
|
-
|
|
2150
|
+
e.moreCount > 0 && /* @__PURE__ */ C("div", { "data-rsv": "more-anchor", children: [
|
|
2151
|
+
/* @__PURE__ */ u("button", { type: "button", "data-rsv": "more-link", onClick: w, children: B(
|
|
2152
|
+
(k = r.slots) == null ? void 0 : k.moreLinkContent,
|
|
2153
|
+
{
|
|
2154
|
+
date: i,
|
|
2155
|
+
moreCount: e.moreCount,
|
|
2156
|
+
allEvents: [...e.events, ...e.hiddenEvents],
|
|
2157
|
+
hiddenEvents: e.hiddenEvents,
|
|
2158
|
+
view: n
|
|
2159
|
+
},
|
|
2160
|
+
W(r.locale).more(e.moreCount),
|
|
2161
|
+
r.hostBridge
|
|
2162
|
+
) }),
|
|
2163
|
+
T && /* @__PURE__ */ u(
|
|
2164
|
+
Zr,
|
|
410
2165
|
{
|
|
411
|
-
api:
|
|
412
|
-
cell:
|
|
2166
|
+
api: t,
|
|
2167
|
+
cell: e,
|
|
413
2168
|
options: r,
|
|
414
|
-
|
|
2169
|
+
view: n,
|
|
2170
|
+
onClose: () => v(!1)
|
|
415
2171
|
}
|
|
416
2172
|
)
|
|
417
2173
|
] })
|
|
@@ -419,287 +2175,507 @@ function St({
|
|
|
419
2175
|
}
|
|
420
2176
|
);
|
|
421
2177
|
}
|
|
422
|
-
function
|
|
423
|
-
api:
|
|
424
|
-
cell:
|
|
2178
|
+
function Zr({
|
|
2179
|
+
api: t,
|
|
2180
|
+
cell: e,
|
|
425
2181
|
options: r,
|
|
426
|
-
|
|
2182
|
+
view: n,
|
|
2183
|
+
onClose: a
|
|
427
2184
|
}) {
|
|
428
|
-
const o = F(null),
|
|
2185
|
+
const o = F(null), d = new Intl.DateTimeFormat(r.locale ?? "en", {
|
|
429
2186
|
weekday: "long",
|
|
430
2187
|
day: "numeric",
|
|
431
2188
|
month: "long"
|
|
432
|
-
}),
|
|
433
|
-
return
|
|
434
|
-
const
|
|
435
|
-
o.current && !o.current.contains(c.target) &&
|
|
436
|
-
},
|
|
437
|
-
c.key === "Escape" &&
|
|
2189
|
+
}), i = [...e.events, ...e.hiddenEvents].filter((s) => s.display !== "none");
|
|
2190
|
+
return H(() => {
|
|
2191
|
+
const s = (c) => {
|
|
2192
|
+
o.current && !o.current.contains(c.target) && a();
|
|
2193
|
+
}, l = (c) => {
|
|
2194
|
+
c.key === "Escape" && a();
|
|
438
2195
|
};
|
|
439
|
-
return document.addEventListener("mousedown",
|
|
440
|
-
document.removeEventListener("mousedown",
|
|
2196
|
+
return document.addEventListener("mousedown", s), document.addEventListener("keydown", l), () => {
|
|
2197
|
+
document.removeEventListener("mousedown", s), document.removeEventListener("keydown", l);
|
|
441
2198
|
};
|
|
442
|
-
}, [
|
|
443
|
-
/* @__PURE__ */
|
|
444
|
-
/* @__PURE__ */
|
|
445
|
-
/* @__PURE__ */
|
|
2199
|
+
}, [a]), /* @__PURE__ */ C("div", { "data-rsv": "more-popover", role: "dialog", ref: o, onClick: (s) => s.stopPropagation(), children: [
|
|
2200
|
+
/* @__PURE__ */ C("div", { "data-rsv": "more-popover-header", children: [
|
|
2201
|
+
/* @__PURE__ */ u("span", { "data-rsv": "more-popover-title", children: d.format(g.toDate(e.date)) }),
|
|
2202
|
+
/* @__PURE__ */ u("button", { type: "button", "data-rsv": "more-popover-close", "aria-label": "✕", onClick: a, children: "✕" })
|
|
446
2203
|
] }),
|
|
447
|
-
/* @__PURE__ */
|
|
448
|
-
|
|
2204
|
+
/* @__PURE__ */ u("div", { "data-rsv": "more-popover-body", children: i.map((s) => /* @__PURE__ */ u(
|
|
2205
|
+
Se,
|
|
449
2206
|
{
|
|
450
|
-
api:
|
|
451
|
-
event:
|
|
2207
|
+
api: t,
|
|
2208
|
+
event: s,
|
|
452
2209
|
options: r,
|
|
453
|
-
|
|
2210
|
+
view: n,
|
|
2211
|
+
arrastrandose: !1
|
|
454
2212
|
},
|
|
455
|
-
|
|
2213
|
+
s.id
|
|
456
2214
|
)) })
|
|
457
2215
|
] });
|
|
458
2216
|
}
|
|
459
|
-
function
|
|
460
|
-
api:
|
|
461
|
-
event:
|
|
2217
|
+
function Se({
|
|
2218
|
+
api: t,
|
|
2219
|
+
event: e,
|
|
462
2220
|
options: r,
|
|
463
|
-
|
|
2221
|
+
view: n,
|
|
2222
|
+
arrastrandose: a
|
|
464
2223
|
}) {
|
|
465
|
-
var
|
|
466
|
-
const o = r.editable === !0 &&
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
2224
|
+
var p, h;
|
|
2225
|
+
const o = r.editable === !0 && e.editable !== !1, d = o && r.eventDraggable === !0, i = F(null), s = F(null);
|
|
2226
|
+
H(() => () => {
|
|
2227
|
+
var w;
|
|
2228
|
+
return (w = i.current) == null ? void 0 : w.call(i);
|
|
2229
|
+
}, []);
|
|
2230
|
+
const l = t.selectedEventIds.value.has(e.id), c = F(!1), y = ct(r.locale ?? "en", r.eventTimeFormat), T = e.allDay ? "" : y ? y(g.toDate(e.start)) : g.format(e.start, "HH:mm"), v = { event: e, isAllDay: e.allDay, timeText: T, view: n }, f = B(
|
|
2231
|
+
(p = r.slots) == null ? void 0 : p.eventContent,
|
|
2232
|
+
v,
|
|
2233
|
+
/* @__PURE__ */ C("span", { "data-rsv": "event-title", children: [
|
|
2234
|
+
T ? `${T} ` : "",
|
|
2235
|
+
e.title
|
|
2236
|
+
] }),
|
|
2237
|
+
r.hostBridge
|
|
473
2238
|
);
|
|
474
|
-
return /* @__PURE__ */
|
|
2239
|
+
return /* @__PURE__ */ u(
|
|
475
2240
|
"div",
|
|
476
2241
|
{
|
|
477
2242
|
"data-rsv": "event",
|
|
478
2243
|
role: "button",
|
|
479
2244
|
tabIndex: 0,
|
|
480
|
-
class:
|
|
481
|
-
"data-all-day": String(
|
|
482
|
-
"data-display":
|
|
483
|
-
"data-event-id":
|
|
2245
|
+
class: K((h = r.classNames) == null ? void 0 : h.event, ...e.classNames),
|
|
2246
|
+
"data-all-day": String(e.allDay),
|
|
2247
|
+
"data-display": e.display,
|
|
2248
|
+
"data-event-id": e.id,
|
|
484
2249
|
"data-editable": String(o),
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
2250
|
+
"data-rsv-selected": String(l),
|
|
2251
|
+
"data-rsv-dragging": a ? "true" : void 0,
|
|
2252
|
+
ref: (w) => {
|
|
2253
|
+
var D, M;
|
|
2254
|
+
U(w, (D = r.hooks) == null ? void 0 : D.eventDidMount, () => v), w !== s.current && ((M = i.current) == null || M.call(i), s.current = w, i.current = w ? he(w, e, d) : null);
|
|
2255
|
+
},
|
|
2256
|
+
style: `--rsv-event-bg:${e.backgroundColor};--rsv-event-fg:${e.textColor};--rsv-event-border:${e.borderColor}`,
|
|
2257
|
+
onClick: (w) => {
|
|
2258
|
+
if (w.stopPropagation(), c.current) {
|
|
2259
|
+
c.current = !1;
|
|
489
2260
|
return;
|
|
490
2261
|
}
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
api: a,
|
|
495
|
-
event: t,
|
|
496
|
-
sourceDate: e,
|
|
497
|
-
onMoved: () => {
|
|
498
|
-
i.current = !0;
|
|
2262
|
+
if (w.ctrlKey || w.metaKey) {
|
|
2263
|
+
t.toggleEventSelection(e.id);
|
|
2264
|
+
return;
|
|
499
2265
|
}
|
|
2266
|
+
t.trigger("eventClick", { event: e, el: w.currentTarget }), e.url && window.open(e.url, "_self");
|
|
2267
|
+
},
|
|
2268
|
+
onKeyDown: o ? (w) => re(w, {
|
|
2269
|
+
api: t,
|
|
2270
|
+
event: e,
|
|
2271
|
+
kind: "dayGrid",
|
|
2272
|
+
shortcuts: r.keyboardShortcuts
|
|
500
2273
|
}) : void 0,
|
|
501
|
-
|
|
502
|
-
children: d
|
|
2274
|
+
children: f
|
|
503
2275
|
}
|
|
504
2276
|
);
|
|
505
2277
|
}
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
2278
|
+
const it = 40, Qt = 16, Jr = {
|
|
2279
|
+
update() {
|
|
2280
|
+
},
|
|
2281
|
+
getScrolled: () => 0,
|
|
2282
|
+
stop() {
|
|
2283
|
+
}
|
|
2284
|
+
};
|
|
2285
|
+
function Oe(t) {
|
|
2286
|
+
if (!t) return Jr;
|
|
2287
|
+
let e = 0, r = 0, n = 0;
|
|
2288
|
+
const a = () => {
|
|
2289
|
+
const o = t.getBoundingClientRect();
|
|
2290
|
+
let d = 0;
|
|
2291
|
+
if (e < o.top + it ? d = -Qt * (1 - Math.max(0, e - o.top) / it) : e > o.bottom - it && (d = Qt * (1 - Math.max(0, o.bottom - e) / it)), d !== 0) {
|
|
2292
|
+
const i = t.scrollTop;
|
|
2293
|
+
t.scrollTop += d, r += t.scrollTop - i;
|
|
2294
|
+
}
|
|
2295
|
+
n = requestAnimationFrame(a);
|
|
2296
|
+
};
|
|
2297
|
+
return n = requestAnimationFrame(a), {
|
|
2298
|
+
update(o) {
|
|
2299
|
+
e = o;
|
|
2300
|
+
},
|
|
2301
|
+
getScrolled: () => r,
|
|
2302
|
+
stop() {
|
|
2303
|
+
cancelAnimationFrame(n);
|
|
2304
|
+
}
|
|
2305
|
+
};
|
|
2306
|
+
}
|
|
2307
|
+
function Te(t) {
|
|
2308
|
+
return t.closest('[data-rsv="tg-body"]');
|
|
2309
|
+
}
|
|
2310
|
+
function te(t, e) {
|
|
2311
|
+
t.preventDefault(), t.stopPropagation();
|
|
2312
|
+
const { api: r, event: n, model: a, columnEl: o, snap: d = "00:15", edge: i, onPreview: s } = e, l = o.getBoundingClientRect(), c = a.maxMinutes - a.minMinutes, y = l.height === 0 ? 0 : l.height / c, T = t.clientY, v = Oe(Te(o));
|
|
2313
|
+
v.update(t.clientY);
|
|
2314
|
+
const f = X(d) || 15, p = (D) => {
|
|
2315
|
+
const M = g.toDate(D);
|
|
2316
|
+
return M.getHours() * 60 + M.getMinutes();
|
|
2317
|
+
}, h = (D) => {
|
|
2318
|
+
if (v.update(D.clientY), !s) return;
|
|
2319
|
+
const M = It(D.clientY - T + v.getScrolled(), y, d), k = i ? $t(n.start, n.end, i, M, g) : ht(n.start, n.end, M, g), m = p(k.start), x = k.end ? p(k.end) : m + f;
|
|
2320
|
+
s({ startMin: Math.min(m, x), endMin: Math.max(m, x) });
|
|
2321
|
+
}, w = (D) => {
|
|
2322
|
+
document.removeEventListener("pointermove", h), document.removeEventListener("pointerup", w), v.stop(), s == null || s(null);
|
|
2323
|
+
const M = It(D.clientY - T + v.getScrolled(), y, d);
|
|
2324
|
+
if (M === 0) return;
|
|
2325
|
+
const k = i ? $t(n.start, n.end, i, M, g) : ht(n.start, n.end, M, g);
|
|
2326
|
+
if (r.moveEvent(n.id, k.start, k.end)) {
|
|
2327
|
+
const m = r.getEventById(n.id);
|
|
2328
|
+
m && r.trigger(i ? "eventResize" : "eventDrop", { event: m });
|
|
2329
|
+
}
|
|
2330
|
+
};
|
|
2331
|
+
document.addEventListener("pointermove", h), document.addEventListener("pointerup", w);
|
|
2332
|
+
}
|
|
2333
|
+
function Qr(t, e) {
|
|
2334
|
+
if (t.target.closest('[data-rsv="event"]')) return;
|
|
2335
|
+
const { api: r, date: n, model: a, columnEl: o, snap: d = "00:15" } = e, i = a.maxMinutes - a.minMinutes, s = X(d) || 15, l = (h) => {
|
|
2336
|
+
const w = o.getBoundingClientRect(), D = w.height === 0 ? 0 : w.height / i, M = a.minMinutes + (D === 0 ? 0 : (h - w.top) / D), k = Math.max(a.minMinutes, Math.min(a.maxMinutes, M));
|
|
2337
|
+
return Math.round(k / s) * s;
|
|
2338
|
+
}, c = l(t.clientY);
|
|
2339
|
+
let y = c, T = !1;
|
|
2340
|
+
const v = Oe(Te(o));
|
|
2341
|
+
v.update(t.clientY);
|
|
2342
|
+
const f = (h) => {
|
|
2343
|
+
var D;
|
|
2344
|
+
v.update(h.clientY);
|
|
2345
|
+
const w = l(h.clientY);
|
|
2346
|
+
w !== c && (T = !0), y = w, T && ((D = e.onPreview) == null || D.call(e, {
|
|
2347
|
+
startMin: Math.min(c, y),
|
|
2348
|
+
endMin: Math.max(c, y)
|
|
2349
|
+
}));
|
|
2350
|
+
}, p = () => {
|
|
2351
|
+
var M;
|
|
2352
|
+
if (document.removeEventListener("pointermove", f), document.removeEventListener("pointerup", p), v.stop(), (M = e.onPreview) == null || M.call(e, null), !T) return;
|
|
2353
|
+
const h = Math.min(c, y), w = Math.max(c, y), D = g.startOf(n, "day");
|
|
533
2354
|
r.select(
|
|
534
|
-
|
|
535
|
-
|
|
2355
|
+
g.toISOString(g.add(D, { minutes: h })),
|
|
2356
|
+
g.toISOString(g.add(D, { minutes: w }))
|
|
536
2357
|
);
|
|
537
2358
|
};
|
|
538
|
-
document.addEventListener("pointermove",
|
|
2359
|
+
document.addEventListener("pointermove", f), document.addEventListener("pointerup", p);
|
|
539
2360
|
}
|
|
540
|
-
function
|
|
541
|
-
const
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
2361
|
+
function tn({ api: t, model: e, options: r }) {
|
|
2362
|
+
const n = r.locale ?? "en", a = { type: t.getView().type }, o = dt(n, r.dayHeaderFormat, {
|
|
2363
|
+
weekday: "short",
|
|
2364
|
+
day: "numeric"
|
|
2365
|
+
}), d = ct(n, r.slotLabelFormat), i = r.allDaySlot !== !1, s = `calc(var(--spacing-rsv-slot, 2.5rem) * ${e.slots.length})`, l = e.maxMinutes - e.minMinutes, c = X(r.snapDuration ?? r.slotDuration ?? "00:15") || 15, y = xe(r.businessHours), T = r.selectConstraint === "businessHours" && y !== null, v = (b, E) => {
|
|
2366
|
+
if (!T) return !0;
|
|
2367
|
+
const P = g.add(g.startOf(b, "day"), { minutes: E });
|
|
2368
|
+
return Pe(P, null, y, g);
|
|
2369
|
+
}, f = F(null), p = F(e);
|
|
2370
|
+
p.current = e;
|
|
2371
|
+
const [h, w] = V(null), [D, M] = V(null), k = F(null), m = F(/* @__PURE__ */ new Map());
|
|
2372
|
+
H(() => {
|
|
2373
|
+
const b = m.current;
|
|
2374
|
+
return () => {
|
|
2375
|
+
for (const E of b.values()) E();
|
|
2376
|
+
b.clear();
|
|
2377
|
+
};
|
|
2378
|
+
}, []), H(
|
|
2379
|
+
() => Ur({
|
|
2380
|
+
api: t,
|
|
2381
|
+
getModel: () => p.current,
|
|
2382
|
+
snap: r.snapDuration ?? r.slotDuration,
|
|
2383
|
+
onPreview: (b) => M(b ? { id: k.current ?? "", preview: b } : null),
|
|
2384
|
+
onDragging: (b) => {
|
|
2385
|
+
k.current = b, b === null && M(null);
|
|
2386
|
+
}
|
|
2387
|
+
}),
|
|
2388
|
+
[t, r.snapDuration, r.slotDuration]
|
|
2389
|
+
), H(() => {
|
|
2390
|
+
const b = f.current;
|
|
2391
|
+
if (!b) return;
|
|
2392
|
+
const E = {
|
|
2393
|
+
scrollToTime(P) {
|
|
2394
|
+
const O = p.current, A = O.maxMinutes - O.minMinutes, j = b.scrollHeight;
|
|
2395
|
+
if (A <= 0 || j <= 0) return;
|
|
2396
|
+
const S = (Math.max(O.minMinutes, Math.min(O.maxMinutes, X(P))) - O.minMinutes) / A * j;
|
|
2397
|
+
b.scrollTop = Math.max(0, Math.min(S, j - b.clientHeight));
|
|
2398
|
+
},
|
|
2399
|
+
getScrollTime() {
|
|
2400
|
+
const P = p.current, O = P.maxMinutes - P.minMinutes, A = b.scrollHeight;
|
|
2401
|
+
return O <= 0 || A <= 0 ? null : Ge(P.minMinutes + b.scrollTop / A * O);
|
|
2402
|
+
}
|
|
2403
|
+
};
|
|
2404
|
+
return t.setViewAdapter(E), () => t.setViewAdapter(null);
|
|
2405
|
+
}, [t]);
|
|
2406
|
+
const x = r.scrollTime;
|
|
2407
|
+
H(() => {
|
|
2408
|
+
if (!x) return;
|
|
2409
|
+
let b = 0;
|
|
2410
|
+
const E = requestAnimationFrame(() => {
|
|
2411
|
+
b = requestAnimationFrame(() => t.scrollToTime(x));
|
|
2412
|
+
});
|
|
2413
|
+
return () => {
|
|
2414
|
+
cancelAnimationFrame(E), cancelAnimationFrame(b);
|
|
2415
|
+
};
|
|
2416
|
+
}, [t]);
|
|
2417
|
+
const R = (b, E) => {
|
|
2418
|
+
const P = b.getBoundingClientRect();
|
|
2419
|
+
if (P.height === 0 || l <= 0) return e.minMinutes;
|
|
2420
|
+
const O = (E - P.top) / P.height * l, A = Math.floor(Math.max(0, Math.min(l, O)) / c) * c;
|
|
2421
|
+
return e.minMinutes + A;
|
|
2422
|
+
}, $ = e.days[0];
|
|
2423
|
+
return /* @__PURE__ */ C("div", { "data-rsv": "timegrid", style: `--rsv-tg-days:${e.days.length}`, children: [
|
|
2424
|
+
/* @__PURE__ */ C("div", { "data-rsv": "tg-header", role: "row", children: [
|
|
2425
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tg-axis-corner" }),
|
|
2426
|
+
e.days.map((b) => {
|
|
2427
|
+
var A, j;
|
|
2428
|
+
const E = g.toDate(b.date), P = o ? o(E) : "", O = {
|
|
2429
|
+
date: E,
|
|
2430
|
+
text: P,
|
|
2431
|
+
dayOfWeek: g.dayOfWeek(b.date),
|
|
2432
|
+
dayNumber: g.dayOfMonth(b.date),
|
|
2433
|
+
isToday: b.isToday,
|
|
2434
|
+
view: a
|
|
2435
|
+
};
|
|
2436
|
+
return /* @__PURE__ */ u(
|
|
2437
|
+
"div",
|
|
2438
|
+
{
|
|
2439
|
+
"data-rsv": "tg-col-header",
|
|
2440
|
+
role: "columnheader",
|
|
2441
|
+
"data-today": String(b.isToday),
|
|
2442
|
+
"data-date": g.toISOString(b.date),
|
|
2443
|
+
"data-nav-link": r.navLinks ? "true" : void 0,
|
|
2444
|
+
class: K((A = r.classNames) == null ? void 0 : A.dayHeader),
|
|
2445
|
+
ref: (L) => {
|
|
2446
|
+
var S;
|
|
2447
|
+
return U(L, (S = r.hooks) == null ? void 0 : S.dayHeaderDidMount, () => O);
|
|
2448
|
+
},
|
|
2449
|
+
onClick: r.navLinks ? () => ee(t, b.date) : void 0,
|
|
2450
|
+
children: B((j = r.slots) == null ? void 0 : j.dayHeaderContent, O, P, r.hostBridge)
|
|
2451
|
+
},
|
|
2452
|
+
g.toISOString(b.date)
|
|
2453
|
+
);
|
|
2454
|
+
})
|
|
557
2455
|
] }),
|
|
558
|
-
i && /* @__PURE__ */
|
|
559
|
-
/* @__PURE__ */
|
|
560
|
-
|
|
2456
|
+
i && /* @__PURE__ */ C("div", { "data-rsv": "tg-allday", role: "row", children: [
|
|
2457
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tg-axis-label", children: W(r.locale).allDay }),
|
|
2458
|
+
e.days.map((b) => /* @__PURE__ */ u(
|
|
561
2459
|
"div",
|
|
562
2460
|
{
|
|
563
|
-
"data-rsv": "
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
2461
|
+
"data-rsv": "tg-allday-cell",
|
|
2462
|
+
onClick: () => t.trigger("dateClick", { date: b.date, allDay: !0 }),
|
|
2463
|
+
children: b.allDayEvents.filter((E) => E.display !== "none").map((E) => {
|
|
2464
|
+
var P, O;
|
|
2465
|
+
return /* @__PURE__ */ u(
|
|
2466
|
+
"div",
|
|
2467
|
+
{
|
|
2468
|
+
"data-rsv": "event",
|
|
2469
|
+
"data-all-day": "true",
|
|
2470
|
+
"data-event-id": E.id,
|
|
2471
|
+
class: K((P = r.classNames) == null ? void 0 : P.event, ...E.classNames),
|
|
2472
|
+
"data-display": E.display,
|
|
2473
|
+
style: `--rsv-event-bg:${E.backgroundColor};--rsv-event-fg:${E.textColor};--rsv-event-border:${E.borderColor}`,
|
|
2474
|
+
onClick: (A) => {
|
|
2475
|
+
A.stopPropagation(), t.trigger("eventClick", { event: E, el: A.currentTarget }), E.url && window.open(E.url, "_self");
|
|
2476
|
+
},
|
|
2477
|
+
children: B(
|
|
2478
|
+
(O = r.slots) == null ? void 0 : O.eventContent,
|
|
2479
|
+
{ event: E, isAllDay: !0, timeText: "", view: a },
|
|
2480
|
+
E.title,
|
|
2481
|
+
r.hostBridge
|
|
2482
|
+
)
|
|
2483
|
+
},
|
|
2484
|
+
E.id
|
|
2485
|
+
);
|
|
2486
|
+
})
|
|
572
2487
|
},
|
|
573
|
-
|
|
574
|
-
))
|
|
2488
|
+
g.toISOString(b.date)
|
|
2489
|
+
))
|
|
575
2490
|
] }),
|
|
576
|
-
/* @__PURE__ */
|
|
577
|
-
/* @__PURE__ */
|
|
578
|
-
var
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
2491
|
+
/* @__PURE__ */ C("div", { "data-rsv": "tg-body", ref: f, children: [
|
|
2492
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tg-axis", style: `height:${s}`, children: e.slots.map((b) => {
|
|
2493
|
+
var A, j;
|
|
2494
|
+
const E = e.minMinutes + b.offsetMin;
|
|
2495
|
+
let P = "";
|
|
2496
|
+
b.isMajor && (P = d && $ ? d(g.toDate(g.add(g.startOf($.date, "day"), { minutes: E }))) : b.label || We(E));
|
|
2497
|
+
const O = { text: P, minutes: E, isMajor: b.isMajor, view: a };
|
|
2498
|
+
return /* @__PURE__ */ u("div", { "data-rsv": "tg-slot", "data-major": String(b.isMajor), children: /* @__PURE__ */ u(
|
|
2499
|
+
"span",
|
|
2500
|
+
{
|
|
2501
|
+
"data-rsv": "tg-slot-label",
|
|
2502
|
+
class: K((A = r.classNames) == null ? void 0 : A.slotLabel),
|
|
2503
|
+
ref: (L) => {
|
|
2504
|
+
var S;
|
|
2505
|
+
return U(L, (S = r.hooks) == null ? void 0 : S.slotLabelDidMount, () => O);
|
|
2506
|
+
},
|
|
2507
|
+
children: B((j = r.slots) == null ? void 0 : j.slotLabelContent, O, P, r.hostBridge)
|
|
2508
|
+
}
|
|
2509
|
+
) }, b.offsetMin);
|
|
584
2510
|
}) }),
|
|
585
|
-
|
|
586
|
-
var
|
|
587
|
-
return /* @__PURE__ */
|
|
2511
|
+
e.days.map((b, E) => {
|
|
2512
|
+
var P;
|
|
2513
|
+
return /* @__PURE__ */ C(
|
|
588
2514
|
"div",
|
|
589
2515
|
{
|
|
590
2516
|
"data-rsv": "tg-col",
|
|
591
|
-
"data-today": String(
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
2517
|
+
"data-today": String(b.isToday),
|
|
2518
|
+
"data-business": String(b.isBusiness),
|
|
2519
|
+
"data-date": g.toISOString(b.date),
|
|
2520
|
+
"data-rsv-day-index": String(E),
|
|
2521
|
+
ref: (O) => {
|
|
2522
|
+
!O || m.current.has(O) || m.current.set(O, Vr(O));
|
|
2523
|
+
},
|
|
2524
|
+
style: `height:${s}`,
|
|
2525
|
+
onClick: (O) => {
|
|
2526
|
+
if (ye()) return;
|
|
2527
|
+
const A = R(O.currentTarget, O.clientY);
|
|
2528
|
+
v(b.date, A) && t.trigger("dateClick", {
|
|
2529
|
+
date: g.add(g.startOf(b.date, "day"), { minutes: A }),
|
|
2530
|
+
allDay: !1
|
|
2531
|
+
});
|
|
2532
|
+
},
|
|
2533
|
+
onPointerDown: r.selectable ? (O) => {
|
|
2534
|
+
const A = R(O.currentTarget, O.clientY);
|
|
2535
|
+
v(b.date, A) && Qr(O, {
|
|
2536
|
+
api: t,
|
|
2537
|
+
date: b.date,
|
|
2538
|
+
model: e,
|
|
2539
|
+
columnEl: O.currentTarget,
|
|
2540
|
+
snap: r.snapDuration ?? r.slotDuration,
|
|
2541
|
+
onPreview: r.selectMirror ? (j) => w(
|
|
2542
|
+
j ? { dayIndex: E, startMin: j.startMin, endMin: j.endMin } : null
|
|
2543
|
+
) : void 0
|
|
2544
|
+
});
|
|
2545
|
+
} : void 0,
|
|
601
2546
|
children: [
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
2547
|
+
b.nonBusinessPct.map((O) => /* @__PURE__ */ u(
|
|
2548
|
+
"div",
|
|
2549
|
+
{
|
|
2550
|
+
"data-rsv": "tg-nonbusiness",
|
|
2551
|
+
style: `top:${O.topPct}%;height:${O.heightPct}%`
|
|
2552
|
+
},
|
|
2553
|
+
O.topPct
|
|
2554
|
+
)),
|
|
2555
|
+
(h == null ? void 0 : h.dayIndex) === E && l > 0 && /* @__PURE__ */ u(
|
|
2556
|
+
"div",
|
|
2557
|
+
{
|
|
2558
|
+
"data-rsv": "select-mirror",
|
|
2559
|
+
style: `top:${(h.startMin - e.minMinutes) / l * 100}%;height:${(h.endMin - h.startMin) / l * 100}%`
|
|
2560
|
+
}
|
|
2561
|
+
),
|
|
2562
|
+
b.timedSegs.filter((O) => O.event.display !== "none").map((O) => /* @__PURE__ */ u(
|
|
2563
|
+
en,
|
|
615
2564
|
{
|
|
616
|
-
api:
|
|
617
|
-
seg:
|
|
618
|
-
model:
|
|
619
|
-
options: r
|
|
2565
|
+
api: t,
|
|
2566
|
+
seg: O,
|
|
2567
|
+
model: e,
|
|
2568
|
+
options: r,
|
|
2569
|
+
view: a,
|
|
2570
|
+
dragging: (D == null ? void 0 : D.id) === O.event.id,
|
|
2571
|
+
onDragPreview: (A) => M(A ? { id: O.event.id, preview: { dayIndex: E, ...A } } : null)
|
|
620
2572
|
},
|
|
621
|
-
|
|
2573
|
+
O.event.id
|
|
622
2574
|
)),
|
|
623
|
-
(
|
|
2575
|
+
(D == null ? void 0 : D.preview.dayIndex) === E && l > 0 && /* @__PURE__ */ u(
|
|
2576
|
+
"div",
|
|
2577
|
+
{
|
|
2578
|
+
"data-rsv": "drag-mirror",
|
|
2579
|
+
style: `top:${(D.preview.startMin - e.minMinutes) / l * 100}%;height:${(D.preview.endMin - D.preview.startMin) / l * 100}%`
|
|
2580
|
+
}
|
|
2581
|
+
),
|
|
2582
|
+
((P = e.nowIndicator) == null ? void 0 : P.dayIndex) === E && /* @__PURE__ */ u("div", { "data-rsv": "now-indicator", style: `top:${e.nowIndicator.topPct}%` })
|
|
624
2583
|
]
|
|
625
2584
|
},
|
|
626
|
-
|
|
2585
|
+
g.toISOString(b.date)
|
|
627
2586
|
);
|
|
628
2587
|
})
|
|
629
2588
|
] })
|
|
630
2589
|
] });
|
|
631
2590
|
}
|
|
632
|
-
function
|
|
633
|
-
api:
|
|
634
|
-
seg:
|
|
2591
|
+
function en({
|
|
2592
|
+
api: t,
|
|
2593
|
+
seg: e,
|
|
635
2594
|
model: r,
|
|
636
|
-
options:
|
|
2595
|
+
options: n,
|
|
2596
|
+
view: a,
|
|
2597
|
+
dragging: o,
|
|
2598
|
+
onDragPreview: d
|
|
637
2599
|
}) {
|
|
638
|
-
var
|
|
639
|
-
const { event:
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
2600
|
+
var M, k;
|
|
2601
|
+
const { event: i } = e, s = n.editable === !0 && i.editable !== !1, l = s && n.eventDraggable === !0, c = F(null), y = F(null);
|
|
2602
|
+
H(() => () => {
|
|
2603
|
+
var m;
|
|
2604
|
+
return (m = c.current) == null ? void 0 : m.call(c);
|
|
2605
|
+
}, []);
|
|
2606
|
+
const T = t.selectedEventIds.value.has(i.id), v = 100 / e.colCount, f = ct(n.locale ?? "en", n.eventTimeFormat), p = f ? f(g.toDate(i.start)) : g.format(i.start, "HH:mm"), h = { event: i, isAllDay: !1, timeText: p, view: a }, w = B(
|
|
2607
|
+
(M = n.slots) == null ? void 0 : M.eventContent,
|
|
2608
|
+
h,
|
|
2609
|
+
/* @__PURE__ */ C("span", { "data-rsv": "event-title", children: [
|
|
2610
|
+
p,
|
|
644
2611
|
" ",
|
|
645
|
-
|
|
646
|
-
] })
|
|
647
|
-
|
|
648
|
-
|
|
2612
|
+
i.title
|
|
2613
|
+
] }),
|
|
2614
|
+
n.hostBridge
|
|
2615
|
+
), D = (m) => m.closest('[data-rsv="tg-col"]') ?? m;
|
|
2616
|
+
return /* @__PURE__ */ C(
|
|
649
2617
|
"div",
|
|
650
2618
|
{
|
|
651
2619
|
"data-rsv": "event",
|
|
652
2620
|
"data-all-day": "false",
|
|
653
|
-
"data-display":
|
|
654
|
-
"data-event-id":
|
|
655
|
-
|
|
2621
|
+
"data-display": i.display,
|
|
2622
|
+
"data-event-id": i.id,
|
|
2623
|
+
"data-rsv-selected": String(T),
|
|
2624
|
+
"data-rsv-dragging": o ? "true" : void 0,
|
|
2625
|
+
class: K((k = n.classNames) == null ? void 0 : k.event, ...i.classNames),
|
|
656
2626
|
role: "button",
|
|
657
2627
|
tabIndex: 0,
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
2628
|
+
ref: (m) => {
|
|
2629
|
+
var x, R;
|
|
2630
|
+
U(m, (x = n.hooks) == null ? void 0 : x.eventDidMount, () => h), m !== y.current && ((R = c.current) == null || R.call(c), y.current = m, c.current = m ? he(m, i, l) : null);
|
|
661
2631
|
},
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
2632
|
+
style: `position:absolute;top:${e.topPct}%;height:${e.heightPct}%;left:${e.col * v}%;width:${v}%;--rsv-event-bg:${i.backgroundColor};--rsv-event-fg:${i.textColor};--rsv-event-border:${i.borderColor}`,
|
|
2633
|
+
onClick: (m) => {
|
|
2634
|
+
if (m.stopPropagation(), !ye()) {
|
|
2635
|
+
if (m.ctrlKey || m.metaKey) {
|
|
2636
|
+
t.toggleEventSelection(i.id);
|
|
2637
|
+
return;
|
|
2638
|
+
}
|
|
2639
|
+
t.trigger("eventClick", { event: i, el: m.currentTarget }), i.url && window.open(i.url, "_self");
|
|
2640
|
+
}
|
|
2641
|
+
},
|
|
2642
|
+
onKeyDown: s ? (m) => re(m, {
|
|
2643
|
+
api: t,
|
|
2644
|
+
event: i,
|
|
665
2645
|
kind: "timeGrid",
|
|
666
|
-
snap:
|
|
667
|
-
|
|
668
|
-
onPointerDown: i ? (g) => G(g, {
|
|
669
|
-
api: a,
|
|
670
|
-
event: o,
|
|
671
|
-
model: r,
|
|
672
|
-
columnEl: c(g.currentTarget),
|
|
673
|
-
snap: e.snapDuration
|
|
2646
|
+
snap: n.snapDuration ?? n.slotDuration,
|
|
2647
|
+
shortcuts: n.keyboardShortcuts
|
|
674
2648
|
}) : void 0,
|
|
675
2649
|
children: [
|
|
676
|
-
|
|
2650
|
+
s && /* @__PURE__ */ u(
|
|
677
2651
|
"span",
|
|
678
2652
|
{
|
|
679
2653
|
"data-rsv": "resize-handle",
|
|
680
2654
|
"data-edge": "start",
|
|
681
|
-
onPointerDown: (
|
|
682
|
-
api:
|
|
683
|
-
event:
|
|
2655
|
+
onPointerDown: (m) => te(m, {
|
|
2656
|
+
api: t,
|
|
2657
|
+
event: i,
|
|
684
2658
|
model: r,
|
|
685
|
-
columnEl:
|
|
686
|
-
snap:
|
|
2659
|
+
columnEl: D(m.currentTarget),
|
|
2660
|
+
snap: n.snapDuration,
|
|
2661
|
+
onPreview: d,
|
|
687
2662
|
edge: "start"
|
|
688
2663
|
})
|
|
689
2664
|
}
|
|
690
2665
|
),
|
|
691
|
-
|
|
692
|
-
|
|
2666
|
+
w,
|
|
2667
|
+
s && /* @__PURE__ */ u(
|
|
693
2668
|
"span",
|
|
694
2669
|
{
|
|
695
2670
|
"data-rsv": "resize-handle",
|
|
696
2671
|
"data-edge": "end",
|
|
697
|
-
onPointerDown: (
|
|
698
|
-
api:
|
|
699
|
-
event:
|
|
2672
|
+
onPointerDown: (m) => te(m, {
|
|
2673
|
+
api: t,
|
|
2674
|
+
event: i,
|
|
700
2675
|
model: r,
|
|
701
|
-
columnEl:
|
|
702
|
-
snap:
|
|
2676
|
+
columnEl: D(m.currentTarget),
|
|
2677
|
+
snap: n.snapDuration,
|
|
2678
|
+
onPreview: d,
|
|
703
2679
|
edge: "end"
|
|
704
2680
|
})
|
|
705
2681
|
}
|
|
@@ -708,227 +2684,337 @@ function $t({
|
|
|
708
2684
|
}
|
|
709
2685
|
);
|
|
710
2686
|
}
|
|
711
|
-
function
|
|
712
|
-
const
|
|
2687
|
+
function rn({ api: t, model: e, options: r }) {
|
|
2688
|
+
const n = r.locale ?? "en", a = { type: t.getView().type }, o = W(r.locale), d = dt(n, r.listDayFormat, {
|
|
713
2689
|
weekday: "long",
|
|
714
2690
|
day: "numeric",
|
|
715
2691
|
month: "long"
|
|
716
|
-
});
|
|
717
|
-
return
|
|
718
|
-
/* @__PURE__ */
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
2692
|
+
}), i = r.listDaySideFormat ? dt(n, r.listDaySideFormat, { month: "short", day: "2-digit" }) : null, s = ct(n, r.eventTimeFormat);
|
|
2693
|
+
return e.isEmpty ? /* @__PURE__ */ u("div", { "data-rsv": "list", children: /* @__PURE__ */ u("div", { "data-rsv": "list-empty", children: o.noEvents }) }) : /* @__PURE__ */ u("div", { "data-rsv": "list", role: "list", children: e.days.map((l) => /* @__PURE__ */ C("div", { "data-rsv": "list-day", "data-today": String(l.isToday), children: [
|
|
2694
|
+
/* @__PURE__ */ C("div", { "data-rsv": "list-day-header", role: "heading", "aria-level": 3, children: [
|
|
2695
|
+
/* @__PURE__ */ u("span", { "data-rsv": "list-day-text", children: d ? d(g.toDate(l.date)) : "" }),
|
|
2696
|
+
i && /* @__PURE__ */ u("span", { "data-rsv": "list-day-side-text", children: i(g.toDate(l.date)) })
|
|
2697
|
+
] }),
|
|
2698
|
+
l.events.filter((c) => c.display !== "none").map((c) => {
|
|
2699
|
+
var v, f;
|
|
2700
|
+
const y = c.allDay ? o.allDay : s ? s(g.toDate(c.start)) : g.format(c.start, "HH:mm"), T = { event: c, isAllDay: c.allDay, timeText: y, view: a };
|
|
2701
|
+
return /* @__PURE__ */ C(
|
|
723
2702
|
"div",
|
|
724
2703
|
{
|
|
725
2704
|
"data-rsv": "list-item",
|
|
726
2705
|
role: "listitem",
|
|
727
2706
|
tabIndex: 0,
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
2707
|
+
"data-event-id": c.id,
|
|
2708
|
+
class: K((v = r.classNames) == null ? void 0 : v.event, ...c.classNames),
|
|
2709
|
+
"data-display": c.display,
|
|
2710
|
+
ref: (p) => {
|
|
2711
|
+
var h;
|
|
2712
|
+
return U(p, (h = r.hooks) == null ? void 0 : h.eventDidMount, () => T);
|
|
2713
|
+
},
|
|
2714
|
+
style: `--rsv-event-bg:${c.backgroundColor};--rsv-event-fg:${c.textColor};--rsv-event-border:${c.borderColor}`,
|
|
2715
|
+
onClick: (p) => {
|
|
2716
|
+
t.trigger("eventClick", { event: c, el: p.currentTarget }), c.url && window.open(c.url, "_self");
|
|
732
2717
|
},
|
|
733
2718
|
children: [
|
|
734
|
-
/* @__PURE__ */
|
|
735
|
-
/* @__PURE__ */
|
|
2719
|
+
/* @__PURE__ */ u("span", { "data-rsv": "list-item-time", children: y }),
|
|
2720
|
+
/* @__PURE__ */ u(
|
|
736
2721
|
"span",
|
|
737
2722
|
{
|
|
738
2723
|
"data-rsv": "list-item-dot",
|
|
739
|
-
style: `--rsv-event-bg:${
|
|
2724
|
+
style: `--rsv-event-bg:${c.backgroundColor}`
|
|
740
2725
|
}
|
|
741
2726
|
),
|
|
742
|
-
/* @__PURE__ */
|
|
743
|
-
(
|
|
744
|
-
|
|
745
|
-
|
|
2727
|
+
/* @__PURE__ */ u("div", { "data-rsv": "list-item-title", children: B(
|
|
2728
|
+
(f = r.slots) == null ? void 0 : f.eventContent,
|
|
2729
|
+
T,
|
|
2730
|
+
c.title,
|
|
2731
|
+
r.hostBridge
|
|
746
2732
|
) })
|
|
747
2733
|
]
|
|
748
2734
|
},
|
|
749
|
-
|
|
2735
|
+
c.id
|
|
750
2736
|
);
|
|
751
2737
|
})
|
|
752
|
-
] },
|
|
753
|
-
}
|
|
754
|
-
function
|
|
755
|
-
const
|
|
756
|
-
return /* @__PURE__ */
|
|
757
|
-
/* @__PURE__ */
|
|
758
|
-
/* @__PURE__ */
|
|
759
|
-
] },
|
|
760
|
-
}
|
|
761
|
-
const
|
|
762
|
-
function
|
|
763
|
-
return /* @__PURE__ */
|
|
764
|
-
/* @__PURE__ */
|
|
765
|
-
/* @__PURE__ */
|
|
2738
|
+
] }, g.toISOString(l.date))) });
|
|
2739
|
+
}
|
|
2740
|
+
function nn({ api: t, model: e, options: r }) {
|
|
2741
|
+
const n = r.locale ?? "en", a = new Intl.DateTimeFormat(n, { month: "long" });
|
|
2742
|
+
return /* @__PURE__ */ u("div", { "data-rsv": "multimonth", children: e.months.map((o) => /* @__PURE__ */ C("section", { "data-rsv": "mm-month", children: [
|
|
2743
|
+
/* @__PURE__ */ u("header", { "data-rsv": "mm-title", children: a.format(g.toDate(o.date)) }),
|
|
2744
|
+
/* @__PURE__ */ u(De, { api: t, model: o.dayGrid, options: r })
|
|
2745
|
+
] }, g.toISOString(o.date))) });
|
|
2746
|
+
}
|
|
2747
|
+
const Tt = 1.6;
|
|
2748
|
+
function an({ api: t, model: e, options: r }) {
|
|
2749
|
+
return /* @__PURE__ */ C("div", { "data-rsv": "timeline", children: [
|
|
2750
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tl-axis", role: "row", children: e.slots.map((n) => /* @__PURE__ */ u("div", { "data-rsv": "tl-slot", style: `left:${n.leftPct}%`, children: n.label }, n.leftPct)) }),
|
|
2751
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tl-body", style: `height:${e.laneCount * Tt + 0.5}rem`, children: e.segs.map((n) => /* @__PURE__ */ u(Ee, { api: t, seg: n, options: r }, n.event.id)) })
|
|
766
2752
|
] });
|
|
767
2753
|
}
|
|
768
|
-
function
|
|
769
|
-
api:
|
|
770
|
-
seg:
|
|
2754
|
+
function Ee({
|
|
2755
|
+
api: t,
|
|
2756
|
+
seg: e,
|
|
771
2757
|
options: r
|
|
772
2758
|
}) {
|
|
773
|
-
var
|
|
774
|
-
const { event:
|
|
775
|
-
return /* @__PURE__ */
|
|
2759
|
+
var a;
|
|
2760
|
+
const { event: n } = e;
|
|
2761
|
+
return /* @__PURE__ */ u(
|
|
776
2762
|
"div",
|
|
777
2763
|
{
|
|
778
2764
|
"data-rsv": "event",
|
|
779
|
-
"data-event-id":
|
|
2765
|
+
"data-event-id": n.id,
|
|
780
2766
|
role: "button",
|
|
781
2767
|
tabIndex: 0,
|
|
782
|
-
style: `position:absolute;left:${
|
|
783
|
-
onClick: () =>
|
|
784
|
-
children:
|
|
785
|
-
(
|
|
786
|
-
{ event:
|
|
787
|
-
|
|
2768
|
+
style: `position:absolute;left:${e.leftPct}%;width:${e.widthPct}%;top:${e.lane * Tt}rem;height:${Tt - 0.2}rem;--rsv-event-bg:${n.backgroundColor};--rsv-event-fg:${n.textColor};--rsv-event-border:${n.borderColor}`,
|
|
2769
|
+
onClick: (o) => t.trigger("eventClick", { event: n, el: o.currentTarget }),
|
|
2770
|
+
children: B(
|
|
2771
|
+
(a = r.slots) == null ? void 0 : a.eventContent,
|
|
2772
|
+
{ event: n, isAllDay: n.allDay, timeText: "", view: { type: t.getView().type } },
|
|
2773
|
+
n.title,
|
|
2774
|
+
r.hostBridge
|
|
788
2775
|
)
|
|
789
2776
|
}
|
|
790
2777
|
);
|
|
791
2778
|
}
|
|
792
|
-
const
|
|
793
|
-
function
|
|
794
|
-
return /* @__PURE__ */
|
|
795
|
-
/* @__PURE__ */
|
|
796
|
-
/* @__PURE__ */
|
|
797
|
-
/* @__PURE__ */
|
|
2779
|
+
const on = 1.6;
|
|
2780
|
+
function sn({ api: t, model: e, options: r }) {
|
|
2781
|
+
return /* @__PURE__ */ C("div", { "data-rsv": "resource-timeline", children: [
|
|
2782
|
+
/* @__PURE__ */ C("div", { "data-rsv": "rt-header", role: "row", children: [
|
|
2783
|
+
/* @__PURE__ */ u("div", { "data-rsv": "resource-area-header", children: r.locale === "es" ? "Recursos" : "Resources" }),
|
|
2784
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tl-axis", children: e.slots.map((n) => /* @__PURE__ */ u("div", { "data-rsv": "tl-slot", style: `left:${n.leftPct}%`, children: n.label }, n.leftPct)) })
|
|
798
2785
|
] }),
|
|
799
|
-
|
|
800
|
-
const
|
|
801
|
-
return /* @__PURE__ */
|
|
802
|
-
/* @__PURE__ */
|
|
2786
|
+
e.lanes.map((n) => {
|
|
2787
|
+
const a = n.laneCount * on + 0.4;
|
|
2788
|
+
return /* @__PURE__ */ C("div", { "data-rsv": "resource-row", role: "row", children: [
|
|
2789
|
+
/* @__PURE__ */ C(
|
|
803
2790
|
"div",
|
|
804
2791
|
{
|
|
805
2792
|
"data-rsv": "resource-label",
|
|
806
|
-
style: `padding-inline-start:${0.5 +
|
|
2793
|
+
style: `padding-inline-start:${0.5 + n.row.depth * 1}rem`,
|
|
807
2794
|
children: [
|
|
808
|
-
|
|
2795
|
+
n.row.hasChildren && /* @__PURE__ */ u(
|
|
809
2796
|
"button",
|
|
810
2797
|
{
|
|
811
2798
|
type: "button",
|
|
812
2799
|
"data-rsv": "resource-toggle",
|
|
813
|
-
"aria-expanded":
|
|
814
|
-
onClick: () =>
|
|
815
|
-
children:
|
|
2800
|
+
"aria-expanded": n.row.expanded,
|
|
2801
|
+
onClick: () => t.toggleResource(n.row.resource.id),
|
|
2802
|
+
children: n.row.expanded ? "▾" : "▸"
|
|
816
2803
|
}
|
|
817
2804
|
),
|
|
818
|
-
/* @__PURE__ */
|
|
2805
|
+
/* @__PURE__ */ u("span", { "data-rsv": "resource-title", children: n.row.resource.title })
|
|
819
2806
|
]
|
|
820
2807
|
}
|
|
821
2808
|
),
|
|
822
|
-
/* @__PURE__ */
|
|
823
|
-
] },
|
|
2809
|
+
/* @__PURE__ */ u("div", { "data-rsv": "resource-lane", style: `height:${a}rem`, children: n.segs.map((o) => /* @__PURE__ */ u(Ee, { api: t, seg: o, options: r }, o.event.id)) })
|
|
2810
|
+
] }, n.row.resource.id);
|
|
824
2811
|
})
|
|
825
2812
|
] });
|
|
826
2813
|
}
|
|
827
|
-
function
|
|
828
|
-
const
|
|
829
|
-
return /* @__PURE__ */
|
|
830
|
-
/* @__PURE__ */
|
|
831
|
-
/* @__PURE__ */
|
|
832
|
-
|
|
2814
|
+
function dn({ api: t, model: e, options: r }) {
|
|
2815
|
+
const n = `calc(var(--spacing-rsv-slot, 2.5rem) * ${e.slots.length})`;
|
|
2816
|
+
return /* @__PURE__ */ C("div", { "data-rsv": "timegrid", style: `--rsv-tg-days:${e.columns.length}`, children: [
|
|
2817
|
+
/* @__PURE__ */ C("div", { "data-rsv": "tg-header", role: "row", children: [
|
|
2818
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tg-axis-corner" }),
|
|
2819
|
+
e.columns.map((a) => /* @__PURE__ */ u("div", { "data-rsv": "tg-col-header", role: "columnheader", children: a.row.resource.title }, a.row.resource.id))
|
|
833
2820
|
] }),
|
|
834
|
-
/* @__PURE__ */
|
|
835
|
-
/* @__PURE__ */
|
|
836
|
-
|
|
2821
|
+
/* @__PURE__ */ C("div", { "data-rsv": "tg-allday", role: "row", children: [
|
|
2822
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tg-axis-label", children: W(r.locale).allDay }),
|
|
2823
|
+
e.columns.map((a) => /* @__PURE__ */ u("div", { "data-rsv": "tg-allday-cell", children: a.allDayEvents.map((o) => /* @__PURE__ */ u(
|
|
837
2824
|
"div",
|
|
838
2825
|
{
|
|
839
2826
|
"data-rsv": "event",
|
|
840
2827
|
"data-all-day": "true",
|
|
841
|
-
style: `--rsv-event-bg:${
|
|
842
|
-
onClick: () =>
|
|
843
|
-
children:
|
|
2828
|
+
style: `--rsv-event-bg:${o.backgroundColor}`,
|
|
2829
|
+
onClick: (d) => t.trigger("eventClick", { event: o, el: d.currentTarget }),
|
|
2830
|
+
children: o.title
|
|
844
2831
|
},
|
|
845
|
-
|
|
846
|
-
)) },
|
|
2832
|
+
o.id
|
|
2833
|
+
)) }, a.row.resource.id))
|
|
847
2834
|
] }),
|
|
848
|
-
/* @__PURE__ */
|
|
849
|
-
/* @__PURE__ */
|
|
850
|
-
|
|
2835
|
+
/* @__PURE__ */ C("div", { "data-rsv": "tg-body", children: [
|
|
2836
|
+
/* @__PURE__ */ u("div", { "data-rsv": "tg-axis", style: `height:${n}`, children: e.slots.map((a) => /* @__PURE__ */ u("div", { "data-rsv": "tg-slot", "data-major": String(a.isMajor), children: /* @__PURE__ */ u("span", { "data-rsv": "tg-slot-label", children: a.label }) }, a.offsetMin)) }),
|
|
2837
|
+
e.columns.map((a) => /* @__PURE__ */ C(
|
|
851
2838
|
"div",
|
|
852
2839
|
{
|
|
853
2840
|
"data-rsv": "tg-col",
|
|
854
|
-
"data-rsv-resource-id":
|
|
855
|
-
style: `height:${
|
|
2841
|
+
"data-rsv-resource-id": a.row.resource.id,
|
|
2842
|
+
style: `height:${n}`,
|
|
856
2843
|
children: [
|
|
857
|
-
|
|
858
|
-
const
|
|
859
|
-
return /* @__PURE__ */
|
|
2844
|
+
a.timedSegs.map((o) => {
|
|
2845
|
+
const d = 100 / o.colCount;
|
|
2846
|
+
return /* @__PURE__ */ C(
|
|
860
2847
|
"div",
|
|
861
2848
|
{
|
|
862
2849
|
"data-rsv": "event",
|
|
863
2850
|
"data-all-day": "false",
|
|
864
|
-
"data-event-id":
|
|
2851
|
+
"data-event-id": o.event.id,
|
|
865
2852
|
role: "button",
|
|
866
2853
|
tabIndex: 0,
|
|
867
|
-
style: `position:absolute;top:${
|
|
868
|
-
onClick: (
|
|
869
|
-
|
|
2854
|
+
style: `position:absolute;top:${o.topPct}%;height:${o.heightPct}%;left:${o.col * d}%;width:${d}%;--rsv-event-bg:${o.event.backgroundColor};--rsv-event-fg:${o.event.textColor}`,
|
|
2855
|
+
onClick: (i) => {
|
|
2856
|
+
i.stopPropagation(), t.trigger("eventClick", { event: o.event });
|
|
870
2857
|
},
|
|
871
2858
|
children: [
|
|
872
|
-
|
|
2859
|
+
g.format(o.event.start, "HH:mm"),
|
|
873
2860
|
" ",
|
|
874
|
-
|
|
2861
|
+
o.event.title
|
|
875
2862
|
]
|
|
876
2863
|
},
|
|
877
|
-
|
|
2864
|
+
o.event.id
|
|
878
2865
|
);
|
|
879
2866
|
}),
|
|
880
|
-
|
|
2867
|
+
e.nowTopPct != null && /* @__PURE__ */ u("div", { "data-rsv": "now-indicator", style: `top:${e.nowTopPct}%` })
|
|
881
2868
|
]
|
|
882
2869
|
},
|
|
883
|
-
|
|
2870
|
+
a.row.resource.id
|
|
884
2871
|
))
|
|
885
2872
|
] })
|
|
886
2873
|
] });
|
|
887
2874
|
}
|
|
888
|
-
function
|
|
889
|
-
return /* @__PURE__ */
|
|
890
|
-
/* @__PURE__ */
|
|
891
|
-
/* @__PURE__ */
|
|
2875
|
+
function ln({ api: t, model: e }) {
|
|
2876
|
+
return /* @__PURE__ */ C("div", { "data-rsv": "resource-daygrid", style: `--rsv-rdg-cols:${e.columns.length}`, children: [
|
|
2877
|
+
/* @__PURE__ */ u("div", { "data-rsv": "rdg-header", role: "row", children: e.columns.map((r) => /* @__PURE__ */ u("div", { "data-rsv": "rdg-col-header", role: "columnheader", children: r.row.resource.title }, r.row.resource.id)) }),
|
|
2878
|
+
/* @__PURE__ */ u("div", { "data-rsv": "rdg-body", role: "row", children: e.columns.map((r) => /* @__PURE__ */ u(
|
|
892
2879
|
"div",
|
|
893
2880
|
{
|
|
894
2881
|
"data-rsv": "rdg-col",
|
|
895
2882
|
"data-rsv-resource-id": r.row.resource.id,
|
|
896
|
-
children: r.events.map((
|
|
2883
|
+
children: r.events.map((n) => /* @__PURE__ */ C(
|
|
897
2884
|
"div",
|
|
898
2885
|
{
|
|
899
2886
|
"data-rsv": "event",
|
|
900
|
-
"data-all-day": String(
|
|
901
|
-
"data-event-id":
|
|
2887
|
+
"data-all-day": String(n.allDay),
|
|
2888
|
+
"data-event-id": n.id,
|
|
902
2889
|
role: "button",
|
|
903
2890
|
tabIndex: 0,
|
|
904
|
-
style: `--rsv-event-bg:${
|
|
905
|
-
onClick: () =>
|
|
2891
|
+
style: `--rsv-event-bg:${n.backgroundColor};--rsv-event-fg:${n.textColor};--rsv-event-border:${n.borderColor}`,
|
|
2892
|
+
onClick: (a) => t.trigger("eventClick", { event: n, el: a.currentTarget }),
|
|
906
2893
|
children: [
|
|
907
|
-
|
|
908
|
-
|
|
2894
|
+
n.allDay ? "" : g.format(n.start, "HH:mm") + " ",
|
|
2895
|
+
n.title
|
|
909
2896
|
]
|
|
910
2897
|
},
|
|
911
|
-
|
|
2898
|
+
n.id
|
|
912
2899
|
))
|
|
913
2900
|
},
|
|
914
2901
|
r.row.resource.id
|
|
915
2902
|
)) })
|
|
916
2903
|
] });
|
|
917
2904
|
}
|
|
918
|
-
function
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
2905
|
+
function cn({ api: t, model: e, options: r }) {
|
|
2906
|
+
return /* @__PURE__ */ u("div", { "data-rsv": "resource-daygrid-month", style: `--rsv-rdgm-cols:${e.columnCount}`, children: e.weeks.map((n, a) => /* @__PURE__ */ u("div", { "data-rsv": "rdgm-week", role: "row", children: n.days.map((o) => /* @__PURE__ */ u(
|
|
2907
|
+
un,
|
|
2908
|
+
{
|
|
2909
|
+
api: t,
|
|
2910
|
+
cell: o,
|
|
2911
|
+
options: r
|
|
2912
|
+
},
|
|
2913
|
+
g.toISOString(o.date)
|
|
2914
|
+
)) }, `week-${a}`)) });
|
|
2915
|
+
}
|
|
2916
|
+
function un({
|
|
2917
|
+
api: t,
|
|
2918
|
+
cell: e,
|
|
2919
|
+
options: r
|
|
2920
|
+
}) {
|
|
2921
|
+
const n = g.dayOfMonth(e.date);
|
|
2922
|
+
return /* @__PURE__ */ C(
|
|
2923
|
+
"div",
|
|
2924
|
+
{
|
|
2925
|
+
"data-rsv": "day",
|
|
2926
|
+
role: "gridcell",
|
|
2927
|
+
"data-date": g.toISOString(e.date),
|
|
2928
|
+
"data-today": String(e.isToday),
|
|
2929
|
+
"data-other": String(e.isOther),
|
|
2930
|
+
children: [
|
|
2931
|
+
/* @__PURE__ */ u("span", { "data-rsv": "day-number", children: n }),
|
|
2932
|
+
/* @__PURE__ */ u("div", { "data-rsv": "rdgm-columns", children: e.columns.map((a) => /* @__PURE__ */ C("div", { "data-rsv": "rdgm-col", "data-rsv-resource-id": a.row.resource.id, children: [
|
|
2933
|
+
/* @__PURE__ */ u("span", { "data-rsv": "rdgm-col-label", children: a.row.resource.title }),
|
|
2934
|
+
a.events.map((o) => {
|
|
2935
|
+
const d = t.selectedEventIds.value.has(o.id);
|
|
2936
|
+
return /* @__PURE__ */ C(
|
|
2937
|
+
"div",
|
|
2938
|
+
{
|
|
2939
|
+
"data-rsv": "event",
|
|
2940
|
+
"data-all-day": String(o.allDay),
|
|
2941
|
+
"data-event-id": o.id,
|
|
2942
|
+
"data-rsv-selected": String(d),
|
|
2943
|
+
role: "button",
|
|
2944
|
+
tabIndex: 0,
|
|
2945
|
+
style: `--rsv-event-bg:${o.backgroundColor};--rsv-event-fg:${o.textColor};--rsv-event-border:${o.borderColor}`,
|
|
2946
|
+
onClick: (i) => {
|
|
2947
|
+
if (i.stopPropagation(), i.ctrlKey || i.metaKey) {
|
|
2948
|
+
t.toggleEventSelection(o.id);
|
|
2949
|
+
return;
|
|
2950
|
+
}
|
|
2951
|
+
t.trigger("eventClick", { event: o, el: i.currentTarget }), o.url && window.open(o.url, "_self");
|
|
2952
|
+
},
|
|
2953
|
+
children: [
|
|
2954
|
+
o.allDay ? "" : `${g.format(o.start, "HH:mm")} `,
|
|
2955
|
+
o.title
|
|
2956
|
+
]
|
|
2957
|
+
},
|
|
2958
|
+
o.id
|
|
2959
|
+
);
|
|
2960
|
+
}),
|
|
2961
|
+
a.moreCount > 0 && /* @__PURE__ */ u(
|
|
2962
|
+
"span",
|
|
2963
|
+
{
|
|
2964
|
+
"data-rsv": "rdgm-more",
|
|
2965
|
+
onClick: (o) => {
|
|
2966
|
+
o.stopPropagation(), t.trigger("moreLinkClick", {
|
|
2967
|
+
date: e.date,
|
|
2968
|
+
allEvents: [...a.events, ...a.hiddenEvents],
|
|
2969
|
+
hiddenEvents: a.hiddenEvents
|
|
2970
|
+
});
|
|
2971
|
+
},
|
|
2972
|
+
children: W(r.locale).more(a.moreCount)
|
|
2973
|
+
}
|
|
2974
|
+
)
|
|
2975
|
+
] }, a.row.resource.id)) })
|
|
2976
|
+
]
|
|
2977
|
+
}
|
|
2978
|
+
);
|
|
2979
|
+
}
|
|
2980
|
+
function vn({ api: t, options: e }) {
|
|
2981
|
+
var l;
|
|
2982
|
+
const r = t.viewModel.value, n = e.direction ?? W(e.locale).direction, a = t.getEffectiveOption("hourHeight", r.type), o = t.getEffectiveOption("height", r.type), d = [
|
|
2983
|
+
e.themeTokens ? Ie(e.themeTokens) : "",
|
|
2984
|
+
a ? `${Ae.slotHeight}:${a}px` : "",
|
|
2985
|
+
o != null && o !== "auto" ? `height:${typeof o == "number" ? `${o}px` : o}` : ""
|
|
2986
|
+
].filter(Boolean).join(";") || void 0, i = F(null);
|
|
2987
|
+
H(() => (t.setRootEl(i.current), () => t.setRootEl(null)), [t]);
|
|
2988
|
+
const s = F(e.responsiveViews);
|
|
2989
|
+
return s.current = e.responsiveViews, H(() => {
|
|
2990
|
+
const c = i.current;
|
|
2991
|
+
if (!c || typeof ResizeObserver > "u") return;
|
|
2992
|
+
let y = 0;
|
|
2993
|
+
const T = new ResizeObserver((v) => {
|
|
2994
|
+
const f = v[0], p = (f == null ? void 0 : f.contentRect.width) ?? c.clientWidth;
|
|
2995
|
+
cancelAnimationFrame(y), y = requestAnimationFrame(() => {
|
|
2996
|
+
const h = s.current;
|
|
2997
|
+
if (!(h != null && h.length)) return;
|
|
2998
|
+
const w = Le(h, p);
|
|
2999
|
+
w && w !== t.getView().type && t.hasView(w) && t.changeView(w);
|
|
3000
|
+
});
|
|
3001
|
+
});
|
|
3002
|
+
return T.observe(c), () => {
|
|
3003
|
+
cancelAnimationFrame(y), T.disconnect();
|
|
3004
|
+
};
|
|
3005
|
+
}, [t]), /* @__PURE__ */ C(
|
|
922
3006
|
"div",
|
|
923
3007
|
{
|
|
3008
|
+
ref: i,
|
|
924
3009
|
"data-rsv": "root",
|
|
925
|
-
dir:
|
|
926
|
-
"data-rsv-theme":
|
|
927
|
-
|
|
928
|
-
|
|
3010
|
+
dir: n,
|
|
3011
|
+
"data-rsv-theme": e.theme,
|
|
3012
|
+
"data-rsv-autoheight": o === "auto" ? "true" : void 0,
|
|
3013
|
+
style: d,
|
|
3014
|
+
class: K((l = e.classNames) == null ? void 0 : l.root),
|
|
929
3015
|
children: [
|
|
930
|
-
|
|
931
|
-
/* @__PURE__ */
|
|
3016
|
+
e.headerToolbar !== !1 && /* @__PURE__ */ u(Ve, { api: t, title: r.title, activeView: r.type, options: e }),
|
|
3017
|
+
/* @__PURE__ */ u("div", { "data-rsv": "view", "data-view": r.type, children: r.dayGrid ? /* @__PURE__ */ u(De, { api: t, model: r.dayGrid, options: e }) : r.timeGrid ? /* @__PURE__ */ u(tn, { api: t, model: r.timeGrid, options: e }) : r.list ? /* @__PURE__ */ u(rn, { api: t, model: r.list, options: e }) : r.multiMonth ? /* @__PURE__ */ u(nn, { api: t, model: r.multiMonth, options: e }) : r.resourceTimeGrid ? /* @__PURE__ */ u(dn, { api: t, model: r.resourceTimeGrid, options: e }) : r.resourceDayGrid ? /* @__PURE__ */ u(ln, { api: t, model: r.resourceDayGrid, options: e }) : r.resourceDayGridMonth ? /* @__PURE__ */ u(cn, { api: t, model: r.resourceDayGridMonth, options: e }) : r.resourceTimeline ? /* @__PURE__ */ u(sn, { api: t, model: r.resourceTimeline, options: e }) : r.timeline ? /* @__PURE__ */ u(an, { api: t, model: r.timeline, options: e }) : /* @__PURE__ */ C("div", { "data-rsv": "unsupported", children: [
|
|
932
3018
|
'La vista "',
|
|
933
3019
|
r.type,
|
|
934
3020
|
'" se implementa en una fase posterior.'
|
|
@@ -937,47 +3023,54 @@ function Gt({ api: a, options: t }) {
|
|
|
937
3023
|
}
|
|
938
3024
|
);
|
|
939
3025
|
}
|
|
940
|
-
function
|
|
941
|
-
const r = new
|
|
942
|
-
return
|
|
3026
|
+
function bn(t, e) {
|
|
3027
|
+
const r = new $e(e);
|
|
3028
|
+
return At(ke(vn, { api: r, options: e }), t), {
|
|
943
3029
|
api: r,
|
|
944
3030
|
destroy() {
|
|
945
|
-
|
|
3031
|
+
At(null, t), r.destroy();
|
|
946
3032
|
}
|
|
947
3033
|
};
|
|
948
3034
|
}
|
|
949
|
-
function
|
|
3035
|
+
function wn(t, e = "calendar.ics") {
|
|
950
3036
|
if (typeof document > "u") return;
|
|
951
|
-
const r =
|
|
952
|
-
|
|
3037
|
+
const r = je(t), n = new Blob([r], { type: "text/calendar;charset=utf-8" }), a = URL.createObjectURL(n), o = document.createElement("a");
|
|
3038
|
+
o.href = a, o.download = e, document.body.appendChild(o), o.click(), o.remove(), URL.revokeObjectURL(a);
|
|
953
3039
|
}
|
|
954
3040
|
export {
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
|
|
959
|
-
|
|
960
|
-
|
|
961
|
-
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
3041
|
+
vn as Calendar,
|
|
3042
|
+
De as DayGridView,
|
|
3043
|
+
rn as ListView,
|
|
3044
|
+
nn as MultiMonthView,
|
|
3045
|
+
ln as ResourceDayGridView,
|
|
3046
|
+
dn as ResourceTimeGridView,
|
|
3047
|
+
sn as ResourceTimelineView,
|
|
3048
|
+
tn as TimeGridView,
|
|
3049
|
+
an as TimelineView,
|
|
3050
|
+
Ve as Toolbar,
|
|
3051
|
+
U as callDidMount,
|
|
3052
|
+
K as cx,
|
|
3053
|
+
dt as dateFormatter,
|
|
3054
|
+
On as dayGridPlugin,
|
|
3055
|
+
Tn as definePlugin,
|
|
3056
|
+
En as defineTheme,
|
|
3057
|
+
wn as downloadICS,
|
|
3058
|
+
Mn as eventsToICS,
|
|
3059
|
+
re as handleEventKeydown,
|
|
3060
|
+
hn as hostSlot,
|
|
3061
|
+
Fe as isHostSlot,
|
|
3062
|
+
Cn as listPlugin,
|
|
3063
|
+
We as minutesToLabel,
|
|
3064
|
+
Ge as minutesToTimeString,
|
|
3065
|
+
bn as mount,
|
|
3066
|
+
kn as multiMonthPlugin,
|
|
3067
|
+
xn as parseICS,
|
|
3068
|
+
B as renderSlot,
|
|
3069
|
+
Pn as resourcePlugin,
|
|
3070
|
+
te as startEventDrag,
|
|
3071
|
+
An as themeToStyle,
|
|
3072
|
+
ct as timeFormatter,
|
|
3073
|
+
In as timeGridPlugin,
|
|
3074
|
+
$n as timelinePlugin
|
|
982
3075
|
};
|
|
983
3076
|
//# sourceMappingURL=index.js.map
|