Skills for Claude Code CLI such as full stack dev Cloudflare, React, Tailwind v4, and AI integrations.
Python aianthropicautomationclaude-codeclaude-skillscloudflaredevtoolsproductivityreactskillstailwindvite
feat(ux-audit): add first-time-user lens (mandatory)
Jeremy Dawes0ec39a57c4d7
diff --git a/.claude/settings.json b/.claude/settings.jsonnew file mode 100644index 00000000..b85957bb--- /dev/null+++ b/.claude/settings.json@@ -0,0 +1,15 @@+{+ "hooks": {+ "UserPromptSubmit": [+ {+ "matcher": "",+ "hooks": [+ {+ "type": "command",+ "command": "/Users/marcuswebb/Documents/virtual-team/shared/hooks/heartbeat-context.sh"+ }+ ]+ }+ ]+ }+}diff --git a/plugins/dev-tools/commands/ux-audit.md b/plugins/dev-tools/commands/ux-audit.mdindex e427e576..1bcd1da9 100644--- a/plugins/dev-tools/commands/ux-audit.md+++ b/plugins/dev-tools/commands/ux-audit.md@@ -1,5 +1,5 @@----description: Exhaustively audit a web app — threads, elements, 8 scenarios, fix-and-verify loop+description: Exhaustively audit a web app — threads, elements, visual polish (AI-tells), 8 scenarios, fix-and-verify loopargument-hint: "[optional: persona or scope, e.g. 'as a busy broker' or 'the dashboard only']"allowed-tools: "*"---diff --git a/plugins/dev-tools/skills/codex-review/SKILL.md b/plugins/dev-tools/skills/codex-review/SKILL.mdnew file mode 100644index 00000000..427385fe--- /dev/null+++ b/plugins/dev-tools/skills/codex-review/SKILL.md@@ -0,0 +1,104 @@+---+name: codex-review+description: "Run an independent code review using the OpenAI Codex CLI in headless mode. Gets a second opinion from a different model family (GPT-5/o3) on recent changes, a PR, a commit, or the whole app — covering bugs, regressions, security, data consistency, UX/state bugs, performance risks, and testing gaps. Saves a severity-prioritised report to .jez/reviews/. Triggers: 'codex review', 'review with codex', 'second opinion on this code', 'independent code review', 'what does codex think', 'get codex to review'."+compatibility: Designed for Claude Code (or similar products)+---++# Codex Review++Run an independent code review via the OpenAI Codex CLI (`codex review`). The value is a second opinion from a **different model family** than the one that wrote the code — Codex catches things Claude misses due to author bias.++Complements `brains-trust` (generic multi-model opinions). This skill is specialised: git-aware, uses a tuned review prompt, saves structured output.++## When to Use++- After a meaningful change, before committing or shipping+- Before opening a PR, to self-review with an independent reviewer+- When something feels off but you can't articulate what+- Periodic whole-app reviews for projects in active development+- When the user explicitly asks for an "independent" or "second opinion" review++**Do NOT use** for:+- Trivial changes (typos, one-line fixes)+- Research questions or architecture discussions — use `brains-trust` instead+- Auto-fixing issues — this is advisory only++## Preflight++1. Confirm Codex CLI is installed:+ ```bash+ which codex+ ```+ If missing: tell the user to install it (`brew install codex` on macOS, or see https://github.com/openai/codex) and stop. Do not continue.++2. Confirm auth: the first `codex review` call will fail clearly if not logged in. If that happens, instruct the user to run `codex login` and stop.++## Determine scope++Pick the scope flag based on what the user asked for:++| User intent | Flag |+|---|---|+| "codex review" / "review the app" / "full review" / default | no flag (reviews whole app at current HEAD) |+| "review my changes" / "review what I just did" / "review uncommitted" | `--uncommitted` |+| "review this branch vs main" / "review the PR" | `--base main` (or the branch they name) |+| "review commit abc123" | `--commit abc123` |++**Default is whole-app review.** A bare "codex review" with no qualifier means review the entire codebase at HEAD — not just uncommitted changes. Only use `--uncommitted` if the user specifically refers to their recent/uncommitted work.++If ambiguous, ask once. Don't guess on commits or branches.++## Run the review++The canonical review prompt lives in `prompt.md` next to this skill. Pipe it via stdin to avoid shell escaping:++```bash+mkdir -p .jez/reviews+TS=$(date +%Y-%m-%d-%H%M)+OUT=".jez/reviews/codex-${TS}.md"+SKILL_DIR="$(dirname "$0")" # or use the skill's absolute path++# Example: uncommitted changes+cat "${SKILL_DIR}/prompt.md" | codex review --uncommitted - 2>&1 | tee "$OUT"+```++Other scopes:++```bash+# Vs base branch+cat prompt.md | codex review --base main - 2>&1 | tee "$OUT"++# Specific commit+cat prompt.md | codex review --commit abc123 - 2>&1 | tee "$OUT"++# Current HEAD (no scope flag)+cat prompt.md | codex review - 2>&1 | tee "$OUT"+```++`codex review` can take several minutes on a large diff. Let it run.++## Summarise for the user++After Codex finishes:++1. Print the output path: `Report saved to .jez/reviews/codex-<timestamp>.md`+2. Read the saved report and extract the top findings (anything under **Critical** and **High**)+3. Show them inline in the chat, with file:line references intact+4. Offer to action specific findings: "Want me to fix the SQL injection in `auth.ts:42`?"++## Rules++- **Advisory only.** Never auto-apply Codex's suggestions. Read the findings, discuss with the user, fix with their approval.+- **Don't leak Claude's reasoning into the prompt.** The `prompt.md` file is deliberately neutral — Codex reviews the code, not Claude's narrative about the code. Independence is the whole point.+- **Save to `.jez/reviews/`**, never `.claude/` (protected directory).+- **One report per run.** Don't overwrite — the timestamp makes each run unique so the user can compare.+- **Report what Codex actually found.** Don't soften, editorialise, or skip findings you disagree with. If you think Codex is wrong about something, say so as your own opinion after showing what Codex said.++## Verification++The skill is working if:+- Preflight correctly detects a missing `codex` binary+- The right scope flag is chosen based on user intent+- The report file appears in `.jez/reviews/` with a sensible timestamp+- The file contains severity-prioritised findings with file:line refs+- Claude surfaces the top findings without auto-fixing themdiff --git a/plugins/dev-tools/skills/codex-review/prompt.md b/plugins/dev-tools/skills/codex-review/prompt.mdnew file mode 100644index 00000000..047d25bd--- /dev/null+++ b/plugins/dev-tools/skills/codex-review/prompt.md@@ -0,0 +1,31 @@+Review the entire app for bugs, regressions, edge cases, security issues, data consistency problems, UX/state bugs, performance risks, and testing gaps. Treat this as a code review.++Prioritize findings by severity (critical / high / medium / low / nit), include file/line references for every finding, list open questions and assumptions you had to make, and mention what you verified with typecheck, lint, and tests (and what you couldn't verify).++Be concrete. Prefer "auth.ts:42 — SQL query concatenates user input, vulnerable to injection" over "watch out for SQL injection". If something looks wrong but you're not sure, say so and explain what you'd need to confirm it.++Structure the output as:++## Summary+One-paragraph overview: overall health, biggest concerns, what's solid.++## Critical+Issues that break things, lose data, or expose security holes. Each: file:line, what's wrong, why it matters, suggested fix.++## High+Bugs, regressions, meaningful edge cases.++## Medium+Code quality issues that will bite later — error handling gaps, fragile patterns, missing validation.++## Low / Nits+Style, naming, minor improvements.++## Testing gaps+What should be tested but isn't. What existing tests might miss.++## Open questions & assumptions+What you weren't sure about. What you assumed. What the author should confirm.++## Verification performed+What you ran (typecheck, lint, tests) and the results. What you couldn't run and why.diff --git a/plugins/dev-tools/skills/ux-audit/SKILL.md b/plugins/dev-tools/skills/ux-audit/SKILL.mdindex e1d16729..bb20b803 100644--- a/plugins/dev-tools/skills/ux-audit/SKILL.md+++ b/plugins/dev-tools/skills/ux-audit/SKILL.md@@ -1,6 +1,6 @@---name: ux-audit-description: "Exhaustive UX audit of a web app. Walks every thread a real user would follow, tests every interactive element, runs scenario battery (keyboard-only, heavy data, destructive actions, second user, interrupted workflow, wrong turn, returning user, first contact), produces ranked findings with screenshots, then offers a fix-and-verify loop. Requires a persona. Trigger with 'ux audit', 'dogfood this', 'audit the app', 'qa sweep', 'exhaustive test', 'check all pages'."+description: "Exhaustive UX audit of a web app. Walks every thread a real user would follow, tests every interactive element, runs visual polish sweep (AI-tells, optical centring, design-token discipline, animation timings) and scenario battery (keyboard-only, heavy data, destructive actions, second user, interrupted workflow, wrong turn, returning user, first contact), produces ranked findings with screenshots, then offers a fix-and-verify loop. Requires a persona. Trigger with 'ux audit', 'dogfood this', 'audit the app', 'qa sweep', 'exhaustive test', 'check all pages'."compatibility: claude-code-only---@@ -10,6 +10,7 @@ Exhaustively audit a web app from the perspective of a real user. Two lenses, co- **Flow lens** — walk the 3–5 real tasks a user would do ("threads"). Count clicks, mark dead ends, screenshot every state change.- **Element lens** — after threads, sweep every interactive element not already hit. Forms, menus, toggles, edge data volumes.+- **Polish lens** — page-by-page visual polish sweep covering optical centring, design-token discipline, off-scale spacing, animation timings, and the other patterns that mark UIs as machine-generated.Then run an eight-scenario battery (first contact, interrupted workflow, wrong turn recovery, returning user, keyboard only, heavy data, destructive confidence, second user) and close with a fix-and-verify loop for critical findings.@@ -62,6 +63,8 @@ The audit needs a persona. Without one, findings drift toward generic "looks finCapture: role, tech comfort, time pressure, emotional state, device context. A good persona predicts what they'd miss ("A receptionist between phone calls won't scroll below the fold").+**Always also run the first-time-user lens** (see below) on every multi-page feature, even when the explicit persona is something else. It's the single biggest blind spot for AI / internal tooling — engineers writing the screen know what every field means, brand-new users don't.+### 5. Screenshot post-processingOn Retina Macs, Chrome captures screenshots at 2× the logical viewport — a 1440×900 window produces a 2880×1800 PNG. That's larger than the vision pipeline needs and wastes context. Downsize screenshots after each capture phase:@@ -118,6 +121,46 @@ This inventory powers the coverage metric. After the audit you can say *"testedBuild inventories lazily — per-page as you traverse, not all up-front.+## First-time-user lens (mandatory)++Every multi-page feature the audit covers must pass the **first-time+user** check. This catches the single biggest UX failure mode in+internal/AI tooling: features built by the people who designed them+work *for them*, but a brand-new user landing on the same screen has+no idea what any of the controls mean, what to type into the inputs,+or what defaults to keep.++Run the lens like this. Adopt the persona of *someone signing in to+this app for the very first time, with no prior context, no source+access, no internal documentation*. Before each screen you audit, ask:++| Question | What it catches |+|---|---|+| Could I complete the task without reading the code or docs? | Hidden technical knowledge baked into the form |+| Are the field labels in plain language, not internal vocabulary? | `agentClass`, `slug`, `agentName`, `webhook_id`, `instance_id` leaking into UI |+| Do dropdowns / pickers show **what each option does**, not just an ID? | Snake_case enums, raw class names, opaque slugs |+| Are defaults sensible enough that I can keep them and move on? | Required fields with no defaults, mandatory ID inputs |+| When I'm asked to enter something, is there a discoverable list of valid values? | Free-text inputs where a combobox / picker should be |+| If I'd say "click Skip" because I don't understand a setting, that's a UX bug. | Optional-but-confusing settings exposed as primary inputs |++When the lens fires, log a finding even if the screen technically+works. The fix is usually one of:++- **Replace text inputs with pickers** that read from a discovery+ endpoint and show display names + descriptions+- **Surface metadata** on every primitive (agent / tool / skill /+ channel / role / outcome) so UIs never fall back to raw IDs+- **Auto-derive** values that the user shouldn't have to invent+ (instance names, slugs, IDs)+- **Hide internal IDs** under an "Advanced" disclosure so they're+ available for debugging but invisible by default+- **Add inline guidance** ("Use this when…", "Pick the routine that…")+ next to each control rather than gating users on tribal knowledge++The lens applies to both new screens being audited and existing screens+being polished. A screen passes the lens when a brand-new persona could+complete the screen's task without back-channel help.+## Thread Traversal (primary phase)For each thread:@@ -188,6 +231,33 @@ On any page that breaks at an intermediate width, screenshot the transition poinRun the automated layout-detection JS (overflow, clipping, invisible text) at each width — snippets in [references/walkthrough-checklist.md](references/walkthrough-checklist.md). Read console output after injection; every warning is a potential finding.+## Visual Polish Sweep++A page-by-page micro-polish pass that catches the patterns separating *technically correct* UIs from *visibly considered* ones — and the patterns that mark a UI as machine-generated. Run after the Responsive Sweep, before the Scenario Battery.++Cover this even if a separate design-review didn't run. The visual-polish concern lives in this phase by default.++For each major page, walk the **AI-tell catalogue** in `references/visual-polish.md`. The ten checks:++1. **Optical vs mathematical centring** — text in buttons, icons next to labels, numbers in badges. `align-items: center` is not optical centring.+2. **Nested border-radius rule** — `inner radius = outer radius - padding`. Concentric arcs, not pinched corners.+3. **Off-scale spacing** — every margin / padding / gap should land on the design system's scale. 22px where 24px belongs is the AI tell.+4. **Vibe greys** — body text and borders trace to design tokens (`var(--*)`), not raw hex / Tailwind greys. Eyedropper every grey.+5. **Border-weight drift** — 1px / 1.5px / 2px mixed in same logical category.+6. **Drop shadow direction** — light source consistent across the app (all shadows point the same direction).+7. **Animation timings off canonical** — durations on 150 / 200 / 300 / 500ms. Arbitrary values like 187ms are tells.+8. **Hover-delta calibration** — perceptible state change (~10% brightness shift), not 5% imperceptible or 20% jarring.+9. **Underline offset / uppercase letter-spacing** — set deliberately, not browser default.+10. **Symmetry vs editorial pacing** — composed pages vs templated layouts. App shells generated by AI tend toward perfect mathematical symmetry.++Plus a **per-component optical pass** for buttons, badges, inputs, dropdowns, cards, tabs, avatars, toasts. Each verified against the four-point check (text optically centred, icons on cap-height baseline, hover delta perceptible, nested radii correct).++**Tools**: DevTools eyedropper for greys/colours, Computed styles tab for spacing/borders/timings, Layout overlay for grid/padding visualisation. Take screenshots of every finding *with the inspector overlay visible* — the overlay is the proof.++**Severity**: stacked AI-tells on one component (off-centre text + arbitrary radius + raw grey) is **High**. Pattern-level violation across components (raw greys app-wide) is **High**. Single instance, single tell is **Low**.++Full protocol, expected values, and findings shapes in [references/visual-polish.md](references/visual-polish.md).+## Scenario BatteryEight scenarios. All eight, always. They catch what screen-by-screen testing misses. Full protocols in [references/scenario-tests.md](references/scenario-tests.md).@@ -348,6 +418,7 @@ For audits expected to run longer than 30 minutes, set up a 15-min `/loop` check| Per-screen evaluation questions | [references/walkthrough-checklist.md](references/walkthrough-checklist.md) || Workflow threads, wayfinding, mental model alignment, page-to-page continuity | [references/workflow-comprehension.md](references/workflow-comprehension.md) || Full protocol for each of the 8 scenarios | [references/scenario-tests.md](references/scenario-tests.md) |+| AI-tell catalogue, optical centring, design-token discipline, per-component pass | [references/visual-polish.md](references/visual-polish.md) || Report format and severity rubrics | [references/report-template.md](references/report-template.md) || Browser tool commands and viewport notes | [references/browser-tools.md](references/browser-tools.md) || Long-running audit supervision via 15-min `/loop` check-in | [references/long-running-check-in-pattern.md](references/long-running-check-in-pattern.md) |@@ -359,4 +430,5 @@ For audits expected to run longer than 30 minutes, set up a 15-min `/loop` check- **Write findings incrementally.** The report file is cheaper memory than your context.- **Stay in persona.** If you catch yourself thinking "a developer would know…" stop. Your persona doesn't.- **Every hesitation is a finding.** If you paused to figure out what to click, that's friction worth reporting.+- **Use the eyedropper liberally.** Single fastest way to find vibe greys, off-token colours, and design-system drift.- **Coverage is arithmetic.** Inventoried ÷ tested. Publish the ratio in the report.diff --git a/plugins/dev-tools/skills/ux-audit/references/report-template.md b/plugins/dev-tools/skills/ux-audit/references/report-template.mdindex c8e60196..452b592a 100644--- a/plugins/dev-tools/skills/ux-audit/references/report-template.md+++ b/plugins/dev-tools/skills/ux-audit/references/report-template.md@@ -26,6 +26,7 @@ Write incrementally — open the file at the start of the audit, append as you g| Interactive elements | 187 | 203 | 92% || Threads walked | 4 | 4 | 100% || Scenarios completed | 7 | 8 | 88% (Destructive Confidence skipped — no test account) |+| Pages with visual polish sweep | 11 | 14 | 79% (3 modal-only pages folded into parent route reviews) |**Elements not tested** (and why):- /app/billing — 16 elements — requires paid plan, not available on test account@@ -170,6 +171,29 @@ Write incrementally — open the file at the start of the audit, append as you g| / | ✓ | ✓ | ✓ | ✓ | ✓ | ✗ (text invisible) | || /app/clients | ✓ | ✓ | ✗ (overflow) | ✗ | ✓ | ✓ | |+## Visual Polish (AI-tell sweep)++For each page audited, mark which AI-tells were found:++| Route | Optical centring | Nested radius | Off-scale spacing | Vibe greys | Border drift | Shadow direction | Anim timings | Hover delta | Underline / uppercase | Symmetry / pacing |+|-------|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|:---:|+| / | ✓ | ✓ | ✗ (22px gap) | ✗ (#5a6168 raw) | ✓ | ✓ | ✗ (187ms drop) | ✓ | ✓ | ✓ |+| /app/clients | ✗ (button text 2px high) | ✓ | ✓ | ✗ (3 raw greys) | ✓ | ✓ | ✓ | ✗ (3% delta) | ✓ | ✓ |++**Per-component findings**:++- **Buttons (primary)** — text mathematically centred across all uses; needs ~1px upward optical correction+- **Sidebar dividers** — 2 raw grey values mixed (`#d4d4d8` and `#dfe1e6`); should consolidate to `--border` token+- **Modal shadow direction** — `-2px x-offset` on settings modal disagrees with app-wide `0 x-offset` light source++**Severity tally**:++| Severity | Count | Pattern type |+|----------|-------|-------------|+| High | 2 | Stacked AI-tells on primary CTA component (text + radius + grey + spacing) |+| Medium | 4 | Pattern-level (raw greys app-wide, animation timings off canonical) |+| Low | 7 | Single-instance (one-off underline offset, single off-scale value) |+## What Works WellPositive findings — patterns to preserve and replicate:diff --git a/plugins/dev-tools/skills/ux-audit/references/visual-polish.md b/plugins/dev-tools/skills/ux-audit/references/visual-polish.mdnew file mode 100644index 00000000..b3750c43--- /dev/null+++ b/plugins/dev-tools/skills/ux-audit/references/visual-polish.md@@ -0,0 +1,233 @@+# Visual Polish Sweep++A page-by-page micro-polish pass. Run after the Responsive Sweep, before the Scenario Battery. Goal: would a design-conscious person look at the page and think *"this is well made"* or *"a developer / AI built this"*?++This is the layer that separates a UI that's *technically correct* from one that *feels considered*. Most of the patterns below are invisible to functional testing and to most humans on first glance — but they pile up and form the unmistakable "machine-generated" smell.++## How to run++1. Pick one major page at a time. Work in this order:+ - Most-used screen (dashboard, primary list view)+ - Highest-stakes screen (settings, billing, anything destructive)+ - Marketing surfaces (login, signup, public pages)+ - Edit / detail screens++2. For each page, run through the **AI-tell catalogue** below in order. Don't skip the ones that feel subtle — those are exactly the ones the catalogue exists for.++3. Use Browser DevTools actively:+ - **Eyedropper** on greys, blues, borders — verify they trace back to design tokens, not raw values+ - **Computed styles** on suspect spacing values — verify they land on the design system's scale+ - **Inspect → Layout panel** — overlays show exact box dimensions and padding/margin+ - **Throttle network → Slow 3G** — forces loading and skeleton states to stay visible long enough to evaluate++4. Capture screenshots of every finding with the relevant DOM inspector overlay visible — the overlay is the proof.++## AI-tell catalogue++### 1. Optical vs mathematical centring++`align-items: center` puts the text-box centre at the container's centre. But text has descenders that shift the *perceptual* centre upward — what looks centred is not the same as what is mathematically centred.++**Buttons / chips / badges with text**:+- Take a screenshot. Draw a horizontal line through the visible text x-height (the top of the lowercase letters and bottom excluding descenders).+- The button's vertical centre should be 1-2px *above* the text-box centre — text should sit slightly low if mathematically centred.+- If text looks high-floating in the button, it's mathematically centred (broken). Should appear visually anchored.+- Numbers in badges (no descenders) need a different correction — they often need to be nudged *down* 1px from text default.++**Icon next to label**:+- Icon should align to the **cap height** of the text (the top of capital letters), not to the line-height box.+- Walk every "icon + text" pair: nav items, button labels with icons, list-item adornments, breadcrumb separators.+- If the icon looks low-slung (sitting on the descender line), it's wrong. Verify with: select the text + icon, check whether the icon centres above the baseline of the lowercase text, not on it.++**How to test**:+- Zoom screenshot to 400% and squint+- Use a horizontal ruler / DevTools horizontal guide+- Compare to a reference component from a polished design system (Radix UI primitives, Linear, Vercel docs)++**Findings shape**: *"Submit button on /signup — text mathematically centred (computed: y-offset 0px from container midline), should be optically corrected (~1px upward nudge). Compare to Linear's primary button styling."*++### 2. Nested border-radius rule++When a rounded container holds a rounded inner element, the inner radius should equal the outer radius minus the padding. `inner = outer - padding`.++**Why**: visually concentric corners trace parallel arcs. Mismatched radii create a wedge of awkward space at every corner.++**How to check**:+- Card with internal media (image, code block, embedded list): outer radius (e.g. 12px), inner padding (e.g. 8px), inner radius should be **4px**.+- Modal dialog with header/footer that have their own backgrounds: same rule applies recursively.+- Buttons with internal icon backgrounds, chips with adornments — same rule.++**Common AI failure**: outer 12px, padding 8px, inner ALSO 12px (or worse, 8px or 4px arbitrary). Inner corner looks pinched or floating depending on direction.++**Findings shape**: *"Card on /dashboard has 12px outer radius and 16px padding, but internal preview image has 12px radius — should be ~0px (clamped) or 4px for a subtle inner corner."*++### 3. Off-scale spacing++The design system defines a spacing scale (e.g. 4 / 8 / 12 / 16 / 24 / 32 / 48 / 64). Every margin, padding, and gap should be a step on that scale. AI-generated CSS often produces *almost-right* values: 22px where 24px belongs, 7px where 8px belongs.++**How to check**:+- DevTools → Computed styles → check every `margin`, `padding`, `gap` on visible elements+- Look for raw pixel values like 13, 15, 17, 22, 27, 31 — these are tells+- The scale's gaps reveal themselves under squint test as inconsistent rhythm: rows that should feel equally spaced look subtly off++**The squint test**: blur your eyes at a list / grid / form. Distances should feel like a small, regular ladder. If anything jumps, that's the off-scale value.++**Findings shape**: *"Form fields on /settings have 14px gap between groups (computed). Design tokens use 12 / 16 / 24 step scale. Should be either 16 or 24."*++### 4. Vibe greys (and other off-token colours)++Body text, borders, dividers, muted text — these should all come from design tokens (`text-foreground`, `text-muted-foreground`, `border`, etc.). AI often introduces raw greys: `text-gray-450`, `#5a6168`, hand-picked hex values.++The eye notices because:+- Multiple greys with slightly different temperature (warm vs cool) within one component looks careless+- Greys that don't trace to the system fail in dark mode (no inverted equivalent)+- Borders that read as 1.5 different greys at the same weight = visual debt++**How to check**:+- DevTools → Styles → look for inline colour values vs `var(--*)` references+- Eyedropper → sample text, borders, dividers, muted UI+- Verify each sampled colour matches a token in the design system's CSS variables++**Findings shape**: *"Sidebar dividers on /dashboard use #d4d4d8 (raw). Border tokens are `--border: hsl(220 13% 91%)` ≈ #e3e6eb. Two different values rendering at similar weights produces visual drift."*++### 5. Border-weight drift++Borders within the same logical category (inputs, cards, modals) should use the same weight. AI often uses 1px / 1.5px / 2px interchangeably with no rationale.++**How to check**:+- DevTools → Computed → `border-width` on every input field, card, modal+- Inputs: typically all 1px+- Cards: 1px or no border + shadow+- Modals: typically no border + larger shadow+- Hover/focus states may bump weight (1px → 2px focus ring), but consistently across the same category++**Findings shape**: *"On /clients, list cards use 1px border, action buttons use 1.5px, search input uses 2px focus ring while text inputs in modals use 3px. No clear pattern — pick one weight per state per category."*++### 6. Drop shadow direction inconsistency++Shadows imply a light source. The light source should be consistent across the entire app — typically top-left or top, casting shadows down or down-right.++**How to check**:+- For each component with a shadow (cards, modals, dropdowns, tooltips), inspect `box-shadow`+- Shadows should all share the same x-offset sign (positive or zero) and a positive y-offset+- Shadows that point in opposite directions (one shadow down-right, another shadow down-left) is the immediate tell++**Common AI failure**: dropdown shadow `0 4px 6px rgba(0,0,0,0.1)` (good — points down), modal shadow `-2px 4px 12px rgba(0,0,0,0.15)` (bad — points down-left). Same app, different light sources.++**Findings shape**: *"Modal shadow on /settings has -2px x-offset (light from upper-right). Dropdown shadows app-wide have 0 x-offset (light from above). Pick one and apply consistently."*++### 7. Animation timings off canonical++Canonical UX motion durations:+- 100-150ms — micro-interactions (hover, focus)+- 200ms — small transitions (toggle, accordion)+- 300ms — modal/sheet open+- 500ms+ — full-page route transitions++**AI failure**: arbitrary values like 157ms, 233ms, 412ms — reads as "let me just type a number". Off-canonical durations don't *feel* worse than canonical ones in isolation, but they signal lack of care.++**How to check**:+- DevTools → Inspect → Computed → `transition-duration`, `animation-duration`+- Check easing curves too: `ease`, `ease-in-out`, `cubic-bezier(0.4, 0, 0.2, 1)` are reasonable; `cubic-bezier(0.31, 0.07, 0.52, 0.99)` (or any random-looking curve) is a tell++**Findings shape**: *"Dropdown open animation duration is 187ms. Should be either 150 or 200 — pick canonical."*++### 8. Hover-delta too subtle (or too loud)++Default → hover should be a perceptible state change but not jarring.++- **Background-only hover**: typically ~10% darker (or lighter on dark backgrounds). 5% is subtle enough that users wonder if anything happened.+- **Border hover**: typically full colour shift (token to primary), not subtle weight change+- **Text hover**: typically full colour shift to primary or accent, with optional underline+- **Card hover**: shadow bump + 1-2px translate, not 0px bump or 8px translate++**How to check**:+- Hover every interactive element. Take a screenshot of default and hover state.+- Diff visually — would a user notice the change without actively looking for it?+- Accessibility consideration: pure colour changes need to also work in high-contrast / reduced-motion modes++**Findings shape**: *"Sidebar nav items: hover changes background from \`hsl(220 13% 96%)\` to \`hsl(220 13% 94%)\` — 2% delta, imperceptible. Should be ~10% or use a token like \`--accent\`."*++### 9. Text underline offset / letter-spacing on uppercase++**Underline offset**: default browser underlines render close to the descender line, often touching letters. Good design sets `text-underline-offset: 3-4px` or uses `text-decoration-thickness` for a tuned look.++**Uppercase letter-spacing**: ALL CAPS text without letter-spacing reads as cramped. Standard correction is +0.05em to +0.1em letter-spacing on uppercase headings, button labels, badges. AI often skips this.++**How to check**:+- Find every underlined link → DevTools Computed → check `text-underline-offset`. If `auto` or unset on long-form content, log it.+- Find every uppercase element → check `letter-spacing`. If 0 or unset, log it.++**Findings shape**: *"Inline links in body copy have default underline offset (browser ~1-2px) — descenders cross the underline line. Set \`text-underline-offset: 3px\`."*++### 10. Symmetry vs editorial pacing++App shells generated by AI tend toward perfect symmetry: forms perfectly centred in containers, padding equal on all sides, layouts horizontally balanced.++Polished apps often break symmetry intentionally:+- Forms aligned to a column grid, not centred in viewport+- Section padding asymmetric (more breathing room above headings than below)+- Sidebars sized to a meaningful unit (240px, 280px) not "33% / 67%"+- Dashboard cards on a 12-column grid, not all equal width+- Hero sections with asymmetric content/visual layout++**How to check**: hide content for a moment and look at structural composition.+- Does the page feel composed, or laid out by a templater?+- Is white space trapped (awkward) or shaped (intentional)?+- Compare to reference apps: Linear (asymmetric editorial), Stripe Dashboard (deliberate hierarchy), Notion (intentional density), Vercel Dashboard (informational density with whitespace).++**Findings shape**: *"Settings page form is centred in 768px container. Other pages use a left-aligned 640px column with right rail for help/docs. Centred form on settings reads as orphaned and template-generated."*++## Per-component optical pass++For every instance of these component categories on every page, verify the four-point optical check:++| Component | Verify |+|-----------|--------|+| **Buttons (primary, secondary, ghost, destructive)** | Text optically centred, icon (if any) on cap-height baseline, hover delta perceptible, focus ring visible and on token |+| **Badges / chips / tags** | Text or count optically centred (extra care for numbers), padding consistent with size variant |+| **Inputs (text, select, textarea)** | All same height per size variant, leading/trailing icons aligned to text cap height, placeholder colour from token, focus state distinct from default |+| **Dropdowns / comboboxes** | Trigger same height as inputs of same size, chevron icon optically aligned, popover follows nested-radius rule |+| **Cards** | Outer radius and inner content radius follow nested rule, padding consistent within category, shadow direction matches app-wide light source |+| **Tabs** | Active tab indicator height/colour consistent, hover state on inactive tabs distinct, alignment of tab text optically corrected |+| **Avatars** | Truly circular (border-radius: 50%, square aspect), text/initials optically centred, fallback colours from a defined palette |+| **Toasts / alerts** | Icon optically aligned with first line of text, dismiss button optically centred, severity colour from semantic token |++## Severity guide++| Severity | When to assign |+|----------|---------------|+| **High** | One component shows multiple AI-tells stacked (off-centre text + arbitrary radius + raw grey + off-scale padding). Indicates the component was generated end-to-end without polish. |+| **High** | A pattern repeats across the app (raw greys throughout, off-canonical animation timings everywhere) — signals systemic lack of design tokens. |+| **Medium** | Single recurring pattern affecting one component family (all buttons share an off-centring issue; all dropdowns have the same border-weight drift). One fix lifts many surfaces. |+| **Medium** | Light source inconsistency across more than two components. |+| **Low** | Single instance, single tell — one badge with optical-centring miss, one section with off-scale padding. |+| **Low** | Underline offset, uppercase letter-spacing — meaningful but easily forgiven by most users. |++## Tools++- **Browser DevTools eyedropper** — fastest way to verify "is this colour from the system?"+- **DevTools → Computed** — exposes the actual rendered values for every CSS property+- **DevTools → Layout overlay** — visualises grid, padding, margin+- **`getComputedStyle(el)` in console** — script to extract all computed values from a selection+- **Reference apps** for calibration: Linear, Stripe Dashboard, Vercel Dashboard, Notion, Cron / Notion Calendar, Raycast docs++## Tips++- **Run this AFTER the responsive sweep**, not before — responsive sweep often surfaces visual issues that visual polish was masking.+- **Don't stop at "it looks fine"** — the catalogue exists because most patterns require active checking, not vibes.+- **Use the eyedropper on every grey** — this single check catches more issues than any other.+- **The squint test is your friend** — for hierarchy, spacing rhythm, and overall composition.+- **Stack-rank the findings** — fix systemic patterns (token migration, light source consistency) before single-instance polish.+- **Photograph evidence** — every finding should have a screenshot with DOM inspector overlay or eyedropper readout visible. The overlay is the proof.++## What this catches that nothing else does++| Other phase | What it covers | What it misses |+|-------------|---------------|----------------|+| Thread Traversal | Friction, hesitation, dead ends, comprehension | Whether the friction is *partly* caused by visual confusion |+| Element Exhaustion | Functional behaviour of every control | Whether controls *look* trustworthy |+| Responsive Sweep | Layout breakage at different widths | Polish at any single width |+| Scenario Battery | Contextual issues (first contact, returning user, lifecycle) | Composition, optical correction, design token discipline |++Visual Polish Sweep is the only phase that asks: *"Does this look made by someone who cares, or made by an automated pipeline?"*