ui-component – Design & UI skill for AI agents
Generate a new UI component following the StyleSeed design conventions
Install the ui-component skill with one command
Pick the tool you use, copy the command and paste it in your terminal. The skill lands in that tool's skills folder and is ready in your next session.
Claude Code
mkdir -p ~/.claude/skills && curl -fsSL https://skill.dn1nguoi.com/z/ui-component-3e566.tgz | tar xz -C ~/.claude/skills
Call it in Claude Code: /ui-component – then describe the task you want done.
Codex
mkdir -p ~/.codex/skills && curl -fsSL https://skill.dn1nguoi.com/z/ui-component-3e566.tgz | tar xz -C ~/.codex/skills
Call it in Codex: $ui-component – then describe the task you want done.
Hermes Agent
mkdir -p ~/.hermes/skills && curl -fsSL https://skill.dn1nguoi.com/z/ui-component-3e566.tgz | tar xz -C ~/.hermes/skills
Call it in Hermes Agent: /ui-component – then describe the task you want done.
DeepSeek
mkdir -p ~/.deepcode/skills && curl -fsSL https://skill.dn1nguoi.com/z/ui-component-3e566.tgz | tar xz -C ~/.deepcode/skills
Call it in DeepSeek: /ui-component – then describe the task you want done.
SKILL.md content
UI Component Generator
When to Use
Use this skill when you need generate a new UI component following the StyleSeed design conventions.
When NOT to use
- For full-page scaffolding → use
/ss-page - For composed multi-component patterns → use
/ss-pattern - For tweaking an existing component — just edit the file directly
- For non-StyleSeed projects (no
components/ui/directory or no Tailwind v4)
Generate a new component: $0
Description: $ARGUMENTS
Instructions
1. First, read the design system seed for context:
- Read
CLAUDE.mdfor component conventions - Read
css/theme.cssfor available design tokens - Read
components/ui/button.tsxas a reference pattern
2. Follow these conventions strictly:
- Use
functiondeclaration (notconst) - Add
data-slot="component-name"attribute - Use
cn()from@/components/ui/utilsfor all className merging - Use
React.ComponentProps<>for prop typing - Always support
classNameprop for overrides - Use CVA (
class-variance-authority) if the component has variants - Use semantic color tokens (
bg-card,text-foreground) — never inline hex
3. Design token usage:
- Colors:
text-foreground,bg-card,text-brand,text-muted-foreground,border-border - Shadows:
shadow-[var(--shadow-card)],shadow-[var(--shadow-elevated)] - Radius:
rounded-md,rounded-lg,rounded-2xl - Spacing: multiples of 6px (
p-1.5,p-3,p-6) - Motion:
duration-[var(--duration-fast)],ease-[var(--ease-default)]
4. Typography rules:
- Display (36-48px):
leading-none tracking-[-0.02em] - Heading (18-24px):
leading-snug tracking-[-0.01em] - Body (14-17px):
leading-normal(default tracking) - Caption uppercase (10-13px):
tracking-[0.05em] - Use
size-*shorthand instead ofw-* h-* - Use
ms-*/me-*instead ofml-*/mr-*(logical properties)
5. Accessibility requirements:
- Minimum touch target: 44x44px (
min-h-11 min-w-11) - Support
aria-*attributes passthrough - Use
focus-visible:ring-2 focus-visible:ring-ringfor keyboard focus - Respect
prefers-reduced-motionfor animations
6. Export the component as a named export (not default)
7. Place the file in the appropriate directory:
- Primitive/reusable →
src/components/ui/ - Composed pattern →
src/components/patterns/
Example
User request:
> Generate a new UI component following the StyleSeed design conventions.
Limitations
- Use this skill only when the task clearly matches its upstream source and local project context.
- Verify commands, generated code, dependencies, credentials, and external service behavior before applying changes.
- Do not treat examples as a substitute for environment-specific tests, security review, or user approval for destructive or costly actions.
Execution boundaries
This guide targets an existing StyleSeed project. The listed project paths, components, tokens and /ss-* commands are not bundled in this single-file entrypoint. Discover the actual project root and verify those prerequisites before edits; report absent resources instead of inventing them. Use host-supported invocation and existing project conventions. Layout numbers are design-system choices, not universal usability guarantees. Test keyboard access, responsive overflow and reduced motion on the actual interface.
Related skills
- ui-from-screenshot – Turn a screenshot or mockup into matching UI with the project's own components, then…
- ui-lint – Quick automated lint — detects common design system violations in seconds
- ui-motion – Apply a named StyleSeed motion to a component — either one of the 5 personality seeds…
- ui-page – Scaffold a new mobile page/screen using the StyleSeed layout patterns
- ui-pattern – Generate a composed UI pattern (card layout, list, form section, grid, etc.) using…
- ui-review – Review UI code for design system compliance, accessibility, and best practices
- ui-score – Score a UI file's design quality 0-100 against StyleSeed's design language —…
- ui-setup – Interactive setup wizard — guides you step-by-step to configure the design system for…