@ihabdevteam/core 0.391.0 → 0.393.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +72 -0
- package/dist/components.cjs.js +177 -177
- package/dist/components.esm.css +3 -3
- package/dist/hooks.cjs.js +5 -5
- package/dist/i18n.cjs.js +3 -3
- package/dist/ihabdevteam-core.cjs.js +183 -183
- package/dist/ihabdevteam-core.d.ts +85 -3
- package/dist/packages/core/src/components/Badge.css +5 -1
- package/dist/packages/core/src/components/Badge.d.ts +11 -2
- package/dist/packages/core/src/components/ConsentRecordPopup.css +13 -0
- package/dist/packages/core/src/components/ConsentRecordPopup.d.ts +69 -0
- package/dist/packages/core/src/components/ConsentRecordPopup.js +79 -0
- package/dist/packages/core/src/components.d.ts +2 -0
- package/dist/packages/core/src/components.js +1 -0
- package/dist/packages/core/src/i18n/locales/en.json +26 -0
- package/dist/packages/core/src/i18n/locales/ko.json +26 -0
- package/dist/packages/core/src/utils/phonemePairSearch.js +9 -1
- package/dist/packages/core/src/version.d.ts +1 -1
- package/dist/packages/core/src/version.js +1 -1
- package/dist/utils.cjs.js +21 -21
- package/package.json +1 -1
|
@@ -250,8 +250,17 @@ export declare interface BadgeProps {
|
|
|
250
250
|
label?: string;
|
|
251
251
|
children?: ReactNode;
|
|
252
252
|
/**
|
|
253
|
-
* 색상 variant
|
|
254
|
-
*
|
|
253
|
+
* 색상 variant — `dot` · `bar` 가 같은 것을 쓴다.
|
|
254
|
+
*
|
|
255
|
+
* `default` · `main` · `sub` · `danger` · `disabled` · `like` ·
|
|
256
|
+
* `success` · `warning` · `critical`
|
|
257
|
+
*
|
|
258
|
+
* `success` 는 브랜드 청록(`--color-sub`)이라 `sub` 와 **색이 같다**(사용자 지시
|
|
259
|
+
* 2026-10-28). 이름이 다른 까닭은 뜻이 달라서다 — 색이 바뀔 날 한쪽만 바뀐다.
|
|
260
|
+
* `critical` 은 보안 이벤트 심각도 최상급 전용이다.
|
|
261
|
+
*
|
|
262
|
+
* 목록에 없는 색은 `color` 로 직접 준다. 이 목록과 CSS 의 `.badge--*` 규칙이
|
|
263
|
+
* 어긋나면 `test/badgeSuccessVariant1028.test.tsx` 가 운다.
|
|
255
264
|
*/
|
|
256
265
|
variant?: string;
|
|
257
266
|
/**
|
|
@@ -1708,6 +1717,79 @@ export declare function ConfirmStep({ _stepIndex, _totalSteps, ...rest }: StepWr
|
|
|
1708
1717
|
/** @public */
|
|
1709
1718
|
export declare function ConfirmWithTextStep({ _stepIndex, _totalSteps, ...rest }: StepWrapperProps): JSX.Element;
|
|
1710
1719
|
|
|
1720
|
+
/**
|
|
1721
|
+
* 법이 따로 요구하는 동의 갈래 셋 — 화면도 이 차례로 보여 준다.
|
|
1722
|
+
*
|
|
1723
|
+
* 대장(`customer_consent.kind`)의 CHECK 와 **같은 셋이어야 한다.** 여기만 늘리면 서버가
|
|
1724
|
+
* 거절하고, 서버만 늘리면 받을 길이 없다.
|
|
1725
|
+
* @public
|
|
1726
|
+
*/
|
|
1727
|
+
export declare const CONSENT_KINDS: readonly ["personal", "sensitive", "marketing"];
|
|
1728
|
+
|
|
1729
|
+
/** @public */
|
|
1730
|
+
export declare type ConsentKind = (typeof CONSENT_KINDS)[number];
|
|
1731
|
+
|
|
1732
|
+
/**
|
|
1733
|
+
* **동의 받기 창** — 갈래를 여럿 한 번에 적는다.
|
|
1734
|
+
*
|
|
1735
|
+
* 한 상담에서 일반과 민감을 같이 받는 것이 보통이라 갈래마다 따로 부르면 **받은 때가 몇 초씩
|
|
1736
|
+
* 갈린다.** 서버가 한 자리에서 같은 `consented_at` 으로 적게 돼 있고, 이 창은 그 한 번에 맞춰
|
|
1737
|
+
* 짰다.
|
|
1738
|
+
*
|
|
1739
|
+
* **받은 날을 손으로 적는다** — 종이로 먼저 받고 나중에 입력하는 자리라, 오늘로 못 박으면
|
|
1740
|
+
* 대장이 거짓을 말한다. 앞날은 서버가 거절한다(하루치 여유).
|
|
1741
|
+
*
|
|
1742
|
+
* **자료를 안 쥔다** — 서버를 안 부르고, 받은 것을 저장하지도 않는다. `takenKinds` 를 받아
|
|
1743
|
+
* 그리고 `onSubmit` 으로 돌려줄 뿐이다. 부르는 쪽이 대장을 쥔다.
|
|
1744
|
+
*
|
|
1745
|
+
* **'오늘' 을 띄울 때마다 다시 센다** — 앱에서 옮겨 올 때 `todayYmd` 가 모듈 첫 줄에서
|
|
1746
|
+
* 한 번 정해지는 상수였다. 창을 띄운 채 자정을 넘긴 탭에서는 `max` 가 **어제**라 오늘을
|
|
1747
|
+
* 못 고른다. 여기서는 `todayYmdOr()` 를 창이 설 때 부른다.
|
|
1748
|
+
*
|
|
1749
|
+
* @example
|
|
1750
|
+
* <ConsentRecordPopup
|
|
1751
|
+
* takenKinds={rows.filter(r => !r.revokedAt).map(r => r.kind)}
|
|
1752
|
+
* busy={saving}
|
|
1753
|
+
* onClose={close}
|
|
1754
|
+
* onSubmit={({ kinds, method, source, consentedAt, note }) => save(…)}
|
|
1755
|
+
* />
|
|
1756
|
+
* @public
|
|
1757
|
+
*/
|
|
1758
|
+
export declare function ConsentRecordPopup({ takenKinds, busy, today, onClose, onSubmit, className, }: ConsentRecordPopupProps): JSX.Element;
|
|
1759
|
+
|
|
1760
|
+
/** @public */
|
|
1761
|
+
export declare interface ConsentRecordPopupProps {
|
|
1762
|
+
/**
|
|
1763
|
+
* 이미 **살아 있는** 갈래 — 고르개에서 뺀다. 서버가 그런 줄을 안 건드리므로(`DO NOTHING`)
|
|
1764
|
+
* 보여 주면 **눌러도 아무 일이 안 나는 칸**이 된다. 다시 받으려면 철회하고 받는다.
|
|
1765
|
+
*/
|
|
1766
|
+
takenKinds: string[];
|
|
1767
|
+
/** 저장하는 중 — 단추와 칸을 잠그고 닫기도 막는다 */
|
|
1768
|
+
busy?: boolean;
|
|
1769
|
+
/**
|
|
1770
|
+
* 부르는 쪽이 정한 '오늘'(`YYYY-MM-DD`). 안 주면 KST 오늘이다.
|
|
1771
|
+
* 처음 값과 `max`(앞날 막기)에 함께 쓴다. SSR·시험이 날을 못 박는 자리다.
|
|
1772
|
+
*/
|
|
1773
|
+
today?: string;
|
|
1774
|
+
onClose: () => void;
|
|
1775
|
+
onSubmit: (args: ConsentRecordSubmit) => void;
|
|
1776
|
+
className?: string;
|
|
1777
|
+
}
|
|
1778
|
+
|
|
1779
|
+
/** `onSubmit` 이 받는 것 — 서버의 `manager_record_customer_consent` 가 쓰는 꼴 그대로. @public */
|
|
1780
|
+
export declare interface ConsentRecordSubmit {
|
|
1781
|
+
/** 이번에 받은 갈래들 — 하나 이상이다(비면 저장 단추가 잠긴다) */
|
|
1782
|
+
kinds: string[];
|
|
1783
|
+
/** `paper` · `verbal` · `electronic` */
|
|
1784
|
+
method: string;
|
|
1785
|
+
/** `self` · `guardian` · `referral` */
|
|
1786
|
+
source: string;
|
|
1787
|
+
/** 받은 날 `YYYY-MM-DD`. 비우면 `null` */
|
|
1788
|
+
consentedAt: string | null;
|
|
1789
|
+
/** 메모. 공백뿐이면 `null` */
|
|
1790
|
+
note: string | null;
|
|
1791
|
+
}
|
|
1792
|
+
|
|
1711
1793
|
/** 표준발음 기준 오답 필터에 필요한 의존성 */
|
|
1712
1794
|
export declare interface ContrastFilterOpts {
|
|
1713
1795
|
/** 허용 단어 집합(이미지 필터 등). 없거나 null이면 전체 허용. */
|
|
@@ -1820,7 +1902,7 @@ export declare function copyText(text: string): Promise<boolean>;
|
|
|
1820
1902
|
*
|
|
1821
1903
|
* 값은 손으로 적고 `test/coreVersion.test.ts` 가 package.json 과 어긋나면 운다.
|
|
1822
1904
|
*/
|
|
1823
|
-
export declare const CORE_VERSION = "0.
|
|
1905
|
+
export declare const CORE_VERSION = "0.393.0";
|
|
1824
1906
|
|
|
1825
1907
|
/** @public */
|
|
1826
1908
|
declare const coreDefault: Record<string, unknown>;
|
|
@@ -50,8 +50,12 @@
|
|
|
50
50
|
--badge-color: var(--color-like);
|
|
51
51
|
--badge-on-color: #ffffff;
|
|
52
52
|
}
|
|
53
|
+
/* **`success` 는 브랜드의 청록(`--color-sub`)이다** — 사용자 지시 2026-10-28
|
|
54
|
+
(*"--color-sub 로 넣어"*). 시맨틱 토큰 `--color-success`(#2fae9e) 도 있으나
|
|
55
|
+
그것보다 밝은 브랜드 청록(#4dcdc0)을 골랐다. 그래서 `success` 와 `sub` 는
|
|
56
|
+
**색이 같다** — 뜻이 다른 두 이름이 같은 색을 쓴다(의도된 것이다). */
|
|
53
57
|
.badge--success {
|
|
54
|
-
--badge-color: var(--color-
|
|
58
|
+
--badge-color: var(--color-sub);
|
|
55
59
|
--badge-on-color: #ffffff;
|
|
56
60
|
}
|
|
57
61
|
.badge--warning {
|
|
@@ -53,8 +53,17 @@ export interface BadgeProps {
|
|
|
53
53
|
label?: string;
|
|
54
54
|
children?: ReactNode;
|
|
55
55
|
/**
|
|
56
|
-
* 색상 variant
|
|
57
|
-
*
|
|
56
|
+
* 색상 variant — `dot` · `bar` 가 같은 것을 쓴다.
|
|
57
|
+
*
|
|
58
|
+
* `default` · `main` · `sub` · `danger` · `disabled` · `like` ·
|
|
59
|
+
* `success` · `warning` · `critical`
|
|
60
|
+
*
|
|
61
|
+
* `success` 는 브랜드 청록(`--color-sub`)이라 `sub` 와 **색이 같다**(사용자 지시
|
|
62
|
+
* 2026-10-28). 이름이 다른 까닭은 뜻이 달라서다 — 색이 바뀔 날 한쪽만 바뀐다.
|
|
63
|
+
* `critical` 은 보안 이벤트 심각도 최상급 전용이다.
|
|
64
|
+
*
|
|
65
|
+
* 목록에 없는 색은 `color` 로 직접 준다. 이 목록과 CSS 의 `.badge--*` 규칙이
|
|
66
|
+
* 어긋나면 `test/badgeSuccessVariant1028.test.tsx` 가 운다.
|
|
58
67
|
*/
|
|
59
68
|
variant?: string;
|
|
60
69
|
/**
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/* 갈래 고르개 — 셋을 세로로 쌓는다. 가로로 늘어놓으면 이름표가 길어 폰에서 줄이 깨진다.
|
|
2
|
+
|
|
3
|
+
**칸을 다 쓰고 왼끝에 맞춘다**(실측 2026-10-28, 창 1365): 그냥 두면 상자가 글자만큼만
|
|
4
|
+
넓어지고(142px) 줄마다 오른끝에 붙어, 셋의 왼끝이 935·967·935 로 **들쭉날쭉**했다.
|
|
5
|
+
읽는 눈이 네모를 세로로 훑는 자리라 그 어긋남이 그대로 보인다. */
|
|
6
|
+
.consent-record-popup__kinds {
|
|
7
|
+
display: flex;
|
|
8
|
+
flex-direction: column;
|
|
9
|
+
align-items: flex-start;
|
|
10
|
+
width: 100%;
|
|
11
|
+
gap: 8px;
|
|
12
|
+
}
|
|
13
|
+
.consent-record-popup__none { color: var(--color-gray); }
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
import './ConsentRecordPopup.css';
|
|
2
|
+
/**
|
|
3
|
+
* 법이 따로 요구하는 동의 갈래 셋 — 화면도 이 차례로 보여 준다.
|
|
4
|
+
*
|
|
5
|
+
* 대장(`customer_consent.kind`)의 CHECK 와 **같은 셋이어야 한다.** 여기만 늘리면 서버가
|
|
6
|
+
* 거절하고, 서버만 늘리면 받을 길이 없다.
|
|
7
|
+
* @public
|
|
8
|
+
*/
|
|
9
|
+
export declare const CONSENT_KINDS: readonly ["personal", "sensitive", "marketing"];
|
|
10
|
+
/** @public */
|
|
11
|
+
export type ConsentKind = (typeof CONSENT_KINDS)[number];
|
|
12
|
+
/** `onSubmit` 이 받는 것 — 서버의 `manager_record_customer_consent` 가 쓰는 꼴 그대로. @public */
|
|
13
|
+
export interface ConsentRecordSubmit {
|
|
14
|
+
/** 이번에 받은 갈래들 — 하나 이상이다(비면 저장 단추가 잠긴다) */
|
|
15
|
+
kinds: string[];
|
|
16
|
+
/** `paper` · `verbal` · `electronic` */
|
|
17
|
+
method: string;
|
|
18
|
+
/** `self` · `guardian` · `referral` */
|
|
19
|
+
source: string;
|
|
20
|
+
/** 받은 날 `YYYY-MM-DD`. 비우면 `null` */
|
|
21
|
+
consentedAt: string | null;
|
|
22
|
+
/** 메모. 공백뿐이면 `null` */
|
|
23
|
+
note: string | null;
|
|
24
|
+
}
|
|
25
|
+
/** @public */
|
|
26
|
+
export interface ConsentRecordPopupProps {
|
|
27
|
+
/**
|
|
28
|
+
* 이미 **살아 있는** 갈래 — 고르개에서 뺀다. 서버가 그런 줄을 안 건드리므로(`DO NOTHING`)
|
|
29
|
+
* 보여 주면 **눌러도 아무 일이 안 나는 칸**이 된다. 다시 받으려면 철회하고 받는다.
|
|
30
|
+
*/
|
|
31
|
+
takenKinds: string[];
|
|
32
|
+
/** 저장하는 중 — 단추와 칸을 잠그고 닫기도 막는다 */
|
|
33
|
+
busy?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* 부르는 쪽이 정한 '오늘'(`YYYY-MM-DD`). 안 주면 KST 오늘이다.
|
|
36
|
+
* 처음 값과 `max`(앞날 막기)에 함께 쓴다. SSR·시험이 날을 못 박는 자리다.
|
|
37
|
+
*/
|
|
38
|
+
today?: string;
|
|
39
|
+
onClose: () => void;
|
|
40
|
+
onSubmit: (args: ConsentRecordSubmit) => void;
|
|
41
|
+
className?: string;
|
|
42
|
+
}
|
|
43
|
+
/**
|
|
44
|
+
* **동의 받기 창** — 갈래를 여럿 한 번에 적는다.
|
|
45
|
+
*
|
|
46
|
+
* 한 상담에서 일반과 민감을 같이 받는 것이 보통이라 갈래마다 따로 부르면 **받은 때가 몇 초씩
|
|
47
|
+
* 갈린다.** 서버가 한 자리에서 같은 `consented_at` 으로 적게 돼 있고, 이 창은 그 한 번에 맞춰
|
|
48
|
+
* 짰다.
|
|
49
|
+
*
|
|
50
|
+
* **받은 날을 손으로 적는다** — 종이로 먼저 받고 나중에 입력하는 자리라, 오늘로 못 박으면
|
|
51
|
+
* 대장이 거짓을 말한다. 앞날은 서버가 거절한다(하루치 여유).
|
|
52
|
+
*
|
|
53
|
+
* **자료를 안 쥔다** — 서버를 안 부르고, 받은 것을 저장하지도 않는다. `takenKinds` 를 받아
|
|
54
|
+
* 그리고 `onSubmit` 으로 돌려줄 뿐이다. 부르는 쪽이 대장을 쥔다.
|
|
55
|
+
*
|
|
56
|
+
* **'오늘' 을 띄울 때마다 다시 센다** — 앱에서 옮겨 올 때 `todayYmd` 가 모듈 첫 줄에서
|
|
57
|
+
* 한 번 정해지는 상수였다. 창을 띄운 채 자정을 넘긴 탭에서는 `max` 가 **어제**라 오늘을
|
|
58
|
+
* 못 고른다. 여기서는 `todayYmdOr()` 를 창이 설 때 부른다.
|
|
59
|
+
*
|
|
60
|
+
* @example
|
|
61
|
+
* <ConsentRecordPopup
|
|
62
|
+
* takenKinds={rows.filter(r => !r.revokedAt).map(r => r.kind)}
|
|
63
|
+
* busy={saving}
|
|
64
|
+
* onClose={close}
|
|
65
|
+
* onSubmit={({ kinds, method, source, consentedAt, note }) => save(…)}
|
|
66
|
+
* />
|
|
67
|
+
* @public
|
|
68
|
+
*/
|
|
69
|
+
export default function ConsentRecordPopup({ takenKinds, busy, today, onClose, onSubmit, className, }: ConsentRecordPopupProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { useState } from 'react';
|
|
4
|
+
import { useTranslation } from 'react-i18next';
|
|
5
|
+
import Popup from './Popup/Popup';
|
|
6
|
+
import Panel, { PanelRow } from './Panel';
|
|
7
|
+
import Checkbox from './Checkbox';
|
|
8
|
+
import SegmentedControl from './SegmentedControl';
|
|
9
|
+
import TextField from './TextField';
|
|
10
|
+
import DatePicker from './DatePicker';
|
|
11
|
+
import Button from './Button';
|
|
12
|
+
import { todayYmdOr } from '../utils/date';
|
|
13
|
+
import './ConsentRecordPopup.css';
|
|
14
|
+
/**
|
|
15
|
+
* 법이 따로 요구하는 동의 갈래 셋 — 화면도 이 차례로 보여 준다.
|
|
16
|
+
*
|
|
17
|
+
* 대장(`customer_consent.kind`)의 CHECK 와 **같은 셋이어야 한다.** 여기만 늘리면 서버가
|
|
18
|
+
* 거절하고, 서버만 늘리면 받을 길이 없다.
|
|
19
|
+
* @public
|
|
20
|
+
*/
|
|
21
|
+
export const CONSENT_KINDS = ['personal', 'sensitive', 'marketing'];
|
|
22
|
+
/**
|
|
23
|
+
* **동의 받기 창** — 갈래를 여럿 한 번에 적는다.
|
|
24
|
+
*
|
|
25
|
+
* 한 상담에서 일반과 민감을 같이 받는 것이 보통이라 갈래마다 따로 부르면 **받은 때가 몇 초씩
|
|
26
|
+
* 갈린다.** 서버가 한 자리에서 같은 `consented_at` 으로 적게 돼 있고, 이 창은 그 한 번에 맞춰
|
|
27
|
+
* 짰다.
|
|
28
|
+
*
|
|
29
|
+
* **받은 날을 손으로 적는다** — 종이로 먼저 받고 나중에 입력하는 자리라, 오늘로 못 박으면
|
|
30
|
+
* 대장이 거짓을 말한다. 앞날은 서버가 거절한다(하루치 여유).
|
|
31
|
+
*
|
|
32
|
+
* **자료를 안 쥔다** — 서버를 안 부르고, 받은 것을 저장하지도 않는다. `takenKinds` 를 받아
|
|
33
|
+
* 그리고 `onSubmit` 으로 돌려줄 뿐이다. 부르는 쪽이 대장을 쥔다.
|
|
34
|
+
*
|
|
35
|
+
* **'오늘' 을 띄울 때마다 다시 센다** — 앱에서 옮겨 올 때 `todayYmd` 가 모듈 첫 줄에서
|
|
36
|
+
* 한 번 정해지는 상수였다. 창을 띄운 채 자정을 넘긴 탭에서는 `max` 가 **어제**라 오늘을
|
|
37
|
+
* 못 고른다. 여기서는 `todayYmdOr()` 를 창이 설 때 부른다.
|
|
38
|
+
*
|
|
39
|
+
* @example
|
|
40
|
+
* <ConsentRecordPopup
|
|
41
|
+
* takenKinds={rows.filter(r => !r.revokedAt).map(r => r.kind)}
|
|
42
|
+
* busy={saving}
|
|
43
|
+
* onClose={close}
|
|
44
|
+
* onSubmit={({ kinds, method, source, consentedAt, note }) => save(…)}
|
|
45
|
+
* />
|
|
46
|
+
* @public
|
|
47
|
+
*/
|
|
48
|
+
export default function ConsentRecordPopup({ takenKinds, busy, today, onClose, onSubmit, className, }) {
|
|
49
|
+
const { t } = useTranslation();
|
|
50
|
+
/* 창이 설 때 한 번 센다 — 모듈이 읽힐 때가 아니다(위 주석) */
|
|
51
|
+
const [todayIso] = useState(() => todayYmdOr(today));
|
|
52
|
+
const [kinds, setKinds] = useState([]);
|
|
53
|
+
const [method, setMethod] = useState('paper');
|
|
54
|
+
const [source, setSource] = useState('self');
|
|
55
|
+
const [day, setDay] = useState(todayIso);
|
|
56
|
+
const [note, setNote] = useState('');
|
|
57
|
+
const pickable = CONSENT_KINDS.filter(k => !takenKinds.includes(k));
|
|
58
|
+
const kindLabel = {
|
|
59
|
+
personal: t('customers.consent.kind.personal', '일반 개인정보'),
|
|
60
|
+
sensitive: t('customers.consent.kind.sensitive', '민감정보(청력·진단)'),
|
|
61
|
+
marketing: t('customers.consent.kind.marketing', '광고성 정보 수신'),
|
|
62
|
+
};
|
|
63
|
+
return (_jsx(Popup, { title: t('customers.consent.record', '동의 받기'), closeDisabled: busy, onClose: onClose, className: className, footer: () => (
|
|
64
|
+
/* 코어의 단추는 `htmlType` 을 밝힌다 — 폼 안에 놓였을 때 제출로 새지 않게.
|
|
65
|
+
앱에서 옮겨 올 때 빠져 있었고 `noSubmitButtonsInCore` 가 잡았다. */
|
|
66
|
+
_jsx(Button, { htmlType: "button", size: 48, variant: "main", disabled: busy || kinds.length === 0, label: t('customers.consent.submit', '저장하기'), onClick: () => onSubmit({
|
|
67
|
+
kinds, method, source,
|
|
68
|
+
consentedAt: day || null,
|
|
69
|
+
note: note.trim() || null,
|
|
70
|
+
}) })), children: _jsxs(Panel, { useBorder: false, useRowBorder: false, labelWidth: 96, children: [_jsx(PanelRow, { variant: "custom", useFullWidth: true, label: t('customers.consent.kinds', '받은 갈래'), children: _jsxs("div", { className: "consent-record-popup__kinds", children: [pickable.map(k => (_jsx(Checkbox, { checked: kinds.includes(k), disabled: busy, label: kindLabel[k], onChange: on => setKinds(was => on ? [...was, k] : was.filter(x => x !== k)) }, k))), pickable.length === 0 && (_jsx("p", { className: "body-3 consent-record-popup__none", children: t('customers.consent.allTaken', '세 갈래를 이미 다 받았습니다. 다시 받으려면 먼저 철회하세요.') }))] }) }), _jsx(PanelRow, { variant: "custom", useFullWidth: true, label: t('customers.consent.methodTitle', '받은 방법'), children: _jsx(SegmentedControl, { size: 40, fullWidth: true, ariaLabel: t('customers.consent.methodTitle', '받은 방법'), options: [
|
|
71
|
+
{ key: 'paper', label: t('customers.consent.method.paper', '서면') },
|
|
72
|
+
{ key: 'verbal', label: t('customers.consent.method.verbal', '구두') },
|
|
73
|
+
{ key: 'electronic', label: t('customers.consent.method.electronic', '전자') },
|
|
74
|
+
], value: method, onChange: v => setMethod(String(v)) }) }), _jsx(PanelRow, { variant: "custom", useFullWidth: true, label: t('customers.consent.sourceTitle', '수집 출처'), children: _jsx(SegmentedControl, { size: 40, fullWidth: true, ariaLabel: t('customers.consent.sourceTitle', '수집 출처'), options: [
|
|
75
|
+
{ key: 'self', label: t('customers.consent.source.self', '본인') },
|
|
76
|
+
{ key: 'guardian', label: t('customers.consent.source.guardian', '보호자') },
|
|
77
|
+
{ key: 'referral', label: t('customers.consent.source.referral', '의뢰기관') },
|
|
78
|
+
], value: source, onChange: v => setSource(String(v)) }) }), _jsx(PanelRow, { variant: "custom", useFullWidth: true, label: t('customers.consent.day', '받은 날'), children: _jsx(DatePicker, { size: 48, value: day, max: todayIso, today: today, onChange: v => setDay(v ?? '') }) }), _jsx(PanelRow, { variant: "custom", useFullWidth: true, label: t('customers.consent.note', '메모'), children: _jsx(TextField, { size: 48, fullWidth: true, value: note, onChange: setNote, disabled: busy, ariaLabel: t('customers.consent.note', '메모'), placeholder: t('customers.consent.notePlaceholder', '의뢰기관 이름 등 — 민감한 내용은 적지 않습니다') }) })] }) }));
|
|
79
|
+
}
|
|
@@ -115,6 +115,8 @@ export type { SectionHeaderProps, SectionHeaderTone } from './components/Section
|
|
|
115
115
|
export { default as CompanyMeta } from './components/CompanyMeta';
|
|
116
116
|
export type { CompanyMetaProps } from './components/CompanyMeta';
|
|
117
117
|
export type { CountTileProps } from './components/CountTile';
|
|
118
|
+
export { default as ConsentRecordPopup, CONSENT_KINDS } from './components/ConsentRecordPopup';
|
|
119
|
+
export type { ConsentRecordPopupProps, ConsentRecordSubmit, ConsentKind, } from './components/ConsentRecordPopup';
|
|
118
120
|
export { default as Toolbar } from './components/Toolbar';
|
|
119
121
|
export type { ToolbarProps, ToolbarCount, ToolbarDropdown } from './components/Toolbar';
|
|
120
122
|
export { default as CodeBox } from './components/CodeBox';
|
|
@@ -76,6 +76,7 @@ export { default as PublicationCard } from './components/PublicationCard';
|
|
|
76
76
|
export { default as SplashLogo } from './components/SplashLogo';
|
|
77
77
|
export { default as SectionHeader } from './components/SectionHeader';
|
|
78
78
|
export { default as CompanyMeta } from './components/CompanyMeta';
|
|
79
|
+
export { default as ConsentRecordPopup, CONSENT_KINDS } from './components/ConsentRecordPopup';
|
|
79
80
|
export { default as Toolbar } from './components/Toolbar';
|
|
80
81
|
export { default as CodeBox } from './components/CodeBox';
|
|
81
82
|
export { default as Loader } from './components/Loader';
|
|
@@ -383,6 +383,32 @@
|
|
|
383
383
|
"minSec": "{{m}}m {{s}}s",
|
|
384
384
|
"min": "{{m}}m",
|
|
385
385
|
"sec": "{{s}}s"
|
|
386
|
+
},
|
|
387
|
+
"consent": {
|
|
388
|
+
"record": "Record consent",
|
|
389
|
+
"kinds": "Kinds given",
|
|
390
|
+
"methodTitle": "How it was given",
|
|
391
|
+
"sourceTitle": "Who gave it",
|
|
392
|
+
"day": "Date given",
|
|
393
|
+
"note": "Note",
|
|
394
|
+
"notePlaceholder": "Referring clinic and the like — do not write anything sensitive",
|
|
395
|
+
"submit": "Save",
|
|
396
|
+
"allTaken": "All three kinds are already on record. Revoke one first to record it again.",
|
|
397
|
+
"kind": {
|
|
398
|
+
"personal": "General personal data",
|
|
399
|
+
"sensitive": "Sensitive data (hearing, diagnosis)",
|
|
400
|
+
"marketing": "Marketing messages"
|
|
401
|
+
},
|
|
402
|
+
"method": {
|
|
403
|
+
"paper": "On paper",
|
|
404
|
+
"verbal": "Spoken",
|
|
405
|
+
"electronic": "Electronic"
|
|
406
|
+
},
|
|
407
|
+
"source": {
|
|
408
|
+
"self": "The customer",
|
|
409
|
+
"guardian": "A guardian",
|
|
410
|
+
"referral": "A referring body"
|
|
411
|
+
}
|
|
386
412
|
}
|
|
387
413
|
},
|
|
388
414
|
"payment": {
|
|
@@ -375,6 +375,32 @@
|
|
|
375
375
|
"minSec": "{{m}}분 {{s}}초",
|
|
376
376
|
"min": "{{m}}분",
|
|
377
377
|
"sec": "{{s}}초"
|
|
378
|
+
},
|
|
379
|
+
"consent": {
|
|
380
|
+
"record": "동의 받기",
|
|
381
|
+
"kinds": "받은 갈래",
|
|
382
|
+
"methodTitle": "받은 방법",
|
|
383
|
+
"sourceTitle": "수집 출처",
|
|
384
|
+
"day": "받은 날",
|
|
385
|
+
"note": "메모",
|
|
386
|
+
"notePlaceholder": "의뢰기관 이름 등 — 민감한 내용은 적지 않습니다",
|
|
387
|
+
"submit": "저장하기",
|
|
388
|
+
"allTaken": "세 갈래를 이미 다 받았습니다. 다시 받으려면 먼저 철회하세요.",
|
|
389
|
+
"kind": {
|
|
390
|
+
"personal": "일반 개인정보",
|
|
391
|
+
"sensitive": "민감정보(청력·진단)",
|
|
392
|
+
"marketing": "광고성 정보 수신"
|
|
393
|
+
},
|
|
394
|
+
"method": {
|
|
395
|
+
"paper": "서면",
|
|
396
|
+
"verbal": "구두",
|
|
397
|
+
"electronic": "전자"
|
|
398
|
+
},
|
|
399
|
+
"source": {
|
|
400
|
+
"self": "본인",
|
|
401
|
+
"guardian": "보호자",
|
|
402
|
+
"referral": "의뢰기관"
|
|
403
|
+
}
|
|
378
404
|
}
|
|
379
405
|
},
|
|
380
406
|
"payment": {
|
|
@@ -193,7 +193,15 @@ export function matchesFilters(word, filterSelected, keys = DEFAULT_PAIR_FILTER_
|
|
|
193
193
|
}
|
|
194
194
|
export function applyFilters(filterSelected, words, keys = DEFAULT_PAIR_FILTER_KEYS) {
|
|
195
195
|
return words.filter(entry => {
|
|
196
|
-
|
|
196
|
+
/* **낱말을 통째로 넘긴다** — 칸을 손으로 하나씩 옮겨 적던 자리다(말귀 청 (345), 2026-10-28).
|
|
197
|
+
(342) 로 `age` 칸이 늘었는데 여기만 안 따라와, 나이 칩 다섯(`3세`~`7세`)이 대립쌍표에서
|
|
198
|
+
**늘 0쌍**이었다. `matchesFilters` 는 바로 읽고 있었으니 **같은 자료로 두 함수가 다른
|
|
199
|
+
답을 냈다** — 에러도 없고 빈 표만 선다. 앱에도 똑같이 손으로 세는 자리가 둘 있었고 둘 다
|
|
200
|
+
같은 흠이었다고 한다(말귀 실측).
|
|
201
|
+
|
|
202
|
+
`FilterableWord` 가 `WordEntry` 의 부분집합이라 통째로 넘겨도 된다. 이제 칸이 늘면
|
|
203
|
+
저절로 따라온다. */
|
|
204
|
+
if (!matchesFilters({ ...entry, syllables: [...entry.word].length }, filterSelected, keys))
|
|
197
205
|
return false;
|
|
198
206
|
/* **의미범주도 다른 넷과 같은 길로 읽는다**(사장님 지시 2026-10-14, 말귀 실측으로 다리는
|
|
199
207
|
필요 없음이 확인됐다 — 앱 소스 0건·저장 구성 416줄 0건).
|