Spacing overlay
for AI agents.

Hover any element and Padbear tags its padding, margin, gap and radius with a tiny ID. Quote it and your AI agent swaps in the right token.

localhost:3000 - padbear enabled live overlay
Drop-in overlay · no layout shift live dashboard · 4 region kinds · 0 px touched
How it works

Spacing you can quote.

Unambiguous layout coordinates for your AI agent. Hover, or Alt+drag a scope.

Hover to inspect

The page stays clean until you hover - then spacing bands, clickable ID badges and edge guides appear.

localhost:3000 - your app, tagged
g_1
p_13 m_18
g_3
g_2
p_13 · padding-top · 16px
→ var(--space-4) exact token match

Alt+drag to scope

Drag a box - only what's inside gets inspected, with live W × H chips. Esc clears it.

p_20
m_7
240 × 168

Never touches your layout

One overlay layer, pointer-events off. Your app doesn't move a millimeter.

Tokens, not vibes

Values reconcile against your token dictionary - Tailwind, CSS vars, Sass, Dart. Never a raw pixel when a token exists.

// one command, one edit- padding-top: 17px; /* raw px */+ padding-top: var(--space-4);
TailwindCSS varsSassVueFlutter

A new way to fix spacing

No screenshots, no "the box on the left". The ID lands the edit in the right file.

You You change p_13 to 4px - the hero card is way too chunky
Your agent ✓ padding-top: var(--space-4) - traced to Hero.tsx, exact token match. Nearest token proposed for m_18.

A lens for tiny things

Tiny element? Padbear scales it up to 3×, bands and badges redrawn crisp.

r_9
3× · scaled replica
The blind spot

No vision, no browser support?
Padbear becomes your agent's eyes.

localhost:3000 - your app
check the attached images and change the padding to 4px
I cannot view or analyze images — the model doesn't have image input capability.
run npx padbear init
Done - the overlay engine is in public/ and the padbear skill is installed. Reload and hover anything.
change p_13 to 4px
Done - p_13 traces to Hero.tsx:42, and padding-top is now var(--space-4), an exact token match.
Install

One command to install.
Two words after that.

First install
your agent · first install connected
run npx padbear init in this project
$ npx padbear init
✓ padbear-engine.js → public/ dev-only script tag added
✓ .agents/skills/padbear agent skill installed
Done. Reload and hover anything.
After that
your agent · padbear installed connected
remove padbear
$ npx padbear remove
✓ engine, script tag and skill removed tokens file stays
add padbear
$ npx padbear init
✓ padbear-engine.js → public/ dev-only script tag added
✓ .agents/skills/padbear agent skill installed
Done. Reload your dev server and hover anything.

Prefer typing it yourself? npx padbear init - any web project.

The details

Small footprint, serious rules.

Everything Padbear adds to your project, on the record.

padbear-engine.js98 KB
One static file About 98 KB, zero dependencies, no build step. Copied into your static dir and that is it.
devprod<script src="padbear-engine.js" data-padbear>
You own the switch One line in your HTML - in while you tweak, out when you ship. Nothing automatic, nothing hidden in your build.
cookies0analytics0uploads0
Zero cookies, zero telemetry Every measurement happens in your browser. Nothing leaves the page - no accounts, no analytics, no uploads.
p_1316pxvar(--space-4)
Bring your own tokens Comes from your scale, not ours. The engine invents nothing - badges suggest from your system.
tailwindreactvuescsscsshtml
Any DOM stack Plus CSS Modules and plain HTML - the engine reads computed styles. Flutter gets an analyzer-based index.
padbear-engine.js→
Reversible Takes the engine, script tag and skill back out. Your token dictionary stays yours.
FAQ

Fair questions, straight answers.

Four overlay kinds: purple = padding, coral red = margin, sage green = flex/grid gap, and lime = corner radius (one r_<n> region per rounded corner). Each region carries a deterministic ID - p_1, m_41, g_2, r_9.
No. The overlay is a single document layer with pointer-events: none - only the tiny ID chips accept clicks. Your layout doesn't move a millimeter.
Anything that renders to the DOM - Tailwind, React, Vue, SCSS, CSS Modules, plain HTML - because the engine reads computed styles. Flutter is covered by an analyzer-based index instead.
Add <Script src="/padbear-engine.js" strategy="beforeInteractive" /> in app/layout.tsx - the skill's install section covers the other edge cases for you.
init doesn't invent tokens. Drop a padbear.tokens.json into your static dir - derived from your Tailwind scale or CSS variables - and badges annotate token names and suggest substitutions.
Say you ask for 17px but your scale steps 16 → 24. The agent suggests the closest token you have (16px) first. If you insist on 17px, it applies the raw pixel only after your explicit OK - and leaves a searchable marker comment in the code so it's easy to find and swap for a token later. Nothing sneaks in.
None. Every measurement happens in your browser. No accounts, no analytics, no cookies, nothing leaves the page - the engine is a plain script that reads computed styles and your own padbear.tokens.json.
Yes - they persist per session via sessionStorage, keyed by structural DOM path. A stable DOM yields stable IDs. After structural changes, rescan and everything re-tags itself.
One command: npx padbear init inside your project copies the engine into your static dir, tags your index.html with a dev-only script line, and installs the agent skill. Reload your dev server - the panel appears top-right. npx padbear remove undoes it all.