AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Design Tokens Theming

skill-param087-saas-ui-skills-design-tokens-theming · by param087

Use when setting up a design system — color, typography, and spacing scales as CSS variables, the shadcn/ui theme, and dark mode. Covers semantic tokens, Tailwind wiring, and consistent theming across components.

No reviews yet
0 installs
37 views
0.0% view→install

Install

$ agentstack add skill-param087-saas-ui-skills-design-tokens-theming

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-param087-saas-ui-skills-design-tokens-theming)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
3mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Design Tokens Theming? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Design Tokens & Theming

Overview

A SaaS UI looks "designed" when every color, space, and font size comes from a small, named scale — not arbitrary values sprinkled per component. Define tokens once as CSS variables, expose them through Tailwind, and let dark mode be a swap of variable values, not a rewrite of class names.

When to use

  • Starting a new app and deciding colors/spacing/typography.
  • Components use raw hex codes or one-off pixel values.
  • You need dark mode or multi-brand theming.

Semantic tokens (the key idea)

Name tokens by role, not by hue. --primary, --muted, --destructive — not --blue-500. Roles let you re-theme without touching components. shadcn/ui uses exactly this convention:

/* globals.css */
:root {
  --background: 0 0% 100%;
  --foreground: 240 10% 3.9%;
  --primary: 240 5.9% 10%;
  --primary-foreground: 0 0% 98%;
  --muted: 240 4.8% 95.9%;
  --muted-foreground: 240 3.8% 46.1%;
  --destructive: 0 84.2% 60.2%;
  --border: 240 5.9% 90%;
  --radius: 0.5rem;
}
.dark {
  --background: 240 10% 3.9%;
  --foreground: 0 0% 98%;
  --primary: 0 0% 98%;
  --primary-foreground: 240 5.9% 10%;
  --muted: 240 3.7% 15.9%;
  --muted-foreground: 240 5% 64.9%;
  --border: 240 3.7% 15.9%;
}

Store HSL channels (no hsl(...) wrapper) so Tailwind can add opacity: hsl(var(--primary) / 0.5).

Wire tokens into Tailwind

// tailwind.config.ts
export default {
  darkMode: "class",
  theme: {
    extend: {
      colors: {
        background: "hsl(var(--background))",
        foreground: "hsl(var(--foreground))",
        primary: { DEFAULT: "hsl(var(--primary))", foreground: "hsl(var(--primary-foreground))" },
        muted: { DEFAULT: "hsl(var(--muted))", foreground: "hsl(var(--muted-foreground))" },
        border: "hsl(var(--border))",
      },
      borderRadius: { lg: "var(--radius)", md: "calc(var(--radius) - 2px)" },
    },
  },
};

Now bg-primary text-primary-foreground works in both themes automatically.

Dark mode toggle

Use next-themes (or a tiny class toggler) and darkMode: "class". Never hard-code dark: colors when a semantic token already flips — bg-background beats bg-white dark:bg-zinc-950.

Scales to standardize

  • Spacing: stick to Tailwind's 4px scale (p-2, gap-4, space-y-6). Avoid p-[13px].
  • Typography: a 5–6 step type scale (text-smtext-3xl); set text-muted-foreground for secondary text.
  • Radius/shadow: one --radius token; 2–3 shadow steps.

Pitfalls

  • Raw hex/px values per component → inconsistent UI that can't be re-themed.
  • dark: overrides everywhere instead of flipping tokens once.
  • Naming tokens by color (--blue) instead of role (--primary).
  • Wrapping hsl() in the variable — breaks Tailwind opacity modifiers.
  • Too many shades — a bloated palette is harder to keep consistent than a tight one.

Hand-off

A token layer that responsive-layout, accessible-components, and every component skill build on — change a value once, the whole app re-themes.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.