Token导航 LogoToken导航TokenDH.com
前端设计执行命令github未标认证来源可访问clear审计通过

frontend-design前端设计

Agent Skill

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

总安装

14,582

周安装

620

GitHub Stars

15,886

下载量

5,109
CodexClaudeCursorGemini CLI

安装说明

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

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

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

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

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/everyinc/compound-engineering-plugin --skill frontend-design

简介

frontend-design 用于辅助前端页面、组件、样式和交互逻辑的开发与维护,支持 React、Next.js、Vue、Tailwind、CSS 等技术栈。

  • 它能生成或审查 UI 代码,整理组件结构,诊断布局问题,并遵循项目设计系统保持一致性。
  • 使用时需结合现有路由、构建方式和设计规范,避免孤立片段;涉及页面改动应配合本地预览验证效果。
  • 安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写等操作。
  • 适用宿主包括 Codex、Claude、Cursor、Gemini CLI,接入前应确认版本、权限和运行环境要求。

SKILL.md

Frontend Design

Guide creation of distinctive, production-grade frontend interfaces that avoid generic AI aesthetics. This skill covers the full lifecycle: detect what exists, plan the design, build with intention, and verify visually.

Authority Hierarchy

Every rule in this skill is a default, not a mandate.

  1. Existing design system / codebase patterns -- highest priority, always respected
  2. User's explicit instructions -- override skill defaults
  3. Skill defaults -- apply in greenfield work or when the user asks for design guidance

When working in an existing codebase with established patterns, follow those patterns. When the user specifies a direction that contradicts a default, follow the user.

Workflow

Detect context -> Plan the design -> Build -> Verify visually

Layer 0: Context Detection

Before any design work, examine the codebase for existing design signals. This determines how much of the skill's opinionated guidance applies.

What to Look For

  • Design tokens / CSS variables: --color-*, --spacing-*, --font-* custom properties, theme files
  • Component libraries: shadcn/ui, Material UI, Chakra, Ant Design, Radix, or project-specific component directories
  • CSS frameworks: tailwind.config.*, styled-components theme, Bootstrap imports, CSS modules with consistent naming
  • Typography: Font imports in HTML/CSS, @font-face declarations, Google Fonts links
  • Color palette: Defined color scales, brand color files, design token exports
  • Animation libraries: Framer Motion, GSAP, anime.js, Motion One, Vue Transition imports
  • Spacing / layout patterns: Consistent spacing scale usage, grid systems, layout components

Use the platform's native file-search and content-search tools (e.g., Glob/Grep in Claude Code) to scan for these signals. Do not use shell commands for routine file exploration.

Mode Classification

Based on detected signals, choose a mode:

  • Existing system (4+ signals across multiple categories): Defer to it. The skill's aesthetic opinions (typography, color, motion) yield to the established system. Structural guidance (composition, copy, accessibility, verification) still applies.
  • Partial system (1-3 signals): Follow what exists; apply skill defaults only for areas where no convention was detected. For example, if Tailwind is configured but no component library exists, follow the Tailwind tokens and apply skill guidance for component structure.
  • Greenfield (no signals detected): Full skill guidance applies.
  • Ambiguous (signals are contradictory or unclear): Ask the user before proceeding.

Asking the User

When context is ambiguous, use the platform's blocking question tool (AskUserQuestion in Claude Code, request_user_input in Codex, ask_user in Gemini). If no question tool is available, assume "partial" mode and proceed conservatively.

Example question: "I found [detected signals]. Should I follow your existing design patterns or create something distinctive?"


Layer 1: Pre-Build Planning

Before writing code, write three short statements. These create coherence and give the user a checkpoint to redirect before code is written.

  1. Visual thesis -- one sentence describing the mood, material, and energy

- Greenfield examples: "Clean editorial feel, lots of whitespace, serif headlines, muted earth tones" or "Dense data-forward dashboard, monospace accents, dark surface hierarchy" - Existing codebase: Describe the *existing* aesthetic and how the new work will extend it

  1. Content plan -- what goes on the page and in what order

- Landing page: hero, support, detail, CTA - App: primary workspace, nav, secondary context - Component: what states it has, what it communicates

  1. Interaction plan -- 2-3 specific motion ideas that change the feel

- Not "add animations" but "staggered fade-in on hero load, parallax on scroll between sections, scale-up on card hover" - In an existing codebase, describe only the interactions being added, using the existing motion library


Layer 2: Design Guidance Core

These principles apply across all context types. Each yields to existing design systems and user instructions per the authority hierarchy.

Typography

  • Choose distinctive, characterful fonts. Avoid the usual suspects (Inter, Roboto, Arial, system defaults) unless the existing codebase uses them.
  • Two typefaces maximum without a clear reason for more. Pair a display/headline font with a body font.
  • *Yields to existing font choices when detected in Layer 0.*

Color & Theme

  • Commit to a cohesive palette using CSS variables. A dominant color with sharp accents outperforms timid, evenly-distributed palettes.
  • No purple-on-white bias, no dark-mode bias. Vary between light and dark based on context.
  • One accent color by default unless the product already has a multi-color system.
  • *Yields to existing color tokens when detected.*

Composition

  • Start with composition, not components. Treat the first viewport as a poster, not a document.
  • Use whitespace, alignment, scale, cropping, and contrast before adding chrome (borders, shadows, cards).
  • Default to cardless layouts. Cards are allowed when they serve as the container for a user interaction (clickable item, draggable unit, selectable option). If removing the card styling would not hurt comprehension, it should not be a card.
  • *All composition rules are defaults. The user can override them.*

Motion

  • Ship 2-3 intentional motions for visually-led work: one entrance sequence, one scroll-linked or depth effect, one hover/reveal transition.
  • Use the project's existing animation library if one is present.
  • When no existing library is found, use framework-conditional defaults:

- CSS animations as the universal baseline - Framer Motion for React projects - Vue Transition / Motion One for Vue projects - Svelte transitions for Svelte projects

  • Motion should be noticeable in a quick recording, smooth on mobile, and consistent across the page. Remove if purely ornamental.

Accessibility

  • Semantic HTML by default: nav, main, section, article, button -- not divs for everything.
  • Color contrast meeting WCAG AA minimum.
  • Focus states on all interactive elements.
  • Accessibility and aesthetics are not in tension when done well.

Imagery

  • When images are needed, prefer real or realistic photography over abstract gradients or fake 3D objects.
  • Choose or generate images with a stable tonal area for text overlay.
  • If image generation tools are available in the environment, use them to create contextually appropriate visuals rather than placeholder stock.

Context Modules

Select the module that fits what is being built. When working inside an existing application, default to Module C regardless of what the feature is.

Module A: Landing Pages & Marketing (Greenfield)

Default section sequence:

  1. Hero -- brand/product, promise, CTA, one dominant visual
  2. Support -- one concrete feature, offer, or proof point
  3. Detail -- atmosphere, workflow, product depth, or story
  4. Final CTA -- convert, start, visit, or contact

Hero rules (defaults):

  • One composition, not a dashboard. Full-bleed image or dominant visual plane.
  • Brand first, headline second, body third, CTA fourth.
  • Keep the text column narrow and anchored to a calm area of the image.
  • No more than 6 sections total without a clear reason.
  • One H1 headline. One primary CTA above the fold.

Copy:

  • Let the headline carry the meaning. Supporting copy is usually one short sentence.
  • Write in product language, not design commentary. No prompt language or AI commentary in the UI.
  • Each section gets one job: explain, prove, deepen, or convert.
  • Every sentence should earn its place. Default to less copy, not more.

Module B: Apps & Dashboards (Greenfield)

Default patterns:

  • Calm surface hierarchy, strong typography and spacing, few colors, dense but readable information, minimal chrome.
  • Organize around: primary workspace, navigation, secondary context/inspector, one clear accent for action or state.
  • Cards only when the card is the interaction (clickable item, draggable unit, selectable option). If a panel can become plain layout without losing meaning, remove the card treatment.

Copy (utility, not marketing):

  • Prioritize orientation, status, and action over promise, mood, or brand voice.
  • Section headings should say what the area is or what the user can do there. Good: "Plan status", "Search metrics". Bad: "Unlock Your Potential".
  • If a sentence could appear in a homepage hero, rewrite it until it sounds like product UI.
  • Litmus: if an operator scans only headings, labels, and numbers, can they understand the page immediately?

Module C: Components & Features (Default in Existing Apps)

For adding to an existing application:

  • Match the existing visual language. This module is about making something that belongs, not something that stands out.
  • Inherit spacing scale, border radius, color tokens, and typography from surrounding code.
  • Focus on interaction quality: clear states (default, hover, active, disabled, loading, error), smooth transitions between states, obvious affordances.
  • One new component should not introduce a new design system. If the existing app uses 4px border radius, do not add a component with 8px.

Hard Rules & Anti-Patterns

Default Against (Overridable)

These are the skill being opinionated. The user can override any of them.

  • Generic SaaS card grid as the first impression
  • Purple-on-white color schemes, dark-mode bias
  • Overused fonts (Inter, Roboto, Arial, Space Grotesk, system defaults) in greenfield work
  • Hero sections cluttered with stats, schedules, pill clusters, logo clouds
  • Sections that repeat the same mood statement in different words
  • Carousel with no narrative purpose
  • Multiple competing accent colors
  • Decorative gradients or abstract backgrounds standing in for real visual content
  • Copy that sounds like design commentary ("Experience the seamless integration")
  • Split-screen heroes where text sits on the busy side of an image

Always Avoid (Quality Floor)

These are genuine quality failures no user would want.

  • Prompt language or AI commentary leaking into the UI
  • Broken contrast -- text unreadable over images or backgrounds
  • Interactive elements without visible focus states
  • Semantic div soup when proper HTML elements exist

Litmus Checks

Quick self-review before moving to visual verification. Not all checks apply in every context -- apply judgment about which are relevant.

  • Is the brand or product unmistakable in the first screen?
  • Is there one strong visual anchor?
  • Can the page be understood by scanning headlines only?
  • Does each section have one job?
  • Are cards actually necessary where they are used?
  • Does motion improve hierarchy or atmosphere, or is it just there?
  • Would the design feel premium if all decorative shadows were removed?
  • Does the copy sound like the product, not like a prompt?
  • Does the new work match the existing design system? (Module C)

Visual Verification

After implementing, verify visually. This is a sanity check, not a pixel-perfect review. One pass. If there is a glaring issue, fix it. If it looks solid, move on.

Tool Preference Cascade

Use the first available option:

  1. Existing project browser tooling -- if Playwright, Puppeteer, Cypress, or similar is already in the project's dependencies, use it. Do not introduce new dependencies just for verification.
  2. Browser MCP tools -- if browser automation tools (e.g., claude-in-chrome) are available in the agent's environment, use them.
  3. agent-browser CLI -- if nothing else is available and agent-browser is installed, use it. If not installed, inform the user: "agent-browser is not installed. Run /ce-setup to install required dependencies." Then skip to the next option.
  4. Mental review -- if no browser access is possible (headless CI, no permissions to install), apply the litmus checks as a self-review and note that visual verification was skipped.

What to Assess

  • Does the output match the visual thesis from the pre-build plan?
  • Are there obvious visual problems (broken layout, unreadable text, missing images)?
  • Does it look like the context module intended (landing page feels like a landing page, dashboard feels like a dashboard, component fits its surroundings)?

Scope Control

One iteration. Take a screenshot, assess against the litmus checks, fix any glaring issues, and move on. Include the screenshot in the deliverable (PR description, conversation output, etc.).

For iterative refinement beyond a single pass (multiple rounds of screenshot-assess-fix), see the compound-engineering:design:design-iterator agent.


Creative Energy

This skill provides structure, but the goal is distinctive work that avoids AI slop -- not formulaic output.

For greenfield work, commit to a bold aesthetic direction. Consider the tone: brutally minimal, maximalist, retro-futuristic, organic/natural, luxury/refined, playful, editorial, brutalist, art deco, soft/pastel, industrial -- or invent something that fits the context. There are endless flavors. Use these for inspiration but design one that is true to the project.

Ask: what makes this unforgettable? What is the one thing someone will remember?

Match implementation complexity to the aesthetic vision. Maximalist designs need elaborate code with extensive animations and effects. Minimalist designs need restraint, precision, and careful attention to spacing, typography, and subtle details. Elegance comes from executing the vision well, not from intensity.

适合场景

01

前端页面设计

02

生成更有辨识度的 UI

03

避免模板化 AI 页面

04

需要统一视觉方向时

能力概览

能力 1

建立明确视觉方向

能力 2

约束排版、色彩、动效和空间布局

能力 3

提醒避免通用模板化设计

能力 4

要求生成可运行的前端实现

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

平台分布

Claude Code

30.41%
按下载量换算1,554

Cursor

22.89%
按下载量换算1,169

OpenCode

18.48%
按下载量换算944

Gemini CLI

13.52%
按下载量换算691

Antigravity

8.19%
按下载量换算418

Codex

3.5%
按下载量换算179

安全审计

Gen Agent Trust Hub

通过

Socket

通过

Snyk

通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/everyinc/compound-engineering-plugin --skill frontend-design;npx skills add everyinc/compound-engineering-plugin --skill "frontend-design" 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。

来源信息

继续浏览同类 Skills