@ggui-ai/project-config 0.2.0-alpha.3 → 0.3.0-rc.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/README.md +2 -2
- package/dist/schema.d.ts +49 -15
- package/dist/schema.d.ts.map +1 -1
- package/dist/schema.js +30 -11
- package/dist/theme-loader.d.ts +2 -2
- package/dist/theme-loader.js +1 -1
- package/dist/theme.d.ts +5 -30
- package/dist/theme.d.ts.map +1 -1
- package/dist/theme.js +8 -26
- package/dist/ui-manifest.d.ts +1 -1
- package/dist/ui-manifest.d.ts.map +1 -1
- package/dist/ui-manifest.js +1 -1
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -31,8 +31,8 @@ import { parseGguiJson, safeParseGguiJson } from "@ggui-ai/project-config";
|
|
|
31
31
|
const manifest = parseGguiJson(JSON.parse(rawText)); // throws on invalid input
|
|
32
32
|
|
|
33
33
|
const result = safeParseGguiJson(JSON.parse(rawText));
|
|
34
|
-
if (result.
|
|
35
|
-
// result.
|
|
34
|
+
if (result.success) {
|
|
35
|
+
// result.data is a validated GguiJsonV1
|
|
36
36
|
}
|
|
37
37
|
```
|
|
38
38
|
|
package/dist/schema.d.ts
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
*
|
|
4
4
|
* When a developer runs `ggui serve`, the OSS server reads this file
|
|
5
5
|
* to discover everything it needs: app identity, protocol version,
|
|
6
|
-
* blueprint manifests, primitive packages, theme tokens,
|
|
7
|
-
*
|
|
6
|
+
* blueprint manifests, primitive packages, theme tokens, MCP tool
|
|
7
|
+
* mounts. The schema is framework-neutral — it describes
|
|
8
8
|
* *the ggui app*, never the internal orchestration of any specific
|
|
9
9
|
* agent runtime. LLM choice, system prompt, framework-specific tool
|
|
10
10
|
* inventory belong in each framework's own config, not here.
|
|
@@ -163,9 +163,9 @@ declare const StorageSchema: z.ZodObject<{
|
|
|
163
163
|
}, z.core.$strict>], "driver">>;
|
|
164
164
|
}, z.core.$strict>;
|
|
165
165
|
/**
|
|
166
|
-
* Public type alias for one storage surface's config (renders
|
|
167
|
-
* vectors). Callers instantiating adapters from a
|
|
168
|
-
* pattern-match on `driver`.
|
|
166
|
+
* Public type alias for one storage surface's config (renders,
|
|
167
|
+
* vectors, or threads). Callers instantiating adapters from a
|
|
168
|
+
* parsed manifest pattern-match on `driver`.
|
|
169
169
|
*/
|
|
170
170
|
export type StorageSurfaceConfig = z.infer<typeof StorageSurfaceSchema>;
|
|
171
171
|
/** Public type alias for the full storage block. */
|
|
@@ -206,6 +206,23 @@ declare const GenerationSchema: z.ZodObject<{
|
|
|
206
206
|
provider: "openrouter";
|
|
207
207
|
model: (string & {}) | "anthropic/claude-haiku-4.5" | "anthropic/claude-sonnet-4.6" | "anthropic/claude-opus-4.7" | "openai/gpt-5.5" | "openai/gpt-5.5-pro" | "openai/gpt-5.4-mini" | "openai/gpt-5.4-nano" | "google/gemini-3.5-flash" | "google/gemini-3.1-pro-preview" | "google/gemini-3.1-flash-lite" | "x-ai/grok-4.3" | "meta-llama/llama-4-maverick" | "meta-llama/llama-3.3-70b-instruct" | "deepseek/deepseek-v4-pro" | "deepseek/deepseek-r1-0528" | "qwen/qwen3.7-max" | "qwen/qwen3-coder" | "mistralai/mistral-large-2512" | "openai/gpt-oss-120b";
|
|
208
208
|
}, string>>;
|
|
209
|
+
/**
|
|
210
|
+
* Which API key UI generation runs against.
|
|
211
|
+
*
|
|
212
|
+
* - `'own'` — your own configured provider key (e.g. an env var
|
|
213
|
+
* or secrets manager entry you supply); the server uses whatever
|
|
214
|
+
* key the configured `generation.model` provider resolves.
|
|
215
|
+
* - `'managed'` — your hosting provider supplies the key; you do
|
|
216
|
+
* not need to configure a provider key yourself.
|
|
217
|
+
*
|
|
218
|
+
* Absent (the default) means the server resolves the key from the
|
|
219
|
+
* environment via the standard provider-key lookup chain. Self-host
|
|
220
|
+
* deployments always use `'own'`.
|
|
221
|
+
*/
|
|
222
|
+
keySource: z.ZodOptional<z.ZodEnum<{
|
|
223
|
+
own: "own";
|
|
224
|
+
managed: "managed";
|
|
225
|
+
}>>;
|
|
209
226
|
}, z.core.$strict>;
|
|
210
227
|
/**
|
|
211
228
|
* Public type alias for the parsed generation block. `model` is the
|
|
@@ -229,10 +246,12 @@ export type ThemeConfig = z.infer<typeof ThemeConfigSchema>;
|
|
|
229
246
|
*
|
|
230
247
|
* **Required fields:** `schema`, `protocol`, `app`.
|
|
231
248
|
* **Optional fields with defaults:** `blueprints`, `primitives`,
|
|
232
|
-
* `
|
|
249
|
+
* `mcpMounts`. A zero-config `ggui.json` is just the three required
|
|
233
250
|
* fields — the OSS server boots with defaults for everything else.
|
|
234
|
-
* **Optional without default:** `theme` (absent =
|
|
235
|
-
* tokens), `agent` (absent = `ggui serve` runs
|
|
251
|
+
* **Optional without default:** `operator`, `theme` (absent =
|
|
252
|
+
* shipped default tokens), `agent` (absent = `ggui serve` runs
|
|
253
|
+
* MCP-only), `storage` (absent = in-memory), `generation`,
|
|
254
|
+
* `registry`.
|
|
236
255
|
*
|
|
237
256
|
* **Strict root:** unknown top-level keys are rejected.
|
|
238
257
|
*/
|
|
@@ -286,7 +305,6 @@ export declare const GguiJsonV1: z.ZodObject<{
|
|
|
286
305
|
"screen-wake-lock": "screen-wake-lock";
|
|
287
306
|
}>>;
|
|
288
307
|
gotchas: z.ZodOptional<z.ZodString>;
|
|
289
|
-
required: z.ZodOptional<z.ZodBoolean>;
|
|
290
308
|
hook: z.ZodString;
|
|
291
309
|
}, z.core.$strict>, z.ZodObject<{
|
|
292
310
|
description: z.ZodString;
|
|
@@ -311,7 +329,6 @@ export declare const GguiJsonV1: z.ZodObject<{
|
|
|
311
329
|
"screen-wake-lock": "screen-wake-lock";
|
|
312
330
|
}>>;
|
|
313
331
|
gotchas: z.ZodOptional<z.ZodString>;
|
|
314
|
-
required: z.ZodOptional<z.ZodBoolean>;
|
|
315
332
|
component: z.ZodString;
|
|
316
333
|
}, z.core.$strict>]>>;
|
|
317
334
|
version: z.ZodString;
|
|
@@ -337,11 +354,11 @@ export declare const GguiJsonV1: z.ZodObject<{
|
|
|
337
354
|
* declared in some registered wrapper's `requires`. Operators who
|
|
338
355
|
* declare a key without a value can use the empty string (the
|
|
339
356
|
* Mapbox SDK will surface "Invalid token" on first request rather
|
|
340
|
-
* than a missing-key error from the
|
|
357
|
+
* than a missing-key error from the render gate).
|
|
341
358
|
*
|
|
342
359
|
* Omitting this field is equivalent to `{}` — wrappers without
|
|
343
360
|
* `requires` work unchanged; wrappers that declare `requires` will
|
|
344
|
-
* fail at
|
|
361
|
+
* fail at render-gate validation if their required keys are missing.
|
|
345
362
|
*/
|
|
346
363
|
publicEnv: z.ZodOptional<z.ZodReadonly<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
347
364
|
/**
|
|
@@ -352,13 +369,13 @@ export declare const GguiJsonV1: z.ZodObject<{
|
|
|
352
369
|
* Honored by hosts as a PRESENTATION preference — `'fullscreen'`
|
|
353
370
|
* says "render as a main view"; `'inline'` says "stack vertically in
|
|
354
371
|
* the chat log"; `'pip'` says "render as picture-in-picture overlay".
|
|
355
|
-
* The wire mechanism is identical regardless of mode (every
|
|
372
|
+
* The wire mechanism is identical regardless of mode (every render
|
|
356
373
|
* stamps its own `_meta.ui.resourceUri` and every iframe goes
|
|
357
374
|
* through the same runtime mount path); display mode controls ONLY
|
|
358
375
|
* how the host arranges the iframes it mounts. Agents can override
|
|
359
|
-
* per
|
|
376
|
+
* per render via `ggui_render.input.displayMode`.
|
|
360
377
|
*
|
|
361
|
-
* Absent ⇒ no per-
|
|
378
|
+
* Absent ⇒ no per-render hint stamped (host falls back to its own
|
|
362
379
|
* default, typically `'inline'`).
|
|
363
380
|
*/
|
|
364
381
|
defaultDisplayMode: z.ZodOptional<z.ZodEnum<{
|
|
@@ -522,6 +539,23 @@ export declare const GguiJsonV1: z.ZodObject<{
|
|
|
522
539
|
provider: "openrouter";
|
|
523
540
|
model: (string & {}) | "anthropic/claude-haiku-4.5" | "anthropic/claude-sonnet-4.6" | "anthropic/claude-opus-4.7" | "openai/gpt-5.5" | "openai/gpt-5.5-pro" | "openai/gpt-5.4-mini" | "openai/gpt-5.4-nano" | "google/gemini-3.5-flash" | "google/gemini-3.1-pro-preview" | "google/gemini-3.1-flash-lite" | "x-ai/grok-4.3" | "meta-llama/llama-4-maverick" | "meta-llama/llama-3.3-70b-instruct" | "deepseek/deepseek-v4-pro" | "deepseek/deepseek-r1-0528" | "qwen/qwen3.7-max" | "qwen/qwen3-coder" | "mistralai/mistral-large-2512" | "openai/gpt-oss-120b";
|
|
524
541
|
}, string>>;
|
|
542
|
+
/**
|
|
543
|
+
* Which API key UI generation runs against.
|
|
544
|
+
*
|
|
545
|
+
* - `'own'` — your own configured provider key (e.g. an env var
|
|
546
|
+
* or secrets manager entry you supply); the server uses whatever
|
|
547
|
+
* key the configured `generation.model` provider resolves.
|
|
548
|
+
* - `'managed'` — your hosting provider supplies the key; you do
|
|
549
|
+
* not need to configure a provider key yourself.
|
|
550
|
+
*
|
|
551
|
+
* Absent (the default) means the server resolves the key from the
|
|
552
|
+
* environment via the standard provider-key lookup chain. Self-host
|
|
553
|
+
* deployments always use `'own'`.
|
|
554
|
+
*/
|
|
555
|
+
keySource: z.ZodOptional<z.ZodEnum<{
|
|
556
|
+
own: "own";
|
|
557
|
+
managed: "managed";
|
|
558
|
+
}>>;
|
|
525
559
|
}, z.core.$strict>>;
|
|
526
560
|
/**
|
|
527
561
|
* Default plugin-registry URL for this app.
|
package/dist/schema.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"schema.d.ts","sourceRoot":"","sources":["../src/schema.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAyCG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAmHxB;;;;;;;;;;;;;;;;;;;GAmBG;AACH,QAAA,MAAM,cAAc;IAClB;sDACkD;;IAElD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;;;;;;;;;;;;;;;;;OAkBG;;;;;;;;;;;;;;;IAKH;0DACsD;;QAtVtD;;;;;kDAK0C;;;IAsV1C;;;;gCAI4B;;QAlM5B;yCACiC;;;;;YAnBjC;;4DAEgD;;;QAmBhD;oDAC4C;;;;;YAtB5C;;4DAEgD;;;QAsBhD;;;;;;0CAMkC;;;;;YA9BlC;;4DAEgD;;;;IAuNhD;;;;;;;;;;OAUG;;QAxKH;;;;WAIG;;;;;;;;;;;;;;;;;QAqBH;;;;;;;;;;;;WAYG;;;;;;IAwIH;;;;;;;;;;;;;;;;;;;;;;;;;;OA0BG;;IAQH;;;;;;;;;;;;;;;;;;;;;;;;6EAwByE;;kBASzE,CAAC;AAEH,yDAAyD;AACzD,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,CAAC;AAEpD;;;;GAIG;AACH,eAAO,MAAM,kBAAkB,cAAc,CAAC;AAE9C;;;;;;;GAOG;AACH,wBAAgB,aAAa,CAAC,GAAG,EAAE,OAAO,GAAG,UAAU,CAEtD;AAED;;;;;GAKG;AACH,wBAAgB,iBAAiB,CAC/B,GAAG,EAAE,OAAO,GACX,UAAU,CAAC,OAAO,UAAU,CAAC,SAAS,CAAC,CAEzC"}
|
package/dist/schema.js
CHANGED
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
*
|
|
4
4
|
* When a developer runs `ggui serve`, the OSS server reads this file
|
|
5
5
|
* to discover everything it needs: app identity, protocol version,
|
|
6
|
-
* blueprint manifests, primitive packages, theme tokens,
|
|
7
|
-
*
|
|
6
|
+
* blueprint manifests, primitive packages, theme tokens, MCP tool
|
|
7
|
+
* mounts. The schema is framework-neutral — it describes
|
|
8
8
|
* *the ggui app*, never the internal orchestration of any specific
|
|
9
9
|
* agent runtime. LLM choice, system prompt, framework-specific tool
|
|
10
10
|
* inventory belong in each framework's own config, not here.
|
|
@@ -115,11 +115,11 @@ const AppSchema = z.strictObject({
|
|
|
115
115
|
* declared in some registered wrapper's `requires`. Operators who
|
|
116
116
|
* declare a key without a value can use the empty string (the
|
|
117
117
|
* Mapbox SDK will surface "Invalid token" on first request rather
|
|
118
|
-
* than a missing-key error from the
|
|
118
|
+
* than a missing-key error from the render gate).
|
|
119
119
|
*
|
|
120
120
|
* Omitting this field is equivalent to `{}` — wrappers without
|
|
121
121
|
* `requires` work unchanged; wrappers that declare `requires` will
|
|
122
|
-
* fail at
|
|
122
|
+
* fail at render-gate validation if their required keys are missing.
|
|
123
123
|
*/
|
|
124
124
|
publicEnv: appPublicEnvSchema.optional(),
|
|
125
125
|
/**
|
|
@@ -130,13 +130,13 @@ const AppSchema = z.strictObject({
|
|
|
130
130
|
* Honored by hosts as a PRESENTATION preference — `'fullscreen'`
|
|
131
131
|
* says "render as a main view"; `'inline'` says "stack vertically in
|
|
132
132
|
* the chat log"; `'pip'` says "render as picture-in-picture overlay".
|
|
133
|
-
* The wire mechanism is identical regardless of mode (every
|
|
133
|
+
* The wire mechanism is identical regardless of mode (every render
|
|
134
134
|
* stamps its own `_meta.ui.resourceUri` and every iframe goes
|
|
135
135
|
* through the same runtime mount path); display mode controls ONLY
|
|
136
136
|
* how the host arranges the iframes it mounts. Agents can override
|
|
137
|
-
* per
|
|
137
|
+
* per render via `ggui_render.input.displayMode`.
|
|
138
138
|
*
|
|
139
|
-
* Absent ⇒ no per-
|
|
139
|
+
* Absent ⇒ no per-render hint stamped (host falls back to its own
|
|
140
140
|
* default, typically `'inline'`).
|
|
141
141
|
*/
|
|
142
142
|
defaultDisplayMode: z.enum(['inline', 'fullscreen', 'pip']).optional(),
|
|
@@ -447,6 +447,23 @@ const GenerationSchema = z.strictObject({
|
|
|
447
447
|
}
|
|
448
448
|
return parsed;
|
|
449
449
|
}),
|
|
450
|
+
/**
|
|
451
|
+
* Which API key UI generation runs against.
|
|
452
|
+
*
|
|
453
|
+
* - `'own'` — your own configured provider key (e.g. an env var
|
|
454
|
+
* or secrets manager entry you supply); the server uses whatever
|
|
455
|
+
* key the configured `generation.model` provider resolves.
|
|
456
|
+
* - `'managed'` — your hosting provider supplies the key; you do
|
|
457
|
+
* not need to configure a provider key yourself.
|
|
458
|
+
*
|
|
459
|
+
* Absent (the default) means the server resolves the key from the
|
|
460
|
+
* environment via the standard provider-key lookup chain. Self-host
|
|
461
|
+
* deployments always use `'own'`.
|
|
462
|
+
*/
|
|
463
|
+
keySource: z
|
|
464
|
+
.enum(['own', 'managed'])
|
|
465
|
+
.optional()
|
|
466
|
+
.describe("Which API key UI generation runs against: 'own' = your own configured provider key; 'managed' = your hosting provider supplies the key. Self-host deployments always use 'own'."),
|
|
450
467
|
});
|
|
451
468
|
/**
|
|
452
469
|
* The authoritative v1 schema. `z.infer<typeof GguiJsonV1>` yields
|
|
@@ -455,10 +472,12 @@ const GenerationSchema = z.strictObject({
|
|
|
455
472
|
*
|
|
456
473
|
* **Required fields:** `schema`, `protocol`, `app`.
|
|
457
474
|
* **Optional fields with defaults:** `blueprints`, `primitives`,
|
|
458
|
-
* `
|
|
475
|
+
* `mcpMounts`. A zero-config `ggui.json` is just the three required
|
|
459
476
|
* fields — the OSS server boots with defaults for everything else.
|
|
460
|
-
* **Optional without default:** `theme` (absent =
|
|
461
|
-
* tokens), `agent` (absent = `ggui serve` runs
|
|
477
|
+
* **Optional without default:** `operator`, `theme` (absent =
|
|
478
|
+
* shipped default tokens), `agent` (absent = `ggui serve` runs
|
|
479
|
+
* MCP-only), `storage` (absent = in-memory), `generation`,
|
|
480
|
+
* `registry`.
|
|
462
481
|
*
|
|
463
482
|
* **Strict root:** unknown top-level keys are rejected.
|
|
464
483
|
*/
|
|
@@ -513,7 +532,7 @@ export const GguiJsonV1 = z.strictObject({
|
|
|
513
532
|
* default). Present means the operator has opted in per surface
|
|
514
533
|
* — no surface silently creates a file on disk. See
|
|
515
534
|
* {@link StorageConfig}. */
|
|
516
|
-
storage: StorageSchema.optional().describe('Per-surface storage adapter declarations. Absent = every persistence surface (renders, threads, vectors
|
|
535
|
+
storage: StorageSchema.optional().describe('Per-surface storage adapter declarations. Absent = every persistence surface (renders, threads, vectors) stays in-memory (zero-config OSS default). Present = opt-in per surface; no surface silently creates a file on disk.'),
|
|
517
536
|
/**
|
|
518
537
|
* Explicit UI-generation LLM route. Absent + a boot-time provider
|
|
519
538
|
* key resolves → `ggui serve` hard-fails with an actionable error
|
package/dist/theme-loader.d.ts
CHANGED
|
@@ -14,8 +14,8 @@ import { type ThemeDocument } from './theme.js';
|
|
|
14
14
|
* `--ggui-*` CSS through `parseTheme`; every group required).
|
|
15
15
|
* - `file` → `ThemeDocument` (the strict-Zod schema for the open
|
|
16
16
|
* `ggui.json#theme` file format — same `color`/`font`/`spacing`/
|
|
17
|
-
* `shape`/`motion`/`
|
|
18
|
-
* as `DtcgTheme`, but `motion`/`
|
|
17
|
+
* `shape`/`motion`/`accessibility`/`zIndex` vocabulary
|
|
18
|
+
* as `DtcgTheme`, but `motion`/`accessibility`/`zIndex`
|
|
19
19
|
* are optional so external tools that emit only a subset still
|
|
20
20
|
* parse).
|
|
21
21
|
*
|
package/dist/theme-loader.js
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
*
|
|
19
19
|
* The loader pre-renders the `:root { --ggui-*: value; }` CSS block
|
|
20
20
|
* via `@ggui-ai/design/themes`: `parseTheme(id, DtcgTheme)` for the
|
|
21
|
-
* preset / default paths (full DTCG with
|
|
21
|
+
* preset / default paths (full DTCG with motion tokens) and
|
|
22
22
|
* `generateCssVariables(ThemeDocument)` for the file path (the
|
|
23
23
|
* duck-typed walker accepts the plain DTCG document without requiring
|
|
24
24
|
* the strict {@link DtcgTheme} shape). Downstream consumers (console,
|
package/dist/theme.d.ts
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* **Shape parity with the internal `DtcgTheme`.** This v1 schema is
|
|
10
10
|
* deliberately the same shape as `@ggui-ai/design`'s canonical
|
|
11
11
|
* {@link DtcgTheme} — `color`/`font`/`spacing`/`shape`/`motion`/
|
|
12
|
-
* `
|
|
12
|
+
* `accessibility`/`zIndex` — so an authored `theme.json`
|
|
13
13
|
* uses the same vocabulary the curated registry themes (light/dark/
|
|
14
14
|
* premium-*) use. Previously this schema was Tailwind-style flat
|
|
15
15
|
* (`typography`/`radius`/`shadow` at root); the v1 schema now mirrors
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
* **External-tool compatibility.** External tooling (Figma Tokens,
|
|
19
19
|
* Style Dictionary, Tokens Studio) commonly emits only a subset of
|
|
20
20
|
* the canonical shape. Only the original required groups (`color`,
|
|
21
|
-
* `font`, `spacing`, `shape`) stay required; `motion`,
|
|
21
|
+
* `font`, `spacing`, `shape`) stay required; `motion`,
|
|
22
22
|
* `accessibility`, `zIndex`, and the new DTCG metadata fields
|
|
23
23
|
* (`$name`, `$description`, `$metadata`) are all OPTIONAL so tools
|
|
24
24
|
* that only emit colors + dimensions still parse cleanly.
|
|
@@ -58,8 +58,7 @@
|
|
|
58
58
|
* 1. Additive only within `schema: '1'`. New optional fields must
|
|
59
59
|
* default to no-op behaviour so older tooling ignores them.
|
|
60
60
|
* 2. Framework-neutral + host-neutral. No vendor names in enum
|
|
61
|
-
* values, no build-pipeline fields.
|
|
62
|
-
* vendor vocabulary; it is opt-in via the optional field.)
|
|
61
|
+
* values, no build-pipeline fields.
|
|
63
62
|
* 3. Root and per-group objects are strict — unknown keys fail
|
|
64
63
|
* parse. Same discipline as `ggui.json`, `ggui.ui.json`, and
|
|
65
64
|
* `ggui.primitives.json`.
|
|
@@ -71,7 +70,7 @@
|
|
|
71
70
|
* shadow / duration / cubicBezier / transition / number). Each
|
|
72
71
|
* variant validates its `$value` shape. `$description` is accepted
|
|
73
72
|
* everywhere as a free-form docstring. Token leaves under newer
|
|
74
|
-
* groups (`
|
|
73
|
+
* groups (`accessibility`, `zIndex`) accept a slightly
|
|
75
74
|
* wider token vocabulary because external tools sometimes encode
|
|
76
75
|
* scalar/array values with permissive `$type` strings (`string`,
|
|
77
76
|
* `array`, …); the schema accepts those without enumerating every
|
|
@@ -83,7 +82,7 @@ import { z } from 'zod';
|
|
|
83
82
|
* `spacing`, `shape`) map 1:1 to `@ggui-ai/design`'s
|
|
84
83
|
* `generateCssVariables` walker targets — anything less would mean
|
|
85
84
|
* a partial CSS output worse than falling back to the shipped
|
|
86
|
-
* default. Optional groups (`motion`, `
|
|
85
|
+
* default. Optional groups (`motion`, `accessibility`,
|
|
87
86
|
* `zIndex`) are the well-known DTCG additives; present → emitted,
|
|
88
87
|
* absent → the design system's built-in fallbacks apply.
|
|
89
88
|
*
|
|
@@ -212,30 +211,6 @@ export declare const ThemeDocumentV1: z.ZodObject<{
|
|
|
212
211
|
$description: z.ZodOptional<z.ZodString>;
|
|
213
212
|
}, z.core.$strict>>>;
|
|
214
213
|
}, z.core.$strict>>;
|
|
215
|
-
/** Canvas configuration for the GenerativeCanvas background.
|
|
216
|
-
* Optional — external tools won't emit this. */
|
|
217
|
-
canvas: z.ZodOptional<z.ZodObject<{
|
|
218
|
-
mode: z.ZodObject<{
|
|
219
|
-
$type: z.ZodString;
|
|
220
|
-
$value: z.ZodUnknown;
|
|
221
|
-
$description: z.ZodOptional<z.ZodString>;
|
|
222
|
-
}, z.core.$strict>;
|
|
223
|
-
speed: z.ZodObject<{
|
|
224
|
-
$type: z.ZodString;
|
|
225
|
-
$value: z.ZodUnknown;
|
|
226
|
-
$description: z.ZodOptional<z.ZodString>;
|
|
227
|
-
}, z.core.$strict>;
|
|
228
|
-
colors: z.ZodObject<{
|
|
229
|
-
$type: z.ZodString;
|
|
230
|
-
$value: z.ZodUnknown;
|
|
231
|
-
$description: z.ZodOptional<z.ZodString>;
|
|
232
|
-
}, z.core.$strict>;
|
|
233
|
-
background: z.ZodObject<{
|
|
234
|
-
$type: z.ZodString;
|
|
235
|
-
$value: z.ZodUnknown;
|
|
236
|
-
$description: z.ZodOptional<z.ZodString>;
|
|
237
|
-
}, z.core.$strict>;
|
|
238
|
-
}, z.core.$strict>>;
|
|
239
214
|
/** Accessibility tokens (focus ring, reduced motion, high contrast).
|
|
240
215
|
* Optional. */
|
|
241
216
|
accessibility: z.ZodOptional<z.ZodObject<{
|
package/dist/theme.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../src/theme.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../src/theme.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6EG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AA4OxB;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,eAAe;IAC1B;kEAC8D;;IAG9D,qEAAqE;;IAGrE;6BACyB;;IAGzB;4CACwC;;IAGxC;8CAC0C;;;;;;IAG1C,0DAA0D;;;;;;;;;;IAG1D,+BAA+B;;;;;;IAG/B,2EAA2E;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAG3E,oDAAoD;;;;;;;;;;;;;;;;;;;IAGpD;mEAC+D;;;;;;;;;;;;;;;;;;;;;;;;;;;IAG/D;oBACgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAGhB,+BAA+B;;;;;;kBAE/B,CAAC;AAEH,yDAAyD;AACzD,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC;AAE9D,iDAAiD;AACjD,MAAM,MAAM,aAAa,GAAG,eAAe,CAAC;AAE5C;;;GAGG;AACH,wBAAgB,kBAAkB,CAAC,GAAG,EAAE,OAAO,GAAG,aAAa,CAE9D;AAED;;;;GAIG;AACH,wBAAgB,sBAAsB,CACpC,GAAG,EAAE,OAAO,GACX,UAAU,CAAC,OAAO,eAAe,CAAC,SAAS,CAAC,CAE9C"}
|
package/dist/theme.js
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
* **Shape parity with the internal `DtcgTheme`.** This v1 schema is
|
|
10
10
|
* deliberately the same shape as `@ggui-ai/design`'s canonical
|
|
11
11
|
* {@link DtcgTheme} — `color`/`font`/`spacing`/`shape`/`motion`/
|
|
12
|
-
* `
|
|
12
|
+
* `accessibility`/`zIndex` — so an authored `theme.json`
|
|
13
13
|
* uses the same vocabulary the curated registry themes (light/dark/
|
|
14
14
|
* premium-*) use. Previously this schema was Tailwind-style flat
|
|
15
15
|
* (`typography`/`radius`/`shadow` at root); the v1 schema now mirrors
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
* **External-tool compatibility.** External tooling (Figma Tokens,
|
|
19
19
|
* Style Dictionary, Tokens Studio) commonly emits only a subset of
|
|
20
20
|
* the canonical shape. Only the original required groups (`color`,
|
|
21
|
-
* `font`, `spacing`, `shape`) stay required; `motion`,
|
|
21
|
+
* `font`, `spacing`, `shape`) stay required; `motion`,
|
|
22
22
|
* `accessibility`, `zIndex`, and the new DTCG metadata fields
|
|
23
23
|
* (`$name`, `$description`, `$metadata`) are all OPTIONAL so tools
|
|
24
24
|
* that only emit colors + dimensions still parse cleanly.
|
|
@@ -58,8 +58,7 @@
|
|
|
58
58
|
* 1. Additive only within `schema: '1'`. New optional fields must
|
|
59
59
|
* default to no-op behaviour so older tooling ignores them.
|
|
60
60
|
* 2. Framework-neutral + host-neutral. No vendor names in enum
|
|
61
|
-
* values, no build-pipeline fields.
|
|
62
|
-
* vendor vocabulary; it is opt-in via the optional field.)
|
|
61
|
+
* values, no build-pipeline fields.
|
|
63
62
|
* 3. Root and per-group objects are strict — unknown keys fail
|
|
64
63
|
* parse. Same discipline as `ggui.json`, `ggui.ui.json`, and
|
|
65
64
|
* `ggui.primitives.json`.
|
|
@@ -71,7 +70,7 @@
|
|
|
71
70
|
* shadow / duration / cubicBezier / transition / number). Each
|
|
72
71
|
* variant validates its `$value` shape. `$description` is accepted
|
|
73
72
|
* everywhere as a free-form docstring. Token leaves under newer
|
|
74
|
-
* groups (`
|
|
73
|
+
* groups (`accessibility`, `zIndex`) accept a slightly
|
|
75
74
|
* wider token vocabulary because external tools sometimes encode
|
|
76
75
|
* scalar/array values with permissive `$type` strings (`string`,
|
|
77
76
|
* `array`, …); the schema accepts those without enumerating every
|
|
@@ -168,11 +167,10 @@ const LineHeightToken = z.union([
|
|
|
168
167
|
}),
|
|
169
168
|
]);
|
|
170
169
|
/**
|
|
171
|
-
* Permissive token leaf for the newer optional groups
|
|
172
|
-
* `motion.keyframes`, `zIndex`). DTCG hasn't standardised every
|
|
170
|
+
* Permissive token leaf for the newer optional groups
|
|
171
|
+
* (`motion.keyframes`, `zIndex`). DTCG hasn't standardised every
|
|
173
172
|
* `$type` value the curated registry themes carry — for example
|
|
174
|
-
*
|
|
175
|
-
* `$type: 'array'`, easing uses `$type: 'cubicBezier'`. Rather than
|
|
173
|
+
* easing uses `$type: 'cubicBezier'`. Rather than
|
|
176
174
|
* enumerate every spelling, this leaf accepts any `$type` string and
|
|
177
175
|
* any JSON-serializable `$value`. Strict per-leaf shape stays in
|
|
178
176
|
* force for the original token types via the leaves above.
|
|
@@ -248,19 +246,6 @@ const MotionGroup = z.strictObject({
|
|
|
248
246
|
transition: z.record(z.string(), TransitionToken),
|
|
249
247
|
keyframes: z.record(z.string(), PermissiveToken).optional(),
|
|
250
248
|
});
|
|
251
|
-
/**
|
|
252
|
-
* Canvas group — GenerativeCanvas background configuration.
|
|
253
|
-
* Optional at the document root (external tools won't emit this).
|
|
254
|
-
* Token leaves use `PermissiveToken` because the canonical shape
|
|
255
|
-
* mixes `$type: 'string'` (mode), `$type: 'number'` (speed),
|
|
256
|
-
* `$type: 'array'` (colors), `$type: 'color'` (background).
|
|
257
|
-
*/
|
|
258
|
-
const CanvasGroup = z.strictObject({
|
|
259
|
-
mode: PermissiveToken,
|
|
260
|
-
speed: PermissiveToken,
|
|
261
|
-
colors: PermissiveToken,
|
|
262
|
-
background: PermissiveToken,
|
|
263
|
-
});
|
|
264
249
|
const AccessibilityGroup = z.strictObject({
|
|
265
250
|
focusRing: z
|
|
266
251
|
.strictObject({
|
|
@@ -300,7 +285,7 @@ const MetadataGroup = z.strictObject({
|
|
|
300
285
|
* `spacing`, `shape`) map 1:1 to `@ggui-ai/design`'s
|
|
301
286
|
* `generateCssVariables` walker targets — anything less would mean
|
|
302
287
|
* a partial CSS output worse than falling back to the shipped
|
|
303
|
-
* default. Optional groups (`motion`, `
|
|
288
|
+
* default. Optional groups (`motion`, `accessibility`,
|
|
304
289
|
* `zIndex`) are the well-known DTCG additives; present → emitted,
|
|
305
290
|
* absent → the design system's built-in fallbacks apply.
|
|
306
291
|
*
|
|
@@ -340,9 +325,6 @@ export const ThemeDocumentV1 = z.strictObject({
|
|
|
340
325
|
/** Motion tokens — `duration` + `transition` (required sub-records),
|
|
341
326
|
* `easing` + `keyframes` (optional sub-records). Optional. */
|
|
342
327
|
motion: MotionGroup.optional(),
|
|
343
|
-
/** Canvas configuration for the GenerativeCanvas background.
|
|
344
|
-
* Optional — external tools won't emit this. */
|
|
345
|
-
canvas: CanvasGroup.optional(),
|
|
346
328
|
/** Accessibility tokens (focus ring, reduced motion, high contrast).
|
|
347
329
|
* Optional. */
|
|
348
330
|
accessibility: AccessibilityGroup.optional(),
|
package/dist/ui-manifest.d.ts
CHANGED
|
@@ -47,7 +47,7 @@ export declare const UiManifestV1: z.ZodObject<{
|
|
|
47
47
|
name: z.ZodString;
|
|
48
48
|
/** One-line description of what this UI does. */
|
|
49
49
|
description: z.ZodOptional<z.ZodString>;
|
|
50
|
-
/** Data contract:
|
|
50
|
+
/** Data contract: propsSpec, actionSpec, streamSpec, contextSpec, agentCapabilities/clientCapabilities. */
|
|
51
51
|
contract: z.ZodCustom<DataContract, DataContract>;
|
|
52
52
|
/** Category for browsing/filtering (e.g., "dashboard", "form", "data-viz"). */
|
|
53
53
|
category: z.ZodOptional<z.ZodString>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ui-manifest.d.ts","sourceRoot":"","sources":["../src/ui-manifest.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AA4BtD;;;GAGG;AACH,eAAO,MAAM,YAAY;IACvB,+DAA+D;;IAG/D,kEAAkE;;IAGlE,iDAAiD;;IAGjD,
|
|
1
|
+
{"version":3,"file":"ui-manifest.d.ts","sourceRoot":"","sources":["../src/ui-manifest.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmCG;AACH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AA4BtD;;;GAGG;AACH,eAAO,MAAM,YAAY;IACvB,+DAA+D;;IAG/D,kEAAkE;;IAGlE,iDAAiD;;IAGjD,2GAA2G;;IAG3G,+EAA+E;;IAG/E,+DAA+D;;IAK/D,iFAAiF;;IAGjF,2EAA2E;;IAK3E,4EAA4E;;IAG5E;6DACyD;;IAGzD,6EAA6E;;IAG7E,+EAA+E;;kBAE/E,CAAC;AAEH,yDAAyD;AACzD,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAExD;;;;GAIG;AACH,MAAM,MAAM,UAAU,GAAG,YAAY,CAAC;AAEtC;;;;GAIG;AACH,eAAO,MAAM,qBAAqB,iBAAiB,CAAC;AAEpD;;;GAGG;AACH,wBAAgB,eAAe,CAAC,GAAG,EAAE,OAAO,GAAG,UAAU,CAExD;AAED;;;;GAIG;AACH,wBAAgB,mBAAmB,CACjC,GAAG,EAAE,OAAO,GACX,UAAU,CAAC,OAAO,YAAY,CAAC,SAAS,CAAC,CAE3C"}
|
package/dist/ui-manifest.js
CHANGED
|
@@ -69,7 +69,7 @@ export const UiManifestV1 = z.strictObject({
|
|
|
69
69
|
name: z.string().min(1).max(120),
|
|
70
70
|
/** One-line description of what this UI does. */
|
|
71
71
|
description: z.string().max(500).optional(),
|
|
72
|
-
/** Data contract:
|
|
72
|
+
/** Data contract: propsSpec, actionSpec, streamSpec, contextSpec, agentCapabilities/clientCapabilities. */
|
|
73
73
|
contract: z.custom((v) => typeof v === 'object' && v !== null),
|
|
74
74
|
/** Category for browsing/filtering (e.g., "dashboard", "form", "data-viz"). */
|
|
75
75
|
category: z.string().max(60).optional(),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ggui-ai/project-config",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0-rc.0",
|
|
4
4
|
"description": "Schema and loader for `ggui.json` — the portable app/agent manifest for the ggui protocol. Vendor-neutral. Consumed by the `ggui` CLI and any host that reconstitutes an agent from the manifest.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ggui",
|
|
@@ -33,8 +33,8 @@
|
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"tinyglobby": "^0.2.16",
|
|
35
35
|
"zod": "^4.3.6",
|
|
36
|
-
"@ggui-ai/design": "0.
|
|
37
|
-
"@ggui-ai/protocol": "0.
|
|
36
|
+
"@ggui-ai/design": "0.3.0-rc.0",
|
|
37
|
+
"@ggui-ai/protocol": "0.3.0-rc.0"
|
|
38
38
|
},
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"@types/node": "^24.0.0",
|