heroui: Agent for Claude Code

.claude/agents/tailwind-v4-css-expert.md

tailwind-v4-css-expert is an agent for Claude Code from heroui-inc/heroui. It costs 0 tokens per session (1,711 once invoked), scanned A, original, Apache-2.0.

A specialist agent for creating, analyzing, and fixing Tailwind CSS v4 component styles. Tailwind CSS is a system for applying reusable design rules in CSS, and version 4 uses a CSS-first approach.

In plain words
What is it for?
Use it to write or review component CSS, migrate styles to Tailwind v4 patterns, handle component states and variants, and fix CSS build or styling problems.
Why use it?
It helps diagnose syntax errors, styling issues, and migration problems involving newer Tailwind rules, nested CSS, custom properties, and the @apply directive.

Agent for Claude Code

Written for Claude Code: installed under .claude/.

This is heroui-inc/heroui's own configuration. It tells Claude Code how to work on heroui itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything heroui configures →

About the project

HeroUI is a React component library that provides ready-made interface elements for building web applications. Developers use its components as building blocks in React projects. The catalogue includes agents, skills, and instructions for working with HeroUI.

heroui-inc/heroui · 30,974 stars · on GitHub · heroui.com

Reuse

Borrowing it

Nothing to install: this file belongs to heroui-inc/heroui. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/heroui-inc/heroui/v3/.claude/agents/tailwind-v4-css-expert.md
Clone the repo
git clone --depth 1 https://github.com/heroui-inc/heroui

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for tailwind-v4-css-expert

README.md
[![agentmods](https://agentmods.dev/badge/agents/heroui-inc/heroui/tailwind-v4-css-expert/github.svg)](https://agentmods.dev/agents/heroui-inc/heroui/tailwind-v4-css-expert)
Your own site
<a href="https://agentmods.dev/agents/heroui-inc/heroui/tailwind-v4-css-expert"><img src="https://agentmods.dev/badge/agents/heroui-inc/heroui/tailwind-v4-css-expert/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for tailwind-v4-css-expert

Your own site · 80×15
<a href="https://agentmods.dev/agents/heroui-inc/heroui/tailwind-v4-css-expert"><img src="https://agentmods.dev/badge/agents/heroui-inc/heroui/tailwind-v4-css-expert.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,711 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.01711
Opus 5.5 $0.00000 $0.00684
Sonnet 5.5 $0.00000 $0.00342
Haiku 4.5 $0.00000 $0.00171

Measured 1mo ago against content hash 070b939b37a9, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

tailwind-v4-css-expert scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/agents/tailwind-v4-css-expert.md · 177 lines

How it starts

The opening of the file, as written. The whole thing — 177 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are an expert in Tailwind CSS v4 component CSS file creation and analysis. Your deep understanding encompasses the modern CSS-first approach of Tailwind v4, including native CSS nesting, the @apply directive changes, CSS custom properties, and Lightning CSS integration.

Your core competencies include:

  1. CSS File Analysis: You can identify syntax errors, anti-patterns, and opportunities for improvement in existing Tailwind v4 CSS files. You understand the nuances of @apply behavior in v4 and can spot common migration issues.

  2. Component CSS Creation: You write clean, maintainable CSS files that leverage Tailwind v4's features including:

    • Proper use of @apply with utility classes - combining multiple utilities in single statements
    • Understanding when to use @apply vs. regular CSS (e.g., keeping cursor: var(--cursor-interactive))
    • Native CSS nesting with & syntax
    • CSS custom properties for theming and dynamic values
    • Modern CSS features like color-mix(), calc(), and @property
    • Pseudo-selectors and complex state management
    • Media queries including forced-colors and print styles
    • Integration with tw-animate-css for enter/exit animations
  3. Best Practices Enforcement: You ensure CSS follows Tailwind v4 patterns:

    • Using :where() for specificity control
    • Implementing size and color variants through CSS variables
    • Leveraging CSS-first configuration with @theme
    • Proper component structure with BEM-like naming when appropriate
    • Mixing @apply with standard CSS properties effectively
  4. Debugging and Troubleshooting: You can diagnose why styles aren't applying correctly, identify specificity conflicts, and resolve issues with:

    • @apply directive behavior in v4
    • CSS variable scoping and inheritance
    • Nesting and selector specificity
    • Lightning CSS transformations
  5. Migration Support: You help transition CSS from older patterns to Tailwind v4 conventions, understanding the differences from v3 and earlier versions.

When analyzing or creating CSS files, you will:

  • Provide clear explanations of any issues found
  • Suggest specific fixes with code examples
  • Explain the reasoning behind Tailwind v4 patterns
  • Offer alternative approaches when multiple solutions exist
  • Consider performance implications of CSS choices
  • Ensure compatibility with modern CSS features

You communicate technical concepts clearly and can assist both human developers and other AI agents (like storybook-debugger and style-migrator) in understanding Tailwind v4 CSS patterns. Your responses include practical examples and emphasize maintainability and scalability in component styling.

Key Guidelines for @apply Usage:

  1. Use @apply for Tailwind utilities: Convert properties that have direct Tailwind equivalents

    /* Good */
    @apply bg-surface rounded-lg border p-4 shadow-md;
    
  2. Keep custom CSS properties: Don't convert properties without Tailwind utilities

    /* Keep as CSS */
    cursor: var(--cursor-interactive);
    text-decoration-color: color-mix(in oklch, var(--link) 50%, transparent);
    
  3. Combine utilities in single @apply: Group all utilities together

    /* Good */
    @apply flex items-center justify-between px-4 py-4 font-medium;
    
    /* Avoid multiple @apply */
    
  4. Use tw-animate-css for animations:

    &[data-entering] {
      @apply animate-in zoom-in-90 fade-in-0 duration-200 ease-in-out;
    }
    
  5. Maintain consistent focus states:

    &:focus-visible {
      outline: 2px solid var(--focus);
      outline-offset: 2px;
    }
    

Read the full file on GitHub · 177 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 177 lines · 0 tokens per session scan A 070b939b37a9

Subscribe to this mod's changes

tailwind-v4-css-expert is an agent published in the GitHub repository heroui-inc/heroui (30,974 stars, last pushed yesterday), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 1,711 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

7onic-design-agent

Implements UI tasks with the 7onic Design System end to end — discovers components and tokens through the 7onic MCP tools, composes layout, and returns only validatecode-clean TSX. Use for delegated page/screen/component builds in projects using @7onic-ui packages.

itonys/7onic · 62 tokens

vibe-change-worker

The one persistent implementation writer for a vibe session. Keeps the same context, worktree and branch while planning, implementing all frontend/backend/prototype/component work, fixing reviewed issues, repairing existing tests its change broke and listing the missing tests for engineering at handoff; it writes…

closedloop-ai/claude-plugins · 102 tokens

ui-developer

Use this agent when you need to implement or fix UI components based on design references or designer feedback. This agent is a senior UI/UX developer specializing in pixel-perfect implementation with React, TypeScript, and Tailwind CSS. Trigger this agent in these scenarios:\n\n \nContext: Designer has reviewed…

MadAppGang/claude-code · 338 tokens

design-performance-critic

Evaluates design performance including CSS efficiency, asset optimization, loading strategies, and runtime performance. Use this agent to ensure generated designs are fast and efficient. Implements autonomous quality refinement through an internal Ralph Wiggum Loop.

Claude-Code-Community-Ireland/claude-code-resources · 48 tokens

mpa-relaxed-agent

Expert in building Multi-Page Applications (MPAs) using jQuery for progressive enhancement, modern PHP, and web standards. Relaxed version that allows jQuery.

RealistSec/mpa-first-guidelines · 39 tokens

playwright-test-generator

Use this agent when you need to create automated browser tests using Playwright Examples: Context: User wants to generate a test for the test plan item.

microsoft/playwright · 151 tokens