@nadicodeai/design-system 1.1.1 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +12 -5
- package/CONTEXT.md +16 -49
- package/DESIGN.md +507 -153
- package/LICENSES/shadow-plugin-MIT.txt +21 -0
- package/README.md +30 -1
- package/dist/css/index.css +134 -75
- package/dist/tailwind/nadicode.tailwind.json +9 -55
- package/dist/tokens/nadicode.dtcg-resolved.json +5092 -0
- package/dist/tokens/nadicode.dtcg.json +4602 -2169
- package/package.json +5 -1
package/AGENTS.md
CHANGED
|
@@ -4,7 +4,13 @@ The `@nadicodeai/design-system` npm workspace. `DESIGN.md` is the normative cont
|
|
|
4
4
|
|
|
5
5
|
## Commands
|
|
6
6
|
|
|
7
|
-
Proof
|
|
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.
|
|
8
14
|
|
|
9
15
|
| Command | When |
|
|
10
16
|
| --- | --- |
|
|
@@ -20,13 +26,14 @@ Proof escalates by the ladder in the root `AGENTS.md` "Commands": `npm run check
|
|
|
20
26
|
| Shared design-language terms | `CONTEXT.md` |
|
|
21
27
|
| Colors, tokens, typography, layout doctrine, seam ownership, component semantics | `DESIGN.md` (read it before stating any of these) |
|
|
22
28
|
| CSS layers, token pipeline, dark remaps, generated outputs, their guards | `DESIGN.md` "CSS Architecture & Token Pipeline". Decision history in `../../docs/adr/` |
|
|
23
|
-
|
|
|
29
|
+
| Where a token is authored, and what the build publishes | The YAML front matter for the four schema groups, the one `json design-tokens` fence for everything the schema has no group for (`DESIGN.md` "Authored token extension"). `scripts/sd/design-tokens-fence.ts` reads the fence and `scripts/sd/compose-token-graph.ts` merges it with the CLI export into `dist/tokens/nadicode.dtcg.json` (aliases preserved) and `dist/tokens/nadicode.dtcg-resolved.json` (aliases replaced by values) |
|
|
30
|
+
| Motion direction and runtime | `DESIGN.md` "Motion" for the direction and `core.motion` of the fence for the durations and easings, `src/css/motion.css` for the keyframes, the classes, and reduced motion, then the `product-design` skill for agent procedure |
|
|
24
31
|
| Package exports | `package.json` (guard: `../../scripts/check-export-targets.mjs`, run by the root `build` script, so root `npm run check` and the post-merge suite, never the workspace `check` or the required gate) |
|
|
25
32
|
| Static or non-React consumption | `README.md` |
|
|
26
33
|
| React consumption | `../ui/docs/consuming-cross-repo.md` |
|
|
27
34
|
| Logo hierarchy, usage, geometry, and asset delivery | `DESIGN.md` "Brand media authority". Static package routes in `README.md`. Implementation routes through `src/assets/`. `dist/` is generated, never hand-edited |
|
|
28
35
|
| `examples/` specimen work | `examples/` plus the `write-clearly` skill for specimen copy (guard: `tests/guards/examples-package-coherence.test.ts`) |
|
|
29
|
-
| Releasing a change to package-consumed output | `../../docs/agents/
|
|
36
|
+
| Releasing a change to package-consumed output | `../../docs/agents/publish.md` |
|
|
30
37
|
| Visual test implementation | `playwright.visual.config.ts` and `tests/visual/` |
|
|
31
38
|
|
|
32
39
|
## Boundaries
|
|
@@ -35,9 +42,9 @@ Proof escalates by the ladder in the root `AGENTS.md` "Commands": `npm run check
|
|
|
35
42
|
- Token-only CSS: no raw color or radius literal in hand-authored `src/css/` or `examples/`, fallback-encoded or not. A new value enters `DESIGN.md` first (colors and the examples scan: `tests/guards/consumer-css-discipline.test.ts`; kit radius: `tests/guards/kernel-css-architecture.test.ts`).
|
|
36
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").
|
|
37
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.
|
|
38
|
-
- `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 YAML, 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").
|
|
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").
|
|
39
46
|
- Seams and grids are computed, single-owner, never eyeballed (doctrine home: `DESIGN.md` "## Layout" and "Seam Ownership").
|
|
40
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.
|
|
41
48
|
- Name everything as NadicodeAI-owned primitives. A source brand never appears in a name, a comment, a contract, or any living design document.
|
|
42
|
-
- 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/
|
|
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`).
|
|
43
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.
|
package/CONTEXT.md
CHANGED
|
@@ -1,79 +1,46 @@
|
|
|
1
1
|
# Design Language
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
The shared vocabulary for NadicodeAI's reusable visual decisions and interface structures.
|
|
4
4
|
|
|
5
5
|
## Language
|
|
6
6
|
|
|
7
7
|
### Foundations
|
|
8
8
|
|
|
9
|
-
**
|
|
10
|
-
The
|
|
9
|
+
**Foundation**:
|
|
10
|
+
The visual values shared by every NadicodeAI product, including colour roles, typography, spacing, shape, material, elevation, motion, icons, and brand assets.
|
|
11
|
+
_Avoid_: Palette, base theme
|
|
11
12
|
|
|
12
|
-
**
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
**Scale step**:
|
|
16
|
-
One numbered value in a functional color scale whose number carries the same interaction or contrast role across every scale.
|
|
17
|
-
_Avoid_: Shade, tint
|
|
13
|
+
**Register**:
|
|
14
|
+
One product's visual rules for applying the Foundation. NadicodeAI has three Registers: website, Portal, and Nadia desktop.
|
|
15
|
+
_Avoid_: Theme, skin
|
|
18
16
|
|
|
19
17
|
**Brand tier**:
|
|
20
|
-
The
|
|
18
|
+
The Campo fields used for brand identity, imagery, and large surface grounds.
|
|
21
19
|
|
|
22
20
|
**Functional tier**:
|
|
23
|
-
The
|
|
21
|
+
The semantic colour roles and chart colours used for interface state and data.
|
|
24
22
|
|
|
25
23
|
**Campo**:
|
|
26
|
-
A named, full-strength brand
|
|
24
|
+
A named, full-strength brand colour field.
|
|
27
25
|
_Avoid_: Swatch, theme color
|
|
28
26
|
|
|
29
|
-
**One campo per room**:
|
|
30
|
-
The composition rule that one section or image field owns one campo, with adjacent fields separated by a clear luminance change.
|
|
31
|
-
|
|
32
|
-
**Luminance jump**:
|
|
33
|
-
The perceptual brightness difference that makes the edge between adjacent campi, or between a campo and its text, read clearly.
|
|
34
|
-
|
|
35
27
|
### Structure and surfaces
|
|
36
28
|
|
|
37
29
|
**Page grammar**:
|
|
38
|
-
The shared structural
|
|
30
|
+
The shared structural vocabulary of frames, rows, lanes, fills, seams, markers, grids, and stages.
|
|
39
31
|
|
|
40
32
|
**Seam**:
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
**CSS primitive**:
|
|
44
|
-
A low-level, framework-agnostic CSS helper for geometry, type, seams, fills, or structural behavior. It carries no product-specific meaning.
|
|
45
|
-
|
|
46
|
-
**CSS component**:
|
|
47
|
-
A framework-agnostic visual component that remains useful on both static and interactive surfaces without owning an app feature.
|
|
33
|
+
The visible structural line where parts of the Page grammar meet.
|
|
48
34
|
|
|
49
35
|
**Status vocabulary**:
|
|
50
|
-
The
|
|
36
|
+
The shared five-tone visual language for product status. Each product owns its status families, values, and mapping to those tones.
|
|
51
37
|
|
|
52
38
|
**Content surface**:
|
|
53
|
-
A visual family for presenting a
|
|
39
|
+
A visual family for presenting a specific kind of content inside the Page grammar.
|
|
54
40
|
|
|
55
41
|
**Agentic work surface**:
|
|
56
|
-
A
|
|
42
|
+
A visual family outside the conversation renderer for work output and workflow state, such as memory, run progress, identity, and handoffs.
|
|
57
43
|
|
|
58
44
|
**Agent visual**:
|
|
59
|
-
The decorative metaball identity assigned
|
|
60
|
-
type. It identifies the Agent across products without carrying status, runtime
|
|
61
|
-
activity, capability, or work output.
|
|
45
|
+
The decorative metaball identity assigned to an Agent type across products.
|
|
62
46
|
_Avoid_: Agent glyph, Agent avatar
|
|
63
|
-
|
|
64
|
-
**App-owned product feature**:
|
|
65
|
-
A product-specific route, screen, use case, or behavior owned by the consuming app rather than by the reusable design or UI packages.
|
|
66
|
-
|
|
67
|
-
### React composition
|
|
68
|
-
|
|
69
|
-
**React adapter**:
|
|
70
|
-
A thin typed React interface over approved design-system CSS grammar or assets. It exposes the shared implementation without taking ownership of it.
|
|
71
|
-
|
|
72
|
-
**Reusable composition**:
|
|
73
|
-
A React component that combines shared grammar, primitives, slots, variants, and responsive behavior into a repeatable product or marketing pattern.
|
|
74
|
-
|
|
75
|
-
**Reusable section**:
|
|
76
|
-
A reusable composition for one recurring content role, such as an introduction, proof area, media block, or call to action.
|
|
77
|
-
|
|
78
|
-
**Specimen**:
|
|
79
|
-
A runnable example that assembles shipped pieces for inspection without inventing new design rules.
|