before-after
Skill4 starsChanged 19 days agoMITView on GitHub
Show whoever decides the before and after of a visual change —the published version on the left, the new one on the right and a red bar in the middle, on desktop, tablet and mobile— and push nothing until they approve; once approved, those screenshots go with the PR. Use when you finish a change that can be seen —redesign, polish, new page, responsive—, when asked "enséñame cómo queda antes de subirlo", "pásame el antes y el después" or "quiero verlo en el móvil", or before pushing the branch of anything that touches the interface.
- Installs packages
2 other projects use a version of this.
Adopted by
Most recently taken up by
- OHOKAYYEAH/claude-skillstheir own version, first seen Oct 13, 2026
- dundas/thinkruntheir own version, first seen Sep 21, 2026
Other versions2 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 2
- dundas/thinkrun★ 2same name
- OHOKAYYEAH/claude-skills★ 1same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository46 other files it gives its agents.
- AGENTS.mdAGENTS.md
- add-repo-to-docsSkill
- adrSkill
- auth-bypass-localSkill
- bug-huntSkill
- carry-envSkill
- code-healthSkill
- crux-doctorSkill
- crux-initSkill
- css-to-componentsSkill
- deploy-fallbackSkill
- deploy-watchSkill
- device-loopSkill
- drive-browserSkill
- e2eSkill
- end-sessionSkill
- eval-fixturesSkill
- explain-planSkill
- flowSkill
- grillSkill
- merge-conflictsSkill
- motion-videoSkill
- oauth-reauthorizeSkill
- prod-signalsSkill
- promote-to-docsSkill
- prose-checkSkill
- read-documentSkill
- render-loopSkill
- repo-mapSkill
- review-prSkill
- root-causeSkill
- runbookSkill
- security-auditSkill
- share-localSkill
- shipSkill
- skill-auditSkill
- skill-creatorSkill
- teachSkill
- ui-behaviourSkill
- ui-tellsSkill
- visual-diffSkill
- visual-testSkill
- wizardSkill
- workspaceSkill
- write-testsSkill
- x-postsSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 0 are distinctive, and 2 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
2
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 17
Before proposing the change (crux workspace finish), after /ship.
- Very specific: line 93
If the proposal is already open and is shown again after comments: crux visual pr <number> replaces that section instead of adding another.
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
before-after
A visual change is finished when whoever decides has seen it. This skill
prepares the before and the after for them, side by side, at three screen sizes,
so they can decide in a minute from their phone. The reason behind each step and
each gotcha: <this-skill-directory>/references/why.md.
When to use
- The diff touches something that can be seen: interface, styles, a new page, a chart.
- Before proposing the change (
crux workspace finish), after/ship. - Again if, after showing it, there were changes: from the person's comments or from the proposal's review.
When not to use
- Changes that cannot be seen: logic, backend, data, documentation.
- Iterating on a detail yourself while laying out: that is
/render-loop. - Measuring the deviation against an official design: that is
/visual-diff.
The procedure
1. Decide what is shown
The pages the diff touches, not the whole site, at three widths: desktop (1440), tablet (820) and mobile (390). If there are pieces that are not pages —a video, a PDF, a downloadable image—, they are generated and shown too, as a file.
2. Capture both versions with the same script
The before, from what is published if the base is what is deployed; otherwise, the base on another port from the main checkout. The after, from the branch, preferably with the production build locally. Both with the same script and the same data.
mkdir -p ~/.cache/visual-test && cd ~/.cache/visual-test
[ -d node_modules/playwright-core ] || npm i playwright-core >/dev/null 2>&1
cp "<this-skill-directory>/scripts/capture.mjs" .
node capture.mjs --base https://<published> --head http://localhost:<port> \
--paths /,/<other> --widths 1440,820,390 --out <folder> \
--hide '<selectors for cookie notices, chat and floating layers>'3. Assemble the comparisons
python3 "<this-skill-directory>/scripts/compose.py" <folder> --lang esIt leaves in <folder>/compare/ one montage per page and width (before on the
left, after on the right, red bar), in sections of about 3,000 px and in WebP.
4. Look at them before sending them
Open each montage. Whatever looks wrong is fixed before showing; tell capture artefacts apart (see Gotchas).
5. Show them and wait
They are sent to whoever decides through the conversation channel, with one line on what changed. Desktop and mobile first; tablet if something specific to it changes. Nothing is pushed —neither push nor proposal— until they say yes.
6. Record the yes
crux visual approve <folder>/compare --note "<what was reviewed, in one sentence>"It saves the .crux-visual receipt with the commit the capture was taken on. If
another commit goes in afterwards, the screenshots no longer show what is being
proposed: go back to step 2.
7. Propose
crux workspace finish reads the receipt and adds to the proposal a section
"Antes y después". Depending on the project's profile:
visual.publish | What it does |
branch (default) | Pushes the images to a separate branch that is never merged (visual.branch, crux-review by default) and links them in the proposal |
none (client repos) | Only the review note, without images and without leaving anything of ours in their repo |
If the proposal is already open and is shown again after comments:
crux visual pr <number> replaces that section instead of adding another.
Gotchas
- An empty chart in the capture is usually the animation restarted when the
window is resized;
capture.mjsalready waits. Check it in the browser before calling it a bug. - What loads on entering the screen needs the page to be scrolled through; the script does it.
- With a development server, the system Chrome may not paint; the production build is better.
- Cookie notices, chat and floating layers:
--hidewith their selectors, which go in the project's adapter. - Fixed elements appear at the end of the full capture: they belong to the capture, not the design.
- Only the pages the diff touched: nobody reviews twenty-seven images.
Anti-patterns
- Sending only desktop.
- Showing the after without the before.
- Pushing "so they can see it in the proposal": what is shown for approval goes before pushing.
- Publishing screenshots of an earlier commit (it is not dodged by deleting the receipt).
Related
/ship— the gate that comes before; its gate 7 is the one the agent sees/visual-test— inspect a page at both widths while working/render-loop— iterate on a layout detail/visual-diff— measure against an official design/flow— where this fits in the cycle
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

