agentleFS
NikoxkxNikoxkx/Agent-Skills/skills/web-development/tailwind-design-system/SKILL.md

tailwind-design-system

Skill2 starsChanged 6 months agoApache-2.0View on GitHub

Creates a Tailwind CSS design system with custom tokens, component classes, and dark mode. Use when establishing a consistent design language for a project.

18 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use shadcn-ui and shadcn.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • akornmeierSkill

    shadcn-ui

    Use when building React UIs with component libraries, implementing forms, dialogs, navigation, or data display. Use when user mentions shadcn, Radix UI, Base UI, or asks about accessible React components. Proactively suggest when building UI that would benefit from pre-built accessible components with Tailwind CSS styling.

    Also in 3 projects that use this

  • VercelSkill

    shadcn

    Pre-built shadcn/ui components for json-render. Use when working with @json-render/shadcn, adding standard UI components to a catalog, or building web UIs with Radix UI + Tailwind CSS components.

    Also in 3 projects that use this

The file

We split this skill into the rules it gives an agent

4 rules. 0 are common, 4 are distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 5 edited versions we read keep these.

  • 4

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use OKLCH or HSL for better dark mode and accessibility.

    line 36
  2. Distinctive:

    Document pros/cons of each approach.

    line 47
  3. Distinctive:

    Bundle size: Use Tailwind's content paths correctly and purge in production.

    line 66
  4. Distinctive:

    Check contrast ratios for primary/foreground pairs.

    line 73

“Common” is measured: kept by at least 6 in 10 of the 5 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Overview

Establishes a complete, maintainable Tailwind CSS design system by extending the config with semantic design tokens (colors, spacing, typography, shadows, radii), creating reusable component classes via @apply or a component library approach, setting up dark mode (class or media), and providing plugin examples for custom utilities.

When to Use This Skill

  • Starting a new project that will use Tailwind and needs a design language from day one.
  • Standardizing an existing Tailwind project that has inconsistent colors, spacing, or component styles.
  • Building or contributing to a design system / component library.

Prerequisites

  • Tailwind CSS 3.4+ installed (or via CDN for prototypes).
  • tailwind.config.ts or .js in the project root.
  • PostCSS and build pipeline set up.
  • Design tokens or brand guidelines (or the skill will propose a sensible neutral + accent system).

Steps

  1. Audit current usage (if existing project): Find all hard-coded colors, spacing, fonts.
  2. Design token architecture in tailwind.config.ts:
    • Extend theme.extend.colors with semantic names (primary, neutral, success, background, foreground).
    • Use OKLCH or HSL for better dark mode and accessibility.
    • Define spacing scale, typography scale, border radius, box shadows as tokens.
  3. Dark mode setup:
    • Preferred: darkMode: 'class' + dark: variants.
    • Alternative: media for system preference.
    • Provide a theme toggle component (button that adds/removes dark class on <html>).
  4. Component abstraction strategy:
    • For simple components: use @apply in a components.css layer.
    • For complex or highly reusable: create actual React/Vue/Svelte components.
    • Document pros/cons of each approach.
  5. Create custom plugins (optional but powerful):
    • Plugin for text-balance, container-query utilities, or brand-specific helpers.
  6. Output:
    • Complete tailwind.config.ts with tokens and plugins.
    • app/globals.css or equivalent with layers and component classes.
    • 3 example custom components (Button, Card, Input) using the tokens.
    • Theme toggle implementation.
    • Documentation of the token system.

Examples

Full recommended tailwind.config.ts, CSS layers, and three component examples (Button with variants, Card, Form Input) are included in the skill output, along with dark mode toggle code.

Edge Cases & Error Handling

  • Design token drift: Recommend a token studio or Figma Tokens plugin for sync.
  • Bundle size: Use Tailwind's content paths correctly and purge in production.
  • Arbitrary values abuse: Provide a "when to use arbitrary" guideline.

Verification

  1. Build the project — Tailwind classes generate correctly.
  2. Toggle dark mode — all components adapt properly.
  3. Check contrast ratios for primary/foreground pairs.
  4. Success: New developers can use bg-primary, text-foreground, etc. consistently without guessing hex values.

References

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.