@dotss/tictoccroc 0.0.23 → 0.0.24
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/shared/components/ChatKit/BotMessage/BotMessage.d.ts +6 -4
- package/dist/shared/components/ChatKit/BotMessage/BotMessage.mjs +39 -31
- package/dist/shared/components/ChatKit/BotMessage/index.d.ts +2 -2
- package/dist/shared/components/ChatKit/Message/Message.mjs +21 -20
- package/dist/shared/components/Image/Image.d.ts +1 -0
- package/dist/shared/components/Image/Image.mjs +162 -98
- package/dist/shared/components/Masonry/MasonryBlock/MasonryBlock.mjs +86 -89
- package/dist/shared/components/Scheduler/Scheduler.d.ts +4 -1
- package/dist/shared/components/Scheduler/Scheduler.mjs +220 -196
- package/dist/shared/components/Scheduler/Scheduler.utils.d.ts +4 -0
- package/dist/shared/components/Scheduler/Scheduler.utils.mjs +61 -57
- package/dist/shared/utils/dayFlagToDay/dayFlagToDay.d.ts +1 -1
- package/dist/shared/utils/getImageUrl/getImageUrl.d.ts +3 -1
- package/dist/shared/utils/getImageUrl/getImageUrl.mjs +14 -13
- package/dist/teacher/profile/components/ActivityGallery/ActivityGallery.mjs +41 -42
- package/dist/teacher/profile/components/CareerSection/CareerItem/CareerItem.mjs +28 -30
- package/dist/teacher/profile/components/CareerSection/CareerSection.mjs +9 -7
- package/package.json +1 -1
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { FlexboxProps } from 'node_modules/@dotss/ui/Flexbox/Flexbox';
|
|
2
|
-
export type BotMessageType = 'MATCHING_SUCCEEDED' | 'TEACHER_INQUIRED' | 'PARENT_CHANGED_OFFER_SCHEDULE' | 'PARENT_CHANGED_MATCHING_SCHEDULE' | 'TEACHER_APPLIED' | 'PARENT_SENT_OFFER' | 'KOK_MATCHING_SUCCEEDED' | 'APPLICATION_MATCHING_SUCCEEDED' | 'PARENT_REJECTED_APPLICATION' | 'TEACHER_REFUSED_OFFER' | 'PARENT_CANCELED_MATCHING' | 'TEACHER_CANCELED_MATCHING' | 'TEACHER_COMPLETED_CARE' | 'ADMIN_CANCELED_MATCHING';
|
|
2
|
+
export type BotMessageType = 'MATCHING_SUCCEEDED' | 'TEACHER_INQUIRED' | 'PARENT_CHANGED_OFFER_SCHEDULE' | 'PARENT_CHANGED_MATCHING_SCHEDULE' | 'TEACHER_APPLIED' | 'PARENT_SENT_OFFER' | 'KOK_MATCHING_SUCCEEDED' | 'APPLICATION_MATCHING_SUCCEEDED' | 'ASSIGNMENT_MATCHING_SUCCEEDED' | 'PARENT_REJECTED_APPLICATION' | 'TEACHER_REFUSED_OFFER' | 'PARENT_CANCELED_MATCHING' | 'TEACHER_CANCELED_MATCHING' | 'TEACHER_COMPLETED_CARE' | 'ADMIN_CANCELED_MATCHING';
|
|
3
3
|
export type BotMessageCtaType = 'MY_CLASS_CHECK' | 'OFFER_CHECK' | 'CHANGE_INFO_CHECK' | 'MY_APPLICATION_INFO_VIEW' | 'CARE_NOTE_CHECK' | 'TEACHER_SELECTION';
|
|
4
|
-
export type
|
|
4
|
+
export type BotMessageCtaTargetTable = 'OFFER' | 'MATCHING';
|
|
5
|
+
export type BotMessageSubCtaTargetTable = 'OFFER' | 'MATCHING';
|
|
5
6
|
export interface BotMessageOffer {
|
|
6
7
|
careStartDate: string;
|
|
7
8
|
careStartTime: string;
|
|
@@ -14,7 +15,7 @@ export interface BotMessageProps extends Omit<FlexboxProps, 'id' | 'title'> {
|
|
|
14
15
|
id: string | number;
|
|
15
16
|
botMessageType: BotMessageType;
|
|
16
17
|
ctaType?: BotMessageCtaType | null;
|
|
17
|
-
ctaTargetTable?:
|
|
18
|
+
ctaTargetTable?: BotMessageCtaTargetTable | null;
|
|
18
19
|
ctaTargetId?: number | null;
|
|
19
20
|
subCtaTargetTable?: BotMessageSubCtaTargetTable | null;
|
|
20
21
|
subCtaTargetId?: number | null;
|
|
@@ -29,10 +30,11 @@ export interface BotMessageProps extends Omit<FlexboxProps, 'id' | 'title'> {
|
|
|
29
30
|
botMessageType: BotMessageType;
|
|
30
31
|
ctaType?: BotMessageCtaType | null;
|
|
31
32
|
ctaTargetId?: number | null;
|
|
33
|
+
ctaTargetTable?: string | null;
|
|
32
34
|
subCtaTargetTable?: BotMessageSubCtaTargetTable | null;
|
|
33
35
|
subCtaTargetId?: number | null;
|
|
34
36
|
}) => void;
|
|
35
37
|
onView?: () => void;
|
|
36
38
|
}
|
|
37
|
-
declare function BotMessage({ id, botMessageType, ctaType, ctaTargetId, subCtaTargetTable, subCtaTargetId, mine, avatarUrl, title, content, unreadUserCount, offer, regDatetime, onAction, onView, inlineCSS, ...props }: BotMessageProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
39
|
+
declare function BotMessage({ id, botMessageType, ctaType, ctaTargetId, ctaTargetTable, subCtaTargetTable, subCtaTargetId, mine, avatarUrl, title, content, unreadUserCount, offer, regDatetime, onAction, onView, inlineCSS, ...props }: BotMessageProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
38
40
|
export default BotMessage;
|
|
@@ -1,39 +1,47 @@
|
|
|
1
1
|
import { jsxs as t, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { useRef as
|
|
3
|
-
import { Flexbox as n, Typography as e, Button as
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import { getClassInfo as
|
|
7
|
-
import
|
|
8
|
-
import
|
|
2
|
+
import { useRef as F, useEffect as L } from "react";
|
|
3
|
+
import { Flexbox as n, Typography as e, Button as $ } from "@dotss/ui";
|
|
4
|
+
import q from "@dotss/ui/core/useTheme";
|
|
5
|
+
import z from "dayjs";
|
|
6
|
+
import { getClassInfo as G, getCtaButtonText as J } from "./BotMessage.utils.mjs";
|
|
7
|
+
import K from "../../Image/Image.mjs";
|
|
8
|
+
import N from "../../../hooks/useInView/useInView.mjs";
|
|
9
9
|
import S from "../../../utils/getCareTypeLabel/getCareTypeLabel.mjs";
|
|
10
|
-
function
|
|
11
|
-
id:
|
|
10
|
+
function V({
|
|
11
|
+
id: P,
|
|
12
12
|
botMessageType: y,
|
|
13
13
|
ctaType: s,
|
|
14
14
|
ctaTargetId: C,
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
ctaTargetTable: b,
|
|
16
|
+
subCtaTargetTable: v,
|
|
17
|
+
subCtaTargetId: T,
|
|
17
18
|
mine: a,
|
|
18
19
|
avatarUrl: g,
|
|
19
|
-
title:
|
|
20
|
+
title: R,
|
|
20
21
|
content: p,
|
|
21
22
|
unreadUserCount: h,
|
|
22
|
-
offer:
|
|
23
|
-
regDatetime:
|
|
23
|
+
offer: w,
|
|
24
|
+
regDatetime: I,
|
|
24
25
|
onAction: o,
|
|
25
26
|
onView: l,
|
|
26
|
-
inlineCSS:
|
|
27
|
-
...
|
|
27
|
+
inlineCSS: B,
|
|
28
|
+
...j
|
|
28
29
|
}) {
|
|
29
30
|
const {
|
|
30
|
-
palette: { brand:
|
|
31
|
+
palette: { brand: D, grey: m, background: k },
|
|
31
32
|
spacing: d
|
|
32
|
-
} =
|
|
33
|
+
} = q(), f = F(null), { isInView: u } = N(f), x = J(s), i = w, H = [
|
|
33
34
|
S(i == null ? void 0 : i.firstCareType),
|
|
34
35
|
S(i == null ? void 0 : i.secondCareType)
|
|
35
|
-
].filter(Boolean).filter((
|
|
36
|
-
|
|
36
|
+
].filter(Boolean).filter((E) => E !== "-").join("+"), c = G(i), M = () => o == null ? void 0 : o({
|
|
37
|
+
botMessageType: y,
|
|
38
|
+
ctaType: s,
|
|
39
|
+
ctaTargetId: C,
|
|
40
|
+
ctaTargetTable: b,
|
|
41
|
+
subCtaTargetTable: v,
|
|
42
|
+
subCtaTargetId: T
|
|
43
|
+
});
|
|
44
|
+
return L(() => {
|
|
37
45
|
u && (l == null || l());
|
|
38
46
|
}, [u, l]), /* @__PURE__ */ t(
|
|
39
47
|
n,
|
|
@@ -45,10 +53,10 @@ function O({
|
|
|
45
53
|
pl: 4,
|
|
46
54
|
pr: 4,
|
|
47
55
|
flexDirection: a ? "row" : "row-reverse",
|
|
48
|
-
...
|
|
56
|
+
...j,
|
|
49
57
|
inlineCSS: {
|
|
50
58
|
overflowAnchor: "none",
|
|
51
|
-
...
|
|
59
|
+
...B
|
|
52
60
|
},
|
|
53
61
|
children: [
|
|
54
62
|
/* @__PURE__ */ r(e, { visuallyHidden: !0, children: "안내" }),
|
|
@@ -68,7 +76,7 @@ function O({
|
|
|
68
76
|
variant: "c5B",
|
|
69
77
|
"aria-hidden": !0,
|
|
70
78
|
inlineCSS: {
|
|
71
|
-
color:
|
|
79
|
+
color: D.primary.text
|
|
72
80
|
},
|
|
73
81
|
children: h
|
|
74
82
|
}
|
|
@@ -83,7 +91,7 @@ function O({
|
|
|
83
91
|
inlineCSS: {
|
|
84
92
|
whiteSpace: "nowrap"
|
|
85
93
|
},
|
|
86
|
-
children:
|
|
94
|
+
children: z(I).format("A h:mm")
|
|
87
95
|
}
|
|
88
96
|
)
|
|
89
97
|
]
|
|
@@ -104,7 +112,7 @@ function O({
|
|
|
104
112
|
},
|
|
105
113
|
children: [
|
|
106
114
|
g && /* @__PURE__ */ r(
|
|
107
|
-
|
|
115
|
+
K,
|
|
108
116
|
{
|
|
109
117
|
src: g,
|
|
110
118
|
width: 32,
|
|
@@ -114,7 +122,7 @@ function O({
|
|
|
114
122
|
}
|
|
115
123
|
),
|
|
116
124
|
/* @__PURE__ */ t(n, { flexDirection: "column", children: [
|
|
117
|
-
/* @__PURE__ */ r(e, { tag: "p", variant: "h4B", children:
|
|
125
|
+
/* @__PURE__ */ r(e, { tag: "p", variant: "h4B", children: R }),
|
|
118
126
|
p && /* @__PURE__ */ r(
|
|
119
127
|
e,
|
|
120
128
|
{
|
|
@@ -134,7 +142,7 @@ function O({
|
|
|
134
142
|
flexDirection: "column",
|
|
135
143
|
inlineCSS: {
|
|
136
144
|
borderRadius: d.content(2),
|
|
137
|
-
backgroundColor:
|
|
145
|
+
backgroundColor: k.primary
|
|
138
146
|
},
|
|
139
147
|
children: [
|
|
140
148
|
/* @__PURE__ */ t(e, { tag: "dl", children: [
|
|
@@ -147,16 +155,16 @@ function O({
|
|
|
147
155
|
] }),
|
|
148
156
|
/* @__PURE__ */ t(e, { tag: "dl", children: [
|
|
149
157
|
/* @__PURE__ */ r(e, { tag: "dt", visuallyHidden: !0, children: "돌봄 유형" }),
|
|
150
|
-
/* @__PURE__ */ r(e, { tag: "dd", variant: "b4R", color: "grey.70", children:
|
|
158
|
+
/* @__PURE__ */ r(e, { tag: "dd", variant: "b4R", color: "grey.70", children: H })
|
|
151
159
|
] })
|
|
152
160
|
]
|
|
153
161
|
}
|
|
154
162
|
),
|
|
155
163
|
x && /* @__PURE__ */ r(
|
|
156
|
-
|
|
164
|
+
$,
|
|
157
165
|
{
|
|
158
166
|
color: "secondary",
|
|
159
|
-
onClick:
|
|
167
|
+
onClick: M,
|
|
160
168
|
inlineCSS: {
|
|
161
169
|
marginTop: d.content(2)
|
|
162
170
|
},
|
|
@@ -172,5 +180,5 @@ function O({
|
|
|
172
180
|
);
|
|
173
181
|
}
|
|
174
182
|
export {
|
|
175
|
-
|
|
183
|
+
V as default
|
|
176
184
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { default as BotMessage, BotMessageCtaType, BotMessageOffer, BotMessageProps, BotMessageSubCtaTargetTable, BotMessageType } from './BotMessage';
|
|
1
|
+
import { default as BotMessage, BotMessageCtaTargetTable, BotMessageCtaType, BotMessageOffer, BotMessageProps, BotMessageSubCtaTargetTable, BotMessageType } from './BotMessage';
|
|
2
2
|
export { getClassInfo, getCtaButtonText, getBotMessageLabel } from './BotMessage.utils';
|
|
3
|
-
export type { BotMessageProps, BotMessageCtaType, BotMessageType, BotMessageOffer, BotMessageSubCtaTargetTable };
|
|
3
|
+
export type { BotMessageProps, BotMessageCtaType, BotMessageType, BotMessageOffer, BotMessageSubCtaTargetTable, BotMessageCtaTargetTable };
|
|
4
4
|
export default BotMessage;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsxs as t, jsx as r, Fragment as O } from "react/jsx-runtime";
|
|
2
|
-
import { useRef as
|
|
3
|
-
import { Flexbox as s, Typography as C, Button as J, Icon as I, Menu as K, MenuBlock as
|
|
2
|
+
import { useRef as b, useImperativeHandle as q, useEffect as x } from "react";
|
|
3
|
+
import { Flexbox as s, Typography as C, Button as J, Icon as I, Menu as K, MenuBlock as P, CircularProgressIndicator as Q } from "@dotss/ui";
|
|
4
4
|
import W from "@dotss/ui/core/useTheme";
|
|
5
5
|
import { useCheckHoverPossible as X } from "@dotss/ui/hooks";
|
|
6
6
|
import { MenuButton as Y } from "@dotss/ui/Menu";
|
|
@@ -13,17 +13,17 @@ function ar({
|
|
|
13
13
|
mine: e = !1,
|
|
14
14
|
avatarUrl: f = "",
|
|
15
15
|
unreadUserCount: h = 0,
|
|
16
|
-
regDatetime:
|
|
16
|
+
regDatetime: $,
|
|
17
17
|
status: n,
|
|
18
18
|
onView: c,
|
|
19
19
|
openMenu: g,
|
|
20
20
|
onCloseMenu: i,
|
|
21
|
-
onClickMenu:
|
|
21
|
+
onClickMenu: z,
|
|
22
22
|
onResend: u,
|
|
23
23
|
onDelete: S,
|
|
24
|
-
onViewAll:
|
|
24
|
+
onViewAll: B,
|
|
25
25
|
showAvatar: k,
|
|
26
|
-
showTime:
|
|
26
|
+
showTime: D,
|
|
27
27
|
ref: R,
|
|
28
28
|
inlineCSS: T,
|
|
29
29
|
...j
|
|
@@ -31,21 +31,21 @@ function ar({
|
|
|
31
31
|
const {
|
|
32
32
|
palette: { brand: y, grey: o, etc: A },
|
|
33
33
|
spacing: w
|
|
34
|
-
} = W(), { isHoverPossible: G } = X(), l =
|
|
34
|
+
} = W(), { isHoverPossible: G } = X(), l = b(null), E = b(null), m = b(null);
|
|
35
35
|
q(R, () => l.current);
|
|
36
|
-
const
|
|
36
|
+
const F = V(l), L = 300, d = n === "FAILED", N = p.length > L, H = (a) => {
|
|
37
37
|
a === "resend" ? (i == null || i(), m.current = setTimeout(() => {
|
|
38
38
|
u == null || u();
|
|
39
39
|
}, 200)) : a === "delete" && (i == null || i(), m.current = setTimeout(() => {
|
|
40
40
|
S == null || S();
|
|
41
41
|
}, 200));
|
|
42
42
|
};
|
|
43
|
-
return
|
|
44
|
-
|
|
45
|
-
}, [
|
|
43
|
+
return x(() => {
|
|
44
|
+
F && (c == null || c());
|
|
45
|
+
}, [F, c]), x(() => {
|
|
46
46
|
var a;
|
|
47
47
|
d && ((a = l == null ? void 0 : l.current) == null || a.scrollIntoView());
|
|
48
|
-
}, [d]),
|
|
48
|
+
}, [d]), x(() => () => {
|
|
49
49
|
m.current && clearTimeout(m.current);
|
|
50
50
|
}, []), /* @__PURE__ */ t(
|
|
51
51
|
s,
|
|
@@ -74,6 +74,7 @@ function ar({
|
|
|
74
74
|
borderRadius: "50%",
|
|
75
75
|
alt: "째깍악어 선생님 심볼",
|
|
76
76
|
role: "presentation",
|
|
77
|
+
enableFallback: !0,
|
|
77
78
|
style: {
|
|
78
79
|
objectFit: "cover"
|
|
79
80
|
}
|
|
@@ -104,16 +105,16 @@ function ar({
|
|
|
104
105
|
whiteSpace: "pre-wrap",
|
|
105
106
|
wordBreak: "break-all"
|
|
106
107
|
},
|
|
107
|
-
children:
|
|
108
|
+
children: N ? p.slice(0, L) + "..." : p
|
|
108
109
|
}
|
|
109
110
|
),
|
|
110
|
-
|
|
111
|
+
N && /* @__PURE__ */ r(
|
|
111
112
|
J,
|
|
112
113
|
{
|
|
113
114
|
variant: "text",
|
|
114
115
|
size: "xSmall",
|
|
115
116
|
endAdornment: /* @__PURE__ */ r(I, { name: "ChevronRightLine" }),
|
|
116
|
-
onClick:
|
|
117
|
+
onClick: B,
|
|
117
118
|
inlineCSS: {
|
|
118
119
|
marginLeft: "auto"
|
|
119
120
|
},
|
|
@@ -131,7 +132,7 @@ function ar({
|
|
|
131
132
|
ref: E,
|
|
132
133
|
isMenuOpen: !!g,
|
|
133
134
|
menuId: `message-${v}-menu`,
|
|
134
|
-
onClick:
|
|
135
|
+
onClick: z,
|
|
135
136
|
size: "xSmall",
|
|
136
137
|
inlineCSS: {
|
|
137
138
|
padding: w.content(0.5),
|
|
@@ -185,8 +186,8 @@ function ar({
|
|
|
185
186
|
width: 160,
|
|
186
187
|
placement: "bottom-left",
|
|
187
188
|
children: [
|
|
188
|
-
/* @__PURE__ */ r(
|
|
189
|
-
/* @__PURE__ */ r(
|
|
189
|
+
/* @__PURE__ */ r(P, { value: "resend", children: "재전송" }),
|
|
190
|
+
/* @__PURE__ */ r(P, { value: "delete", children: "삭제" })
|
|
190
191
|
]
|
|
191
192
|
}
|
|
192
193
|
)
|
|
@@ -230,9 +231,9 @@ function ar({
|
|
|
230
231
|
variant: "c5R",
|
|
231
232
|
color: "etc.dimmed01",
|
|
232
233
|
inlineCSS: {
|
|
233
|
-
display:
|
|
234
|
+
display: D ? void 0 : "none"
|
|
234
235
|
},
|
|
235
|
-
children: Z(
|
|
236
|
+
children: Z($).format("A h:mm")
|
|
236
237
|
}
|
|
237
238
|
)
|
|
238
239
|
]
|
|
@@ -15,6 +15,7 @@ export interface ImageProps extends Omit<HTMLProps<HTMLImageElement>, 'onError'>
|
|
|
15
15
|
disabledResizing?: boolean;
|
|
16
16
|
withIntrinsicRatio?: boolean;
|
|
17
17
|
wrapperProps?: FlexboxProps;
|
|
18
|
+
enableBlurPlaceholder?: boolean;
|
|
18
19
|
enableFallback?: boolean;
|
|
19
20
|
enableErrorFallback?: boolean;
|
|
20
21
|
renderErrorFallback?: () => ReactNode;
|