Skip to content
Back to skills

Taste Tokens

ASecurity

Builds the design-token system every Tastemaker skill consumes - primitive, semantic and component layers in design-tokens.json, light/dark/high-contrast themes, density modes, and generated tokens.css, Tailwind v4 @theme, Tailwind v3 config and shadcn/ui variables, with automatic reference and WCAG contrast validation. Use for "design system", "tokens", "theme", "dark mode", "brand colors in Tailwind", "component specs", or before any UI build that lacks tokens.

  • 4 stars
  • 0 votes
  • 0 copies
  • 0 views
  • Added November 7, 2026
ai-agentsgobashnode

Security analysis

A100/100

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

Scanned November 7, 2026

npx -y skills add Harrypatria/tastemaker --skill taste-tokens --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Taste Tokens?

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

Security grade badge for Taste Tokens
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/harrypatria-taste-tokens/badge)](https://www.skillsdirectory.com/skills/harrypatria-taste-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: taste-tokens
description: Builds the design-token system every Tastemaker skill consumes - primitive, semantic and component layers in design-tokens.json, light/dark/high-contrast themes, density modes, and generated tokens.css, Tailwind v4 @theme, Tailwind v3 config and shadcn/ui variables, with automatic reference and WCAG contrast validation. Use for "design system", "tokens", "theme", "dark mode", "brand colors in Tailwind", "component specs", or before any UI build that lacks tokens.
---

# Taste Tokens: one source of truth

Every color, space, radius, font, shadow, duration and z-index in the product comes from `design-tokens.json`. Components never see a raw value (V08).

## Modes

- **Minimal** (default before UI work): copy `templates/design-tokens.json`, set primary/neutral from taste-direction or brand, build, done.
- **Full** (explicit design-system request): all layers, component specs, docs page, governance.

## Procedure

1. Start from `templates/design-tokens.json` (valid, contrast-checked). Replace primitives with the brand or taste palette; keep the semantic names.
2. Three layers (`references/token-architecture.md`): **primitive** (raw) -> **semantic** (role, the only layer components use) -> **component** (targeted overrides). Themes remap semantic only.
3. Every semantic color has a `light` and `dark` value; add `contrast` pairs for every text/background combination you use.
4. Build and validate:
   ```bash
   node <skill-dir>/scripts/build-tokens.mjs design-tokens.json --out src/styles
   ```
   Writes `tokens.css` (CSS variables + shadcn aliases, light/dark/reduced-motion), `tailwind.v4.css` (`@theme inline`), `tailwind.v3.cjs` (`theme.extend` fragment). Fails on unresolved references, missing dark values, component-to-primitive references and contrast failures. Fix and rebuild until clean.
5. Wire by detected Tailwind major (tastemaker/references/stacks.md): v4 imports `tailwind.v4.css` after `@import "tailwindcss"`; v3 spreads `tailwind.v3.cjs` into `theme.extend`.
6. Full mode: write component specs (`references/component-spec.md`) and a `design-system.html` showing swatches, type, spacing, radius, elevation and every component state in both themes.

No Node available (chat platforms): emit `tokens.css` by hand from the same structure and list the contrast pairs you checked with their ratios.

## Rules

- Names: `{category}.{role}.{variant}.{state}` in JSON, `--color-bg-surface` in CSS. Lowercase, no brand names in semantic tokens.
- Dark mode is a remap, not an inversion. Elevation in dark = lighter surface, not shadow.
- Density via `data-density="compact|comfortable"` overriding component space/size tokens.
- Theme switch: class `.dark` (or `data-theme`) on `<html>`, respect `prefers-color-scheme` on first visit, persist with try/catch storage, set before paint to avoid flash.
- Versioning: semver. Add = minor, rename/remove = major (keep a deprecated alias for one minor), value tweak = patch.

## Quality gate

- [ ] Build script exits 0 (references, dark coverage, layer rules, contrast).
- [ ] shadcn variable set complete (`--background` ... `--ring`, `--radius`, `--chart-1..5`).
- [ ] No raw values in components (`tastemaker scan` V08 clean).
- [ ] Specs exist for every shipped component (Full mode).

Files in this skill

  • SKILL.md3.2 KB
  • references/component-spec.md1.5 KB
  • references/token-architecture.md2.7 KB
  • scripts/build-tokens.mjs11.3 KB
  • scripts/contrast.mjs4.1 KB
  • templates/design-tokens.json8 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.

Comments

Loading comments…

Newsletter

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