Agent skill Frontend
Tailwind Design System
Translate a visual system into Tailwind CSS v4 theme tokens, responsive layouts and reusable component variants.
Install the skill
Run the command from your project root with Node.js and npm.
npx skills@latest add wshobson/agents --skill tailwind-design-system --agent claude-code --yesCheck this file in your project.claude/skills/tailwind-design-system/SKILL.md
Other ways to install
Choose an assistant interactively
npx skills@latest add wshobson/agents --skill tailwind-design-systemSelect your assistant and choose the project installation scope.
Official instructions
The tested Skills CLI 1.10.0 requires Node.js 22.20 or later. Open the project and confirm Tailwind CSS v4, its stylesheet entry, and its build tool. For a v3 project, review the official upgrade guide and identify the supported browser baseline before proposing a migration.
View operation manualWhat this skill helps with
- Define a theme with semantic color, type and spacing tokens.
- Build reusable component variants around shared design decisions.
- Apply responsive and dark-theme patterns across pages.
Good for
- Tailwind CSS v4 design systems
- Standardizing components across a website
- Scope
- Tailwind CSS v4 semantic tokens, variants, responsive patterns, and theming.
- Inputs
- The CSS entry, existing token and component recipes, and representative call sites.
- Options
- The React examples use libraries such as class-variance-authority and tailwind-merge. Keep the project’s existing equivalent where it fits.
- Deliverable
- A focused component or theme change and its build, appearance, and interaction evidence.
- Skill name
tailwind-design-system- Repository
wshobson/agents
Map the role before moving a color into a token
A global rewrite by value
Move all my colors into @theme and replace duplicate class strings.
The same value can represent different roles. A global replacement can change dark mode, focus indicators, and unrelated components.
A change tied to real components
- Trace one component’s variants and document its current users.
- Map semantic roles to existing tokens or introduce a missing role deliberately.
- Verify the same component states in light and dark appearance.
Tailwind Design System operation manual
Use the skill to consolidate a button recipe or fix dark-mode inconsistencies in a card. Fill in the bracketed project details before sending a prompt.
Find the right Tailwind v4 pattern
Point the assistant to the project stylesheet and the matching installed reference.
Several call sites repeat button class listsVariants
- Command or reference
references/details.md · Pattern 1- Examples
- Map actual intent, size, and component states through the project’s variant API.
An alias resolves incorrectly after theme changesTokens
- Command or reference
references/advanced-patterns.md · Theme Modifiers- Examples
- Compare the runtime variable and generated utility. Use @theme inline for variable aliases.
A dark-mode card ignores the existing switchDark mode
- Command or reference
references/advanced-patterns.md · Pattern 6- Examples
- Trace the project’s dark selector and inspect both computed color pairs.
A variant works locally but its styles disappear from the buildClass detection
- Command or reference
Tailwind · Detecting classes in source files- Examples
- Replace interpolated fragments with full class strings and verify project source detection.
Tailwind Design System troubleshooting
Can I paste the v4 CSS into a Tailwind v3 project?
Use the official upgrade guide to review framework integration and browser support first. The skill’s CSS-first directives and examples target v4.
Do I have to add CVA and tailwind-merge?
The React examples show both tools. Use the variant and class merging mechanism that the project already uses when it can express the same styles. The Skills CLI installs documentation.
Why is the generated utility missing?
Tailwind scans source text for complete class names. Keep variant values as complete literals, confirm the component source is picked up by the build, and verify the compiled result.