Skip to content
Back to skills

audit-design-tokens

ASecurity

Scans a codebase for design token drift - raw hex colors, off-scale spacing, near-duplicate colors, font sprawl, hardcoded z-index. Use when asked to "audit my design tokens", "find hardcoded colors in this codebase", "check for design token drift", or "clean up our CSS variables". Returns a severity-ranked report with file:line refs and a plan. Do not use to generate tokens from a screenshot or URL - use extract-design-tokens instead.

  • 2 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added October 23, 2026
ai-agentsgovuenodegit

Works with

  • cli

Security analysis

A100/100

Pro scans all 2 files and shows the line behind each finding

Scanned December 4, 2026

npx -y skills add humbleteam/audit-design-tokens --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of audit-design-tokens?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for audit-design-tokens
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/humbleteam-audit-design-tokens/badge)](https://www.skillsdirectory.com/skills/humbleteam-audit-design-tokens)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: audit-design-tokens
description: Scans a codebase for design token drift - raw hex colors, off-scale spacing, near-duplicate colors, font sprawl, hardcoded z-index. Use when asked to "audit my design tokens", "find hardcoded colors in this codebase", "check for design token drift", or "clean up our CSS variables". Returns a severity-ranked report with file:line refs and a plan. Do not use to generate tokens from a screenshot or URL - use extract-design-tokens instead.
---

# Audit design tokens

Find every place a codebase drifted away from its own design tokens, rank the drift by
how much damage it does, and hand back a plan to fix it one small step at a time.

## When this skill applies

The user has an existing codebase with some notion of design tokens - a `:root` block of
CSS custom properties, a `tailwind.config.js` theme, a `theme.ts` / `tokens.json` file, or
styled-components theme object - and wants to know where the code stopped using them.

If there are no token definitions anywhere in the codebase, stop the audit and say so (see
Edge case: no tokens found below). Auditing drift against tokens that do not exist produces
nothing useful.

## Step 1: find the token source of truth

Search the target path (default: repo root, or the path the user names) for token
definitions, in this order:

1. CSS custom properties: `--[A-Za-z0-9_-]+\s*:` inside `:root`, `:host`, or a
   `[data-theme]` selector - match the declaration, then classify by the value. Matching on
   the value instead finds only part of the set: a pattern anchored to `#|rgb|hsl|oklch`
   returns colors only, and one whose name class excludes digits also drops
   `--blue-500` and `--gray-100`, which is how most palettes are named. Both misses are
   worse than no match at all, because an undiscovered token is not treated as missing -
   it is treated as absent, and every correct use of its value elsewhere in the codebase
   is then reported as raw drift against a token that exists.
2. Tailwind config: `theme.colors`, `theme.spacing`, `theme.extend.colors`,
   `theme.extend.spacing` in `tailwind.config.js` / `.ts` / `.mjs`.
3. A dedicated tokens file: `tokens.json`, `theme.ts`, `theme.js`, `design-tokens.*`.
4. styled-components / Emotion theme objects passed to `ThemeProvider`.

Record every token found as `name -> value` per category. The value's shape decides what a
token can be, and the name only splits the categories the shape cannot tell apart, since
`--space-3: 12px`, `--radius-md: 8px` and `--font-size-lg: 1.25rem` are all one length:

| Value shape | Category |
|---|---|
| `#hex`, `rgb()`, `rgba()`, `hsl()`, `hsla()`, `oklch()`, a named CSS color | color |
| an offset/blur/spread list ending in a color | shadow |
| a bare integer | z-index |
| a single length in `px`, `rem`, `em` | spacing, radius, or font-size - split on the name (`space`/`gap`/`inset`, `radius`/`corner`, `font`/`text`/`size`) |

Shape wins over name where they disagree: `--brand-blue: 8px` is a length, so it is not a
color whatever it is called. A length whose name matches none of the three groups is
recorded as spacing, the scale it most often belongs to, and named in the report as an
assumption.

**A token's value is scoped to a theme, so the record is `name -> value per theme`.** Step 1
searches `:root`, `:host` and `[data-theme]` selectors, and a themed codebase defines the same
name in more than one of them on purpose: `--color-surface` is `#FFFFFF` in the base block and
`#111111` under `[data-theme="dark"]`. One name against one value keeps whichever block was
read last and drops the rest of the palette, which is the half the report needs most, since P0
is defined by what happens under an alternate theme. Treat the base block as the default theme,
record each override under the selector carrying it, and list the themes found in the summary.
Two things downstream depend on it:

- **Nearest token is resolved inside one theme.** Compare a literal against the palette of the
  theme its call site renders in - the theme selector it sits under, or the default theme when
  it sits under none. A literal inside a dark block compared against the light palette comes
  back with the token whose value is furthest from it, and the suggested fix then paints a dark
  surface with a light one. Where a name exists in several themes, the `Nearest token` cell is
  still just the name: `var(--color-surface)` is correct in every theme, which is the point of
  the token.
- **Near-duplicate pairs are found inside one theme.** Two values that never render together
  are not a merge candidate. One name across two themes is never a pair - that is the token
  doing its job - and two names that sit within 5% lightness in one theme but not in another
  are a pair only in the theme where they collide, so the row names that theme.

This list is the baseline every other file gets checked against. If more than one source
exists (e.g. CSS variables AND a Tailwind config), treat both as valid tokens - report a
value as drift only if it matches neither.

**Then write down which categories have a baseline and which do not.** A codebase with a
`:root` block of brand colors and no spacing scale is normal, not broken, and it is the
common starting shape. The stop rule above fires only when the token set is completely
empty, so a partial set reaches Step 2 and every category it does not cover has nothing to
be checked against. Carry that list into Steps 2 and 3 - it decides what can be audited at
all.

## Step 2: scan for drift

Walk `.css`, `.scss`, `.less`, `.tsx`, `.jsx`, `.ts`, `.js`, `.vue`, `.svelte`, and inline
`style=` attributes in `.html`. Skip `node_modules`, `dist`, `build`, `.next`, `vendor`, and
lockfiles. For each category below, collect every match with its file and line number.

A literal that is the fallback inside a token reference - the `#2563eb` in
`var(--brand, #2563eb)`, the `13px` in `var(--space-3, 13px)` - is not matched as a raw value
by any category below. It sits beside a token reference rather than in place of one, so it is
checked against that token instead, per the fallback edge case at the end of this file.

- **Raw colors outside token definitions.** Any `#rrggbb`, `#rgb`, `rgb(...)`, `rgba(...)`,
  `hsl(...)`, or `hsla(...)` literal that is not itself the right-hand side of a token
  definition found in Step 1. This is the highest-value category - it is what makes theming
  and dark mode break.
- **Off-scale spacing.** Any `margin`, `padding`, `gap`, `top/right/bottom/left`, or `width/
  height` value in `px` or `rem` that is not a multiple of the codebase's spacing base and is
  not itself a spacing token reference. `padding: 13px` on a 4px scale is drift;
  `padding: 16px` is not. Infer the base from the spacing tokens Step 1 recorded - the
  greatest common divisor of the scale, usually 4px or 8px. **If Step 1 found no spacing
  tokens, there is no base and this category is not audited.** Do not fall back to 4px or
  8px because they are common: a codebase that never had a spacing scale would have every
  odd value reported as drift against a standard it never adopted, which is the same
  invented baseline the no-tokens stop rule exists to prevent, applied one category at a
  time instead of all at once.
- **Near-duplicate colors.** Group all raw and token colors by hue (convert to HSL). Flag
  pairs whose lightness differs by less than 5%, or whose values differ by a handful of hex
  units, and which carry the same role - background, text, or border - since two close colors
  doing different jobs are a contrast decision rather than a merge candidate. **Role is not
  one of the Step 1 categories, and nothing before this point has recorded it, so derive it
  per side.** A literal's role is the property of the declaration it sits on, which this walk
  is already reading to get the line number: `background`/`background-color` is background,
  `color` is text, `border-*` and `outline-*` are border, and the color ending a `box-shadow`
  is shadow. A token's role is its call sites - the `var(--name)` occurrences the same walk
  passes over - and its own name only where the name states the role outright
  (`--color-bg-*`, `--text-*`, `--border-*`). Step 1 records `name -> value` and never visits
  a call site, so a token whose name says nothing and which is referenced nowhere has no
  derivable role at all, and that lands hardest on the pair that matters most: token and
  token is the only shape that earns its own row, and it is the one shape where neither side
  sits on a declaration to be read. **A pair with one or both roles underivable is still
  reported, with the unknown side named in the fix cell and the fix asked as a question
  rather than written as a merge.** Dropping it would have the gate discard exactly the
  findings it exists to catch, and discard them silently - no count, no row, nothing
  downstream showing that a pair was seen and set aside. Record what each side of the pair
  is, because that decides whether the pair is a finding of its own or a property of one
  already open:
  - **Token and token.** Neither side is drift, so nothing else in the report covers it.
    This is the shape that earns its own P2 row, and its fix edits the token set - merge the
    two, keep the better-named one, and propose the rename for the loser's call sites.
  - **Literal and token.** The literal is already a raw-color finding, and the token it
    nearly duplicates is the `Nearest token` for that row. Replacing the literal dissolves
    the pair, so it does not open a second row - say `near-duplicate of the token` in the
    existing row's fix instead.
  - **Literal and literal.** If a color baseline exists, both sides are raw-color rows
    pointing at the same nearest token, and the pair dissolves with them. If no color
    baseline exists, neither side is drift against anything, and the pair is the whole
    finding: one P2 row naming both locations, with the fix being to converge on one value
    and define it as the token that was missing.
- **Font-size sprawl.** Collect every distinct `font-size` value in the codebase, raw or
  token. A single product's considered scale is 8-10 distinct sizes, and **a row opens at
  11** - list every value with a count of how many places use it, sorted descending.
- **Radius and shadow variants past their scale.** Most products need at most `sm` / `md` /
  `lg` radius and 2-3 shadow depths. Count distinct `border-radius` and `box-shadow` values
  actually in use. The two categories open a row at different counts, because their scales
  are different sizes and one of them has a legitimate fourth value: **a row opens at 5
  distinct radius values, and at 4 distinct shadow values.** Radius gets the extra step
  because a pill or fully-rounded value - `9999px`, `50%` - is a shape rather than a fourth
  point on the ramp: it does not interpolate with `sm`/`md`/`lg` and a product reaches it
  deliberately, not by accretion. Nothing plays that role for shadow, where every value is a
  point on one elevation ramp, so a fourth depth is already past the scale. A count below
  the bound is reported and opens nothing.
- **Hardcoded z-index stacks.** Any numeric `z-index` value not pulled from a token or a
  shared constant. Collect all of them sorted by value - an ungoverned z-index list is a
  common source of stacking bugs even when nothing else in the design system has drifted.

**A category with no baseline is not scanned as drift.** Drift means a distance from a
known-good value, so where Step 1 found no token of that category there is nothing to
measure against and every literal would be reported as a violation of a rule the codebase
never set. This applies to raw colors and off-scale spacing, which need a token to drift
from. It does not apply to font-size sprawl, radius and shadow variants, or near-duplicate
colors: those compare the codebase against itself, so they run on any codebase. Hardcoded
z-index runs too - with no z-index token every literal is ungoverned, which is the finding
rather than a false positive, and it stays P2.

## Step 3: write the report

Output in this exact structure. Use real file paths and line numbers from the scan - never
invent a location.

```markdown
# Design token audit - <path scanned>

## Summary
- Token sources found: <list, e.g. "CSS custom properties (32 tokens), tailwind.config.js theme (8 colors)">
- Themes found: <list, e.g. "default (:root), [data-theme=dark]" - or "default only">
- Categories with a baseline: <list> · no baseline: <list, or "none">
- Raw colors outside tokens: <count>
- Off-scale spacing values: <count>
- Near-duplicate color pairs: <count> (<n> token-to-token, <m> dissolved by the raw-color rows)
- Distinct font sizes in use: <count> (target: 10 or fewer)
- Radius variants: <count> (target: 4 or fewer) · Shadow variants: <count> (target: 3 or fewer)
- Hardcoded z-index values: <count>

## P0 - breaks theming
Hardcoded colors on interactive states (hover, focus, active, disabled) or on anything that
changes under a `[data-theme]` / dark-mode selector elsewhere in the codebase.

| File:line | Value | Nearest token | Suggested fix |
|---|---|---|---|
| src/Button.tsx:42 | #2563EB | --color-primary (#2563EB) | replace literal with var(--color-primary) |

## P1 - scale drift
Off-scale spacing, font-size sprawl, radius/shadow variants beyond the established scale.

| File:line | Value | Nearest token | Suggested fix |
|---|---|---|---|

## P2 - consolidation candidates
Near-duplicate colors, one-off z-index values, anything safe to leave but worth merging.

| File:line | Value | Nearest token | Suggested fix |
|---|---|---|---|

## Proposed renames (do not apply silently)
A rename earns a line here for one of two reasons, and the line says which:
- **The name no longer matches its use** (e.g. `--blue-500` used as an error color).
- **A token-and-token near-duplicate merges into a survivor** (Step 2's P2 pair). The loser's
  name may be perfectly accurate; its call sites still have to move to the survivor's name,
  so the move is proposed here like any other rename.

Nothing else qualifies - a name you would merely prefer is not a finding. List old name ->
proposed name -> reason -> every call site. Do not rename in the report itself - this is a
proposal for the user to approve.

## Consolidation plan
Ordered, smallest-diff-first. Each step is a single PR-sized change that ships independently
without waiting for the others. A step that applies a rename from the proposed-renames section
carries the one precondition a step may carry: it waits on the user's approval of that
proposal, never on another step. Such a step names the gate in its own line, keeps the place
its size earns it, and leaves every other step shippable whether the approval arrives or not.

1. <one file or one component, e.g. "Replace 6 raw #2563EB literals in src/Button.tsx and src/Link.tsx with var(--color-primary)">
2. <next smallest step>
3. ...
```

Reconcile the summary against the tables before shipping the report. The summary carries two
kinds of number, and only one of them is a row count:

- **Drift counts** - raw colors, off-scale spacing, hardcoded z-index. Each of these
  findings is a row in exactly one of the P0/P1/P2 tables, so the summary count must equal
  the number of rows carrying that category across all three tables.
- **Near-duplicate pairs** are counted but not row-matched, and they are the one category
  where a literal carries two categories at once: a raw `#F7F7F7` next to a
  `--color-surface-muted: #F8F8F8` is both a raw-color finding and half a pair. Row-matching
  it would put the same literal in two tables and bill the same fix twice, since replacing
  the literal with the token also ends the pair; dropping the pair from the count instead
  would hide a real observation. So state the count and its split, and let each pair land
  where Step 2 puts it: `Near-duplicate color pairs: 3 (1 token-to-token, 2 dissolved by the
  raw-color rows above)`. Only the pairs that opened their own row are rows, and the split is
  what reconciles the number. A pair that does open a row is one row naming both locations,
  never two.
- **Inventory counts** - distinct font sizes in use, radius variants, shadow variants. These
  count distinct values in the codebase, most of which are not drift, so they never match a
  row count: a clean codebase with six tokenized font sizes reports 6 and opens no rows at
  all. Reconcile them against the values instead - state the count, list the distinct values,
  and open a P1 row only for what is past the threshold. That row is a shape the three
  tables were not built for, since they are keyed by `File:line` and sprawl has no single
  line - see the edge case below for how it is filled, why it stays one row, and why that
  one row is the only finding whose consolidation plan runs to several steps.

  Each of the three carries its threshold on the summary line, because the count alone does
  not say whether it is a finding: `Radius variants: 5` reads as a fact, and only the bound
  makes it the same kind of statement as `Raw colors outside tokens: 5` one line above. The
  bounds are Step 2's, and what the line prints is the one that opens a row - 10 or fewer
  font sizes, 4 or fewer radius variants, 3 or fewer shadow variants - not the typical scale
  Step 2 also names (8-10 sizes, `sm` / `md` / `lg` radius, 2-3 shadow depths), which
  describes a considered scale rather than the accretion line. Each printed bound is one
  number, and radius and shadow print different ones. A range cannot be a threshold - `3-4
  or fewer` never said whether a fourth value opens a row - and one bound shared by two
  categories whose scales differ in size leaves a band between them that nothing describes:
  a fourth shadow depth was above everything Step 2 calls a considered scale and inside the
  printed target, so it was neither clean nor a finding. The drift counts carry no target
  for the opposite
  reason: any value above zero is a finding there, so a target beside one would read as a
  tolerance this skill does not grant. The bound is also what makes the summary reconcilable
  by eye against the P1 table, since an inventory count above its threshold with no row is a
  gap in the report, and without the bound printed that gap looks exactly like a clean
  count.

If a category has zero findings, keep its row in the summary showing 0 and omit its table.

A count of 0 and a category that could not be audited are different results and must not
share a number. `0` says the scan ran and the codebase is clean; a category with no baseline
was never scanned, and reporting it as 0 claims a clean bill of health for the one part of
the system nobody has defined yet. Write `no baseline - no <category> tokens found` in place
of the count, and say what would unlock it: define the scale first, or run
`extract-design-tokens` against the codebase's own most-used values to propose one. The same
goes for the `Nearest token` column - where no token of that category exists there is no
nearest one, so the cell says `none defined` and the suggested fix is to define the token,
never a token name invented to fill the column.

Every `Suggested fix` cell reads on its own. The three tables are sorted by severity, and a
reader arrives at one row from a `File:line` match in their own diff or from a summary count
being reconciled, so a cell leaning on a proposal made in a row above it is a fix nobody at
that row can apply. Where several literals of a no-baseline category close against one scale
the plan has to define, each row carries the shared condition and its own place in that
scale: the rows hold the values the scale is built from, so the order is theirs to state, and
the plan's step is the single move that defines the scale and routes all of them. The cell
says what closing that row means, never which step runs first - that order is the
consolidation plan's.

## Severity rules

- **P0**: a hardcoded color sits on an interactive state (hover/focus/active/disabled) or
  inside a component that also renders under a dark-mode or alternate-theme selector
  elsewhere in the codebase. This is the category that visibly breaks for users.
- **P1**: off-scale spacing, font-size sprawl past 10 sizes, radius past 4 variants, shadow
  past 3, and any raw color that meets neither P0 condition (see the default below).
  Does not break anything today but actively degrades consistency.
- **P2**: near-duplicate colors, isolated z-index literals, anything a reasonable team could
  ship as-is and clean up opportunistically.

**Every raw color gets a bucket.** A literal that sits on no interactive state and inside no
component rendered under an alternate theme - a background on a static marketing banner in a
codebase with no dark mode - still has to land somewhere. It defaults to **P1**: it breaks
nothing for a user today and degrades consistency, which is what P1 means. Downgrade it to P2
only when the literal is genuinely one-off: a single value in a component nothing else shares,
with no near-duplicate anywhere in the scan. Without this default, the category Step 2 calls
the highest-value one has no home in an unthemed codebase, since P0 requires a state or a
theme, P1 listed only spacing and type, and P2 listed only near-duplicate pairs and z-index -
leaving the finding to be dropped from the report or inflated to P0 against the rule below.

Never invent a P0 finding to make the report look more urgent. If nothing qualifies as P0,
say so plainly - "no P0 findings" is a valid and common result.

## Rules

- Never rename a token in the report as if it already happened. Renames are always a
  separate proposed section the user reviews before applying.
- Never invent a file path, line number, or token value. Every row in every table must trace
  to something you actually found in the scan. If you could not scan a file (binary, too
  large, generated), say which files were skipped and why.
- Do not touch accessibility, contrast ratios, or component states - that is the design-qa
  and accessibility-audit skills. Stay inside token consistency.
- Do not apply any fix automatically unless the user explicitly asks you to apply the
  consolidation plan after reviewing it.

## Edge cases

- **No token definitions found at all.** Stop the audit. Tell the user there is nothing to
  audit drift against, and point them at the `extract-design-tokens` skill to pull a token
  set from a URL, screenshot, or the codebase's own most-used values first.
- **A partial token set.** Colors defined, nothing else - the commonest real shape, since a
  `:root` of brand colors is where most teams start. The audit runs, and it runs only on the
  categories that have a baseline plus the ones that compare the codebase against itself.
  Say which categories were audited and which were not, in the summary and in one line of
  the report, so a short report reads as limited coverage rather than a clean codebase. Do
  not stop the audit: the color half is real work, and the missing scales are worth naming
  as the gap they are.
- **A themed codebase.** Several blocks define the same token names - `:root` plus
  `[data-theme="dark"]`, or a light and a dark object in one theme file. That is the token set
  working, not drift. Audit each theme against its own palette, report one set of findings with
  the theme named on any row where it matters, and never propose merging two values that belong
  to different themes. A name defined in the base block and missing from a theme override is
  worth one line as a gap rather than a row as drift: it falls back to the base value, which is
  how a dark mode ends up with one light surface, but nothing in the codebase bypassed a token,
  so it opens no row and enters no count.
- **Monorepo.** If the target path contains multiple `package.json` files with independent
  `src/` trees, ask which package to scan, or scan only the path the user named. Do not
  silently scan the whole monorepo - drift counts across unrelated apps are not comparable.
- **Tailwind.** Compare every class-based usage against `tailwind.config.js`'s `theme` and
  `theme.extend`. Arbitrary-value classes (`bg-[#2563eb]`, `p-[13px]`, `text-[15px]`) are the
  drift signal in a Tailwind codebase - treat every arbitrary-value bracket as a raw-value
  hit in the matching category (color, spacing, font-size). A safelist entry is not drift.
- **Literals that are raw on purpose.** Some values are not drift, and flagging them buries
  the ones that are. Exclude these by default: brand-mark colors inside an inline SVG logo
  (fixed by brand guidelines, not themeable), third-party or vendor stylesheets the team
  does not own and cannot edit, and email templates - most email clients do not resolve CSS
  custom properties, so a literal there is the working choice rather than a mistake. Do not
  drop them silently: list them under an "Excluded from the count" note after the
  consolidation plan, one line each with the reason, so every exclusion stays reviewable.
  If the user says one of them should be tokenized after all, move it back into the tables
  and update the summary counts.
- **An inventory category past its threshold.** Thirteen font sizes where the bound is 10,
  six radius variants where the bound is 4, or four shadow depths where the bound is 3 and
  the scale is 2-3. The finding is the
  count, so it is one finding rather than one per value, and it has no single location: the
  tables are keyed by `File:line` and the sizes are spread over every file that sets the
  property. It opens exactly one P1 row for the category, and the two columns it cannot
  fill say so rather than name one file and imply the rest are clean:

  | File:line | Value | Nearest token | Suggested fix |
  |---|---|---|---|
  | font-size - no single location | 13 distinct sizes (target 10) | not applicable - the finding is the count, not a distance from a token | retire 3 values to bring the count inside the bound - the consolidation plan carries the order |

  `not applicable` is a different cell from the `none defined` above it: that one says the
  category has no token to be nearest to, this one says nearest-token is the wrong question
  for a finding about how many values exist. What Step 2 collected for the category goes
  under the table as that row's evidence - for font size the counted list, one line per
  value with its use count, sorted descending, because a row cannot hold thirteen values
  and the summary line carries them without the counts; for radius and shadow the distinct
  values, which the summary already lists. Reconciliation is unchanged: an inventory
  category opens either no row or one row, never a row per value, so its summary number
  stays a count of distinct values and is never matched against a row count.

  In the consolidation plan this row is the one finding that becomes more than one step,
  and a row and a step are not the same unit. The row is the finding, and it stays single
  because the summary count reconciles against it. The plan is a work order and the
  row's cell is not: the cell names what closing the finding means, the count back inside
  the bound, and leaves which values go first to the plan. Taken as one move the fix has
  neither property the plan requires - retiring three font sizes at once touches every
  file that sets the property, which is the giant sweep the smallest-diff-first order
  exists to avoid, and it does not ship without waiting for anything. So the plan carries
  one step per value retired - the call sites of one
  off-scale value moved onto the nearest step of the scale - which is PR-sized and
  independent like every other step. The steps come off the evidence already under the
  table and are never invented: for font size the counted list says which values are
  cheapest to retire, the ones used once or twice, and for radius and shadow, where use
  counts were not collected, the step names the variant it retires. Each step then takes
  its own place in the order by its own size rather than sitting as a block at the end, so
  an inventory finding and a single literal replacement interleave. The steps stop when
  the count is back inside the bound that opened the row, since that bound is what made it
  a finding - thirteen sizes against a bound of 10 is three steps, not thirteen, and going
  on to eight is the considered scale rather than the finding, so it is offered and not
  assumed - and the plan names the values it kept so a reader is not left wondering which
  of the thirteen are still there.
- **A token reference with a literal fallback.** `var(--brand, #2563eb)` references a token,
  so it is not a raw value. Compare the fallback with the token's defined value: if they
  match, there is no row. If they differ, open one row in the matching category at the
  severity a raw literal of that category would get, because the fallback is what renders
  whenever the token fails to resolve, and the suggested fix is to match the fallback to the
  token or drop it.
- **CSS-in-JS with computed values.** If a color or spacing value is computed at runtime
  (e.g. `darken(theme.primary, 0.1)`), do not flag it as raw - it already derives from a
  token. Only flag literals that do not reference any token.

Files in this skill

  • CHANGELOG.md19.9 KB
  • SKILL.md26.5 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.