21st-ui-build — скилл для Claude Code: сборка UI по контексту проекта
Скилл для реализации страниц и компонентов в существующем веб-проекте: сначала читает дизайн-контекст и токены, потом ищет готовое в 21st.
npx skills add 21st-dev/skill --skill 21st-ui-build -a claude-codeЧто делает 21st-ui-build
Скилл включается, когда нужно собрать страницу, секцию или компонент, сделать адаптивный редизайн либо визуальную полировку в уже существующем веб-проекте. Первым делом он читает .21st/design.json и .21st/DESIGN.md. Если этих файлов нет, агент запускает 21st init --design-context.
Дальше он смотрит целевой маршрут, ближайшие компоненты, инструкции проекта и существующие токены. Явные факты проекта для него важнее общих вкусовых предпочтений. Поиск идёт до генерации: 21st search "<specific UI need>" --context auto. Сначала переиспользуются уже установленные примитивы проекта, и только если результат из 21st убирает дублирование или заметно улучшает итог, компонент достают или ставят.
Генерация вариантов доступна не всем. Перед вызовом 21st generate "<goal and constraints>" --context auto --variants 3 скилл проверяет MCP get_usage.aiGenerationEnabled или строку 21st AI generation в выводе 21st usage; в CLI 1.17.1+ есть 21st usage --json. Если AI не включён, варианты пишет ваш собственный агент на основе 21st search и 21st get. Хостинговые generate и iterate_generation без доступа к AI вызывать нельзя. В конце — проверки проекта и 21st review <changed paths>, автоматически применяются только безопасные детерминированные правки.
Какие задачи решает
- собрать страницу в реальном фреймворке проекта, а не вставленным HTML-наброском
- переиспользовать существующие компоненты вместо параллельных похожих
- удержать токены, плотность и типографику при доработке интерфейса
- проверить изменённые пути через
21st reviewперед коммитом - сохранить адаптивность, фокус и состояния загрузки при редизайне
Примеры запросов агенту
- собери эту страницу по дизайн-контексту проекта и покажи, что переиспользовал
- сделай этот экран production-ready, не ломая существующие токены
- найди в 21st подходящий компонент для этой секции и встрой его в наш React-проект
Как установить 21st-ui-build
1Через Skills CLI (Vercel)
npx skills add 21st-dev/skill --skill 21st-ui-build -a claude-code2Вручную: положить файлы
~/.claude/skills/21st-ui-build/SKILL.mdПапка скилла целиком; для одного проекта — .claude/skills/21st-ui-build/
1Через Skills CLI (Vercel)
npx skills add 21st-dev/skill --skill 21st-ui-build -a codex2Вручную: положить файлы
.agents/skills/21st-ui-build/SKILL.mdДля всех проектов — ~/.agents/skills/
1Через Skills CLI (Vercel)
npx skills add 21st-dev/skill --skill 21st-ui-build -a cursor2Вручную: положить файлы
.cursor/skills/21st-ui-build/SKILL.mdCursor читает и .agents/skills/, и .claude/skills/
1GitHub CLI
gh skill install 21st-dev/skill 21st-ui-build2Вручную: положить файлы
.github/skills/21st-ui-build/SKILL.md1Через Skills CLI (Vercel)
npx skills add 21st-dev/skill --skill 21st-ui-build -a gemini-cli2Командой платформы
gemini skills install https://github.com/21st-dev/skill --path skills/21st-ui-buildВручную: положить файлы
.devin/skills/21st-ui-build/SKILL.mdСтарый путь .windsurf/skills/ тоже читается
Через Skills CLI (Vercel)
npx skills add 21st-dev/skill --skill 21st-ui-build -a opencodeClaude.ai
Упакуйте папку в zip и загрузите в Settings → Capabilities → Skills
По шагам, с командами для каждой платформы: Как установить скилл в Claude Code: пять способов
Из того же набора6
Похожие
Рядом в теме «Фронтенд и UI»
Всё по теме «Фронтенд и UI» →Вопросы о 21st-ui-build
Как установить 21st-ui-build в Claude?
Выполните npx skills add 21st-dev/skill --skill 21st-ui-build -a claude-code. Скилл окажется в ~/.claude/skills/21st-ui-build/SKILL.md.
Что делает 21st-ui-build?
Реализует или заметно меняет UI в существующем веб-проекте: читает дизайн-контекст, ищет в 21st, переиспользует компоненты проекта и прогоняет проверки.
Чем 21st-ui-build отличается от 21st-ui-explore и 21st-ui-review?
Этот скилл пишет код. 21st-ui-explore берут, когда визуальное направление ещё не выбрано, а 21st-ui-review — когда нужна только критика без правок.
Исходный текст
SKILL.md · Apache-2.0
--- name: 21st-ui-build description: Build or substantially change production UI using the current project's design context, existing components, and grounded 21st inspiration. Use when implementing a page, section, component, responsive redesign, or visual polish in an existing web project. Trigger for requests such as "build this UI", "implement this screen", "make this page production-ready", or "use 21st to create the interface". Use 21st-ui-explore first when the visual direction is intentionally undecided, and 21st-ui-review for critique-only work. --- # Build project-aware UI Preserve the product's identity while using 21st supply to accelerate implementation. ## Workflow 1. Read `.21st/design.json` and `.21st/DESIGN.md`. If neither exists, run `21st init --design-context`. 2. Inspect the target route, its closest components, project instructions, and existing tokens. Treat explicit project facts as stronger than generic taste. 3. Search before generating: ```bash 21st search "<specific UI need>" --context auto ``` 4. Reuse installed project primitives first. Retrieve or install a 21st result only when it reduces duplication or materially improves the result. 5. If no result fits, check MCP `get_usage.aiGenerationEnabled` or run `21st usage` and read the `21st AI generation` line. CLI 1.17.1+ also supports `21st usage --json`. Only when AI is explicitly enabled, generate project-aware alternatives using available AI credits: ```bash 21st generate "<goal and constraints>" --context auto --variants 3 ``` Otherwise, implement alternatives with your own coding agent, grounded in `21st search` and `21st get` (MCP: `search` and `get_component`). Do not call or suggest hosted `generate` or `iterate_generation` without AI access. 6. Implement the selected direction in the project's real framework. Do not paste sketch HTML when the project expects React components, tokens, or established APIs. 7. Preserve responsive behavior, keyboard interaction, visible focus, semantics, reduced motion, loading states, empty states, and error states. 8. Run the project's checks and `21st review <changed paths>`. Apply only safe, deterministic fixes automatically. ## Design rules - Prefer project tokens over new arbitrary values. - Prefer existing components over parallel lookalikes. - Preserve established density, radii, typography, iconography, and layout rhythm unless the user explicitly requests a redesign. - Use real product copy and states when available. - Avoid decorative gradients, excessive cards, glass effects, huge headlines, and animation unless supported by the project or requested. - Never claim a component, token, or capability exists without inspecting it. ## Handoff Report the direction used, reused 21st/project components, files changed, and verification performed. Record a durable visual choice in `.21st/design.json` under `decisions` when the user selects a new direction.
© 21st-dev · Apache-2.0 · 21st-dev/skill