tailwind-patterns
Build Modern Tailwind v4 UIs with CSS-First Architecture
Également disponible depuis: 0xDarkMatter,0xDarkMatter
Stop struggling with Tailwind configuration and responsive design. This skill provides CSS-first patterns, container query mastery, and modern design token architecture for building scalable UIs with Tailwind CSS v4.
Télécharger le ZIP du skill
Importer dans Claude
Allez dans Paramètres → Capacités → Skills → Importer un skill
Activez et commencez Ă utiliser
Tester
Utilisation de "tailwind-patterns". Create a dark mode card component with container queries
Résultat attendu:
- .card { @container; background: white; padding: var(--spacing-lg); }
- .dark .card { background: zinc-900; }
- @sm { .card-content { grid-template-columns: 1fr 1fr; } }
Utilisation de "tailwind-patterns". Set up design tokens with OKLCH colors
Résultat attendu:
- @theme {
- --color-primary: oklch(0.7 0.15 250);
- --color-surface: oklch(0.98 0 0);
- --spacing-md: 1rem;
- }
Audit de sécurité
SûrStatic analysis detected 77 potential issues (backtick execution patterns, weak cryptography, system reconnaissance) but ALL are FALSE POSITIVES. The flagged patterns are markdown code block delimiters (```), inline code formatting, and CSS framework documentation comparing v3 vs v4. No executable code exists - this is documentation-only content for Tailwind CSS v4 patterns.
Score de qualité
Ce que vous pouvez construire
Migrate Tailwind v3 to v4
Developers upgrading from Tailwind v3 to v4 who need to replace JavaScript config with CSS-first @theme directive
Build responsive component libraries
UI engineers creating reusable components that adapt to their container size rather than viewport breakpoints
Implement design token systems
Teams establishing semantic color, spacing, and typography scales using OKLCH and CSS variables
Essayez ces prompts
Create a Tailwind v4 @theme configuration with a primary brand color, spacing scale, and font stack for a [project type]
Design a responsive [component type] using container queries that adapts from narrow to wide containers
Implement dark mode for a [page type] using [class/media/selector] strategy with proper color tokens
Create a [layout type] using [flexbox/grid] with responsive breakpoints and asymmetric Bento-style sections
Bonnes pratiques
- Use CSS-first @theme directive in Tailwind v4 instead of tailwind.config.js for better performance and native CSS variable support
- Prefer container queries (@container) for component-level responsive design over viewport breakpoints for reusable, context-independent components
- Organize design tokens in three layers: primitive colors (raw values), semantic tokens (primary, surface), and component tokens (button-bg)
- Use mobile-first approach by writing base styles without prefixes, then adding sm:, md:, lg: overrides for larger screens
- Extract components when class combinations repeat 3+ times or when complex state variants are needed
Éviter
- Avoid arbitrary values everywhere - use design system scale values for consistency instead of hardcoded numbers like w-[327px]
- Do not use !important to override styles - fix specificity issues through proper component structure and CSS layering
- Avoid inline style attributes - use Tailwind utility classes instead to maintain design system consistency
- Do not mix v3 JavaScript config with v4 CSS-first patterns - migrate fully to @theme directive and CSS-based configuration
- Avoid heavy use of @apply directive - prefer React/Vue components for dynamic behavior or pure CSS components for static patterns