@nadicodeai/design-system 0.10.2 → 0.11.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 +30 -101
- package/CONTEXT.md +75 -0
- package/DESIGN.md +180 -345
- package/README.md +27 -54
- package/dist/assets/logo-mark.svg +6 -0
- package/dist/assets/logo-wordmark.svg +4 -0
- package/dist/assets/nadia-canonical-face.png +0 -0
- package/dist/css/chat-autoplay.js +18 -27
- package/dist/css/index.css +2540 -56
- package/dist/favicon/apple-touch-icon.png +0 -0
- package/dist/favicon/favicon.ico +0 -0
- package/dist/favicon/favicon.svg +6 -16
- package/dist/favicon/icon-192.png +0 -0
- package/dist/favicon/icon-512.png +0 -0
- package/dist/favicon/site.webmanifest +2 -2
- package/dist/tailwind/nadicode.tailwind.json +98 -143
- package/dist/tokens/nadicode.dtcg.json +413 -908
- package/package.json +19 -11
- package/src/assets/logo-geometry.d.ts +27 -0
- package/src/assets/logo-geometry.js +204 -0
- package/src/assets/nadia-canonical-face.d.ts +2 -0
- package/dist/css/components/.gitkeep +0 -0
- package/dist/css/components/agent-avatar.css +0 -52
- package/dist/css/components/approval-gate.css +0 -145
- package/dist/css/components/artifact-preview.css +0 -81
- package/dist/css/components/chat-bubble-agent.css +0 -63
- package/dist/css/components/chat-bubble-user.css +0 -28
- package/dist/css/components/chat-thread.css +0 -159
- package/dist/css/components/handoff-banner.css +0 -37
- package/dist/css/components/image.css +0 -87
- package/dist/css/components/memory-item.css +0 -36
- package/dist/css/components/run-timeline.css +0 -160
- package/dist/css/components/state-row.css +0 -64
- package/dist/css/components/state-tag.css +0 -67
- package/dist/css/components/status-tag.css +0 -101
- package/dist/css/components/tool-call-trace.css +0 -36
- package/dist/css/components/typing-dots.css +0 -54
- package/dist/css/components/usage-meter.css +0 -63
- package/dist/css/foundation.css +0 -177
- package/dist/css/layout.css +0 -657
- package/dist/css/motion.css +0 -225
- package/dist/css/primitives.css +0 -333
- package/dist/css/reset.css +0 -22
- package/dist/css/tokens.generated.css +0 -349
- package/dist/css/tokens.local.css +0 -11
- package/dist/tailwind/nadicode.theme.css +0 -596
- package/src/assets/favicon.svg +0 -17
- package/src/assets/logo-mark.svg +0 -15
- package/src/assets/logo-wordmark.svg +0 -26
- package/src/assets/nadia.d.ts +0 -9
- package/src/assets/nadia.png +0 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nadicodeai/design-system",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -11,31 +11,38 @@
|
|
|
11
11
|
"./agent": "./AGENTS.md",
|
|
12
12
|
"./tokens/dtcg": "./dist/tokens/nadicode.dtcg.json",
|
|
13
13
|
"./tailwind": "./dist/tailwind/nadicode.tailwind.json",
|
|
14
|
-
"./tailwind/theme.css": "./dist/tailwind/nadicode.theme.css",
|
|
15
14
|
"./css": "./dist/css/index.css",
|
|
16
|
-
"./css
|
|
15
|
+
"./css/chat-autoplay.js": "./dist/css/chat-autoplay.js",
|
|
17
16
|
"./icons/*": "./dist/icons/*",
|
|
18
17
|
"./favicon/*": "./dist/favicon/*",
|
|
19
18
|
"./assets/logo-mark": {
|
|
20
19
|
"types": "./src/assets/logo-mark.d.ts",
|
|
21
|
-
"default": "./
|
|
20
|
+
"default": "./dist/assets/logo-mark.svg"
|
|
22
21
|
},
|
|
23
22
|
"./assets/logo-wordmark": {
|
|
24
23
|
"types": "./src/assets/logo-wordmark.d.ts",
|
|
25
|
-
"default": "./
|
|
24
|
+
"default": "./dist/assets/logo-wordmark.svg"
|
|
26
25
|
},
|
|
27
|
-
"./assets/
|
|
28
|
-
"types": "./src/assets/
|
|
29
|
-
"
|
|
26
|
+
"./assets/logo-geometry": {
|
|
27
|
+
"types": "./src/assets/logo-geometry.d.ts",
|
|
28
|
+
"import": "./src/assets/logo-geometry.js",
|
|
29
|
+
"default": "./src/assets/logo-geometry.js"
|
|
30
|
+
},
|
|
31
|
+
"./assets/nadia-canonical-face": {
|
|
32
|
+
"types": "./src/assets/nadia-canonical-face.d.ts",
|
|
33
|
+
"default": "./dist/assets/nadia-canonical-face.png"
|
|
30
34
|
},
|
|
31
35
|
"./assets/fonts/geist.css": "./src/assets/fonts/geist.css",
|
|
32
36
|
"./assets/fonts/*": "./src/assets/fonts/*"
|
|
33
37
|
},
|
|
34
38
|
"files": [
|
|
35
39
|
"AGENTS.md",
|
|
40
|
+
"CONTEXT.md",
|
|
36
41
|
"README.md",
|
|
37
42
|
"DESIGN.md",
|
|
38
|
-
"src/assets",
|
|
43
|
+
"src/assets/*.d.ts",
|
|
44
|
+
"src/assets/logo-geometry.js",
|
|
45
|
+
"src/assets/fonts",
|
|
39
46
|
"dist"
|
|
40
47
|
],
|
|
41
48
|
"engines": {
|
|
@@ -48,13 +55,14 @@
|
|
|
48
55
|
"lint:design": "design.md lint DESIGN.md",
|
|
49
56
|
"lint": "eslint --max-warnings=0",
|
|
50
57
|
"test": "vitest run",
|
|
51
|
-
"test:visual": "
|
|
58
|
+
"test:visual": "playwright test --config playwright.visual.config.ts",
|
|
52
59
|
"prepublishOnly": "npm run build"
|
|
53
60
|
},
|
|
54
61
|
"devDependencies": {
|
|
55
62
|
"@google/design.md": "0.1.1",
|
|
56
63
|
"@types/node": "^22",
|
|
57
|
-
"
|
|
64
|
+
"@playwright/test": "^1.57.0",
|
|
65
|
+
"esbuild": "^0.28.0",
|
|
58
66
|
"eslint": "^9.39.4",
|
|
59
67
|
"lucide-static": "^1.17.0",
|
|
60
68
|
"style-dictionary": "^5.4.3",
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
export type LogoGeometryNode = Readonly<{
|
|
2
|
+
element: "clipPath" | "g" | "path" | "rect";
|
|
3
|
+
attributes: Readonly<Record<string, string>>;
|
|
4
|
+
children?: readonly LogoGeometryNode[];
|
|
5
|
+
}>;
|
|
6
|
+
|
|
7
|
+
export type LogoGeometry = Readonly<{
|
|
8
|
+
viewBox: string;
|
|
9
|
+
nodes: readonly LogoGeometryNode[];
|
|
10
|
+
}>;
|
|
11
|
+
|
|
12
|
+
export type LogoPaints = Readonly<{
|
|
13
|
+
ink: string;
|
|
14
|
+
primary: string;
|
|
15
|
+
}>;
|
|
16
|
+
|
|
17
|
+
export type LogoGeometryBindings = Readonly<{
|
|
18
|
+
paints: LogoPaints;
|
|
19
|
+
idPrefix?: string;
|
|
20
|
+
}>;
|
|
21
|
+
|
|
22
|
+
export declare const logoMarkGeometry: LogoGeometry;
|
|
23
|
+
export declare const logoWordmarkGeometry: LogoGeometry;
|
|
24
|
+
export declare function resolveLogoGeometry(
|
|
25
|
+
geometry: LogoGeometry,
|
|
26
|
+
bindings: LogoGeometryBindings,
|
|
27
|
+
): LogoGeometry;
|
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Framework-neutral SVG geometry for the NadicodeAI mark and wordmark.
|
|
3
|
+
*
|
|
4
|
+
* Attribute values use two renderer bindings:
|
|
5
|
+
* - `{paint:ink}` / `{paint:primary}` select presentation colors.
|
|
6
|
+
* - `{id:<name>}` becomes an instance-scoped SVG id and may be referenced from
|
|
7
|
+
* another attribute, for example `url(#{id:mark-overlap})`.
|
|
8
|
+
*
|
|
9
|
+
* This module is the only authored logo geometry. Public SVG files, favicons,
|
|
10
|
+
* and React adapters render these descriptors instead of copying paths or rects.
|
|
11
|
+
*/
|
|
12
|
+
|
|
13
|
+
const freezeNode = (node) => {
|
|
14
|
+
Object.freeze(node.attributes);
|
|
15
|
+
if (node.children) {
|
|
16
|
+
node.children.forEach(freezeNode);
|
|
17
|
+
Object.freeze(node.children);
|
|
18
|
+
}
|
|
19
|
+
return Object.freeze(node);
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
const freezeGeometry = (geometry) => {
|
|
23
|
+
geometry.nodes.forEach(freezeNode);
|
|
24
|
+
Object.freeze(geometry.nodes);
|
|
25
|
+
return Object.freeze(geometry);
|
|
26
|
+
};
|
|
27
|
+
|
|
28
|
+
export const logoMarkGeometry = freezeGeometry({
|
|
29
|
+
viewBox: "0 0 160 160",
|
|
30
|
+
nodes: [
|
|
31
|
+
{
|
|
32
|
+
element: "clipPath",
|
|
33
|
+
attributes: { id: "{id:mark-overlap}" },
|
|
34
|
+
children: [
|
|
35
|
+
{
|
|
36
|
+
element: "rect",
|
|
37
|
+
attributes: { x: "58", y: "84", width: "26", height: "26" },
|
|
38
|
+
},
|
|
39
|
+
],
|
|
40
|
+
},
|
|
41
|
+
{
|
|
42
|
+
element: "rect",
|
|
43
|
+
attributes: {
|
|
44
|
+
fill: "none",
|
|
45
|
+
stroke: "{paint:ink}",
|
|
46
|
+
"stroke-width": "10",
|
|
47
|
+
x: "42",
|
|
48
|
+
y: "50",
|
|
49
|
+
width: "46",
|
|
50
|
+
height: "46",
|
|
51
|
+
rx: "13",
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
{
|
|
55
|
+
element: "rect",
|
|
56
|
+
attributes: {
|
|
57
|
+
fill: "none",
|
|
58
|
+
stroke: "{paint:primary}",
|
|
59
|
+
"stroke-width": "10",
|
|
60
|
+
x: "72",
|
|
61
|
+
y: "64",
|
|
62
|
+
width: "46",
|
|
63
|
+
height: "46",
|
|
64
|
+
rx: "13",
|
|
65
|
+
},
|
|
66
|
+
},
|
|
67
|
+
{
|
|
68
|
+
element: "rect",
|
|
69
|
+
attributes: {
|
|
70
|
+
fill: "none",
|
|
71
|
+
stroke: "{paint:ink}",
|
|
72
|
+
"stroke-width": "10",
|
|
73
|
+
x: "42",
|
|
74
|
+
y: "50",
|
|
75
|
+
width: "46",
|
|
76
|
+
height: "46",
|
|
77
|
+
rx: "13",
|
|
78
|
+
"clip-path": "url(#{id:mark-overlap})",
|
|
79
|
+
},
|
|
80
|
+
},
|
|
81
|
+
],
|
|
82
|
+
});
|
|
83
|
+
|
|
84
|
+
export const logoWordmarkGeometry = freezeGeometry({
|
|
85
|
+
viewBox: "0 0 320 100",
|
|
86
|
+
nodes: [
|
|
87
|
+
{
|
|
88
|
+
element: "g",
|
|
89
|
+
attributes: {
|
|
90
|
+
fill: "{paint:ink}",
|
|
91
|
+
transform: "translate(0 76) scale(0.06 -0.06)",
|
|
92
|
+
},
|
|
93
|
+
children: [
|
|
94
|
+
{
|
|
95
|
+
element: "path",
|
|
96
|
+
attributes: {
|
|
97
|
+
transform: "translate(0 0)",
|
|
98
|
+
d: "M74 0L74 710L242 710L524 220L524 710L676 710L676 0L506 0L226 473L226 0Z",
|
|
99
|
+
},
|
|
100
|
+
},
|
|
101
|
+
{
|
|
102
|
+
element: "path",
|
|
103
|
+
attributes: {
|
|
104
|
+
transform: "translate(706.867 0)",
|
|
105
|
+
d: "M225 -12Q142 -12 89.5 26.5Q37 65 37 134Q37 205 81.5 243.5Q126 282 213 300L386 334Q386 386 362.5 412.5Q339 439 295 439Q252 439 228 419.5Q204 400 197 362L46 369Q61 457 125.5 502.5Q190 548 295 548Q415 548 475.5 491Q536 434 536 324L536 141Q536 118 543.5 110.5Q551 103 566 103L581 103L581 0Q574 -2 558.5 -4Q543 -6 528 -6Q496 -6 468.5 5Q441 16 424 42.5Q407 69 407 118L420 108Q410 72 384.5 45Q359 18 318.5 3Q278 -12 225 -12ZM261 91Q298 91 326 105.5Q354 120 370 148Q386 176 386 214L386 240L264 214Q228 207 209.5 190.5Q191 174 191 148Q191 121 209 106Q227 91 261 91Z",
|
|
106
|
+
},
|
|
107
|
+
},
|
|
108
|
+
{
|
|
109
|
+
element: "path",
|
|
110
|
+
attributes: {
|
|
111
|
+
transform: "translate(1258.133 0)",
|
|
112
|
+
d: "M257 -12Q189 -12 139.5 22.5Q90 57 63.5 119.5Q37 182 37 268Q37 354 64 416.5Q91 479 140.5 513.5Q190 548 257 548Q314 548 355.5 524.5Q397 501 418 460L418 710L568 710L568 0L425 0L422 79Q400 36 356.5 12Q313 -12 257 -12ZM306 103Q342 103 367 122Q392 141 405 177.5Q418 214 418 268Q418 323 405 359.5Q392 396 367 414.5Q342 433 306 433Q253 433 222 388.5Q191 344 191 268Q191 193 222.5 148Q254 103 306 103Z",
|
|
113
|
+
},
|
|
114
|
+
},
|
|
115
|
+
{
|
|
116
|
+
element: "path",
|
|
117
|
+
attributes: {
|
|
118
|
+
transform: "translate(1844.8 0)",
|
|
119
|
+
d: "M66 0L66 536L216 536L216 0ZM63 602L63 722L218 722L218 602Z",
|
|
120
|
+
},
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
element: "path",
|
|
124
|
+
attributes: {
|
|
125
|
+
transform: "translate(2082.667 0)",
|
|
126
|
+
d: "M309 -12Q227 -12 166 22.5Q105 57 71 120Q37 183 37 268Q37 353 71 415.5Q105 478 166 513Q227 548 309 548Q380 548 436.5 523Q493 498 528 451Q563 404 571 338L416 331Q409 381 380.5 406.5Q352 432 309 432Q253 432 222 389Q191 346 191 268Q191 190 222 146.5Q253 103 309 103Q352 103 381 129.5Q410 156 416 210L571 204Q564 138 529.5 89.5Q495 41 438.5 14.5Q382 -12 309 -12Z",
|
|
127
|
+
},
|
|
128
|
+
},
|
|
129
|
+
{
|
|
130
|
+
element: "path",
|
|
131
|
+
attributes: {
|
|
132
|
+
transform: "translate(2636.933 0)",
|
|
133
|
+
d: "M309 -12Q227 -12 166 22.5Q105 57 71 120Q37 183 37 268Q37 353 71 415.5Q105 478 166 513Q227 548 309 548Q391 548 452 513Q513 478 547 415.5Q581 353 581 268Q581 183 547 120Q513 57 452 22.5Q391 -12 309 -12ZM309 103Q365 103 396 146.5Q427 190 427 268Q427 346 396 389.5Q365 433 309 433Q253 433 222 389.5Q191 346 191 268Q191 190 222 146.5Q253 103 309 103Z",
|
|
134
|
+
},
|
|
135
|
+
},
|
|
136
|
+
{
|
|
137
|
+
element: "path",
|
|
138
|
+
attributes: {
|
|
139
|
+
transform: "translate(3211.6 0)",
|
|
140
|
+
d: "M257 -12Q189 -12 139.5 22.5Q90 57 63.5 119.5Q37 182 37 268Q37 354 64 416.5Q91 479 140.5 513.5Q190 548 257 548Q314 548 355.5 524.5Q397 501 418 460L418 710L568 710L568 0L425 0L422 79Q400 36 356.5 12Q313 -12 257 -12ZM306 103Q342 103 367 122Q392 141 405 177.5Q418 214 418 268Q418 323 405 359.5Q392 396 367 414.5Q342 433 306 433Q253 433 222 388.5Q191 344 191 268Q191 193 222.5 148Q254 103 306 103Z",
|
|
141
|
+
},
|
|
142
|
+
},
|
|
143
|
+
{
|
|
144
|
+
element: "path",
|
|
145
|
+
attributes: {
|
|
146
|
+
transform: "translate(3802.267 0)",
|
|
147
|
+
d: "M307 -12Q225 -12 164.5 22.5Q104 57 70.5 120Q37 183 37 268Q37 353 70.5 415.5Q104 478 164 513Q224 548 306 548Q386 548 445 513Q504 478 536.5 413Q569 348 569 258L569 228L192 228Q195 164 226.5 133Q258 102 310 102Q348 102 373.5 118Q399 134 410 167L561 158Q540 78 472 33Q404 -12 307 -12ZM192 320L415 320Q412 379 382.5 408Q353 437 306 437Q259 437 228.5 406.5Q198 376 192 320Z",
|
|
148
|
+
},
|
|
149
|
+
},
|
|
150
|
+
],
|
|
151
|
+
},
|
|
152
|
+
{
|
|
153
|
+
element: "g",
|
|
154
|
+
attributes: {
|
|
155
|
+
fill: "{paint:primary}",
|
|
156
|
+
transform: "translate(259 76) scale(0.06 -0.06)",
|
|
157
|
+
},
|
|
158
|
+
children: [
|
|
159
|
+
{
|
|
160
|
+
element: "path",
|
|
161
|
+
attributes: {
|
|
162
|
+
transform: "translate(0 0)",
|
|
163
|
+
d: "M19 0L275 710L455 710L711 0L553 0L501 151L228 151L176 0ZM271 276L459 276L365 550Z",
|
|
164
|
+
},
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
element: "path",
|
|
168
|
+
attributes: {
|
|
169
|
+
transform: "translate(670.467 0)",
|
|
170
|
+
d: "M74 0L74 710L226 710L226 0Z",
|
|
171
|
+
},
|
|
172
|
+
},
|
|
173
|
+
],
|
|
174
|
+
},
|
|
175
|
+
],
|
|
176
|
+
});
|
|
177
|
+
|
|
178
|
+
const resolveAttributeValue = (value, paints, idPrefix) => {
|
|
179
|
+
if (value === "{paint:ink}") return paints.ink;
|
|
180
|
+
if (value === "{paint:primary}") return paints.primary;
|
|
181
|
+
if (/^\{paint:[^}]+\}$/.test(value)) {
|
|
182
|
+
throw new Error(`Logo geometry references an unknown paint binding: ${value}`);
|
|
183
|
+
}
|
|
184
|
+
return value.replace(/\{id:([a-z0-9-]+)\}/g, `${idPrefix}$1`);
|
|
185
|
+
};
|
|
186
|
+
|
|
187
|
+
const resolveNode = (node, paints, idPrefix) => ({
|
|
188
|
+
element: node.element,
|
|
189
|
+
attributes: Object.fromEntries(
|
|
190
|
+
Object.entries(node.attributes).map(([name, value]) => [
|
|
191
|
+
name,
|
|
192
|
+
resolveAttributeValue(value, paints, idPrefix),
|
|
193
|
+
]),
|
|
194
|
+
),
|
|
195
|
+
...(node.children
|
|
196
|
+
? { children: node.children.map((child) => resolveNode(child, paints, idPrefix)) }
|
|
197
|
+
: {}),
|
|
198
|
+
});
|
|
199
|
+
|
|
200
|
+
/** Resolve paint roles and instance-scoped ids without choosing a UI framework. */
|
|
201
|
+
export const resolveLogoGeometry = (geometry, { paints, idPrefix = "" }) => ({
|
|
202
|
+
viewBox: geometry.viewBox,
|
|
203
|
+
nodes: geometry.nodes.map((node) => resolveNode(node, paints, idPrefix)),
|
|
204
|
+
});
|
|
File without changes
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* agent-avatar — agent identity slot (DESIGN.md `agent-avatar`).
|
|
3
|
-
* Graduated from `chat-anim.jsx` ChatHeader avatar. A round identity chip: the
|
|
4
|
-
* chrome is reusable, the visual payload (initials, image, or generated asset)
|
|
5
|
-
* is project-specific and slotted by the consumer. Per the DESIGN.md contract
|
|
6
|
-
* the surface is `canvas-soft`, the shape is fully rounded ({rounded.full}),
|
|
7
|
-
* padding is 0. An optional `[data-accent]` tints the ring from the shared accent
|
|
8
|
-
* map. Color is `var(--nc-*)` only; the radius reads `var(--nc-rounded-*)`;
|
|
9
|
-
* size/font are literals.
|
|
10
|
-
*/
|
|
11
|
-
.nc-agent-avatar {
|
|
12
|
-
--nc-accent: var(--nc-line);
|
|
13
|
-
display: grid;
|
|
14
|
-
place-items: center;
|
|
15
|
-
width: 32px;
|
|
16
|
-
height: 32px;
|
|
17
|
-
overflow: hidden;
|
|
18
|
-
border: var(--nc-guide) solid var(--nc-accent);
|
|
19
|
-
border-radius: var(--nc-rounded-full);
|
|
20
|
-
background: var(--nc-canvas-soft);
|
|
21
|
-
color: var(--nc-ink);
|
|
22
|
-
font-family: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
|
|
23
|
-
font-size: 12px;
|
|
24
|
-
font-weight: 600;
|
|
25
|
-
line-height: 1;
|
|
26
|
-
letter-spacing: 0.02em;
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
.nc-agent-avatar img,
|
|
30
|
-
.nc-agent-avatar svg {
|
|
31
|
-
display: block;
|
|
32
|
-
width: 100%;
|
|
33
|
-
height: 100%;
|
|
34
|
-
object-fit: cover;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
/* Optional identity accent — same AC-016 map as chat-bubble-agent. */
|
|
38
|
-
.nc-agent-avatar[data-accent="green"] {
|
|
39
|
-
--nc-accent: var(--nc-link);
|
|
40
|
-
}
|
|
41
|
-
.nc-agent-avatar[data-accent="cyan"] {
|
|
42
|
-
--nc-accent: var(--nc-info);
|
|
43
|
-
}
|
|
44
|
-
.nc-agent-avatar[data-accent="amber"] {
|
|
45
|
-
--nc-accent: var(--nc-warning-deep);
|
|
46
|
-
}
|
|
47
|
-
.nc-agent-avatar[data-accent="ink"] {
|
|
48
|
-
--nc-accent: var(--nc-ink);
|
|
49
|
-
}
|
|
50
|
-
.nc-agent-avatar[data-accent="red"] {
|
|
51
|
-
--nc-accent: var(--nc-error);
|
|
52
|
-
}
|
|
@@ -1,145 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* approval-gate — human-in-the-loop pause surface (DESIGN.md `approval-gate`).
|
|
3
|
-
* Graduated from the `base.css` `.nc-approval-gate` shim + `chat-anim.jsx`
|
|
4
|
-
* ApprovalGate. A warning-soft panel that pauses an agent action for explicit
|
|
5
|
-
* review: a mono label slot, title, copy, and an Approve / Edit affordance row.
|
|
6
|
-
* The panel's amber hairline is derived from the warning tokens via color-mix
|
|
7
|
-
* (no hex). Message atom → carries the M5 rise-in. Color is `var(--nc-*)` only;
|
|
8
|
-
* radii read `var(--nc-rounded-*)`; spacing/font are literals.
|
|
9
|
-
*/
|
|
10
|
-
.nc-approval-gate {
|
|
11
|
-
align-self: stretch;
|
|
12
|
-
display: grid;
|
|
13
|
-
gap: 6px;
|
|
14
|
-
padding: 12px;
|
|
15
|
-
border: var(--nc-guide) solid
|
|
16
|
-
color-mix(in srgb, var(--nc-warning-deep) 40%, var(--nc-warning-soft));
|
|
17
|
-
border-radius: var(--nc-rounded-md);
|
|
18
|
-
background: var(--nc-warning-soft);
|
|
19
|
-
color: var(--nc-ink);
|
|
20
|
-
font-family: "Geist", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
|
|
21
|
-
animation-name: nc-msg-in;
|
|
22
|
-
/* Confirm move: state transitions at the 150–200 ms feedback band. */
|
|
23
|
-
transition:
|
|
24
|
-
background-color var(--nc-duration-confirm) var(--nc-ease-out-strong),
|
|
25
|
-
border-color var(--nc-duration-confirm) var(--nc-ease-out-strong),
|
|
26
|
-
color var(--nc-duration-confirm) var(--nc-ease-out-strong);
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
.nc-approval-gate-label {
|
|
30
|
-
font-family: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
|
|
31
|
-
font-size: 10px;
|
|
32
|
-
font-weight: 600;
|
|
33
|
-
line-height: 16px;
|
|
34
|
-
color: var(--nc-warning-deep);
|
|
35
|
-
text-transform: uppercase;
|
|
36
|
-
letter-spacing: 0.06em;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
.nc-approval-gate-title {
|
|
40
|
-
font-size: 14px;
|
|
41
|
-
font-weight: 500;
|
|
42
|
-
line-height: 20px;
|
|
43
|
-
color: var(--nc-ink);
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.nc-approval-gate-copy {
|
|
47
|
-
font-size: 13px;
|
|
48
|
-
line-height: 18px;
|
|
49
|
-
color: var(--nc-body);
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
.nc-approval-gate-actions {
|
|
53
|
-
display: flex;
|
|
54
|
-
flex-wrap: wrap;
|
|
55
|
-
gap: 6px;
|
|
56
|
-
margin-top: 2px;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
/* Choice affordances. The unmarked button is the ink primary (approve / run);
|
|
60
|
-
`secondary` is the canvas neutral, `outline` a lighter panel-transparent
|
|
61
|
-
neutral, and `destructive` carries the error affordance for a deny/reject.
|
|
62
|
-
Shape and color reuse the existing chrome button vocabulary. */
|
|
63
|
-
.nc-approval-gate-actions button {
|
|
64
|
-
padding: 5px 10px;
|
|
65
|
-
border: var(--nc-guide) solid var(--nc-ink);
|
|
66
|
-
border-radius: var(--nc-rounded-sm);
|
|
67
|
-
background: var(--nc-ink);
|
|
68
|
-
color: var(--nc-canvas);
|
|
69
|
-
font-family: inherit;
|
|
70
|
-
font-size: 12px;
|
|
71
|
-
font-weight: 500;
|
|
72
|
-
line-height: 16px;
|
|
73
|
-
cursor: pointer;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
.nc-approval-gate-actions button[data-variant="secondary"] {
|
|
77
|
-
border-color: var(--nc-line);
|
|
78
|
-
background: var(--nc-canvas);
|
|
79
|
-
color: var(--nc-ink);
|
|
80
|
-
}
|
|
81
|
-
|
|
82
|
-
.nc-approval-gate-actions button[data-variant="outline"] {
|
|
83
|
-
border-color: var(--nc-line);
|
|
84
|
-
background: transparent;
|
|
85
|
-
color: var(--nc-ink);
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
/* Destructive deny/reject: an error-outlined chip so the panel keeps a single
|
|
89
|
-
filled primary while the reject reads as destructive, not neutral. Error is
|
|
90
|
-
not part of the global :root.dark --nc-* remap, so its dark counterpart is
|
|
91
|
-
flipped here (the state-tag pattern); canvas flips globally. */
|
|
92
|
-
.nc-approval-gate-actions button[data-variant="destructive"] {
|
|
93
|
-
border-color: var(--nc-error);
|
|
94
|
-
background: var(--nc-canvas);
|
|
95
|
-
color: var(--nc-error-deep);
|
|
96
|
-
}
|
|
97
|
-
|
|
98
|
-
.dark .nc-approval-gate-actions button[data-variant="destructive"] {
|
|
99
|
-
border-color: var(--nc-dark-error);
|
|
100
|
-
color: var(--nc-dark-error-deep);
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
/* Leading affordance marks — Lucide check (Approve) and square-pen (Edit),
|
|
104
|
-
painted via CSS mask with currentColor so each tracks its button's text
|
|
105
|
-
color (canvas on the ink primary, ink on the canvas secondary). */
|
|
106
|
-
.nc-approval-gate-actions button::before {
|
|
107
|
-
content: "";
|
|
108
|
-
display: inline-block;
|
|
109
|
-
width: 13px;
|
|
110
|
-
height: 13px;
|
|
111
|
-
margin-right: 5px;
|
|
112
|
-
vertical-align: -2px;
|
|
113
|
-
background-color: currentColor;
|
|
114
|
-
-webkit-mask: url("../../icons/check.svg") center / contain no-repeat;
|
|
115
|
-
mask: url("../../icons/check.svg") center / contain no-repeat;
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
.nc-approval-gate-actions button[data-variant="secondary"]::before {
|
|
119
|
-
-webkit-mask-image: url("../../icons/square-pen.svg");
|
|
120
|
-
mask-image: url("../../icons/square-pen.svg");
|
|
121
|
-
}
|
|
122
|
-
|
|
123
|
-
/* Per-choice leading marks for the React multi-choice gate. Keyed on the
|
|
124
|
-
semantic choice, not the variant, so they override the variant defaults
|
|
125
|
-
above (equal specificity, later in source) while the two-button HTML
|
|
126
|
-
Approve/Edit specimens keep check/square-pen. */
|
|
127
|
-
.nc-approval-gate-actions button[data-approval-choice="deny"]::before {
|
|
128
|
-
-webkit-mask-image: url("../../icons/ban.svg");
|
|
129
|
-
mask-image: url("../../icons/ban.svg");
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
.nc-approval-gate-actions button[data-approval-choice="session"]::before {
|
|
133
|
-
-webkit-mask-image: url("../../icons/clock.svg");
|
|
134
|
-
mask-image: url("../../icons/clock.svg");
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
.nc-approval-gate-actions button[data-approval-choice="always"]::before {
|
|
138
|
-
-webkit-mask-image: url("../../icons/shield.svg");
|
|
139
|
-
mask-image: url("../../icons/shield.svg");
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
.nc-approval-gate-actions button:focus-visible {
|
|
143
|
-
outline: var(--nc-focus-ring-width) solid var(--nc-focus-ring);
|
|
144
|
-
outline-offset: 0;
|
|
145
|
-
}
|
|
@@ -1,81 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* artifact-preview — CSS-internal atom (NO DESIGN.md contract entry; D8/D14).
|
|
3
|
-
* Graduated from `chat-anim.jsx` ArtifactPreview. A bordered preview card with a
|
|
4
|
-
* soft header (kind glyph + title + kind label) and a body excerpt. The kind is
|
|
5
|
-
* selected with `[data-kind]` (doc/sheet/code/pdf/report) which sets a leading
|
|
6
|
-
* mono glyph; doc is the default. Message atom → carries the M5 rise-in. Color
|
|
7
|
-
* is `var(--nc-*)` only; radii read `var(--nc-rounded-*)`; spacing/font are literals.
|
|
8
|
-
*/
|
|
9
|
-
.nc-artifact-preview {
|
|
10
|
-
align-self: stretch;
|
|
11
|
-
overflow: hidden;
|
|
12
|
-
border: var(--nc-guide) solid var(--nc-line);
|
|
13
|
-
border-radius: var(--nc-rounded-md);
|
|
14
|
-
background: var(--nc-canvas);
|
|
15
|
-
font-family: "Geist", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
|
|
16
|
-
animation-name: nc-msg-in;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
.nc-artifact-preview-header {
|
|
20
|
-
display: flex;
|
|
21
|
-
align-items: center;
|
|
22
|
-
gap: 8px;
|
|
23
|
-
padding: 7px 10px;
|
|
24
|
-
border-bottom: var(--nc-guide) solid var(--nc-line);
|
|
25
|
-
background: var(--nc-canvas-soft);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
/* Leading kind glyph — a Lucide icon chosen by [data-kind], painted via CSS mask
|
|
29
|
-
so it tints with the muted token. doc is the default; each kind is visually
|
|
30
|
-
distinct (pdf and report no longer collide). */
|
|
31
|
-
.nc-artifact-preview-header::before {
|
|
32
|
-
content: "";
|
|
33
|
-
flex: none;
|
|
34
|
-
width: 14px;
|
|
35
|
-
height: 14px;
|
|
36
|
-
background-color: var(--nc-muted);
|
|
37
|
-
-webkit-mask: url("../../icons/file-text.svg") center / contain no-repeat;
|
|
38
|
-
mask: url("../../icons/file-text.svg") center / contain no-repeat;
|
|
39
|
-
}
|
|
40
|
-
.nc-artifact-preview[data-kind="sheet"] .nc-artifact-preview-header::before {
|
|
41
|
-
-webkit-mask-image: url("../../icons/table.svg");
|
|
42
|
-
mask-image: url("../../icons/table.svg");
|
|
43
|
-
}
|
|
44
|
-
.nc-artifact-preview[data-kind="code"] .nc-artifact-preview-header::before {
|
|
45
|
-
-webkit-mask-image: url("../../icons/code.svg");
|
|
46
|
-
mask-image: url("../../icons/code.svg");
|
|
47
|
-
}
|
|
48
|
-
.nc-artifact-preview[data-kind="pdf"] .nc-artifact-preview-header::before {
|
|
49
|
-
-webkit-mask-image: url("../../icons/file.svg");
|
|
50
|
-
mask-image: url("../../icons/file.svg");
|
|
51
|
-
}
|
|
52
|
-
.nc-artifact-preview[data-kind="report"] .nc-artifact-preview-header::before {
|
|
53
|
-
-webkit-mask-image: url("../../icons/chart-column.svg");
|
|
54
|
-
mask-image: url("../../icons/chart-column.svg");
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
.nc-artifact-preview-title {
|
|
58
|
-
font-size: 13px;
|
|
59
|
-
font-weight: 500;
|
|
60
|
-
line-height: 18px;
|
|
61
|
-
color: var(--nc-ink);
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
.nc-artifact-preview-kind {
|
|
65
|
-
margin-left: auto;
|
|
66
|
-
font-family: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
|
|
67
|
-
font-size: 10px;
|
|
68
|
-
font-weight: 500;
|
|
69
|
-
line-height: 16px;
|
|
70
|
-
color: var(--nc-muted);
|
|
71
|
-
text-transform: uppercase;
|
|
72
|
-
letter-spacing: 0.05em;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
.nc-artifact-preview-body {
|
|
76
|
-
padding: 10px 12px;
|
|
77
|
-
color: var(--nc-body);
|
|
78
|
-
font-size: 13px;
|
|
79
|
-
line-height: 18px;
|
|
80
|
-
white-space: pre-wrap;
|
|
81
|
-
}
|
|
@@ -1,63 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* chat-bubble-agent — agent message bubble (DESIGN.md `chat-bubble-agent`).
|
|
3
|
-
* Graduated from the `base.css` `.nc-chat-bubble-agent` shim + `chat-anim.jsx`
|
|
4
|
-
* BubbleAgent. Canvas surface, ink text, left-aligned, with a 3px accent stripe
|
|
5
|
-
* drawn as an inset box-shadow on the left edge (single-owner: the stripe lives
|
|
6
|
-
* inside the bubble, never on a thread seam). The stripe consumes `--nc-accent`,
|
|
7
|
-
* which `[data-accent]` switches per the AC-016 map; the default is the brand
|
|
8
|
-
* green (`var(--nc-link)`). Message atom → carries the M5 rise-in.
|
|
9
|
-
* Color is `var(--nc-*)` only; the bubble radius reads `var(--nc-rounded-*)`
|
|
10
|
-
* (the inline code chip keeps an off-scale literal — no `rounded` token matches);
|
|
11
|
-
* spacing/font are literals.
|
|
12
|
-
*/
|
|
13
|
-
.nc-chat-bubble-agent {
|
|
14
|
-
/* AC-016 accent: default green; switchable via [data-accent]. */
|
|
15
|
-
--nc-accent: var(--nc-link);
|
|
16
|
-
align-self: flex-start;
|
|
17
|
-
width: fit-content;
|
|
18
|
-
max-width: 84%;
|
|
19
|
-
/* Extra left padding clears the 3px stripe so text never kisses it. */
|
|
20
|
-
padding: 9px 13px 9px 15px;
|
|
21
|
-
border: var(--nc-guide) solid var(--nc-line);
|
|
22
|
-
border-radius: var(--nc-rounded-md);
|
|
23
|
-
/* 3px inset accent stripe on the left edge — the bubble owns this edge. */
|
|
24
|
-
box-shadow: inset 3px 0 0 0 var(--nc-accent);
|
|
25
|
-
background: var(--nc-canvas);
|
|
26
|
-
color: var(--nc-ink);
|
|
27
|
-
font-family: "Geist", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
|
|
28
|
-
font-size: 14px;
|
|
29
|
-
line-height: 20px;
|
|
30
|
-
white-space: pre-wrap;
|
|
31
|
-
word-break: break-word;
|
|
32
|
-
/* Message-atom motion identity (AC-014); the M5 hook owns the rest. */
|
|
33
|
-
animation-name: nc-msg-in;
|
|
34
|
-
}
|
|
35
|
-
|
|
36
|
-
/* AC-016 accent map → existing --nc-* tokens. Each rule references a token, no
|
|
37
|
-
hard-coded hex. green→link, cyan→info (blue-cobalto; the killed cyan token
|
|
38
|
-
retired per Italia contract §6), amber→warning-deep, ink→ink, red→error. */
|
|
39
|
-
.nc-chat-bubble-agent[data-accent="green"] {
|
|
40
|
-
--nc-accent: var(--nc-link);
|
|
41
|
-
}
|
|
42
|
-
.nc-chat-bubble-agent[data-accent="cyan"] {
|
|
43
|
-
--nc-accent: var(--nc-info);
|
|
44
|
-
}
|
|
45
|
-
.nc-chat-bubble-agent[data-accent="amber"] {
|
|
46
|
-
--nc-accent: var(--nc-warning-deep);
|
|
47
|
-
}
|
|
48
|
-
.nc-chat-bubble-agent[data-accent="ink"] {
|
|
49
|
-
--nc-accent: var(--nc-ink);
|
|
50
|
-
}
|
|
51
|
-
.nc-chat-bubble-agent[data-accent="red"] {
|
|
52
|
-
--nc-accent: var(--nc-error);
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/* Inline mono token chip inside an agent bubble (prototype renderInline). */
|
|
56
|
-
.nc-chat-bubble-agent code {
|
|
57
|
-
padding: 1px 5px;
|
|
58
|
-
border-radius: var(--nc-rounded-xs);
|
|
59
|
-
background: var(--nc-canvas-soft-2);
|
|
60
|
-
color: var(--nc-ink);
|
|
61
|
-
font-family: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Monaco, monospace;
|
|
62
|
-
font-size: 12px;
|
|
63
|
-
}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* chat-bubble-user — human message bubble (DESIGN.md `chat-bubble-user`).
|
|
3
|
-
* Graduated from the `base.css` `.nc-chat-bubble-user` shim + `chat-anim.jsx`
|
|
4
|
-
* BubbleUser. Ink surface, white text, right-aligned (the human prompt). It is
|
|
5
|
-
* a message atom, so it carries the M5 rise-in: add the `.nc-anim-msg-in` hook
|
|
6
|
-
* in markup (it sets `animation-name: nc-msg-in`); a hard `animation-name` here
|
|
7
|
-
* guarantees the rise-in motion identity even without the hook class, while the
|
|
8
|
-
* hook still owns duration/easing/delay and reduced-motion. Color is
|
|
9
|
-
* `var(--nc-*)` only; radii read `var(--nc-rounded-*)`; spacing/font are literals.
|
|
10
|
-
*/
|
|
11
|
-
.nc-chat-bubble-user {
|
|
12
|
-
align-self: flex-end;
|
|
13
|
-
width: fit-content;
|
|
14
|
-
max-width: 84%;
|
|
15
|
-
padding: 9px 13px;
|
|
16
|
-
border: var(--nc-guide) solid var(--nc-ink);
|
|
17
|
-
border-radius: var(--nc-rounded-md);
|
|
18
|
-
background: var(--nc-ink);
|
|
19
|
-
color: var(--nc-canvas);
|
|
20
|
-
font-family: "Geist", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
|
|
21
|
-
font-size: 14px;
|
|
22
|
-
line-height: 20px;
|
|
23
|
-
white-space: pre-wrap;
|
|
24
|
-
word-break: break-word;
|
|
25
|
-
/* Message-atom motion identity (AC-014). The M5 motion layer owns timing,
|
|
26
|
-
stagger (`--nc-anim-delay`), and reduced-motion via `.nc-anim-msg-in`. */
|
|
27
|
-
animation-name: nc-msg-in;
|
|
28
|
-
}
|