@cyberskill/design 1.3.8 → 1.3.9

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 (55) hide show
  1. package/DESIGN.md +8 -7
  2. package/README.md +13 -10
  3. package/SKILL.md +15 -6
  4. package/VERSION +1 -1
  5. package/_ds_bundle.js +2 -2
  6. package/_esm/cs.mjs +2 -2
  7. package/docs/benchmark-rubric.md +2 -2
  8. package/docs/ci-cd.md +1 -1
  9. package/docs/consumer-grant.md +1 -1
  10. package/docs/consuming.md +9 -5
  11. package/docs/contrast-report.md +3 -1
  12. package/docs/conventions.md +1 -1
  13. package/docs/decisions.md +1 -1
  14. package/docs/deploy.md +3 -1
  15. package/docs/design-styles.md +1 -1
  16. package/docs/doctrine.md +51 -0
  17. package/docs/figma.md +2 -0
  18. package/docs/live-hub.md +3 -1
  19. package/docs/products.md +1 -1
  20. package/docs/quality-gates.md +7 -3
  21. package/docs/release-notes.md +1 -1
  22. package/docs/release-runbook.md +1 -1
  23. package/docs/storybook.md +3 -3
  24. package/docs/sync.md +8 -8
  25. package/docs/template-schema-v2.md +1 -1
  26. package/docs/vi/benchmark-rubric.md +2 -2
  27. package/docs/vi/ci-cd.md +1 -1
  28. package/docs/vi/consumer-grant.md +1 -1
  29. package/docs/vi/consuming.md +9 -5
  30. package/docs/vi/contrast-report.md +3 -1
  31. package/docs/vi/conventions.md +1 -1
  32. package/docs/vi/decisions.md +1 -1
  33. package/docs/vi/deploy.md +3 -1
  34. package/docs/vi/design-styles.md +1 -1
  35. package/docs/vi/doctrine.md +51 -0
  36. package/docs/vi/figma.md +2 -0
  37. package/docs/vi/live-hub.md +3 -1
  38. package/docs/vi/products.md +1 -1
  39. package/docs/vi/quality-gates.md +6 -2
  40. package/docs/vi/release-notes.md +1 -1
  41. package/docs/vi/release-runbook.md +1 -1
  42. package/docs/vi/storybook.md +3 -3
  43. package/docs/vi/sync.md +7 -7
  44. package/docs/vi/template-schema-v2.md +1 -1
  45. package/docs/viewer.html +15 -4
  46. package/llms.txt +18 -11
  47. package/package.json +2 -2
  48. package/tokens/element-seeds.json +1 -1
  49. package/tokens/native/CSTokens.kt +1 -1
  50. package/tokens/native/CSTokens.swift +1 -1
  51. package/tokens/native/cs_tokens.dart +1 -1
  52. package/tokens/provenance.json +6 -6
  53. package/tokens/tokens.dtcg.json +1 -1
  54. package/tokens/tokens.js +2 -2
  55. package/tokens/tokens.json +1 -1
@@ -1,10 +1,10 @@
1
1
  # Quality gates — the benchmark reference
2
2
 
3
- Every deterministic quality gate in the system, what it asserts, its pass criterion, whether it blocks (hard) or informs (advisory), and where it runs.
3
+ Every deterministic quality gate in the system, what it asserts, its pass criterion, whether it blocks (hard) or informs (advisory), and where it runs. Published on Storybook **Docs** at `design.cyberskill.world`.
4
4
 
5
5
  **Where gates run.** *Fast board CI* = the `fast-gates` job in `.github/workflows/design-system-gates.yml`, which serves the repo and drives `_audit/run.html` headless via `_audit/ci/run-gates.mjs` (every push/PR + nightly + manual) — new board rows are picked up automatically. Two gates additionally run standalone as *merge blockers* (`docs-consistency-blocker` job, via `_audit/ci/run-single-gate.mjs`). *Whole-set CI* = the `whole-set-audits` job (every push/PR + nightly — owner decision B). *Unit test* = `npm run test:unit` in the `unit-tests` job (plain Node, no browser). *Node pre-checks* = the `node-prechecks` job (browser-free authorities: bundle freshness, DESIGN.md freshness, styles.min.css + contrast-report freshness, manifest coverage) plus the `token-provenance` job. *Storybook CI* = the `storybook-build` job (`build:storybook` + freshness `--require`). Every browser gate publishes a verdict global (`window.__*`) that the headless runners read.
6
6
 
7
- ## Fast board — 40 gates in `_audit/run.html`
7
+ ## Fast board — 42 gates in `_audit/run.html`
8
8
 
9
9
  Benchmark principles (WCAG · APCA · OKLCH · DTCG · CDS doctrine + style expansion): [`docs/benchmark-rubric.md`](benchmark-rubric.md).
10
10
 
@@ -13,9 +13,11 @@ Benchmark principles (WCAG · APCA · OKLCH · DTCG · CDS doctrine + style expa
13
13
  | Contrast guard | `_audit/contrast-guard.html` | No base rule paints umber on a themeable surface without a dark override; every semantic text×surface pair scores in light and dark | 0 unshielded rules and 0 failing pairs (`__contrastguard`) | Hard | Fast board CI |
14
14
  | Axes guard | `_audit/axis-guard.html` | No live source reintroduces the retired Expression/Density product surface | 0 hits across manifest-indexed sources (`__axisguard`) | Hard | Fast board CI |
15
15
  | Manifest CSS paths | `_audit/manifest-css-guard.html` | Every `_ds_manifest.json` `globalCssPaths` entry exists as raw CSS; every `styles.css` `@import` is listed | 0 missing / 0 unlisted (`__cssguard`) | Hard | Fast board CI |
16
- | Docs consistency | `_audit/docs-consistency.html` | Every count claim in README/SKILL/llms.txt matches the compiler manifest; audit prose card-count claims (`_audit/index` / README / namespace-portability) match `manifest.cards`; `VERSION` is semver and `package.json` matches it (LAUNCHED 1.1.0; auto-bump on main); no changelog-file reference; stale-phrase blacklist (the retired suite/pack counts the Jul 2026 audit removed) clean across README/SKILL/llms + `docs/*.md` (historical notes under `_audit/archive/` are not scanned); `DESIGN.md` exists with front-matter version = `VERSION`; agent routing honesty — Claude path cites `_esm/cs.mjs` + bundle prefix; Stitch path forbids `*.dc.html` as SoT; package name `@cyberskill/design`; doctrine↔source parity — 10 accent roles incl. `on-strong`, full depth scale, default lang `vi` vs `i18n.js`, breakpoint CSS↔JSON, `base/` depth fallbacks vs `elevation.css` | 0 mismatched claims, 0 blacklist hits, VERSION sync + stamp + routing + doctrine parity intact (`__docs`) | Hard | Fast board CI + merge blocker |
16
+ | Docs consistency | `_audit/docs-consistency.html` | Every count claim in README/SKILL/llms.txt matches the compiler manifest; audit prose card-count claims (`_audit/index` / README / namespace-portability) match `manifest.cards`; `VERSION` is semver and `package.json` matches it (LAUNCHED 1.1.0; auto-bump on main); no changelog-file reference; stale-phrase blacklist (the retired suite/pack counts the Jul 2026 audit removed) clean across README/SKILL/llms + `docs/*.md` (historical notes under `_audit/archive/` are not scanned); `DESIGN.md` exists with front-matter version = `VERSION`; agent routing honesty — SKILL/llms cite `_esm/cs.mjs` + bundle prefix; Stitch path forbids `*.dc.html` as SoT; package name `@cyberskill/design`; doctrine↔source parity — 10 accent roles incl. `on-strong`, full depth scale, default lang `vi` vs `i18n.js`, breakpoint CSS↔JSON, `base/` depth fallbacks vs `elevation.css` | 0 mismatched claims, 0 blacklist hits, VERSION sync + stamp + routing + doctrine parity intact (`__docs`) | Hard | Fast board CI + merge blocker |
17
17
  | Asset-weight budget | `_audit/asset-weight-budget.html` | Elemental aurora WebPs (`assets/aurora-{tho,hoa,thuy,moc,kim}.webp`) stay under regression ceilings (≤300 KB each, ≤1.2 MB set); legacy aurora PNGs fail; wash CSS must not point at the Thổ JPEG | All five present under ceilings (`__assetweight`) | Hard | Fast board CI (+ Node twin in `test-docs-consistency.mjs`) |
18
18
  | Docs language parity | `_audit/docs-lang-parity.html` | Every operator-facing EN `docs/*.md` has a `docs/vi/` counterpart; VI is not an empty/TODO stub (≥40% EN length); stale-phrase blacklist clean on both EN and VI (historical notes under `_audit/archive/` are not tracked) | 0 missing pairs, 0 stubs, 0 blacklist hits (`__docslangparity`) | Hard | Fast board CI |
19
+ | Docs Storybook coverage | `_audit/docs-storybook-coverage.html` | Live HTML: published catalog + `/docs/**` + viewer + entrance files; Storybook `index.json` titles when present (never unpublished `.storybook/` / `stories/`). Node twin: CSF/MDX source + `staticDirs` | 0 missing published pages / viewer entries (`__docssbcoverage`) | Hard | Fast board CI + unit twin |
20
+ | Docs link check | `_audit/docs-link-check.html` | Live HTML: published markdown + viewer links resolve; no retired paths. Node twin also scans unpublished MDX `href`/`src` | 0 broken in-repo links (`__docslinkcheck`) | Hard | Fast board CI + unit twin |
19
21
  | DESIGN.md parity | `_audit/design-md-parity.html` | The root `DESIGN.md` (Stitch open-spec surface) byte-equals an in-browser regeneration from `tokens.dtcg.json` + `_ds_manifest.json` + `VERSION` via the shared `scripts/design-md-lib.mjs`; every token row re-checked individually (the count is printed with the verdict) | Byte-identical + 0 drifted rows (`__designmd`) | Hard | Fast board CI |
20
22
  | Version stamp | `_audit/version-stamp.html` | `package.json`, `tokens.json`/`tokens.js` metas, DTCG `$extensions`, `provenance.json` release + dtcgStamp, `DESIGN.md` front matter, and `_esm/cs.mjs` `export const VERSION` all equal `VERSION` (pin tracks file; LAUNCHED at 1.1.0) | All 9 stamps equal (`__versionstamp`) | Hard | Fast board CI |
21
23
  | Namespace portability | `_audit/namespace-portability.html` | No manifest-indexed source hardcodes the compiler's project-id bundle suffix | 0 hardcoded suffixes (`__nsguard`) | Hard | Fast board CI |
@@ -78,6 +80,8 @@ Benchmark principles (WCAG · APCA · OKLCH · DTCG · CDS doctrine + style expa
78
80
  | Nav model | `_audit/ci/test-nav-model.mjs` | The shipped `guidelines/nav-model.js` classify/group logic behaves (drives the real module) | All assertions pass (exit 0) | Hard | Unit test |
79
81
  | Health/Tokens UI contract | `_audit/ci/test-health-tokens-contract.mjs` | Structural contracts of the Health + Tokens HTML entry points hold | All assertions pass (exit 0) | Hard | Unit test |
80
82
  | Docs consistency (Node twin) | `_audit/ci/test-docs-consistency.mjs` | Doctrine↔source parity (roles/depth/lang/breakpoints/fallbacks) + aurora asset-weight ceilings | All assertions pass (exit 0) | Hard | Unit test |
83
+ | Docs Storybook coverage (Node twin) | `_audit/ci/test-docs-storybook-coverage.mjs` | Tracked docs + entrance + doctrine each have a Storybook story title and a viewer nav path; `staticDirs` includes `docs/` | Exit 0 | Hard | Unit test |
84
+ | Docs link check (Node twin) | `_audit/ci/test-docs-link-check.mjs` | In-repo relative links in the required published set resolve; retired paths absent as live hrefs | Exit 0 | Hard | Unit test |
81
85
  | Form paths | `_audit/ci/test-form-paths.mjs` | Form path helpers behave (drives the shipped `Form.jsx` via dynamic import) | All assertions pass (exit 0) | Hard | Unit test |
82
86
  | Storybook contract | `_audit/ci/test-storybook-contract.mjs` | Live hub is Storybook only; SB10 ESM main + addon-docs/a11y; complete CSF for every public primary; Matrix/AllVariants + AllSizes when `argTypes.size`; States/Matrix cover disabled/loading/error/busy; every discrete size/variant enum mounted; FullMatrix required when ≥1 of {size, variant, state} axes exist (≥28 qualifiers) | All assertions pass (exit 0) | Hard | Unit test |
83
87
  | Axe coverage | `_audit/ci/test-axe-coverage.mjs` | Fixture `NAMES` ≡ `listPublicComponents()`; axe-smoke loads inventory-locked fixtures | All assertions pass (exit 0) | Hard | Unit test |
@@ -1,6 +1,6 @@
1
1
  # Release Notes
2
2
 
3
- Curated product highlights for operators. This is **not** a git log and **not** a `CHANGELOG.md` — the design system does not maintain a changelog file. Version is **LAUNCHED at 1.1.0**; **pin tracks `VERSION`** (auto-bump on push to `main` from Conventional Commits; owner may still force a bump). Technical continuity is the repo tip; product-facing continuity is this page (mirrored in Storybook **Release Notes**).
3
+ Curated product highlights for operators. This is **not** a git log and **not** a `CHANGELOG.md` — the design system does not maintain a changelog file. Version is **LAUNCHED at 1.1.0**; **pin tracks `VERSION`** (auto-bump on push to `main` from Conventional Commits; owner may still force a bump). Technical continuity is the repo tip; product-facing continuity is this page (mirrored in Storybook **Release Notes**). Published on Storybook **Docs** at `design.cyberskill.world`.
4
4
 
5
5
  ## Patch — `@cyberskill/design@1.1.1`
6
6
 
@@ -1,6 +1,6 @@
1
1
  # Release runbook (authoritative)
2
2
 
3
- One page for how a release happens and how to tell it worked. Consolidates areas 21/23. Related detail: `docs/ci-cd.md`, `docs/deploy.md`, `docs/decisions.md` §7 / §13.
3
+ One page for how a release happens and how to tell it worked. Consolidates areas 21/23. Related detail: `docs/ci-cd.md`, `docs/deploy.md`, `docs/decisions.md` §7 / §13. Published on Storybook **Docs** at `design.cyberskill.world`.
4
4
 
5
5
  ## Trigger
6
6
 
package/docs/storybook.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Storybook — product surface at `/` (host)
2
2
 
3
- Storybook **10** is the **product site** for operators on `design.cyberskill.world` (`/`). It is still **not** part of the portable consumer contract.
3
+ Storybook **10** is the **product site** for operators on `design.cyberskill.world` (`/`). It is still **not** part of the portable consumer contract. Published on Storybook **Docs** at `design.cyberskill.world`.
4
4
 
5
5
  ## URL
6
6
 
@@ -20,7 +20,7 @@ Storybook **10** is the **product site** for operators on `design.cyberskill.wor
20
20
  - Every discrete `size` / `variant` enum option mounted in a matrix-family story
21
21
  - `FullMatrix` when ≥1 of {size enums, variant enums, state keys} exist — the size × variant × key-state product via shared helpers in `stories/lib/matrix.jsx`
22
22
  - Toolbar globals: Theme (light · dark · **system**) × Element × Language × Style (same axes as templates / Atomic View). Element lists **all 15** Ngũ Hành packs (`tokens.elements` / template EL maps / Storybook toolbar) — not a subset. Style’s sole pack is **liquid-glass**.
23
- - **Docs/** public MDX guides; **Release Notes/** curated product prose (**no CHANGELOG.md**); **Status/** embeds `_audit/run.html` full-bleed
23
+ - **Docs/** published operator documentation — nested **Start / Guides / Maintainers**, curated MDX for high-traffic pages, one sidebar story per tracked markdown page, and a Documentation Library iframe of `/docs/viewer.html` (EN·VI). Canonical prose remains `docs/*.md`; Storybook is the live reading surface. **Release Notes/** curated product prose (**no CHANGELOG.md**); **Status/** embeds `_audit/run.html` full-bleed
24
24
  - **Maintainer/** stories for portable HTML surfaces (Motion, templates, kitchen-sink, AI cluster, RTL; Atomic View buried for gates)
25
25
  - Same `styles.css` as production
26
26
  - Addons: `@storybook/addon-docs` + `@storybook/addon-a11y` (essentials folded into core in SB10)
@@ -40,7 +40,7 @@ Storybook **10** is the **product site** for operators on `design.cyberskill.wor
40
40
  | ESM (bundler) | `_esm/react.mjs` (default / `@cyberskill/design/react`) |
41
41
  | ESM (browser legacy) | `_esm/cs.mjs` (`@cyberskill/design/legacy`) |
42
42
  | Tokens | `tokens/*` |
43
- | Claude Design | `templates/**/*.dc.html` |
43
+ | DC-capable authoring | `templates/**/*.dc.html` |
44
44
 
45
45
  ## Commands
46
46
 
package/docs/sync.md CHANGED
@@ -1,10 +1,10 @@
1
- # Repo ↔ Claude Design — round-trip fidelity & two-way sync
1
+ # Repo ↔ authoring environment — round-trip fidelity & two-way sync
2
2
 
3
- The GitHub repo (`cyberskill-official/design`) is the **source of truth**. Claude Design sessions are ephemeral project filesystems — this doc is how they stay in sync without losing work.
3
+ The GitHub repo (`cyberskill-official/design`) is the **source of truth**. Compiler sessions (for example Claude Design) are ephemeral project filesystems — this doc is how they stay in sync without losing work. Published on Storybook **Docs** at `design.cyberskill.world`.
4
4
 
5
5
  ## Does the repo restore the full system intact?
6
6
 
7
- **In a Claude-Design session — yes.** Everything that defines the system is plain text/asset files and round-trips losslessly:
7
+ **In a DC-capable compiler session — yes.** Everything that defines the system is plain text/asset files and round-trips losslessly:
8
8
  - `styles.css` + `tokens/` + `base/` (all CSS + `tokens.json`/`tokens.js`)
9
9
  - `components/**` (`.jsx` + `.d.ts` + `.prompt.md` + `*.card.html`)
10
10
  - `templates/**/*.dc.html` (+ `ds-base.js`, `support.js`)
@@ -13,15 +13,15 @@ The GitHub repo (`cyberskill-official/design`) is the **source of truth**. Claud
13
13
  - **`_esm/react.mjs`** — bundler-native React entry (default package export; React peer). Regenerated via `npm run build:react-entry`.
14
14
  - **`_esm/cs.mjs`** — the browser / no-build legacy ESM entry (`@cyberskill/design/legacy`). Underscore-prefixed does **not** mean build artifact or gitignored here (only `uploads/`, `scraps/`, `_audit/exports/` are — see Hygiene below); `_esm/` is source, same tier as `templates/` or `docs/`. A prior port of this repo skipped it on exactly this assumption and broke the ESM smoke gate — if you're porting/copying this tree by hand, **explicitly include every top-level folder this list names**, don't infer from the `_` prefix.
15
15
 
16
- - `README.md`, `CONTRIBUTING.md`, `SKILL.md`, `CLAUDE.md`, `VERSION`, `DESIGN.md` (generated open-spec surface — committed, regenerated only via `npm run build:design-md`, pinned by the `design-md-parity` gate)
16
+ - `README.md`, `CONTRIBUTING.md`, `SKILL.md`, `docs/doctrine.md`, host shims (`CLAUDE.md`), `VERSION`, `DESIGN.md` (generated open-spec surface — committed, regenerated only via `npm run build:design-md`, pinned by the `design-md-parity` gate)
17
17
 
18
- Pull them back into a fresh project (see below) and the compiler re-recognizes it as a design system — it keys off `styles.css`, the `.d.ts`/`.jsx` pairs, `@dsCard` HTML, and `templates/`. The **derived** files (`_ds_bundle.js`, `_ds_manifest.json`, `_adherence.oxlintrc.json`) are regenerated every turn from source, so they need not be trusted from the repo — they rebuild.
18
+ Pull them back into a fresh project (see below) and the compiler re-recognizes it as a design system — it keys off `styles.css`, the `.d.ts`/`.jsx` pairs, `@dsCard` HTML, and `templates/`. Committed compiled artifacts (`_ds_bundle.js`, `_ds_manifest.json`, `_adherence.oxlintrc.json`, `dist/styles.min.css`, `DESIGN.md`) are part of the consumer contract — keep them in the tree and regenerate them with the documented npm scripts rather than treating them as disposable.
19
19
 
20
- **In other agents (Google Stitch, generic LLM tools) — partially.** They can consume the **portable** layer — `tokens/tokens.json` + `tokens.js`, the raw CSS, the component `.jsx`, fonts, and the Markdown docs — but they do **not** understand the `.dc.html` Design-Component format or the compiler that drives it. So a non-Claude-Design agent gets the tokens, styles, and component source as files, not the live DC/tweak/compile behavior. Point those tools at the root **`DESIGN.md`** first (the generated Stitch-style open-spec surface: doctrine + every token value + inventory, regenerated from DTCG via `npm run build:design-md` and pinned by the `design-md-parity` gate), then `tokens.json` / `tokens.dtcg.json` and the CSS for the machine contract; treat `.dc.html` + the compiler as Claude-Design-native.
20
+ **In other agents (Google Stitch, generic LLM tools) — partially.** They can consume the **portable** layer — `tokens/tokens.json` + `tokens.js`, the raw CSS, the component `.jsx`, fonts, and the Markdown docs — but they do **not** understand the `.dc.html` Design-Component format or the compiler that drives it. So a non-compiler agent gets the tokens, styles, and component source as files, not the live DC/tweak/compile behavior. Point those tools at the root **`DESIGN.md`** first (the generated Stitch-style open-spec surface: doctrine + every token value + inventory, regenerated from DTCG via `npm run build:design-md` and pinned by the `design-md-parity` gate), then `tokens.json` / `tokens.dtcg.json` and the CSS for the machine contract; treat `.dc.html` + the compiler as DC-native.
21
21
 
22
22
  ## Two-way sync (repo = source of truth)
23
23
 
24
- Claude Design can **read/copy from** GitHub but **cannot push to** it. So sync is *automatic pull, manual push*:
24
+ Compiler sessions can **read/copy from** GitHub but typically **cannot push to** it. So sync is *automatic pull, manual push*:
25
25
  **Session START — pull (reliable, automated):** tell the agent to load the repo. It copies the tree into the fresh project (the `github_copy_files` path), the compiler validates, and you continue from the committed truth — never from stale project state. Always begin here; do not resume from a half-remembered project.
26
26
 
27
27
  **Session END — push (manual, reviewed):** download the project, then from a clone:
@@ -37,7 +37,7 @@ git push -u origin session/<date-or-topic> # branch, never --force, never stra
37
37
  The PR diff is the safety net — it shows exactly what changed since the last committed truth.
38
38
 
39
39
  ## Hygiene that keeps round-trips clean
40
- - **`.gitignore`** the transient (`uploads/`, `scraps/`, `_audit/exports/`); commit everything else, **including `_esm/`** (see above — it is source, not a build artifact, despite the `_` prefix). The compiled `_ds_bundle.js`/manifest are committed for consumers that have no build step, but expect churn — or ignore them and let each session regenerate.
40
+ - **`.gitignore`** the transient (`uploads/`, `scraps/`, `_audit/exports/`); commit everything else, **including `_esm/`** (see above — it is source, not a build artifact, despite the `_` prefix). The compiled `_ds_bundle.js`, `_ds_manifest.json`, and `_adherence.oxlintrc.json` are **committed consumer artifacts** — they ship in the npm package so consumers with no build step can load the system. Do not gitignore them. Regenerate via `npm run build:bundle` after source changes; the bundle-freshness gate fails on drift.
41
41
 
42
42
  - **`VERSION` is LAUNCHED at 1.1.0; pin tracks `VERSION`** — auto-bump on push to `main` (`.github/workflows/version.yml` → tag `v*` → `npm-publish.yml`); owner may still force a bump. Do not maintain a changelog file. Continuity is the git history; open maintainer tasks live in `docs/decisions.md`.
43
43
 
@@ -1,6 +1,6 @@
1
1
  # Template content-schema v2 — typed content slots
2
2
 
3
- Purely additive, opt-in metadata: a sidecar `templates/<slug>/content-schema.json` next to a template's `.dc.html`, declaring the **type** of each `{{ hole }}` already in the template — so an agent or pipeline can populate/validate real client content programmatically without parsing HTML or guessing.
3
+ Purely additive, opt-in metadata: a sidecar `templates/<slug>/content-schema.json` next to a template's `.dc.html`, declaring the **type** of each `{{ hole }}` already in the template — so an agent or pipeline can populate/validate real client content programmatically without parsing HTML or guessing. Published on Storybook **Docs** at `design.cyberskill.world`.
4
4
 
5
5
  **Zero template-markup changes required.** The slot `id` is the hole name already used in the `.dc.html` (e.g. `{{ heroH }}`) and already bound in the logic class's `renderVals()` — the schema just describes it.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # Rubric benchmark Design System
2
2
 
3
- Checklist tự kiểm khi tiến hóa CyberSkill Design System — chuẩn bên ngoài cộng rule CDS. Ghép với [`docs/vi/quality-gates.md`](quality-gates.md) (gate xác định) và [`docs/vi/design-styles.md`](design-styles.md) (hợp đồng màu Element).
3
+ Checklist tự kiểm khi tiến hóa CyberSkill Design System — chuẩn bên ngoài cộng rule CDS. Ghép với [`docs/vi/quality-gates.md`](quality-gates.md) (gate xác định) và [`docs/vi/design-styles.md`](design-styles.md) (hợp đồng màu Element). Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## Chuẩn bên ngoài
6
6
 
@@ -22,7 +22,7 @@ Checklist tự kiểm khi tiến hóa CyberSkill Design System — chuẩn bên
22
22
  | Chữ không trên mid `-accent`; focus Ochre không remap; màu status không remap | Hợp đồng `elements.css` · contrast-report · conventions |
23
23
  | Một element mỗi bề mặt; gradient chỉ Tương sinh | Registry products · conventions |
24
24
  | Registry product→element khóa; UI kit trung thành Thổ | [`docs/vi/products.md`](products.md) |
25
- | Expansion Rule đủ + `_audit/run.html` xanh + docs EN·VI parity | CLAUDE.md · docs-consistency · docs-lang-parity |
25
+ | Expansion Rule đủ + `_audit/run.html` xanh + docs EN·VI parity | `docs/doctrine.md` · docs-consistency · docs-lang-parity · docs-storybook-coverage |
26
26
  | VERSION theo file (LAUNCH 1.1.0; auto-bump trên main) | version-stamp · docs-consistency |
27
27
  | Pack Element chỉ từ seed (30 bộ) | `element-geometry` · `tokens:elements` |
28
28
 
package/docs/vi/ci-cd.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # CI/CD — tự động hóa bảng gate
2
2
 
3
- **Gate CI** (workflow này) vẫn coi design system như cây tĩnh: serve repo, mở `_audit/run.html` headless, đọc verdict globals. Không cần product bundler cho gates.
3
+ **Gate CI** (workflow này) vẫn coi design system như cây tĩnh: serve repo, mở `_audit/run.html` headless, đọc verdict globals. Không cần product bundler cho gates. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  **Host deploy** (Vercel, tách khỏi workflow này) chạy `npm install` + `npm run build:site` để Storybook ship làm bề mặt sản phẩm tại `/` — xem `docs/deploy.md` và `docs/storybook.md`. Đường đóng gói host đó không bắt buộc cho consuming project hay các job gate bên dưới.
6
6
 
@@ -1,6 +1,6 @@
1
1
  # Grant consumer — `@cyberskill/design`
2
2
 
3
- **Trạng thái: có hiệu lực** (Th7 2026). Văn bản chính sách — không phải secret. License trên package vẫn **UNLICENSED**; grant này là lớp duyệt dùng trong các sản phẩm đã nêu.
3
+ **Trạng thái: có hiệu lực** (Th7 2026). Văn bản chính sách — không phải secret. License trên package vẫn **UNLICENSED**; grant này là lớp duyệt dùng trong các sản phẩm đã nêu. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## Grant
6
6
 
@@ -1,10 +1,14 @@
1
1
  # Tiêu thụ & nâng cấp CyberSkill Design System
2
2
 
3
- Cách mọi project — do người hoặc agent điều khiển — áp dụng design system HTML-first này, và cách nhận update an toàn.
3
+ Cách mọi project — do người hoặc agent điều khiển — áp dụng design system HTML-first này, và cách nhận update an toàn. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  **Tên package:** `@cyberskill/design` (xem `package.json`). Không coi `@cyberskill/react` lịch sử là đường cài cho monolith này.
6
6
 
7
- ## Claude Code vs Google Stitch
7
+ ## Khi nào dùng
8
+
9
+ Bạn đang cài, liên kết, hoặc nâng cấp hệ thống trong sản phẩm khác. Maintainer mở rộng hệ thống bắt đầu từ `docs/doctrine.md`.
10
+
11
+ ## Capability paths (DC-capable vs static)
8
12
 
9
13
  | Consumer | Bắt đầu tại | Hoạt động hôm nay | Không làm |
10
14
  |---|---|---|---|
@@ -17,11 +21,11 @@ Cách mọi project — do người hoặc agent điều khiển — áp dụng
17
21
 
18
22
  **Tín hiệu release:** đã LAUNCH ở **1.1.0**; **pin theo `VERSION`** (không CHANGELOG). Coi **git tip SHA** là chân lý kỹ thuật; đọc điểm nổi bật sản phẩm curated trong `docs/release-notes.md`.
19
23
 
20
- ## Đường nhanh cho AI agent (Claude Code, hoặc điều khiển một agent)
24
+ ## Đường nhanh cho AI agent (DC-capable authoring, hoặc điều khiển một agent)
21
25
 
22
26
  **Bạn nhận:** `styles.css` (400+ token + class `.cs-*` + bề mặt Liquid Glass, `@import` `tokens/` + `base/`) · `_ds_bundle.js` (React component đã compile, không cần build) · `_esm/react.mjs` (entry React bundler-native — React là peerDependency; mặc định `exports["."]`) · `_esm/cs.mjs` (browser / no-build legacy qua `exports["./legacy"]`) · `_ds_manifest.json` (inventory máy đọc được) · mỗi component `Name.d.ts` (API) + `Name.prompt.md` (brief dùng) · `tokens/tokens.dtcg.json` (W3C DTCG) + `tokens.json`/`tokens.js`.
23
27
 
24
- **Checkout repo** — clone hoặc copy cả cây; mọi thứ là static đường dẫn tương đối. Điểm vào: Storybook trên host site (`/` / `npm run storybook`) · `guidelines/atomic-view.html` (mọi component live, portable) · `templates/<slug>/` (điểm bắt đầu copy được — DC cho Claude Design; kitchen-sink / `.cs-*` cho Stitch). Đọc `SKILL.md` trước khi author bất kỳ thứ gì on-brand; reader Stitch bắt đầu tại `DESIGN.md`. Bản đồ sâu hơn ở `llms.txt` (inventory) và file này (hướng dẫn adopt + upgrade đầy đủ bên dưới).
28
+ **Checkout repo** — clone hoặc copy cả cây; mọi thứ là static đường dẫn tương đối. Điểm vào: Storybook trên host site (`/` / `npm run storybook`) · `guidelines/atomic-view.html` (mọi component live, portable) · `templates/<slug>/` (điểm bắt đầu copy được — DC khi có compiler; kitchen-sink / `.cs-*` cho Stitch / static). Đọc `SKILL.md` trước khi author bất kỳ thứ gì on-brand; reader Stitch bắt đầu tại `DESIGN.md`. Bản đồ sâu hơn ở `llms.txt` (inventory) và file này (hướng dẫn adopt + upgrade đầy đủ bên dưới).
25
29
 
26
30
  **Sau import — chứng minh health.** Mở `_audit/run.html`, để bảng gate chạy xong (mọi fast gate). Tất cả xanh = bản copy nhất quán nội bộ (contrast, docs, portability, tokens, consumer path, behavior, a11y, stories, bilingual parity). Chỉ full-clone — `_audit/` không nằm trong tarball npm.
27
31
 
@@ -34,7 +38,7 @@ Cách mọi project — do người hoặc agent điều khiển — áp dụng
34
38
 
35
39
  - Anchors (Umber/Ochre), tên class `.cs-*`, tên token `--cs-*` là hợp đồng ổn định.
36
40
 
37
- - Mở rộng hệ thống? Theo `CONTRIBUTING.md` (Expansion Rule: lan tới mọi deliverable trong một change; verify qua `_audit/`).
41
+ - Mở rộng hệ thống? Theo `docs/doctrine.md` và `CONTRIBUTING.md` (Expansion Rule: lan tới mọi deliverable trong một change; verify qua `_audit/`).
38
42
 
39
43
  ## Adopt qua npm (tùy chọn)
40
44
 
@@ -1,6 +1,8 @@
1
1
  # Báo cáo contrast — cặp elemental (APCA)
2
2
 
3
- Tạo · quét tại VERSION 1.3.8.
3
+ Tạo · quét tại VERSION 1.3.9.
4
+
5
+ Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
6
 
5
7
  **Doctrine của sweep này:** chữ ngồi trên `-bright` hoặc `-tint`, không bao giờ trên mid-tone `-accent`. Accent chỉ cho bar, border, progress, fill không chữ. (Rule trong `tokens/elements.css` và conventions.)
6
8
 
@@ -1,6 +1,6 @@
1
1
  # Conventions — authoring CyberSkill DS
2
2
 
3
- Cho người và agent *mở rộng hệ thống này*. (Consumer: đọc `SKILL.md`.) Compiler là nguồn chân lý cho đếm; prose mô tả hình dạng, không bao giờ số.
3
+ Cho người và agent *mở rộng hệ thống này*. (Consumer: đọc `SKILL.md`.) Học thuyết mở rộng và kiểm chứng: `docs/doctrine.md`. Compiler là nguồn chân lý cho đếm; prose mô tả hình dạng, không bao giờ số. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## Quy tắc expansion
6
6
 
@@ -1,6 +1,6 @@
1
1
  # Quyết định (maintainer)
2
2
 
3
- Các lựa chọn của owner định hình CI, đồng bộ Figma, và phân phối. How-to nằm ở `docs/figma.md` và `docs/ci-cd.md` — file này chỉ là biên bản quyết định. Không phải hướng dẫn consumer.
3
+ Các lựa chọn của owner định hình CI, đồng bộ Figma, và phân phối. How-to nằm ở `docs/figma.md` và `docs/ci-cd.md` — file này chỉ là biên bản quyết định. Không phải hướng dẫn consumer. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## 1. Whole-set audits trên mọi PR
6
6
 
package/docs/vi/deploy.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # Deploy site Atomic live (Vercel / VPS / mọi static host)
2
2
 
3
+ Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
+
3
5
  Hai track:
4
6
 
5
7
  1. **Design system portable (consumers)** — vẫn là cây file tĩnh: không cần bundler. Link `styles.css` + tùy chọn `_ds_bundle.js` / ESM. Claude Design, Google Stitch, và product app không cần Node hay Storybook.
@@ -67,7 +69,7 @@ server {
67
69
  ```
68
70
  Path portable vẫn là file thật (`guidelines/atomic-view.html`, `_audit/run.html`, `styles.css`, v.v.). Storybook sở hữu `/` và `/index.html`.
69
71
 
70
- **Netlify / Cloudflare Pages / tương tự:** file `_headers` ở root (và `public/_headers`) mirror cùng ba header cho host đọc `_headers` kiểu Netlify. Giữ khớp `vercel.json`.
72
+ **Netlify / Cloudflare Pages / tương tự:** file `_headers` ở root mirror cùng ba header cho host đọc `_headers` kiểu Netlify. Giữ khớp `vercel.json`.
71
73
 
72
74
  ## Checklist sau deploy
73
75
  1. Mở `/` — xác nhận Storybook load (không 404, directory listing, hay shell dashboard cũ).
@@ -1,6 +1,6 @@
1
1
  # Phong cách thiết kế
2
2
 
3
- Các trục styling sống là **Theme × Element × Language × Style**. Pack Style duy nhất hôm nay là **liquid-glass** (vắng `data-cs-style` ≡ liquid-glass — cùng pattern mặc định với light theme / Thổ middle).
3
+ Các trục styling sống là **Theme × Element × Language × Style**. Pack Style duy nhất hôm nay là **liquid-glass** (vắng `data-cs-style` ≡ liquid-glass — cùng pattern mặc định với light theme / Thổ middle). Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  | Trục | Cách đặt | Thay đổi gì |
6
6
  |---|---|---|
@@ -0,0 +1,51 @@
1
+ # Học thuyết
2
+
3
+ Quy tắc chuẩn cho việc mở rộng và kiểm chứng Hệ thống Thiết kế CyberSkill. File theo từng host (`CLAUDE.md`, `AGENTS.md`, `GEMINI.md`) chỉ là shim trỏ về đây. Người tiêu thụ bắt đầu từ `SKILL.md` và thanh bên **Docs** trên Storybook tại `design.cyberskill.world`. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
+
5
+ ## Khi nào dùng
6
+
7
+ - Bạn đang thêm hoặc đổi element, variant, icon, component, vai trò token, ngôn ngữ, hoặc mẫu template.
8
+ - Bạn đang kiểm chứng một thay đổi trước khi tuyên bố xong.
9
+ - Bạn cần các bất biến không được thiết kế lại tùy tiện.
10
+
11
+ ## Ngoài phạm vi
12
+
13
+ File này không phải changelog, không phải sổ đăng ký sản phẩm, và không phải hướng dẫn tiêu thụ. Ánh xạ sản phẩm → element nằm ở `docs/products.md`. Đường dẫn adoption nằm ở `docs/consuming.md`.
14
+
15
+ ## Quy tắc mở rộng
16
+
17
+ Khi **bất kỳ thứ gì** trong hệ thống này lớn lên, cập nhật **mọi deliverable trong cùng một thay đổi**:
18
+
19
+ 1. Token và nguồn (`tokens/`, component `.jsx` + `.d.ts` + `.prompt.md`).
20
+ 2. Thẻ mẫu (guidelines cộng thẻ nhóm component) **và mọi trang guideline liên quan**.
21
+ 3. **Tất cả** template (enum tweak, bản đồ EL/EX, accent đã quét).
22
+ 4. UI kit — trang kit trung thành Thổ; demo trục qua thanh công cụ Storybook và Atomic View (Identity Lab đã nghỉ).
23
+ 5. Docs: README (số đếm theo compiler), `SKILL.md`, file này, `docs/conventions.md`, **và mọi tài liệu liên quan mà thay đổi chạm tới** (README kit, `docs/products.md`, tái sinh `docs/contrast-report.md` sau khi đổi token). Xuất bản cùng các trang đó qua Storybook Docs (xem `docs/storybook.md`). **`VERSION` tự tăng khi đẩy lên `main`** từ Conventional Commits (`.github/workflows/version.yml` → tag `v*` → `npm-publish.yml`); chủ sở hữu vẫn có thể ép bump qua `Release-As:` / `workflow_dispatch`. **Không duy trì file changelog** — LAUNCHED tại **1.1.0**; pin theo `VERSION`. Tính liên tục là lịch sử git cộng Release Notes đã chọn lọc.
24
+ 6. Bề mặt duyệt và sức khỏe: component mới hoặc đổi được một story Atomic View trong `guidelines/atomic-view.html` (cộng playground sống nếu có prop chỉnh được — `_audit/story-coverage.html` bắt story) và phủ hành vi trong `_audit/component-behavior-test.html` nếu tương tác; mọi trục, công cụ, hoặc tab mới được nối vào `_audit/index.html` và Storybook **Status** (`_audit/run.html` full-bleed — `dashboard.html` chỉ redirect); gate xác định tương ứng được thêm hoặc cập nhật (`contrast-guard` cho quy tắc màu mới, `token-contract` cộng ma trận contrast cho token, `story-coverage` cho component, `docs-storybook-coverage` cho docs đã xuất bản).
25
+
26
+ **Gate:** `check_design_system` sạch (chỉ phiên compiler) **cộng** `_audit/run.html` (mọi gate nhanh) xanh **cộng** `docs-consistency` xanh **cộng** grep enum hoặc danh sách cũ để chứng minh không bỏ sót. Trên clone portable, tương đương là bảng nhanh cộng `npm run test:unit`.
27
+
28
+ Ranh giới phạm vi đã ghi (học thuyết, không phải lỗ hổng): trang UI-kit vẫn tái tạo trung thành Thổ; song ngữ EN·VN phủ email cộng tài liệu team, pháp lý, và tài chính (tài sản khách/truyền thông ưu tiên EN); chữ không bao giờ nằm trên `-accent` tông giữa.
29
+
30
+ ## Độ sâu kiểm chứng
31
+
32
+ Kiểm sâu, không điểm danh bề mặt. Phủ **cả tập và mọi trạng thái liên quan** — không lấy mẫu. Ưu tiên quét xác định, theo chương trình chạm **mọi** mục (ví dụ parity khóa EN/VI, phủ lỗ, và quét rò trên mọi template; probe computed-style và overflow ở mọi breakpoint qua harness `_audit/` dùng `__dcSetProps` cho ngôn ngữ và postMessage `__dc_theme` cho theme), rồi thêm xác nhận visual hoặc export đại diện. Vài ảnh chụp là bằng chứng, không phải chứng minh. Không tuyên bố đã kiểm vì “spot-check” khi kiểm đủ là khả thi; nếu kiểm đủ thật sự không khả thi, nói rõ và nêu cái đã và chưa phủ. Ngôn ngữ, theme, và trạng thái responsive mỗi cái một lượt — một ngôn ngữ, chiều rộng, hoặc theme render sạch không phải bằng chứng cho cái khác.
33
+
34
+ ## Bất biến
35
+
36
+ | Bất biến | Giá trị |
37
+ |---|---|
38
+ | Khẩu hiệu | *Turn Your Will Into Real* / *Hiện Thực Hoá Ý Chí* |
39
+ | Thương hiệu chính | Umber `#45210E` |
40
+ | Accent chính | Ochre `#F4BA17` |
41
+ | Giọng | ấm · thẳng · thật · tôn trọng (cả bốn cùng lúc) |
42
+ | Ngôn ngữ | Việt Nam trước; mọi chuỗi UI gửi cặp EN + VN |
43
+ | Sàn a11y | APCA Lc ≥ 75 chữ thân; không bao giờ gỡ focus ring; mục tiêu chạm ≥ 44px |
44
+ | Trục | Theme × Element × Language × Style (độc lập) |
45
+ | Gói Style | liquid-glass (gói duy nhất; vắng ≡ mặc định) |
46
+
47
+ Một accent mỗi bề mặt. Trạng thái ngữ nghĩa và chỉ báo focus tổ hợp (viền text-primary + hào quang ochre) không bao giờ elemental. Lumi luôn vàng trong mọi element.
48
+
49
+ ## Tài liệu đã xuất bản
50
+
51
+ Docs operator và entrance là markdown chuẩn trong kho. Chúng **cũng** bắt buộc trên site Storybook sống: mọi trang được theo dõi phải xuất hiện trên thanh bên Docs và trong Thư viện tài liệu (`docs/viewer.html`). Tài liệu chỉ có trong repo mà không nằm trong tập xuất bản đó là lỗi, bị `docs-storybook-coverage` và `docs-link-check` bắt.
package/docs/vi/figma.md CHANGED
@@ -1,5 +1,7 @@
1
1
  # Figma / Tokens Studio — ghi chú
2
2
 
3
+
4
+ Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
3
5
  ## Những gì ship trong repo
4
6
  - Design tokens dạng CSS + DTCG (`tokens/tokens.dtcg.json`) kèm mirror native Swift/Kotlin/Flutter.
5
7
  - UI kits dưới `ui_kits/` là tái tạo HTML giữ pixel-faithful theo doctrine brand (kit Thổ-first; demo trục ở Storybook / Atomic View).
@@ -1,5 +1,7 @@
1
1
  # Live hub = Storybook
2
2
 
3
+ Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
+
3
5
  ## Quyết định
4
6
 
5
7
  **Storybook là live interactive hub duy nhất** cho operator trên `design.cyberskill.world`. Không có trang Live View riêng và không còn shell dashboard HTML làm sản phẩm. Production **`/`** là Storybook.
@@ -8,7 +10,7 @@
8
10
 
9
11
  | Nhóm | Vai trò |
10
12
  |---|---|
11
- | **Docs** | Hướng dẫn MDX công khai (consuming, deploy, conventions, styles, products, schema, Figma, contrast, voice, axes) |
13
+ | **Docs** | Docs operator đã xuất bản: **Start** (Introduction, README, SKILL, Contributing, llms, Library) · **Guides** (consuming, grant, deploy, schema, conventions, styles, products, Figma, contrast, storybook, live-hub, runbook phát hành, benchmark, …) · **Maintainers** (học thuyết, decisions, CI/CD, quality gates, sync). MDX curated cộng một mục sidebar mỗi trang tracked. EN·VI qua Thư viện tài liệu (`/docs/viewer.html`) |
12
14
  | **Foundations** | Colors, typography, spacing, elevation, motion, elements |
13
15
  | **Components** | Thư viện CSF đầy đủ |
14
16
  | **Release Notes** | Prose sản phẩm curated (**không CHANGELOG.md**) |
@@ -1,6 +1,6 @@
1
1
  # Product registry — ánh xạ element
2
2
 
3
- > **Đã khóa / locked** (Th7 2026). Registry product → element chuẩn cho agent và kit. **Không** invent ánh xạ product → element mới; thêm hoặc đổi hàng chỉ qua quyết định maintainer trong `docs/decisions.md`.
3
+ > **Đã khóa / locked** (Th7 2026). Registry product → element chuẩn cho agent và kit. **Không** invent ánh xạ product → element mới; thêm hoặc đổi hàng chỉ qua quyết định maintainer trong `docs/decisions.md`. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  **Nguồn chân lý.** Ánh xạ sản phẩm portfolio CyberSkill sang pack element Ngũ Hành. Một element mỗi sản phẩm; accent phụ chỉ trong gradient wash theo Tương sinh.
6
6
 
@@ -1,10 +1,10 @@
1
1
  # Quality gates — tài liệu chuẩn benchmark
2
2
 
3
- Mọi quality gate deterministic trong hệ thống, nó assert gì, tiêu chí pass, hard hay advisory, và chạy ở đâu.
3
+ Mọi quality gate deterministic trong hệ thống, nó assert gì, tiêu chí pass, hard hay advisory, và chạy ở đâu. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  **Gate chạy ở đâu.** *Fast board CI* = job `fast-gates` trong `.github/workflows/design-system-gates.yml`, serve repo và điều khiển `_audit/run.html` headless qua `_audit/ci/run-gates.mjs` (mọi push/PR + nightly + thủ công) — hàng board mới được nhận tự động. Hai gate thêm chạy standalone như *merge blocker* (job `docs-consistency-blocker`, qua `_audit/ci/run-single-gate.mjs`). *Whole-set CI* = job `whole-set-audits` (mọi push/PR + nightly — quyết định B của owner). *Unit test* = `npm run test:unit` trong job `unit-tests` (Node thuần, không trình duyệt). *Node pre-checks* = job `node-prechecks` (authority không trình duyệt: bundle freshness, DESIGN.md freshness, styles.min.css + contrast-report freshness, manifest coverage) cộng job `token-provenance`. *Storybook CI* = job `storybook-build` (`build:storybook` + freshness `--require`). Mọi browser gate publish verdict global (`window.__*`) mà headless runner đọc.
6
6
 
7
- ## Fast board — 40 gates trong `_audit/run.html`
7
+ ## Fast board — 42 gates trong `_audit/run.html`
8
8
 
9
9
  Nguyên tắc benchmark (WCAG · APCA · OKLCH · DTCG · doctrine CDS + mở rộng style): [`docs/vi/benchmark-rubric.md`](benchmark-rubric.md).
10
10
 
@@ -16,6 +16,8 @@ Nguyên tắc benchmark (WCAG · APCA · OKLCH · DTCG · doctrine CDS + mở r
16
16
  | Docs consistency | `_audit/docs-consistency.html` | Mọi claim đếm trong README/SKILL/llms.txt khớp compiler manifest; claim số card trong prose audit (`_audit/index` / README / namespace-portability) khớp `manifest.cards`; `VERSION` semver và `package.json` khớp (LAUNCH 1.1.0; auto-bump trên main); không tham chiếu changelog-file; blacklist stale-phrase sạch trên README/SKILL/llms + `docs/*.md`; `DESIGN.md` stamp = `VERSION`; routing agent trung thực; doctrine↔source — 10 role accent (gồm `on-strong`), depth scale đủ, default lang `vi`, breakpoint CSS↔JSON, fallback depth trong `base/` | 0 claim lệch + doctrine parity (`__docs`) | Hard | Fast board CI + merge blocker |
17
17
  | Asset-weight budget | `_audit/asset-weight-budget.html` | WebP aurora elemental (`assets/aurora-{tho,hoa,thuy,moc,kim}.webp`) dưới trần hồi quy (≤300 KB/file, ≤1.2 MB cả bộ); PNG aurora legacy thì fail; CSS wash không được trỏ JPEG Thổ | Cả năm dưới trần (`__assetweight`) | Hard | Fast board CI (+ Node twin `test-docs-consistency.mjs`) |
18
18
  | Docs language parity | `_audit/docs-lang-parity.html` | Mọi EN `docs/*.md` hướng operator có counterpart `docs/vi/`; VI không phải stub trống/TODO (≥40% độ dài EN); blacklist stale-phrase sạch trên cả EN và VI (ghi chú lịch sử dưới `_audit/archive/` không được theo dõi) | 0 cặp thiếu, 0 stub, 0 blacklist hit (`__docslangparity`) | Hard | Fast board CI |
19
+ | Docs Storybook coverage | `_audit/docs-storybook-coverage.html` | HTML sống: catalog đã xuất bản + `/docs/**` + viewer + file entrance; title `index.json` Storybook khi có (không fetch `.storybook/` / `stories/` chưa xuất bản). Node twin: nguồn CSF/MDX + `staticDirs` | 0 trang / mục viewer thiếu (`__docssbcoverage`) | Hard | Fast board CI + unit twin |
20
+ | Docs link check | `_audit/docs-link-check.html` | HTML sống: markdown đã xuất bản + link viewer resolve; không path đã nghỉ. Node twin còn quét `href`/`src` MDX chưa xuất bản | 0 link trong-repo gãy (`__docslinkcheck`) | Hard | Fast board CI + unit twin |
19
21
  | DESIGN.md parity | `_audit/design-md-parity.html` | Root `DESIGN.md` (open-spec Stitch) byte-equals regeneration trong trình duyệt từ `tokens.dtcg.json` + `_ds_manifest.json` + `VERSION` qua `scripts/design-md-lib.mjs` dùng chung; từng hàng token được re-check riêng (số hàng in kèm verdict) | Byte-identical + 0 hàng drift (`__designmd`) | Hard | Fast board CI |
20
22
  | Version stamp | `_audit/version-stamp.html` | `package.json`, meta `tokens.json`/`tokens.js`, DTCG `$extensions`, `provenance.json` release + dtcgStamp, front matter `DESIGN.md`, và `_esm/cs.mjs` `export const VERSION` đều bằng `VERSION` (pin theo file; LAUNCH 1.1.0) | Cả 9 stamp bằng nhau (`__versionstamp`) | Hard | Fast board CI |
21
23
  | Namespace portability | `_audit/namespace-portability.html` | Không source index bởi manifest hardcode hậu tố bundle project-id của compiler | 0 hậu tố hardcode (`__nsguard`) | Hard | Fast board CI |
@@ -77,6 +79,8 @@ Nguyên tắc benchmark (WCAG · APCA · OKLCH · DTCG · doctrine CDS + mở r
77
79
  |---|---|---|---|---|---|
78
80
  | Nav model | `_audit/ci/test-nav-model.mjs` | Logic classify/group của `guidelines/nav-model.js` đã ship hành xử đúng (chạy module thật) | Mọi assert pass (exit 0) | Hard | Unit test |
79
81
  | Health/Tokens UI contract | `_audit/ci/test-health-tokens-contract.mjs` | Hợp đồng cấu trúc của entry HTML Health + Tokens giữ | Mọi assert pass (exit 0) | Hard | Unit test |
82
+ | Docs Storybook coverage (Node twin) | `_audit/ci/test-docs-storybook-coverage.mjs` | Docs tracked + entrance + doctrine mỗi cái có title story Storybook và path viewer; `staticDirs` gồm `docs/` | Exit 0 | Hard | Unit test |
83
+ | Docs link check (Node twin) | `_audit/ci/test-docs-link-check.mjs` | Link tương đối trong-repo của tập xuất bản bắt buộc resolve; path đã nghỉ không là href sống | Exit 0 | Hard | Unit test |
80
84
  | Form paths | `_audit/ci/test-form-paths.mjs` | Helper Form path hành xử đúng (chạy `Form.jsx` đã ship qua dynamic import) | Mọi assert pass (exit 0) | Hard | Unit test |
81
85
  | Storybook contract | `_audit/ci/test-storybook-contract.mjs` | Live hub chỉ là Storybook; SB10 ESM main + addon-docs/a11y; CSF đủ cho mọi public primary; Matrix/AllVariants + AllSizes khi có `argTypes.size`; States/Matrix phủ disabled/loading/error/busy; mọi enum size/variant rời rạc được mount; FullMatrix bắt buộc khi ≥1 trục trong {size, variant, state} tồn tại (≥28 primary đủ điều kiện) | Mọi assert pass (exit 0) | Hard | Unit test |
82
86
  | Axe coverage | `_audit/ci/test-axe-coverage.mjs` | `NAMES` fixture ≡ `listPublicComponents()`; axe-smoke nạp fixture khoá inventory | Mọi assert pass (exit 0) | Hard | Unit test |
@@ -1,6 +1,6 @@
1
1
  # Ghi chú phát hành
2
2
 
3
- Điểm nổi bật sản phẩm cho operator — **không** phải git log và **không** phải `CHANGELOG.md`. Hệ thống thiết kế không maintain file changelog. Phiên bản **đã LAUNCH ở 1.1.0**; **pin theo `VERSION`** (auto-bump khi push lên `main` từ Conventional Commits; owner vẫn có thể force bump). Chân lý kỹ thuật là tip repo; chân lý hướng sản phẩm là trang này (đồng bộ Storybook **Release Notes**).
3
+ Điểm nổi bật sản phẩm cho operator — **không** phải git log và **không** phải `CHANGELOG.md`. Hệ thống thiết kế không maintain file changelog. Phiên bản **đã LAUNCH ở 1.1.0**; **pin theo `VERSION`** (auto-bump khi push lên `main` từ Conventional Commits; owner vẫn có thể force bump). Chân lý kỹ thuật là tip repo; chân lý hướng sản phẩm là trang này (đồng bộ Storybook **Release Notes**). Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## Patch — `@cyberskill/design@1.1.1`
6
6
 
@@ -1,6 +1,6 @@
1
1
  # Runbook phát hành (chuẩn)
2
2
 
3
- Một trang về cách một bản phát hành diễn ra và cách biết nó đã thành công. Gộp các vùng 21/23. Chi tiết liên quan: `docs/ci-cd.md`, `docs/deploy.md`, `docs/decisions.md` §7 / §13.
3
+ Một trang về cách một bản phát hành diễn ra và cách biết nó đã thành công. Gộp các vùng 21/23. Chi tiết liên quan: `docs/ci-cd.md`, `docs/deploy.md`, `docs/decisions.md` §7 / §13. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## Kích hoạt
6
6
 
@@ -1,6 +1,6 @@
1
1
  # Storybook — bề mặt sản phẩm tại `/` (host)
2
2
 
3
- Storybook **10** là **site sản phẩm** cho operator trên `design.cyberskill.world` (`/`). Nó vẫn **không** thuộc hợp đồng consumer portable.
3
+ Storybook **10** là **site sản phẩm** cho operator trên `design.cyberskill.world` (`/`). Nó vẫn **không** thuộc hợp đồng consumer portable. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## URL
6
6
 
@@ -20,7 +20,7 @@ Storybook **10** là **site sản phẩm** cho operator trên `design.cyberskill
20
20
  - Mọi option enum `size` / `variant` rời rạc được mount trong story họ matrix
21
21
  - `FullMatrix` khi ≥1 trong {size enums, variant enums, state keys} tồn tại — tích size × variant × key-state qua helper chung `stories/lib/matrix.jsx`
22
22
  - Toolbar globals: Theme (light · dark · **system**) × Element × Language × Style (cùng trục với template / Atomic View). Element liệt kê **đủ 15** pack Ngũ Hành (`tokens.elements` / EL map template / Storybook toolbar) — không phải tập con. Pack Style duy nhất là **liquid-glass**.
23
- - **Docs/** hướng dẫn MDX công khai; **Release Notes/** prose sản phẩm curated (**không CHANGELOG.md**); **Status/** nhúng `_audit/run.html` full-bleed
23
+ - **Docs/** tài liệu operator đã xuất bản — lồng **Start / Guides / Maintainers**, MDX curated cho trang traffic cao, một story sidebar mỗi trang markdown tracked, và iframe Thư viện tài liệu `/docs/viewer.html` (EN·VI). Prose chuẩn vẫn là `docs/*.md`; Storybook là bề mặt đọc sống. **Release Notes/** prose sản phẩm curated (**không CHANGELOG.md**); **Status/** nhúng `_audit/run.html` full-bleed
24
24
  - Story **Maintainer/** cho bề mặt HTML portable (Motion, templates, kitchen-sink, AI cluster, RTL; Atomic View chôn cho gates)
25
25
  - Cùng `styles.css` như production
26
26
  - Addon: `@storybook/addon-docs` + `@storybook/addon-a11y` (essentials gộp vào core ở SB10)
@@ -40,7 +40,7 @@ Storybook **10** là **site sản phẩm** cho operator trên `design.cyberskill
40
40
  | ESM (bundler) | `_esm/react.mjs` (mặc định / `@cyberskill/design/react`) |
41
41
  | ESM (browser legacy) | `_esm/cs.mjs` (`@cyberskill/design/legacy`) |
42
42
  | Tokens | `tokens/*` |
43
- | Claude Design | `templates/**/*.dc.html` |
43
+ | DC-capable authoring | `templates/**/*.dc.html` |
44
44
 
45
45
  ## Lệnh
46
46
 
package/docs/vi/sync.md CHANGED
@@ -1,10 +1,10 @@
1
- # Repo ↔ Claude Design — round-trip fidelity & đồng bộ hai chiều
1
+ # Repo ↔ môi trường authoring — round-trip fidelity & đồng bộ hai chiều
2
2
 
3
- Repo GitHub (`cyberskill-official/design`) là **nguồn chân lý**. Session Claude Design là filesystem project tạm — tài liệu này nói cách chúng giữ sync mà không mất việc.
3
+ Repo GitHub (`cyberskill-official/design`) là **nguồn chân lý**. Session compiler (ví dụ Claude Design) là filesystem project tạm — tài liệu này nói cách chúng giữ sync mà không mất việc. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  ## Repo có khôi phục nguyên hệ thống không?
6
6
 
7
- **Trong session Claude Design — có.** Mọi thứ định nghĩa hệ thống là file text/asset thuần và round-trip lossless:
7
+ **Trong session compiler DC-capable — có.** Mọi thứ định nghĩa hệ thống là file text/asset thuần và round-trip lossless:
8
8
  - `styles.css` + `tokens/` + `base/` (mọi CSS + `tokens.json`/`tokens.js`)
9
9
  - `components/**` (`.jsx` + `.d.ts` + `.prompt.md` + `*.card.html`)
10
10
  - `templates/**/*.dc.html` (+ `ds-base.js`, `support.js`)
@@ -13,15 +13,15 @@ Repo GitHub (`cyberskill-official/design`) là **nguồn chân lý**. Session Cl
13
13
  - **`_esm/react.mjs`** — entry React bundler-native (export package mặc định; React peer). Regenerated qua `npm run build:react-entry`.
14
14
  - **`_esm/cs.mjs`** — entry ESM browser / no-build legacy (`@cyberskill/design/legacy`). Tiền tố underscore **không** nghĩa là build artifact hay gitignored ở đây (chỉ `uploads/`, `scraps/`, `_audit/exports/` là — xem Hygiene bên dưới); `_esm/` là source, cùng tầng với `templates/` hoặc `docs/`. Một lần port trước đã bỏ nó đúng vì giả định đó và làm gãy ESM smoke gate — nếu bạn port/copy cây này bằng tay, **explicit include mọi thư mục top-level danh sách này đặt tên**, đừng suy từ tiền tố `_`.
15
15
 
16
- - `README.md`, `CONTRIBUTING.md`, `SKILL.md`, `CLAUDE.md`, `VERSION`, `DESIGN.md` (open-spec surface generate — commit, chỉ regen qua `npm run build:design-md`, khóa bởi gate `design-md-parity`)
16
+ - `README.md`, `CONTRIBUTING.md`, `SKILL.md`, `docs/doctrine.md`, shim host (`CLAUDE.md`), `VERSION`, `DESIGN.md` (open-spec surface generate — commit, chỉ regen qua `npm run build:design-md`, khóa bởi gate `design-md-parity`)
17
17
 
18
- Kéo chúng vào project mới (xem bên dưới) và compiler nhận lại như design system — nó khóa vào `styles.css`, cặp `.d.ts`/`.jsx`, HTML `@dsCard`, và `templates/`. File **derived** (`_ds_bundle.js`, `_ds_manifest.json`, `_adherence.oxlintrc.json`) được regenerate mỗi turn từ source, nên không cần tin từ repo — chúng rebuild.
18
+ Kéo chúng vào project mới (xem bên dưới) và compiler nhận lại như design system — nó khóa vào `styles.css`, cặp `.d.ts`/`.jsx`, HTML `@dsCard`, và `templates/`. Artifact compile đã commit (`_ds_bundle.js`, `_ds_manifest.json`, `_adherence.oxlintrc.json`, `dist/styles.min.css`, `DESIGN.md`) là một phần hợp đồng consumer — giữ trong cây và regenerate bằng npm script đã ghi, đừng coi chúng là disposable.
19
19
 
20
- **Ở agent khác (Google Stitch, LLM tool generic) — một phần.** Chúng tiêu thụ được lớp **portable** — `tokens/tokens.json` + `tokens.js`, raw CSS, component `.jsx`, fonts, và Markdown docs — nhưng **không** hiểu format Design-Component `.dc.html` hay compiler điều khiển nó. Vậy agent non-Claude-Design nhận tokens, styles, và source component như file, không phải hành vi DC/tweak/compile live. Hướng những tool đó vào root **`DESIGN.md`** trước (open-spec kiểu Stitch generate: doctrine + mọi giá trị token + inventory, regen từ DTCG qua `npm run build:design-md` và khóa bởi gate `design-md-parity`), rồi `tokens.json` / `tokens.dtcg.json` và CSS cho hợp đồng máy; coi `.dc.html` + compiler là native Claude Design.
20
+ **Ở agent khác (Google Stitch, LLM tool generic) — một phần.** Chúng tiêu thụ được lớp **portable** — `tokens/tokens.json` + `tokens.js`, raw CSS, component `.jsx`, fonts, và Markdown docs — nhưng **không** hiểu format Design-Component `.dc.html` hay compiler điều khiển nó. Vậy agent không-compiler nhận tokens, styles, và source component như file, không phải hành vi DC/tweak/compile live. Hướng những tool đó vào root **`DESIGN.md`** trước (open-spec kiểu Stitch generate: doctrine + mọi giá trị token + inventory, regen từ DTCG qua `npm run build:design-md` và khóa bởi gate `design-md-parity`), rồi `tokens.json` / `tokens.dtcg.json` và CSS cho hợp đồng máy; coi `.dc.html` + compiler là native DC.
21
21
 
22
22
  ## Đồng bộ hai chiều (repo = nguồn chân lý)
23
23
 
24
- Claude Design có thể **đọc/copy từ** GitHub nhưng **không push tới** nó. Vậy sync là *pull tự động, push thủ công*:
24
+ Session compiler có thể **đọc/copy từ** GitHub nhưng thường **không push tới** nó. Vậy sync là *pull tự động, push thủ công*:
25
25
  **Bắt đầu session — pull (tin cậy, tự động):** bảo agent load repo. Nó copy cây vào project mới (đường `github_copy_files`), compiler validate, và bạn tiếp từ chân lý đã commit — không bao giờ từ project state cũ. Luôn bắt đầu đây; đừng resume từ project nửa nhớ.
26
26
 
27
27
  **Kết thúc session — push (thủ công, review):** tải project, rồi từ clone:
@@ -1,6 +1,6 @@
1
1
  # Template content-schema v2 — content slot có kiểu
2
2
 
3
- Metadata thuần additive, opt-in: sidecar `templates/<slug>/content-schema.json` cạnh `.dc.html` của template, khai báo **kiểu** của mỗi `{{ hole }}` đã có trong template — để agent hoặc pipeline điền/validate nội dung khách thật theo chương trình mà không parse HTML hay đoán.
3
+ Metadata thuần additive, opt-in: sidecar `templates/<slug>/content-schema.json` cạnh `.dc.html` của template, khai báo **kiểu** của mỗi `{{ hole }}` đã có trong template — để agent hoặc pipeline điền/validate nội dung khách thật theo chương trình mà không parse HTML hay đoán. Xuất bản trên Storybook **Docs** tại `design.cyberskill.world`.
4
4
 
5
5
  **Không cần đổi markup template.** `id` của slot là tên hole đã dùng trong `.dc.html` (ví dụ `{{ heroH }}`) và đã bind trong `renderVals()` của logic class — schema chỉ mô tả nó.
6
6
 
package/docs/viewer.html CHANGED
@@ -43,12 +43,23 @@
43
43
  article hr{border:0;border-top:1px dashed var(--cs-color-border-default);margin:20px 0}
44
44
  article a{color:var(--cs-color-link)}article a:hover{color:var(--cs-color-link-hover)}
45
45
  #err{color:#B42318;font-family:var(--cs-font-family-mono);font-size:13px}
46
+ html.embed body{grid-template-columns:1fr}
47
+ html.embed aside{display:none}
48
+ html.embed main{padding:24px 32px}
46
49
  @media (max-width:640px){
47
50
  body{grid-template-columns:1fr}
48
51
  aside{border-inline-end:0;border-block-end:1px solid var(--cs-color-border-default);max-height:38vh}
49
52
  main{padding:18px 16px}
53
+ html.embed main{padding:18px 16px}
50
54
  }
51
- </style></head>
55
+ </style>
56
+ <script>
57
+ (function(){
58
+ var q=new URLSearchParams(location.search);
59
+ if(q.get('embed')==='1'||q.get('chrome')==='0') document.documentElement.classList.add('embed');
60
+ })();
61
+ </script>
62
+ </head>
52
63
  <body>
53
64
  <aside id="nav"><h1>CyberSkill Docs</h1>
54
65
  <div class="langtog" role="group" aria-label="Doc language"><button type="button" id="lang-en" data-lang="en">EN</button><button type="button" id="lang-vi" data-lang="vi">VI</button></div>
@@ -58,13 +69,13 @@
58
69
  <script>
59
70
  const DOCS_EN=[
60
71
  ['Start',[['README.md','README'],['SKILL.md','SKILL (agent rules)'],['llms.txt','llms.txt'],['CONTRIBUTING.md','Contributing']]],
61
- ['Guides',[['docs/consuming.md','Consuming & upgrading (incl. AI-agent quick path)'],['docs/consumer-grant.md','Consumer grant (npm · UNLICENSED)'],['docs/deploy.md','Deploy (Vercel/VPS)'],['docs/template-schema-v2.md','Template content-schema v2'],['docs/conventions.md','Conventions'],['docs/release-notes.md','Release Notes'],['docs/release-runbook.md','Release runbook'],['docs/storybook.md','Storybook (product at /)'],['docs/live-hub.md','Live hub (Storybook at /)'],['docs/design-styles.md','Design styles'],['docs/benchmark-rubric.md','Benchmark rubric'],['docs/products.md','Products'],['docs/contrast-report.md','Contrast report'],['docs/figma.md','Figma']]],
62
- ['Maintainers',[['docs/decisions.md','Decisions'],['docs/ci-cd.md','CI/CD automation'],['docs/quality-gates.md','Quality gates'],['docs/sync.md','Git sync & hygiene']]]
72
+ ['Guides',[['docs/consuming.md','Consuming & upgrading'],['docs/consumer-grant.md','Consumer grant (npm · UNLICENSED)'],['docs/deploy.md','Deploy (Vercel/VPS)'],['docs/template-schema-v2.md','Template content-schema v2'],['docs/conventions.md','Conventions'],['docs/release-notes.md','Release Notes'],['docs/release-runbook.md','Release runbook'],['docs/storybook.md','Storybook (product at /)'],['docs/live-hub.md','Live hub (Storybook at /)'],['docs/design-styles.md','Design styles'],['docs/benchmark-rubric.md','Benchmark rubric'],['docs/products.md','Products'],['docs/contrast-report.md','Contrast report'],['docs/figma.md','Figma']]],
73
+ ['Maintainers',[['docs/doctrine.md','Doctrine'],['docs/decisions.md','Decisions'],['docs/ci-cd.md','CI/CD automation'],['docs/quality-gates.md','Quality gates'],['docs/sync.md','Git sync & hygiene']]]
63
74
  ];
64
75
  const DOCS_VI=[
65
76
  ['Bắt đầu',[['README.md','README (EN)'],['SKILL.md','SKILL (EN)'],['llms.txt','llms.txt (EN)'],['CONTRIBUTING.md','Contributing (EN)']]],
66
77
  ['Hướng dẫn',[['docs/consuming.md','Tiêu thụ & nâng cấp'],['docs/consumer-grant.md','Grant consumer (npm · UNLICENSED)'],['docs/deploy.md','Deploy (Vercel/VPS)'],['docs/template-schema-v2.md','Template schema v2'],['docs/conventions.md','Conventions'],['docs/release-notes.md','Ghi chú phát hành'],['docs/release-runbook.md','Runbook phát hành'],['docs/storybook.md','Storybook (sản phẩm tại /)'],['docs/live-hub.md','Live hub (Storybook tại /)'],['docs/design-styles.md','Phong cách'],['docs/benchmark-rubric.md','Rubric benchmark'],['docs/products.md','Sản phẩm'],['docs/contrast-report.md','Báo cáo contrast'],['docs/figma.md','Figma']]],
67
- ['Maintainer',[['docs/decisions.md','Quyết định'],['docs/ci-cd.md','CI/CD'],['docs/quality-gates.md','Quality gates'],['docs/sync.md','Đồng bộ Git']]]
78
+ ['Maintainer',[['docs/doctrine.md','Học thuyết'],['docs/decisions.md','Quyết định'],['docs/ci-cd.md','CI/CD'],['docs/quality-gates.md','Quality gates'],['docs/sync.md','Đồng bộ Git']]]
68
79
  ];
69
80
  let lang=(localStorage.getItem('cs-docs-lang')==='vi')?'vi':'en';
70
81
  function DOCS(){ return lang==='vi'?DOCS_VI:DOCS_EN; }