Token导航 LogoToken导航TokenDH.com
研究检索操作浏览器github未标认证来源可访问许可证需确认审计提醒

frontend-designer前端设计师

Agent Skill

用于辅助前端页面、组件、样式和交互逻辑的开发与维护。它适合让 Agent 生成或审查 React、Next.js、Vue、Tailwind、CSS 等相关代码,整理组件结构,或定位布局和性能问题。使用时需要结合项目现有设计系统、路由和构建方式,避免只生成孤立片段;涉及页面改动时,应配合本地预览和构建检查确认视觉效果。

总安装

1,018

周安装

42

GitHub Stars

2

下载量

333
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

unknown

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:frontend-designer(前端设计师)
来源仓库:https://github.com/wyattowalsh/agents
仓库路径:skills/frontend-designer
安装命令:
npx skills add https://github.com/wyattowalsh/agents --skill frontend-designer
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 npx skills 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

skills.shnpx skills
npx skills add https://github.com/wyattowalsh/agents --skill frontend-designer

简介

用于辅助前端页面、组件和样式逻辑开发。

  • 适合生成 React、Vue 或 Tailwind CSS 相关代码。
  • 使用时需结合项目现有设计系统和路由方式,避免孤立片段。
  • 安装命令:npx skills add https://github.com/wyattowalsh/agents --skill frontend-designer。
  • 涉及页面改动时应配合本地预览和构建检查确认效果。

SKILL.md

Frontend Designer

Build production-grade frontend interfaces with modern React, TailwindCSS v4, and shadcn/ui. Six modes from project scaffolding to rendered UI audit.

Input: $ARGUMENTS — mode keyword + target, natural language UI description, or file path.


Canonical Vocabulary

TermMeaningNOT
server componentReact component rendered on the server; default in Next.js/Remix App Router"SSR component"
client componentReact component with "use client" directive; runs in the browser"CSR component"
design tokenCSS custom property holding a design decision (color, spacing, font)"CSS variable" (too generic)
themeComplete set of design tokens configured in @theme {}"skin", "palette"
componentReusable UI building block (React component + styles)"widget", "module"
primitiveRadix UI base component providing behavior without styling"base component"
registryshadcn/ui component distribution endpoint (local or remote)"package", "library"
container queryCSS @container rule for component-scoped responsive design"media query" (page-scoped)
actionReact 19 Server Action: async function executed server-side via form"API call", "handler"
scaffoldCreate a new project with full stack configuration"bootstrap", "setup"
refactorModernize existing frontend code to current best practices"rewrite"
auditRead-only analysis of frontend codebase quality and patterns"review", "scan"
utility classTailwind CSS class mapping to a single CSS declaration"helper class"
logical propertyCSS property using start/end instead of left/right for RTL"directional property"
texture healingMonaspace technique for adjusting glyph spacing in monospace

Dispatch

Route $ARGUMENTS to the appropriate mode:

$ARGUMENTS patternModeStart at
scaffold <name> / init <name>ScaffoldMode A
component <name> / create <name>ComponentMode B
page <name> / view <name> / screen <name>Page/ViewMode F
theme / theme <path> / tokens / tokens <path>ThemeMode C
refactor <path> / style <path>RefactorMode D
audit / audit <path>AuditMode E
Natural language UI description ("build a sidebar", "design a card")Auto: ComponentMode B
Natural language page/view description ("build a landing page", "design a dashboard")Auto: Page/ViewMode F
Path to existing .tsx/.jsx/.css file or directoryAuto: RefactorMode D
Error message / "not working" / "broken"Auto: AuditMode E
"backend" / "API" / "database" / "DevOps" / testing / state / routing / build toolingRefuseRedirect to relevant skill
EmptyGalleryShow modes with example invocations

Classification Gate

For ambiguous inputs, disambiguate before routing:

SignalRoute to
Error, broken, bug, crash, "doesn't work"Audit
Test runner, state library, router, bundler, package manager, CIRefuse or redirect
Upgrade, modernize, migrate, update, convertRefactor
Colors, dark mode, tokens, palette, brandingTheme
Landing page, dashboard, settings, checkout, profile, app shell, route, screenPage/View
Build, create, design, add, new + component nounComponent
Setup, init, start, new projectScaffold
Mixed signalsAsk user which mode

Live Documentation (Optional)

Consult live docs only when: user reports unexpected behavior, a reference notes a pre-release API, or user asks about features not covered in bundled references.

  1. Context7resolve-library-id for "tailwindcss", "shadcn-ui", or "react", then query-docs.
  2. WebSearchsite:tailwindcss.com, site:ui.shadcn.com, or site:react.dev for specific topics.
  3. If live docs contradict bundled references, live docs win.

Mode A: Scaffold

Goal: Create a new project with the full modern frontend stack.

Load: references/tailwind-v4.md, references/vite-config.md, references/shadcn-patterns.md, references/typography.md, references/aesthetic-guide.md

A.1 Framework Selection

Ask or detect:

FrameworkWhen
Vite + ReactSPA, no SSR needed, fastest setup
Next.js App RouterSSR/SSG, Server Components, production web apps
RemixFull-stack, nested routing, progressive enhancement

Default to Vite + React unless user specifies otherwise.

A.2 Tailwind v4 Setup

CSS-first configuration — no tailwind.config.js:

@import "tailwindcss";

@theme {
  --color-primary: oklch(0.6 0.2 260);
  --color-surface: oklch(0.98 0 0);
  --color-surface-dark: oklch(0.15 0 0);
  --font-display: "Your Display Font", serif;
  --font-body: "Your Body Font", sans-serif;
  --font-mono: "Monaspace Neon", monospace;
}

A.3 shadcn/ui Init

npx shadcn@latest init

Configure components.json for project structure. Install core components: button, input, card, dialog, dropdown-menu, toast.

A.4 Typography

  • Code/mono: Monaspace Neon (or Argon, Krypton, Radon, Xenon per aesthetic)
  • Display: Distinctive, characterful — never Inter, Roboto, Arial, system-ui
  • Body: Clean, readable — pair with display font for contrast
  • Load references/typography.md for @font-face setup and fluid type scale.

A.5 Aesthetic Direction

Run the domain-fit gate and design thinking exercise (see Aesthetic Direction section below). Commit to an appropriate direction before writing UI code.

A.6 File Structure

src/
  components/ui/     # shadcn/ui components (managed by CLI)
  components/        # Custom project components
  lib/               # Utilities, helpers
  hooks/             # Custom React hooks
  styles/            # Global CSS, @theme, @font-face
  app/ or pages/     # Routes (framework-dependent)

A.7 Completion

Run the Visual Acceptance Gate before declaring scaffolded UI complete.


Mode B: Component

Goal: Design and build a single component with production quality.

Load: references/react-19.md, references/shadcn-patterns.md, references/modern-css.md Conditional: Load references/aesthetic-guide.md for visual/landing/hero/marketing components. Skip for utility components, forms, data tables.

B.1 Classify Component

ContextDefault"use client" needed?
Next.js / Remix App RouterServer ComponentOnly if using hooks, event handlers, or browser APIs
Vite + ReactClient ComponentNo — "use client" is unnecessary, all components are client

For compound components (e.g., <Tabs>, <Accordion>): separate server wrapper from client interactive parts.

B.2 Design Intent

Gather before building:

  • Purpose: What problem does this solve? Who uses it?
  • Interactions: Click, hover, drag, keyboard, touch?
  • Responsive behavior: How does it adapt across container sizes?
  • Accessibility: Required ARIA roles, keyboard patterns?

B.3 Primitive Selection

Check if shadcn/ui provides the component or a close base. If interactive (dialog, dropdown, popover, tooltip, tabs, accordion, toggle), use Radix UI primitives via shadcn/ui — never build from scratch.

Load references/shadcn-patterns.md for CLI commands and customization patterns.

B.4 Implement

  • Style with Tailwind v4 utility classes + CSS custom properties from @theme {}
  • Responsiveness: use @container queries for component-level adaptation, not media queries
  • Modern CSS: :has() for parent-based styling, view transitions for state changes
  • Keep component files focused — extract hooks and utilities to separate files

B.5 Accessibility

Non-negotiable for every interactive component:

  • Keyboard navigation (Tab, Enter, Escape, Arrow keys as appropriate)
  • ARIA attributes (roles, labels, descriptions, live regions)
  • Focus management (trap in modals, restore on close)
  • Color contrast: WCAG AA minimum (4.5:1 text, 3:1 large text/UI)

B.6 Completion

Run the Visual Acceptance Gate for any rendered component or component demo.


Mode C: Theme

Goal: Configure or reconfigure the project's design token system.

Load: references/tailwind-v4.md, references/modern-css.md, references/typography.md

C.1 Sub-dispatch

If $ARGUMENTS contains tokens: run token extraction workflow:

  1. Grep for hardcoded color values (hex, rgb, hsl) across .tsx, .jsx, .css files
  2. Grep for hardcoded spacing/font values not using Tailwind utilities
  3. Organize into three layers: primitive (raw values) → semantic (purpose-named) → component (scoped overrides)
  4. Generate @theme {} block with organized custom properties

C.2 Color System

Use oklch for perceptually uniform color manipulation:

@theme {
  --color-primary: oklch(0.6 0.2 260);
  --color-primary-light: color-mix(in oklch, var(--color-primary) 70%, white);
  --color-primary-dark: color-mix(in oklch, var(--color-primary) 70%, black);
}

contrast-color() is experimental — Firefox 146+ and Safari TP only. Use manual fallbacks:

/* Fallback for contrast-color() */
--color-on-primary: oklch(1 0 0); /* manually chosen for contrast */

C.3 Dark Mode

CSS custom properties strategy with Tailwind v4:

@custom-variant dark (&:where(.dark, .dark *));

Override tokens on the .dark selector:

.dark {
  --color-surface: oklch(0.15 0 0);
  --color-text: oklch(0.95 0 0);
}

C.4 Typography Scale

Fluid type scale with clamp():

@theme {
  --text-base: clamp(1rem, 0.5vw + 0.875rem, 1.125rem);
  --text-lg: clamp(1.125rem, 0.75vw + 1rem, 1.25rem);
  --text-xl: clamp(1.25rem, 1vw + 1.125rem, 1.5rem);
}

C.5 RTL Preparation

Audit and convert directional properties to logical equivalents:

PhysicalLogical
margin-leftmargin-inline-start
padding-rightpadding-inline-end
text-align: lefttext-align: start
float: rightfloat: inline-end

Mode D: Refactor

Goal: Modernize existing frontend code to current best practices.

Load: references/tailwind-v4.md, references/react-19.md, references/modern-css.md, references/anti-patterns.md

D.1 Pre-scan Checklist

Before any changes, scan the project:

  • Glob for tailwind.config.js or tailwind.config.ts — v3 legacy config?
  • Grep for "use client" count across .tsx/.jsx files
  • Grep for @media vs @container ratio — component responsiveness pattern?
  • Grep for hardcoded hex/rgb/hsl color values outside CSS custom properties
  • Grep for font-family declarations — are distinctive fonts used or defaults?
  • Check package.json for React version, Tailwind version, Vite version

D.2 Migration Patterns

FromToReference
tailwind.config.jsCSS-first @import "tailwindcss" + @theme {}references/tailwind-v4.md
@media for component sizing@container queriesreferences/modern-css.md
Manual dropdowns/modalsRadix primitives via shadcn/uireferences/shadcn-patterns.md
Hardcoded colorsDesign tokens in @theme {}Mode C
Class componentsFunction components + hooksreferences/react-19.md
Excessive "use client"Server Components where possible (Next.js/Remix only)references/react-19.md

D.3 Workflow

  1. Present file-by-file migration plan → user approval gate
  2. Execute changes, one file at a time
  3. Verify after each file: project checks pass and the Visual Acceptance Gate shows no regressions
  4. Re-run pre-scan checklist to confirm improvement

Mode E: Audit

Goal: Read-only analysis of frontend codebase quality. Never modify code.

Load: references/anti-patterns.md

E.1 Pre-scan

Run the same checklist as Mode D (§D.1).

E.2 Score Dimensions

DimensionWhat to check
Stack currencyTailwind v4 CSS-first? React 19? Latest shadcn/ui?
Component patternsServer vs client split? Radix primitives? Compound components?
Design tokens@theme usage? Hardcoded values? Token layers?
CSS modernnessContainer queries?:has()? Logical properties? @supports guards?
TypographyDistinctive fonts? Monaspace for code? Fluid type scale?
AccessibilityARIA attributes? Keyboard nav? Focus management? Contrast ratios?
Visual proofScreenshots/browser inspection? Mobile/desktop states? Overflow, overlap, focus, reduced motion?

E.3 Report Format

## Frontend Audit Report

### Critical (must fix)
- [finding with evidence]

### Warning (should fix)
- [finding with evidence]

### Suggestion (nice to have)
- [finding with evidence]

### Strengths
- [well-implemented patterns]

### Recommended Actions
- [action] → use `/frontend-designer refactor <path>`
- [action] → use `/frontend-designer theme`

Mode F: Page/View

Goal: Design and build a full page, route, screen, dashboard, landing page, or app shell.

Load: references/react-19.md, references/shadcn-patterns.md, references/modern-css.md, references/typography.md Conditional: Load references/aesthetic-guide.md for marketing, hero, editorial, portfolio, game, or brand-heavy pages.

F.1 Classify Page Context

Gather before building:

  • Domain: SaaS/admin/ops/docs/finance vs marketing/portfolio/editorial/game/product showcase
  • User job: Primary action, repeated workflow, scan/comparison need, decision point
  • Composition: Layout shell, route slots, navigation, responsive breakpoints, loading/empty/error states
  • Integration: Framework routing convention, Server/Client boundary, data placeholders, component reuse

F.2 Design and Implement

  1. Run the Aesthetic Direction domain-fit gate.
  2. Compose from shadcn/ui primitives and existing project components before custom UI.
  3. Keep page-level layout responsive with media queries and component internals responsive with container queries.
  4. Include meaningful loading, empty, and error states when the page represents data.
  5. Run the Visual Acceptance Gate before declaring complete.

Visual Acceptance Gate

Run for Scaffold, Component, Page/View, and Refactor outputs whenever a rendered surface exists.

  1. Start or use the project dev server when feasible; otherwise state why live rendering was not possible.
  2. Inspect at one mobile width and one desktop width.
  3. Capture or describe visual evidence for the changed surface.
  4. Verify no incoherent overlap, clipped text, horizontal overflow, layout jump, or unreadable state.
  5. Check keyboard focus order, visible focus indicators, Escape/arrow behavior where relevant, and reduced-motion behavior for animation.
  6. Check WCAG AA contrast: 4.5:1 for normal text, 3:1 for large text and UI indicators.
  7. Run the project’s relevant smoke/build command when available.

Aesthetic Direction

Before building visual components or pages, choose the direction that fits the domain and audience:

DomainDefault direction
SaaS, CRM, admin, finance, ops, docsRestrained, dense, scannable, predictable
Marketing, portfolio, editorial, brand, product showcaseExpressive, asset-led, memorable
Games, toys, experiments, art toolsPlayful, immersive, highly interactive

Design Thinking:

  1. Purpose — What problem does this interface solve? Who uses it?
  2. Tone — Pick a tone appropriate to the domain; use extreme aesthetics only when the product context supports them
  3. Constraints — Framework, performance budget, accessibility requirements
  4. Differentiation — What makes this unforgettable? The one thing someone remembers?

Anti-Slop Rules:

  • NEVER default to Inter, Roboto, Arial, or system fonts
  • NEVER use purple gradients on white backgrounds
  • NEVER produce cookie-cutter layouts that could come from any AI
  • NEVER converge on the same aesthetic across generations — vary themes, fonts, palettes
  • Match implementation complexity to vision: maximalism needs elaborate code; minimalism needs precision

Full aesthetic catalog, color theory, motion design, spatial composition: load references/aesthetic-guide.md.


Scope Boundaries

Supersedes: The frontend-design skill. All aesthetic guidance is now here.

NOT for:

  • Backend APIs, database design, DevOps configuration
  • Testing frameworks (Jest, Vitest) — use standard testing patterns
  • State management libraries (Zustand, Redux, Jotai) — choose per project needs
  • Routing (React Router, TanStack Router) — framework-specific docs
  • Full SSR framework setup (Next.js, Remix config beyond React 19 patterns)
  • Build tooling, package management — defer to javascript-conventions

Reference File Index

Load on demand during the relevant mode. Do NOT load all at once.

FileContentLoad during
references/tailwind-v4.mdCSS-first config, @theme, @import, Oxide engine, dark mode, container queries, v3→v4 migrationScaffold, Theme, Refactor
references/shadcn-patterns.mdCLI commands, components.json, RTL, registries, Radix primitives, compound components, formsScaffold, Component
references/react-19.mdServer vs Client decision tree (framework-dependent), Actions, useActionState, use(), SuspenseComponent, Refactor
references/modern-css.mdContainer queries,:has(), @scope, view transitions, scroll-driven animations, anchor positioning, color-mix(), @layerComponent, Theme, Refactor
references/typography.mdMonaspace superfamily, variable fonts, @font-face, font pairing, fluid type scale with clamp()Scaffold, Theme, Component (visual)
references/aesthetic-guide.mdDesign thinking, aesthetic catalog, color theory, motion, spatial composition, anti-slop rulesComponent (visual/landing/hero), Scaffold
references/vite-config.mdCurrent Vite setup, plugins, CSS handling, asset optimization, env variable securityScaffold
references/anti-patterns.mdDetection criteria and fixes for common frontend anti-patternsAudit, Refactor

Validation Contract

Run before declaring this skill complete after edits:

uv run wagents validate
uv run wagents eval validate
uv run python path/to/audit.py skills/frontend-designer/ --format json
uv run wagents package frontend-designer --dry-run
uv run pytest -q tests/test_frontend_designer_scan.py
uv run wagents readme --check

Completion criteria: all commands pass with zero errors, audit score is A (90+), and docs-steward has handled generated docs if skill docs changed.


Critical Rules

  1. Never use tailwind.config.js in Tailwind v4 — CSS-first with @import "tailwindcss" and @theme {} exclusively
  2. Framework-aware component model — In Next.js/Remix: minimize "use client", Server Components are default. In Vite+React: "use client" is unnecessary, all components are client
  3. Use Radix primitives via shadcn/ui for interactive components — never build custom dialogs, popovers, dropdowns, or tooltips from scratch
  4. Design tokens in CSS custom properties via @theme {} — never hardcode colors, spacing, or font values
  5. Container queries for component responsiveness — media queries for page layout and user preferences (prefers-color-scheme, prefers-reduced-motion, hover, pointer)
  6. @supports guards for progressive enhancement — mandatory for contrast-color(), anchor positioning, scroll-driven animations, @scope
  7. Logical properties for RTL readinessmargin-inline-start not margin-left, padding-block not padding-top
  8. Never default to Inter/Roboto/Arial/system-ui — select distinctive fonts; Monaspace for code contexts
  9. Accessibility non-negotiable — keyboard nav, ARIA, focus management, WCAG AA contrast (4.5:1 text, 3:1 large text)
  10. Consult live docs only when needed — references are stable; fetch Context7/WebSearch only for unexpected behavior or uncovered features
  11. Body stays under 500 lines — deep technical details go to reference files
  12. Audit mode is read-only — never modify code in audit mode
  13. Rendered UI must be proven — do not declare frontend work complete without the Visual Acceptance Gate or an explicit blocker

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Codex

34.93%
按下载量换算116

Claude

30.72%
按下载量换算102

Cursor

19.81%
按下载量换算66

Gemini CLI

9.69%
按下载量换算32

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

可疑

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills