styles
Guide for brand discovery, theme generation, and style validation for Slidev presentations. Use when extracting brand tokens from websites, creating Slidev…
от vinnie357★ 30 звёзд на GitHub
Установить styles в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Об этом скилле
Slidev Styles
Brand discovery, theme generation, and style validation for Slidev presentations.
Brand Discovery Pipeline Overview
The full brand discovery workflow has four stages:
- Navigate to the brand site using Playwright MCP tools
- Extract CSS variables and computed styles via
browser_evaluate - Parse extracted values into a brand config JSON object
- Generate the Slidev theme from the brand config
For step-by-step Playwright extraction details, see references/discovery-pipeline.md.
For theme generation details, see references/theme-generation.md.
For validation details, see references/validation-checklist.md.
Playwright MCP Tools
Use these tools during brand extraction:
| Tool | Purpose |
|---|---|
browser_navigate |
Open the brand site URL |
browser_evaluate |
Run JavaScript to extract CSS vars and computed styles |
browser_take_screenshot |
Capture rendered slides or pages for visual validation |
browser_snapshot |
Get accessibility tree snapshot for structural inspection |
browser_close |
Close the browser session when extraction is complete |
Always call browser_close after extraction to release resources.
Brand Config JSON Schema
Produce a brand config JSON object after extraction. All fields are optional; populate what is available.
{
"colors": {
"primary": "#hex",
"secondary": "#hex",
"accent": "#hex",
"background": "#hex",
"text": "#hex",
"error": "#hex",
"success": "#hex"
},
"fonts": {
"heading": "Font Name",
"body": "Font Name",
"code": "Monospace Font"
},
"spacing": {
"slide-padding": "value",
"section-gap": "value"
},
"logo": {
"url": "path/to/logo",
"position": "top-left|top-right"
}
}
Save the brand config as brand-config.json in the project root before proceeding to theme generation.
Theme Generation Overview
Convert the brand config to a Slidev theme by:
- Creating
styles/index.csswith CSS custom properties mapped from brand config colors and spacing - Configuring UnoCSS theme extensions in
uno.config.ts(orvite.config.ts) with brand colors and font stacks - Adding UnoCSS shortcut classes for common slide patterns (headings, callouts, code blocks)
- Loading fonts via Google Fonts import in
styles/index.cssor placing font files inpublic/fonts/ - Creating a global
components/Logo.vuecomponent for logo placement
For complete theme generation with code examples, see references/theme-generation.md.
Validation Overview
After applying a theme, validate compliance by:
- Taking screenshots of rendered slides with
browser_take_screenshot - Running contrast ratio checks using the WCAG AA formula via
browser_evaluate - Verifying rendered font families match the brand spec
- Checking all colors against the brand palette within a tolerance of ±5 hex units per channel
- Confirming logo placement and sizing
WCAG 2.2 AA requirements (per design:accessibility) — these contrast success criteria (1.4.3, 1.4.11) are unchanged from 2.1:
- Normal text (< 18pt): minimum contrast ratio 4.5:1
- Large text (≥ 18pt or ≥ 14pt bold): minimum contrast ratio 3:1
- UI components and graphical objects: minimum contrast ratio 3:1
For the full validation workflow and automated checks, see references/validation-checklist.md.
Manual Brand Input
When no website is available, gather brand information using this questionnaire:
Brand Color Questionnaire
--------------------------
1. Primary brand color (main CTA, headings): ___
2. Secondary brand color (accents, highlights): ___
3. Background color (slides): ___
4. Body text color: ___
5. Accent/success color (callouts): ___
6. Error/warning color: ___
Font Questionnaire
------------------
7. Heading font (name and weight): ___
8. Body text font: ___
9. Code/monospace font: ___
10. Are fonts hosted on Google Fonts, or do you have local files?
Spacing Questionnaire
---------------------
11. Slide padding (distance from edge to content): ___
12. Gap between major sections: ___
Logo Questionnaire
------------------
13. Logo file URL or local path: ___
14. Logo placement: top-left / top-right / none
Populate the brand config JSON from questionnaire answers, then proceed to theme generation.
Integration with design:accessibility
Load design:accessibility when:
- Validating contrast ratios for slide text and UI components
- Reviewing color combinations for color-blindness considerations
- Checking that information is not conveyed by color alone
Key WCAG requirements that apply to slide presentations:
- Text on slide backgrounds must meet 4.5:1 contrast ratio (AA)
- Heading text at large sizes must meet 3:1 contrast ratio
- Charts and diagrams must have text labels or patterns, not only color
- Slide transitions and animations must not flash more than 3 times per second
Slidev Theme File Structure
A self-contained brand th
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
Вложенные файлы
- references/discovery-pipeline.md
- references/theme-generation.md
- references/validation-checklist.md
FAQ
Что делает скилл styles?
Guide for brand discovery, theme generation, and style validation for Slidev presentations. Use when extracting brand tokens from websites, creating Slidev themes from brand guidelines, validating slide compliance with brand standards, or configuring colors, fonts, and spacing.
Как установить скилл styles?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл styles запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
frontend-design
AnthropicGuidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making…
webapp-testing
AnthropicToolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing…
brand-guidelines
AnthropicApplies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand…
web-artifacts-builder
AnthropicSuite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use…