gpui-kit-design-guides
它能做什么
为使用 GPUI Kit 框架构建桌面应用提供设计指南。它适用于制作界面、希望在布局、颜色和交互上保持一致的开发者。
适用场景
- ✓当你即将在 GPUI Kit 应用中设计或修改页面的时候。
- ✓当你需要审查桌面界面的设计质量的时候。
- ✓当你想知道设计规则对信息密度或浮层有何规定的时候。
技能链接
https://github.com/longbridge/gpui-kit/blob/main/skills/gpui-kit-design-guides/SKILL.md复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。
使用方法
最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。
可直接粘贴的消息
适用于 Claude Code、Codex 或 Cursor:在项目文件夹中运行,即可安装该技能。
下载 SKILL.md,放进智能体的技能文件夹。
可以这样问 AI
“请按照设计规则,为我的 GPUI Kit 应用设计一个设置页面。”
每周 5 个新技能,1 分钟读完。
工作原理
该技能要求智能体在进行任何界面工作之前先阅读完整的设计指南,而不是依赖记忆或现有页面。该指南涵盖设计主旨、任务层级、视觉语言、颜色、信息密度、状态和浮层。
技术内容(原始 SKILL.md)
作者在 GitHub 上的英文原文。
GPUI Kit Design Guides
The guide is references/design-guides.md. It is a requirement, not inspiration. Read the guide file itself before doing UI work. Do not answer from this page, from an existing screen in the codebase, or from training data.
If the file is missing, fetch https://gpui-kit.com/docs/design-guides.md.
The guide is a verbatim copy of that page, so its link to ./coding-guides.md
means the Coding Guides in the gpui-kit skill (or https://gpui-kit.com/docs/coding-guides.md).
How to read it
Read the whole guide for a new screen or a redesign. For a narrow change, read
"Design thesis" and "Start from the task" first, then the section for the
change. Sections, in order (grep -n '^## ' references/design-guides.md):
| Section | Read when |
|---|---|
| Design thesis | Always |
| Learning from Shadcn | Choosing what to borrow from web component libraries |
| Start from the task | Always; task hierarchy, interaction promise, what to leave out |
| Visual language | Color, typography, spacing, radius, borders, elevation, density, icons |
| Layout patterns | Window structure, sidebars, toolbars, panels, forms, resizable regions |
| Components and composition | Picking a component, composing parts, when to build a new one |
| Interaction states | Hover, focus, pressed, selected, disabled, loading, validation, danger |
| Feedback and overlays | Dialog, sheet, popover, menu, notification, tooltip, dismissal, focus |
| Motion | Any animation or transition |
| Designing data-heavy interfaces | Tables, lists, trees, dashboards, dense inspectors |
| Interface language | Any user-facing text: labels, buttons, titles, errors, empty states |
| Internationalization and platform fit | Multi-locale copy, Chinese terminology, macOS/Windows conventions |
| Guidance for AI-generated interfaces | Always when an agent produces UI |
| Accessibility checklist | Before finishing |
| Design review checklist | Before finishing; run every item against the work |
Non-negotiables
A floor, not a substitute for the guide.
- Desktop before web convention. Keyboard access, window chrome, menus, dense data views, resizable regions, persistent navigation.
ButtonvsLink.Buttonfor every in-app command,ghostoroutlinewhen it should read quietly.Linkonly for external URLs and email addresses.- Tokens before values. No raw hex or
rgb(...); usecx.theme()semantic tokens and rem-based helpers. Any spacing number quoted in the guide is the current default scale, not a literal to repeat. - State must be visible. Hover, focus, selection, disabled, loading, validation, and destructive states each need distinct, consistent treatment.
- Overlays. Escape dismisses the topmost surface and returns focus to its trigger.
- Copy. Name the object and the verb:
Delete "Roadmap"?with aDeletebutton, notAre you sure?withOK.
Finish by running the Design review checklist against the work.
常见问题
智能体可以跳过指南吗?
不可以。该技能要求先阅读指南。
如果指南文件缺失怎么办?
该技能会指示从项目的文档站点获取一份新的副本。
它涵盖组件的选择吗?
涵盖。它说明哪些组件适合某项任务,以及交互状态应如何呈现。
详情
作者的原始描述
The normative Design Guides for GPUI Kit desktop applications. Read in full before designing or changing any screen, layout, spacing, visual hierarchy, color, density, component choice, interaction state, overlay, motion, data-heavy view, or interface copy in a GPUI Kit (gpui-kit / gpui-component) application, and before reviewing UI work for design quality. Also use when asked what the design rules are, or whether a UI decision follows them.
repo: longbridge/gpui-kit
热度
- GitHub 星标
- 19k
- 排名
- #10483
- 许可证
- —
- 更新时间
- 2026/11/2
评论
- …