Agent skill Frontend
Tailwind CSS Mobile First
Build or refine reusable components for a web interface.
Install the skill
Run the command from your project root with Node.js and npm.
npx skills@latest add https://github.com/josiahsiegel/claude-plugin-marketplace/tree/main/plugins/tailwindcss-master/skills/tailwindcss-mobile-first --skill tailwindcss-mobile-first --agent claude-code --yesCheck this file in your project.claude/skills/tailwindcss-mobile-first/SKILL.md
Other ways to install
Choose an assistant interactively
npx skills@latest add https://github.com/josiahsiegel/claude-plugin-marketplace/tree/main/plugins/tailwindcss-master/skills/tailwindcss-mobile-first --skill tailwindcss-mobile-firstSelect your assistant and choose the project installation scope.
Official instructions
The tested Skills CLI 1.10.0 requires Node.js 22.20 or later. Use an existing Tailwind CSS v4 app and open two card placements at the same viewport. A Tailwind CSS 4.3.5 fixture verified named container behavior.
View operation manualWhat this skill helps with
- Build or refine reusable components for a web interface.
Good for
- Component implementation
- Skill name
- tailwindcss-mobile-first
- Scenario
- Adapt a product card to narrow and wide placement
- Deliverable
- A reusable mobile-first card, measured container thresholds and a touch and keyboard check.
- Skill name
tailwindcss-mobile-first- Repository
josiahsiegel/claude-plugin-marketplace
Define a styling task with a visible result
A request with an unclear outcome
At desktop width make every card a two-column layout.
A narrow drawer can sit inside a wide viewport, so a viewport-only rule can still squeeze the card.
A workflow with observable results
- Measure both card placements
- Build a one-column base and a container variant
- Compare placements and input modes
Tailwind CSS Mobile First operation manual
Give one card a mobile baseline, then let each placement respond to its own container.
Replace the bracketed details with your own project and target.
Measure both card placements
Choose thresholds using actual content widths.
Prompt · Step 1Use tailwindcss-mobile-first for [shared product card] in [narrow drawer] and [wide main area]. Confirm Tailwind v4 and measure each card's container at the same viewport. With the longest title and action label, decide where one column should become two. Identify expected keyboard and touch access and reserve space for media.Build a one-column base and a container variant
Apply the named container only at the intended parent.
Prompt · Step 2Use tailwindcss-mobile-first to implement [approved product card]. Start with unprefixed one-column classes. Put @container/[name] on the containing parent and a matching named variant on the card where it gains width. Use reserved media aspect ratio, responsive text within usable bounds and a comfortably sized native action with focus styling. Keep the DOM order stable.Compare placements and input modes
Use one viewport for the container check and a separate narrow preview.
- Two placements can produce different columns at the same viewport.
- Keyboard and touch can activate the primary action.
Prompt · Step 3Use tailwindcss-mobile-first to verify [two card placements] at the same viewport, then at [narrow viewport]. Compare computed columns, long-text fit and action dimensions. Confirm keyboard and touch activation without hover and that media does not shift the action on load. If a fixed mobile control is involved, state whether a real device with a nonzero safe-area inset was tested.
Find the relevant rule
Point the assistant to the installed Skill and a specific issue.
A sidebar card still uses the viewport layoutReference
- Command or reference
SKILL.md · Core Workflow- Examples
- Choose a named container query for the shared card's actual parent.
Fixed controls overlap bottom contentReference
- Command or reference
references/mobile-first-complete-guide.md- Examples
- Check reserved content padding and verify safe-area behavior on a suitable device.
Tailwind CSS Mobile First troubleshooting
What width triggers the named container variant?
Read the resolved container threshold from the generated CSS and measure the named container, even when the viewport is the same.