设计与多媒体

Design Spec Personal

试用

生成并验证 UI 设计交付物:可交互 preview.html、annotated.html、tokens.css、spec.json 与 assumptions.log。支持文字、截图、Sketch、Figma 输入,以及 mobile-h5/web-pc 平台;按需加载 universal、内置或用户导入的...

它能做什么

生成并验证 UI 设计交付物:可交互 preview.html、annotated.html、tokens.css、spec.json 与 assumptions.log。支持文字、截图、Sketch、Figma 输入,以及 mobile-h5/web-pc 平台;按需加载 universal、内置或用户导入的 design profile,执行组件路由、场景模板、token 约束、静态 QA 和 真实浏览器验收。支持 W3C/Style Dictionary Token 导入。用户要求设计稿、原型、UI、页面设计、视觉稿、交互稿、design、prototype、 mockup、wireframe、hi-fi、设计还原、design token、annotated spec、d2c、Ant Design、antd、 antd-mobile、Arco Design、Arco、中后台或移动端 H5 时使用。

技能文档

design

A unified design skill that produces hi-fi interactive prototypes and implementation-ready specs in a single run. Every output is simultaneously a visual artifact and a precise engineering specification.

What it produces

From any input, always generates the design deliverables plus browser evidence:

FileFor whomWhat it is
preview.htmlPM / DesignerHi-fi interactive prototype
annotated.htmlEngineer / AI coding toolSpec-annotated HTML with data-spec-* attributes
tokens.cssEveryoneCSS custom properties — the single source of truth
spec.jsonAI coding toolMachine-readable full spec with states and assumptions
assumptions.logAI coding toolEvery inferred/estimated value, marked with confidence
preview.measure-report.jsonQA / AI coding toolBrowser-measured geometry, contrast, overflow, and P0/P1 findings
preview.measured.pngReviewerScreenshot captured from the same measured browser session
acceptance.spec.mjsEngineer / CIExecutable P0/P1 and geometry regression contract

How to use this skill

1. Detect your harness. Read the matching reference doc once:

  • Claude Code (AskUserQuestion, SendUserFile, Claude Preview MCP) → read references/claude.md
  • Cursor (AskQuestion, cursor-ide-browser MCP) → read references/cursor.md
  • Codex Agent (functions.*, Codex Browser) → read references/codex.md

2. Load the core methodology. Read system-prompt.md — the L1→L4 pipeline, quality rules, and output generation guidelines.

3. Identify input type. Read the matching handler:

  • Text description → input-handlers/text.md
  • Screenshot / image → input-handlers/screenshot.md
  • Sketch file (.sketch) → input-handlers/sketch.md
  • Figma URL → input-handlers/figma.md

4. Load the design system. Three-layer stack: universal → standard → brand. Load in order, later layers override earlier ones.

Layer 1 — Universal (progressive load):

Core:

  • Copy tokens.css and component-tokens.css to the output without preloading their full contents; query only selected token definitions when needed.
  • Read component-routing.md once as the fallback binding gate.

Load only when the current decision needs it:

  • Universal component is selected → components.md
  • Token semantics are unresolved → usage-guidelines.md
  • Page skeleton is unresolved → layout-patterns.md
  • A concrete interaction pattern is used → interaction-patterns.md
  • apple-hig only → macos-patterns.md
  • Hardcoded platform/SVG/preview constants appear → token-exceptions.md
  • Functional icons or simulated platform chrome appear → icon-policy.md
  • Relevant failure pattern only → anti-examples.md
  • Before visual delivery → critic-checklist.md and visual-critic.md

Layer 2 — Design Standard Profile (load when user specifies a standard, or when platform implies one):

  • 先读 design-system/profiles/registry.json,把用户指定标准按忽略大小写、合并空白的规则匹配唯一 profile_id 或 alias;未知或冲突时阻断,不猜测。
  • 命中后先读 profile.json 和 ``,按 tier/capabilities 加载,不通过目录猜能力。禁止在根入口硬编码新增 profile 的文件清单。
  • Tier 1:读 semantic/token-map.jsonsemantic/unmapped-tokens.jsontokens.css;组件和布局使用 universal,未映射语义必须阻断确认。
  • Tier 2:在 Tier 1 基础上读取 routing/component-routing.md 和当前平台 registry;Profile 组件路由是权威来源。
  • Tier 3:再读取 ``、深组件规格、templates 和 runtime;Ant Design、Arco Design 属于 Tier 3。
  • 请求的平台必须存在于 profile.platforms。只有 Profile 声明对应 capability 时,才要求 component registry、templates 或 runtime。
  • Ant Design 旧路径 design-system/standards/ant-design 仅作兼容入口;新增规范只进入 design-system/profiles//

When the user supplies W3C Design Tokens or Style Dictionary JSON, create a Tier 1 profile with:

node scripts/create-profile.mjs --profile  --name "" \
  --tokens  --register

Review semantic/unmapped-tokens.json before generation. Do not promote a partial profile to stable or infer unresolved semantic roles without user input.

Layer 3 — Brand (load when user specifies a brand):

  • Read design-system/brand/index.md, then check design-system/brand// for matching brand tokens and override standard defaults.

5. Run the pipeline. Follow system-prompt.md through L1 → Scene Engine → design-system load → binding gate → L2 → L3 → L4 → output.

6. Verify and deliver. Run agents/run-pipeline.mjs --strict-measure with Node >= 22. A P0/P1 measurement, including icon provenance/rendering/alignment failure, blocks acceptance. Per your harness reference: serve over HTTP, inspect the measured screenshot, fix errors, rerun, then send file + URL.

Output location

All files go to designs//:

designs//
├── preview.html
├── annotated.html
├── tokens.css
├── spec.json
├── assumptions.log
├── preview.measure-report.json
├── preview.measured.png
└── acceptance.spec.mjs

Invocation examples

设计一个商品详情页,移动端,有加购栏和图文详情
从这张截图还原规格,输出给 AI coding 工具用
用 Example Brand 设计系统,设计一个入职申请表单页面
用 Ant Design,设计一个移动端 H5 商品列表页,支持筛选和排序
用 Ant Design,设计一个 PC 后台数据报表页面,含图表和数据表格

相关技能

当用户给出一个产品或界面设计想法时,自动按标准模版范式将其优化为结构清晰、细节完备的设计描述。适用于小程序、App、网页、H5 等任何界面类产品设计任务。

1 次安装

A design-language assistant for Ant Design (antd). Use when the user wants to learn, apply, critique, or theme UIs according to Ant Design's design language — its four design values

1 次安装

把一句模糊需求变成一份成型的 HTML 视觉交付物(演示文稿、原型或动效),一次对话内完成。

19 次安装

设计走查:将生成的 HTML/CSS 页面对照设计规范文档逐项审查,输出结构化合规报告。 当用户说"设计走查"、"走查页面"、"检查是否符合设计规范"、"审查设计合规"时触发。 生成任何 HTML/CSS 页面后也可主动触发,确保输出符合设计规范。 用户可指定任意设计规范文档路径,skill 会自动读取并逐项对照检查。

1 次安装

网站设计风格分析器,从网站URL、HTML文件或截图提取设计规范,生成符合 Google design.md 规范的 DESIGN.md 文档。当用户要求"分析设计风格"、"提取设计规范"、"生成设计文档"、"从XX网站提取风格"、"分析这个页面的设计"等任务时触发此skill。也支持用户直接提供URL、HTML文件路径或截图文件作为输入。

17 次安装

High-fidelity HTML design and prototype skill for landing pages, slide decks, mobile mockups, interactive prototypes, dashboard explorations, design-directio...

18 次安装