baldart 4.76.1 → 4.78.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.
Files changed (25) hide show
  1. package/CHANGELOG.md +42 -0
  2. package/README.md +14 -13
  3. package/VERSION +1 -1
  4. package/framework/.claude/agents/REGISTRY.md +2 -1
  5. package/framework/.claude/agents/markup-fidelity-verifier.md +239 -0
  6. package/framework/.claude/agents/prd-card-writer.md +6 -1
  7. package/framework/.claude/agents/visual-fidelity-verifier.md +22 -0
  8. package/framework/.claude/skills/design-system-init/SKILL.md +16 -6
  9. package/framework/.claude/skills/design-system-init/scripts/compile-ds-cards.mjs +2 -1
  10. package/framework/.claude/skills/design-system-init/scripts/extract-manifest.mjs +17 -5
  11. package/framework/.claude/skills/design-system-init/scripts/extract-ts.mjs +302 -0
  12. package/framework/.claude/skills/design-system-init/scripts/render-manifest.mjs +26 -9
  13. package/framework/.claude/skills/design-system-init/scripts/serialize-spec.mjs +4 -2
  14. package/framework/.claude/skills/ds-edit/SKILL.md +2 -1
  15. package/framework/.claude/skills/ds-new/SKILL.md +2 -2
  16. package/framework/.claude/skills/e2e-review/SKILL.md +196 -27
  17. package/framework/.claude/skills/new/references/codex-gate.md +15 -1
  18. package/framework/.claude/skills/new/references/completeness.md +2 -0
  19. package/framework/.claude/skills/new/references/review-cycle.md +14 -1
  20. package/framework/agents/component-manifest-schema.md +24 -3
  21. package/framework/agents/design-system-protocol.md +79 -1
  22. package/framework/docs/COMPONENT-MANIFEST-LAYER.md +6 -3
  23. package/framework/templates/component-spec.template.md +3 -2
  24. package/framework/templates/overlays/e2e-review.fidelity-example.md +74 -0
  25. package/package.json +1 -1
@@ -0,0 +1,74 @@
1
+ ---
2
+ base_skill: e2e-review
3
+ base_skill_version: 4.78.0
4
+ mode: extend
5
+ ---
6
+
7
+ # e2e-review — fidelity-app overlay (example)
8
+
9
+ > Project-specific **reach-state recipes** for `/e2e-review` Phase 3.8. The framework
10
+ > owns the contract and the bounded loop; this overlay tells the orchestrator HOW to put
11
+ > the app into the data state a mockup depicts, so the visual reviewer never compares a
12
+ > degenerate (empty / wrong-tenant / error) render. Drop into
13
+ > `.baldart/overlays/e2e-review.md` and adapt to your stack.
14
+ >
15
+ > Without these recipes `/e2e-review` falls back to generic remediation (real auth from
16
+ > the persona creds, MSW/API-mock, deterministic factory/snapshot, heuristic context
17
+ > auto-seek) and, failing that, **blocks** with `coverage-gap` — it never silently passes
18
+ > an empty render.
19
+
20
+ ## [APPEND] Reach-state recipes
21
+
22
+ The orchestrator runs the applicable recipes in order until `render_health.degenerate`
23
+ is false. Each recipe is a named, deterministic sequence of steps the orchestrator can
24
+ execute via Playwright / `webapp-testing` / a project script. Cap: 2 attempts.
25
+
26
+ ### `seed_data` — populate the database for the route
27
+
28
+ Run before navigating, when the route shows an empty-state because the demo/CI database
29
+ is empty:
30
+
31
+ ```bash
32
+ # Example: seed a deterministic dataset the mockup depicts (idempotent).
33
+ npm run db:seed:e2e # creates store "demo" + ≥3 products + 1 supplier
34
+ ```
35
+
36
+ State guarantee: after this, `/products` renders a populated table matching the mockup's
37
+ DATI PRODOTTO / FORNITORI sections. The seed MUST be deterministic (fixed ids, no
38
+ faker-without-seed) so screenshots are reproducible.
39
+
40
+ ### `select_populated_context` — the multi-store / multi-tenant case
41
+
42
+ When the default-selected store/tenant is empty but another has data (the exact failure
43
+ the user flagged): switch context to a populated one before screenshotting.
44
+
45
+ ```
46
+ 1. Authenticate as the owner persona (test_plan.test_credentials).
47
+ 2. Open the store switcher: getByRole("button", { name: /store|negozio/i }).
48
+ 3. Pick the first store whose product count > 0 (the seeded "demo" store), NOT the
49
+ default empty one.
50
+ 4. Wait for networkidle, then proceed to the route.
51
+ ```
52
+
53
+ Heuristic fallback (no explicit list): enumerate the switcher options, navigate the route
54
+ under each, and pick the first that yields non-empty content (the verifier confirms
55
+ non-emptiness). This is the generic `webapp-testing` auto-seek.
56
+
57
+ ### `goto_populated_entity` — detail routes that need a specific id
58
+
59
+ When the mockup depicts a specific entity (e.g. a product detail), navigate to a seeded
60
+ entity id rather than a random/empty one:
61
+
62
+ ```
63
+ Navigate to `/products?selected=<seeded-product-id>&edit=1` (the id created by
64
+ `seed_data`), not the bare `/products`.
65
+ ```
66
+
67
+ ## [APPEND] Notes
68
+
69
+ - Recipes are tried in the order above (`seed_data` → `select_populated_context` →
70
+ `goto_populated_entity`); a recipe that does not apply to a route is a no-op.
71
+ - Keep recipes **deterministic and idempotent** — they run inside the bounded reach-state
72
+ loop and may be re-invoked across self-heal iterations.
73
+ - A recipe MUST NOT mutate production data: scope to the e2e/demo database the dev server
74
+ uses. The framework's contract assumes an isolated test database.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "baldart",
3
- "version": "4.76.1",
3
+ "version": "4.78.0",
4
4
  "description": "Claude Agent Framework - Reusable framework for coordinating AI agents and humans in software projects",
5
5
  "bin": {
6
6
  "baldart": "./bin/baldart.js"