chrome-development
Expert guidelines for Chrome extension development with Manifest V3, covering security, performance, and best practices. Use when building browser extensions,…
Mathematical spacing, sizing, weight, line-height, letter-spacing, radius, and padding rules for "productive" SaaS interfaces, across density regimes: Dense (Linear / Doppler / Raycast / Vercel), Comfortable/roomier (Cal.com style), and anything in between. Use this whenever you
$ npx -y skills add HarKro753/claude-copy --skill dense-ui-metrics --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/dense-ui-metricsContext preview
The summary Claude sees to decide when to auto-load this skill.
Mathematical spacing, sizing, weight, line-height, letter-spacing, radius, and padding rules for "productive" SaaS interfaces, across density regimes: Dense (Linear / Doppler / Raycast / Vercel), Comfortable/roomier (Cal.com style), and anything in between. Use this whenever you
name: dense-ui-metrics description: >- Mathematical spacing, sizing, weight, line-height, letter-spacing, radius, and padding rules for "productive" SaaS interfaces, across density regimes: Dense (Linear / Doppler / Raycast / Vercel), Comfortable/roomier (Cal.com style), and anything in between. Use this whenever you are building OR refining any such UI — dashboards, data tables, sidebars, toolbars, filter bars, forms, inputs, buttons, badges/pills, KPI tiles, nav items, list rows, icon rails — or whenever you're picking font-size, weight, line-height, letter-spacing (tracking), padding, gaps, corner radius, or control heights, even if the user doesn't name a grid. Trigger it when spacing "looks off," when values are arbitrary (p-[13px], gap-18px, radius-7px, height: 60px), when snapping a design to an 8px grid, or when the user mentions tracking, density, Inter/SF Pro metrics, or wants a component to feel "tight" and premium. Prefer this over eyeballing numbers.
A single source of truth for the numbers that make productive SaaS UIs feel engineered rather than hand-placed. Every value traces to an industry spec: Inter Dynamic Metrics (Rasmus Andersson) for tracking, IBM Carbon 2x grid + Material Design 3 8dp grid for spacing/density, Bringhurst / Carbon Productive sets for type. The point of encoding it is that "premium" isn't taste — it's a small set of locked relationships. Follow them and the rhythm holds; break one and the eye notices even when the user can't say why.
**The model in one breath:** a small set of **universal laws** (this file) applied at a chosen set of **anchors** (a *regime*). Laws never change; anchors slide with density. Regimes are named points on a continuous axis, **not** boxes every app falls into — if a design matches no preset, read its base font size and base padding off the reference and apply the laws at those numbers.
freedom) + the apply-loop + self-check. Read top to bottom; it's the whole method.
(Dense + Comfortable): per-role font size, weight, line-height, tracking, padding, height. **Read this when you need concrete numbers for a component.**
reduce to a single-line control: multi-line list rows, icon-only nav rails, corner- radius scale, row-separation strategy (zebra vs borders vs whitespace), inline code chips. **Read this when building lists, rails, cards, or choosing radii/separators.**
1. **Pick the regime, then the component role.** Regime = density anchor set (Dense / Comfortable / read-your-own). Then find the role's row in `references/regimes.md` — it gives size, weight, line-height, tracking, and padding at once. Don't mix values across roles or across regimes on one screen. 2. **Snap every spacing value to the grid** (§Spatial scale). Padding, margin, gap, offsets. No arbitrary numbers — `13px`, `18px`, `60px` are smells. Nearest step wins. 3. **Derive height, don't set it.** `H = L + 2·Py` (Degree 4). A 36px control is `20px line-height + 2×8px`, not a magic `height: 36px` with mystery padding. (Multi- line rows are the exception — see `references/component-patterns.md`.) 4. **Apply tracking by font size** (§Tracking). Small text loosens (positive), large text tightens (negative). Headings left at `0` look soft; body over-tightened looks cramped. This is where cheap UIs give themselves away. 5. **Vary only along the degrees of freedom** (§Degrees of freedom) when a design needs to breathe or compress. Those axes are the *only* sanctioned ways to move off the defaults without breaking rhythm.
IBM Plex Sans. High x-height is what keeps 12–14px text legible at density.
SF Mono, Fira Code. Use for anything that aligns in columns (secrets, hashes, numbers in tables) and for inline code chips (see `references/component-patterns.md`).
Tracking is a function of size, from the Inter metrics spec:
Tracking(z) = -0.0223 + 0.185 · e^(-0.1745·z) # z = font size in px, result in em
You rarely need to compute it — this lookup covers the common sizes (the formula evaluated):
| Size | Tracking | | Size | Tracking | |---|---|---|---|---| | 10px | `+0.010em` | | 18px | `-0.014em` | | 11px | `+0.005em` | | 20px | `-0.017em` | | 12px | `0.000em` | | 24px | `-0.020em` | | 13px | `-0.003em` | | 28px | `-0.021em` | | 14px | `-0.006em` | | 32px | `-0.022em` | | 16px | `-0.011em` | | 40px+ | `-0.022em` (asymptote) |
Rule of thumb: **≤12px loosens, ≥14px tightens, and it never goes past ≈-0.022em.** At 12–14px the delta is sub-pixel — real but subtle; at 20px+ it's clearly visible and is the single highest-leverage fix for a heading that looks unrefined.
All padding, margin, gap, and layout offsets come from here:
`4 · 8 · 12 · 16 · 24 · 32 · 48 · 64px` (4px is the micro-unit for icon-to-text and pill internals).
Four roles, each ~1.5–2× the previous (Degree 3):
Dark-surface detail: on deep backgrounds (`#0d0d10`–`#16171a`) use translucent hairline borders (`rgba(255,255,255,0.08)`–`0.1`) rather than solid greys — they read as one crisp pixel instead of a muddy line.
The defaults aren't a straitjacket. There
Expert guidelines for Chrome extension development with Manifest V3, covering security, performance, and best practices. Use when building browser extensions,…
Clone a captured website into pixel-verified static HTML — a capture session (pages.json plus one folder per page holding ref.png, source.html, computed.json,…
Recreate a single flat image as one self-contained HTML page, verified by rendering it and comparing to the image — no capture, no DOM, no HTML input. Use when…
Clone a captured website into verified shadcn/ui React components — a capture session becomes one component per route with its captured states as props, themed…
When the user wants to write, rewrite, or improve marketing copy for any page — including homepage, landing pages, pricing pages, feature pages, about pages,…
Build, validate, and distribute Claude Code plugins — the packaged form of skills, agents, hooks, MCP/LSP servers, monitors and `bin/` executables, with a…