@event4u/agent-config 7.1.0 → 7.2.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 +2 -1
- package/CHANGELOG.md +39 -0
- package/README.md +1 -1
- package/dist/agent-src/rules/brand-source-of-truth.md +10 -0
- package/dist/agent-src/rules/delegation-policy.md +1 -0
- package/dist/agent-src/rules/legal-safety-floor.md +42 -4
- package/dist/agent-src/rules/output-discipline.md +85 -0
- package/dist/agent-src/rules/telegraph-speak.md +4 -1
- package/dist/agent-src/rules/token-budget-discipline.md +94 -0
- package/dist/agent-src/skills/accessibility-auditor/SKILL.md +20 -5
- package/dist/agent-src/skills/blade-ui/SKILL.md +9 -0
- package/dist/agent-src/skills/contract-review/SKILL.md +3 -2
- package/dist/agent-src/skills/dashboard-design/SKILL.md +21 -5
- package/dist/agent-src/skills/design-intelligence/SKILL.md +96 -0
- package/dist/agent-src/skills/design-review/SKILL.md +83 -0
- package/dist/agent-src/skills/design-system-capture/SKILL.md +234 -0
- package/dist/agent-src/skills/design-tokens/SKILL.md +1 -0
- package/dist/agent-src/skills/dpa-review/SKILL.md +3 -2
- package/dist/agent-src/skills/existing-ui-audit/SKILL.md +15 -4
- package/dist/agent-src/skills/fe-design/SKILL.md +98 -16
- package/dist/agent-src/skills/flux/SKILL.md +8 -0
- package/dist/agent-src/skills/iconography/SKILL.md +1 -0
- package/dist/agent-src/skills/legal-intake-triage/SKILL.md +3 -2
- package/dist/agent-src/skills/legal-practice-profile/SKILL.md +3 -2
- package/dist/agent-src/skills/livewire/SKILL.md +8 -0
- package/dist/agent-src/skills/nda-triage/SKILL.md +3 -2
- package/dist/agent-src/skills/react-shadcn-ui/SKILL.md +21 -9
- package/dist/agent-src/skills/skill-writing/SKILL.md +18 -0
- package/dist/agent-src/skills/subagent-orchestration/SKILL.md +7 -10
- package/dist/agent-src/skills/tailwind-engineer/SKILL.md +17 -7
- package/dist/agent-src/skills/typography-system/SKILL.md +14 -0
- package/dist/agent-src/skills/ui-component-architect/SKILL.md +9 -0
- package/dist/discovery/deprecation-report.md +1 -1
- package/dist/discovery/discovery-manifest.json +123 -59
- package/dist/discovery/discovery-manifest.json.sha256 +1 -1
- package/dist/discovery/discovery-manifest.summary.md +8 -8
- package/dist/discovery/orphan-report.md +1 -1
- package/dist/discovery/packs.json +18 -15
- package/dist/discovery/trust-report.md +5 -5
- package/dist/discovery/workspaces.json +15 -12
- package/dist/mcp/registry-manifest.json +2 -2
- package/dist/router.json +1 -1
- package/dist/server/routes/wizard.js +4 -3
- package/dist/server/routes/wizard.js.map +1 -1
- package/dist/server/schemas/settings.js +9 -0
- package/dist/server/schemas/settings.js.map +1 -1
- package/dist/ui/assets/{index-CoQo90sz.js → index-UjcTG_9O.js} +2 -2
- package/dist/ui/assets/index-UjcTG_9O.js.map +1 -0
- package/dist/ui/index.html +1 -1
- package/docs/RELEASE_STORY_TEMPLATE.md +37 -0
- package/docs/architecture.md +3 -3
- package/docs/contracts/capability-boundary.md +64 -0
- package/docs/contracts/discovery-manifest.schema.json +2 -2
- package/docs/contracts/package-self-orientation.md +3 -0
- package/docs/contracts/subagent-boundary.md +54 -0
- package/docs/decisions/ADR-013-discovery-frontmatter-contract.md +13 -0
- package/docs/decisions/ADR-107-legal-domain-pack-adoption.md +19 -0
- package/docs/getting-started.md +1 -1
- package/docs/guidelines/agent-infra/domain-pack-architecture.md +1 -0
- package/docs/guidelines/design-antipatterns-triggers.json +17 -0
- package/docs/guidelines/design-antipatterns.md +170 -0
- package/docs/guidelines/design-modes.md +97 -0
- package/package.json +1 -1
- package/src/config/agent-settings.template.yml +31 -0
- package/src/config/discovery/packs.yml +16 -5
- package/src/config/discovery/workspaces.yml +4 -4
- package/src/scripts/check_trunk_drift.ts +67 -0
- package/src/scripts/lint_design_quality.ts +321 -0
- package/src/scripts/lint_discovery_vocabulary.ts +4 -4
- package/src/scripts/lint_legal_pack.ts +62 -4
- package/src/scripts/lint_output_slop.ts +223 -0
- package/src/scripts/lint_pack_risk_class.ts +79 -0
- package/src/scripts/schemas/agent-settings.schema.json +12 -0
- package/src/scripts/schemas/skill.schema.json +5 -0
- package/dist/ui/assets/index-CoQo90sz.js.map +0 -1
|
@@ -36,6 +36,12 @@ A **live preview URL** is required for testing.
|
|
|
36
36
|
|
|
37
37
|
## Procedure: Design review
|
|
38
38
|
|
|
39
|
+
1. **Inspect the PR and preview** — Read the PR description, diff, and identify changed components/pages; capture a baseline screenshot of the preview URL.
|
|
40
|
+
2. **Walk the interactions** — Run Phase 1; cover hover/focus/active/disabled, keyboard, loading, and form error states.
|
|
41
|
+
3. **Cover responsiveness, polish, a11y, robustness** — Run Phases 2–5 in order; record findings per phase.
|
|
42
|
+
4. **Audit code-health and content** — Run Phases 6–7; check tokens, dead styles, copy, console warnings.
|
|
43
|
+
5. **Verify and report** — Consolidate findings in the report structure; classify each as Blocker / High / Medium / Nit before posting.
|
|
44
|
+
|
|
39
45
|
### Phase 0: Preparation
|
|
40
46
|
|
|
41
47
|
- Read PR description and git diff.
|
|
@@ -110,6 +116,61 @@ Test at three viewports:
|
|
|
110
116
|
- No placeholder text left in production.
|
|
111
117
|
- Check browser console for JavaScript errors or warnings.
|
|
112
118
|
|
|
119
|
+
## Reviewer posture
|
|
120
|
+
|
|
121
|
+
**Approval is earned, not assumed. Default to flagging.**
|
|
122
|
+
|
|
123
|
+
A design review is a skeptic's pass. The default verdict for every element
|
|
124
|
+
is "this needs to justify itself" — not "this is probably fine." Approve
|
|
125
|
+
explicitly when you have examined the evidence and found it sound.
|
|
126
|
+
|
|
127
|
+
This posture prevents the failure of "nothing to report" reviews that miss
|
|
128
|
+
real issues because the reviewer defaulted to charitable assumptions.
|
|
129
|
+
|
|
130
|
+
## Subtraction-first remedial hierarchy
|
|
131
|
+
|
|
132
|
+
When a finding warrants a remediation recommendation, prefer in this order:
|
|
133
|
+
|
|
134
|
+
1. **Delete** — remove the element, animation, pattern, or copy entirely
|
|
135
|
+
2. **Reduce** — make it smaller, shorter, subtler, less frequent
|
|
136
|
+
3. **Fix the specific issue** — change easing, origin, duration, contrast, font
|
|
137
|
+
4. **Make it interruptible** (for motion) — switch to transition/spring
|
|
138
|
+
5. **Move to GPU** (for motion) — animate only transform/opacity
|
|
139
|
+
6. **Polish** — the lowest-leverage fix; only if the above don't apply
|
|
140
|
+
|
|
141
|
+
*"Delete the animation" is always the first option to consider, even before
|
|
142
|
+
suggesting a different easing curve.* The same applies to decorative elements,
|
|
143
|
+
excessive copy, and redundant UI chrome.
|
|
144
|
+
|
|
145
|
+
## Before / After / Why output format
|
|
146
|
+
|
|
147
|
+
When reporting a finding with a specific remediation, use this table format:
|
|
148
|
+
|
|
149
|
+
| Field | Content |
|
|
150
|
+
|---|---|
|
|
151
|
+
| **Before** | The current state (quote the code, value, or describe the pattern) |
|
|
152
|
+
| **After** | The corrected state (specific value or alternative) |
|
|
153
|
+
| **Why** | The mechanism: why is Before wrong and After better? (one sentence, states the principle) |
|
|
154
|
+
|
|
155
|
+
**Wrong format** (do not use):
|
|
156
|
+
```
|
|
157
|
+
Before:
|
|
158
|
+
button { transition: all 0.3s ease; }
|
|
159
|
+
After:
|
|
160
|
+
button { transition: transform 0.2s ease-out, opacity 0.2s ease-out; }
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
**Right format:**
|
|
164
|
+
|
|
165
|
+
| | |
|
|
166
|
+
|---|---|
|
|
167
|
+
| **Before** | `transition: all 0.3s ease` |
|
|
168
|
+
| **After** | `transition: transform 0.2s ease-out, opacity 0.2s ease-out` |
|
|
169
|
+
| **Why** | `transition: all` animates layout properties on every state change, causing browser reflow; enumerate only the properties that move. |
|
|
170
|
+
|
|
171
|
+
The Why column carries the reasoning — it's the part that teaches the developer
|
|
172
|
+
and prevents the same finding from recurring.
|
|
173
|
+
|
|
113
174
|
## Communication principles
|
|
114
175
|
|
|
115
176
|
### Problems over prescriptions
|
|
@@ -224,6 +285,28 @@ This is especially useful when the user provides a screenshot or Figma export as
|
|
|
224
285
|
- The model tends to suggest accessibility improvements that break the existing design system.
|
|
225
286
|
- "Best practice" is not always the right choice — sometimes "good enough" ships faster.
|
|
226
287
|
|
|
288
|
+
## Anti-slop scan
|
|
289
|
+
|
|
290
|
+
During any design review, load
|
|
291
|
+
[`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md)
|
|
292
|
+
as a reference. After the structured review phases, add an explicit
|
|
293
|
+
**Anti-Slop Check** section to the review output:
|
|
294
|
+
|
|
295
|
+
1. List any patterns from the catalog that appear in the reviewed UI (cite by
|
|
296
|
+
entry ID, e.g. V1, T2, C1).
|
|
297
|
+
2. For each finding: note whether an override condition is in effect (if yes,
|
|
298
|
+
verify it is stated in the design brief; if not, flag as a finding).
|
|
299
|
+
3. Run the AI-slop originality self-test on the overall aesthetic direction.
|
|
300
|
+
Report the result (pass / flag / fail) with one sentence of evidence.
|
|
301
|
+
|
|
302
|
+
For the **objective quality floors** (WCAG contrast, font-size, line-length,
|
|
303
|
+
reduced-motion, heading hierarchy, focus indicator), do NOT eyeball them —
|
|
304
|
+
cite [`lint_design_quality`](../../../src/scripts/lint_design_quality.ts)
|
|
305
|
+
output for the consumer project (Q1–Q6 in the catalog). The review owns the
|
|
306
|
+
*subjective* anti-slop judgment (Visual / Typography / Color / Layout taste);
|
|
307
|
+
the linter owns the *objective* floors; `accessibility-auditor` owns the WCAG
|
|
308
|
+
*audit method*. Cite, don't re-derive.
|
|
309
|
+
|
|
227
310
|
## Do NOT
|
|
228
311
|
|
|
229
312
|
- Do NOT skip accessibility testing — it's not optional.
|
|
@@ -0,0 +1,234 @@
|
|
|
1
|
+
---
|
|
2
|
+
model_tier: inherit
|
|
3
|
+
name: design-system-capture
|
|
4
|
+
description: "Write and maintain DESIGN.md + PRODUCT.md — captures visual decisions and interaction patterns so design tasks stay consistent across sessions without re-scanning past work."
|
|
5
|
+
domain: engineering
|
|
6
|
+
personas:
|
|
7
|
+
- frontend-engineer
|
|
8
|
+
workspaces:
|
|
9
|
+
- engineering
|
|
10
|
+
packs:
|
|
11
|
+
- frontend-design
|
|
12
|
+
token_budget_class: rich
|
|
13
|
+
execution:
|
|
14
|
+
type: manual
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
# design-system-capture
|
|
18
|
+
|
|
19
|
+
> Solves "design amnesia" — the failure mode where every AI design task
|
|
20
|
+
> re-invents visual patterns (radius, shadows, motion, spacing) and
|
|
21
|
+
> interaction patterns (destructive-action handling, optimistic UI, filter
|
|
22
|
+
> persistence) because the agent has no cross-task memory of decisions
|
|
23
|
+
> already made.
|
|
24
|
+
>
|
|
25
|
+
> **Boundary:** `brand-to-tokens` extracts *primitives* (colors, font
|
|
26
|
+
> families → DTCG tokens). `existing-ui-audit` inventories *what exists*.
|
|
27
|
+
> **This skill captures *usage decisions*:** "we use 8px radius for
|
|
28
|
+
> elevated surfaces", "all destructive actions require typed confirmation".
|
|
29
|
+
> They are complementary, not redundant.
|
|
30
|
+
>
|
|
31
|
+
> Gated by `tokens.rich_skills` in `.agent-settings.yml` (default `on`).
|
|
32
|
+
> If `off`, skip rich context loading and work from brief alone.
|
|
33
|
+
|
|
34
|
+
## Why this skill is rich
|
|
35
|
+
|
|
36
|
+
DESIGN.md and PRODUCT.md serve as the project's design memory. To write
|
|
37
|
+
useful capture documents and to read/apply them effectively, the agent
|
|
38
|
+
needs full templates with worked examples showing what a well-structured
|
|
39
|
+
DESIGN.md and PRODUCT.md look like in practice. A condensed version that
|
|
40
|
+
says "write down your design decisions" produces documents too vague to
|
|
41
|
+
be useful. The worked examples teach agents both the *vocabulary*
|
|
42
|
+
(elevation, motion strategy, destructive-action policy) and the
|
|
43
|
+
*specificity level* that makes these documents actionable across tasks.
|
|
44
|
+
|
|
45
|
+
## When to use
|
|
46
|
+
|
|
47
|
+
- Starting a new consumer project (initial capture, run once early)
|
|
48
|
+
- After 2+ design tasks in the same project (update to capture what was decided)
|
|
49
|
+
- When a subsequent design task produces inconsistent results (audit and reconcile)
|
|
50
|
+
- Explicitly asked: "capture the design system", "write a DESIGN.md", "document our patterns"
|
|
51
|
+
|
|
52
|
+
## The two documents
|
|
53
|
+
|
|
54
|
+
### `DESIGN.md` — visual-system decisions
|
|
55
|
+
|
|
56
|
+
Captures the *visual usage decisions* (not token primitives) that agents
|
|
57
|
+
should apply consistently across all UI tasks in this project. Unlike
|
|
58
|
+
`.tokens.json` (which records what a color value IS), DESIGN.md records
|
|
59
|
+
*how and when to use it*.
|
|
60
|
+
|
|
61
|
+
**Format:**
|
|
62
|
+
|
|
63
|
+
```markdown
|
|
64
|
+
# DESIGN.md — [Project name] visual system
|
|
65
|
+
|
|
66
|
+
> AI-readable project design memory. Update after each design decision.
|
|
67
|
+
> Last updated: [date]
|
|
68
|
+
|
|
69
|
+
## Design philosophy
|
|
70
|
+
One sentence: [density/formality/complexity philosophy]
|
|
71
|
+
Example: "Information-dense dashboard; optimize for power users, not casual exploration."
|
|
72
|
+
|
|
73
|
+
## Visual system
|
|
74
|
+
|
|
75
|
+
### Elevation and radius
|
|
76
|
+
- Elevated surfaces (modals, sheets, dropdowns): [X]px radius, [shadow-spec]
|
|
77
|
+
- Inline elements (cards, chips): [X]px radius
|
|
78
|
+
- Buttons: [X]px radius
|
|
79
|
+
|
|
80
|
+
### Shadows
|
|
81
|
+
- Elevated: [box-shadow value]
|
|
82
|
+
- Floating (tooltips, popovers): [box-shadow value]
|
|
83
|
+
- None (flat cards): [confirm]
|
|
84
|
+
|
|
85
|
+
### Motion
|
|
86
|
+
- Overlays and modals: [spring / easing spec + duration]
|
|
87
|
+
- Micro-interactions (button feedback, toggles): [duration + easing]
|
|
88
|
+
- Page transitions: [strategy or "none"]
|
|
89
|
+
|
|
90
|
+
### Spacing
|
|
91
|
+
- Base unit: [X]px
|
|
92
|
+
- Card padding: [spec]
|
|
93
|
+
- Section gap: [spec]
|
|
94
|
+
- Tight grouping: [spec]
|
|
95
|
+
|
|
96
|
+
### Color usage
|
|
97
|
+
- Primary action: [token name]
|
|
98
|
+
- Destructive: [token name]
|
|
99
|
+
- Surface hierarchy: [primary bg → secondary bg → elevated bg]
|
|
100
|
+
|
|
101
|
+
## Stack and conventions
|
|
102
|
+
- CSS approach: [Tailwind / CSS modules / styled-components / etc.]
|
|
103
|
+
- Component primitives: [shadcn / Radix / Headless UI / custom]
|
|
104
|
+
- Icon system: [Phosphor / Heroicons / Lucide / etc.]
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
### `PRODUCT.md` — cross-feature interaction patterns
|
|
108
|
+
|
|
109
|
+
Captures *interaction decisions* that should be consistent across features.
|
|
110
|
+
Unlike a feature spec (which describes one feature), PRODUCT.md captures
|
|
111
|
+
patterns that apply everywhere.
|
|
112
|
+
|
|
113
|
+
**Format:**
|
|
114
|
+
|
|
115
|
+
```markdown
|
|
116
|
+
# PRODUCT.md — [Project name] interaction patterns
|
|
117
|
+
|
|
118
|
+
> AI-readable cross-feature pattern memory. Update when a new pattern is established.
|
|
119
|
+
> Last updated: [date]
|
|
120
|
+
|
|
121
|
+
## Destructive actions
|
|
122
|
+
Policy: [typed confirmation ("DELETE") / dialog with verb button / undo toast / etc.]
|
|
123
|
+
Example: "All destructive actions require the user to type 'DELETE' or the resource name."
|
|
124
|
+
|
|
125
|
+
## Mutation feedback
|
|
126
|
+
Policy: [optimistic UI + inline undo / loading spinner / success toast / etc.]
|
|
127
|
+
Undo window: [N seconds, or "not applicable"]
|
|
128
|
+
Example: "Optimistic UI for all mutations; inline undo toast for 5 seconds, then commit."
|
|
129
|
+
|
|
130
|
+
## Filter and sort persistence
|
|
131
|
+
Policy: [URL params / localStorage / session / not persisted]
|
|
132
|
+
Restore on load: [yes / no]
|
|
133
|
+
|
|
134
|
+
## Empty states
|
|
135
|
+
Approach: [illustration + CTA / text only / skeleton / etc.]
|
|
136
|
+
Example: "Illustration + primary CTA for empty lists; text-only for zero-search-results."
|
|
137
|
+
|
|
138
|
+
## Error handling
|
|
139
|
+
Approach: [inline field errors / toast / error boundary / etc.]
|
|
140
|
+
Network errors: [retry + message / fail fast / etc.]
|
|
141
|
+
|
|
142
|
+
## Navigation and routing
|
|
143
|
+
Pattern: [SPA / MPA / hybrid / etc.]
|
|
144
|
+
Active state: [how active nav items are marked]
|
|
145
|
+
|
|
146
|
+
## Mental model
|
|
147
|
+
One sentence: [how the product conceptualizes itself to the user]
|
|
148
|
+
Example: "Dashboard = control panel for power users, not an exploration space."
|
|
149
|
+
```
|
|
150
|
+
|
|
151
|
+
## Procedure
|
|
152
|
+
|
|
153
|
+
### Step 1 — Assess what exists
|
|
154
|
+
|
|
155
|
+
1. Check if `DESIGN.md` and `PRODUCT.md` already exist in the project root.
|
|
156
|
+
2. If they exist: read both → skip to Step 3 (Update).
|
|
157
|
+
3. If they don't exist: run `existing-ui-audit` (if not already done for this session) to inventory existing components, tokens, and conventions → proceed to Step 2.
|
|
158
|
+
|
|
159
|
+
### Step 2 — Create (first run)
|
|
160
|
+
|
|
161
|
+
1. **Extract visual decisions from the audit** (`state.ui_audit`): dominant
|
|
162
|
+
radius values, shadow patterns, spacing conventions, motion patterns.
|
|
163
|
+
Fill the DESIGN.md template above with the observed values. Mark
|
|
164
|
+
un-observed sections as `TBD`.
|
|
165
|
+
2. **Extract interaction decisions from the codebase**: scan for delete
|
|
166
|
+
confirmation patterns, toast/feedback patterns, filter/URL persistence.
|
|
167
|
+
Fill the PRODUCT.md template. Mark un-observed sections as `TBD`.
|
|
168
|
+
3. Write `DESIGN.md` and `PRODUCT.md` to the project root.
|
|
169
|
+
4. Surface a one-paragraph summary: what was captured, what is still TBD,
|
|
170
|
+
and what action the user should take (review and correct the TBDs).
|
|
171
|
+
|
|
172
|
+
### Step 3 — Update (subsequent runs)
|
|
173
|
+
|
|
174
|
+
1. Read existing `DESIGN.md` and `PRODUCT.md`.
|
|
175
|
+
2. Identify any decisions made in recent tasks that aren't yet captured
|
|
176
|
+
(e.g., a modal was built with 12px radius — add that to DESIGN.md).
|
|
177
|
+
3. Correct any TBDs that are now resolved.
|
|
178
|
+
4. Update the "Last updated" date.
|
|
179
|
+
5. Output a diff summary: what changed and why.
|
|
180
|
+
|
|
181
|
+
## How the design skills consume these documents
|
|
182
|
+
|
|
183
|
+
When `DESIGN.md` or `PRODUCT.md` is present in the project root:
|
|
184
|
+
|
|
185
|
+
- **`design-intelligence`** and **`fe-design`**: read DESIGN.md at the
|
|
186
|
+
start of any design task — use the captured decisions as project
|
|
187
|
+
constraints that override corpus suggestions.
|
|
188
|
+
- **`ui-component-architect`**: read DESIGN.md for radius/shadow/motion
|
|
189
|
+
conventions before proposing any new component.
|
|
190
|
+
- **`existing-ui-audit`**: when a full audit is impractical (large project),
|
|
191
|
+
read DESIGN.md as a proxy for "what this project's conventions are".
|
|
192
|
+
|
|
193
|
+
The boundary from `brand-to-tokens`:
|
|
194
|
+
- `.tokens.json` carries primitive values (gray-700 = #374151)
|
|
195
|
+
- DESIGN.md carries usage decisions (elevated surfaces use 8px radius,
|
|
196
|
+
not 4px or 12px)
|
|
197
|
+
Both are consumed together; DESIGN.md takes precedence for usage questions.
|
|
198
|
+
|
|
199
|
+
## Gotcha
|
|
200
|
+
|
|
201
|
+
- **Over-writing instead of diff-updating** — the most common failure.
|
|
202
|
+
Always read existing `DESIGN.md`/`PRODUCT.md` before writing; carry
|
|
203
|
+
all existing decisions forward and only add/correct. Losing prior
|
|
204
|
+
captured history is worse than capturing nothing.
|
|
205
|
+
- **Copying tokens into DESIGN.md** — DESIGN.md is NOT a copy of
|
|
206
|
+
`.tokens.json`. It captures *usage decisions* ("8px radius on elevated
|
|
207
|
+
surfaces"), not primitive values ("gray-700 = #374151"). The
|
|
208
|
+
distinction is what makes DESIGN.md actionable.
|
|
209
|
+
- **Capturing feature-specific behavior** — PRODUCT.md is for patterns
|
|
210
|
+
that repeat across 2+ features. A delete-confirmation pattern in one
|
|
211
|
+
form does NOT belong in PRODUCT.md until it appears in at least two
|
|
212
|
+
independent features.
|
|
213
|
+
|
|
214
|
+
## Do NOT
|
|
215
|
+
|
|
216
|
+
- Do NOT overwrite DESIGN.md/PRODUCT.md without first reading and diffing
|
|
217
|
+
the existing content — accumulated history is the value.
|
|
218
|
+
- Do NOT make DESIGN.md a copy of `.tokens.json` — it captures decisions,
|
|
219
|
+
not token definitions.
|
|
220
|
+
- Do NOT capture feature-specific behavior in PRODUCT.md — only patterns
|
|
221
|
+
that repeat across multiple features.
|
|
222
|
+
- Do NOT mark a decision as captured without evidence from the actual codebase.
|
|
223
|
+
|
|
224
|
+
## Output format
|
|
225
|
+
|
|
226
|
+
On create:
|
|
227
|
+
1. Write `DESIGN.md` to the project root with the extracted visual decisions.
|
|
228
|
+
2. Write `PRODUCT.md` to the project root with the extracted interaction patterns.
|
|
229
|
+
3. Surface a one-paragraph summary of what was captured and what is TBD.
|
|
230
|
+
4. List any questions where the existing code is ambiguous.
|
|
231
|
+
|
|
232
|
+
On update:
|
|
233
|
+
1. Update both files with new decisions.
|
|
234
|
+
2. Output a short diff: "Added: destructive-action policy. Updated: motion strategy (was TBD, now spring)."
|
|
@@ -132,4 +132,5 @@ four-operation split assigns to *rules/linters*, not the corpus).
|
|
|
132
132
|
- [`design-intelligence`](../design-intelligence/SKILL.md) — grounded value selection.
|
|
133
133
|
- [`tailwind-engineer`](../tailwind-engineer/SKILL.md) — utility-discipline consumer.
|
|
134
134
|
- [`react-shadcn-ui`](../react-shadcn-ui/SKILL.md) — shadcn token conventions.
|
|
135
|
+
- [`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md) — when authoring the colour layer, avoid the C5 cream/sand default palette (OKLCH L 0.84–0.97, C < 0.06) and C1 purple/violet primaries unless the brand explicitly defines them; the `brand-consistency` rule validates emitted tokens against the active brand profile.
|
|
135
136
|
- Tests: `tests/test_design_tokens_toolchain.py`.
|
|
@@ -4,12 +4,13 @@ name: dpa-review
|
|
|
4
4
|
description: "Use when reviewing a DPA as controller or processor against GDPR Art. 28 — GREEN/YELLOW/RED gap frame, never a final call. Triggers on \"review this DPA\", \"check this DPA\"."
|
|
5
5
|
status: active
|
|
6
6
|
tier: senior
|
|
7
|
+
council_depth: deep
|
|
7
8
|
domain: process
|
|
8
9
|
recommended_for_user_types: [legal]
|
|
9
10
|
workspaces:
|
|
10
|
-
- legal
|
|
11
|
+
- legal-review-prep
|
|
11
12
|
packs:
|
|
12
|
-
- legal
|
|
13
|
+
- legal-review-prep
|
|
13
14
|
trust:
|
|
14
15
|
level: advisory
|
|
15
16
|
install:
|
|
@@ -16,10 +16,10 @@ packs:
|
|
|
16
16
|
> **Interplay:** this audit answers *what exists* (components, tokens,
|
|
17
17
|
> primitives → `state.ui_audit`);
|
|
18
18
|
> [`design-intelligence`](../design-intelligence/SKILL.md) answers *what to
|
|
19
|
-
> build* (corpus-grounded style/token/typography/pattern selection
|
|
20
|
-
> Audit runs first
|
|
21
|
-
> let a grounded recommendation introduce a
|
|
22
|
-
> already covers.
|
|
19
|
+
> build* (corpus-grounded style/token/typography/pattern selection for the
|
|
20
|
+
> brief). Audit runs first, and its reuse findings outrank corpus
|
|
21
|
+
> suggestions — never let a grounded recommendation introduce a new
|
|
22
|
+
> component the inventory already covers.
|
|
23
23
|
|
|
24
24
|
## When to use
|
|
25
25
|
|
|
@@ -208,6 +208,17 @@ violations will surface as new findings on every run.
|
|
|
208
208
|
- Greenfield is detected, not assumed — a project with one Blade layout and no components is still greenfield only if tokens AND design system markers AND components are all empty.
|
|
209
209
|
- Re-running the skill on a stale state-file: cache by `(composer.json mtime, package.json mtime)`; if either changed, re-audit and overwrite.
|
|
210
210
|
|
|
211
|
+
## Anti-slop cross-reference
|
|
212
|
+
|
|
213
|
+
When the audit inventory reveals an existing aesthetic direction (dominant color
|
|
214
|
+
scheme, border-radius convention, motion patterns), cross-check the findings
|
|
215
|
+
against
|
|
216
|
+
[`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md).
|
|
217
|
+
If the existing UI already uses a listed anti-pattern, surface it as a design-debt
|
|
218
|
+
finding (separate from the reuse inventory) — flag by entry ID and severity. The
|
|
219
|
+
next design step can then decide whether to continue the existing pattern (for
|
|
220
|
+
consistency) or introduce a corrective direction change.
|
|
221
|
+
|
|
211
222
|
## Do NOT
|
|
212
223
|
|
|
213
224
|
- Do NOT advance to `directives/ui/design.py` or `apply.py` if `state.ui_audit` is empty.
|
|
@@ -49,9 +49,10 @@ Do NOT use this skill to:
|
|
|
49
49
|
states, microcopy, a11y). Selection decisions (style, semantic color
|
|
50
50
|
tokens, typography pairing, layout pattern, anti-patterns) come **grounded**
|
|
51
51
|
from [`design-intelligence`](../design-intelligence/SKILL.md) — run its
|
|
52
|
-
corpus query first; fall back to
|
|
53
|
-
reports an evidence gap or the audit already pins a
|
|
54
|
-
Stack-specific choices come from the dispatched
|
|
52
|
+
corpus query first; fall back to the heuristics in this reference only
|
|
53
|
+
where the corpus reports an evidence gap or the audit already pins a
|
|
54
|
+
project pattern. Stack-specific choices come from the dispatched
|
|
55
|
+
implementation skill, not from here.
|
|
55
56
|
|
|
56
57
|
## Component Architecture
|
|
57
58
|
|
|
@@ -198,24 +199,97 @@ Step indicator (1 — 2 — 3)
|
|
|
198
199
|
| Auto-playing content | Provide pause/stop control |
|
|
199
200
|
| Tiny click targets | Min 44×44px touch target |
|
|
200
201
|
|
|
202
|
+
## Motion — decision-tree and rationale
|
|
203
|
+
|
|
204
|
+
Before adding any animation to a UI element, run through this decision tree:
|
|
205
|
+
|
|
206
|
+
**1. Should this animate at all?**
|
|
207
|
+
- 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.
|
|
208
|
+
- 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.
|
|
209
|
+
- Modal/overlay/sheet entering/exiting? **Animate. Why:** position change needs motion to maintain spatial continuity.
|
|
210
|
+
- Background process with no user action? **No animation.** Why: unexplained motion is disorienting.
|
|
211
|
+
|
|
212
|
+
**2. Which easing?**
|
|
213
|
+
- Entering (element appearing)? **ease-out** (starts fast, slows to rest). Why: the element arriving quickly signals responsiveness; the deceleration feels natural as it settles.
|
|
214
|
+
- Exiting (element disappearing)? **ease-in** (starts slow, accelerates out). Why: the reverse is true — fast exit signals completion.
|
|
215
|
+
- **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.
|
|
216
|
+
- **Never bounce or elastic easing in UI.** Why: bounce draws attention to the animation itself, not the content; it feels dated.
|
|
217
|
+
|
|
218
|
+
**3. How long?**
|
|
219
|
+
- Button/micro-feedback: 100–160ms. Tooltip: 100ms. Dropdown open: 150–200ms. Modal: 200–350ms. Page transition: 300–500ms. Above 500ms: almost never.
|
|
220
|
+
- **Never animate layout properties** (width, height, top, left, padding). Why: triggers browser layout recalculation on every frame; always solvable with `transform`.
|
|
221
|
+
- **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.
|
|
222
|
+
|
|
223
|
+
**4. What to animate?**
|
|
224
|
+
Animate `transform` and `opacity` only. Why: these run on the GPU compositor thread, not the main thread; they never trigger layout or paint.
|
|
225
|
+
`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.
|
|
226
|
+
|
|
201
227
|
## UX Principles
|
|
202
228
|
|
|
203
|
-
1. **Feedback** — Every action gets a response (toast, loading state, success message)
|
|
204
|
-
2. **Forgiveness** — Undo
|
|
205
|
-
3. **Consistency** — Same patterns for same interactions across the app
|
|
206
|
-
4. **Progressive disclosure** — Show basics first, details on demand
|
|
207
|
-
5. **Loading states** — Skeleton screens
|
|
208
|
-
6. **Error recovery** — Clear error messages with suggested actions
|
|
229
|
+
1. **Feedback** — Every action gets a response (toast, loading state, success message). **Why:** users interpret no feedback as failure.
|
|
230
|
+
2. **Forgiveness** — Undo beats confirmation dialogs. Users click through confirmations mindlessly. **Why:** remove destructively then show undo toast; actually delete after toast expires.
|
|
231
|
+
3. **Consistency** — Same patterns for same interactions across the app. **Why:** predictability reduces cognitive load; inconsistency forces users to re-learn.
|
|
232
|
+
4. **Progressive disclosure** — Show basics first, details on demand. **Why:** premature complexity overwhelms; reveal information as it becomes relevant.
|
|
233
|
+
5. **Loading states** — Skeleton screens preferred over spinners. **Why:** skeletons reduce perceived wait time by showing structure immediately.
|
|
234
|
+
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.
|
|
235
|
+
|
|
236
|
+
## Cross-task design memory — read DESIGN.md / PRODUCT.md first
|
|
237
|
+
|
|
238
|
+
Before applying any heuristics from this reference, check the project root
|
|
239
|
+
for `DESIGN.md` and/or `PRODUCT.md` (written by `design-system-capture`):
|
|
240
|
+
|
|
241
|
+
- `DESIGN.md` present → use its captured radius/shadow/motion/spacing as
|
|
242
|
+
project constraints. The heuristics in this skill are **fallbacks for
|
|
243
|
+
gaps**, not overrides for captured decisions.
|
|
244
|
+
- `PRODUCT.md` present → honor its interaction patterns (empty-state approach,
|
|
245
|
+
mutation feedback policy, filter persistence) in any UI design that touches
|
|
246
|
+
those surfaces.
|
|
247
|
+
|
|
248
|
+
Flag any new decision for future capture: *"This establishes a new pattern —
|
|
249
|
+
suggest adding to PRODUCT.md: [pattern description]."*
|
|
250
|
+
|
|
251
|
+
## Register — brand vs product
|
|
252
|
+
|
|
253
|
+
Before applying heuristics, determine the register (see
|
|
254
|
+
[`docs/guidelines/design-modes.md`](../../../docs/guidelines/design-modes.md)):
|
|
255
|
+
brand mode (impression-first) vs product mode (task-first). Form-heavy, table-heavy,
|
|
256
|
+
and dashboard surfaces are almost always product mode — favour the standard
|
|
257
|
+
patterns in this skill (Form Design, Table Design) over expressive variance.
|
|
258
|
+
Marketing/landing surfaces are brand mode — let the Aesthetic-direction section
|
|
259
|
+
commit to a deliberate, distinctive direction.
|
|
260
|
+
|
|
261
|
+
## Design Read — articulate intent before generating
|
|
262
|
+
|
|
263
|
+
When this reference is cited for a UI planning task, emit one line declaring
|
|
264
|
+
the design read before any heuristics are applied:
|
|
265
|
+
|
|
266
|
+
```
|
|
267
|
+
Reading this as: <page-kind> for <audience>, <vibe> language, leaning <design-system>.
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
**If context is incomplete:** state so and proceed exploratory — do NOT block.
|
|
271
|
+
|
|
272
|
+
**Anti-Default Discipline:** Before committing to any layout or component
|
|
273
|
+
pattern, verify you are NOT defaulting to:
|
|
274
|
+
- Centered hero + 3-column feature grid + CTA (the "AI landing page" layout)
|
|
275
|
+
- Side-stripe `border-left` accent cards (V1 in `design-antipatterns`)
|
|
276
|
+
- Identical card grids with no visual rhythm (L2)
|
|
277
|
+
- `Inter` or `Space Grotesk` as the uncritical font pick (T7)
|
|
278
|
+
- Glassmorphism as a decoration device (V2)
|
|
279
|
+
|
|
280
|
+
If any of these was the first impulse, choose a different approach or
|
|
281
|
+
explicitly justify why this brief genuinely calls for it.
|
|
209
282
|
|
|
210
283
|
## Aesthetic direction
|
|
211
284
|
|
|
212
285
|
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.
|
|
213
286
|
|
|
214
|
-
Typography pairings (73 curated heading/body
|
|
215
|
-
Tailwind config) and icon-system guidance (104 Phosphor
|
|
216
|
-
import code) come grounded from
|
|
287
|
+
Typography pairings (73 curated heading/body combinations with Google
|
|
288
|
+
Fonts URLs + Tailwind config) and icon-system guidance (104 Phosphor
|
|
289
|
+
entries with import code) come grounded from
|
|
217
290
|
[`design-intelligence`](../design-intelligence/SKILL.md)
|
|
218
|
-
(`--domain typography`, `--domain icons`) — query before picking from
|
|
291
|
+
(`--domain typography`, `--domain icons`) — query before picking from
|
|
292
|
+
memory.
|
|
219
293
|
|
|
220
294
|
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.
|
|
221
295
|
|
|
@@ -228,7 +302,7 @@ When `directives/ui/design.py` (or any caller) cites this skill:
|
|
|
228
302
|
1. **Inspect `state.ui_audit` first** — review the audit produced by [`existing-ui-audit`](../existing-ui-audit/SKILL.md); it is mandatory. Stop and request the audit if missing.
|
|
229
303
|
2. **Pick the smallest matching section** — Component Architecture, Form Design, Table Design, Responsive Strategy, Accessibility, or UX Principles. Cite by H2/H3 heading, never paste the whole skill.
|
|
230
304
|
3. **Defer to audit findings** — when the audit pins a project pattern (token, primitive, layout convention), use it. The heuristics here are fallbacks for gaps, not overrides.
|
|
231
|
-
4. **Defer to the stack apply skill** — Blade vs. Livewire vs. Flux vs. React-shadcn choices come from the dispatched
|
|
305
|
+
4. **Defer to the stack apply skill** — Blade vs. Livewire vs. Flux vs. React-shadcn choices come from the dispatched implementation skill, never from this reference.
|
|
232
306
|
5. **Surface conflicts** — if a heuristic here contradicts an audit finding or stack convention, name both and let the caller decide; do not silently pick.
|
|
233
307
|
|
|
234
308
|
## Output format
|
|
@@ -245,8 +319,8 @@ When this skill's content is folded into a design brief or review:
|
|
|
245
319
|
- **Orchestrator:** [`directives/ui/`](../../templates/scripts/work_engine/directives/ui/) — owns the UI flow
|
|
246
320
|
- **Pre-step (mandatory):** [`existing-ui-audit`](../existing-ui-audit/SKILL.md) — inventory before design
|
|
247
321
|
- **Stack apply skills (dispatched, not standalone):**
|
|
248
|
-
- [`blade-ui`](../blade-ui/SKILL.md) — Blade template
|
|
249
|
-
- [`livewire`](../livewire/SKILL.md) — Livewire component
|
|
322
|
+
- [`blade-ui`](../blade-ui/SKILL.md) — Blade template implementation
|
|
323
|
+
- [`livewire`](../livewire/SKILL.md) — Livewire component implementation
|
|
250
324
|
- [`flux`](../flux/SKILL.md) — Flux component library usage
|
|
251
325
|
- [`react-shadcn-ui`](../react-shadcn-ui/SKILL.md) — React + shadcn primitives
|
|
252
326
|
- **Adjacent reference:** [`dashboard-design`](../dashboard-design/SKILL.md) — monitoring dashboard design (different domain)
|
|
@@ -257,6 +331,14 @@ When this skill's content is folded into a design brief or review:
|
|
|
257
331
|
- Heuristics in this reference apply across stacks; do not promote them to project rules without checking the audit.
|
|
258
332
|
- Mobile-first is not optional — every layout must work on 320px width.
|
|
259
333
|
|
|
334
|
+
## Anti-slop discipline
|
|
335
|
+
|
|
336
|
+
Before proposing any UI layout, component, or aesthetic direction, pull
|
|
337
|
+
[`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md)
|
|
338
|
+
and scan the Visual (V1–V7), Layout (L1–L8), and Quality-floors (Q1–Q12) sections.
|
|
339
|
+
If the first-impulse design matches a listed pattern, either choose a different
|
|
340
|
+
approach or explicitly invoke the override condition in the design brief.
|
|
341
|
+
|
|
260
342
|
## Do NOT
|
|
261
343
|
|
|
262
344
|
- Do NOT skip mobile viewport testing.
|
|
@@ -118,6 +118,14 @@ current state on the next polish round.
|
|
|
118
118
|
- Do NOT override Flux styles with conflicting Tailwind — use variants or slots.
|
|
119
119
|
- Do NOT skip the `label` prop on form fields — accessibility.
|
|
120
120
|
|
|
121
|
+
## Anti-slop
|
|
122
|
+
|
|
123
|
+
Flux primitives carry sane defaults, but composition still drifts into slop —
|
|
124
|
+
pull [`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md)
|
|
125
|
+
and check Layout (L1/L2 hero-metric + identical-card grids) and Color
|
|
126
|
+
(C1 gradient defaults) before shipping. Tailwind-level bans:
|
|
127
|
+
[`tailwind-engineer`](../tailwind-engineer/SKILL.md).
|
|
128
|
+
|
|
121
129
|
## Auto-trigger keywords
|
|
122
130
|
|
|
123
131
|
- Flux UI
|
|
@@ -86,3 +86,4 @@ execution:
|
|
|
86
86
|
- [`typography-system`](../typography-system/SKILL.md) — sibling visual-consistency skill.
|
|
87
87
|
- [`fe-design`](../fe-design/SKILL.md) — broader frontend design discipline.
|
|
88
88
|
- [`icon-consistency`](../../rules/icon-consistency.md) — enforced rule for set discipline across the project.
|
|
89
|
+
- [`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md) — icon-relevant slop tells: V5 (hand-drawn SVG mixed with crisp icon-system icons) and T3 (small rounded-square icon tile above every feature heading — the universal AI feature-card template).
|
|
@@ -4,12 +4,13 @@ name: legal-intake-triage
|
|
|
4
4
|
description: "Use when triaging the quick legal-question channel + intake; classifies and ROUTES, never reviews. Triggers on 'is this a legal problem', 'do we need a lawyer for this', 'quick legal question'."
|
|
5
5
|
status: active
|
|
6
6
|
tier: senior
|
|
7
|
+
council_depth: deep
|
|
7
8
|
domain: process
|
|
8
9
|
recommended_for_user_types: [legal]
|
|
9
10
|
workspaces:
|
|
10
|
-
- legal
|
|
11
|
+
- legal-review-prep
|
|
11
12
|
packs:
|
|
12
|
-
- legal
|
|
13
|
+
- legal-review-prep
|
|
13
14
|
trust:
|
|
14
15
|
level: advisory
|
|
15
16
|
install:
|
|
@@ -4,12 +4,13 @@ name: legal-practice-profile
|
|
|
4
4
|
description: "Use when setting up the legal pack — captures jurisdiction, role, escalation, and playbook into a plain-prose profile every legal skill reads. Triggers on \"set up legal\", \"legal profile\"."
|
|
5
5
|
status: active
|
|
6
6
|
tier: senior
|
|
7
|
+
council_depth: deep
|
|
7
8
|
domain: process
|
|
8
9
|
recommended_for_user_types: [legal]
|
|
9
10
|
workspaces:
|
|
10
|
-
- legal
|
|
11
|
+
- legal-review-prep
|
|
11
12
|
packs:
|
|
12
|
-
- legal
|
|
13
|
+
- legal-review-prep
|
|
13
14
|
trust:
|
|
14
15
|
level: advisory
|
|
15
16
|
install:
|
|
@@ -130,6 +130,14 @@ current state on the next polish round.
|
|
|
130
130
|
- Do NOT nest Livewire components deeply — keep the tree shallow.
|
|
131
131
|
- Do NOT expose sensitive data as public properties.
|
|
132
132
|
|
|
133
|
+
## Anti-slop
|
|
134
|
+
|
|
135
|
+
When a Livewire component renders UI, pull
|
|
136
|
+
[`docs/guidelines/design-antipatterns.md`](../../../docs/guidelines/design-antipatterns.md)
|
|
137
|
+
for the Visual / Layout / Motion checks (loading states that animate layout
|
|
138
|
+
properties — M2 — are a common Livewire `wire:loading` pitfall). Stack styling
|
|
139
|
+
bans: [`tailwind-engineer`](../tailwind-engineer/SKILL.md).
|
|
140
|
+
|
|
133
141
|
## Auto-trigger keywords
|
|
134
142
|
|
|
135
143
|
- Livewire
|
|
@@ -4,12 +4,13 @@ name: nda-triage
|
|
|
4
4
|
description: "Use when triaging an inbound NDA fast — GREEN/YELLOW/RED so only the hard ones reach a lawyer. Triggers on 'check this NDA', 'can we sign this NDA', 'is this NDA standard'."
|
|
5
5
|
status: active
|
|
6
6
|
tier: senior
|
|
7
|
+
council_depth: deep
|
|
7
8
|
domain: process
|
|
8
9
|
recommended_for_user_types: [legal]
|
|
9
10
|
workspaces:
|
|
10
|
-
- legal
|
|
11
|
+
- legal-review-prep
|
|
11
12
|
packs:
|
|
12
|
-
- legal
|
|
13
|
+
- legal-review-prep
|
|
13
14
|
trust:
|
|
14
15
|
level: advisory
|
|
15
16
|
install:
|