@ihabdevteam/core 0.415.0 → 0.423.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 +617 -1
- package/dist/components.cjs.js +179 -179
- package/dist/components.esm.css +2 -2
- package/dist/hooks.cjs.js +3 -3
- package/dist/i18n.cjs.js +3 -3
- package/dist/ihabdevteam-core.cjs.js +190 -190
- package/dist/ihabdevteam-core.d.ts +199 -8
- package/dist/packages/core/src/components/Badge.css +26 -0
- package/dist/packages/core/src/components/Badge.d.ts +6 -1
- package/dist/packages/core/src/components/BarChart.css +25 -5
- package/dist/packages/core/src/components/Button.css +114 -2
- package/dist/packages/core/src/components/Button.js +3 -2
- package/dist/packages/core/src/components/ChartSection.css +33 -0
- package/dist/packages/core/src/components/ChartSection.d.ts +8 -3
- package/dist/packages/core/src/components/ChartSection.js +106 -4
- package/dist/packages/core/src/components/Header.css +3 -1
- package/dist/packages/core/src/components/Landing/Landing.css +235 -0
- package/dist/packages/core/src/components/Landing/LandingButton.d.ts +31 -0
- package/dist/packages/core/src/components/Landing/LandingButton.js +19 -0
- package/dist/packages/core/src/components/Landing/LandingCard.d.ts +31 -0
- package/dist/packages/core/src/components/Landing/LandingCard.js +21 -0
- package/dist/packages/core/src/components/Landing/LandingSection.d.ts +28 -0
- package/dist/packages/core/src/components/Landing/LandingSection.js +18 -0
- package/dist/packages/core/src/components/Landing/LandingStatBand.d.ts +23 -0
- package/dist/packages/core/src/components/Landing/LandingStatBand.js +90 -0
- package/dist/packages/core/src/components/Landing/LandingTitle.d.ts +34 -0
- package/dist/packages/core/src/components/Landing/LandingTitle.js +26 -0
- package/dist/packages/core/src/components/Popup/DeviceSideTable.js +6 -1
- package/dist/packages/core/src/components/SideNav.css +44 -15
- package/dist/packages/core/src/components/SideNav.js +1 -1
- package/dist/packages/core/src/components/StatChart.d.ts +1 -1
- package/dist/packages/core/src/components/TableField.css +9 -0
- package/dist/packages/core/src/components/Word/wordTableScoring.d.ts +54 -0
- package/dist/packages/core/src/components/Word/wordTableScoring.js +60 -0
- package/dist/packages/core/src/components/WordTable.css +30 -1
- package/dist/packages/core/src/components/WordTable.js +34 -2
- package/dist/packages/core/src/components/barChartData.d.ts +23 -0
- package/dist/packages/core/src/components/barChartData.js +30 -0
- package/dist/packages/core/src/components/buttonTypes.d.ts +35 -2
- package/dist/packages/core/src/components/useBarChartControl.js +17 -13
- package/dist/packages/core/src/components.d.ts +10 -0
- package/dist/packages/core/src/components.js +6 -0
- package/dist/packages/core/src/i18n/locales/en.json +2 -1
- package/dist/packages/core/src/i18n/locales/ko.json +1 -0
- package/dist/packages/core/src/utils/date.d.ts +12 -0
- package/dist/packages/core/src/utils/date.js +18 -0
- package/dist/packages/core/src/version.d.ts +1 -1
- package/dist/packages/core/src/version.js +1 -1
- package/dist/utils.cjs.js +3 -3
- package/package.json +5 -1
|
@@ -66,8 +66,18 @@ const CARD_GAP = 20;
|
|
|
66
66
|
* 더 길면 늘어난다(잘리지 않는다).
|
|
67
67
|
*/
|
|
68
68
|
const CARD_H_SMALL = 120;
|
|
69
|
+
/**
|
|
70
|
+
* `xSmall` 의 가로 — **정사각 120**(사장님 지시 2026-11-03, 말귀_1 청 (372) —
|
|
71
|
+
* *"small은 타이틀과 숫자가 적으면 120*120 으로 고정해서 사용해보고 싶은데"*).
|
|
72
|
+
*
|
|
73
|
+
* 사다리에 맞아떨어진다 — `small` 이 이미 `120×2 + 20` 이라, `xSmall` 둘을 가로로 세우면
|
|
74
|
+
* `small` 하나와 **옆끝이 한 선**에 선다. 안 드는 카드가 `small` 로 내려앉을 때 두 칸
|
|
75
|
+
* (`grid-column: span 2`)을 쓰는 것도 그 셈이다.
|
|
76
|
+
*/
|
|
77
|
+
const CARD_W_XSMALL = 120;
|
|
69
78
|
/** 급 → 가장 낮은 키(px). 적힌 것만 키를 받는다 — 나머지는 속이 정한다 */
|
|
70
79
|
const CARD_MIN_HEIGHT = {
|
|
80
|
+
xSmall: CARD_H_SMALL,
|
|
71
81
|
small: CARD_H_SMALL,
|
|
72
82
|
/** `small` 둘이 위아래로 쌓인 것과 **바닥이 한 선**이 되는 키 — 120×2 + 20 = 260 */
|
|
73
83
|
medium: CARD_H_SMALL * 2 + CARD_GAP,
|
|
@@ -76,10 +86,33 @@ const CARD_MIN_HEIGHT = {
|
|
|
76
86
|
};
|
|
77
87
|
/** 급 → 껍데기에 붙는 꼴. `large` 는 밑바탕이라 붙일 것이 없다 */
|
|
78
88
|
const CARD_SIZE_CLASS = {
|
|
89
|
+
/** 작은 카드의 꼴은 그대로 쓰고, 하한 폭(160)만 푼다 — 그것이 있으면 120 칸을 40 넘친다 */
|
|
90
|
+
xSmall: 'chart-section--compact chart-section--xsmall',
|
|
79
91
|
small: 'chart-section--compact',
|
|
80
92
|
medium: 'chart-section--compact',
|
|
81
93
|
xLarge: 'chart-section--full',
|
|
82
94
|
};
|
|
95
|
+
/** CSS 가 돌려주는 px 글자 하나 — 못 읽으면 0(`normal` · 빈 글) */
|
|
96
|
+
const cssPx = (v) => {
|
|
97
|
+
const n = parseFloat(v);
|
|
98
|
+
return Number.isFinite(n) ? n : 0;
|
|
99
|
+
};
|
|
100
|
+
/**
|
|
101
|
+
* flex 줄의 **속 폭** — 칸(flex item)은 제 속만큼이라, **카드 폭이 변해도 이 수는 안 변한다.**
|
|
102
|
+
*
|
|
103
|
+
* 그것이 이 자를 고른 까닭이다. 같은 것을 `row.scrollWidth > row.clientWidth` 로 재면
|
|
104
|
+
* 120 에서는 맞지만 **260 으로 내려앉은 뒤에는 "든다"** 가 되어 다시 120 으로 올라가고,
|
|
105
|
+
* 카드가 두 폭 사이를 오간다. 재는 수가 카드 폭을 안 보는 쪽이어야 셈이 선다.
|
|
106
|
+
*/
|
|
107
|
+
function rowInkWidth(row) {
|
|
108
|
+
if (!row)
|
|
109
|
+
return 0;
|
|
110
|
+
const kids = Array.from(row.children);
|
|
111
|
+
if (!kids.length)
|
|
112
|
+
return 0;
|
|
113
|
+
const gap = cssPx(getComputedStyle(row).columnGap);
|
|
114
|
+
return kids.reduce((w, k) => w + k.getBoundingClientRect().width, 0) + gap * (kids.length - 1);
|
|
115
|
+
}
|
|
83
116
|
/**
|
|
84
117
|
* 차트 카드 공통 레이아웃 — 제목 헤더 + total/legend 서브로우 + 차트 본체.
|
|
85
118
|
* BarChart와 RingChart 기반 섹션(숙제 진행현황 등)이 동일한 헤더/범례 디자인을
|
|
@@ -89,12 +122,28 @@ const CARD_SIZE_CLASS = {
|
|
|
89
122
|
export default function ChartSection({ type = 'chart', title, titleClassName, titleLevel, icon, disc, headRight, headFloat, headSegment, headMenuItems, collapseBelow = 420, onClick, ariaLabel, tooltip, totalNum, totalUnit, totalMuted = false, totalLabel, change, changeType, size, bodyAlign = 'bottom', subRow, legend, subRowAlign = 'start', className, inGrid = false, fitBody = false, children }) {
|
|
90
123
|
const isStat = type === 'stat';
|
|
91
124
|
/** 안 주면 갈래가 정한다 — 수 칸은 `small`, 차트 카드는 `large`(밑바탕) */
|
|
92
|
-
|
|
125
|
+
/** 부르는 쪽이 **적은** 급 — 재서 내려앉아도 이 값은 안 바뀐다(그래서 셈이 안 돈다) */
|
|
126
|
+
const declaredSize = size ?? (isStat ? 'small' : 'large');
|
|
127
|
+
/* `xSmall` 은 **수 칸 전용**이다 — 속폭 80 에 차트가 설 자리가 없다. 차트 카드가 받으면
|
|
128
|
+
`small` 로 읽는다(반만 듣는 길을 안 남긴다). */
|
|
129
|
+
const wantsXSmall = declaredSize === 'xSmall' && isStat;
|
|
130
|
+
/**
|
|
131
|
+
* **`xSmall` 이 제목과 큰 수를 담나**(말귀_1 청 (372)).
|
|
132
|
+
*
|
|
133
|
+
* 못 쟀으면 `true` — **적힌 급을 그대로 둔다.** 넓히는 것은 쟀을 때만 한다. 0 을 "든다"
|
|
134
|
+
* 로 읽으면 흉내 판·글꼴이 오기 전의 0 이 안전처럼 보인다(아래 `measure` 가 그 0 을 거른다).
|
|
135
|
+
*/
|
|
136
|
+
const [xSmallFits, setXSmallFits] = useState(true);
|
|
137
|
+
const cardSize = declaredSize === 'xSmall' ? (wantsXSmall && xSmallFits ? 'xSmall' : 'small') : declaredSize;
|
|
138
|
+
/** 내려앉은 카드 — 120 격자에서 두 칸을 쓴다 */
|
|
139
|
+
const xSmallFellBack = wantsXSmall && !xSmallFits;
|
|
140
|
+
/** 지금 **그려지는** 급이 120 인가 — 그림씨를 접는 자리다 */
|
|
141
|
+
const isXSmall = cardSize === 'xSmall';
|
|
93
142
|
/* **작은 카드인가** — 글자 단계(아래 `totalRow`)와 꼴이 이것으로 갈린다.
|
|
94
143
|
급에서 바로 읽는다. 2026-11-02 아침까지는 `className` 글자에서 `chart-section--compact`
|
|
95
144
|
를 찾았는데, 그 이름을 붙이는 것은 `RingChart`·`BarChart` 뿐이라 **부르는 쪽이 클래스를
|
|
96
145
|
적어야만 작은 카드가 되는** 꼴이었다. 급을 받으면 그 꼼수가 필요 없다. */
|
|
97
|
-
const isCompact = cardSize === 'small' || cardSize === 'medium';
|
|
146
|
+
const isCompact = cardSize === 'xSmall' || cardSize === 'small' || cardSize === 'medium';
|
|
98
147
|
/* 글자 꼴·머리글 급의 밑바탕이 갈래마다 다르다 — `stat` 의 제목은 작은 이름표(`h5`)이고
|
|
99
148
|
**머리글이 아니다**(급 0). 수 칸이 열 개 서는 화면에서 그것을 다 머리글로 올리면
|
|
100
149
|
낭독기의 층이 수 칸으로 뒤덮인다. */
|
|
@@ -214,6 +263,52 @@ export default function ChartSection({ type = 'chart', title, titleClassName, ti
|
|
|
214
263
|
const minHeight = typeof cardSize === 'number' ? cardSize : CARD_MIN_HEIGHT[cardSize];
|
|
215
264
|
const resolvedChangeType = changeType ?? (change === undefined ? undefined : change > 0 ? 'up' : change < 0 ? 'down' : 'neutral');
|
|
216
265
|
const changeText = change === undefined ? undefined : change > 0 ? `+${change}` : `${change}`;
|
|
266
|
+
/* ── `xSmall` 이 드나 ──────────────────────────────────────────────
|
|
267
|
+
**잘림이 아니라 부풂으로 깨지는 자리다.** 120 카드의 속폭은 80 인데(120 − 여백 19×2 −
|
|
268
|
+
테두리 1×2), 제목이 그보다 길면 두 줄이 되어 **카드 키가 120 을 넘고 정사각이 무너진다**
|
|
269
|
+
(말귀_1 실측 2026-11-03: 129 · 132 · 155). 그래서 넘침을 숨기는 것으로는 안 된다 —
|
|
270
|
+
말줄임으로 박으면 `Sentence …` 가 되어 **무엇의 수인지가 사라진다.**
|
|
271
|
+
|
|
272
|
+
사람이 고를 수 없는 까닭이 둘이다. 수가 자라고(`총 다운로드 수 31,745`), 영어가 거의
|
|
273
|
+
다 안 든다(`Sentence Training` 123 · `Word Training` 95 · `Word Tables` 85 — 셋 다 80 을
|
|
274
|
+
넘는다). 한국어로 맞게 박아 둔 것이 **영어에서 · 수가 자라는 날 조용히 깨진다.**
|
|
275
|
+
그러니 코어가 잰다. */
|
|
276
|
+
/** 제목을 재는 쌍둥이 — 아래 `--probe` 참고(안 보이고, 자리도 안 차지한다) */
|
|
277
|
+
const titleProbeRef = useRef(null);
|
|
278
|
+
/** 큰 수 줄 — 그 **칸들의 속 폭**을 잰다(`rowInkWidth`) */
|
|
279
|
+
const statRowRef = useRef(null);
|
|
280
|
+
useIsoLayoutEffect(() => {
|
|
281
|
+
if (!wantsXSmall)
|
|
282
|
+
return;
|
|
283
|
+
const card = secRef.current;
|
|
284
|
+
if (!card || typeof getComputedStyle !== 'function')
|
|
285
|
+
return;
|
|
286
|
+
const measure = () => {
|
|
287
|
+
/* **속폭은 120 에서 센다** — 지금 카드 폭에서 세면, 내려앉아 260 이 된 카드가 "든다"
|
|
288
|
+
로 읽혀 다시 120 으로 올라가고 둘 사이를 오간다. 여백·테두리는 두 급이 같은 값을
|
|
289
|
+
쓰므로(`--compact`) 이 셈은 어느 쪽에서 돌아도 같은 수를 낸다. */
|
|
290
|
+
const cs = getComputedStyle(card);
|
|
291
|
+
const chrome = cssPx(cs.paddingLeft) + cssPx(cs.paddingRight) + cssPx(cs.borderLeftWidth) + cssPx(cs.borderRightWidth);
|
|
292
|
+
const budget = CARD_W_XSMALL - chrome;
|
|
293
|
+
const need = Math.max(titleProbeRef.current?.getBoundingClientRect().width ?? 0, rowInkWidth(statRowRef.current));
|
|
294
|
+
/* **0 은 '든다' 가 아니다** — 자가 안 닿은 것이다(흉내 판 · 글꼴 오기 전 · 숨은 카드).
|
|
295
|
+
그때는 적힌 급을 그대로 둔다. 0 을 통과로 읽는 못은 조용히 죽는다. */
|
|
296
|
+
if (!(budget > 0) || !(need > 0))
|
|
297
|
+
return;
|
|
298
|
+
/* 0.5 는 소수점 반올림 여유다 — 꼭 맞는 글이 반 픽셀 때문에 내려앉지 않게 */
|
|
299
|
+
setXSmallFits(need <= budget + 0.5);
|
|
300
|
+
};
|
|
301
|
+
measure();
|
|
302
|
+
/* 글꼴이 늦게 오면 폭이 바뀐다 — 쌍둥이와 수 줄을 함께 본다 */
|
|
303
|
+
if (typeof ResizeObserver === 'undefined')
|
|
304
|
+
return;
|
|
305
|
+
const ro = new ResizeObserver(measure);
|
|
306
|
+
if (titleProbeRef.current)
|
|
307
|
+
ro.observe(titleProbeRef.current);
|
|
308
|
+
if (statRowRef.current)
|
|
309
|
+
ro.observe(statRowRef.current);
|
|
310
|
+
return () => ro.disconnect();
|
|
311
|
+
}, [wantsXSmall, title, totalNum, totalUnit, changeText]);
|
|
217
312
|
const tooltipNode = tooltip && tipRect ? (_jsx(TooltipInfo, { anchorRect: {
|
|
218
313
|
left: tipRect.left,
|
|
219
314
|
top: tipRect.top + 21,
|
|
@@ -223,9 +318,16 @@ export default function ChartSection({ type = 'chart', title, titleClassName, ti
|
|
|
223
318
|
height: tipRect.height,
|
|
224
319
|
}, text: tooltip })) : null;
|
|
225
320
|
if (isStat) {
|
|
226
|
-
return (_jsxs("div", { ref: secRef, className: withLegacy(['chart-section', 'chart-section--stat', inGrid && 'chart-section--grid', bodyAlign === 'center' && 'chart-section--body-center', typeof cardSize === 'string' && CARD_SIZE_CLASS[cardSize], onClick && 'chart-section--clickable', className].filter(Boolean).join(' ')), style: minHeight === undefined ? undefined : { minHeight }, onClick: onClick ? onCardClick : undefined, onKeyDown: onClick ? onCardKeyDown : undefined, onPointerEnter: tooltip ? showTip : undefined, onPointerLeave: tooltip ? closeTip : undefined,
|
|
321
|
+
return (_jsxs("div", { ref: secRef, className: withLegacy(['chart-section', 'chart-section--stat', inGrid && 'chart-section--grid', bodyAlign === 'center' && 'chart-section--body-center', typeof cardSize === 'string' && CARD_SIZE_CLASS[cardSize], xSmallFellBack && 'chart-section--span-two', onClick && 'chart-section--clickable', className].filter(Boolean).join(' ')), style: minHeight === undefined ? undefined : { minHeight }, onClick: onClick ? onCardClick : undefined, onKeyDown: onClick ? onCardKeyDown : undefined, onPointerEnter: tooltip ? showTip : undefined, onPointerLeave: tooltip ? closeTip : undefined,
|
|
227
322
|
// hover 전용이면 키보드로는 툴팁 내용을 볼 수 없다
|
|
228
|
-
onFocus: tooltip ? showTip : undefined, onBlur: tooltip ? closeTip : undefined, role: onClick ? 'button' : undefined, tabIndex: onClick ? 0 : undefined, "aria-label": onClick ? (ariaLabel ?? [typeof title === 'string' ? title : undefined, totalNum, changeText].filter(v => v !== undefined && v !== null && v !== '').join(' ')) : undefined, "aria-labelledby": !onClick && title != null ? titleId : undefined, children: [tooltipNode, _jsxs("div", { className: withLegacy("chart-section__head"), children: [_jsx(TitleTag, { id: titleId, className: withLegacy(['chart-section__title', resolvedTitleClass].filter(Boolean).join(' ')), children: title }),
|
|
323
|
+
onFocus: tooltip ? showTip : undefined, onBlur: tooltip ? closeTip : undefined, role: onClick ? 'button' : undefined, tabIndex: onClick ? 0 : undefined, "aria-label": onClick ? (ariaLabel ?? [typeof title === 'string' ? title : undefined, totalNum, changeText].filter(v => v !== undefined && v !== null && v !== '').join(' ')) : undefined, "aria-labelledby": !onClick && title != null ? titleId : undefined, children: [tooltipNode, _jsxs("div", { className: withLegacy("chart-section__head"), children: [_jsx(TitleTag, { id: titleId, className: withLegacy(['chart-section__title', resolvedTitleClass].filter(Boolean).join(' ')), children: title }), wantsXSmall && (
|
|
324
|
+
/* **자(ruler)** — 제목이 120 카드의 속폭에 한 줄로 드나를 재는 쌍둥이다.
|
|
325
|
+
`white-space: nowrap` 인 인라인 상자라 **카드 폭이 변해도 제 속만큼**이고,
|
|
326
|
+
그래서 내려앉은 뒤 다시 재도 같은 수가 나온다. 보이는 제목과 **같은 꼴**을
|
|
327
|
+
달아야 같은 글꼴로 재진다 — `resolvedTitleClass` 를 한 군데서 꺼내 쓴다.
|
|
328
|
+
`TitleTag` 가 아니라 `div` 인 것은 급이 글자 꼴(`h5`)에서 오기 때문이다 —
|
|
329
|
+
`aria-hidden` 이라 낭독기에는 애초에 안 든다. */
|
|
330
|
+
_jsx("div", { ref: titleProbeRef, "aria-hidden": "true", className: withLegacy(['chart-section__title', resolvedTitleClass, 'chart-section__title--probe'].filter(Boolean).join(' ')), children: title })), icon && !isXSmall && (_jsx("span", { className: withLegacy("chart-section__head-icon"), children: _jsx(Icon, { icon: icon, className: withLegacy("chart-section__head-icon-inner") }) }))] }), _jsxs(_Fragment, { children: [_jsxs("div", { ref: statRowRef, className: withLegacy("chart-section__sub-row"), children: [_jsxs(ChartTotal, { children: [_jsx("span", { className: withLegacy([chartTotalNumClass(true), totalMuted && 'chart-section__total__num--muted'].filter(Boolean).join(' ')), children: totalNum }), totalUnit && _jsx("span", { className: withLegacy("chart-section__total__unit body-3"), children: totalUnit })] }), changeText && (_jsx("div", { className: withLegacy(`chart-section__change chart-section__change--${resolvedChangeType ?? 'neutral'} caption-1`), children: changeText }))] }), children && _jsx("div", { className: withLegacy("chart-section__body"), children: children })] })] }));
|
|
229
331
|
}
|
|
230
332
|
return (_jsxs("section", { ref: secRef, className: withLegacy(['chart-section', inGrid && 'chart-section--grid', fitBody && 'chart-section--fit', typeof cardSize === 'string' && CARD_SIZE_CLASS[cardSize], onClick && 'chart-section--clickable', className].filter(Boolean).join(' ')),
|
|
231
333
|
/* **속이 제 키에 맞추는 카드는 키를 박는다**(사장님 지시 2026-11-02 "높이 260 으로
|
|
@@ -226,10 +226,12 @@
|
|
|
226
226
|
펼치면(`:hover`·`:focus-within`) 이 아래가 통째로 안 걸리고 넓은 화면 규칙이 그대로
|
|
227
227
|
산다. 못 박아 접어 둔 레일은 호버해도 안 펼쳐지므로 늘 걸린다 — 그래서 선택자가
|
|
228
228
|
둘씩이다. */
|
|
229
|
+
/* 좌우 여백은 **값 하나(`--rail-pad`)로** 정한다(2026-11-03) — 목록이 그 값만큼 밖으로 폈다가
|
|
230
|
+
안으로 되돌리므로, 여기서 패딩을 직접 적으면 둘이 어긋난다. 변수만 바꾼다. */
|
|
229
231
|
.header:not(:hover):not(:focus-within) .side-nav__menu,
|
|
230
232
|
.header--force-collapsed .side-nav__menu {
|
|
231
233
|
/* 좌우는 여백만으로 같다(실측 8px 기준: 좌 9 / 우 9, 항목 52) */
|
|
232
|
-
|
|
234
|
+
--rail-pad: var(--spacing-xs);
|
|
233
235
|
}
|
|
234
236
|
|
|
235
237
|
.header:not(:hover):not(:focus-within) .side-nav__item,
|
|
@@ -0,0 +1,235 @@
|
|
|
1
|
+
/* ── Landing ───────────────────────────────────
|
|
2
|
+
랜딩(소개) 쪽을 짓는 부품들이 함께 쓰는 꼴.
|
|
3
|
+
|
|
4
|
+
**수는 전부 토큰이다** — 여백·모서리·글자·색 가운데 손으로 적은 수는 없다.
|
|
5
|
+
말귀 랜딩 시안(2026-11-04~05)에서 재어 맞춘 값이고, 거기서 쓰던 `.lv2-*` 이름을
|
|
6
|
+
코어로 옮기며 제 이름으로 바꿨다. */
|
|
7
|
+
|
|
8
|
+
/* 구획 — 위아래 여백은 늘 쪽 여백의 두 배다 */
|
|
9
|
+
.landing-section {
|
|
10
|
+
padding: calc(var(--spacing-page) * 2) 0;
|
|
11
|
+
}
|
|
12
|
+
.landing-section--line { border-top: 1px solid var(--color-darkWhite); }
|
|
13
|
+
|
|
14
|
+
/* 구획 — 안쪽 틀. 쪽 가운데로 모으고 좌우에 쪽 여백을 준다 */
|
|
15
|
+
.landing-section__inner {
|
|
16
|
+
max-width: var(--container-page);
|
|
17
|
+
margin: 0 auto;
|
|
18
|
+
padding-inline: var(--spacing-page);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/* 구획 머리 */
|
|
22
|
+
.landing-title__text {
|
|
23
|
+
/* 윗 여백은 쓰는 쪽이 제 변수로 고른다(`--landing-title-gap`). **아래는 0 이다** —
|
|
24
|
+
h2 의 기본 아래 여백을 안 지우면 구획마다 20px 씩 늘어난다(실측 2026-11-05, +733px). */
|
|
25
|
+
margin: var(--landing-title-gap, var(--spacing-m)) 0 0;
|
|
26
|
+
font-size: var(--text-display-2-size);
|
|
27
|
+
font-weight: var(--text-display-2-weight-bold);
|
|
28
|
+
letter-spacing: var(--text-display-2-spacing);
|
|
29
|
+
/* **행간만 토큰보다 넓다**(1.12 → 1.3) — 구획 머리는 한글 두 줄로 쓰는 자리라, 꽉 찬
|
|
30
|
+
글자들이 두 줄에서 서로 붙어 보였다(말귀 사장님 지시 2026-11-06). 글자 크기·굵기·자간은
|
|
31
|
+
`display-2` 그대로다. 토큰 쪽을 넓히지 않은 까닭 — `display-2` 를 한 줄짜리 큰 글에
|
|
32
|
+
쓰는 자리가 따로 있어, 거기까지 벌어진다. */
|
|
33
|
+
line-height: 1.3;
|
|
34
|
+
}
|
|
35
|
+
.landing-title__text--no-gap { margin-top: 0; }
|
|
36
|
+
/* 설명 아래에 **한 칸 더** — 뒤따르는 칸·판이 제 윗 여백(`--spacing-xl`)만 쥐고 있어
|
|
37
|
+
머리와 내용이 24px 로 붙어 있었다(말귀 사장님 지시 2026-11-06). 합쳐 48px 이 된다.
|
|
38
|
+
|
|
39
|
+
**아래쪽은 `margin` 이 아니라 `padding` 이다** — 형제끼리의 세로 여백은 겹쳐서 큰 쪽
|
|
40
|
+
하나만 남는다(margin 24 + margin 24 = 24. 처음에 그렇게 적었다가 수가 안 늘어 잡았다). */
|
|
41
|
+
.landing-title__sub {
|
|
42
|
+
font-size: var(--text-body-1-size);
|
|
43
|
+
line-height: var(--text-body-1-line);
|
|
44
|
+
color: var(--color-darkGray);
|
|
45
|
+
margin: var(--spacing-s) 0 0;
|
|
46
|
+
padding-bottom: var(--spacing-xl);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
/* 칸 */
|
|
50
|
+
/* 테두리는 `--color-darkWhite` 다 — `--color-whiteLine` 은 또렷해서 칸이 많을 때 줄이 셌다
|
|
51
|
+
(말귀 사장님 지시 2026-11-06). */
|
|
52
|
+
.landing-card {
|
|
53
|
+
background: var(--color-pureWhite);
|
|
54
|
+
border: 1px solid var(--color-darkWhite);
|
|
55
|
+
border-radius: var(--radius-m);
|
|
56
|
+
}
|
|
57
|
+
/* 칸 제목은 **한 크기뿐이다**(말귀 사장님 지시 2026-11-06) — `big` 으로 두 크기를 두었더니
|
|
58
|
+
같은 쪽 안에서 24px 과 17px 이 섞여 어느 것이 큰 자리인지 안 읽혔다.
|
|
59
|
+
|
|
60
|
+
**자는 `h3` 것이다** — 요소가 `h3` 인데 `--text-h2` 를 입혀 두었더니 이름과 자가 어긋났다
|
|
61
|
+
(사장님이 짚으심 2026-11-06). 구획 머리가 `h2`(display-2), 칸 제목이 `h3` 로 한 단계 아래다. */
|
|
62
|
+
.landing-card__title {
|
|
63
|
+
font-size: var(--text-h3-size);
|
|
64
|
+
font-weight: var(--text-h3-weight-bold);
|
|
65
|
+
line-height: var(--text-h3-line);
|
|
66
|
+
margin: var(--spacing-m) 0 0;
|
|
67
|
+
}
|
|
68
|
+
.landing-card--row {
|
|
69
|
+
display: flex;
|
|
70
|
+
align-items: flex-start;
|
|
71
|
+
gap: var(--spacing-xl);
|
|
72
|
+
flex-wrap: wrap;
|
|
73
|
+
}
|
|
74
|
+
.landing-card__lead { flex: none; }
|
|
75
|
+
.landing-card__panel {
|
|
76
|
+
flex: 1;
|
|
77
|
+
min-width: 360px;
|
|
78
|
+
background: var(--color-deepWhite);
|
|
79
|
+
border-radius: var(--radius-s);
|
|
80
|
+
padding: var(--spacing-l);
|
|
81
|
+
}
|
|
82
|
+
/* 가운데 꼴 — 아이콘이 `div` 라 `text-align` 만으로는 안 가운데로 간다 */
|
|
83
|
+
.landing-card--center {
|
|
84
|
+
display: flex;
|
|
85
|
+
flex-direction: column;
|
|
86
|
+
align-items: center;
|
|
87
|
+
text-align: center;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.landing-card--pad { padding: var(--spacing-xl); }
|
|
91
|
+
.landing-card--pad-tight { padding: var(--spacing-l) var(--spacing-xl); }
|
|
92
|
+
|
|
93
|
+
.landing-card__desc {
|
|
94
|
+
font-size: var(--text-body-3-size);
|
|
95
|
+
line-height: var(--text-body-3-line);
|
|
96
|
+
color: var(--color-darkGray);
|
|
97
|
+
margin: var(--spacing-xs) 0 0;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
/* 큰 단추 — 쪽에서 무언가로 넘어가는 자리 */
|
|
101
|
+
.landing-button {
|
|
102
|
+
display: inline-flex;
|
|
103
|
+
align-items: center;
|
|
104
|
+
justify-content: center;
|
|
105
|
+
gap: var(--spacing-s);
|
|
106
|
+
box-sizing: border-box;
|
|
107
|
+
height: var(--btn-height, 60px);
|
|
108
|
+
padding: 0 var(--spacing-xl);
|
|
109
|
+
border: 1px solid transparent;
|
|
110
|
+
border-radius: var(--radius-m);
|
|
111
|
+
background: var(--color-black);
|
|
112
|
+
color: var(--color-pureWhite);
|
|
113
|
+
font-size: var(--text-h4-size);
|
|
114
|
+
font-weight: var(--text-h4-weight-bold);
|
|
115
|
+
text-decoration: none;
|
|
116
|
+
cursor: pointer;
|
|
117
|
+
}
|
|
118
|
+
.landing-button:hover { background: var(--color-black); color: var(--color-pureWhite); }
|
|
119
|
+
|
|
120
|
+
.landing-button--main { background: var(--color-main); color: var(--color-pureWhite); }
|
|
121
|
+
.landing-button--main:hover { background: var(--color-main); color: var(--color-pureWhite); }
|
|
122
|
+
.landing-button--sub { background: var(--color-sub); border-color: var(--color-sub); color: var(--color-black); }
|
|
123
|
+
.landing-button--sub:hover { background: var(--color-sub); color: var(--color-black); }
|
|
124
|
+
.landing-button--line { background: var(--color-pureWhite); border-color: var(--color-whiteLine); color: var(--color-black); }
|
|
125
|
+
.landing-button--line:hover { background: var(--color-pureWhite); color: var(--color-black); }
|
|
126
|
+
|
|
127
|
+
/* 수 띠 — 겉틀이 **그라데이션 그림자**를 쥔다.
|
|
128
|
+
|
|
129
|
+
`box-shadow` 는 한 색뿐이라 띠처럼 두 색으로 번지게 둘 수 없다(사장님 물음 2026-11-06).
|
|
130
|
+
그래서 띠와 **같은 그라데이션을 흐려서** 뒤에 깐다 — 색이 자리마다 달라져 바닥에 번진다.
|
|
131
|
+
띠가 둥실 뜰 때 이쪽은 더 멀리 · 더 옅게 · 더 흐리게 퍼져 '높이 떴다' 가 보인다. */
|
|
132
|
+
.landing-stat-band-wrap {
|
|
133
|
+
position: relative;
|
|
134
|
+
|
|
135
|
+
/* **그림자가 설 자리**를 아래에 비운다 — 그림자는 띠 밖 20px 아래까지 내려가는데
|
|
136
|
+
자리를 안 먹어서, 다음 구획이 바짝 붙어 보였다(말귀 사장님 지시 2026-11-06).
|
|
137
|
+
`margin` 이 아니라 `padding` 이다 — 겹쳐서 사라지지 않게. */
|
|
138
|
+
padding-bottom: var(--spacing-page);
|
|
139
|
+
|
|
140
|
+
/* 띠의 그라데이션은 **한 자리에만 적는다** — 그림자가 같은 그라데이션을 흐린 사본이라,
|
|
141
|
+
두 군데 적으면 한쪽만 바뀌어 색이 어긋난다.
|
|
142
|
+
|
|
143
|
+
**두 색뿐이다** — 끝에 포인트 색(따뜻한 금빛 · 채도 올린 보조색)을 한 자락 둬 봤으나
|
|
144
|
+
사장님이 걷으라 하셨다(2026-11-06).
|
|
145
|
+
|
|
146
|
+
**크기는 `farthest-corner` 다** — 비율(`135% 260%`)로 적으면 원이 띠보다 커져 끝 색이
|
|
147
|
+
띠 밖에 떨어진다. 이 값이라야 100% 가 가장 먼 모서리(오른쪽 아래)에 딱 닿는다. */
|
|
148
|
+
--landing-band-gradient: radial-gradient(farthest-corner at 0% 0%,
|
|
149
|
+
var(--color-main) 0%,
|
|
150
|
+
var(--color-sub) 100%);
|
|
151
|
+
}
|
|
152
|
+
.landing-stat-band-wrap::before {
|
|
153
|
+
content: '';
|
|
154
|
+
position: absolute;
|
|
155
|
+
/* 왼쪽은 24px 안으로 · **오른쪽은 36px 밖으로** — 빛이 왼쪽 위에서 드는 꼴이다(사장님 지시).
|
|
156
|
+
**늘리기(`scaleX`)가 아니라 고정 px 이다** — 비율로 늘리면 넓은 화면에서 쪽 여백(60)을
|
|
157
|
+
넘어 가로 스크롤이 생긴다(1722px 에서 18px 넘쳤다). */
|
|
158
|
+
inset: 0 -36px 0 24px;
|
|
159
|
+
border-radius: var(--radius-m);
|
|
160
|
+
background: var(--landing-band-gradient);
|
|
161
|
+
animation: landing-stat-band-glow 6s ease-in-out infinite;
|
|
162
|
+
/* 움직임을 줄이면 전역 규칙이 애니메이션을 멈춘다 — 그때 설 자리를 여기 적어 둔다 */
|
|
163
|
+
opacity: 0.36;
|
|
164
|
+
filter: blur(28px);
|
|
165
|
+
transform: translateY(10px) scaleY(0.95);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
@keyframes landing-stat-band-glow {
|
|
169
|
+
0%, 100% { opacity: 0.36; filter: blur(28px); transform: translateY(10px) scaleY(0.95); }
|
|
170
|
+
50% { opacity: 0.28; filter: blur(38px); transform: translateY(20px) scaleY(0.91); }
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
/* 수 띠 */
|
|
174
|
+
.landing-stat-band {
|
|
175
|
+
position: relative; /* 흐린 사본 위에 선다 */
|
|
176
|
+
z-index: 1;
|
|
177
|
+
display: grid;
|
|
178
|
+
gap: var(--spacing-xl);
|
|
179
|
+
background: var(--landing-band-gradient);
|
|
180
|
+
border-radius: var(--radius-m);
|
|
181
|
+
/* **둥실둥실** — 6초에 한 번 8px 떴다 가라앉는다(말귀 사장님 지시). 그림자도 함께
|
|
182
|
+
옅어졌다 짙어져서 '떠 있다' 가 보인다. 눈이 쫓을 만큼 빠르면 글을 못 읽으니 느리다.
|
|
183
|
+
'동작 줄이기' 가 켜지면 `styles.css` 의 전역 규칙이 이 움직임을 멈춘다. */
|
|
184
|
+
animation: landing-stat-band-float 6s ease-in-out infinite;
|
|
185
|
+
/* 좌우는 `--spacing-page` 다 — 24 는 수가 띠 끝에 바싹 붙었다(말귀 사장님 지시).
|
|
186
|
+
이 토큰은 폭에 따라 60 → 40 → 20 으로 줄어, 좁은 쪽에서 수가 눌리지 않는다. */
|
|
187
|
+
padding: var(--spacing-xl) var(--spacing-page);
|
|
188
|
+
}
|
|
189
|
+
.landing-stat-band__value {
|
|
190
|
+
font-size: var(--text-display-2-size);
|
|
191
|
+
font-weight: var(--text-display-2-weight-bold);
|
|
192
|
+
letter-spacing: var(--text-display-2-spacing);
|
|
193
|
+
line-height: var(--text-display-2-line);
|
|
194
|
+
color: var(--color-black);
|
|
195
|
+
margin: 0;
|
|
196
|
+
}
|
|
197
|
+
.landing-title__sub--on-band { color: var(--color-pureWhite); }
|
|
198
|
+
|
|
199
|
+
/* 가운데 꼴 — 글자만이 아니라 **폭이 좁혀진 칸 자신도** 가운데로 보낸다(`margin: auto`).
|
|
200
|
+
안 그러면 `maxWidth` 가 걸린 큰 글이 왼쪽에 붙은 채 글자만 가운데로 모인다. */
|
|
201
|
+
.landing-title__badge--center { text-align: center; }
|
|
202
|
+
.landing-title__text--center,
|
|
203
|
+
.landing-title__sub--center {
|
|
204
|
+
text-align: center;
|
|
205
|
+
margin-left: auto;
|
|
206
|
+
margin-right: auto;
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
/* 이름표도 본색이다 — 띠 위의 회색은 흐렸다(말귀 사장님 지시).
|
|
210
|
+
검정은 띠의 두 끝 어디에서나 또렷하다(주색 위 6.39:1 · 보조색 위 9.72:1). */
|
|
211
|
+
@keyframes landing-stat-band-float {
|
|
212
|
+
0%, 100% { transform: translateY(0); }
|
|
213
|
+
50% { transform: translateY(-8px); }
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/* 눈에는 안 보이고 낭독기에만 가는 글 — 수가 올라가는 동안에도 들리는 것은 최종값 하나다.
|
|
217
|
+
`display:none` 이면 낭독기도 못 읽으니 잘라서 숨긴다. */
|
|
218
|
+
.landing-stat-band__sr {
|
|
219
|
+
position: absolute;
|
|
220
|
+
width: 1px;
|
|
221
|
+
height: 1px;
|
|
222
|
+
margin: -1px;
|
|
223
|
+
padding: 0;
|
|
224
|
+
overflow: hidden;
|
|
225
|
+
clip-path: inset(50%);
|
|
226
|
+
white-space: nowrap;
|
|
227
|
+
border: 0;
|
|
228
|
+
}
|
|
229
|
+
|
|
230
|
+
.landing-stat-band__label {
|
|
231
|
+
font-size: var(--text-body-3-size);
|
|
232
|
+
font-weight: var(--text-body-3-weight-bold);
|
|
233
|
+
color: var(--color-black);
|
|
234
|
+
margin: var(--spacing-xs) 0 0;
|
|
235
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import './Landing.css';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface LandingButtonProps {
|
|
5
|
+
href: string;
|
|
6
|
+
/**
|
|
7
|
+
* 단추의 꼴
|
|
8
|
+
* · `dark` — 검정 바탕에 흰 글씨(기본)
|
|
9
|
+
* · `main` — 주색 바탕에 흰 글씨
|
|
10
|
+
* · `sub` — 보조색 바탕에 검정 글씨
|
|
11
|
+
* · `line` — 흰 바탕에 선만
|
|
12
|
+
*/
|
|
13
|
+
tone?: 'dark' | 'main' | 'sub' | 'line';
|
|
14
|
+
/** 뒤에 화살표(루시드 `chevron-right`)를 붙인다 */
|
|
15
|
+
arrow?: boolean;
|
|
16
|
+
className?: string;
|
|
17
|
+
children: ReactNode;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* **랜딩의 큰 단추** — 쪽에서 무언가로 넘어가는 자리.
|
|
21
|
+
*
|
|
22
|
+
* 키 60 · 모서리 `--radius-m` · 글자 h4 굵게는 네 꼴이 늘 같다. 화살표는 루시드
|
|
23
|
+
* `chevron-right` 24px — 글자(h4 18px)보다 또렷이 크게 두어야 눈에 든다(16 · 20 은 작았다).
|
|
24
|
+
*
|
|
25
|
+
* **주색 위 흰 글씨는 2.96 : 1** 로 본문 기준(4.5) 아래다 — 코어 기본 단추
|
|
26
|
+
* (`Button variant="main"`)가 쓰는 바로 그 짝이라 제품 전체가 같은 꼴이다. 더 또렷해야 하는
|
|
27
|
+
* 자리라면 `--color-infoLink`(흰 글씨 4.14) 쪽을 쓴다.
|
|
28
|
+
*
|
|
29
|
+
* @public
|
|
30
|
+
*/
|
|
31
|
+
export default function LandingButton({ href, tone, arrow, className, children }: LandingButtonProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { cx } from '../../utils/cx';
|
|
4
|
+
import './Landing.css';
|
|
5
|
+
/**
|
|
6
|
+
* **랜딩의 큰 단추** — 쪽에서 무언가로 넘어가는 자리.
|
|
7
|
+
*
|
|
8
|
+
* 키 60 · 모서리 `--radius-m` · 글자 h4 굵게는 네 꼴이 늘 같다. 화살표는 루시드
|
|
9
|
+
* `chevron-right` 24px — 글자(h4 18px)보다 또렷이 크게 두어야 눈에 든다(16 · 20 은 작았다).
|
|
10
|
+
*
|
|
11
|
+
* **주색 위 흰 글씨는 2.96 : 1** 로 본문 기준(4.5) 아래다 — 코어 기본 단추
|
|
12
|
+
* (`Button variant="main"`)가 쓰는 바로 그 짝이라 제품 전체가 같은 꼴이다. 더 또렷해야 하는
|
|
13
|
+
* 자리라면 `--color-infoLink`(흰 글씨 4.14) 쪽을 쓴다.
|
|
14
|
+
*
|
|
15
|
+
* @public
|
|
16
|
+
*/
|
|
17
|
+
export default function LandingButton({ href, tone = 'dark', arrow = false, className, children }) {
|
|
18
|
+
return (_jsxs("a", { className: cx('landing-button', tone !== 'dark' && `landing-button--${tone}`, className), href: href, children: [children, arrow ? (_jsx("svg", { "aria-hidden": "true", width: "24", height: "24", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", style: { flex: 'none' }, children: _jsx("path", { d: "m9 18 6-6-6-6" }) })) : null] }));
|
|
19
|
+
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { CSSProperties, ReactNode } from 'react';
|
|
2
|
+
import './Landing.css';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface LandingCardProps {
|
|
5
|
+
/** 아이콘 칸 — 보통 `CategoryIcon` 을 넣는다 */
|
|
6
|
+
icon?: ReactNode;
|
|
7
|
+
title?: ReactNode;
|
|
8
|
+
desc?: ReactNode;
|
|
9
|
+
/** 제목·설명 아래(또는 줄 꼴이면 오른쪽)에 붙는 것 */
|
|
10
|
+
children?: ReactNode;
|
|
11
|
+
/** `row` 면 아이콘·제목이 왼쪽 칸에 서고 children 이 오른쪽에 붙는다 */
|
|
12
|
+
layout?: 'stack' | 'row';
|
|
13
|
+
/** 왼쪽 칸의 폭 — `row` 일 때만 */
|
|
14
|
+
leadWidth?: number;
|
|
15
|
+
/** 제목 줄에만 더 얹는 꼴 */
|
|
16
|
+
titleStyle?: CSSProperties;
|
|
17
|
+
/** 안쪽 여백을 좁게 */
|
|
18
|
+
tight?: boolean;
|
|
19
|
+
/** 아이콘·글을 칸 가운데로 (`stack` 일 때만) */
|
|
20
|
+
align?: 'left' | 'center';
|
|
21
|
+
className?: string;
|
|
22
|
+
style?: CSSProperties;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* **랜딩의 칸 하나** — 흰 바탕에 선을 두른 상자.
|
|
26
|
+
*
|
|
27
|
+
* 두 꼴뿐이다 — 아이콘이 윗줄에 서는 `stack`, 왼쪽에 서고 오른쪽에 내용이 붙는 `row`.
|
|
28
|
+
*
|
|
29
|
+
* @public
|
|
30
|
+
*/
|
|
31
|
+
export default function LandingCard({ icon, title, desc, children, layout, leadWidth, titleStyle, tight, align, className, style, }: LandingCardProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
|
+
import { cx } from '../../utils/cx';
|
|
4
|
+
import './Landing.css';
|
|
5
|
+
/**
|
|
6
|
+
* **랜딩의 칸 하나** — 흰 바탕에 선을 두른 상자.
|
|
7
|
+
*
|
|
8
|
+
* 두 꼴뿐이다 — 아이콘이 윗줄에 서는 `stack`, 왼쪽에 서고 오른쪽에 내용이 붙는 `row`.
|
|
9
|
+
*
|
|
10
|
+
* @public
|
|
11
|
+
*/
|
|
12
|
+
export default function LandingCard({ icon, title, desc, children, layout = 'stack', leadWidth = 300, titleStyle, tight = false, align = 'left', className, style, }) {
|
|
13
|
+
/* 여백·바탕·모서리는 **CSS 가 쥔다**(코어 `inlineVarIsInvisible1020` — 인라인 `var()` 는
|
|
14
|
+
jsdom 이 버려서 시험이 그 자리를 못 본다). 인라인은 쓰는 쪽이 준 것과 폭 수치뿐이다. */
|
|
15
|
+
const pad = tight ? 'landing-card--pad-tight' : 'landing-card--pad';
|
|
16
|
+
const head = (_jsxs(_Fragment, { children: [icon, title ? _jsx("h3", { className: "landing-card__title", style: titleStyle, children: title }) : null, desc ? _jsx("p", { className: "landing-card__desc", children: desc }) : null] }));
|
|
17
|
+
if (layout === 'row') {
|
|
18
|
+
return (_jsxs("div", { className: cx('landing-card', 'landing-card--row', pad, className), style: style, children: [_jsx("div", { className: "landing-card__lead", style: { width: `${leadWidth}px` }, children: head }), _jsx("div", { className: "landing-card__panel", children: children })] }));
|
|
19
|
+
}
|
|
20
|
+
return (_jsxs("div", { className: cx('landing-card', pad, align === 'center' && 'landing-card--center', className), style: style, children: [head, children] }));
|
|
21
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import type { CSSProperties, ReactNode } from 'react';
|
|
2
|
+
import './Landing.css';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface LandingSectionProps {
|
|
5
|
+
/** 닻 이름 — 맨 위 띠의 고리가 이것으로 찾아온다 */
|
|
6
|
+
id?: string;
|
|
7
|
+
/**
|
|
8
|
+
* 구획의 꼴.
|
|
9
|
+
* · `plain` — 그냥 선다(기본)
|
|
10
|
+
* · `line` — 위에 선 하나를 긋는다(갈래가 바뀌는 자리)
|
|
11
|
+
*/
|
|
12
|
+
tone?: 'plain' | 'line';
|
|
13
|
+
/** 속틀을 안 쓴다 — 띠가 화면 끝까지 가는 자리 */
|
|
14
|
+
bare?: boolean;
|
|
15
|
+
className?: string;
|
|
16
|
+
style?: CSSProperties;
|
|
17
|
+
children?: ReactNode;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* **랜딩 구획 하나** — 위아래 여백과 안쪽 틀을 한 자리에 둔다.
|
|
21
|
+
*
|
|
22
|
+
* 위아래 여백은 늘 **쪽 여백의 두 배**다(말귀 랜딩 시안, 2026-11-04 — *"섹션에 위아래 여백이
|
|
23
|
+
* 많이 부족해보이는데 답답해보여"*). 그 수를 구획마다 적어 두면 다음에 고칠 때 한둘이 빠지고,
|
|
24
|
+
* 빠진 자리는 눈으로만 잡힌다.
|
|
25
|
+
*
|
|
26
|
+
* @public
|
|
27
|
+
*/
|
|
28
|
+
export default function LandingSection({ id, tone, bare, className, style, children }: LandingSectionProps): import("react").JSX.Element;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import { cx } from '../../utils/cx';
|
|
4
|
+
import './Landing.css';
|
|
5
|
+
/**
|
|
6
|
+
* **랜딩 구획 하나** — 위아래 여백과 안쪽 틀을 한 자리에 둔다.
|
|
7
|
+
*
|
|
8
|
+
* 위아래 여백은 늘 **쪽 여백의 두 배**다(말귀 랜딩 시안, 2026-11-04 — *"섹션에 위아래 여백이
|
|
9
|
+
* 많이 부족해보이는데 답답해보여"*). 그 수를 구획마다 적어 두면 다음에 고칠 때 한둘이 빠지고,
|
|
10
|
+
* 빠진 자리는 눈으로만 잡힌다.
|
|
11
|
+
*
|
|
12
|
+
* @public
|
|
13
|
+
*/
|
|
14
|
+
export default function LandingSection({ id, tone = 'plain', bare = false, className, style, children }) {
|
|
15
|
+
/* 여백과 선은 **CSS 가 쥔다** — 인라인에 `var()` 를 주면 jsdom 이 버려서 시험이 그 자리를
|
|
16
|
+
못 본다(코어 `inlineVarIsInvisible1020`). 쓰는 쪽이 준 `style` 만 그대로 얹는다. */
|
|
17
|
+
return (_jsx("section", { id: id, className: cx('landing-section', tone === 'line' && 'landing-section--line', className), style: style, children: bare ? children : _jsx("div", { className: "landing-section__inner", children: children }) }));
|
|
18
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import './Landing.css';
|
|
3
|
+
/** @public */
|
|
4
|
+
export interface LandingStat {
|
|
5
|
+
value: ReactNode;
|
|
6
|
+
label: ReactNode;
|
|
7
|
+
}
|
|
8
|
+
/** @public */
|
|
9
|
+
export interface LandingStatBandProps {
|
|
10
|
+
stats: LandingStat[];
|
|
11
|
+
className?: string;
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* **수 띠** — 큰 수 몇을 그라데이션 띠 위에 나란히 세운다.
|
|
15
|
+
*
|
|
16
|
+
* 수는 **받아서만** 쓴다 — 지어낸 수를 띄우면 쪽 전체가 못 믿을 것이 된다.
|
|
17
|
+
*
|
|
18
|
+
* **띠가 화면에 들어오면 수가 0 에서 올라간다**(1.2초, 한 번만). 올라가는 동안의 수는
|
|
19
|
+
* 낭독기에 안 보낸다 — 들리는 것은 늘 최종값 하나다.
|
|
20
|
+
*
|
|
21
|
+
* @public
|
|
22
|
+
*/
|
|
23
|
+
export default function LandingStatBand({ stats, className }: LandingStatBandProps): import("react").JSX.Element;
|