@dotss/tictoccroc 0.0.2 → 0.0.3
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/LessonNotesSection-Bg1DHFxg.js +208 -0
- package/dist/index.mjs +102 -100
- package/dist/shared/components/Carousel/Carousel.mjs +87 -82
- package/dist/shared/components/Masonry/Masonry.mjs +157 -139
- package/dist/shared/components/Masonry/Masonry.utils.d.ts +5 -1
- package/dist/shared/components/Masonry/Masonry.utils.mjs +53 -52
- package/dist/shared/components/Masonry/MasonryBlock/MasonryBlock.d.ts +5 -0
- package/dist/shared/components/Masonry/MasonryBlock/MasonryBlock.mjs +93 -59
- package/dist/shared/components/MediaDialog/MediaBlock/MediaBlock.d.ts +9 -0
- package/dist/shared/components/MediaDialog/MediaBlock/MediaBlock.mjs +70 -0
- package/dist/shared/components/MediaDialog/MediaBlock/index.d.ts +2 -0
- package/dist/shared/components/MediaDialog/MediaBlock/index.mjs +4 -0
- package/dist/shared/components/MediaDialog/MediaDialog.d.ts +13 -0
- package/dist/shared/components/MediaDialog/MediaDialog.mjs +327 -0
- package/dist/shared/components/MediaDialog/MediaDialogContent/MediaDialogContent.d.ts +3 -0
- package/dist/shared/components/{ImageZoomDialog/ImageZoomDialogContent/ImageZoomDialogContent.mjs → MediaDialog/MediaDialogContent/MediaDialogContent.mjs} +2 -2
- package/dist/shared/components/MediaDialog/MediaDialogContent/index.d.ts +2 -0
- package/dist/shared/components/MediaDialog/MediaDialogContent/index.mjs +4 -0
- package/dist/shared/components/MediaDialog/MediaDialogFooter/MediaDialogFooter.d.ts +3 -0
- package/dist/shared/components/MediaDialog/MediaDialogFooter/index.d.ts +2 -0
- package/dist/shared/components/MediaDialog/MediaDialogFooter/index.mjs +4 -0
- package/dist/shared/components/MediaDialog/MediaDialogToolbar/MediaDialogToolbar.d.ts +3 -0
- package/dist/shared/components/{ImageZoomDialog/ImageZoomDialogToolbar/ImageZoomDialogToolbar.mjs → MediaDialog/MediaDialogToolbar/MediaDialogToolbar.mjs} +6 -6
- package/dist/shared/components/MediaDialog/MediaDialogToolbar/index.d.ts +2 -0
- package/dist/shared/components/MediaDialog/MediaDialogToolbar/index.mjs +4 -0
- package/dist/shared/components/MediaDialog/index.d.ts +7 -0
- package/dist/shared/components/MediaDialog/index.mjs +12 -0
- package/dist/shared/components/Roller/Roller.d.ts +1 -1
- package/dist/shared/components/Roller/Roller.mjs +1 -1
- package/dist/shared/components/Roller/index.mjs +1 -1
- package/dist/shared/components/Scheduler/ScheduleEvent/ScheduleEvent.mjs +1 -1
- package/dist/shared/components/Scheduler/Scheduler.d.ts +2 -1
- package/dist/shared/components/Scheduler/Scheduler.mjs +224 -220
- package/dist/shared/components/Swiper/Swiper.mjs +53 -62
- package/dist/shared/components/index.d.ts +2 -2
- package/dist/shared/components/index.mjs +36 -34
- package/dist/teacher/profile/components/AbilityCollection/AbilityBadge/AbilityBadge.mjs +49 -47
- package/dist/teacher/profile/components/AbilityCollection/AbilityCollection.mjs +27 -28
- package/dist/teacher/profile/components/AbilityCollection/AbilityCollection.utils.mjs +2 -2
- package/dist/teacher/profile/components/ActivityGallery/ActivityGallery.mjs +52 -47
- package/dist/teacher/profile/components/ActivityGallery/ActivityGalleryItem/ActivityGalleryItem.d.ts +3 -2
- package/dist/teacher/profile/components/ActivityGallery/ActivityGalleryItem/ActivityGalleryItem.mjs +33 -61
- package/dist/teacher/profile/components/AvailableScheduleSection/AvailableScheduleSection.mjs +38 -24
- package/dist/teacher/profile/components/CareerSection/CareerSection.d.ts +2 -2
- package/dist/teacher/profile/components/CareerSection/CareerSection.mjs +2 -2
- package/dist/teacher/profile/components/CertificationSection/CertificationSection.d.ts +2 -2
- package/dist/teacher/profile/components/CertificationSection/CertificationSection.mjs +2 -2
- package/dist/teacher/profile/components/EducationSection/EducationSection.d.ts +2 -2
- package/dist/teacher/profile/components/EducationSection/EducationSection.mjs +2 -2
- package/dist/teacher/profile/components/LessonNotesSection/LessonNotesSection.mjs +1 -1
- package/dist/teacher/profile/components/LessonNotesSection/index.mjs +1 -1
- package/dist/teacher/profile/components/index.mjs +1 -1
- package/package.json +1 -1
- package/dist/LessonNotesSection-a2QNdQtj.js +0 -196
- package/dist/shared/components/ImageZoomDialog/ImageBlock/ImageBlock.d.ts +0 -8
- package/dist/shared/components/ImageZoomDialog/ImageBlock/ImageBlock.mjs +0 -36
- package/dist/shared/components/ImageZoomDialog/ImageBlock/index.d.ts +0 -2
- package/dist/shared/components/ImageZoomDialog/ImageBlock/index.mjs +0 -4
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialog.d.ts +0 -16
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialog.mjs +0 -323
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogContent/ImageZoomDialogContent.d.ts +0 -3
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogContent/index.d.ts +0 -2
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogContent/index.mjs +0 -4
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogFooter/ImageZoomDialogFooter.d.ts +0 -3
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogFooter/index.d.ts +0 -2
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogFooter/index.mjs +0 -4
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogToolbar/ImageZoomDialogToolbar.d.ts +0 -3
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogToolbar/index.d.ts +0 -2
- package/dist/shared/components/ImageZoomDialog/ImageZoomDialogToolbar/index.mjs +0 -4
- package/dist/shared/components/ImageZoomDialog/index.d.ts +0 -6
- package/dist/shared/components/ImageZoomDialog/index.mjs +0 -10
- /package/dist/shared/components/{ImageZoomDialog/ImageZoomDialogFooter/ImageZoomDialogFooter.mjs → MediaDialog/MediaDialogFooter/MediaDialogFooter.mjs} +0 -0
|
@@ -1,31 +1,32 @@
|
|
|
1
|
-
import { jsxs as
|
|
2
|
-
import { useState as j, useRef as d, Children as
|
|
3
|
-
import { Flexbox as
|
|
4
|
-
import
|
|
1
|
+
import { jsxs as R, jsx as h } from "react/jsx-runtime";
|
|
2
|
+
import { useState as j, useRef as d, Children as ke, isValidElement as Ee, useEffect as N, cloneElement as fe } from "react";
|
|
3
|
+
import { Flexbox as m, Box as me, Typography as C } from "@dotss/ui";
|
|
4
|
+
import Se from "@dotss/ui/core/useTheme";
|
|
5
5
|
import v from "dayjs";
|
|
6
|
-
import
|
|
7
|
-
import { generateWeek as
|
|
8
|
-
const
|
|
9
|
-
const y = Math.floor((W + 14) / 2) % 24, $ = (W + 14) % 2 === 0 ? "00" : "30", T = v().hour(y).minute(parseInt($)),
|
|
6
|
+
import Le from "./ScheduleEvent/ScheduleEvent.mjs";
|
|
7
|
+
import { generateWeek as Z, getDayScheduleEvents as Re, resolvePositionedScheduleEventsForDate as Ae, getMinutesFromMidnight as he } from "./Scheduler.utils.mjs";
|
|
8
|
+
const A = Array.from({ length: 34 }).map((O, W) => {
|
|
9
|
+
const y = Math.floor((W + 14) / 2) % 24, $ = (W + 14) % 2 === 0 ? "00" : "30", T = v().hour(y).minute(parseInt($)), D = v(), G = D.hour(), U = D.minute(), S = G === y && (U < 30 && $ === "00" || U >= 30 && $ === "30");
|
|
10
10
|
return {
|
|
11
11
|
time: T.format("HH:mm"),
|
|
12
12
|
label: T.format("A h시 m분"),
|
|
13
|
-
isCurrentTime:
|
|
13
|
+
isCurrentTime: S
|
|
14
14
|
};
|
|
15
15
|
});
|
|
16
|
-
function
|
|
17
|
-
children:
|
|
16
|
+
function He({
|
|
17
|
+
children: O,
|
|
18
18
|
date: W = v(),
|
|
19
19
|
legend: y,
|
|
20
20
|
minScheduleBlockHeight: $ = 20,
|
|
21
21
|
renderScheduleBlock: T,
|
|
22
|
-
onDateChange:
|
|
23
|
-
|
|
22
|
+
onDateChange: D,
|
|
23
|
+
adornment: G,
|
|
24
|
+
...U
|
|
24
25
|
}) {
|
|
25
26
|
const {
|
|
26
|
-
palette: { grey:
|
|
27
|
-
} =
|
|
28
|
-
if (e.type ===
|
|
27
|
+
palette: { grey: S }
|
|
28
|
+
} = Se(), [M, F] = j(W.startOf("week")), [H, pe] = j(20), [Y, w] = j(0), [z, k] = j(0), [ve, we] = j(""), ee = d(null), te = d(null), re = d(null), V = d(null), ne = d(0), oe = d(0), I = d(!1), X = d(!1), q = d(!1), K = d(0), ae = d(0), se = d(0), ie = d(0), _ = d(!1), L = d(null), P = d(0), B = d(0), E = d(0), p = d(null), J = ke.toArray(O).filter(Ee).map((e) => {
|
|
29
|
+
if (e.type === Le) {
|
|
29
30
|
const { startDate: n, endDate: a } = e.props;
|
|
30
31
|
return {
|
|
31
32
|
startDate: n,
|
|
@@ -34,38 +35,38 @@ function Te({
|
|
|
34
35
|
};
|
|
35
36
|
}
|
|
36
37
|
return null;
|
|
37
|
-
}).filter(Boolean),
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
],
|
|
38
|
+
}).filter(Boolean), ce = [
|
|
39
|
+
Z(M.subtract(1, "week"), J),
|
|
40
|
+
Z(M, J),
|
|
41
|
+
Z(M.add(1, "week"), J)
|
|
42
|
+
], le = (e, n) => (a) => {
|
|
42
43
|
const o = Number(a.currentTarget.dataset.row), i = Number(a.currentTarget.dataset.col);
|
|
43
|
-
w(o),
|
|
44
|
-
},
|
|
44
|
+
w(o), k(i), we(`${e.format("dddd")} ${e.format("D")}일 ${n}`);
|
|
45
|
+
}, ue = (e) => {
|
|
45
46
|
var g, b;
|
|
46
47
|
const n = Number(e.currentTarget.dataset.row), a = Number(e.currentTarget.dataset.col);
|
|
47
48
|
let o = n, i = a;
|
|
48
49
|
switch (e.key) {
|
|
49
50
|
case "ArrowUp": {
|
|
50
|
-
e.preventDefault(), n === 0 && (a - 1 < 0 ? (F((t) => t.add(-1, "week")), w(
|
|
51
|
+
e.preventDefault(), n === 0 && (a - 1 < 0 ? (F((t) => t.add(-1, "week")), w(A.length - 1), k(6), E.current = requestAnimationFrame(() => {
|
|
51
52
|
var t, r;
|
|
52
53
|
(r = (t = p.current) == null ? void 0 : t.querySelector(
|
|
53
|
-
`[data-row="${
|
|
54
|
+
`[data-row="${A.length - 1}"][data-col="6"][data-week="1"]`
|
|
54
55
|
)) == null || r.focus();
|
|
55
|
-
})) : (w(
|
|
56
|
+
})) : (w(A.length - 1), k(a - 1), E.current = requestAnimationFrame(() => {
|
|
56
57
|
var t, r;
|
|
57
58
|
(r = (t = p.current) == null ? void 0 : t.querySelector(
|
|
58
|
-
`[data-row="${
|
|
59
|
+
`[data-row="${A.length - 1}"][data-col="${a - 1}"][data-week="1"]`
|
|
59
60
|
)) == null || r.focus();
|
|
60
61
|
}))), o = Math.max(n - 1, 0);
|
|
61
62
|
break;
|
|
62
63
|
}
|
|
63
64
|
case "ArrowDown": {
|
|
64
|
-
if (e.preventDefault(), n ===
|
|
65
|
-
a + 1 > 6 ? (F((t) => t.add(1, "week")), w(0),
|
|
65
|
+
if (e.preventDefault(), n === A.length - 1) {
|
|
66
|
+
a + 1 > 6 ? (F((t) => t.add(1, "week")), w(0), k(0), E.current = requestAnimationFrame(() => {
|
|
66
67
|
var t, r;
|
|
67
68
|
(r = (t = p.current) == null ? void 0 : t.querySelector('[data-row="0"][data-col="0"][data-week="1"]')) == null || r.focus();
|
|
68
|
-
})) : (w(0),
|
|
69
|
+
})) : (w(0), k(i + 1), E.current = requestAnimationFrame(() => {
|
|
69
70
|
var t, r;
|
|
70
71
|
(r = (t = p.current) == null ? void 0 : t.querySelector(
|
|
71
72
|
`[data-row="0"][data-col="${i + 1}"][data-week="1"]`
|
|
@@ -73,12 +74,12 @@ function Te({
|
|
|
73
74
|
}));
|
|
74
75
|
return;
|
|
75
76
|
}
|
|
76
|
-
o = Math.min(n + 1,
|
|
77
|
+
o = Math.min(n + 1, A.length - 1);
|
|
77
78
|
break;
|
|
78
79
|
}
|
|
79
80
|
case "ArrowLeft": {
|
|
80
81
|
if (e.preventDefault(), a === 0) {
|
|
81
|
-
F((s) => s.add(-1, "week")), w(o),
|
|
82
|
+
F((s) => s.add(-1, "week")), w(o), k(6), E.current = requestAnimationFrame(() => {
|
|
82
83
|
var s, t;
|
|
83
84
|
(t = (s = p.current) == null ? void 0 : s.querySelector(`[data-row="${o}"][data-col="6"][data-week="1"]`)) == null || t.focus();
|
|
84
85
|
});
|
|
@@ -89,7 +90,7 @@ function Te({
|
|
|
89
90
|
}
|
|
90
91
|
case "ArrowRight": {
|
|
91
92
|
if (e.preventDefault(), a === 6) {
|
|
92
|
-
F((s) => s.add(1, "week")), w(o),
|
|
93
|
+
F((s) => s.add(1, "week")), w(o), k(0), E.current = requestAnimationFrame(() => {
|
|
93
94
|
var s, t;
|
|
94
95
|
(t = (s = p.current) == null ? void 0 : s.querySelector(`[data-row="${o}"][data-col="0"][data-week="1"]`)) == null || t.focus();
|
|
95
96
|
});
|
|
@@ -105,8 +106,8 @@ function Te({
|
|
|
105
106
|
e.preventDefault(), e.currentTarget.click();
|
|
106
107
|
break;
|
|
107
108
|
}
|
|
108
|
-
w(o),
|
|
109
|
-
},
|
|
109
|
+
w(o), k(i), (b = (g = p.current) == null ? void 0 : g.querySelector(`[data-row="${o}"][data-col="${i}"][data-week="1"]`)) == null || b.focus();
|
|
110
|
+
}, ge = (e) => (n) => {
|
|
110
111
|
var i, g, b, l, s, t;
|
|
111
112
|
const a = n.currentTarget.dataset.startDate, o = n.currentTarget.dataset.endDate;
|
|
112
113
|
if (!(!a || !o)) {
|
|
@@ -137,7 +138,7 @@ function Te({
|
|
|
137
138
|
r.focus();
|
|
138
139
|
else {
|
|
139
140
|
if (z === 0) {
|
|
140
|
-
F((f) => f.add(-1, "week")), w(0),
|
|
141
|
+
F((f) => f.add(-1, "week")), w(0), k(6), E.current = requestAnimationFrame(() => {
|
|
141
142
|
var f, x;
|
|
142
143
|
(x = (f = p.current) == null ? void 0 : f.querySelector('[data-row="0"][data-col="6"][data-week="1"]')) == null || x.focus();
|
|
143
144
|
});
|
|
@@ -156,7 +157,7 @@ function Te({
|
|
|
156
157
|
r.focus();
|
|
157
158
|
else {
|
|
158
159
|
if (z === 6) {
|
|
159
|
-
F((f) => f.add(1, "week")), w(0),
|
|
160
|
+
F((f) => f.add(1, "week")), w(0), k(0), E.current = requestAnimationFrame(() => {
|
|
160
161
|
var f, x;
|
|
161
162
|
(x = (f = p.current) == null ? void 0 : f.querySelector('[data-row="0"][data-col="0"][data-week="1"]')) == null || x.focus();
|
|
162
163
|
});
|
|
@@ -189,9 +190,9 @@ function Te({
|
|
|
189
190
|
return N(() => {
|
|
190
191
|
const e = () => {
|
|
191
192
|
var n, a, o;
|
|
192
|
-
if (
|
|
193
|
-
const i = ((a = (n =
|
|
194
|
-
|
|
193
|
+
if (V.current) {
|
|
194
|
+
const i = ((a = (n = ee.current) == null ? void 0 : n.parentElement) == null ? void 0 : a.offsetHeight) ?? 0, g = V.current.offsetHeight, b = ((o = re.current) == null ? void 0 : o.offsetHeight) ?? 0, l = (i - g - b) / A.length;
|
|
195
|
+
pe(
|
|
195
196
|
l < $ ? $ : l
|
|
196
197
|
);
|
|
197
198
|
}
|
|
@@ -200,35 +201,35 @@ function Te({
|
|
|
200
201
|
window.removeEventListener("resize", e);
|
|
201
202
|
};
|
|
202
203
|
}, [$, y]), N(() => {
|
|
203
|
-
const e =
|
|
204
|
+
const e = te.current;
|
|
204
205
|
if (!e) return;
|
|
205
206
|
const n = () => {
|
|
206
|
-
|
|
207
|
+
ae.current = e.offsetWidth;
|
|
207
208
|
};
|
|
208
209
|
n();
|
|
209
210
|
const a = (t, r) => {
|
|
210
|
-
q.current || (L.current && (e.removeEventListener("transitionend", L.current), L.current = null),
|
|
211
|
+
q.current || (L.current && (e.removeEventListener("transitionend", L.current), L.current = null), ne.current = t, oe.current = r, _.current = !1, I.current = !0, K.current = 0);
|
|
211
212
|
}, o = (t, r, u) => {
|
|
212
213
|
if (!I.current) return;
|
|
213
|
-
const c = t -
|
|
214
|
-
if (
|
|
214
|
+
const c = t - ne.current, f = r - oe.current;
|
|
215
|
+
if (K.current = c, !_.current && (se.current = Math.abs(c), ie.current = Math.abs(f), _.current = !0, ie.current > se.current)) {
|
|
215
216
|
I.current = !1;
|
|
216
217
|
return;
|
|
217
218
|
}
|
|
218
|
-
u.cancelable && u.preventDefault(), e.style.transition = "none", e.style.transform = `translate3d(${
|
|
219
|
+
u.cancelable && u.preventDefault(), e.style.transition = "none", e.style.transform = `translate3d(${K.current}px, 0, 0)`, e.style.cursor = "grabbing";
|
|
219
220
|
}, i = () => {
|
|
220
221
|
if (e.style.cursor = "grab", !I.current) return;
|
|
221
222
|
I.current = !1, X.current = !1, q.current = !0;
|
|
222
|
-
const t =
|
|
223
|
+
const t = K.current, r = ae.current, u = r * 0.2;
|
|
223
224
|
e.style.transition = "transform 300ms cubic-bezier(0.25, 1, 0.5, 1)", t > u ? (e.style.transform = `translate3d(${r}px, 0, 0)`, L.current = (c) => {
|
|
224
|
-
c.propertyName === "transform" && (
|
|
225
|
-
F((f) => f.add(-1, "week")),
|
|
225
|
+
c.propertyName === "transform" && (P.current = requestAnimationFrame(() => {
|
|
226
|
+
F((f) => f.add(-1, "week")), B.current = requestAnimationFrame(() => {
|
|
226
227
|
e.style.transition = "none", e.style.transform = "translate3d(0, 0, 0)", X.current = !0, q.current = !1;
|
|
227
228
|
});
|
|
228
229
|
}));
|
|
229
230
|
}, e.addEventListener("transitionend", L.current)) : t < -u ? (e.style.transform = `translate3d(-${r}px, 0, 0)`, L.current = (c) => {
|
|
230
|
-
c.propertyName === "transform" && (
|
|
231
|
-
F((f) => f.add(1, "week")),
|
|
231
|
+
c.propertyName === "transform" && (P.current = requestAnimationFrame(() => {
|
|
232
|
+
F((f) => f.add(1, "week")), B.current = requestAnimationFrame(() => {
|
|
232
233
|
e.style.transition = "none", e.style.transform = "translate3d(0, 0, 0)", X.current = !0, q.current = !1;
|
|
233
234
|
});
|
|
234
235
|
}));
|
|
@@ -245,14 +246,14 @@ function Te({
|
|
|
245
246
|
e == null || e.removeEventListener("click", n);
|
|
246
247
|
};
|
|
247
248
|
}, []), N(() => {
|
|
248
|
-
|
|
249
|
-
}, [
|
|
250
|
-
|
|
251
|
-
}, []), /* @__PURE__ */
|
|
252
|
-
y && (y == null ? void 0 : y.length) > 0 && /* @__PURE__ */
|
|
253
|
-
|
|
249
|
+
D == null || D(M);
|
|
250
|
+
}, [M, D]), N(() => () => {
|
|
251
|
+
P.current && cancelAnimationFrame(P.current), B.current && cancelAnimationFrame(B.current), E.current && cancelAnimationFrame(E.current);
|
|
252
|
+
}, []), /* @__PURE__ */ R(m, { ref: ee, flex: 1, flexDirection: "column", "aria-label": "일정 안내", ...U, children: [
|
|
253
|
+
y && (y == null ? void 0 : y.length) > 0 && /* @__PURE__ */ h(
|
|
254
|
+
m,
|
|
254
255
|
{
|
|
255
|
-
ref:
|
|
256
|
+
ref: re,
|
|
256
257
|
justifyContent: "flex-end",
|
|
257
258
|
alignItems: "center",
|
|
258
259
|
gap: 3,
|
|
@@ -260,28 +261,28 @@ function Te({
|
|
|
260
261
|
pr: 4,
|
|
261
262
|
role: "group",
|
|
262
263
|
"aria-label": "일정 종류 안내",
|
|
263
|
-
children: y == null ? void 0 : y.map(({ text: e, color: n }) => /* @__PURE__ */
|
|
264
|
-
/* @__PURE__ */
|
|
265
|
-
|
|
264
|
+
children: y == null ? void 0 : y.map(({ text: e, color: n }) => /* @__PURE__ */ R(m, { alignItems: "center", gap: 1, children: [
|
|
265
|
+
/* @__PURE__ */ h(
|
|
266
|
+
me,
|
|
266
267
|
{
|
|
267
268
|
"aria-hidden": !0,
|
|
268
269
|
inlineCSS: {
|
|
269
270
|
width: 14,
|
|
270
271
|
height: 14,
|
|
271
|
-
border: `1px solid ${
|
|
272
|
+
border: `1px solid ${S[30]}`,
|
|
272
273
|
borderRadius: 4,
|
|
273
274
|
backgroundColor: n
|
|
274
275
|
}
|
|
275
276
|
}
|
|
276
277
|
),
|
|
277
|
-
/* @__PURE__ */
|
|
278
|
+
/* @__PURE__ */ h(C, { variant: "c3R", color: "grey.70", children: e })
|
|
278
279
|
] }, `legend-${e}-${n}`))
|
|
279
280
|
}
|
|
280
281
|
),
|
|
281
|
-
/* @__PURE__ */
|
|
282
|
-
|
|
282
|
+
/* @__PURE__ */ R(
|
|
283
|
+
m,
|
|
283
284
|
{
|
|
284
|
-
ref:
|
|
285
|
+
ref: V,
|
|
285
286
|
alignItems: "center",
|
|
286
287
|
pt: 1,
|
|
287
288
|
pb: 2,
|
|
@@ -290,11 +291,11 @@ function Te({
|
|
|
290
291
|
position: "sticky",
|
|
291
292
|
top: 0,
|
|
292
293
|
zIndex: 2,
|
|
293
|
-
borderBottom: `1px solid ${
|
|
294
|
-
backgroundColor:
|
|
294
|
+
borderBottom: `1px solid ${S[20]}`,
|
|
295
|
+
backgroundColor: S.white
|
|
295
296
|
},
|
|
296
297
|
children: [
|
|
297
|
-
/* @__PURE__ */
|
|
298
|
+
/* @__PURE__ */ R(
|
|
298
299
|
C,
|
|
299
300
|
{
|
|
300
301
|
variant: "h4B",
|
|
@@ -303,13 +304,13 @@ function Te({
|
|
|
303
304
|
width: 48
|
|
304
305
|
},
|
|
305
306
|
children: [
|
|
306
|
-
|
|
307
|
+
M.month() + 1,
|
|
307
308
|
"월"
|
|
308
309
|
]
|
|
309
310
|
}
|
|
310
311
|
),
|
|
311
|
-
/* @__PURE__ */ m
|
|
312
|
-
|
|
312
|
+
/* @__PURE__ */ h(m, { alignItems: "center", flexGrow: 1, children: ce[1].days.map((e) => /* @__PURE__ */ R(
|
|
313
|
+
m,
|
|
313
314
|
{
|
|
314
315
|
flexDirection: "column",
|
|
315
316
|
alignItems: "center",
|
|
@@ -317,8 +318,8 @@ function Te({
|
|
|
317
318
|
role: "columnheader",
|
|
318
319
|
"aria-label": `${e.format("dddd")} (${e.format("D")}일)`,
|
|
319
320
|
children: [
|
|
320
|
-
/* @__PURE__ */
|
|
321
|
-
/* @__PURE__ */
|
|
321
|
+
/* @__PURE__ */ h(C, { variant: "c3R", children: e.format("ddd") }),
|
|
322
|
+
/* @__PURE__ */ h(C, { variant: "c3M", children: e.format("D") })
|
|
322
323
|
]
|
|
323
324
|
},
|
|
324
325
|
e.day()
|
|
@@ -326,21 +327,21 @@ function Te({
|
|
|
326
327
|
]
|
|
327
328
|
}
|
|
328
329
|
),
|
|
329
|
-
/* @__PURE__ */
|
|
330
|
-
/* @__PURE__ */
|
|
331
|
-
|
|
330
|
+
/* @__PURE__ */ R(m, { flex: 1, children: [
|
|
331
|
+
/* @__PURE__ */ R(
|
|
332
|
+
m,
|
|
332
333
|
{
|
|
333
334
|
flexDirection: "column",
|
|
334
335
|
inlineCSS: {
|
|
335
336
|
position: "sticky",
|
|
336
337
|
left: 0,
|
|
337
338
|
maxHeight: "fit-content",
|
|
338
|
-
backgroundColor:
|
|
339
|
+
backgroundColor: S.white,
|
|
339
340
|
zIndex: 1
|
|
340
341
|
},
|
|
341
342
|
children: [
|
|
342
|
-
|
|
343
|
-
|
|
343
|
+
A.map(({ time: e, label: n, isCurrentTime: a }) => /* @__PURE__ */ h(
|
|
344
|
+
m,
|
|
344
345
|
{
|
|
345
346
|
justifyContent: "center",
|
|
346
347
|
alignItems: "flex-start",
|
|
@@ -353,7 +354,7 @@ function Te({
|
|
|
353
354
|
minHeight: $,
|
|
354
355
|
zIndex: 1
|
|
355
356
|
},
|
|
356
|
-
children: /* @__PURE__ */
|
|
357
|
+
children: /* @__PURE__ */ h(
|
|
357
358
|
C,
|
|
358
359
|
{
|
|
359
360
|
variant: "c3M",
|
|
@@ -367,8 +368,8 @@ function Te({
|
|
|
367
368
|
},
|
|
368
369
|
e
|
|
369
370
|
)),
|
|
370
|
-
/* @__PURE__ */
|
|
371
|
-
|
|
371
|
+
/* @__PURE__ */ h(
|
|
372
|
+
m,
|
|
372
373
|
{
|
|
373
374
|
"aria-hidden": !0,
|
|
374
375
|
inlineCSS: {
|
|
@@ -385,157 +386,160 @@ function Te({
|
|
|
385
386
|
]
|
|
386
387
|
}
|
|
387
388
|
),
|
|
388
|
-
/* @__PURE__ */
|
|
389
|
-
|
|
389
|
+
/* @__PURE__ */ R(
|
|
390
|
+
m,
|
|
390
391
|
{
|
|
391
392
|
flex: 1,
|
|
392
393
|
ref: p,
|
|
393
394
|
role: "grid",
|
|
394
395
|
"aria-label": "주간 일정",
|
|
395
396
|
inlineCSS: { position: "relative", overflow: "hidden", cursor: "grab" },
|
|
396
|
-
children:
|
|
397
|
-
h
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
h
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
g,
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
h
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
onKeyDown: le,
|
|
471
|
-
onFocus: ce(o, s),
|
|
472
|
-
role: "gridcell",
|
|
473
|
-
"data-row": r,
|
|
474
|
-
"data-col": i,
|
|
475
|
-
"data-week": a,
|
|
476
|
-
"data-time": l,
|
|
477
|
-
"aria-current": t ? "time" : void 0,
|
|
478
|
-
tabIndex: u ? 0 : -1,
|
|
479
|
-
"aria-label": `${o.format("dddd")} ${o.format("D")}일 ${s}`,
|
|
480
|
-
style: {
|
|
481
|
-
borderTop: r > 0 ? `1px solid ${k[20]}` : void 0,
|
|
482
|
-
height: H,
|
|
483
|
-
minHeight: $,
|
|
484
|
-
zIndex: 0
|
|
485
|
-
}
|
|
486
|
-
},
|
|
487
|
-
`schedule-block-${o}-${r}-${i}-${l}`
|
|
488
|
-
);
|
|
489
|
-
}),
|
|
490
|
-
b.map(
|
|
491
|
-
({ children: l, startDate: s, endDate: t, totalColumns: r, columnIndex: u }) => {
|
|
492
|
-
const c = me(s), f = me(t), x = Math.floor((c - 7 * 60) / 30), ge = (c - 7 * 60) / 30 * H, be = (f - c) / 30 * H, ue = 100 / r, ye = u * ue, J = l;
|
|
493
|
-
return /* @__PURE__ */ m(
|
|
494
|
-
h,
|
|
397
|
+
children: [
|
|
398
|
+
/* @__PURE__ */ h(
|
|
399
|
+
m,
|
|
400
|
+
{
|
|
401
|
+
ref: te,
|
|
402
|
+
alignItems: "flex-start",
|
|
403
|
+
justifyContent: "center",
|
|
404
|
+
flex: 1,
|
|
405
|
+
inlineCSS: {
|
|
406
|
+
transform: "translate3d(0, 0, 0)"
|
|
407
|
+
},
|
|
408
|
+
children: ce.map(({ days: e, scheduleEvents: n }, a) => /* @__PURE__ */ h(
|
|
409
|
+
m,
|
|
410
|
+
{
|
|
411
|
+
role: "rowgroup",
|
|
412
|
+
"aria-hidden": a !== 1,
|
|
413
|
+
style: {
|
|
414
|
+
display: "grid",
|
|
415
|
+
gridTemplateColumns: "repeat(7, 1fr)",
|
|
416
|
+
minWidth: "100%"
|
|
417
|
+
},
|
|
418
|
+
children: e.map((o, i) => {
|
|
419
|
+
const g = Re(n, o), b = Ae(
|
|
420
|
+
g,
|
|
421
|
+
o
|
|
422
|
+
);
|
|
423
|
+
return /* @__PURE__ */ h(
|
|
424
|
+
m,
|
|
425
|
+
{
|
|
426
|
+
role: "row",
|
|
427
|
+
"aria-label": `${o.format("dddd")} ${o.format("D")}일`,
|
|
428
|
+
style: {
|
|
429
|
+
borderLeft: `1px solid ${S[20]}`
|
|
430
|
+
},
|
|
431
|
+
children: /* @__PURE__ */ R(
|
|
432
|
+
m,
|
|
433
|
+
{
|
|
434
|
+
style: {
|
|
435
|
+
display: "grid",
|
|
436
|
+
position: "relative",
|
|
437
|
+
flex: 1
|
|
438
|
+
},
|
|
439
|
+
children: [
|
|
440
|
+
A.map(({ time: l, label: s, isCurrentTime: t }, r) => {
|
|
441
|
+
const u = a === 1 && r === Y && i === z;
|
|
442
|
+
if (typeof T == "function") {
|
|
443
|
+
const c = T(
|
|
444
|
+
o.format("YYYY-MM-DD"),
|
|
445
|
+
l
|
|
446
|
+
);
|
|
447
|
+
return fe(c, {
|
|
448
|
+
key: `schedule-block-${o}-${r}-${i}-${l}`,
|
|
449
|
+
onKeyDown: ue,
|
|
450
|
+
onFocus: le(o, s),
|
|
451
|
+
role: "gridcell",
|
|
452
|
+
"data-row": r,
|
|
453
|
+
"data-col": i,
|
|
454
|
+
"data-week": a,
|
|
455
|
+
"data-time": l,
|
|
456
|
+
"aria-current": t ? "time" : void 0,
|
|
457
|
+
tabIndex: u ? 0 : -1,
|
|
458
|
+
"aria-label": `${o.format("dddd")} ${o.format("D")}일 ${s}`,
|
|
459
|
+
...c.props,
|
|
460
|
+
style: {
|
|
461
|
+
...c.props.style,
|
|
462
|
+
borderTop: r > 0 ? `1px solid ${S[20]}` : void 0,
|
|
463
|
+
height: H,
|
|
464
|
+
minHeight: $,
|
|
465
|
+
zIndex: 0
|
|
466
|
+
}
|
|
467
|
+
});
|
|
468
|
+
}
|
|
469
|
+
return /* @__PURE__ */ h(
|
|
470
|
+
me,
|
|
495
471
|
{
|
|
472
|
+
onKeyDown: ue,
|
|
473
|
+
onFocus: le(o, s),
|
|
474
|
+
role: "gridcell",
|
|
475
|
+
"data-row": r,
|
|
476
|
+
"data-col": i,
|
|
477
|
+
"data-week": a,
|
|
478
|
+
"data-time": l,
|
|
479
|
+
"aria-current": t ? "time" : void 0,
|
|
480
|
+
tabIndex: u ? 0 : -1,
|
|
481
|
+
"aria-label": `${o.format("dddd")} ${o.format("D")}일 ${s}`,
|
|
496
482
|
style: {
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
zIndex: 1
|
|
503
|
-
},
|
|
504
|
-
children: de(J, {
|
|
505
|
-
role: "button",
|
|
506
|
-
tabIndex: a === 1 ? 0 : -1,
|
|
507
|
-
onKeyDown: we(J.props.onKeyDown),
|
|
508
|
-
"data-start-date": s,
|
|
509
|
-
"data-start-time": v(s).format("HH:mm"),
|
|
510
|
-
"data-end-date": t,
|
|
511
|
-
"data-end-time": v(t).format("HH:mm"),
|
|
512
|
-
"data-is-event": !0,
|
|
513
|
-
"aria-label": `${v(s).format("dddd")} ${v(s).format("D")}일 ${v(s).format("A h시")}부터 ${v(t).format("dddd")} ${v(t).format("D")}일 ${v(t).format("A h시")}까지의 일정`,
|
|
514
|
-
...J.props
|
|
515
|
-
})
|
|
483
|
+
borderTop: r > 0 ? `1px solid ${S[20]}` : void 0,
|
|
484
|
+
height: H,
|
|
485
|
+
minHeight: $,
|
|
486
|
+
zIndex: 0
|
|
487
|
+
}
|
|
516
488
|
},
|
|
517
|
-
|
|
489
|
+
`schedule-block-${o}-${r}-${i}-${l}`
|
|
518
490
|
);
|
|
519
|
-
}
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
491
|
+
}),
|
|
492
|
+
b.map(
|
|
493
|
+
({ children: l, startDate: s, endDate: t, totalColumns: r, columnIndex: u }) => {
|
|
494
|
+
const c = he(s), f = he(t), x = Math.floor((c - 7 * 60) / 30), be = (c - 7 * 60) / 30 * H, ye = (f - c) / 30 * H, de = 100 / r, $e = u * de, Q = l;
|
|
495
|
+
return /* @__PURE__ */ h(
|
|
496
|
+
m,
|
|
497
|
+
{
|
|
498
|
+
style: {
|
|
499
|
+
position: "absolute",
|
|
500
|
+
top: `${be + (x > 0 ? 1 : 0)}px`,
|
|
501
|
+
left: `${$e}%`,
|
|
502
|
+
width: `${de}%`,
|
|
503
|
+
height: `${ye - (x > 0 ? 1 : 0)}px`,
|
|
504
|
+
zIndex: 1
|
|
505
|
+
},
|
|
506
|
+
children: fe(Q, {
|
|
507
|
+
role: "button",
|
|
508
|
+
tabIndex: a === 1 ? 0 : -1,
|
|
509
|
+
onKeyDown: ge(Q.props.onKeyDown),
|
|
510
|
+
"data-start-date": s,
|
|
511
|
+
"data-start-time": v(s).format("HH:mm"),
|
|
512
|
+
"data-end-date": t,
|
|
513
|
+
"data-end-time": v(t).format("HH:mm"),
|
|
514
|
+
"data-is-event": !0,
|
|
515
|
+
"aria-label": `${v(s).format("dddd")} ${v(s).format("D")}일 ${v(s).format("A h시")}부터 ${v(t).format("dddd")} ${v(t).format("D")}일 ${v(t).format("A h시")}까지의 일정`,
|
|
516
|
+
...Q.props
|
|
517
|
+
})
|
|
518
|
+
},
|
|
519
|
+
`${s}-${t}-${u}-${r}`
|
|
520
|
+
);
|
|
521
|
+
}
|
|
522
|
+
)
|
|
523
|
+
]
|
|
524
|
+
}
|
|
525
|
+
)
|
|
526
|
+
},
|
|
527
|
+
o.toISOString()
|
|
528
|
+
);
|
|
529
|
+
})
|
|
530
|
+
},
|
|
531
|
+
e[0].format("YYYY-MM-DD")
|
|
532
|
+
))
|
|
533
|
+
}
|
|
534
|
+
),
|
|
535
|
+
G
|
|
536
|
+
]
|
|
533
537
|
}
|
|
534
538
|
)
|
|
535
539
|
] }),
|
|
536
|
-
/* @__PURE__ */
|
|
540
|
+
/* @__PURE__ */ h(C, { role: "status", visuallyHidden: !0, children: ve })
|
|
537
541
|
] });
|
|
538
542
|
}
|
|
539
543
|
export {
|
|
540
|
-
|
|
544
|
+
He as default
|
|
541
545
|
};
|