@edu-tosel/design 1.0.211 → 1.0.213

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.
Files changed (48) hide show
  1. package/layout/template/Event/Event.d.ts +19 -5
  2. package/layout/template/Event/Event.js +63 -1
  3. package/layout/template/Event/One.js +4 -47
  4. package/layout/template/Event/molecule/Banner.d.ts +6 -0
  5. package/layout/template/Event/molecule/Banner.js +43 -0
  6. package/layout/template/Transcript/design/Transcript.d.ts +90 -0
  7. package/layout/template/Transcript/design/Transcript.design.js +4 -1
  8. package/layout/template/Transcript/design/Transcript.js +121 -1
  9. package/layout/template/Transcript/design/TranscriptAdvanced.design.js +0 -4
  10. package/layout/template/Transcript/design/atom/GetPartDescriptionFromLevel.d.ts +3 -0
  11. package/layout/template/Transcript/design/atom/GetPartDescriptionFromLevel.js +4 -0
  12. package/layout/template/Transcript/design/atom/GetPartTitleFromLevel.d.ts +3 -0
  13. package/layout/template/Transcript/design/atom/GetPartTitleFromLevel.js +4 -0
  14. package/layout/template/Transcript/design/atom/LevelToPartDescriptionMap.d.ts +6 -0
  15. package/layout/template/Transcript/design/atom/LevelToPartDescriptionMap.js +95 -0
  16. package/layout/template/Transcript/design/atom/LevelToPartTitleMap.d.ts +6 -0
  17. package/layout/template/Transcript/design/atom/LevelToPartTitleMap.js +95 -0
  18. package/layout/template/Transcript/design/molecule/BarGraphDuo.d.ts +3 -0
  19. package/layout/template/Transcript/design/molecule/BarGraphDuo.js +1 -1
  20. package/layout/template/Transcript/design/molecule/BarGraphMulti.d.ts +11 -0
  21. package/layout/template/Transcript/design/molecule/BarGraphMulti.js +9 -0
  22. package/layout/template/Transcript/design/molecule/LSWRChart.js +4 -3
  23. package/layout/template/Transcript/design/molecule/MIChart.d.ts +1 -0
  24. package/layout/template/Transcript/design/molecule/MIChart.js +51 -0
  25. package/layout/template/Transcript/design/organism/BarCardRow.js +1 -1
  26. package/layout/template/Transcript/design/organism/IntelligenceCard.d.ts +12 -0
  27. package/layout/template/Transcript/design/organism/IntelligenceCard.js +39 -0
  28. package/layout/template/Transcript/design/organism/SectionRadarCard.d.ts +9 -0
  29. package/layout/template/Transcript/design/organism/SectionRadarCard.js +40 -0
  30. package/layout/template/Transcript/interface.d.ts +23 -0
  31. package/package.json +1 -1
  32. package/tailwind.config.ts +5 -5
  33. package/util/createRecord.d.ts +20 -0
  34. package/util/createRecord.js +23 -0
  35. package/util/getMaxBday.js +6 -3
  36. package/util/index.d.ts +1 -0
  37. package/util/index.js +1 -0
  38. package/util/moment.d.ts +3 -0
  39. package/util/moment.js +10 -0
  40. package/version.txt +1 -1
  41. package/_test/asset/mock/academies.d.ts +0 -5
  42. package/_test/asset/mock/academies.js +0 -52
  43. package/_test/asset/mock/academy.d.ts +0 -28
  44. package/_test/asset/mock/academy.js +0 -419
  45. package/_test/asset/mock/chartData.d.ts +0 -6
  46. package/_test/asset/mock/chartData.js +0 -104
  47. package/_test/asset/mock/index.d.ts +0 -3
  48. package/_test/asset/mock/index.js +0 -3
@@ -1,15 +1,29 @@
1
1
  import { Button as _Button } from "../../../interface";
2
- type EventCategory = "event" | "notice";
2
+ export type EventCategory = "event" | "notice";
3
3
  export interface Event {
4
4
  id: number;
5
5
  category: EventCategory;
6
6
  thumbnail: string;
7
- createdAt: string;
8
- startedAt?: string;
9
- expiredAt?: string;
10
- endData?: string;
7
+ createdAt: number;
8
+ startedAt?: number;
9
+ expiredAt?: number;
10
+ endData?: number;
11
11
  title: string;
12
12
  content: string;
13
13
  button?: _Button;
14
14
  }
15
+ interface EventButton extends _Button {
16
+ option?: {
17
+ background?: string;
18
+ text?: string;
19
+ };
20
+ }
21
+ interface EventElement {
22
+ tag: {
23
+ text: string;
24
+ style?: string;
25
+ };
26
+ button: EventButton;
27
+ }
28
+ export declare function convertEventElement(event: Event, diffTime?: string): EventElement;
15
29
  export {};
@@ -1 +1,63 @@
1
- export {};
1
+ import moment from "moment-timezone";
2
+ import { toMoment } from "../../../util/moment";
3
+ import { gradient } from "../../../util";
4
+ export function convertEventElement(event, diffTime) {
5
+ const now = moment().tz("Asia/Seoul");
6
+ const startedAt = toMoment(event.startedAt);
7
+ const expiredAt = toMoment(event.expiredAt);
8
+ if (event.category === "event") {
9
+ if (now.isBefore(startedAt))
10
+ return {
11
+ tag: {
12
+ text: "오픈예정",
13
+ style: "bg-green-dark text-white",
14
+ },
15
+ button: {
16
+ title: `오픈까지 ${diffTime}`,
17
+ onClick: () => { },
18
+ option: {
19
+ background: "bg-gray-light",
20
+ text: "text-green-dark",
21
+ },
22
+ },
23
+ };
24
+ }
25
+ if (now.isAfter(startedAt) && now.isSameOrBefore(expiredAt))
26
+ return {
27
+ tag: {
28
+ text: `진행중 | D-${now.diff(expiredAt, "days")}`,
29
+ style: "bg-green-light text-green-dark",
30
+ },
31
+ button: {
32
+ title: event.button?.title ?? "참여하기",
33
+ onClick: event.button?.onClick,
34
+ option: {
35
+ background: gradient.bg.greenToRed,
36
+ text: "text-white",
37
+ },
38
+ },
39
+ };
40
+ if (now.isAfter(expiredAt))
41
+ return {
42
+ tag: { text: "마감", style: "bg-gray-light text-gray-medium" },
43
+ button: {
44
+ title: "이벤트가 마감되었어요",
45
+ onClick: () => { },
46
+ option: {
47
+ background: "bg-gray-light",
48
+ text: "text-gray-medium",
49
+ },
50
+ },
51
+ };
52
+ return {
53
+ tag: { text: "토셀 소식", style: "bg-blue-navy/10 text-blue-navy" },
54
+ button: {
55
+ title: "자세히 보기",
56
+ onClick: event.button?.onClick,
57
+ option: {
58
+ background: "bg-green-light",
59
+ text: "text-green-dark",
60
+ },
61
+ },
62
+ };
63
+ }
@@ -1,52 +1,9 @@
1
1
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  import { cn, isHTMLString } from "../../../util";
3
- import { StatusText } from "./StatusText";
4
- import { useState, useEffect } from "react";
3
+ import BannerMolecule from "./molecule/Banner";
5
4
  export default function One({ event }) {
6
- const [currentTime, setCurrentTime] = useState(new Date());
7
- useEffect(() => {
8
- const timer = setInterval(() => setCurrentTime(new Date()), 1000);
9
- return () => clearInterval(timer);
10
- }, []);
11
- // 현재는 startedAt과 expiredAt 모두 시각은 09:00:00 으로 설정되어 있습니다.
12
- const startedAt = event.startedAt ? new Date(event.startedAt) : null;
13
- const expiredAt = event.expiredAt ? new Date(event.expiredAt) : null;
14
- const timeDiff = startedAt
15
- ? startedAt.getTime() - currentTime.getTime()
16
- : expiredAt
17
- ? expiredAt.getTime() - currentTime.getTime()
18
- : 0;
19
- const daysRemaining = Math.floor(timeDiff / (1000 * 60 * 60 * 24));
20
- const hoursRemaining = Math.floor((timeDiff / (1000 * 60 * 60)) % 24);
21
- const minutesRemaining = Math.floor((timeDiff / (1000 * 60)) % 60);
22
- const secondsRemaining = Math.floor((timeDiff / 1000) % 60);
23
- // NOTE: let 쓰지 마세요 없어도 코드 짜는데 문제 없습니다. 스코프 이슈 생기면 답없습니다.
24
- // NOTE: 컴포넌트 내부에서 if else 문 쓰지 마세요 가독성 떨어지고 버그납니다. 예외처리는 함수로 빼서 처리하세요.
25
- // NOTE: 절대 같은 코드 복붙하지마세요. 성능떨어지고 보기 안좋습니다.
26
- const lines = event.title.split("\n");
27
- const countdownText = daysRemaining > 0
28
- ? `오픈까지 D-${daysRemaining}`
29
- : `오픈까지 ${hoursRemaining
30
- .toString()
31
- .padStart(2, "0")}:${minutesRemaining
32
- .toString()
33
- .padStart(2, "0")}:${secondsRemaining
34
- .toString()
35
- .padStart(2, "0")} 남음`;
36
- const button = {
37
- sizes: "w-full h-12 flex items-center justify-center rounded-md cursor-pointer font-bold gap-3 text-sm xs:text-md",
38
- backgrounds: expiredAt && expiredAt < currentTime
39
- ? " bg-gray-light text-gray-medium"
40
- : expiredAt && expiredAt > currentTime
41
- ? "bg-gray-light text-green-dark"
42
- : "bg-gradient-to-l from-crimson-burgundy to-green-dark text-white",
5
+ const container = {
6
+ displays: "flex flex-col xl:flex-row gap-x-8 gap-y-5",
43
7
  };
44
- const buttonText = expiredAt && expiredAt < currentTime
45
- ? "종료된 이벤트입니다"
46
- : startedAt && startedAt > currentTime
47
- ? countdownText
48
- : event.button?.title;
49
- return (_jsxs("div", { className: "flex flex-col mmd:flex-row", children: [_jsx("div", { className: "min-w-[320px] h-auto p-5 mmd:sticky mmd:top-20 mmd:self-start", children: _jsxs("div", { className: "w-full h-auto rounded-xl sm:flex mmd:flex-col", children: [_jsx("div", { className: "w-full mmd:h-50 overflow-hidden", children: _jsx("img", { src: event.thumbnail, alt: event.title, className: "rounded-xl h-full object-cover w-full" }) }), _jsxs("div", { className: "w-full h-auto pt-5 sm:p-5 mmd:p-0 mmd:pt-5 gap-3 flex flex-col", children: [_jsx("div", { className: "flex items-center", children: _jsx(StatusText, { event: event }) }), _jsx("div", { className: "text-sm font-bold text-gray-dark flex flex-col items-start mb-2", children: lines.map((line, index) => (_jsxs("span", { children: [line, _jsx("br", {})] }, index))) }), event.button && (_jsx("div", { className: cn(button), onClick: () => {
50
- event.button?.onClick && event.button.onClick();
51
- }, children: buttonText }))] })] }, event.id) }), isHTMLString(event.content) ? (_jsx("div", { dangerouslySetInnerHTML: { __html: event.content } })) : (_jsx("div", { children: event.content })), _jsx("button", { onClick: () => history.back(), className: "mt-8 p-5 bg-green-dark/5 text-green-dark rounded-xl flex items-center justify-center hover:bg-green-dark/20 transition-all", children: "\uBAA9\uB85D\uC73C\uB85C \uB3CC\uC544\uAC00\uAE30" })] }));
8
+ return (_jsxs("div", { className: cn(container), children: [_jsx(BannerMolecule, { event: event }), _jsx("div", { children: isHTMLString(event.content) ? (_jsx("div", { dangerouslySetInnerHTML: { __html: event.content } })) : (_jsx("div", { children: event.content })) })] }));
52
9
  }
@@ -0,0 +1,6 @@
1
+ import { Event } from "../Event";
2
+ interface BannerProps {
3
+ event: Event;
4
+ }
5
+ export default function BannerMolecule({ event }: BannerProps): import("react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -0,0 +1,43 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { useEffect, useState } from "react";
3
+ import { LineBreaks } from "../../../../text";
4
+ import { cn } from "../../../../util";
5
+ import { Label } from "../../../../widget";
6
+ import { convertEventElement } from "../Event";
7
+ import moment from "moment-timezone";
8
+ import { toDiffFromCurrent } from "../../../../util/moment";
9
+ export default function BannerMolecule({ event }) {
10
+ const { thumbnail, title } = event;
11
+ const [currentTime, setCurrentTime] = useState(moment);
12
+ useEffect(() => {
13
+ const timer = setInterval(() => {
14
+ setCurrentTime(moment.tz("Asia/Seoul"));
15
+ }, 1000);
16
+ return () => clearInterval(timer);
17
+ }, []);
18
+ const diffTime = toDiffFromCurrent(event.expiredAt, currentTime);
19
+ const { button } = convertEventElement(event, diffTime);
20
+ const container = {
21
+ positions: "relative",
22
+ displays: "flex flex-col sm:flex-row xl:flex-col xl:gap-5 justify-center xl:justify-start items-center xl:items-start",
23
+ sizes: "w-full xl:w-[320px]",
24
+ };
25
+ return (_jsxs("div", { className: cn(container), children: [_jsx("div", { className: "w-full max-w-[320px] sm:max-w-[352px] xl:max-w-max h-[200px] overflow-hidden bg-cover rounded-[12px]", children: _jsx("img", { src: thumbnail, className: "w-full h-full object-cover" }) }), _jsxs("div", { className: "flex flex-col gap-y-5 p-5 xl:p-0 w-full max-w-[320px] xl:max-w-full xl:w-full", children: [_jsxs("div", { className: "flex flex-col gap-y-3", children: [_jsx(Tag, { event: event }), _jsx(LineBreaks, { texts: title, className: "text-[16px] font-bold" })] }), _jsx(Label.Button, { title: button?.title, onClick: button?.onClick, option: {
26
+ width: "full",
27
+ background: button?.option?.background,
28
+ text: [button?.option?.text, "font-bold"].join(" "),
29
+ } })] })] }));
30
+ }
31
+ function Tag({ event }) {
32
+ const { tag } = convertEventElement(event);
33
+ const container = {
34
+ selfAligns: "self-start",
35
+ displays: "flex items-center",
36
+ sizes: "h-[22px]",
37
+ paddings: "px-2",
38
+ texts: "leading-none text-[12px]",
39
+ boundaries: "rounded-[4px]",
40
+ styles: tag.style,
41
+ };
42
+ return _jsx("div", { className: cn(container), children: tag.text });
43
+ }
@@ -21,6 +21,38 @@ export interface TranscriptProps {
21
21
  isHonor: boolean;
22
22
  };
23
23
  data: {
24
+ graph: {
25
+ user: {
26
+ section1: {
27
+ partA: number;
28
+ partB: number;
29
+ partC: number;
30
+ partD: number;
31
+ };
32
+ section2: {
33
+ partA: number;
34
+ partB: number;
35
+ partC: number;
36
+ partD: number;
37
+ };
38
+ };
39
+ average: {
40
+ user: {
41
+ section1: {
42
+ partA: number;
43
+ partB: number;
44
+ partC: number;
45
+ partD: number;
46
+ };
47
+ section2: {
48
+ partA: number;
49
+ partB: number;
50
+ partC: number;
51
+ partD: number;
52
+ };
53
+ };
54
+ };
55
+ };
24
56
  analysis: {
25
57
  total: {
26
58
  section1: number;
@@ -50,6 +82,7 @@ export interface TranscriptProps {
50
82
  section1: string | string[];
51
83
  section2: string | string[];
52
84
  };
85
+ multipleIntelligence: MultipleIntelligenceRate;
53
86
  };
54
87
  }
55
88
  interface Score {
@@ -62,6 +95,21 @@ interface Score {
62
95
  part7: number;
63
96
  part8: number;
64
97
  }
98
+ interface Score1 {
99
+ section1: {
100
+ partA: number;
101
+ partB: number;
102
+ partC: number;
103
+ partD: number;
104
+ };
105
+ section2: {
106
+ partA: number;
107
+ partB: number;
108
+ partC: number;
109
+ partD: number;
110
+ };
111
+ total: number;
112
+ }
65
113
  interface LSWRPercent {
66
114
  listening: number;
67
115
  speaking: number;
@@ -122,4 +170,46 @@ export interface TranscriptAdvancedProps {
122
170
  oci: OccupationalCompetency[];
123
171
  }
124
172
  export declare const example: TranscriptAdvancedProps;
173
+ interface MultipleIntelligenceRate {
174
+ musical: number;
175
+ bodilyKinesthetic: number;
176
+ logicalMathematical: number;
177
+ linguistic: number;
178
+ spatial: number;
179
+ interpersonal: number;
180
+ naturalist: number;
181
+ intrapersonal: number;
182
+ }
183
+ export interface TranscriptProps1 {
184
+ info: {
185
+ name: string;
186
+ nickname?: string;
187
+ imgSrc?: string;
188
+ qrSrc?: string;
189
+ sharedSrc?: string;
190
+ code: string;
191
+ birthday: string;
192
+ examName: string;
193
+ examDate: string;
194
+ examType: ExamType;
195
+ examValidAt: string;
196
+ level: Level;
197
+ gender: string;
198
+ };
199
+ result: {
200
+ score: number;
201
+ grade: number;
202
+ isHonor: boolean;
203
+ percentRank: number;
204
+ };
205
+ score: {
206
+ result: Score1;
207
+ average: Score1;
208
+ ageAverage: Score1;
209
+ examHallAverage: Score1;
210
+ percent10Average: Score1;
211
+ percent30Average: Score1;
212
+ };
213
+ multipleIntelligence: MultipleIntelligenceRate;
214
+ }
125
215
  export {};
@@ -8,6 +8,9 @@ import ScoreCard from "./organism/ScoreCard";
8
8
  import HonorCard from "./organism/HonorCard";
9
9
  import ResultGaugeCard from "./organism/ResultGaugeCard";
10
10
  import PerformanceCard from "./organism/PerformanceCard";
11
+ import { MIChart } from "./molecule/MIChart";
12
+ import { IntelligenceCard } from "./organism/IntelligenceCard";
13
+ import { SectionRadarCard } from "./organism/SectionRadarCard";
11
14
  export const EXAM_TYPE = {
12
15
  REG: "REG",
13
16
  CMP: "CMP",
@@ -38,7 +41,7 @@ function TranscriptDesign({ props }, ref) {
38
41
  spacings: "px-5 py-2",
39
42
  backgrounds: "bg-gradient-to-r from-crimson-burgundy to-green-dark",
40
43
  };
41
- return (_jsxs("div", { ref: ref, className: cn(container), children: [_jsxs("div", { className: cn(headerBox), children: [_jsx("img", { src: "images/logos/logo-tosel-white.svg", alt: "", className: "h-10" }), _jsxs("div", { className: "text-white font-bold text-base", children: [getStringfromType(info.examType), " \uC131\uC801\uD45C"] })] }), _jsx(IdCard, { info: info }), _jsxs("div", { className: "flex flex-col gap-5 xs:flex-row mt-5 items-stretch", children: [_jsx(ResultGaugeCard, { result: result, theme: "green" }), _jsx(HonorCard, { result: result })] }), _jsx(PerformanceCard, { data: data, info: info }), _jsx(ScoreCard, { data: data }), _jsx(BarCardRow, { section1: section1Data, section2: section2Data, theme: "green" })] }));
44
+ return (_jsxs("div", { ref: ref, className: cn(container), children: [_jsxs("div", { className: cn(headerBox), children: [_jsx("img", { src: "images/logos/logo-tosel-white.svg", alt: "", className: "h-10" }), _jsxs("div", { className: "text-white font-bold text-base", children: [getStringfromType(info.examType), " \uC131\uC801\uD45C"] })] }), _jsx(IdCard, { info: info }), _jsxs("div", { className: "flex flex-col gap-5 xs:flex-row mt-5 items-stretch", children: [_jsx(ResultGaugeCard, { result: result, theme: "green" }), _jsx(HonorCard, { result: result })] }), _jsx(PerformanceCard, { data: data, info: info }), _jsx(ScoreCard, { data: data }), _jsx(BarCardRow, { section1: section1Data, section2: section2Data, theme: "green" }), _jsx(SectionRadarCard, { data: data, section: "section1", info: info, theme: "red", title: "Section1" }), _jsx(IntelligenceCard, { data: data.multipleIntelligence, theme: "green" }), _jsx(MIChart, {})] }));
42
45
  }
43
46
  export default forwardRef(TranscriptDesign);
44
47
  function SectionBarGraphProps(title, score, total, script, subScripts, scale, subScore) {
@@ -58,4 +58,124 @@ export const example = {
58
58
  },
59
59
  ],
60
60
  };
61
- example.lswr.result.listening;
61
+ const transcript = {
62
+ info: {
63
+ name: "김필립",
64
+ birthday: "1999-11-11",
65
+ code: "123456789012",
66
+ gender: "MAIL",
67
+ examDate: "2024-11-06",
68
+ examName: "제 12회 정기시험",
69
+ examType: "REG",
70
+ examValidAt: "2024-11-07",
71
+ level: "PS",
72
+ },
73
+ result: {
74
+ score: 90,
75
+ grade: 1,
76
+ isHonor: true,
77
+ percentRank: 0.1,
78
+ },
79
+ score: {
80
+ result: {
81
+ section1: {
82
+ partA: 1,
83
+ partB: 1,
84
+ partC: 1,
85
+ partD: 1,
86
+ },
87
+ section2: {
88
+ partA: 1,
89
+ partB: 1,
90
+ partC: 1,
91
+ partD: 1,
92
+ },
93
+ total: 11,
94
+ },
95
+ average: {
96
+ section1: {
97
+ partA: 2,
98
+ partB: 2,
99
+ partC: 2,
100
+ partD: 2,
101
+ },
102
+ section2: {
103
+ partA: 2,
104
+ partB: 2,
105
+ partC: 2,
106
+ partD: 2,
107
+ },
108
+ total: 22,
109
+ },
110
+ ageAverage: {
111
+ section1: {
112
+ partA: 3,
113
+ partB: 3,
114
+ partC: 3,
115
+ partD: 3,
116
+ },
117
+ section2: {
118
+ partA: 3,
119
+ partB: 3,
120
+ partC: 3,
121
+ partD: 3,
122
+ },
123
+ total: 33,
124
+ },
125
+ examHallAverage: {
126
+ section1: {
127
+ partA: 4,
128
+ partB: 4,
129
+ partC: 4,
130
+ partD: 4,
131
+ },
132
+ section2: {
133
+ partA: 4,
134
+ partB: 4,
135
+ partC: 4,
136
+ partD: 4,
137
+ },
138
+ total: 44,
139
+ },
140
+ percent10Average: {
141
+ section1: {
142
+ partA: 5,
143
+ partB: 5,
144
+ partC: 5,
145
+ partD: 5,
146
+ },
147
+ section2: {
148
+ partA: 5,
149
+ partB: 5,
150
+ partC: 5,
151
+ partD: 5,
152
+ },
153
+ total: 55,
154
+ },
155
+ percent30Average: {
156
+ section1: {
157
+ partA: 6,
158
+ partB: 6,
159
+ partC: 6,
160
+ partD: 6,
161
+ },
162
+ section2: {
163
+ partA: 6,
164
+ partB: 6,
165
+ partC: 6,
166
+ partD: 6,
167
+ },
168
+ total: 66,
169
+ },
170
+ },
171
+ multipleIntelligence: {
172
+ musical: 0.2,
173
+ bodilyKinesthetic: 0.2,
174
+ logicalMathematical: 0.428571,
175
+ linguistic: 0.2,
176
+ spatial: 0.285714,
177
+ interpersonal: 0.428571,
178
+ naturalist: 0.375,
179
+ intrapersonal: 0.166667,
180
+ },
181
+ };
@@ -39,10 +39,6 @@ function TranscriptDesign({ props }, ref) {
39
39
  spacings: "px-5 py-2",
40
40
  backgrounds: "bg-gradient-to-r from-crimson-burgundy to-green-dark",
41
41
  };
42
- const RadarWrapper = {
43
- displays: "flex flex-row gap-5",
44
- siezs: "w-full h-fit",
45
- };
46
42
  return (_jsx(_Fragment, { children: _jsxs("div", { ref: ref, className: cn(container), children: [_jsxs("div", { className: cn(headerBox), children: [_jsx("img", { src: "https://resource.tosel.co.kr/images/header-logo2.png", alt: "\uD1A0\uC140 \uB85C\uACE0", className: "h-10 py-1" }), _jsx("div", { className: "text-white font-bold text-base", children: "Official Score Report" })] }), _jsx(IdCard, { info: info }), _jsx(BarCardCol, { section1: section1Data, section2: section2Data, theme: "red" }), _jsx(RadarCard, { data: lswr, theme: "red", title: "Section Scores" }), _jsxs("div", { className: cn("page-break"), children: [_jsx("div", { className: "w-full h-5 print:block" }), _jsxs("div", { className: cn(headerBox), children: [_jsx("img", { src: "https://resource.tosel.co.kr/images/header-logo2.png", alt: "\uD1A0\uC140 \uB85C\uACE0", className: "h-10 py-1" }), _jsx("div", { className: "text-white font-bold text-base", children: "Occupational Competency Index Report" })] }), _jsx(OCICard, { data: oci }), _jsx(OCIChart, {})] })] }) }));
47
43
  }
48
44
  function SectionBarGraphProps(title, score, total, script, subScripts, scale, subScore) {
@@ -0,0 +1,3 @@
1
+ import { Level } from "../../../../../_test/interface";
2
+ import { PartPercent, SectionType } from "../../interface";
3
+ export declare function GetPartTitleFromLevel(level: Level, section: SectionType, part: keyof PartPercent): string;
@@ -0,0 +1,4 @@
1
+ import { LevelToPartDescriptionMap } from "./LevelToPartDescriptionMap";
2
+ export function GetPartTitleFromLevel(level, section, part) {
3
+ return LevelToPartDescriptionMap[level]?.[section]?.[part] || "Unknown";
4
+ }
@@ -0,0 +1,3 @@
1
+ import { Level } from "../../../../../_test/interface";
2
+ import { PartPercent, SectionType } from "../../interface";
3
+ export declare function GetPartDescriptionFromLevel(level: Level, section: SectionType, part: keyof PartPercent): string;
@@ -0,0 +1,4 @@
1
+ import { LevelToPartTitleMap } from "./LevelToPartTitleMap";
2
+ export function GetPartDescriptionFromLevel(level, section, part) {
3
+ return LevelToPartTitleMap[level]?.[section]?.[part] || "Unknown";
4
+ }
@@ -0,0 +1,6 @@
1
+ import { Level } from "../../../../../_test/interface";
2
+ import { partText } from "../../interface";
3
+ export declare const LevelToPartDescriptionMap: Record<Level, {
4
+ section1: partText;
5
+ section2: partText;
6
+ }>;
@@ -0,0 +1,95 @@
1
+ export const LevelToPartDescriptionMap = {
2
+ CO: {
3
+ section1: {
4
+ partA: "Listen and Recognize",
5
+ partB: "Listen and Respond",
6
+ partC: "Listen and Retell",
7
+ },
8
+ section2: {
9
+ partA: "Spell the Words",
10
+ partB: "Look and Recognize",
11
+ partC: "Look and Respond",
12
+ partD: "Read and Retell",
13
+ },
14
+ },
15
+ PS: {
16
+ section1: {
17
+ partA: "Listen and Recognize",
18
+ partB: "Listen and Respond",
19
+ partC: "Listen and Retell",
20
+ },
21
+ section2: {
22
+ partA: "Spell the Words",
23
+ partB: "Look and Recognize",
24
+ partC: "Look and Respond",
25
+ partD: "Read and Retell",
26
+ },
27
+ },
28
+ ST: {
29
+ section1: {
30
+ partA: "Listen and Recognize",
31
+ partB: "Listen and Respond",
32
+ partC: "Listen and Retell",
33
+ },
34
+ section2: {
35
+ partA: "Sentence Completion",
36
+ partB: "Situational Writing",
37
+ partC: "Reading and Retelling",
38
+ },
39
+ },
40
+ BA: {
41
+ section1: {
42
+ partA: "Listen and Recognize",
43
+ partB: "Listen and Respond",
44
+ partC: "Listen and Retell",
45
+ partD: "Listen and Speak",
46
+ },
47
+ section2: {
48
+ partA: "Sentence Completion",
49
+ partB: "Situational Writing",
50
+ partC: "Practical Reading and Retelling",
51
+ partD: "General Reading and Retelling",
52
+ },
53
+ },
54
+ JR: {
55
+ section1: {
56
+ partA: "Listen and Respond",
57
+ partB: "Listen and Retell",
58
+ partC: "Listen and Speak",
59
+ },
60
+ section2: {
61
+ partA: "Sentence Completion",
62
+ partB: "Situational Writing",
63
+ partC: "Practical Reading and Retelling",
64
+ partD: "General Reading and Retelling",
65
+ },
66
+ },
67
+ HJ: {
68
+ section1: {
69
+ partA: "Listen and Recognize",
70
+ partB: "Listen and Respond",
71
+ partC: "Short Conversations",
72
+ partD: "Talks",
73
+ },
74
+ section2: {
75
+ partA: "Picture Description",
76
+ partB: "Sentence Completion",
77
+ partC: "Practical Reading and Comprehension",
78
+ partD: "General Reading and Comprehension",
79
+ },
80
+ },
81
+ AD: {
82
+ section1: {
83
+ partA: "Listen and Recognize",
84
+ partB: "Listen and Respond",
85
+ partC: "Short Conversations",
86
+ partD: "Talks",
87
+ },
88
+ section2: {
89
+ partA: "Picture Description",
90
+ partB: "Sentence Completion",
91
+ partC: "Practical Reading and Comprehension",
92
+ partD: "General Reading and Comprehension",
93
+ },
94
+ },
95
+ };
@@ -0,0 +1,6 @@
1
+ import { Level } from "../../../../../_test/interface";
2
+ import { partText } from "../../interface";
3
+ export declare const LevelToPartTitleMap: Record<Level, {
4
+ section1: partText;
5
+ section2: partText;
6
+ }>;