From qe-framework
Captures and compares rendered screenshots against reference images to detect visual regressions in layout, color, font, alignment, and spacing using Chrome.
How this skill is triggered — by the user, by Claude, or both
Slash command
/qe-framework:Qvisual-qaThe summary Claude sees in its skill listing — used to decide when to auto-load this skill
This skill compares **rendered screens** against reference images. It does NOT audit source code.
This skill compares rendered screens against reference images. It does NOT audit source code.
| Request | Action |
|---|---|
| "Compare screen", "visual test", "screenshot comparison" | This skill |
| "Review UI code", "accessibility check" | NOT this skill — use Qweb-design-guidelines |
| "Set up Chrome MCP" | NOT this skill — use Qchrome |
Before starting, verify the MCP is available:
claude mcp list 2>/dev/null | grep -i chrome
Connected → proceed with workflow. Not connected → warn user:
Claude-in-Chrome MCP is not connected.
Alternatives:
1. Use the Qchrome skill to set up Chrome MCP.
2. Use the Qagent-browser skill to manually collect screenshots.
3. If you provide screenshots directly, comparison can proceed from Step 4 onward.
Do NOT attempt browser steps without MCP connection.
If user provided URLs: use them directly. If not provided: auto-detect from project routes.
# TanStack Router
grep -r "createRoute\|path:" <project>/src --include="*.tsx" -h | grep "path:" | sort -u
# Next.js / file-based routing
find <project>/src/app -name "page.tsx" | sed 's|.*app/||; s|/page.tsx||'
# React Router
grep -r "<Route" <project>/src --include="*.tsx" -h | grep -oP 'path="[^"]+"'
Ask user to confirm the detected list before proceeding.
For each URL, locate the reference image using this priority:
| Priority | Source | Path pattern |
|---|---|---|
| 1 | Stitch export | **/screen.png, **/designs/*.png |
| 2 | Committed baseline | .visual-baseline/<route-slug>.png |
| 3 | No reference | Inform user — first run will set baseline |
find . -name "screen.png" 2>/dev/null | head -20
ls .visual-baseline/ 2>/dev/null
For each URL in the list:
tabs_context_mcp → get current tab state
navigate(url) → load the page
resize_window(1440, 900) → standard viewport
computer("screenshot") → capture current state
Save each screenshot as: .visual-baseline/current/<route-slug>.png
If a page requires auth, ask the user to log in and confirm before continuing.
For each (current, reference) pair, analyze using the Read tool (image mode):
Dimensions to check:
| Category | What to detect |
|---|---|
| Layout | Component position shifts, missing sections, overflow |
| Colors | Background, text, border color changes |
| Typography | Font size, weight, line-height differences |
| Alignment | Horizontal/vertical alignment drift |
| Spacing | Padding/margin changes (gaps between elements) |
| Responsive | Clipping or overflow at the target viewport |
Rate each finding:
Output a structured report:
## Visual QA Report — <date>
### Summary
| Metric | Value |
|--------|-------|
| URLs tested | N |
| Passed | N |
| Failed | N |
| Critical | N |
| Major | N |
| Minor | N |
### Findings
#### [CRITICAL/MAJOR/MINOR] <Route> — <short description>
- **URL**: <url>
- **Finding**: <what changed>
- **Location**: <component or region>
- **Reference**: <reference image path>
- **Current**: <current screenshot path>
For each CRITICAL or MAJOR finding, if the user requests it:
Fix suggestion available for <N> findings. Apply? (y/n/select)
Set new baseline (first run or intentional reset):
mkdir -p .visual-baseline
cp .visual-baseline/current/*.png .visual-baseline/
Update baseline for a single route (after confirmed fix):
cp .visual-baseline/current/<route-slug>.png .visual-baseline/<route-slug>.png
Add .visual-baseline/current/ to .gitignore. Commit reference baselines.
| Step | Tool / Command |
|---|---|
| MCP check | claude mcp list | grep chrome |
| Route detect | grep for createRoute, <Route, page.tsx |
| Screenshot | computer("screenshot") via MCP |
| Compare | Read tool (image mode) — side-by-side analysis |
| Save baseline | cp current/*.png .visual-baseline/ |
Qweb-design-guidelines)npx claudepluginhub inho-team/qe-framework --plugin qe-frameworkCreates, edits, and optimizes skills for Claude Code, including drafting, evaluating with test prompts, iterating on performance, and improving skill descriptions for better triggering accuracy.