tailwind-ui-patterns

Implements Tailwind CSS v4 component patterns, responsive layouts, and theme tokens for React interfaces.

Updated Aug 28, 2026
One-click install
npx skills add https://github.com/Yash-Awasthi/adapfit --skill tailwind-ui-patterns-yash-awasthi
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: tailwind-ui-patterns
Source: https://github.com/Yash-Awasthi/adapfit/tree/main/.agents/skills/tailwind-ui-patterns
Command: npx skills add https://github.com/Yash-Awasthi/adapfit --skill tailwind-ui-patterns-yash-awasthi

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Building consistent, responsive UI components with Tailwind CSS v4 requires knowing the right utility patterns, theme token setup, and variant structures, which developers often reinvent or copy inconsistently across projects. ## Core Features & Use Cases - Component Patterns: Ready-to-use Button variants, Card layouts, and form Input components with dark mode support and the cn() class-merging convention. - Responsive & Animation Patterns: Mobile-first grids, container queries, keyframe animations, and transition utilities defined via Tailwind v4 @theme tokens. - Use Case: When scaffolding a new React + Vite dashboard, apply these patterns to create a branded button system, responsive card grid, and sticky header without writing custom CSS. ## Quick Start Ask the AI to build a responsive card grid with branded buttons using Tailwind CSS v4 patterns from this skill.

Frequently Asked Questions about tailwind-ui-patterns

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create button variants with Tailwind CSS?▼

Define a variants object with base, variant, and size class strings, then merge them with a cn() utility in your Button component. This pattern supports primary, secondary, outline, ghost, and destructive styles with consistent sizing options.

How to set up custom theme tokens in Tailwind CSS v4?▼

Use the @theme directive in your CSS file after importing tailwindcss to define custom colors, fonts, and spacing values. Tokens like --color-brand-500 become available as utilities such as bg-brand-500 throughout your project.

Does Tailwind CSS v4 support container queries?▼

Yes, Tailwind v4 supports container queries using the @container class on a parent element and variants like @md: and @lg: on children. This lets components respond to their container size rather than the viewport.

How do I add dark mode to Tailwind components?▼

Apply the dark: variant prefix to utilities, such as dark:bg-gray-900 alongside bg-white, so styles switch based on the color scheme. You can also define theme tokens that change values inside a prefers-color-scheme media query.

When should I extract Tailwind patterns into components?▼

Extract a pattern into a reusable component when the same utility combination repeats three or more times. Use semantic color tokens like brand or surface instead of raw values to keep the design system consistent.