agentleFS
elevaiteworkselevaiteworks/website-template/.claude/skills/match-reference/SKILL.md

match-reference

Skill1 starsChanged 6 months agoMITView on GitHub

Match the visual feel of a reference website to this Next.js template. Iterates on brand.config.ts (palette, fonts) and section components until the live site visually approaches the reference. Use when the user drops an image into references/ and asks to "match this reference", "match the look of X", "make it feel like this site", or similar. Uses chrome-devtools-mcp to screenshot the live dev server and compare against the reference automatically; falls back to user-described diffs if the MCP is not available.

1 other project uses a version of this.

Adopted by

Most recently taken up by

  • Other versions1 project uses a version of this.

    Word for word · 0

    None found.

    Edited · 0

    None found.

    Wrote their own version · 1

    1. Filtar2000/match-reference★ 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 repository2 other files it gives its agents.

The file

Show its rules and text

We split this skill into the rules it gives an agent

15 rules. About 0 are common, 7 are distinctive, and 8 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈7

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 8

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Before the first iteration, verify these in order.

    line 28
  2. Very specific:

    Read the reference image: Use the Read tool to load references/<filename> into your vision context.

    line 36
  3. Very specific:

    Don't rename tokens. Change *values*, not *names*.

    line 82
  4. Very specific:

    Don't edit globals.css unless brand.config.ts can't solve it.

    line 83
  5. Very specific:

    Don't edit tailwind.config.ts — it reads from brand.config.ts already.

    line 84
  6. Distinctive:

    Wait for the user's response.

    line 114
  7. Distinctive:

    When the loop ends, briefly summarize:

    line 125
  8. Distinctive:

    If the MCP isn't available, you can still run the loop — the user becomes the eyes.

    line 149
  9. Distinctive:

    Read the reference image (same as Step 1.4)

    line 151
  10. Distinctive:

    Ask the user: *"I've set the palette and fonts.

    line 153
  11. Distinctive:

    After the run completes, ask yourself:

    line 165
  12. Very specific:

    Don't change the site's *content* during a match-reference run.

    line 176
  13. Very specific:

    Don't add new sections or pages.

    line 177
  14. Very specific:

    Don't deploy. That's /launch (or just npm run build + Vercel).

    line 178
  15. Very specific:

    Don't write to MEMORY.md — this template doesn't have one.

    line 179

≈ “Common” is an estimate: at least 1 in 5 of the 364,980 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.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Match Reference — Visual Iteration Loop

The signature workflow of this template. The user drops a screenshot of a website they want to feel similar to, and you iterate on brand.config.ts + section components until the live site lands close to that reference.

The key move: you are the eyes. Take screenshots of the live dev server, compare them to the reference yourself, and describe the differences in plain language. The user steers taste; you do the visual-translation work.


When to use

Trigger phrases:

  • "Match this reference: references/<filename>"
  • "Make it feel like <site>"
  • "Match the look of references/<filename>"
  • "Try the <name> reference"

The user must have already dropped a screenshot into references/. If they only gave you a URL, ask for a screenshot first. A CSS scrape tells you what colors exist on a site; only a screenshot tells you how those colors are used (a pink hex might be a 4px badge or a full-page background — same hex, totally different vibe).


Step 1 — Preflight checks

Before the first iteration, verify these in order. Stop and surface to the user if any fails.

  1. Reference image exists. Confirm the file at references/<filename> is readable. Check it's a PNG or JPG, not just a URL the user pasted.
  2. Dev server is running. Check http://localhost:3000. If not reachable, ask the user: "Your dev server isn't running on port 3000. Want me to start it with npm run dev?" Wait for confirmation before launching it. If port 3000 is taken, Vite will auto-pick the next port (3001, 3002) — ask the user which port shows in their terminal.
  3. chrome-devtools-mcp is available. Try mcp__plugin_chrome-devtools-mcp_chrome-devtools__take_screenshot or equivalent. If the MCP isn't installed, fall back to manual mode (see "Fallback" at the bottom). Don't fail silently — tell the user: "I'll do the visual loop in manual mode (you describe what's off, I edit). For the auto loop, install chrome-devtools-mcp."
  4. Read the reference image. Use the Read tool to load references/<filename> into your vision context. Identify before doing anything else:
    • 4–6 hex colors that capture the palette (background, primary, accent, text, muted). Note which color dominates — the most-used color is usually the bg, not the brand color.
    • Font feel: serif vs sans, geometric vs humanist, condensed vs wide, light vs heavy. Pick Google Font names that match (e.g. "Inter", "Fraunces", "Poppins", "Space Grotesk"). If headlines look chunky, the body weight target is 800–900.
    • Button shape: square, rounded, or pill. Solid or outline.
    • Spacing: tight vs airy. Sharp vs rounded corners. Minimal vs decorative.
    • One-line overall feel: "warm editorial," "minimalist tech," "playful saas," "luxury serif," etc.
  5. Read the current brand.config.ts so you know where you're starting from.

Step 2 — Run the match loop

Repeat the following until the user says "ship it" or "let's go a different direction." Max 5 rounds before pausing to check in — long loops fatigue the user's eye.

Round structure

(a) Screenshot the live site.

Use chrome-devtools-mcp:

  1. Navigate to http://localhost:3000
  2. Resize viewport to desktop: 1440 × 900
  3. Take a full-page screenshot to references/_iterations/desktop-round-<N>.png (create the _iterations/ folder if needed; it should be gitignored)
  4. Resize to mobile: 375 × 812
  5. Take another screenshot to references/_iterations/mobile-round-<N>.png

You should now have the reference image AND the current state of the site in your vision context.

(b) Articulate the diff.

Compare reference → current. List 3–6 visible differences in priority order:

  1. Palette — what colors are off? (most rebrands resolve here)
  2. Typography — fonts, weights, sizes wrong?
  3. Spacing — too tight, too loose, wrong rhythm?
  4. Component shape — buttons, cards, corner radius, borders?
  5. Decorations — gradients, shadows, blurs, noise grain

Be specific. "Buttons in the reference are pill-shaped with no shadow; ours are rounded squares with a subtle drop-shadow" beats "buttons look different."

(c) Pick the next edit.

Edit brand.config.ts first. Most rebrands resolve 90% at this layer. Only touch components if the config can't address the diff (e.g., button shape, hero layout, section padding).

Rules:

  • Max 2–3 changes per round. Small steps are easier to evaluate.
  • Don't rename tokens. Change values, not names. primary: "#1A365D" → primary: "#0F172A" keeps every component working.
  • Don't edit globals.css unless brand.config.ts can't solve it.
  • Don't edit tailwind.config.ts — it reads from brand.config.ts already.

(d) Apply, wait for hot reload (~1–2 sec), re-screenshot.

Take fresh screenshots at desktop + mobile after the edit lands.

(e) Show the user.

Surface this exact pattern between rounds:

ROUND <N>

Reference:        references/<filename>
Current desktop:  references/_iterations/desktop-round-<N>.png
Current mobile:   references/_iterations/mobile-round-<N>.png

What I changed: <one-line summary of the edit>

What's still off:
- <diff 1>
- <diff 2>
- <diff 3>

What I'm planning next (won't run until you say "go" or "closer"):
- <next edit>

Closer, further, different direction, or ship it?

Wait for the user's response. Don't loop autonomously — the user steers taste at every round.


Step 3 — Stop conditions

End the loop when any of these is true:

  • User says "ship it," "looks good," or "stop"
  • 5 rounds have completed without convergence — pause and ask: "We've done 5 rounds. Want to keep going, lock in what we have, or try a different reference?"
  • You hit a pixel-clone wall (see "Honest limits" below)

When the loop ends, briefly summarize:

  • Final state of brand.config.ts (colors + fonts now set to: ...)
  • Components touched (if any)
  • Suggested next move: "Want to keep customizing copy now? Run /add-section or just open content/home.md."

Honest limits

You can match palette, type, spacing, button shape, and overall vibe.

You cannot pixel-clone:

  • 3D heroes, custom illustrations, complex SVG art
  • Bespoke animations (parallax stacks, scroll-pinned transforms, custom WebGL)
  • Photography-heavy editorial layouts that depend on the actual photos
  • Interactive product demos
  • Brand-specific custom fonts (use the closest Google Font alternative and name it)

When you hit one of these walls, say so clearly: "The reference has a custom 3D illustration in the hero — that's outside what we can clone with brand.config alone. Closest we can get is the surrounding palette + type; the illustration would need a designer." Don't pretend.


Fallback (no chrome-devtools-mcp)

If the MCP isn't available, you can still run the loop — the user becomes the eyes.

  1. Read the reference image (same as Step 1.4)
  2. Edit brand.config.ts based on your read of the reference
  3. Ask the user: "I've set the palette and fonts. Open localhost:3000 in your browser. What's still off vs. the reference? Be specific — colors, fonts, spacing, button shapes, anything."
  4. Make 2–3 edits based on their feedback
  5. Loop

This is slower per round (5–10 sec MCP screenshot replaced with 1–2 minutes of user looking + describing) but works without any setup.

Encourage the user to install chrome-devtools-mcp for future iterations: "Heads up — installing chrome-devtools-mcp lets me see your site directly and iterate way faster. Optional but recommended."


Self-improvement loop

After the run completes, ask yourself:

  • Did I edit components when brand.config.ts would have worked? (rule violation — surface it)
  • Did I make more than 3 changes in one round? (rule violation)
  • Did the user redirect more than twice on the same dimension (e.g., "the orange is still too saturated")? If yes, I should have anchored on a hex sample from the reference and matched exactly, not eyeballed.

Note any patterns you'd add to this skill next time. Don't edit this skill mid-run — surface the note to the user at the end so they can decide whether to fold it in.


Out of scope

  • Don't change the site's content during a match-reference run. Copy edits belong in content/*.md via a separate ask.
  • Don't add new sections or pages. That's /add-section and /add-page.
  • Don't deploy. That's /launch (or just npm run build + Vercel).
  • Don't write to MEMORY.md — this template doesn't have one. Match outputs that need to persist go in the user's CHANGELOG.md if they choose.

Download now (ZIP)

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
What did you use it for? e.g. Reviewing pull requests in a Rails app

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.