frontend-design

GitHub

用于生成具备专业设计感的UI代码。通过显式令牌系统(类型、间距、色彩)和全面的状态设计,解决AI生成界面千篇一律的问题,产出布局严谨、视觉克制的HTML/CSS或组件。

skills/frontend-design/SKILL.md mohitagw15856/pm-claude-skills

Trigger Scenarios

需要构建或重构UI界面 要求建立应用视觉规范 现有输出看起来像未完成的原型

Install

npx skills add mohitagw15856/pm-claude-skills --skill frontend-design -g -y
More Options

Use without installing

npx skills use mohitagw15856/pm-claude-skills@frontend-design

指定 Agent (Claude Code)

npx skills add mohitagw15856/pm-claude-skills --skill frontend-design -a claude-code -g -y

安装 repo 全部 skill

npx skills add mohitagw15856/pm-claude-skills --all -g -y

预览 repo 内 skill

npx skills add mohitagw15856/pm-claude-skills --list

SKILL.md

Frontmatter
{
    "name": "frontend-design",
    "description": "Produce frontend UI that actually looks designed — a working spacing\/type system, deliberate color use, real states, and restraint — instead of the generic AI-generated interface. Use when asked to build or restyle a UI, landing page, dashboard, or component, when output 'works but looks like a prototype', or to establish the visual system for a new app. Produces working HTML\/CSS (or framework components) built on an explicit token system, with hover\/focus\/empty\/loading states included. For critiquing an existing design use design-critique; for auditing a design system use design-system-audit."
}

Frontend Design Skill

AI-generated UI has a recognisable smell: default blues, five different paddings, everything the same visual weight, no states. This skill produces interfaces that look decided — by making the decisions explicit as a token system, then spending contrast deliberately instead of everywhere.

What This Skill Produces

  • Working UI code (single-file HTML/CSS or framework components) built on an explicit token block
  • The token system: type scale, spacing scale, color roles, radius/shadow levels — small and consistent
  • The states: hover, focus-visible, active, disabled, empty, loading, error — designed, not defaulted

Required Inputs

Ask for (if not already provided):

  • What's being built and its emotional register (dense pro tool? calm consumer? playful?)
  • Brand constraints if any (colors, fonts, an existing product to match) — else the skill picks a deliberate palette and says so
  • The framework target (vanilla/React/Vue/Tailwind) — vanilla single-file is the default demo form

The System (build this first, then the UI)

  1. Type scale, one ratio. Pick a base (16px) and a ratio (1.25 for product UI, 1.333 for marketing); derive 5-6 sizes max. Two font families ceiling (one is usually right); weight does hierarchy work before size does.
  2. Spacing on a single scale. 4-or-8px base: 4/8/12/16/24/32/48/64. Every margin/padding/gap comes FROM the scale — the #1 tell of undesigned UI is seventeen distinct paddings. Related things sit closer than unrelated things (proximity is free information design).
  3. Color as roles, not decoration. Define roles: bg / surface / border / text / text-muted / accent / danger / success. ONE accent, spent where attention belongs — the primary action, the active state, the number that matters. The 90% of a designed UI is neutrals; if everything is colorful, nothing is. Check text contrast (4.5:1 body, 3:1 large) as you pick, not after.
  4. Depth and shape, one voice. 2-3 shadow levels, 2 radius values — used consistently by element class (inputs share a radius; cards share a shadow). Mixed radii on sibling elements reads as accident, because it is.
  5. Motion with restraint. 120-200ms ease-out on hover/expand; prefers-reduced-motion respected; nothing bounces in a pro tool.

The Craft Moves (what separates designed from default)

  • Hierarchy by subtraction — make everything quieter, then raise ONLY what matters: the page should answer "look here first" without arrows
  • Real content shapes — design with a long name, a zero, a 47-item list; lorem-ipsum layouts break on contact with reality
  • The states are the interface — empty states teach ("no reports yet — create your first"), loading states hold layout (skeletons, not spinners-in-a-void), focus-visible is styled (keyboard users see where they are), errors say what to DO
  • Alignment is invisible until broken — one grid, edges that line up, numbers right-aligned in tables
  • Density matches the job — dashboards earn compactness; marketing earns whitespace; mixing registers is the "prototype feel"

Output Format

  1. The token block first (CSS custom properties / theme object) with one line on each decision ("accent used 3 places only")
  2. The working code, componentised sensibly, states included inline
  3. A design-decisions note (5-8 lines): register chosen, where the accent is spent, what was deliberately left quiet

Quality Checks

  • Every spacing value in the code exists on the declared scale — zero ad-hoc paddings
  • One accent color, findable in ≤3 uses; body text contrast ≥4.5:1
  • Hover, focus-visible, disabled, empty, and loading states all present and styled
  • The "look here first" test passes — hierarchy is felt without instruction
  • Tested mentally against real content: the long name, the zero state, the overflow

Anti-Patterns

  • Do not decorate before systematising — tokens first, UI second, or consistency is luck
  • Do not spend the accent everywhere — a UI where everything is highlighted has no hierarchy, just noise
  • Do not ship default focus rings removed with nothing in their place — that's not minimal, it's broken
  • Do not design only the happy state — empty/loading/error are where users actually judge the product
  • Do not mix density registers — a marketing hero above a data grid needs a deliberate seam, not a collision

Version History

  • a38bc30 Current 2026-07-05 11:36

Same Skill Collection

exports/openclaw/360-feedback-template/SKILL.md
exports/openclaw/401k-plan-decoder/SKILL.md
exports/openclaw/ab-test-planner/SKILL.md
exports/openclaw/ab-test-readout/SKILL.md
exports/openclaw/accessibility-audit/SKILL.md
exports/openclaw/account-plan/SKILL.md
exports/openclaw/acquirer-red-team/SKILL.md
exports/openclaw/ad-copy/SKILL.md
exports/openclaw/aeo-optimizer/SKILL.md
exports/openclaw/agenda-or-cancel/SKILL.md
exports/openclaw/agent-design-review/SKILL.md
exports/openclaw/agent-observability-spec/SKILL.md
exports/openclaw/agent-spec/SKILL.md
exports/openclaw/ai-ethics-review/SKILL.md
exports/openclaw/ai-eval-plan/SKILL.md
exports/openclaw/ai-feature-prd/SKILL.md
exports/openclaw/ai-product-canvas/SKILL.md
exports/openclaw/air-quality/SKILL.md
exports/openclaw/altitude-shifter/SKILL.md
exports/openclaw/ambiguity-resolver/SKILL.md
exports/openclaw/analyst-relations-brief/SKILL.md
exports/openclaw/announcement-card/SKILL.md
exports/openclaw/api-docs-writer/SKILL.md
exports/openclaw/api-test-plan/SKILL.md
exports/openclaw/api-versioning-strategy/SKILL.md
exports/openclaw/apology-letter/SKILL.md
exports/openclaw/architecture-decision-record/SKILL.md
exports/openclaw/architecture-diagram/SKILL.md
exports/openclaw/archive-strategy/SKILL.md
exports/openclaw/assumption-bounty/SKILL.md
exports/openclaw/assumption-mapper/SKILL.md
exports/openclaw/async-update-format/SKILL.md
exports/openclaw/auto-repair-estimate-decoder/SKILL.md
exports/openclaw/autopilot-charter/SKILL.md
exports/openclaw/benefits-decoder/SKILL.md
exports/openclaw/bid-tender-review/SKILL.md
exports/openclaw/board-deck-narrative/SKILL.md
exports/openclaw/board-minutes/SKILL.md
exports/openclaw/board-pre-read/SKILL.md
exports/openclaw/bom-cost-review/SKILL.md
exports/openclaw/bookkeeping-categorization/SKILL.md
exports/openclaw/boolean-search-builder/SKILL.md
exports/openclaw/brag-doc/SKILL.md
exports/openclaw/brainstorming/SKILL.md
exports/openclaw/brief-builder/SKILL.md
exports/openclaw/briefing-note/SKILL.md
exports/openclaw/budget-builder/SKILL.md
exports/openclaw/budget-variance-analysis/SKILL.md
exports/openclaw/bug-diagnosis/SKILL.md
exports/openclaw/bug-report/SKILL.md

Metadata

Files
0
Version
471c606
Hash
05afadab
Indexed
2026-07-05 11:36

- 위키
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-07-30 16:24
浙ICP备14020137号-1 $방문자$