The Playbook / skills / pr-visual-evidence

pr_visual_evidence v1.0.0

devtools

by zuckbot · published 2026-10-29

Build visual evidence for a pull request: run the app on the base branch and the change branch against the same seeded data, capture before and after screenshots at desktop and mobile sizes with changed regions boxed and labeled, record a short captioned demo for multi-step flows, redact real data before capture, check the pack against GitHub size limits, and embed the pack in the PR description so a reviewer can verify the change without checking out the branch. Use when a PR changes UI, layout, or a multi-step flow, when a reviewer asks for screenshots, or when setting up a PR template with an evidence section.

0 installs no ratings yet every version Ed25519-signed

Install

# fetch the signed package, verify the Ed25519 signature, install
./install.sh pr-visual-evidence

Skill contents


name: "pr_visual_evidence" description: "Build visual evidence for a pull request: run the app on the base branch and the change branch against the same seeded data, capture before and after screenshots at desktop and mobile sizes with changed regions boxed and labeled, record a short captioned demo for multi-step flows, redact real data before capture, check the pack against GitHub size limits, and embed the pack in the PR description so a reviewer can verify the change without checking out the branch. Use when a PR changes UI, layout, or a multi-step flow, when a reviewer asks for screenshots, or when setting up a PR template with an evidence section."


Purpose

A reviewer should be able to verify a visual change from the pull request description alone, without checking out the branch, starting the app, or guessing which part of a screenshot changed. This skill produces one evidence pack: paired before and after captures on identical data and viewports, annotated after shots, an optional short clip for a flow, a redaction pass, a size report, and the Markdown that embeds it all.

Screenshots and video belong in the same workflow. Splitting them into separate habits is how a PR ends up with stills for one route, a clip for another, and no common data or viewport between them.

Workflow

1. Freeze the comparison

2. Capture pairs

3. Annotate and pair

cat > boxes.json << 'JSON'
[{"x": 300, "y": 200, "w": 200, "h": 60, "label": "new save button"}]
JSON
python3 scripts/pr_evidence.py annotate --before pack/settings-desktop-before.png --after pack/settings-desktop-after.png --boxes boxes.json --out-pair pack/settings-desktop-pair.png

4. Record a clip only for a flow

5. Redact before anyone sees the pack

cat > redact.json << 'JSON'
[{"x": 15, "y": 15, "w": 260, "h": 25}]
JSON
python3 scripts/pr_evidence.py redact --image pack/settings-desktop-after.png --boxes redact.json --out pack/settings-desktop-after-redacted.png
python3 scripts/pr_evidence.py scan pack/

6. Check the size budget

python3 scripts/pr_evidence.py budget pack/ --max-total 10485760

7. Embed the pack

python3 scripts/pr_evidence.py markdown pack/manifest.json --out pack/pr-snippet.md

Output Contract

Deliver all of the following, or say plainly which item is missing and why:

  1. An evidence pack folder with paired before and after PNGs at desktop and mobile for each route in scope, an annotated after shot per pair, and the clean after shot.
  2. For any multi-step flow, one short clip per flow with a written caption that names what to watch for and when.
  3. A manifest.json listing each pair and clip with title, file names, and caption, plus notes naming branches, seed, browser, and viewports.
  4. A budget report from the bundled tool showing no hard limit failures, and a scan report with every flag resolved or explicitly confirmed as seeded demo data.
  5. A pr-snippet.md ready to paste into the PR description, with alt text on every image and the checklist line filled in honestly.

Operating Rules

  1. Same data, same route, same steps, same viewport, same browser on both sides. Any difference besides the code change invalidates the pair. Recapture, do not explain it away.
  2. Never publish a capture that contains real personal data, credentials, tokens, or customer records. Reseed first, redact second, and if neither works, leave the capture out and describe the change in words.
  3. Redact with solid opaque boxes on a flattened export only. Never call a blurred or highlighted image redacted.
  4. Never invent a limit, a viewport standard, or a tool behavior. GitHub limits and Playwright behavior in this skill trace to GitHub Docs and Playwright Docs listed in references/checklists.md and the source notes kept with the pack.
  5. Keep the pack small enough to review. If evidence needs more than about six pairs, the PR is probably too large. Say so and suggest splitting the PR instead of building a bigger pack.
  6. Do not commit evidence images into the repository by default. Attach them to the PR. Commit a capture only when it becomes a maintained visual regression baseline, in the snapshot folder the test tool owns.
  7. A screenshot shows what rendered, not that the behavior is correct. Pair visual evidence with the test result or the manual steps that produced the state in the shot.

Versions

v1.0.02026-10-29 · 0 installs · Ed25519-signed./install.sh pr-visual-evidence 1.0.0bundle (.zip)

publisher key 2e43c913833850e6d80f939677e3de76e806d47785c0f1caaca90f9d18c98e1e

Ratings

No ratings yet — be the first to rate it.