AgentSkillsCN

frontend-design

独具特色的前端界面设计——大胆鲜明的设计风格、定制化的设计系统、精湛的字体运用、成熟的色彩理论、精妙的动效设计、合理的空间布局、避免千篇一律的通用设计模式。适用于 UI 设计、视觉识别塑造、设计方向确立,或在通用模板的基础上进一步提升界面美学。

SKILL.md
--- frontmatter
name: frontend-design
description: Distinctive frontend interface design — bold aesthetic direction, custom design systems, typography mastery, color theory, motion design, spatial composition, anti-generic patterns. Use when designing UIs, creating visual identity, establishing design direction, or elevating interface aesthetics beyond generic templates.
license: MIT

Frontend Design — Anti-Generic UI

Create interfaces that are distinctive, memorable, and intentional. Fight against the sea of identical AI-generated UIs.

Core Philosophy

Every pixel is a decision. Generic is the enemy of great.

Most AI-generated UIs look the same: same rounded corners, same gradient buttons, same card layouts. This skill teaches you to break free.

The 5 Design Pillars

1. Typography as Architecture

code
Typography is 80% of web design. Master it.

- Choose 2 fonts maximum: 1 display + 1 body
- Create a modular scale: 12, 14, 16, 20, 24, 32, 40, 48, 64px
- Use weight contrast, not just size, for hierarchy
- Letter-spacing: tighter for headings, normal for body
- Line-height: 1.1-1.2 for headings, 1.5-1.7 for body

Font Pairing Examples:

DisplayBodyVibe
Space GroteskInterTech, modern
Playfair DisplaySource Sans 3Editorial, elegant
Clash DisplaySatoshiBold, contemporary
FrauncesWork SansWarm, approachable
JetBrains MonoIBM Plex SansDeveloper, precise

2. Color as Emotion

code
Avoid generic: blue hero, white body, gray footer.
Instead, build a palette that tells a story.

Palette Building Process:

  1. Start with ONE signature color (not primary blue!)
  2. Build 5-shade scale: lightest → darkest
  3. Add 1 accent color (complementary or analogous)
  4. Define semantic colors: success, warning, error, info
  5. Create dark mode variants (don't just invert!)

Color Relationships:

TypeMethodExample
MonochromaticShades of one hueDeep navy → light sky
ComplementaryOpposite on wheelTeal + coral
AnalogousAdjacent huesPurple → blue → teal
Split ComplementaryMain + 2 adjacents of complementYellow + blue-purple + red-purple

3. Motion as Communication

code
Animation should communicate, not decorate.

Purposeful motion:                 Decorative motion:
✅ Show state change                ❌ Spinning logos
✅ Guide attention                  ❌ Parallax everything
✅ Provide feedback                 ❌ Bouncing elements
✅ Establish spatial relationships   ❌ Auto-playing carousels

Timing Guidelines:

InteractionDuration
Button feedback100-150ms
Menu open/close150-250ms
Page transition200-400ms
Complex animation300-500ms
Attention-grab600-1000ms

Easing:

  • ease-out for entering elements (fast start, slow end)
  • ease-in for exiting elements (slow start, fast end)
  • ease-in-out for elements that stay on screen
  • Never use linear (feels robotic)

4. Spatial Composition

code
Whitespace is not empty space — it's breathing room.

Rules:
- Related items: 8-16px gap
- Sections: 48-96px gap
- Page margins: 5-10% of viewport
- Asymmetry > symmetry for visual interest
- Grid systems: 4px or 8px base unit

Layout Principles:

  • Rhythm: Consistent vertical spacing creates visual flow
  • Hierarchy: Size + weight + color + space = importance
  • Alignment: Invisible lines connect related elements
  • Contrast: Light vs dark, large vs small, dense vs sparse

5. Detail Obsession

code
The difference between good and great is in the details:
- Border radius: consistent across the entire UI (pick one: 4px, 8px, 12px)
- Shadows: subtle, directional, with color tinting
- Borders: 1px with low-opacity dark color, not solid gray
- Icons: stroke width matches font weight
- Hover states: every interactive element has one
- Focus states: visible, accessible, styled (not default blue outline)

Reference Navigation

  • Design Tokens — Building a complete token system (spacing, color, type, motion)
  • Layout Patterns — Hero sections, dashboards, landing pages, editorial layouts
  • Component Styling — Buttons, cards, inputs, navigation with personality
  • Design Inspiration — Reference sites, award galleries, trend analysis

Anti-Generic Checklist

Before shipping any interface, ask:

  • Is the typography intentional? (Not just default Inter at default sizes)
  • Are the colors unique? (Not generic Bootstrap blue/green/red)
  • Does the layout have rhythm? (Consistent spacing, clear hierarchy)
  • Are animations purposeful? (Not decorative, they communicate something)
  • Would this look like "my brand"? (Distinct from competitors)
  • Is there attention to micro-details? (Shadows, borders, hover states)
  • Does it have an opinion? (Not trying to be everything to everyone)

Related Skills

SkillWhen to Use
ui-stylingTailwind CSS implementation, shadcn/ui
ui-polishVisual refinement process, inspiration capture
nextjs-turborepoNext.js layout and routing