open-grid 1.4.0 → 1.5.1

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 (54) hide show
  1. package/CHANGELOG.md +59 -0
  2. package/README.md +18 -1
  3. package/dist/{OpenGrid-BOtTt5aI.cjs → OpenGrid-CT9bV6On.cjs} +7 -7
  4. package/dist/OpenGrid-CT9bV6On.cjs.map +1 -0
  5. package/dist/{OpenGrid-sI_vdHQw.js → OpenGrid-DACnZdEy.js} +7 -7
  6. package/dist/OpenGrid-DACnZdEy.js.map +1 -0
  7. package/dist/Registry-CPJYOqCn.js.map +1 -0
  8. package/dist/Registry-D74ZmdDz.cjs.map +1 -0
  9. package/dist/{index-D1l3XFCM.cjs → index-Brfso4Ry.cjs} +2 -2
  10. package/dist/index-Brfso4Ry.cjs.map +1 -0
  11. package/dist/index-CeJ-0-80.cjs.map +1 -0
  12. package/dist/index-DnarQ4eR.js.map +1 -0
  13. package/dist/{index-B3fKi43v.js → index-al9Mbv3E.js} +2 -2
  14. package/dist/index-al9Mbv3E.js.map +1 -0
  15. package/dist/open-grid-base.css +98 -35
  16. package/dist/open-grid-header.cjs +188 -0
  17. package/dist/open-grid-header.cjs.map +1 -0
  18. package/dist/open-grid-header.css +386 -0
  19. package/dist/open-grid-header.js +197 -0
  20. package/dist/open-grid-header.js.map +1 -0
  21. package/dist/open-grid-react.cjs +1 -1
  22. package/dist/open-grid-react.cjs.map +1 -0
  23. package/dist/open-grid-react.js +1 -1
  24. package/dist/open-grid-react.js.map +1 -0
  25. package/dist/open-grid-themes.css +774 -1
  26. package/dist/open-grid-typography.cjs +97 -0
  27. package/dist/open-grid-typography.cjs.map +1 -0
  28. package/dist/open-grid-typography.css +181 -0
  29. package/dist/open-grid-typography.js +105 -0
  30. package/dist/open-grid-typography.js.map +1 -0
  31. package/dist/open-grid-vue.cjs +1 -1
  32. package/dist/open-grid-vue.cjs.map +1 -0
  33. package/dist/open-grid-vue.js +1 -1
  34. package/dist/open-grid-vue.js.map +1 -0
  35. package/dist/open-grid.cjs +1 -1
  36. package/dist/open-grid.cjs.map +1 -0
  37. package/dist/open-grid.js +2 -2
  38. package/dist/open-grid.js.map +1 -0
  39. package/dist/types/core/DetailManager.d.ts +2 -2
  40. package/dist/types/core/FormulaController.d.ts +2 -2
  41. package/dist/types/core/MutationService.d.ts +2 -2
  42. package/dist/types/core/OpenGrid.d.ts +4 -4
  43. package/dist/types/core/appearance/AppearanceAxis.d.ts +1 -1
  44. package/dist/types/core/appearance/HeaderRegistry.d.ts +236 -0
  45. package/dist/types/core/appearance/ThemeMetaRegistry.d.ts +1 -1
  46. package/dist/types/core/appearance/TypographyRegistry.d.ts +122 -0
  47. package/dist/types/core/appearance/index.d.ts +1 -0
  48. package/dist/types/core/detail/DetailState.d.ts +1 -1
  49. package/dist/types/core/detail/SubgridCache.d.ts +2 -2
  50. package/dist/types/header/index.d.ts +144 -0
  51. package/dist/types/typography/index.d.ts +128 -0
  52. package/dist/xlsx.min-BQ1o3sB6.cjs.map +1 -0
  53. package/dist/xlsx.min-Bbz2ZypC.js.map +1 -0
  54. package/package.json +126 -114
@@ -0,0 +1,97 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const DEFAULT_AXIS_VALUE = "default", EMPTY_RESOLUTION = Object.freeze({ tokens: Object.freeze({}) });
4
+ function assertNamespace(o, e, t) {
5
+ for (const n of Object.keys(t)) if (!e.has(n)) throw new Error(`[AppearanceAxis:${o}] 토큰 "${n}" 은 ${o} 축 이름공간이 아닙니다. 각 축은 자기 이름공간 토큰만 소유합니다(축 오염 금지 — 이름-분리 물리 직교, 불변식 1).`);
6
+ }
7
+ class TokenAxis {
8
+ constructor(e) {
9
+ this._values = /* @__PURE__ */ new Map(), this.id = e.id, this.namespace = e.namespace, this._attrName = e.attrName, this._requiresRelayout = e.requiresRelayout ?? false;
10
+ }
11
+ registerBuiltin(e, t) {
12
+ assertNamespace(this.id, this.namespace, t), this._values.set(e, this._guardrails(e, t).delta);
13
+ }
14
+ _guardrails(e, t) {
15
+ return { delta: t, warnings: [] };
16
+ }
17
+ define(e, t) {
18
+ assertNamespace(this.id, this.namespace, t);
19
+ const n = this._guardrails(e, t);
20
+ this._values.set(e, n.delta);
21
+ for (const a of n.warnings) typeof console < "u" && console.warn(`[AppearanceAxis:${this.id}] "${e}": ${a}`);
22
+ return n;
23
+ }
24
+ has(e) {
25
+ return this._values.has(e);
26
+ }
27
+ resolve(e) {
28
+ if (e === DEFAULT_AXIS_VALUE) return EMPTY_RESOLUTION;
29
+ const t = this._values.get(e);
30
+ if (t === void 0) return EMPTY_RESOLUTION;
31
+ const n = { tokens: t, attr: { name: this._attrName, value: e } };
32
+ return this._requiresRelayout && (n.requiresRelayout = true), n;
33
+ }
34
+ list() {
35
+ return [...this._values.keys()];
36
+ }
37
+ }
38
+ const TYPOGRAPHY_TOKENS = /* @__PURE__ */ new Set(["--og-font-family", "--og-font-weight", "--og-letter-spacing", "--og-header-font-family", "--og-header-font-weight", "--og-header-letter-spacing", "--og-font-variant-numeric", "--og-num-font-family", "--og-prose-line-height"]), TYPOGRAPHY_ATTR = "data-og-typography", FAMILY_TOKENS = ["--og-font-family", "--og-header-font-family", "--og-num-font-family"], TRACKING_TOKENS = ["--og-letter-spacing", "--og-header-letter-spacing"], WEBFONT_RE = /url\s*\(|@font-face/i, CJK_FONT_RE = /(hangul|gothic|myeongjo|batang|dotum|gulim|malgun|pretendard|nanum|d2coding|noto\s*sans\s*(kr|jp|sc|tc|cjk)|source\s*han|apple\s*sd|hiragino|yu\s*gothic|meiryo|ms\s*(p?)(gothic|mincho)|yahei|pingfang|jhenghei|simsun|songti|cjk)|[가-힣぀-ヿ一-鿿]/i;
39
+ function guessOwnerAxis(o) {
40
+ return o === "--og-font-size" || o === "--og-line-height" || o.startsWith("--og-density-") ? "밀도(data-og-density) — 행높이·글자크기는 밀도가 소유합니다(§9.1 밀도-타이포 동조 계약)" : o.startsWith("--og-texture-") ? "질감(data-og-texture)" : /^--og-(radius|border|elevation|focus|cell-padding|divider|scrollbar|icon|transition|container-radius|row-accent)/.test(o) ? "형태(data-og-skin)" : "색(data-og-theme) 또는 미등록 토큰";
41
+ }
42
+ function assertTypographyOnly(o, e) {
43
+ for (const t of Object.keys(e)) if (!TYPOGRAPHY_TOKENS.has(t)) throw new Error(`[TypographyRegistry] 타이포 "${o}" 의 토큰 "${t}" 은 타이포 축 이름공간이 아닙니다. 이 토큰은 ${guessOwnerAxis(t)} 소유입니다. 타이포(서체) 델타는 서체·웨이트·자간·숫자 변형만 담을 수 있습니다(축 오염 금지, 불변식 1).`);
44
+ }
45
+ class TypographyRegistry extends TokenAxis {
46
+ constructor() {
47
+ super({ id: "typography", attrName: TYPOGRAPHY_ATTR, namespace: TYPOGRAPHY_TOKENS });
48
+ }
49
+ registerBuiltin(e, t) {
50
+ assertTypographyOnly(e, t), super.registerBuiltin(e, t);
51
+ }
52
+ define(e, t) {
53
+ return assertTypographyOnly(e, t), super.define(e, t);
54
+ }
55
+ _guardrails(e, t) {
56
+ const n = { ...t }, a = [];
57
+ for (const r of FAMILY_TOKENS) {
58
+ const i = n[r];
59
+ if (i != null && WEBFONT_RE.test(String(i))) throw new Error(`[TypographyRegistry] 타이포 "${e}" 토큰 "${r}" 에 웹폰트 선언(url()/@font-face)이 있습니다. 타이포 축은 시스템에 이미 있는 서체를 고르는 일만 소유하며 폰트를 내려받지 않습니다(제로 의존성·무다운로드 보증). 서체 이름만 스택으로 나열하세요.`);
60
+ }
61
+ const s = FAMILY_TOKENS.map((r) => n[r] ?? "").join(",");
62
+ if (CJK_FONT_RE.test(s)) for (const r of TRACKING_TOKENS) {
63
+ const i = n[r];
64
+ if (i == null) continue;
65
+ const c = parseFloat(String(i));
66
+ !Number.isNaN(c) && c < 0 && (n[r] = "normal", a.push(`${r} ${i} → normal (음수 자간은 한글 음절을 뭉갠다 — 서체 스택에 CJK 폴백이 있습니다, SPEC §2.4)`));
67
+ }
68
+ return { delta: n, warnings: a };
69
+ }
70
+ }
71
+ const TYPOGRAPHY_UI = { "--og-font-family": 'Inter, "Inter Variable", "Inter var", -apple-system, BlinkMacSystemFont, "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, Pretendard, "Pretendard Variable", "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", "Nanum Gothic", "Hiragino Sans", "Yu Gothic UI", Meiryo, "Microsoft YaHei", "PingFang SC", sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0.014em", "--og-font-variant-numeric": "tabular-nums" }, TYPOGRAPHY_LEDGER = { "--og-font-family": '"IBM Plex Sans", "Source Sans 3", "Source Sans Pro", Inter, "Segoe UI Variable Text", "Segoe UI", system-ui, Pretendard, "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", sans-serif', "--og-num-font-family": '"IBM Plex Mono", "SF Mono", "Cascadia Mono", "Roboto Mono", Consolas, "DejaVu Sans Mono", "Liberation Mono", monospace', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "700", "--og-header-letter-spacing": "0.02em", "--og-font-variant-numeric": "tabular-nums slashed-zero" }, TYPOGRAPHY_TERMINAL = { "--og-font-family": '"JetBrains Mono", "Cascadia Code", "Cascadia Mono", "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", "DejaVu Sans Mono", D2Coding, "D2Coding ligature", "Nanum Gothic Coding", "Noto Sans Mono CJK KR", "Noto Sans Mono CJK JP", monospace', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0.01em", "--og-font-variant-numeric": "tabular-nums slashed-zero" }, TYPOGRAPHY_DENSE_SCAN = { "--og-font-family": 'Inter, "Inter Variable", "Segoe UI Variable Small", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, Roboto, Pretendard, "Pretendard Variable", "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", sans-serif', "--og-font-weight": "430", "--og-letter-spacing": "0.01em", "--og-header-font-weight": "640", "--og-header-letter-spacing": "0.028em", "--og-font-variant-numeric": "tabular-nums" }, TYPOGRAPHY_HUMANIST = { "--og-font-family": 'Verdana, Tahoma, "DejaVu Sans", "Bitstream Vera Sans", "Lucida Grande", "Segoe UI", system-ui, "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", "Nanum Gothic", sans-serif', "--og-header-font-family": '"Segoe UI", system-ui, -apple-system, "Malgun Gothic", "Apple SD Gothic Neo", sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0.02em", "--og-font-variant-numeric": "tabular-nums", "--og-prose-line-height": "1.55" }, TYPOGRAPHY_HANGUL_FIRST = { "--og-font-family": 'Pretendard, "Pretendard Variable", "Pretendard JP", "Apple SD Gothic Neo", "Noto Sans KR", "Source Han Sans KR", "Malgun Gothic", "맑은 고딕", "Nanum Gothic", Dotum, 돋움, system-ui, sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0", "--og-font-variant-numeric": "tabular-nums" }, TYPOGRAPHY_CJK_DOC = { "--og-font-family": '"Noto Sans CJK KR", "Noto Sans KR", "Source Han Sans KR", Pretendard, "Apple SD Gothic Neo", "Malgun Gothic", "Hiragino Sans", "Yu Gothic UI", Meiryo, "Microsoft YaHei", "PingFang SC", "Microsoft JhengHei", "PingFang TC", system-ui, sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0", "--og-font-variant-numeric": "tabular-nums" }, BUILTIN_TYPOGRAPHIES = [["ui", TYPOGRAPHY_UI], ["ledger", TYPOGRAPHY_LEDGER], ["terminal", TYPOGRAPHY_TERMINAL], ["dense-scan", TYPOGRAPHY_DENSE_SCAN], ["humanist", TYPOGRAPHY_HUMANIST], ["hangul-first", TYPOGRAPHY_HANGUL_FIRST], ["cjk-doc", TYPOGRAPHY_CJK_DOC]], typographyRegistry = new TypographyRegistry();
72
+ for (const [o, e] of BUILTIN_TYPOGRAPHIES) typographyRegistry.registerBuiltin(o, e);
73
+ const TYPOGRAPHY_PRESETS = Object.freeze(Object.fromEntries(BUILTIN_TYPOGRAPHIES.map(([o, e]) => [o, e])));
74
+ function isElementTarget(o) {
75
+ const e = o;
76
+ return !!e && typeof e == "object" && typeof e.setAttribute == "function" && typeof e.removeAttribute == "function" && e.style != null;
77
+ }
78
+ function applyTypography(o, e) {
79
+ const t = typographyRegistry.resolve(e), n = [];
80
+ if (e !== "default" && !typographyRegistry.has(e) && n.push(`타이포 프리셋 "${e}" 는 등록되어 있지 않습니다 — default(축 해제)로 처리했습니다. 등록된 id: ${typographyRegistry.list().join(", ")} (사용자 정의는 defineTypography()).`), isElementTarget(o)) {
81
+ for (const s of TYPOGRAPHY_TOKENS) o.style.removeProperty(s);
82
+ return t.attr ? o.setAttribute(t.attr.name, t.attr.value) : o.removeAttribute(TYPOGRAPHY_ATTR), { mode: "element", warnings: n };
83
+ }
84
+ const a = o;
85
+ if (!a || typeof a.setThemeVar != "function") throw new Error("[typography] applyTypography(target, id): target 은 그리드 컨테이너 요소(HTMLElement) 또는 setThemeVar() 를 가진 그리드 인스턴스여야 합니다.");
86
+ for (const s of TYPOGRAPHY_TOKENS) a.setThemeVar(s, "");
87
+ for (const [s, g] of Object.entries(t.tokens)) a.setThemeVar(s, g);
88
+ return t.attr && n.push(`그리드 인스턴스 경로는 CSS 변수만 주입합니다 — ${TYPOGRAPHY_ATTR} 속성은 붙지 않습니다. OpenGrid 가 컨테이너 요소를 돌려주는 공개 접근자를 제공하지 않기 때문입니다. 그래서 밀도 복합 셀렉터(광학 크기)와 cjk-doc 의 :lang() 한자 분기는 적용되지 않습니다. 완전 적용하려면 컨테이너 요소(.og-container)를 직접 넘기세요.`), { mode: "grid-vars", warnings: n };
89
+ }
90
+ function defineTypography(o, e) {
91
+ return typographyRegistry.define(o, e);
92
+ }
93
+ function listTypography() {
94
+ return typographyRegistry.list();
95
+ }
96
+ exports.TYPOGRAPHY_ATTR = TYPOGRAPHY_ATTR, exports.TYPOGRAPHY_PRESETS = TYPOGRAPHY_PRESETS, exports.TYPOGRAPHY_TOKENS = TYPOGRAPHY_TOKENS, exports.TypographyRegistry = TypographyRegistry, exports.applyTypography = applyTypography, exports.assertTypographyOnly = assertTypographyOnly, exports.defineTypography = defineTypography, exports.listTypography = listTypography, exports.typographyRegistry = typographyRegistry;
97
+ //# sourceMappingURL=open-grid-typography.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"open-grid-typography.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,181 @@
1
+ /* ============================================================
2
+ OPEN_GRID — 타이포그래피(TYPE 축) 정의 [제5축]
3
+ 사용법: <div data-og-typography="ui"> 또는 플러그인 applyTypography(grid, 'ui')
4
+ ------------------------------------------------------------
5
+ 색⊥형태⊥밀도⊥타이포 직교성: 이 파일은 **서체(TYPE) 토큰만** 담는다 — 색(hex/rgb/hsl) 0.
6
+ themes.css 는 COLOR 전용, skins.css 는 FORM 전용, 이 파일은 TYPE 전용이다.
7
+ 네 축은 disjoint name set 이라 어떤 조합도 서로를 흔들지 않는다.
8
+
9
+ 소유 토큰(9): --og-font-family / --og-font-weight / --og-letter-spacing /
10
+ --og-header-font-family / --og-header-font-weight / --og-header-letter-spacing /
11
+ --og-font-variant-numeric / --og-num-font-family / --og-prose-line-height
12
+ ⚠ --og-font-size 와 --og-line-height 는 **밀도 축 소유**다. 이 파일은 절대 쓰지 않는다
13
+ ("밀도-타이포 동조" 계약 — 글자 크기와 행 높이는 한 축이 함께 쥐어야 어긋나지 않는다).
14
+ 광학 크기 보정이 필요할 때는 밀도 축을 **읽기만** 한다(복합 셀렉터, dense-scan 참고).
15
+
16
+ ⛔ 웹폰트를 내려받지 않는다. @font-face 선언 0, CDN 0, url() 0.
17
+ 시스템에 이미 있는 서체만 기회적으로 잡아 쓰고, 없으면 우아하게 내려앉는다.
18
+ 제로 의존성 라이브러리의 약속을 타이포 축이 깨지 않는다 — 이 파일을 로드해도
19
+ 네트워크 요청은 한 건도 늘지 않는다.
20
+
21
+ ⚠ DEFAULT(축 미지정 / data-og-typography="default")는 **오늘과 byte-identical**:
22
+ 이 파일은 named 프리셋에만 토큰을 선언하고 default 는 선언하지 않는다 →
23
+ 토큰 미정의 → base.css 의 var() 폴백(오늘 값과 동일)이 그대로 적용된다.
24
+
25
+ ⚠ 이 파일만으로는 아무 일도 일어나지 않는다. 실제 소비는 base.css 가 한다
26
+ (.og-container 의 font-weight/letter-spacing/font-variant-numeric,
27
+ .og-header-cell 의 font-family, .og-cell-number 의 font-family).
28
+ base.css 가 host isolation 때문에 그 속성들을 하드코딩하고 있었으므로,
29
+ "기본값이 오늘 값과 같은 var()" 로 바꿔 격리는 지키고 축은 살렸다.
30
+
31
+ 셀렉터 주의: OpenGrid 는 data-og-typography 를 .og-container 자기 자신에 붙인다.
32
+ 따라서 커스텀 프로퍼티는 **속성 셀렉터 [data-og-typography="X"]**(컴파운드 아님)로
33
+ 선언해 컨테이너 자신과 분리 UI(컨텍스트 메뉴 등) 모두에 토큰이 걸리게 한다.
34
+ ============================================================ */
35
+
36
+ /* ── ① default — 시스템 기본. 빈 델타. ──
37
+ 플러그인을 로드했지만 고르지 않은 상태. 속성 자체를 붙이지 않는 것이 계약이므로
38
+ 여기에 선언을 두지 않는다. 기존 base.css 스택이 그대로 유효 = 하위호환 보증. */
39
+
40
+ /* ── ② ui — UI 그로테스크 (권장 기본) ── */
41
+ [data-og-typography="ui"] {
42
+ --og-font-family:
43
+ Inter, "Inter Variable", "Inter var",
44
+ -apple-system, BlinkMacSystemFont,
45
+ "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", Arial,
46
+ Pretendard, "Pretendard Variable",
47
+ "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕",
48
+ "Noto Sans KR", "Nanum Gothic",
49
+ "Hiragino Sans", "Yu Gothic UI", Meiryo,
50
+ "Microsoft YaHei", "PingFang SC",
51
+ sans-serif;
52
+ --og-font-weight: 400;
53
+ --og-letter-spacing: normal;
54
+ --og-header-font-weight: 600;
55
+ --og-header-letter-spacing: 0.014em; /* 0.025em → 한글 헤더가 벌어지던 결함 교정 */
56
+ --og-font-variant-numeric: tabular-nums;
57
+ }
58
+
59
+ /* ── ③ ledger — 회계 원장 ── */
60
+ [data-og-typography="ledger"] {
61
+ --og-font-family:
62
+ "IBM Plex Sans", "Source Sans 3", "Source Sans Pro",
63
+ Inter, "Segoe UI Variable Text", "Segoe UI", system-ui,
64
+ Pretendard, "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕",
65
+ "Noto Sans KR", sans-serif;
66
+ --og-num-font-family:
67
+ "IBM Plex Mono", "SF Mono", "Cascadia Mono", "Roboto Mono",
68
+ Consolas, "DejaVu Sans Mono", "Liberation Mono", monospace;
69
+ --og-font-weight: 400;
70
+ --og-letter-spacing: normal;
71
+ --og-header-font-weight: 700;
72
+ --og-header-letter-spacing: 0.02em;
73
+ --og-font-variant-numeric: tabular-nums slashed-zero; /* 0↔O, 0↔8 오독 차단 */
74
+ }
75
+
76
+ /* ── ④ terminal — 터미널 / 코드 ── */
77
+ [data-og-typography="terminal"] {
78
+ --og-font-family:
79
+ "JetBrains Mono", "Cascadia Code", "Cascadia Mono", "SF Mono",
80
+ Menlo, Monaco, Consolas, "Liberation Mono", "DejaVu Sans Mono",
81
+ D2Coding, "D2Coding ligature", "Nanum Gothic Coding",
82
+ "Noto Sans Mono CJK KR", "Noto Sans Mono CJK JP",
83
+ monospace;
84
+ --og-font-weight: 400;
85
+ --og-letter-spacing: normal; /* 음수 금지 — D2Coding 한글 음절이 겹친다 */
86
+ --og-header-font-weight: 600;
87
+ --og-header-letter-spacing: 0.01em;
88
+ --og-font-variant-numeric: tabular-nums slashed-zero;
89
+ }
90
+
91
+ /* ── ⑤ dense-scan — 고밀도 스캔 (compact 밀도의 짝) ── */
92
+ [data-og-typography="dense-scan"] {
93
+ --og-font-family:
94
+ Inter, "Inter Variable",
95
+ "Segoe UI Variable Small", "Segoe UI", system-ui,
96
+ -apple-system, BlinkMacSystemFont, Roboto,
97
+ Pretendard, "Pretendard Variable",
98
+ "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR",
99
+ sans-serif;
100
+ --og-font-weight: 430;
101
+ --og-letter-spacing: 0.01em;
102
+ --og-header-font-weight: 640;
103
+ --og-header-letter-spacing: 0.028em;
104
+ --og-font-variant-numeric: tabular-nums;
105
+ }
106
+ /* 광학 크기 — 밀도 축을 **읽기만** 한다(소유하지 않는다). 작을수록 벌리고 굵힌다. */
107
+ [data-og-typography="dense-scan"][data-og-density="compact"],
108
+ [data-og-typography="dense-scan"][data-og-density="compact-touch"] {
109
+ --og-font-weight: 460;
110
+ --og-letter-spacing: 0.014em;
111
+ --og-header-letter-spacing: 0.034em;
112
+ }
113
+ [data-og-typography="dense-scan"][data-og-density="spacious"],
114
+ [data-og-typography="dense-scan"][data-og-density="gallery"] {
115
+ --og-font-weight: 400;
116
+ --og-letter-spacing: 0.002em;
117
+ --og-header-letter-spacing: 0.018em;
118
+ }
119
+
120
+ /* ── ⑥ humanist — 휴머니스트 (장시간·저시력) ── */
121
+ [data-og-typography="humanist"] {
122
+ --og-font-family:
123
+ Verdana, Tahoma, "DejaVu Sans", "Bitstream Vera Sans",
124
+ "Lucida Grande", "Segoe UI", system-ui,
125
+ "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕",
126
+ "Noto Sans KR", "Nanum Gothic", sans-serif;
127
+ /* 8종 중 유일하게 헤더 서체를 따로 쓴다 — "헤더는 데이터가 아니다"를 서체로 선언 */
128
+ --og-header-font-family:
129
+ "Segoe UI", system-ui, -apple-system,
130
+ "Malgun Gothic", "Apple SD Gothic Neo", sans-serif;
131
+ --og-font-weight: 400;
132
+ --og-letter-spacing: normal;
133
+ --og-header-font-weight: 600;
134
+ --og-header-letter-spacing: 0.02em;
135
+ --og-font-variant-numeric: tabular-nums;
136
+ --og-prose-line-height: 1.55;
137
+ }
138
+
139
+ /* ── ⑦ hangul-first — 한글 우선 ── */
140
+ [data-og-typography="hangul-first"] {
141
+ --og-font-family:
142
+ Pretendard, "Pretendard Variable", "Pretendard JP",
143
+ "Apple SD Gothic Neo",
144
+ "Noto Sans KR", "Source Han Sans KR",
145
+ "Malgun Gothic", "맑은 고딕", "Nanum Gothic", Dotum, 돋움,
146
+ system-ui, sans-serif;
147
+ --og-font-weight: 400;
148
+ --og-letter-spacing: normal; /* 고정 — 음수 자간은 한글을 뭉갠다 */
149
+ --og-header-font-weight: 600;
150
+ --og-header-letter-spacing: 0; /* 국문 헤더에 트래킹을 주지 않는다 */
151
+ --og-font-variant-numeric: tabular-nums;
152
+ }
153
+
154
+ /* ── ⑧ cjk-doc — CJK 문서 (한·일·중) ── */
155
+ [data-og-typography="cjk-doc"] {
156
+ --og-font-family:
157
+ "Noto Sans CJK KR", "Noto Sans KR", "Source Han Sans KR",
158
+ Pretendard, "Apple SD Gothic Neo", "Malgun Gothic",
159
+ "Hiragino Sans", "Yu Gothic UI", Meiryo,
160
+ "Microsoft YaHei", "PingFang SC", "Microsoft JhengHei", "PingFang TC",
161
+ system-ui, sans-serif;
162
+ --og-font-weight: 400;
163
+ --og-letter-spacing: normal;
164
+ --og-header-font-weight: 600;
165
+ --og-header-letter-spacing: 0;
166
+ --og-font-variant-numeric: tabular-nums;
167
+ }
168
+ /* 한자 통합(Han unification) — 直·骨·類 는 ko/ja/zh 에서 자형이 다르다.
169
+ 언어 태그가 있을 때만 갈라 그린다. lang 이 없으면 한국어 자형으로 통일된다(예측 가능한 실패). */
170
+ [data-og-typography="cjk-doc"] .og-cell:lang(ja),
171
+ [data-og-typography="cjk-doc"] .og-header-cell:lang(ja) {
172
+ font-family: "Noto Sans CJK JP", "Hiragino Sans", "Yu Gothic UI", Meiryo, "Noto Sans JP", sans-serif;
173
+ }
174
+ [data-og-typography="cjk-doc"] .og-cell:lang(zh-Hans),
175
+ [data-og-typography="cjk-doc"] .og-header-cell:lang(zh-Hans) {
176
+ font-family: "Noto Sans CJK SC", "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
177
+ }
178
+ [data-og-typography="cjk-doc"] .og-cell:lang(zh-Hant),
179
+ [data-og-typography="cjk-doc"] .og-header-cell:lang(zh-Hant) {
180
+ font-family: "Noto Sans CJK TC", "PingFang TC", "Microsoft JhengHei", "Noto Sans TC", sans-serif;
181
+ }
@@ -0,0 +1,105 @@
1
+ const T = "default", m = Object.freeze({ tokens: Object.freeze({}) });
2
+ function p(o, e, t) {
3
+ for (const n of Object.keys(t)) if (!e.has(n)) throw new Error(`[AppearanceAxis:${o}] 토큰 "${n}" 은 ${o} 축 이름공간이 아닙니다. 각 축은 자기 이름공간 토큰만 소유합니다(축 오염 금지 — 이름-분리 물리 직교, 불변식 1).`);
4
+ }
5
+ class P {
6
+ constructor(e) {
7
+ this._values = /* @__PURE__ */ new Map(), this.id = e.id, this.namespace = e.namespace, this._attrName = e.attrName, this._requiresRelayout = e.requiresRelayout ?? false;
8
+ }
9
+ registerBuiltin(e, t) {
10
+ p(this.id, this.namespace, t), this._values.set(e, this._guardrails(e, t).delta);
11
+ }
12
+ _guardrails(e, t) {
13
+ return { delta: t, warnings: [] };
14
+ }
15
+ define(e, t) {
16
+ p(this.id, this.namespace, t);
17
+ const n = this._guardrails(e, t);
18
+ this._values.set(e, n.delta);
19
+ for (const a of n.warnings) typeof console < "u" && console.warn(`[AppearanceAxis:${this.id}] "${e}": ${a}`);
20
+ return n;
21
+ }
22
+ has(e) {
23
+ return this._values.has(e);
24
+ }
25
+ resolve(e) {
26
+ if (e === T) return m;
27
+ const t = this._values.get(e);
28
+ if (t === void 0) return m;
29
+ const n = { tokens: t, attr: { name: this._attrName, value: e } };
30
+ return this._requiresRelayout && (n.requiresRelayout = true), n;
31
+ }
32
+ list() {
33
+ return [...this._values.keys()];
34
+ }
35
+ }
36
+ const c = /* @__PURE__ */ new Set(["--og-font-family", "--og-font-weight", "--og-letter-spacing", "--og-header-font-family", "--og-header-font-weight", "--og-header-letter-spacing", "--og-font-variant-numeric", "--og-num-font-family", "--og-prose-line-height"]), l = "data-og-typography", d = ["--og-font-family", "--og-header-font-family", "--og-num-font-family"], N = ["--og-letter-spacing", "--og-header-letter-spacing"], R = /url\s*\(|@font-face/i, A = /(hangul|gothic|myeongjo|batang|dotum|gulim|malgun|pretendard|nanum|d2coding|noto\s*sans\s*(kr|jp|sc|tc|cjk)|source\s*han|apple\s*sd|hiragino|yu\s*gothic|meiryo|ms\s*(p?)(gothic|mincho)|yahei|pingfang|jhenghei|simsun|songti|cjk)|[가-힣぀-ヿ一-鿿]/i;
37
+ function w(o) {
38
+ return o === "--og-font-size" || o === "--og-line-height" || o.startsWith("--og-density-") ? "밀도(data-og-density) — 행높이·글자크기는 밀도가 소유합니다(§9.1 밀도-타이포 동조 계약)" : o.startsWith("--og-texture-") ? "질감(data-og-texture)" : /^--og-(radius|border|elevation|focus|cell-padding|divider|scrollbar|icon|transition|container-radius|row-accent)/.test(o) ? "형태(data-og-skin)" : "색(data-og-theme) 또는 미등록 토큰";
39
+ }
40
+ function u(o, e) {
41
+ for (const t of Object.keys(e)) if (!c.has(t)) throw new Error(`[TypographyRegistry] 타이포 "${o}" 의 토큰 "${t}" 은 타이포 축 이름공간이 아닙니다. 이 토큰은 ${w(t)} 소유입니다. 타이포(서체) 델타는 서체·웨이트·자간·숫자 변형만 담을 수 있습니다(축 오염 금지, 불변식 1).`);
42
+ }
43
+ class y extends P {
44
+ constructor() {
45
+ super({ id: "typography", attrName: l, namespace: c });
46
+ }
47
+ registerBuiltin(e, t) {
48
+ u(e, t), super.registerBuiltin(e, t);
49
+ }
50
+ define(e, t) {
51
+ return u(e, t), super.define(e, t);
52
+ }
53
+ _guardrails(e, t) {
54
+ const n = { ...t }, a = [];
55
+ for (const r of d) {
56
+ const g = n[r];
57
+ if (g != null && R.test(String(g))) throw new Error(`[TypographyRegistry] 타이포 "${e}" 토큰 "${r}" 에 웹폰트 선언(url()/@font-face)이 있습니다. 타이포 축은 시스템에 이미 있는 서체를 고르는 일만 소유하며 폰트를 내려받지 않습니다(제로 의존성·무다운로드 보증). 서체 이름만 스택으로 나열하세요.`);
58
+ }
59
+ const s = d.map((r) => n[r] ?? "").join(",");
60
+ if (A.test(s)) for (const r of N) {
61
+ const g = n[r];
62
+ if (g == null) continue;
63
+ const h = parseFloat(String(g));
64
+ !Number.isNaN(h) && h < 0 && (n[r] = "normal", a.push(`${r} ${g} → normal (음수 자간은 한글 음절을 뭉갠다 — 서체 스택에 CJK 폴백이 있습니다, SPEC §2.4)`));
65
+ }
66
+ return { delta: n, warnings: a };
67
+ }
68
+ }
69
+ const M = { "--og-font-family": 'Inter, "Inter Variable", "Inter var", -apple-system, BlinkMacSystemFont, "Segoe UI Variable Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, Pretendard, "Pretendard Variable", "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", "Nanum Gothic", "Hiragino Sans", "Yu Gothic UI", Meiryo, "Microsoft YaHei", "PingFang SC", sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0.014em", "--og-font-variant-numeric": "tabular-nums" }, _ = { "--og-font-family": '"IBM Plex Sans", "Source Sans 3", "Source Sans Pro", Inter, "Segoe UI Variable Text", "Segoe UI", system-ui, Pretendard, "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", sans-serif', "--og-num-font-family": '"IBM Plex Mono", "SF Mono", "Cascadia Mono", "Roboto Mono", Consolas, "DejaVu Sans Mono", "Liberation Mono", monospace', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "700", "--og-header-letter-spacing": "0.02em", "--og-font-variant-numeric": "tabular-nums slashed-zero" }, b = { "--og-font-family": '"JetBrains Mono", "Cascadia Code", "Cascadia Mono", "SF Mono", Menlo, Monaco, Consolas, "Liberation Mono", "DejaVu Sans Mono", D2Coding, "D2Coding ligature", "Nanum Gothic Coding", "Noto Sans Mono CJK KR", "Noto Sans Mono CJK JP", monospace', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0.01em", "--og-font-variant-numeric": "tabular-nums slashed-zero" }, G = { "--og-font-family": 'Inter, "Inter Variable", "Segoe UI Variable Small", "Segoe UI", system-ui, -apple-system, BlinkMacSystemFont, Roboto, Pretendard, "Pretendard Variable", "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", sans-serif', "--og-font-weight": "430", "--og-letter-spacing": "0.01em", "--og-header-font-weight": "640", "--og-header-letter-spacing": "0.028em", "--og-font-variant-numeric": "tabular-nums" }, O = { "--og-font-family": 'Verdana, Tahoma, "DejaVu Sans", "Bitstream Vera Sans", "Lucida Grande", "Segoe UI", system-ui, "Apple SD Gothic Neo", "Malgun Gothic", "맑은 고딕", "Noto Sans KR", "Nanum Gothic", sans-serif', "--og-header-font-family": '"Segoe UI", system-ui, -apple-system, "Malgun Gothic", "Apple SD Gothic Neo", sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0.02em", "--og-font-variant-numeric": "tabular-nums", "--og-prose-line-height": "1.55" }, Y = { "--og-font-family": 'Pretendard, "Pretendard Variable", "Pretendard JP", "Apple SD Gothic Neo", "Noto Sans KR", "Source Han Sans KR", "Malgun Gothic", "맑은 고딕", "Nanum Gothic", Dotum, 돋움, system-ui, sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0", "--og-font-variant-numeric": "tabular-nums" }, v = { "--og-font-family": '"Noto Sans CJK KR", "Noto Sans KR", "Source Han Sans KR", Pretendard, "Apple SD Gothic Neo", "Malgun Gothic", "Hiragino Sans", "Yu Gothic UI", Meiryo, "Microsoft YaHei", "PingFang SC", "Microsoft JhengHei", "PingFang TC", system-ui, sans-serif', "--og-font-weight": "400", "--og-letter-spacing": "normal", "--og-header-font-weight": "600", "--og-header-letter-spacing": "0", "--og-font-variant-numeric": "tabular-nums" }, S = [["ui", M], ["ledger", _], ["terminal", b], ["dense-scan", G], ["humanist", O], ["hangul-first", Y], ["cjk-doc", v]], i = new y();
70
+ for (const [o, e] of S) i.registerBuiltin(o, e);
71
+ const E = Object.freeze(Object.fromEntries(S.map(([o, e]) => [o, e])));
72
+ function I(o) {
73
+ const e = o;
74
+ return !!e && typeof e == "object" && typeof e.setAttribute == "function" && typeof e.removeAttribute == "function" && e.style != null;
75
+ }
76
+ function C(o, e) {
77
+ const t = i.resolve(e), n = [];
78
+ if (e !== "default" && !i.has(e) && n.push(`타이포 프리셋 "${e}" 는 등록되어 있지 않습니다 — default(축 해제)로 처리했습니다. 등록된 id: ${i.list().join(", ")} (사용자 정의는 defineTypography()).`), I(o)) {
79
+ for (const s of c) o.style.removeProperty(s);
80
+ return t.attr ? o.setAttribute(t.attr.name, t.attr.value) : o.removeAttribute(l), { mode: "element", warnings: n };
81
+ }
82
+ const a = o;
83
+ if (!a || typeof a.setThemeVar != "function") throw new Error("[typography] applyTypography(target, id): target 은 그리드 컨테이너 요소(HTMLElement) 또는 setThemeVar() 를 가진 그리드 인스턴스여야 합니다.");
84
+ for (const s of c) a.setThemeVar(s, "");
85
+ for (const [s, f] of Object.entries(t.tokens)) a.setThemeVar(s, f);
86
+ return t.attr && n.push(`그리드 인스턴스 경로는 CSS 변수만 주입합니다 — ${l} 속성은 붙지 않습니다. OpenGrid 가 컨테이너 요소를 돌려주는 공개 접근자를 제공하지 않기 때문입니다. 그래서 밀도 복합 셀렉터(광학 크기)와 cjk-doc 의 :lang() 한자 분기는 적용되지 않습니다. 완전 적용하려면 컨테이너 요소(.og-container)를 직접 넘기세요.`), { mode: "grid-vars", warnings: n };
87
+ }
88
+ function H(o, e) {
89
+ return i.define(o, e);
90
+ }
91
+ function K() {
92
+ return i.list();
93
+ }
94
+ export {
95
+ l as TYPOGRAPHY_ATTR,
96
+ E as TYPOGRAPHY_PRESETS,
97
+ c as TYPOGRAPHY_TOKENS,
98
+ y as TypographyRegistry,
99
+ C as applyTypography,
100
+ u as assertTypographyOnly,
101
+ H as defineTypography,
102
+ K as listTypography,
103
+ i as typographyRegistry
104
+ };
105
+ //# sourceMappingURL=open-grid-typography.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"open-grid-typography.js","sources":["../src/core/appearance/AppearanceAxis.ts"],"sourcesContent":["// ============================================================\n// DD-11 §2.1 IAppearanceAxis — 동형 외관 축 SPI(5축 공통 계약) + 델타축 기반구현\n// / DD-11 §2.1 IAppearanceAxis — the isomorphic appearance-axis SPI + a token-delta base impl.\n// ------------------------------------------------------------\n// 설계 근거(Why, §2.1·불변식 1~3):\n// 외관을 \"특수 케이스 5개\" 가 아니라 **하나의 인터페이스를 만족하는 5개 등록소**(theme·skin·\n// density·texture·icon)로 통일한다. 각 축은 **자기 이름공간 토큰만** 낸다(축 오염 금지 = 물리\n// 직교). default id 는 **빈 델타**(byte-identical) 이며, 신설 축(density·texture)은 default 시\n// `attr` 를 생략한다 — default 에 `data-og-density=\"default\"` 같은 새 속성이 붙으면 그 자체로\n// DOM diff 라 골든이 깨진다(REQ-TX-827, §R.1).\n//\n// `define/has/resolve/list` 는 DD-10 `IRegistry<V,K>`(REQ-T4-801)의 얇은 어댑터다(재구현 아님):\n// define≈register(축 오염·정직성 검증을 등록 게이트로), has≈has, resolve≈get(미등록→빈 델타 =\n// never-throw 폴백, IconRegistry 와 동일 계약), list≈keys. 축 고유의 이름공간 검증·relayout\n// 플래그만 얹은 특화 뷰다. 헤드리스·순수(DOM 미참조).\n// ============================================================\n\n/** 외관 축 식별자. 이름공간(prefix)이 물리 직교의 열쇠. / Appearance axis id; the token prefix is the key to physical orthogonality. */\nexport type AxisId = 'theme' | 'skin' | 'density' | 'texture' | 'icon' | 'typography' | 'header';\n\n/** 한 축의 CSS 변수 델타(자기 이름공간만). / A CSS-var delta for one axis (own namespace only). */\nexport type TokenDelta = Readonly<Record<string, string>>;\n\n/** 컨테이너에 붙일 data-* 속성. / A data-* attribute to place on the container. */\nexport interface AxisAttr {\n readonly name: string;\n readonly value: string;\n}\n\n/**\n * 한 축의 선택 결과 = 토큰 델타 + 컨테이너 속성 + relayout 플래그.\n * / One axis's selection = token delta + container attribute + relayout flag.\n */\nexport interface AxisResolution {\n /** 이 축이 발행하는 CSS 변수 델타(자기 이름공간만). default → 빈 객체. / CSS var delta (own namespace only); empty for default. */\n readonly tokens: TokenDelta;\n /** 컨테이너 data-* 속성. default/신설 축이면 생략(byte-identical). / Container data-* attr; omitted for default/new-axis. */\n readonly attr?: AxisAttr;\n /** 이 선택이 재계산을 요구하는가(밀도 = 행높이 relayout). / Does this selection require recompute (density → row-height relayout)? */\n readonly requiresRelayout?: boolean;\n}\n\n/** 축 정의 결과 — 등록된(가드레일 반영) 델타 + 경고. / Axis-definition result — registered (clamped) delta + warnings. */\nexport interface AxisDefineResult {\n readonly delta: TokenDelta;\n readonly warnings: string[];\n}\n\n/**\n * IAppearanceAxis — 한 외관 축의 등록·검증·해소를 소유하는 동형 SPI(§2.1).\n * 불변식: resolve(id)는 **자기 이름공간 토큰만** 낸다(축 오염 금지). default id 는 빈 델타(byte-identical).\n * / IAppearanceAxis — the isomorphic SPI owning one axis's registration/validation/resolution.\n */\nexport interface IAppearanceAxis {\n readonly id: AxisId;\n /** 이 축이 소유하는 토큰 이름공간(검증용). / Token namespace this axis owns (for validation). */\n readonly namespace: ReadonlySet<string>;\n /** 값 등록(사용자 확장). 축 오염·정직성 위반 시 throw 또는 클램프+경고. / Register a value; throws on axis-pollution, clamps+warns on honesty violations. */\n define(id: string, delta: TokenDelta): AxisDefineResult;\n /** 등록 여부. / Whether registered. */\n has(id: string): boolean;\n /** 축값 → 해소(토큰·속성·relayout 플래그). 미등록/default → 빈 델타. / Value id → resolution; unknown/default → empty delta. */\n resolve(valueId: string): AxisResolution;\n /** 등록된 값 id 목록(카탈로그·인스펙터용). / Registered value ids (for catalog/inspector). */\n list(): string[];\n}\n\n/** 축값이 default 인가(빈-델타·attr 생략 경로). / Is a value id the default (empty-delta / attr-omitted path)? */\nexport const DEFAULT_AXIS_VALUE = 'default';\n\n/** 빈 해소(default/미등록) — attr·relayout 없음. / Empty resolution (default/unknown) — no attr, no relayout. */\nexport const EMPTY_RESOLUTION: AxisResolution = Object.freeze({ tokens: Object.freeze({}) });\n\n/** TokenAxis 구성. / TokenAxis configuration. */\nexport interface TokenAxisConfig {\n readonly id: AxisId;\n /** 컨테이너 data-* 속성명(예: 'data-og-density'). / Container data-* attribute name. */\n readonly attrName: string;\n /** 이 축이 소유하는 토큰 이름공간(자기 prefix 집합). / The token namespace (own prefix set). */\n readonly namespace: ReadonlySet<string>;\n /** named 값이 relayout 을 요구하는가(density=true). 기본 false. / Do named values require relayout (density=true)? Default false. */\n readonly requiresRelayout?: boolean;\n}\n\n/**\n * 이름공간 검증 — 델타의 모든 토큰이 이 축 소유인지(축 오염 거부). throw on violation.\n * / Namespace validation — every token must be owned by this axis (rejects axis-pollution).\n *\n * @param axisId - 축 id / Axis id\n * @param namespace - 소유 토큰 집합 / Owned token set\n * @param delta - 검사할 델타 / Delta to validate\n * @throws 이름공간 밖 토큰이 있으면 Error / Throws if a token is outside the namespace\n */\nexport function assertNamespace(axisId: AxisId, namespace: ReadonlySet<string>, delta: TokenDelta): void {\n for (const key of Object.keys(delta)) {\n if (!namespace.has(key)) {\n throw new Error(\n `[AppearanceAxis:${axisId}] 토큰 \"${key}\" 은 ${axisId} 축 이름공간이 아닙니다. ` +\n `각 축은 자기 이름공간 토큰만 소유합니다(축 오염 금지 — 이름-분리 물리 직교, 불변식 1).`,\n );\n }\n }\n}\n\n/**\n * TokenAxis — 델타-등록형 축(density·texture)의 재사용 기반 구현.\n * define 은 이름공간 검증 + (서브클래스) 가드레일 후 등록. resolve 는 default/미등록 → 빈 델타(+attr 생략),\n * named → 델타 + `{name:attrName, value:id}` (+ requiresRelayout).\n * / TokenAxis — reusable base for delta-registered axes (density·texture). Headless, pure.\n *\n * @example\n * const ax = new TokenAxis({ id: 'density', attrName: 'data-og-density', namespace: DENSITY_TOKENS, requiresRelayout: true });\n * ax.resolve('default'); // { tokens:{} } — byte-identical\n */\nexport class TokenAxis implements IAppearanceAxis {\n readonly id: AxisId;\n readonly namespace: ReadonlySet<string>;\n protected readonly _attrName: string;\n protected readonly _requiresRelayout: boolean;\n protected readonly _values = new Map<string, TokenDelta>();\n\n constructor(cfg: TokenAxisConfig) {\n this.id = cfg.id;\n this.namespace = cfg.namespace;\n this._attrName = cfg.attrName;\n this._requiresRelayout = cfg.requiresRelayout ?? false;\n }\n\n /** 내장 값 등록(가드레일만, 경고는 삼킴 — CSS 는 정적 번들 소유). / Register a built-in value (guardrails only). */\n registerBuiltin(id: string, delta: TokenDelta): void {\n assertNamespace(this.id, this.namespace, delta);\n this._values.set(id, this._guardrails(id, delta).delta);\n }\n\n /** 서브클래스 가드레일 훅(기본 no-op). / Subclass guardrail hook (default no-op). */\n protected _guardrails(_id: string, delta: TokenDelta): AxisDefineResult {\n return { delta, warnings: [] };\n }\n\n define(id: string, delta: TokenDelta): AxisDefineResult {\n assertNamespace(this.id, this.namespace, delta);\n const result = this._guardrails(id, delta);\n this._values.set(id, result.delta);\n for (const w of result.warnings) {\n if (typeof console !== 'undefined') console.warn(`[AppearanceAxis:${this.id}] \"${id}\": ${w}`);\n }\n return result;\n }\n\n has(id: string): boolean {\n return this._values.has(id);\n }\n\n resolve(valueId: string): AxisResolution {\n if (valueId === DEFAULT_AXIS_VALUE) return EMPTY_RESOLUTION;\n const delta = this._values.get(valueId);\n if (delta === undefined) return EMPTY_RESOLUTION; // never-throw 폴백(미등록 = default 취급)\n const res: { tokens: TokenDelta; attr: AxisAttr; requiresRelayout?: boolean } = {\n tokens: delta,\n attr: { name: this._attrName, value: valueId },\n };\n if (this._requiresRelayout) res.requiresRelayout = true;\n return res;\n }\n\n list(): string[] {\n return [...this._values.keys()];\n }\n}\n"],"names":[],"mappings":"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"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const vue = require("vue"), OpenGrid$1 = require("./OpenGrid-BOtTt5aI.cjs"), _sfc_main = vue.defineComponent({ __name: "OpenGrid", props: { data: { default: () => [] }, columns: {}, height: { default: 400 }, width: { default: "100%" }, editable: { type: Boolean, default: false }, sortable: { type: Boolean, default: true }, filterable: { type: Boolean, default: true }, rowNumber: { type: Boolean, default: false }, checkColumn: { type: Boolean, default: false }, stateColumn: { type: Boolean, default: false }, draggable: { type: Boolean, default: false }, frozenColumns: { default: 0 }, theme: { default: "default" }, options: {} }, emits: ["update:data", "ready", "cell-click", "row-click", "edit-end", "sort-change", "filter-change", "row-check"], setup(n, { expose: u, emit: r }) {
3
+ const vue = require("vue"), OpenGrid$1 = require("./OpenGrid-CT9bV6On.cjs"), _sfc_main = vue.defineComponent({ __name: "OpenGrid", props: { data: { default: () => [] }, columns: {}, height: { default: 400 }, width: { default: "100%" }, editable: { type: Boolean, default: false }, sortable: { type: Boolean, default: true }, filterable: { type: Boolean, default: true }, rowNumber: { type: Boolean, default: false }, checkColumn: { type: Boolean, default: false }, stateColumn: { type: Boolean, default: false }, draggable: { type: Boolean, default: false }, frozenColumns: { default: 0 }, theme: { default: "default" }, options: {} }, emits: ["update:data", "ready", "cell-click", "row-click", "edit-end", "sort-change", "filter-change", "row-check"], setup(n, { expose: u, emit: r }) {
4
4
  const e = n, o = r, c = vue.ref(), a = vue.shallowRef(null);
5
5
  let i = null;
6
6
  const s = vue.computed(() => ({ height: typeof e.height == "number" ? `${e.height}px` : e.height, width: typeof e.width == "number" ? `${e.width}px` : e.width }));
@@ -0,0 +1 @@
1
+ {"version":3,"file":"open-grid-vue.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,5 +1,5 @@
1
1
  import { defineComponent as f, ref as p, shallowRef as m, computed as h, onMounted as g, watch as d, onUnmounted as y, openBlock as b, createElementBlock as v, normalizeStyle as C } from "vue";
2
- import { O as k } from "./OpenGrid-sI_vdHQw.js";
2
+ import { O as k } from "./OpenGrid-DACnZdEy.js";
3
3
  const w = f({ __name: "OpenGrid", props: { data: { default: () => [] }, columns: {}, height: { default: 400 }, width: { default: "100%" }, editable: { type: Boolean, default: false }, sortable: { type: Boolean, default: true }, filterable: { type: Boolean, default: true }, rowNumber: { type: Boolean, default: false }, checkColumn: { type: Boolean, default: false }, stateColumn: { type: Boolean, default: false }, draggable: { type: Boolean, default: false }, frozenColumns: { default: 0 }, theme: { default: "default" }, options: {} }, emits: ["update:data", "ready", "cell-click", "row-click", "edit-end", "sort-change", "filter-change", "row-check"], setup(n, { expose: u, emit: r }) {
4
4
  const e = n, o = r, c = p(), a = m(null);
5
5
  let i = null;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"open-grid-vue.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
- const OpenGrid = require("./OpenGrid-BOtTt5aI.cjs"), Registry = require("./Registry-D74ZmdDz.cjs");
3
+ const OpenGrid = require("./OpenGrid-CT9bV6On.cjs"), Registry = require("./Registry-D74ZmdDz.cjs");
4
4
  class GridShuttle {
5
5
  constructor(t, e, n, o = {}) {
6
6
  this._left = t, this._right = e;
@@ -0,0 +1 @@
1
+ {"version":3,"file":"open-grid.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
package/dist/open-grid.js CHANGED
@@ -1,5 +1,5 @@
1
- import { b, t as T } from "./OpenGrid-sI_vdHQw.js";
2
- import { D, I, L, O, S, i, l, r, s } from "./OpenGrid-sI_vdHQw.js";
1
+ import { b, t as T } from "./OpenGrid-DACnZdEy.js";
2
+ import { D, I, L, O, S, i, l, r, s } from "./OpenGrid-DACnZdEy.js";
3
3
  import { R, T as T2, i as i2 } from "./Registry-CPJYOqCn.js";
4
4
  class C {
5
5
  constructor(t, e, r2, o = {}) {
@@ -0,0 +1 @@
1
+ {"version":3,"file":"open-grid.js","sources":["../src/core/GridShuttle.ts"],"sourcesContent":["// ============================================================\n// 그리드 셔틀 — 두 그리드 사이에 화살표 버튼을 두고\n// \"체크된 행\"을 드래그 없이 버튼으로 이동(move)시킨다.\n// 이동 자체는 grid.moveCheckedTo() 를 호출 → crossGridMapping(필드 매핑)과\n// 3단계 이벤트가 드래그 이동과 동일하게 적용된다.\n// ============================================================\nimport type { OpenGridInstance } from './types.js';\n\n/**\n * 그리드 셔틀 생성 옵션.\n *\n * Grid shuttle construction options.\n *\n * グリッドシャトルの生成オプション。\n *\n * 表格穿梭框的构造选项。\n */\nexport interface GridShuttleOptions {\n /**\n * 버튼 배치 방향. 두 그리드가 가로로 나란히 있으면 'vertical'(위아래 버튼), 세로로 쌓여 있으면\n * 'horizontal'을 쓴다. 기본 'vertical'.\n *\n * Button layout direction. Use 'vertical' (stacked buttons) when the two grids sit side by side,\n * or 'horizontal' when they're stacked vertically. Default 'vertical'.\n *\n * ボタンの配置方向。2つのグリッドが横に並んでいる場合は 'vertical'(上下のボタン)、縦に積まれて\n * いる場合は 'horizontal' を使います。既定は 'vertical'。\n *\n * 按钮的排列方向。两个表格左右并排时用 'vertical'(上下排列的按钮),上下堆叠时用\n * 'horizontal'。默认 'vertical'。\n *\n * @defaultValue 'vertical'\n */\n layout?: 'vertical' | 'horizontal';\n /**\n * 전체 이동(≫ ≪) 버튼도 표시. \"전체 선택 후 이동\"을 한 번의 클릭으로 줄이고 싶을 때 켠다.\n * 기본 false(개별 이동 버튼만 표시).\n *\n * Also show move-all (≫ ≪) buttons, so a full transfer takes one click instead of\n * \"select all, then move\". Default false (only the per-check move buttons are shown).\n *\n * 全件移動(≫ ≪)ボタンも表示します。「全選択してから移動」を1回のクリックに縮めたいときに\n * 有効にします。既定は false(個別移動ボタンのみ表示)。\n *\n * 同时显示全部移动(≫ ≪)按钮,把「全选后再移动」缩短为一次点击。默认 false(仅显示单项\n * 移动按钮)。\n *\n * @defaultValue false\n */\n includeAll?: boolean;\n /**\n * 버튼 라벨 커스터마이즈(다국어 문구를 직접 넣고 싶을 때). 생략 시 그리드 로케일의 기본\n * 문구(▶ ◀ ⏩ ⏪)를 사용한다.\n *\n * Customize button labels (e.g. to hardcode a specific phrase). Falls back to the grid's\n * locale defaults (▶ ◀ ⏩ ⏪) when omitted.\n *\n * ボタンラベルのカスタマイズ(多言語の文言を直接入れたいとき)。省略した場合はグリッドロケールの\n * 既定の文言(▶ ◀ ⏩ ⏪)を使います。\n *\n * 自定义按钮标签(需要直接写入多语言文案时)。省略时回退到表格区域设置的默认文案\n * (▶ ◀ ⏩ ⏪)。\n */\n labels?: { toRight?: string; toLeft?: string; allRight?: string; allLeft?: string };\n}\n\n/**\n * 두 그리드 사이의 셔틀 UI.\n *\n * Shuttle UI between two grids.\n *\n * 2つのグリッドの間に置くシャトルUI。\n *\n * 两个表格之间的穿梭框 UI。\n *\n * \"가용 항목 그리드\"와 \"선택된 항목 그리드\"를 나란히 두고, 그 사이에서 체크한 행을 화살표\n * 버튼으로 옮기고 싶을 때 쓴다(권한 배정, 컬럼 표시 여부 선택 같은 화면에 흔한 UI 패턴).\n * 동작 순서는 이렇다: 사용자가 왼쪽 그리드에서 행을 체크하고 ▶ 버튼을 클릭하면, 내부적으로\n * `grid.moveCheckedTo()` 가 호출되어 오른쪽 그리드로 행이 옮겨진다 — 이때 crossGridMapping\n * (필드 매핑)과 3단계 이벤트가 드래그로 옮길 때와 동일하게 적용되므로, 버튼 이동과 드래그\n * 이동을 섞어 써도 동작이 갈리지 않는다.\n *\n * Places arrow buttons between an \"available items\" grid and a \"selected items\" grid so\n * checked rows can be moved between them without dragging (a common pattern for permission\n * assignment, column visibility pickers, etc.). Operation order: the user checks rows in the\n * left grid and clicks ▶, which internally calls `grid.moveCheckedTo()` to move those rows into\n * the right grid — crossGridMapping (field mapping) and the 3-stage events apply identically to\n * drag-based moves, so mixing button moves with drag moves never behaves differently.\n *\n * 「利用可能な項目のグリッド」と「選択された項目のグリッド」を並べて置き、その間でチェックした行を\n * 矢印ボタンで移したいときに使います(権限の割り当てや、列の表示可否の選択といった画面によくあるUI\n * パターンです)。動作の順序は次のとおりです。ユーザーが左のグリッドで行をチェックして ▶ ボタンを\n * クリックすると、内部で `grid.moveCheckedTo()` が呼ばれ、右のグリッドへ行が移されます — このとき\n * crossGridMapping(フィールドマッピング)と3段階のイベントがドラッグで移すときと同じように適用\n * されるため、ボタン移動とドラッグ移動を混ぜて使っても動作が食い違うことはありません。\n *\n * 在「可用项目表格」和「已选项目表格」之间放置箭头按钮,无需拖拽即可移动勾选的行(权限分配、\n * 列显示与否的选择等界面中常见的 UI 模式)。动作顺序如下:用户在左侧表格勾选行并点击 ▶,内部\n * 就会调用 `grid.moveCheckedTo()` 把这些行移入右侧表格 — 此时 crossGridMapping(字段映射)\n * 和 3 阶段事件与拖拽移动完全相同地生效,因此混用按钮移动和拖拽移动也不会出现动作分歧。\n *\n * @example\n * const shuttle = new GridShuttle(leftGrid, rightGrid, document.querySelector('#mid')!, {\n * layout: 'vertical',\n * includeAll: true,\n * });\n */\nexport class GridShuttle {\n private _el: HTMLElement;\n\n /**\n * @param _left - 왼쪽 그리드 인스턴스\n *\n * Left grid instance.\n *\n * 左のグリッドインスタンス。\n *\n * 左侧表格实例。\n *\n * @param _right - 오른쪽 그리드 인스턴스\n *\n * Right grid instance.\n *\n * 右のグリッドインスタンス。\n *\n * 右侧表格实例。\n *\n * @param mount - 셔틀 버튼을 붙일 마운트 엘리먼트\n *\n * Mount element to attach the shuttle buttons.\n *\n * シャトルボタンを取り付けるマウント要素。\n *\n * 用于挂载穿梭框按钮的元素。\n *\n * @param opts - 셔틀 옵션\n *\n * Shuttle options.\n *\n * シャトルのオプション。\n *\n * 穿梭框选项。\n */\n constructor(\n private _left: OpenGridInstance,\n private _right: OpenGridInstance,\n mount: HTMLElement,\n opts: GridShuttleOptions = {},\n ) {\n const wrap = document.createElement('div');\n wrap.className = 'og-shuttle';\n wrap.style.cssText =\n `display:flex;gap:6px;align-items:center;justify-content:center;` +\n `flex-direction:${opts.layout === 'horizontal' ? 'row' : 'column'};`;\n\n const mk = (label: string, title: string, fn: () => void): HTMLButtonElement => {\n const b = document.createElement('button');\n b.type = 'button';\n b.className = 'og-shuttle-btn';\n b.textContent = label;\n b.title = title;\n b.style.cssText =\n 'min-width:34px;height:30px;padding:0 8px;border:1px solid #bbb;border-radius:7px;' +\n 'background:#fff;cursor:pointer;font-size:14px;color:#444;line-height:1;' +\n 'box-shadow:0 1px 2px rgba(0,0,0,0.06);';\n b.addEventListener('mouseover', () => { b.style.background = '#f0f6ff'; b.style.borderColor = '#1976d2'; });\n b.addEventListener('mouseout', () => { b.style.background = '#fff'; b.style.borderColor = '#bbb'; });\n b.addEventListener('click', fn);\n return b;\n };\n\n const L = opts.labels ?? {};\n // i18n: 버튼 title 은 왼쪽 그리드 인스턴스 로케일로 해석(라벨 옵션이 있으면 그 값이 우선).\n const t = (key: string) => this._left.t(key);\n wrap.appendChild(mk(L.toRight ?? '▶', t('shuttle.toRight'),\n () => { void this._left.moveCheckedTo(this._right); }));\n wrap.appendChild(mk(L.toLeft ?? '◀', t('shuttle.toLeft'),\n () => { void this._right.moveCheckedTo(this._left); }));\n\n if (opts.includeAll) {\n wrap.appendChild(mk(L.allRight ?? '⏩', t('shuttle.allRight'),\n () => { void this._moveAll(this._left, this._right); }));\n wrap.appendChild(mk(L.allLeft ?? '⏪', t('shuttle.allLeft'),\n () => { void this._moveAll(this._right, this._left); }));\n }\n\n mount.appendChild(wrap);\n this._el = wrap;\n }\n\n private _moveAll(from: OpenGridInstance, to: OpenGridInstance): void {\n const n = from.getData().length;\n if (n > 0) void from.moveRowsTo(to, Array.from({ length: n }, (_, i) => i));\n }\n\n /**\n * 셔틀 UI 를 DOM 에서 제거한다.\n *\n * Remove the shuttle UI from the DOM.\n *\n * シャトルUIをDOMから取り除きます。\n *\n * 从 DOM 中移除穿梭框 UI。\n */\n destroy(): void { this._el.remove(); }\n}\n\n/**\n * 두 그리드 사이에 셔틀(화살표 이동) 버튼을 만든다.\n *\n * Create shuttle (arrow-move) buttons between two grids.\n *\n * 2つのグリッドの間にシャトル(矢印移動)ボタンを作ります。\n *\n * 在两个表格之间创建穿梭框(箭头移动)按钮。\n *\n * `new GridShuttle(...)` 과 동일하되, `new` 없이 함수 호출 한 줄로 끝내고 싶을 때 쓰는 편의 팩토리.\n *\n * Same as `new GridShuttle(...)`, but a convenience factory for callers who'd rather skip `new`.\n *\n * `new GridShuttle(...)` と同じですが、`new` なしで関数呼び出し1行で済ませたいときに使う便利\n * ファクトリです。\n *\n * 与 `new GridShuttle(...)` 相同,只是为不想写 `new` 的调用方提供的便捷工厂。\n *\n * @param left - 왼쪽 그리드 인스턴스\n *\n * Left grid instance.\n *\n * 左のグリッドインスタンス。\n *\n * 左侧表格实例。\n *\n * @param right - 오른쪽 그리드 인스턴스\n *\n * Right grid instance.\n *\n * 右のグリッドインスタンス。\n *\n * 右侧表格实例。\n *\n * @param mount - 셔틀 버튼을 붙일 마운트 엘리먼트\n *\n * Mount element to attach the shuttle buttons.\n *\n * シャトルボタンを取り付けるマウント要素。\n *\n * 用于挂载穿梭框按钮的元素。\n *\n * @param opts - 셔틀 옵션\n *\n * Shuttle options.\n *\n * シャトルのオプション。\n *\n * 穿梭框选项。\n *\n * @returns 생성된 GridShuttle 인스턴스\n *\n * The created GridShuttle instance.\n *\n * 生成された GridShuttle インスタンス。\n *\n * 创建的 GridShuttle 实例。\n *\n * @example\n * const shuttle = createGridShuttle(leftGrid, rightGrid, mountEl, { includeAll: true });\n */\nexport function createGridShuttle(\n left: OpenGridInstance,\n right: OpenGridInstance,\n mount: HTMLElement,\n opts?: GridShuttleOptions,\n): GridShuttle {\n return new GridShuttle(left, right, mount, opts);\n}\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2GO;AAAA,QAAA,iBAAkB,gBAAA;AAAA,IAAA,CAAA,GAAA,EAAA,KAAA,eAAA,GAAA,EAAA,KAAA;AAAA,CAAA;AAAA,EAAA;AAAA,EAAA,OAAA,SAAA,GAAA;AAAA,WAAA,EAAA,QAAA,MAAA,OAAA,EAAA,QAAA,MAAA,MAAA,EAAA,QAAA,MAAA,MAAA;AAAA,EAAA;AAAA,EAAA,OAAA,SAAA,GAAA;AAAA,WAAA,KAAA,SAAA,CAAA,EAAA,QAAA,MAAA,QAAA,EAAA,QAAA,MAAA,QAAA;AAAA,EAAA;AAAA;"}
@@ -130,10 +130,10 @@ export declare class DetailManager<T extends Record<string, any> = any> {
130
130
  */
131
131
  getPanelHost(rowId: string): HTMLElement;
132
132
  private _buildInstance;
133
- /** §5(4) skip-rebuild(FR-8/NFR-2, MCCONNELL-04 → Phase1 승격): renderBody teardown 직전
133
+ /** §5(4) skip-rebuild(FR-8/NFR-2, REVIEW-04 → Phase1 승격): renderBody teardown 직전
134
134
  * 호출된다. 편집 중인 host 는 detach 자체를 회피(document.body 로 hoist, 연결 유지 → blur
135
135
  * 없음) 하고, 그 외는 정상 detach(연결 끊음, 참조는 Map 이 쥐고 있어 파괴 아님).
136
- * / §5(4) skip-rebuild (FR-8/NFR-2, MCCONNELL-04 → promoted to Phase1): called immediately
136
+ * / §5(4) skip-rebuild (FR-8/NFR-2, REVIEW-04 → promoted to Phase1): called immediately
137
137
  * before renderBody teardown. A host that is currently being edited avoids detach altogether
138
138
  * (hoisted into document.body, staying connected → no blur); every other host is detached
139
139
  * normally (disconnected, but not destroyed — the Map still holds the reference). */
@@ -203,8 +203,8 @@ export declare class FormulaController<T extends Record<string, any> = any> {
203
203
  error: FormulaErrorCode | null;
204
204
  approx: boolean;
205
205
  } | null;
206
- /** F3-R13/MCCONNELL-03(P0): 정렬/필터 후 범위-보유(hasRangeRef) 수식 전부 dirty(§3.5).
207
- * / F3-R13/MCCONNELL-03 (P0): after sort/filter, marks every range-referencing (hasRangeRef)
206
+ /** F3-R13/REVIEW-03(P0): 정렬/필터 후 범위-보유(hasRangeRef) 수식 전부 dirty(§3.5).
207
+ * / F3-R13/REVIEW-03 (P0): after sort/filter, marks every range-referencing (hasRangeRef)
208
208
  * formula dirty (§3.5). */
209
209
  recalcRangeBearingFormulas(): void;
210
210
  }
@@ -75,7 +75,7 @@ export interface CommitSpec {
75
75
  * **동작 불변**으로 옮긴 것. `OpenGrid` 는 얇은 위임 공개 메서드만 남긴다(공개 API 불변).
76
76
  *
77
77
  * 스트랭글러 원칙(A2): DataLayer 는 여전히 `OpenGrid` 가 소유하며, 여기에는 `*Deps`
78
- * 클로저 역전 패턴으로 **주입**만 된다. **서비스는 렌더를 직접 모른다**(Yourdon I/O 분리):
78
+ * 클로저 역전 패턴으로 **주입**만 된다. **서비스는 렌더를 직접 모른다**(구조설계 I/O 분리):
79
79
  * render 는 주입된 `doRenderWindow`/`doRenderFull` 콜백으로만 유발한다. 값(vs/pagination/recalc
80
80
  * 등)은 늦은-null / 재할당(worksheet 전환)을 견디도록 전부 getter 클로저로 읽는다.
81
81
  * 배치 코얼레싱(`_batchDepth`/`_batchDirty`) 시맨틱은 R4 와 1:1 동일하다(회귀 0).
@@ -86,7 +86,7 @@ export interface CommitSpec {
86
86
  *
87
87
  * Strangler principle (A2): `DataLayer` is still owned by `OpenGrid`; it is only **injected**
88
88
  * here via the `*Deps` closure-inversion pattern. **The service has no direct knowledge of
89
- * rendering** (Yourdon I/O separation): render is only triggered through the injected
89
+ * rendering** (구조설계 I/O separation): render is only triggered through the injected
90
90
  * `doRenderWindow`/`doRenderFull` callbacks. Values (vs/pagination/recalc, etc.) are all read
91
91
  * through getter closures so they tolerate late-null / reassignment (worksheet switching).
92
92
  * Batch coalescing semantics (`_batchDepth`/`_batchDirty`) are 1:1 identical to R4 (zero
@@ -2497,13 +2497,13 @@ export declare class OpenGrid<T extends Record<string, any> = any> extends Event
2497
2497
  */
2498
2498
  resetFilter(field?: string): void;
2499
2499
  /**
2500
- * F3-R13/MCCONNELL-03(P0): 정렬/필터 후 범위-보유(hasRangeRef) 수식 전부 dirty(§3.5).
2500
+ * F3-R13/REVIEW-03(P0): 정렬/필터 후 범위-보유(hasRangeRef) 수식 전부 dirty(§3.5).
2501
2501
  *
2502
- * F3-R13/MCCONNELL-03 (P0): after sort/filter, mark every range-bearing (hasRangeRef) formula dirty (§3.5).
2502
+ * F3-R13/REVIEW-03 (P0): after sort/filter, mark every range-bearing (hasRangeRef) formula dirty (§3.5).
2503
2503
  *
2504
- * F3-R13/MCCONNELL-03(P0): ソート/フィルター後、範囲を保持する(hasRangeRef)数式をすべて dirty にします(§3.5)。
2504
+ * F3-R13/REVIEW-03(P0): ソート/フィルター後、範囲を保持する(hasRangeRef)数式をすべて dirty にします(§3.5)。
2505
2505
  *
2506
- * F3-R13/MCCONNELL-03(P0): 排序/筛选后,把持有范围的(hasRangeRef)公式全部置为 dirty(§3.5)。
2506
+ * F3-R13/REVIEW-03(P0): 排序/筛选后,把持有范围的(hasRangeRef)公式全部置为 dirty(§3.5)。
2507
2507
  */
2508
2508
  private _recalcRangeBearingFormulas;
2509
2509
  /**
@@ -1,5 +1,5 @@
1
1
  /** 외관 축 식별자. 이름공간(prefix)이 물리 직교의 열쇠. / Appearance axis id; the token prefix is the key to physical orthogonality. */
2
- export type AxisId = 'theme' | 'skin' | 'density' | 'texture' | 'icon';
2
+ export type AxisId = 'theme' | 'skin' | 'density' | 'texture' | 'icon' | 'typography' | 'header';
3
3
  /** 한 축의 CSS 변수 델타(자기 이름공간만). / A CSS-var delta for one axis (own namespace only). */
4
4
  export type TokenDelta = Readonly<Record<string, string>>;
5
5
  /** 컨테이너에 붙일 data-* 속성. / A data-* attribute to place on the container. */