code-quest: Skill for Claude Code

.claude/skills/tailwind-v4/SKILL.md

tailwind-v4 is a skill for Claude Code from recca0120/code-quest. It costs 102 tokens per session (5,041 once invoked), scanned A, original, MIT.

A Tailwind CSS v4 styling guide for defining design tokens and custom utilities directly in CSS. It covers the newer CSS-first setup and migration from Tailwind v3.

In plain words
What is it for?
Use it when styling components, configuring shared design tokens, adding custom utilities or variants, migrating from Tailwind v3, or replacing hardcoded colors with theme tokens.
Why use it?
It reduces confusion when moving from configuration files to Tailwind v4’s CSS-based approach. It also helps keep colors, spacing, and other design values consistent instead of scattering one-off values through components.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

This is recca0120/code-quest's own configuration. It tells Claude Code how to work on code-quest 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 code-quest configures →

Reuse

Borrowing it

Nothing to install: this file belongs to recca0120/code-quest. 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/recca0120/code-quest/main/.claude/skills/tailwind-v4/SKILL.md
Clone the repo
git clone --depth 1 https://github.com/recca0120/code-quest

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

README.md
[![agentmods](https://agentmods.dev/badge/skills/recca0120/code-quest/tailwind-v4/github.svg)](https://agentmods.dev/skills/recca0120/code-quest/tailwind-v4)
Your own site
<a href="https://agentmods.dev/skills/recca0120/code-quest/tailwind-v4"><img src="https://agentmods.dev/badge/skills/recca0120/code-quest/tailwind-v4/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

Your own site · 80×15
<a href="https://agentmods.dev/skills/recca0120/code-quest/tailwind-v4"><img src="https://agentmods.dev/badge/skills/recca0120/code-quest/tailwind-v4.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 102 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,041 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.00102 $0.05041
Opus 5.5 $0.00041 $0.02016
Sonnet 5.5 $0.00020 $0.01008
Haiku 4.5 $0.00010 $0.00504

Measured 2mo ago against content hash 61505da03ef6, 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 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 2mo 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/skills/tailwind-v4/SKILL.md · 435 lines

How it starts

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

Tailwind CSS v4

Overview

Tailwind v4 is CSS-first: no tailwind.config.js, no PostCSS config. Everything lives in CSS via directives.

Setup (Vite)

pnpm add tailwindcss @tailwindcss/vite
// vite.config.ts
import tailwindcss from '@tailwindcss/vite'
export default defineConfig({ plugins: [react(), tailwindcss()] })
/* App.css */
@import "tailwindcss";

No content globs needed — auto-detected. No autoprefixer — Lightning CSS handles it.

v3 → v4 Key Changes

v3 v4
tailwind.config.js @theme in CSS
@tailwind base/components/utilities @import "tailwindcss"
darkMode: 'class' @custom-variant dark
content: [...] Auto-detected
PostCSS required @tailwindcss/vite plugin
Container query plugin Built-in @container

Design flow: token-first

設計 UI 時先看 design token,再考慮 utility。不要遇到設計稿的值就寫 arbitrary(text-[13px] / bg-[#3a7] / p-[7px])。

正確順序(寫 JSX 前跑一遍):

  1. 先查既有 token — 需要的顏色 / 字級 / 間距 / radius / shadow / z-index 是否已經在 @theme 或內建 scale?
    • 顏色:grep "^\s*--color-" apps/web/src/App.css
    • Spacing / text / z:用「優先內建 utility」表對照
  2. 差 1–2px / 1–2 階 → 就近取 — design system 的一致性 > pixel-perfect。13px 取 text-xs 或 text-sm、#3a7d5e 取 text-success。
  3. 超出既有 token 範圍 → 先擴 token,不要寫 arbitrary
    • 新色階:加 --color-X 到 @theme
    • 新語意層級(z-index、muted tier、shadow):加對應 --* token
    • 新可重用效果:抽 @utility
  4. 只有這些 arbitrary 值是合法的(見下方「Arbitrary value 正當情境」):
    • calc(...) 計算值
    • 引用動態 CSS variable
    • 刻意 off-grid 且有清楚理由(icon 尺寸、對齊特定視覺錨點)

不要這樣做:

// ❌ 為了新設計稿直接寫 arbitrary
<div className="bg-[#2a4a6e] text-[13px] p-[7px] shadow-[0_2px_8px_rgba(0,0,0,0.4)]" />

// ✅ 先把需要的值加進 @theme,再用 semantic utility
// App.css:  --color-surface-sunken: oklch(...); --shadow-card: 0 2px 8px rgba(0,0,0,0.4);
<div className="bg-surface-sunken text-xs p-2 shadow-card" />

特別 callout — literal-pixel arbitraries:

任何 \w+-[Npx](text-[13px] / h-[38px] / max-h-[480px] / max-w-[180px] 等)明確禁止。

Read the full file on GitHub · 435 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. 2mo ago First seen · 435 lines · 102 tokens per session scan A 61505da03ef6

Subscribe to this mod's changes

tailwind-v4 is a skill published in the GitHub repository recca0120/code-quest (11 stars, last pushed 4mo ago), licensed MIT. It adds 102 tokens to every session and 5,041 once invoked, about $0.0004 per session on Opus 5.5. 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 skills, from other repositories

anti-slop-design

Autonomous Principal Design Technologist. Cures vibe-coded software from AI frontend slop using curated token archetypes and 7-axis quality gating.

sickn33/agentic-awesome-skills · 34 tokens

chakra-ui-builder

Build responsive, accessible UI components and layouts using Chakra UI v3, install or configure Chakra UI in new and existing projects, and design scalable themes using tokens, semantic tokens, recipes, and slot recipes. Use this skill whenever a user asks to build, create, or generate any UI component, page, form…

chakra-ui/chakra-ui · 214 tokens

visual-ralph

Visual Ralph orchestration for frontend UI from generated references, static references, or live URL targets, using $ultragoal with built-in visual verdict and pixel-diff evidence until the implementation matches and leaves a reproducible design system.

Yeachan-Heo/oh-my-codex · 52 tokens

open-design-setup

Prepare or repair a project's prototyping environment so open-design can build prototypes with the project's own component library and render them through the project's toolchain. Use when the library target is needed and docs/design/prototyping.md is missing, stale, or failing; excludes HTML-only design work and…

compozy/compozy · 67 tokens

edit-site

Plans, coordinates and customizes PAC CLI-downloaded Standard or Enhanced data model non-SPA Power Pages sites created from Microsoft templates or manually in Design Studio. Use for requests involving pages, localized content, navigation, assets, snippets, site markers, Liquid/web templates, page layouts, or styling.…

microsoft/power-platform-skills · 104 tokens

frontend-visual-qa

Audits rendered UI and specific task/object-link handoffs; excludes ordinary source citations alone. Audits already-rendered UI and Markdown/Obsidian image layout — web app, deck/slide, dashboard, design-system, or Electron/native app — via real-browser/native-app journeys and a Playwright sweep. Use after UI…

daymade/claude-code-skills · 125 tokens