@event4u/agent-config 9.16.0 → 9.18.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/.claude-plugin/marketplace.json +1 -1
- package/AGENTS.md +1 -1
- package/CHANGELOG.md +80 -130
- package/README.md +1 -1
- package/dist/agent-src/commands/agent-handoff.md +100 -48
- package/dist/agent-src/commands/challenge-me/vision.md +5 -0
- package/dist/agent-src/commands/commit.md +1 -1
- package/dist/agent-src/commands/condense.md +19 -64
- package/dist/agent-src/commands/evals/agent-handoff.json +13 -1
- package/dist/agent-src/commands/evals/rule-compliance-audit.json +46 -0
- package/dist/agent-src/commands/feature/plan.md +20 -0
- package/dist/agent-src/commands/feature/roadmap.md +19 -0
- package/dist/agent-src/commands/memory/promote.md +14 -1
- package/dist/agent-src/commands/mode.md +9 -5
- package/dist/agent-src/commands/optimize/deep.md +72 -11
- package/dist/agent-src/commands/pr/create.md +29 -0
- package/dist/agent-src/commands/roadmap/create.md +29 -0
- package/dist/agent-src/commands/rule-compliance-audit.md +28 -5
- package/dist/agent-src/contexts/authority/commit-mechanics.md +5 -5
- package/dist/agent-src/contexts/communication/rules-auto/guidelines-mechanics.md +1 -0
- package/dist/agent-src/contexts/communication/rules-auto/skill-quality-mechanics.md +1 -1
- package/dist/agent-src/contexts/communication/rules-auto/think-before-action-mechanics.md +6 -1
- package/dist/agent-src/contexts/communication/rules-auto/token-efficiency-mechanics.md +4 -1
- package/dist/agent-src/contexts/execution/autonomy-mechanics.md +27 -1
- package/dist/agent-src/contexts/execution/plan-confidence-gate.md +133 -0
- package/dist/agent-src/contexts/execution/roadmap-process-loop.md +5 -2
- package/dist/agent-src/profiles/agency.yml +3 -3
- package/dist/agent-src/profiles/content_creator.yml +2 -2
- package/dist/agent-src/profiles/developer.yml +2 -2
- package/dist/agent-src/profiles/finance.yml +1 -1
- package/dist/agent-src/profiles/founder.yml +2 -2
- package/dist/agent-src/profiles/ops.yml +2 -2
- package/dist/agent-src/rules/active-remediation.md +2 -0
- package/dist/agent-src/rules/architecture.md +4 -2
- package/dist/agent-src/rules/augment-edit-discipline.md +2 -0
- package/dist/agent-src/rules/autonomous-execution.md +1 -1
- package/dist/agent-src/rules/brand-consistency.md +10 -62
- package/dist/agent-src/rules/brand-source-of-truth.md +62 -11
- package/dist/agent-src/rules/broken-access-control.md +4 -0
- package/dist/agent-src/rules/cli-output-handling.md +5 -0
- package/dist/agent-src/rules/code-comment-discipline.md +3 -0
- package/dist/agent-src/rules/commit-conventions.md +2 -0
- package/dist/agent-src/rules/context-hygiene.md +3 -2
- package/dist/agent-src/rules/cross-source-consistency.md +3 -0
- package/dist/agent-src/rules/design-fidelity.md +2 -0
- package/dist/agent-src/rules/doc-screenshot-hygiene.md +2 -0
- package/dist/agent-src/rules/docker-commands.md +4 -0
- package/dist/agent-src/rules/domain-adoption-policy.md +2 -0
- package/dist/agent-src/rules/domain-safety-disclaimer.md +5 -2
- package/dist/agent-src/rules/domain-safety-pii.md +1 -1
- package/dist/agent-src/rules/engineering-safety-floor.md +2 -0
- package/dist/agent-src/rules/framework-neutrality-in-generic-skills.md +9 -0
- package/dist/agent-src/rules/image-likeness-and-rights.md +4 -0
- package/dist/agent-src/rules/improve-before-implement.md +4 -0
- package/dist/agent-src/rules/laravel-routing.md +4 -0
- package/dist/agent-src/rules/legal-safety-floor.md +3 -0
- package/dist/agent-src/rules/lethal-trifecta-guard.md +3 -0
- package/dist/agent-src/rules/media-governance-routing.md +5 -0
- package/dist/agent-src/rules/minimal-safe-diff.md +2 -0
- package/dist/agent-src/rules/no-roadmap-references.md +2 -0
- package/dist/agent-src/rules/notes-first-reasoning.md +2 -0
- package/dist/agent-src/rules/output-discipline.md +9 -2
- package/dist/agent-src/rules/php-coding.md +2 -0
- package/dist/agent-src/rules/prefer-enums-over-literals.md +3 -0
- package/dist/agent-src/rules/provider-lifecycle-discipline.md +5 -0
- package/dist/agent-src/rules/roadmap-ci-steps-policy.md +2 -0
- package/dist/agent-src/rules/roadmap-progress-sync.md +2 -0
- package/dist/agent-src/rules/rule-type-governance.md +2 -0
- package/dist/agent-src/rules/scale-discipline.md +3 -0
- package/dist/agent-src/rules/secret-vcs-guard.md +2 -0
- package/dist/agent-src/rules/security-sensitive-stop.md +9 -2
- package/dist/agent-src/rules/senior-engineering-discipline.md +6 -0
- package/dist/agent-src/rules/skill-quality.md +2 -0
- package/dist/agent-src/rules/source-confidentiality.md +4 -0
- package/dist/agent-src/rules/source-discovery-gate.md +3 -0
- package/dist/agent-src/rules/source-of-truth.md +2 -0
- package/dist/agent-src/rules/strategy-safety-floor.md +2 -0
- package/dist/agent-src/rules/think-before-action.md +5 -0
- package/dist/agent-src/rules/token-budget-discipline.md +2 -2
- package/dist/agent-src/rules/ui-audit-gate.md +2 -0
- package/dist/agent-src/rules/user-interaction.md +3 -4
- package/dist/agent-src/skills/build-buy-partner/SKILL.md +1 -1
- package/dist/agent-src/skills/copilot-agents-optimization/SKILL.md +4 -4
- package/dist/agent-src/skills/copilot-config/SKILL.md +1 -1
- package/dist/agent-src/skills/deep-reading-analyst/SKILL.md +7 -4
- package/dist/agent-src/skills/description-assist/SKILL.md +1 -1
- package/dist/agent-src/skills/design-intelligence/SKILL.md +6 -180
- package/dist/agent-src/skills/design-intelligence/references/context-and-registers.md +100 -0
- package/dist/agent-src/skills/design-intelligence/references/integration-mapping.md +91 -0
- package/dist/agent-src/skills/design-review/SKILL.md +4 -141
- package/dist/agent-src/skills/design-review/references/review-communication.md +92 -0
- package/dist/agent-src/skills/design-review/references/verification-automation.md +61 -0
- package/dist/agent-src/skills/existing-ui-audit/SKILL.md +8 -27
- package/dist/agent-src/skills/existing-ui-audit/references/anti-slop-cross-reference.md +31 -0
- package/dist/agent-src/skills/fe-design/SKILL.md +4 -289
- package/dist/agent-src/skills/fe-design/references/design-patterns.md +227 -0
- package/dist/agent-src/skills/fe-design/references/design-read-and-memory.md +75 -0
- package/dist/agent-src/skills/market-entry-analysis/SKILL.md +1 -1
- package/dist/agent-src/skills/persona-writing/SKILL.md +2 -2
- package/dist/agent-src/skills/readme-reviewer/SKILL.md +2 -1
- package/dist/agent-src/skills/roadmap-management/SKILL.md +10 -0
- package/dist/agent-src/skills/roadmap-writing/SKILL.md +12 -1
- package/dist/agent-src/skills/rule-writing/SKILL.md +4 -2
- package/dist/agent-src/skills/skill-reviewer/SKILL.md +1 -1
- package/dist/agent-src/skills/skill-writing/SKILL.md +2 -2
- package/dist/agent-src/skills/tailwind-engineer/SKILL.md +3 -1
- package/dist/agent-src/skills/token-optimizer/SKILL.md +2 -2
- package/dist/agent-src/skills/ui-component-architect/SKILL.md +6 -3
- package/dist/agent-src/templates/agent-settings.md +13 -15
- package/dist/agent-src/templates/agents/agent-project-settings.example.yml +6 -2
- package/dist/agent-src/templates/persona.md +2 -2
- package/dist/agent-src/templates/roadmaps.md +13 -1
- package/dist/agent-src/templates/rule.md +1 -1
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/_fix_lane.ts +52 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/audit.ts +8 -0
- package/dist/agent-src/templates/scripts/work_engine/directives/ui/design.ts +6 -0
- package/dist/agent-src/templates/scripts/work_engine/intent/classify.ts +56 -4
- package/dist/agent-src/templates/skill.md +1 -1
- package/dist/cli/registry.js +3 -0
- package/dist/cli/registry.js.map +1 -1
- package/dist/cli-delegate/chunk-AIIUU73N.js +2040 -0
- package/dist/cli-delegate/{chunk-ZXXJLL5K.js → chunk-BSLUHV2F.js} +127 -1487
- package/dist/cli-delegate/{chunk-H574KOUH.js → chunk-ELMFOQPW.js} +35 -1
- package/dist/cli-delegate/chunk-LF2KKJ4Q.js +183 -0
- package/dist/cli-delegate/chunk-VSYT7OHO.js +1382 -0
- package/dist/cli-delegate/chunk-XGA2NTU4.js +3727 -0
- package/dist/cli-delegate/cmd_conformance.js +4 -3
- package/dist/cli-delegate/cmd_converge.js +3 -3
- package/dist/cli-delegate/cmd_doctor.js +3 -2
- package/dist/cli-delegate/cmd_explain.js +36 -36
- package/dist/cli-delegate/cmd_export.js +4 -4
- package/dist/cli-delegate/cmd_handoff.js +1169 -0
- package/dist/cli-delegate/cmd_memory_get.js +35 -3754
- package/dist/cli-delegate/cmd_migrate.js +2 -2
- package/dist/cli-delegate/cmd_prune.js +4 -4
- package/dist/cli-delegate/cmd_route_audit.js +249 -0
- package/dist/cli-delegate/cmd_route_explain.js +285 -0
- package/dist/cli-delegate/cmd_settings_migrate.js +4 -4
- package/dist/cli-delegate/cmd_sync.js +4 -4
- package/dist/cli-delegate/cmd_uninstall.js +4 -4
- package/dist/cli-delegate/cmd_update.js +3 -3
- package/dist/cli-delegate/cmd_upgrade.js +3 -3
- package/dist/cli-delegate/cmd_validate.js +4 -4
- package/dist/cli-delegate/cmd_versions.js +3 -3
- package/dist/discovery/deprecation-report.md +1 -1
- package/dist/discovery/discovery-manifest.json +84 -84
- package/dist/discovery/discovery-manifest.json.sha256 +1 -1
- package/dist/discovery/discovery-manifest.summary.md +1 -1
- package/dist/discovery/orphan-report.md +1 -1
- package/dist/discovery/packs.json +2 -2
- package/dist/discovery/trust-report.md +1 -1
- package/dist/discovery/workspaces.json +2 -2
- package/dist/hooks/dispatch.js +602 -507
- package/dist/install/install.mjs +34 -0
- package/dist/mcp/awesome-mcp-servers.row.md +1 -1
- package/dist/mcp/mcp-cloudflare-catalogue.json +2 -2
- package/dist/mcp/registry-manifest.json +4 -4
- package/dist/mcp/server.json +2 -2
- package/dist/mcp/server.mjs +25 -3
- package/dist/router.json +1 -1
- package/dist/scripts/_lib/agent_src.js +39 -6
- package/dist/scripts/_lib/agent_src.js.map +1 -1
- package/dist/server/schemas/settings.js +25 -0
- package/dist/server/schemas/settings.js.map +1 -1
- package/docs/guidelines/abstraction-thresholds.md +53 -0
- package/docs/guidelines/agent-infra/agent-interaction-and-decision-quality.md +1 -1
- package/docs/guidelines/agent-infra/asking-and-brevity-examples.md +7 -0
- package/docs/guidelines/agent-infra/context-hygiene-mechanics.md +2 -2
- package/docs/guidelines/agent-infra/minimal-safe-diff-mechanics.md +5 -3
- package/docs/guidelines/agent-infra/size-and-scope.md +8 -2
- package/docs/guidelines/component-oriented-and-oop-development.md +11 -6
- package/docs/guidelines/docs/readme-size-and-splitting.md +5 -2
- package/llms.txt +1 -0
- package/package.json +1 -1
- package/src/agent-src/templates/scripts/work_engine/directives/ui/_fix_lane.ts +52 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/audit.ts +8 -0
- package/src/agent-src/templates/scripts/work_engine/directives/ui/design.ts +6 -0
- package/src/agent-src/templates/scripts/work_engine/intent/classify.ts +56 -4
- package/src/config/agent-settings.template.yml +68 -0
- package/src/config/evaluator-budgets.json +8 -11
- package/src/config/gate-coverage.yml +70 -0
- package/src/scripts/_cli/cmd_explain.ts +41 -36
- package/src/scripts/_cli/cmd_handoff.ts +405 -0
- package/src/scripts/_cli/cmd_route_audit.ts +290 -0
- package/src/scripts/_cli/cmd_route_explain.ts +269 -0
- package/src/scripts/_cli/handoff_generate.ts +453 -0
- package/src/scripts/_cli/handoff_sessions.ts +435 -0
- package/src/scripts/_dispatch.bash +32 -0
- package/src/scripts/_lib/agent_src.ts +36 -6
- package/src/scripts/_lib/git_env.ts +40 -0
- package/src/scripts/_lib/md_table.ts +27 -0
- package/src/scripts/_lib/planning_settings.ts +43 -0
- package/src/scripts/_lib/release_material.ts +156 -0
- package/src/scripts/_lib/router_match.ts +301 -0
- package/src/scripts/annotate_r1_outcomes.ts +258 -0
- package/src/scripts/check_completion_review.ts +1140 -0
- package/src/scripts/check_condensation.ts +2 -1
- package/src/scripts/check_finding_dispositions.ts +278 -0
- package/src/scripts/check_pack_size.ts +4 -3
- package/src/scripts/check_references.ts +1 -0
- package/src/scripts/check_release_highlights.ts +300 -0
- package/src/scripts/check_release_pr_shape.ts +4 -0
- package/src/scripts/check_release_surface_equality.ts +132 -0
- package/src/scripts/check_reply_consistency.ts +187 -138
- package/src/scripts/compile_router.ts +20 -3
- package/src/scripts/dispatch_r2_reviewer.ts +968 -0
- package/src/scripts/eval_ui_triviality.ts +156 -0
- package/src/scripts/handoff_context_hook.ts +148 -0
- package/src/scripts/hook_manifest.yaml +17 -7
- package/src/scripts/hooks/concern_registry.ts +2 -0
- package/src/scripts/lint_abstraction_thresholds.ts +327 -0
- package/src/scripts/lint_framework_leakage_allowlist.json +2 -2
- package/src/scripts/lint_plan_risk_register.ts +931 -0
- package/src/scripts/lint_profile_personas.ts +153 -0
- package/src/scripts/lint_token_budget_discipline.ts +148 -0
- package/src/scripts/lint_trigger_collisions.ts +257 -0
- package/src/scripts/release.ts +156 -32
- package/src/scripts/release_drill.ts +491 -0
- package/src/scripts/router_telemetry.ts +16 -290
- package/src/scripts/schemas/command.schema.json +33 -0
- package/src/scripts/schemas/rule.schema.json +10 -0
- package/src/scripts/self_review_gate.ts +41 -3
- package/src/scripts/skill_linter.ts +3 -1
- package/src/scripts/smoke/router.sh +1 -1
- package/src/scripts/update_counts.ts +60 -12
- package/src/server/schemas/settings.ts +41 -0
- package/dist/cli-delegate/{chunk-XX6TOPD7.js → chunk-WR6GTRHJ.js} +3 -3
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# design-review — verification automation
|
|
2
|
+
|
|
3
|
+
> Section-level entry point of the `design-review` skill (progressive
|
|
4
|
+
> disclosure, 2026-08-04). Content moved VERBATIM from SKILL.md —
|
|
5
|
+
> load this file when the section index in SKILL.md routes here.
|
|
6
|
+
|
|
7
|
+
## Visual QA with browser automation
|
|
8
|
+
|
|
9
|
+
When Playwright MCP or browser tools are available, use them for automated visual verification:
|
|
10
|
+
|
|
11
|
+
### Before/After comparison
|
|
12
|
+
|
|
13
|
+
1. **Capture baseline** — screenshot before changes at all 3 viewports.
|
|
14
|
+
2. **Apply changes** — deploy or hot-reload.
|
|
15
|
+
3. **Capture after** — screenshot at the same viewports and states.
|
|
16
|
+
4. **Compare** — visually diff the screenshots, flag regressions.
|
|
17
|
+
|
|
18
|
+
### State-based verification
|
|
19
|
+
|
|
20
|
+
Don't just screenshot the default state. Capture:
|
|
21
|
+
|
|
22
|
+
| State | How to trigger |
|
|
23
|
+
|---|---|
|
|
24
|
+
| Empty | Remove data, check empty state UI |
|
|
25
|
+
| Loading | Throttle network, capture skeleton/spinner |
|
|
26
|
+
| Error | Force an error response, check error UI |
|
|
27
|
+
| Overflow | Add very long text, many items |
|
|
28
|
+
| Interactive | Hover, focus, open dropdowns |
|
|
29
|
+
|
|
30
|
+
### Mockup-to-code verification
|
|
31
|
+
|
|
32
|
+
When implementing from a design mockup or screenshot:
|
|
33
|
+
|
|
34
|
+
1. **Open the mockup** — use the provided image/screenshot.
|
|
35
|
+
2. **Implement** — build the UI component.
|
|
36
|
+
3. **Side-by-side** — compare mockup vs. implementation at the same viewport.
|
|
37
|
+
4. **Flag deviations** — spacing, colors, typography, alignment differences.
|
|
38
|
+
|
|
39
|
+
This is especially useful when the user provides a screenshot or Figma export as a reference.
|
|
40
|
+
|
|
41
|
+
## Async-verifier pattern (keep the main context clean)
|
|
42
|
+
|
|
43
|
+
For a review that needs browser probing, use an **async background verifier**
|
|
44
|
+
rather than self-screenshotting inline: fork a verifier subagent with its own
|
|
45
|
+
view — it takes the screenshots, probes viewports, and checks states, then
|
|
46
|
+
**stays silent on pass and surfaces only real, actionable problems** (never
|
|
47
|
+
nitpicks). The main agent does not self-screenshot, so its context stays clean
|
|
48
|
+
for the actual review reasoning. This is an orchestration pattern —
|
|
49
|
+
dispatch it via [`subagent-orchestration`](../subagent-orchestration/SKILL.md)
|
|
50
|
+
and position it against [`verify-repair-loop`](../verify-repair-loop/SKILL.md)
|
|
51
|
+
(the existing verify skill); it complements them, it does not duplicate them.
|
|
52
|
+
|
|
53
|
+
**Why the audit passes stay serial (not a parallel-4 fan-out).** A fan-out of
|
|
54
|
+
a11y + slop + hierarchy + states across four subagents was evaluated and
|
|
55
|
+
deferred: the passes share one live browser/navigation session and later phases
|
|
56
|
+
build on state established by earlier ones, so they are not cleanly independent;
|
|
57
|
+
and the expensive part — browser probing / screenshots — is already offloaded by
|
|
58
|
+
the async verifier above, which captures the fan-out's main win without spinning
|
|
59
|
+
up four separate views. Reconsider only when `design-review` runs as a standalone
|
|
60
|
+
heavy batch over many *independent* surfaces, where per-surface
|
|
61
|
+
`do-in-parallel` genuinely pays.
|
|
@@ -234,6 +234,14 @@ violations will surface as new findings on every run.
|
|
|
234
234
|
2. Verify `state.ui_audit.greenfield == true` implies `state.ui_audit.greenfield_decision` is set.
|
|
235
235
|
3. Write the full object back into the state-file. Audit completes with outcome `done` — the dispatcher's audit gate now passes.
|
|
236
236
|
|
|
237
|
+
## Section index — load on demand
|
|
238
|
+
|
|
239
|
+
Load on demand once the audit needs the pitfall catalog:
|
|
240
|
+
|
|
241
|
+
- [`references/anti-slop-cross-reference.md`](references/anti-slop-cross-reference.md) — Anti-slop cross-reference
|
|
242
|
+
|
|
243
|
+
- [`references/output-and-pitfalls.md`](references/output-and-pitfalls.md) — Output format · Gotcha · Anti-slop cross-reference
|
|
244
|
+
|
|
237
245
|
## Output format
|
|
238
246
|
|
|
239
247
|
1. **`state.ui_audit.components`** — array of component/template descriptors (path, name, kind, exports)
|
|
@@ -273,33 +281,6 @@ tool produces, so the import path is uniform.
|
|
|
273
281
|
that run are absent from the inventory the later ones are checked against.
|
|
274
282
|
Adding a second component in the same run → re-read the component directories
|
|
275
283
|
directly rather than trusting `state.ui_audit.components_found`.
|
|
276
|
-
|
|
277
|
-
## Anti-slop cross-reference
|
|
278
|
-
|
|
279
|
-
When the audit inventory reveals an existing aesthetic direction (dominant color
|
|
280
|
-
scheme, border-radius convention, motion patterns), cross-check the findings
|
|
281
|
-
against
|
|
282
|
-
[`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md).
|
|
283
|
-
If the existing UI already uses a listed anti-pattern, surface it as a design-debt
|
|
284
|
-
finding (separate from the reuse inventory) — flag by entry ID and severity.
|
|
285
|
-
|
|
286
|
-
**What the design step may then do depends on whose aesthetic it is.** These
|
|
287
|
-
are two different situations and the sentence that used to cover both was
|
|
288
|
-
wrong about one of them:
|
|
289
|
-
|
|
290
|
-
| The anti-pattern lives in… | The design step may… |
|
|
291
|
-
|---|---|
|
|
292
|
-
| **The consumer's own legacy UI** (inventoried from the repo) | continue it for consistency, **or** propose a corrective direction change. Both are legitimate; it is their codebase and their debt. |
|
|
293
|
-
| **A supplied spec** (a handed-over artifact, a `design-system.json`, a registered brand token) | **neither.** Build it as given. The finding is recorded as informational, marked `artifact_covered`, and no polish round acts on it. |
|
|
294
|
-
|
|
295
|
-
A corrective direction change against a supplied spec is not a design
|
|
296
|
-
improvement, it is overriding a decision the user already made — the failure
|
|
297
|
-
[`design-fidelity`](../../rules/design-fidelity.md) exists to prevent, arriving
|
|
298
|
-
through the audit's side door. Precedence and its exact scope:
|
|
299
|
-
[`design-fidelity-mechanics`](../../../docs/guidelines/design-fidelity-mechanics.md)
|
|
300
|
-
§ Provided-artifact precedence. Where the two sources disagree, surface the
|
|
301
|
-
conflict rather than picking (fixture `daf-slop-vs-provided`).
|
|
302
|
-
|
|
303
284
|
## Do NOT
|
|
304
285
|
|
|
305
286
|
- Do NOT advance to `directives/ui/design.ts` or `apply.ts` if `state.ui_audit` is empty.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# existing-ui-audit — anti-slop cross-reference
|
|
2
|
+
|
|
3
|
+
> Section-level entry point of the `existing-ui-audit` skill (progressive
|
|
4
|
+
> disclosure, 2026-08-04). Content moved VERBATIM from SKILL.md —
|
|
5
|
+
> load this file when the section index in SKILL.md routes here.
|
|
6
|
+
|
|
7
|
+
## Anti-slop cross-reference
|
|
8
|
+
|
|
9
|
+
When the audit inventory reveals an existing aesthetic direction (dominant color
|
|
10
|
+
scheme, border-radius convention, motion patterns), cross-check the findings
|
|
11
|
+
against
|
|
12
|
+
[`docs/guidelines/design-antipatterns.md`](../../../../docs/guidelines/design-antipatterns.md).
|
|
13
|
+
If the existing UI already uses a listed anti-pattern, surface it as a design-debt
|
|
14
|
+
finding (separate from the reuse inventory) — flag by entry ID and severity.
|
|
15
|
+
|
|
16
|
+
**What the design step may then do depends on whose aesthetic it is.** These
|
|
17
|
+
are two different situations and the sentence that used to cover both was
|
|
18
|
+
wrong about one of them:
|
|
19
|
+
|
|
20
|
+
| The anti-pattern lives in… | The design step may… |
|
|
21
|
+
|---|---|
|
|
22
|
+
| **The consumer's own legacy UI** (inventoried from the repo) | continue it for consistency, **or** propose a corrective direction change. Both are legitimate; it is their codebase and their debt. |
|
|
23
|
+
| **A supplied spec** (a handed-over artifact, a `design-system.json`, a registered brand token) | **neither.** Build it as given. The finding is recorded as informational, marked `artifact_covered`, and no polish round acts on it. |
|
|
24
|
+
|
|
25
|
+
A corrective direction change against a supplied spec is not a design
|
|
26
|
+
improvement, it is overriding a decision the user already made — the failure
|
|
27
|
+
[`design-fidelity`](../../rules/design-fidelity.md) exists to prevent, arriving
|
|
28
|
+
through the audit's side door. Precedence and its exact scope:
|
|
29
|
+
[`design-fidelity-mechanics`](../../../../docs/guidelines/design-fidelity-mechanics.md)
|
|
30
|
+
§ Provided-artifact precedence. Where the two sources disagree, surface the
|
|
31
|
+
conflict rather than picking (fixture `daf-slop-vs-provided`).
|
|
@@ -73,297 +73,12 @@ implementation skill, not from here.
|
|
|
73
73
|
> present an ungrounded pick as grounded, and never record a missing pack as
|
|
74
74
|
> an evidence gap.
|
|
75
75
|
|
|
76
|
-
##
|
|
76
|
+
## Section index — load on demand
|
|
77
77
|
|
|
78
|
-
|
|
78
|
+
Load the reference file whose sections the task needs — never all of them by default:
|
|
79
79
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
├── Header (static)
|
|
83
|
-
├── Navigation (interactive — active state)
|
|
84
|
-
├── Content area
|
|
85
|
-
│ ├── Page heading + actions (static)
|
|
86
|
-
│ ├── Filters (interactive — reactive)
|
|
87
|
-
│ ├── Data display (interactive — table / cards)
|
|
88
|
-
│ └── Pagination (interactive)
|
|
89
|
-
└── Footer (static)
|
|
90
|
-
```
|
|
91
|
-
|
|
92
|
-
The stack-specific mapping (Blade partial vs. Livewire component vs.
|
|
93
|
-
React island vs. Vue SFC) is the apply-step's concern, not this skill's.
|
|
94
|
-
|
|
95
|
-
### When to use what (kind, not framework)
|
|
96
|
-
|
|
97
|
-
| Kind | When | Example |
|
|
98
|
-
|---|---|---|
|
|
99
|
-
| **Static partial** | No interactivity, server-rendered only | Header, footer, static info |
|
|
100
|
-
| **Reusable UI component** | Props-only, no state | Button, badge, card shell |
|
|
101
|
-
| **Stateful component** | Needs server interaction or local state | Forms, tables, filters |
|
|
102
|
-
| **Library primitive** | Standard UI from a design system | Modal, dropdown, input, toast |
|
|
103
|
-
| **Client-only micro-interaction** | No server roundtrip needed | Toggle, accordion, clipboard |
|
|
104
|
-
|
|
105
|
-
### Component granularity
|
|
106
|
-
|
|
107
|
-
- **One stateful component per concern** — don't build mega-components.
|
|
108
|
-
- **Compose with reusable UI components** for shared shells, headers, fields.
|
|
109
|
-
- **Use the project's library primitives first** — never rebuild what the design system already provides (audit findings tell you which).
|
|
110
|
-
- **Extract when used 3+ times** — DRY applies to UI too.
|
|
111
|
-
- **Component workshop when the project is large enough** — for a real, growing shared-component library, isolate and document each reusable component in a component workshop so it stays discoverable and reused, not re-invented; skip it for a small surface of one-offs. Tool-specific setup is a carve-out (Storybook et al.) — see the implementation skill (e.g. [`react-shadcn-ui`](../react-shadcn-ui/SKILL.md) § Component workshop), never a generic mandate.
|
|
112
|
-
|
|
113
|
-
## Form Design
|
|
114
|
-
|
|
115
|
-
### Principles
|
|
116
|
-
|
|
117
|
-
1. **Labels always visible** — no placeholder-only inputs
|
|
118
|
-
2. **Validation on blur + submit** — immediate feedback, not on every keystroke
|
|
119
|
-
3. **Error messages below the field** — red text, specific message
|
|
120
|
-
4. **Required fields marked** — asterisk (*) or "(required)" label
|
|
121
|
-
5. **Logical grouping** — related fields in sections with headings
|
|
122
|
-
6. **Primary action prominent** — submit button stands out, cancel is secondary
|
|
123
|
-
|
|
124
|
-
### Layout patterns
|
|
125
|
-
|
|
126
|
-
| Fields | Layout | When |
|
|
127
|
-
|---|---|---|
|
|
128
|
-
| 1–3 fields | Single column | Simple forms (login, search) |
|
|
129
|
-
| 4–8 fields | Two columns on desktop, single on mobile | Standard CRUD forms |
|
|
130
|
-
| 8+ fields | Sections with headings or tabs/steps | Complex entity forms |
|
|
131
|
-
| Related pairs | Side by side (first/last name, city/zip) | Logically paired fields |
|
|
132
|
-
|
|
133
|
-
### Multi-step forms
|
|
134
|
-
|
|
135
|
-
```
|
|
136
|
-
Step indicator (1 — 2 — 3)
|
|
137
|
-
├── Step 1: Basic info → Next
|
|
138
|
-
├── Step 2: Details → Back / Next
|
|
139
|
-
└── Step 3: Review + Submit → Back / Submit
|
|
140
|
-
```
|
|
141
|
-
|
|
142
|
-
- Show progress indicator (step numbers or progress bar)
|
|
143
|
-
- Allow going back without losing data
|
|
144
|
-
- Validate each step before allowing next
|
|
145
|
-
- Show summary on final step
|
|
146
|
-
|
|
147
|
-
## Table Design
|
|
148
|
-
|
|
149
|
-
### Principles
|
|
150
|
-
|
|
151
|
-
1. **Right-align numbers** — easier to compare
|
|
152
|
-
2. **Left-align text** — natural reading direction
|
|
153
|
-
3. **Sortable columns** — click header to sort
|
|
154
|
-
4. **Sticky header** — visible when scrolling long tables
|
|
155
|
-
5. **Row actions** — edit/delete as icon buttons or dropdown menu
|
|
156
|
-
6. **Empty state** — helpful message when no data, not just blank
|
|
157
|
-
|
|
158
|
-
### Responsive tables
|
|
159
|
-
|
|
160
|
-
| Screen | Strategy |
|
|
161
|
-
|---|---|
|
|
162
|
-
| Desktop (≥1024px) | Full table with all columns |
|
|
163
|
-
| Tablet (768–1023px) | Hide less important columns |
|
|
164
|
-
| Mobile (<768px) | Card layout or horizontal scroll |
|
|
165
|
-
|
|
166
|
-
### Pagination
|
|
167
|
-
|
|
168
|
-
- Default: 25 rows per page
|
|
169
|
-
- Show total count: "Showing 1–25 of 142"
|
|
170
|
-
- Allow page size change (10, 25, 50, 100)
|
|
171
|
-
- Prefer server-side pagination — avoid loading the full set client-side
|
|
172
|
-
|
|
173
|
-
## Responsive Strategy
|
|
174
|
-
|
|
175
|
-
### Breakpoints (Tailwind reference scale)
|
|
176
|
-
|
|
177
|
-
| Prefix | Min width | Target |
|
|
178
|
-
|---|---|---|
|
|
179
|
-
| `sm:` | 640px | Large phones |
|
|
180
|
-
| `md:` | 768px | Tablets |
|
|
181
|
-
| `lg:` | 1024px | Small laptops |
|
|
182
|
-
| `xl:` | 1280px | Desktops |
|
|
183
|
-
| `2xl:` | 1536px | Large screens |
|
|
184
|
-
|
|
185
|
-
### Mobile-first approach
|
|
186
|
-
|
|
187
|
-
1. Design for mobile first (default styles)
|
|
188
|
-
2. Add complexity at larger breakpoints
|
|
189
|
-
3. Test at each breakpoint, not just desktop
|
|
190
|
-
|
|
191
|
-
### Common patterns
|
|
192
|
-
|
|
193
|
-
| Element | Mobile | Desktop |
|
|
194
|
-
|---|---|---|
|
|
195
|
-
| Navigation | Hamburger menu | Sidebar or top nav |
|
|
196
|
-
| Forms | Single column | Two columns |
|
|
197
|
-
| Tables | Cards or scroll | Full table |
|
|
198
|
-
| Actions | Bottom sheet / FAB | Inline buttons |
|
|
199
|
-
| Filters | Collapsible panel | Sidebar or inline |
|
|
200
|
-
|
|
201
|
-
## Accessibility (a11y)
|
|
202
|
-
|
|
203
|
-
### Minimum requirements
|
|
204
|
-
|
|
205
|
-
- **Color contrast:** 4.5:1 for text, 3:1 for large text (WCAG AA)
|
|
206
|
-
- **Keyboard navigation:** All interactive elements reachable via Tab
|
|
207
|
-
- **Focus indicators:** Visible focus ring on all focusable elements
|
|
208
|
-
- **Alt text:** All meaningful images have descriptive alt text
|
|
209
|
-
- **ARIA labels:** Interactive elements without visible text need `aria-label`
|
|
210
|
-
- **Semantic HTML:** Use `<button>`, `<nav>`, `<main>`, `<form>` — not `<div>` for everything
|
|
211
|
-
|
|
212
|
-
### Common mistakes
|
|
213
|
-
|
|
214
|
-
| Mistake | Fix |
|
|
215
|
-
|---|---|
|
|
216
|
-
| `<div onclick>` | Use `<button>` |
|
|
217
|
-
| Color-only status | Add icon or text alongside color |
|
|
218
|
-
| Missing form labels | Add `<label for="...">` |
|
|
219
|
-
| Auto-playing content | Provide pause/stop control |
|
|
220
|
-
| Tiny click targets | Min 44×44px touch target |
|
|
221
|
-
|
|
222
|
-
## Motion — decision-tree and rationale
|
|
223
|
-
|
|
224
|
-
Before adding any animation to a UI element, run through this decision tree:
|
|
225
|
-
|
|
226
|
-
**1. Should this animate at all?**
|
|
227
|
-
- Used 100+ times per day (keyboard shortcut, command palette)? **No animation. Why:** animations on high-frequency interactions feel sluggish; users wait for them on every invocation. Raycast has no open/close animation by design.
|
|
228
|
-
- Triggered by user action with visible result (button → state change)? **Micro-feedback only (< 160ms).** Why: quick enough to feel instant, visible enough to confirm the action.
|
|
229
|
-
- Modal/overlay/sheet entering/exiting? **Animate. Why:** position change needs motion to maintain spatial continuity.
|
|
230
|
-
- Background process with no user action? **No animation.** Why: unexplained motion is disorienting.
|
|
231
|
-
|
|
232
|
-
**2. Which easing?**
|
|
233
|
-
- Entering (element appearing)? **ease-out** (starts fast, slows to rest). Why: the element arriving quickly signals responsiveness; the deceleration feels natural as it settles.
|
|
234
|
-
- Exiting (element disappearing)? **ease-in** (starts slow, accelerates out). Why: the reverse is true — fast exit signals completion.
|
|
235
|
-
- **Never ease-in for entering elements.** Why: ease-in delays the initial movement — the exact moment the user is watching most closely — making it feel slow even at the same total duration.
|
|
236
|
-
- **Never bounce or elastic easing in UI.** Why: bounce draws attention to the animation itself, not the content; it feels dated.
|
|
237
|
-
|
|
238
|
-
**3. How long?**
|
|
239
|
-
- Button/micro-feedback: 100–160ms. Tooltip: 100ms. Dropdown open: 150–200ms. Modal: 200–350ms. Page transition: 300–500ms. Above 500ms: almost never.
|
|
240
|
-
- **Never animate layout properties** (width, height, top, left, padding). Why: triggers browser layout recalculation on every frame; always solvable with `transform`.
|
|
241
|
-
- **Always add `@media (prefers-reduced-motion: reduce)`** — gentler animation (reduced distance/opacity), NOT display:none. Why: vestibular disorders make motion UI unusable; reducing is better than removing.
|
|
242
|
-
|
|
243
|
-
**4. What to animate?**
|
|
244
|
-
Animate `transform` and `opacity` only. Why: these run on the GPU compositor thread, not the main thread; they never trigger layout or paint.
|
|
245
|
-
`scale(0)` → `scale(1)` is wrong. Why: nothing in the real world appears from nothing. Use `scale(0.95)` + `opacity: 0` → `scale(1)` + `opacity: 1` instead.
|
|
246
|
-
|
|
247
|
-
## UX Principles
|
|
248
|
-
|
|
249
|
-
1. **Feedback** — Every action gets a response (toast, loading state, success message). **Why:** users interpret no feedback as failure.
|
|
250
|
-
2. **Forgiveness** — Undo beats confirmation dialogs. Users click through confirmations mindlessly. **Why:** remove destructively then show undo toast; actually delete after toast expires.
|
|
251
|
-
3. **Consistency** — Same patterns for same interactions across the app. **Why:** predictability reduces cognitive load; inconsistency forces users to re-learn.
|
|
252
|
-
4. **Progressive disclosure** — Show basics first, details on demand. **Why:** premature complexity overwhelms; reveal information as it becomes relevant.
|
|
253
|
-
5. **Loading states** — Skeleton screens preferred over spinners. **Why:** skeletons reduce perceived wait time by showing structure immediately.
|
|
254
|
-
6. **Error recovery** — Clear error messages with suggested actions. **Why:** "something went wrong" gives the user nothing to do; a specific message with a next step reduces support burden.
|
|
255
|
-
|
|
256
|
-
## Craft details — typography & imagery
|
|
257
|
-
|
|
258
|
-
- **`text-wrap: pretty` on body copy** — avoids widows/orphans without manual
|
|
259
|
-
breaks; cheap, no layout risk. (Display headlines: `text-wrap: balance`.)
|
|
260
|
-
- **Honest placeholders over weak assets** — when the real image/illustration
|
|
261
|
-
is missing, use a striped placeholder with a monospace size label
|
|
262
|
-
(`repeating-linear-gradient(45deg, #E5E5E5 0 10px, #F5F5F5 10px 20px)` +
|
|
263
|
-
`product shot (1200×800)`) instead of a hand-drawn SVG or stock-ish filler.
|
|
264
|
-
A placeholder signals "asset needed"; a weak illustration signals nobody
|
|
265
|
-
had the asset. Never Lorem-ipsum copy in review-bound output
|
|
266
|
-
(per `output-discipline`) — use short label-style skeleton copy.
|
|
267
|
-
|
|
268
|
-
## Presenting variants
|
|
269
|
-
|
|
270
|
-
This skill produces ONE refined solution by default. **Plan the variation
|
|
271
|
-
decision before generating** — do not reflexively emit one generic design when
|
|
272
|
-
exploration was asked, nor spam options when one production answer was asked.
|
|
273
|
-
|
|
274
|
-
- **Decide whether to vary (ask only if ambiguous).** For ambiguous creative
|
|
275
|
-
work, decide the variation count and the axis that varies — visual direction,
|
|
276
|
-
UX flow, interaction model, copy, density, or brand strictness. Ask about
|
|
277
|
-
count + axis only when the choice changes the work materially; for a clear
|
|
278
|
-
implementation task, proceed with one answer. (fixture: `daf-requested-variations`.)
|
|
279
|
-
- **Variation floors.** When the user asks to explore, produce **two to three
|
|
280
|
-
meaningfully different** options along the stated axis — different *decisions*,
|
|
281
|
-
not the same layout recoloured. When the user asks for one production answer,
|
|
282
|
-
produce one; no decorative option spam. (fixtures: `daf-requested-variations`,
|
|
283
|
-
`daf-unwanted-variations`.)
|
|
284
|
-
- **Canvas / exploration contract (host-neutral).** Presenting side-by-side
|
|
285
|
-
concepts: give each a **stable frame label**, keep frames flat (no nested
|
|
286
|
-
cards), use generous spacing, and — on tools with a canvas — export-safe
|
|
287
|
-
coordinates so the layout survives export. Same labelled-frames shape whether
|
|
288
|
-
the host has a real canvas or just stacked sections.
|
|
289
|
-
- **Cost / UX tie-breaker.** Ask about the axis only when it changes the work
|
|
290
|
-
materially; otherwise choose a strong default and **document the axis used in
|
|
291
|
-
the handoff** ("explored along visual-direction; density held constant").
|
|
292
|
-
|
|
293
|
-
Hand off the actual variation **mechanics** — the basic→bold method and the
|
|
294
|
-
single-file tweak-panel (CSS custom properties + floating "Tweaks" panel +
|
|
295
|
-
`localStorage`) — to [`design-variations`](../design-variations/SKILL.md): this
|
|
296
|
-
section owns the *planning decision*, that skill owns the *execution*.
|
|
297
|
-
|
|
298
|
-
## Cross-task design memory — read DESIGN.md / PRODUCT.md first
|
|
299
|
-
|
|
300
|
-
Before applying any heuristics from this reference, check the project root
|
|
301
|
-
for `DESIGN.md` and/or `PRODUCT.md` (written by `design-system-capture`):
|
|
302
|
-
|
|
303
|
-
- `DESIGN.md` present → use its captured radius/shadow/motion/spacing as
|
|
304
|
-
project constraints. The heuristics in this skill are **fallbacks for
|
|
305
|
-
gaps**, not overrides for captured decisions.
|
|
306
|
-
- `PRODUCT.md` present → honor its interaction patterns (empty-state approach,
|
|
307
|
-
mutation feedback policy, filter persistence) in any UI design that touches
|
|
308
|
-
those surfaces.
|
|
309
|
-
|
|
310
|
-
Flag any new decision for future capture: *"This establishes a new pattern —
|
|
311
|
-
suggest adding to PRODUCT.md: [pattern description]."*
|
|
312
|
-
|
|
313
|
-
## Register — brand vs product
|
|
314
|
-
|
|
315
|
-
Before applying heuristics, determine the register (see
|
|
316
|
-
[`docs/guidelines/design-modes.md`](../../../docs/guidelines/design-modes.md)):
|
|
317
|
-
brand mode (impression-first) vs product mode (task-first). Form-heavy, table-heavy,
|
|
318
|
-
and dashboard surfaces are almost always product mode — favour the standard
|
|
319
|
-
patterns in this skill (Form Design, Table Design) over expressive variance.
|
|
320
|
-
Marketing/landing surfaces are brand mode — let the Aesthetic-direction section
|
|
321
|
-
commit to a deliberate, distinctive direction.
|
|
322
|
-
|
|
323
|
-
## Design Read — articulate intent before generating
|
|
324
|
-
|
|
325
|
-
When this reference is cited for a UI planning task, emit one line declaring
|
|
326
|
-
the design read before any heuristics are applied:
|
|
327
|
-
|
|
328
|
-
```
|
|
329
|
-
Reading this as: <page-kind> for <audience>, <vibe> language, leaning <design-system>.
|
|
330
|
-
```
|
|
331
|
-
|
|
332
|
-
**If context is incomplete:** state so and proceed exploratory — do NOT block.
|
|
333
|
-
|
|
334
|
-
**Anti-Default Discipline:** Before committing to any layout or component
|
|
335
|
-
pattern, cross-check your first impulse against
|
|
336
|
-
[`design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md) —
|
|
337
|
-
the L1/L2 "AI landing page" layout (centered hero + 3-column grid + CTA), the
|
|
338
|
-
V1 side-stripe card, the T7 default-font pick, and V2 decorative glassmorphism.
|
|
339
|
-
If a tell was the first impulse, choose a different approach or explicitly
|
|
340
|
-
justify why this brief calls for it. (The full pre-proposal scan is under
|
|
341
|
-
*Anti-slop discipline* below.)
|
|
342
|
-
|
|
343
|
-
**Carve-out — a supplied artifact is the spec, not a first impulse.** This
|
|
344
|
-
discipline governs what *you* reach for. When the user hands over a finished
|
|
345
|
-
artifact, the choices it makes are not your impulses and the justify-or-change
|
|
346
|
-
burden does not apply to them: build them as given. The carve-out is scoped to
|
|
347
|
-
decisions the artifact actually covers — anything it leaves open (a state it
|
|
348
|
-
never shows, a surface it never had) is your first impulse again and gets the
|
|
349
|
-
full scan. See
|
|
350
|
-
[`design-fidelity-mechanics`](../../../docs/guidelines/design-fidelity-mechanics.md)
|
|
351
|
-
§ Provided-artifact precedence.
|
|
352
|
-
|
|
353
|
-
## Aesthetic direction
|
|
354
|
-
|
|
355
|
-
Audit-pinned tokens and components always take precedence (see `existing-ui-audit`). When the audit pins an aesthetic, honor it without deviation. When the audit shows **no pinned aesthetic** — greenfield surface, marketing landing page, brand-new feature without design-system precedent — the design brief is allowed (and expected) to commit to a deliberate direction instead of defaulting to safe centered hero + 3-column features + CTA.
|
|
356
|
-
|
|
357
|
-
Typography pairings (73 curated heading/body combinations with Google
|
|
358
|
-
Fonts URLs + Tailwind config) and icon-system guidance (104 Phosphor
|
|
359
|
-
entries with import code) come grounded from
|
|
360
|
-
[`design-intelligence`](../design-intelligence/SKILL.md)
|
|
361
|
-
(`--domain typography`, `--domain icons`) — query before picking from
|
|
362
|
-
memory.
|
|
363
|
-
|
|
364
|
-
Pick one direction up front and let composition, typography, and color follow from it. Avoid the "neutral AI default": uniform grid, system fonts as the visible body face, purple-to-blue gradients on white, predictable spacing. A direction that fits the brand intent (editorial / brutalist / refined / playful / retro / maximal / minimal / etc.) and is consistent across the page beats hedging.
|
|
365
|
-
|
|
366
|
-
Surface the chosen direction in the design brief as a one-line statement (e.g. `aesthetic: editorial-magazine — asymmetric grid, serif display + sans body, generous gutters`). The apply step (`react-shadcn-ui` / `blade-ui` / `livewire` / `flux`) reads this line and matches typography, spacing, and motion to it; if no line is present, the apply step uses project defaults.
|
|
80
|
+
- [`references/design-patterns.md`](references/design-patterns.md) — Component Architecture · Form Design · Table Design · Responsive Strategy · Accessibility (a11y) · Motion — decision-tree and rationale · UX Principles · Craft details — typography & imagery · Presenting variants
|
|
81
|
+
- [`references/design-read-and-memory.md`](references/design-read-and-memory.md) — Cross-task design memory — read DESIGN.md / PRODUCT.md first · Register — brand vs product · Design Read — articulate intent before generating · Aesthetic direction
|
|
367
82
|
|
|
368
83
|
## Procedure
|
|
369
84
|
|