@nadicodeai/design-system 4.0.0 → 4.0.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.
- package/AGENTS.md +24 -39
- package/package.json +1 -1
package/AGENTS.md
CHANGED
|
@@ -1,50 +1,35 @@
|
|
|
1
1
|
# @nadicodeai/design-system
|
|
2
2
|
|
|
3
|
-
The `@nadicodeai/design-system` npm workspace
|
|
3
|
+
The `@nadicodeai/design-system` npm workspace: `DESIGN.md` is the contract, the package ships tokens, CSS and assets, and `examples/` specimens prove them. React components ship from `@nadicodeai/ui`.
|
|
4
4
|
|
|
5
5
|
## Commands
|
|
6
6
|
|
|
7
|
-
Proof follows [the repository pipeline](../../docs/agents/develop.md#the-pipeline):
|
|
8
|
-
`npm run check -w @nadicodeai/design-system` and
|
|
9
|
-
`npm run test -w @nadicodeai/design-system` before pushing. `check` carries the
|
|
10
|
-
`DESIGN.md` contract lint, so a contract edit needs no separate command. This
|
|
11
|
-
workspace has no app to boot: it ships a package, and `examples/` specimens are
|
|
12
|
-
static HTML pages served from the repo root by
|
|
13
|
-
`../../scripts/lib/static-design-server.ts`, which `npm run test:visual` starts.
|
|
14
|
-
|
|
15
7
|
| Command | When |
|
|
16
8
|
| --- | --- |
|
|
17
|
-
| `npm run
|
|
18
|
-
| `npm run
|
|
19
|
-
| `npm run generate:
|
|
20
|
-
| `npm run
|
|
9
|
+
| `npm run check -w @nadicodeai/design-system` then `npm run test -w @nadicodeai/design-system` | Before pushing; `check` includes the `DESIGN.md` lint |
|
|
10
|
+
| `npm run build -w @nadicodeai/design-system` | After a `DESIGN.md` edit; regenerates `dist/` except `dist/favicon/` |
|
|
11
|
+
| `npm run generate:icons -w @nadicodeai/design-system` | After bumping `lucide-static` |
|
|
12
|
+
| `npm run generate:favicons -w @nadicodeai/design-system` | After a favicon source change |
|
|
13
|
+
| `npm run test:visual -w @nadicodeai/design-system` | Rendered CSS checks |
|
|
21
14
|
|
|
22
15
|
## Routing
|
|
23
16
|
|
|
24
|
-
|
|
|
17
|
+
| Topic | Path |
|
|
25
18
|
| --- | --- |
|
|
26
|
-
|
|
|
27
|
-
| Colors, tokens, typography, layout
|
|
28
|
-
| CSS layers, token pipeline, dark remaps, generated outputs
|
|
29
|
-
| Where a token is authored
|
|
30
|
-
| Motion
|
|
31
|
-
| Package exports | `package.json
|
|
32
|
-
| Static
|
|
33
|
-
|
|
|
34
|
-
|
|
|
35
|
-
|
|
|
36
|
-
| Releasing
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
-
|
|
42
|
-
-
|
|
43
|
-
- Emitted-but-unreferenced contract tokens are intentional. Runtime aliases and compatibility variables are different: each must have a live caller or be removed (`DESIGN.md` "CSS Architecture & Token Pipeline").
|
|
44
|
-
- `DESIGN.md` `## Components` is the semantic component catalog. CSS is its implementation, and `tests/guards/component-contract-matches-css.test.ts` derives the two-way fence without a copied inventory.
|
|
45
|
-
- `DESIGN.md` stays contract-only and spec-shaped: check `npm exec --package=@google/design.md -- design.md spec` before changing YAML fields. Exact reusable values go in the YAML front matter where the schema has a group for them and in the one `json design-tokens` fence where it does not, application guidance in prose. Add a non-spec YAML field only when repo code or a test reads it (spec-shape don'ts: `DESIGN.md` "Do's and Don'ts").
|
|
46
|
-
- Seams and grids are computed, single-owner, never eyeballed (doctrine home: `DESIGN.md` "## Layout" and "Seam Ownership").
|
|
47
|
-
- Authoring is contract-first: a visual behavior comes from `DESIGN.md`, from our own shipped surfaces, or from an explicit user approval, never from another product's rendered output. Screenshots verify, they never author. Ask when the contract leaves a decision open, and stop and re-read `DESIGN.md` before a second visual patch to the same component.
|
|
48
|
-
- Name everything as NadicodeAI-owned primitives. A source brand never appears in a name, a comment, a contract, or any living design document.
|
|
49
|
-
- Any change to package-consumed output ends with an explicit release decision, a version bump or a `[no-publish]` commit marker (enforced by the pre-push release gate, procedure: `../../docs/agents/publish.md`).
|
|
50
|
-
- The deleted `design-canvas/` prototypes and static chat/autoplay surface live only in git history. `src/css/motion.css` owns shared runtime motion primitives. Never reconstruct the prototypes or add a runtime JS surface.
|
|
19
|
+
| Design-language terms | `CONTEXT.md` |
|
|
20
|
+
| Colors, tokens, typography, layout, seams, components | `DESIGN.md` |
|
|
21
|
+
| CSS layers, token pipeline, dark remaps, generated outputs | [CSS Architecture & Token Pipeline](DESIGN.md#css-architecture--token-pipeline); decisions in `../../docs/adr/` |
|
|
22
|
+
| Where a token is authored | the `DESIGN.md` front matter and its `json design-tokens` fence, built by `scripts/sd/design-tokens-fence.ts` and `scripts/sd/compose-token-graph.ts` |
|
|
23
|
+
| Motion | [Motion](DESIGN.md#motion), `src/css/motion.css`, then `product-design` |
|
|
24
|
+
| Package exports | `package.json`; guard `../../scripts/check-export-targets.mjs` |
|
|
25
|
+
| Static consumption | `README.md`. React: `../ui/docs/consuming-cross-repo.md` |
|
|
26
|
+
| Logo forms and asset delivery | [Brand media authority](DESIGN.md#brand-media-authority); sources in `src/assets/` |
|
|
27
|
+
| `examples/` specimens | `examples/`; copy through `write-clearly` |
|
|
28
|
+
| Visual tests | `playwright.visual.config.ts`, `tests/visual/` |
|
|
29
|
+
| Releasing | `../../docs/agents/publish.md` |
|
|
30
|
+
|
|
31
|
+
## Rules
|
|
32
|
+
|
|
33
|
+
- Never edit `dist/**` or `src/css/*.generated.css` by hand; `npm run build` regenerates them from `DESIGN.md`.
|
|
34
|
+
- Authoring is contract-first: a visual behavior comes from `DESIGN.md`, a shipped surface, or an explicit approval; screenshots verify, never author.
|
|
35
|
+
- Name everything as a NadicodeAI-owned primitive; no source brand in a name, comment, or contract.
|