UI design style file format specification with reference image support. Defines the schema for .claude/design-style.md and .claude/design-references/. Use when creating, validating, or parsing...
The UI Style system provides a standardized way to define project design preferences
that the ui agent uses during design reviews. It supports both text-based style
definitions and visual reference images.
{project}/
.claude/
design-style.md # Main style configuration
design-references/ # Visual reference images
{image}.png # PNG or JPG screenshots
MANIFEST.md # Optional metadata
| Section | Purpose |
|---|---|
| Header | Version, dates, base reference |
| Reference Images | Links to visual references (v2.0+) |
| Brand Colors | Color palette with light/dark modes |
| Typography | Fonts and type scale |
| Spacing | Base unit and scale |
| Component Patterns | Button, input, card styles |
| Design Rules | DO and DON'T guidelines |
| Section | Purpose |
|---|---|
| Reference URLs | External style guides |
| Style History | Change log |
| MANIFEST.md | Detailed image descriptions |
All reference images MUST be stored in .claude/design-references/.
| Format | Extension | Recommended Use |
|---|---|---|
| PNG | .png | Screenshots, UI components |
| JPEG | .jpg, .jpeg | Photos, complex imagery |
| WebP | .webp | Modern alternative to PNG/JPEG |
In the style file, reference images are listed in a table:
## Reference Images
| Image | Description | Captured | Mode |
|-------|-------------|----------|------|
| hero-section.png | Homepage hero | 2026-01-08 | light |
Each image should have usage notes:
### Usage Guidelines
- **hero-section.png**: Reference for hero layout, gradient, CTA placement
.claude/design-style.md with Read tool## headersImage Name -> .claude/design-references/{image_name}
Example:
hero-section.png -> .claude/design-references/hero-section.png
Before using a style file, validate:
.claude/design-style.md.claude/design-references/When the ui agent performs a review:
.claude/design-style.md.claude/design-references/Compare this implementation screenshot against the project design reference.
**Reference Image**: .claude/design-references/hero-section.png
**Implementation**: screenshots/current-hero.png
**Style Tokens** (from .claude/design-style.md):
- Primary Color: #2563EB
- Font: Inter 16px
- Spacing: 4px base
**Validate**:
1. Layout matches reference
2. Colors match defined palette
3. Typography follows scale
4. Spacing uses defined tokens
| Version | Features |
|---|---|
| 1.x | Text-only style (legacy) |
| 2.x | Reference images + text style |
Version 2.x is backward compatible - the ui agent handles missing
## Reference Images section gracefully.
Be specific about what each image demonstrates:
Good: "Reference for button padding (12px), border-radius (8px), and hover state" Bad: "Button reference"
When UI changes: