Style Guide Generator
Overview
Generate professionally formatted website style guides and design systems by analyzing provided URLs, screenshots, uploaded files, and user requirements. Output comprehensive PDF documents that serve as the single source of truth for design and development teams.
Workflow Decision Tree
When a user requests a style guide, follow this decision tree:
Gather Information
- If user provides URL → Use web_fetch to analyze the website
- If user provides screenshots/images → Analyze visual elements
- If user provides existing documentation → Extract and structure information
- If user provides minimal information → Ask clarifying questions about brand, goals, and requirements
Extract Design Elements
- Colors (primary, secondary, accent, text, background, success, warning, error)
- Typography (fonts, weights, sizes, line heights)
- Logo usage guidelines
- Iconography style
- Imagery preferences
- UI component patterns
- Layout and spacing systems
- Accessibility requirements
Structure Content
- Follow the standard template structure (see Template Structure section)
- Organize extracted information into appropriate sections
- Add mission/vision if provided or inferred
- Document design principles
- Create component specifications
Generate PDF
- Use the PDF skill to create a professional document
- Apply consistent formatting and typography
- Include tables for color palettes, typography specs, and component states
- Ensure accessibility with proper contrast ratios
- Add version number and last updated date
Standard Template Structure
Every style guide should follow this professional structure (based on industry best practices):
1.0 Introduction
- Version number and last updated date
- Purpose and scope statement
- Target audience (design and development teams)
1.1 Mission & Vision
- Company mission statement
- Company vision statement
- Strategic positioning
1.2 Design Principles
- 4-6 core principles that guide design decisions
- Each principle with name and description
- Examples: "Clarity Above All", "Empowerment Through Simplicity", "Consistency Builds Trust", "Human-Centered"
2.0 Brand Identity
2.1 Logo Usage
- Primary logo specifications
- Clear space requirements
- Incorrect usage examples
- Minimum size requirements
- Color variations (full color, black, white)
2.2 Color Palette
- Organized table with Role, Color Name, HEX, and RGB values
- Primary colors (1-2)
- Secondary colors (1-3)
- Accent colors
- Text colors
- Background colors
- System colors (Success, Warning, Error)
- Accessibility notes for each color combination
2.3 Typography
- Heading font specifications (H1, H2, H3)
- Body text specifications
- Caption/small text specifications
- Font families, weights, sizes, and line heights in tabular format
- Web font loading considerations
- Fallback fonts
2.4 Iconography
- Icon style guidelines (outlined, filled, line weight)
- Grid system specifications
- Size variants
- Usage examples
- Link to icon library
2.5 Imagery
- Photography style guidelines
- Illustration style guidelines
- Image treatment specifications
- Do's and don'ts
- Quality requirements
3.0 Content Style Guide
3.1 Voice and Tone
- Voice characteristics (consistent attributes)
- Tone variations (how voice adapts to context)
- Examples for different scenarios
3.2 Grammar and Mechanics
- Punctuation rules
- Capitalization standards
- Voice preference (active/passive)
- Number formatting
- Date and time formatting
4.0 UI Components
4.1 Buttons
- State variants (Primary, Secondary, Tertiary, Disabled)
- Size variants
- Usage guidelines
- Code snippets (HTML/CSS)
- Accessibility requirements
4.2 Forms
- Input field specifications
- Label positioning
- Validation states
- Required field indicators
- Error message styling
- Help text formatting
4.3 [Additional Components as needed]
- Cards
- Modals
- Navigation
- Tables
- Alerts/Notifications
- Tooltips
- Badges
- Progress indicators
5.0 Layout & Grid
- Grid system specifications (columns, gutters)
- Responsive breakpoints
- Spacing scale (base unit and multipliers)
- Container widths
- Margin and padding conventions
6.0 Accessibility (A11y)
- WCAG compliance level (2.1 AA standard)
- Color contrast requirements
- Alt text guidelines
- Keyboard navigation standards
- Screen reader considerations
- Focus indicators
7.0 Resources
- Links to design files (Figma, Sketch, Adobe XD)
- Icon library location
- Illustration library location
- Font files repository
- Code repository
- Additional documentation
8.0 Changelog
- Version history with dates
- Changes summary for each version
Information Extraction Process
When analyzing provided materials, extract the following systematically:
From URLs/Websites:
- Fetch the website using web_fetch
- Analyze HTML/CSS for:
- Color values (background-color, color properties)
- Font families and typography (font-family, font-size, font-weight)
- Spacing patterns (margin, padding values)
- Component structures
- Take note of:
- Visual hierarchy
- Button styles and states
- Form element treatments
- Navigation patterns
- Responsive behavior (if observable)
From Screenshots/Images:
- Identify color palette using visual analysis
- Determine typography hierarchy
- Note spacing and layout patterns
- Identify UI component variants
- Observe design principles in practice
From Existing Documentation:
- Extract mission/vision statements
- Gather existing brand guidelines
- Collect color specifications
- Document current typography standards
- Note any existing component libraries
Creating Professional Tables
Use well-formatted tables for specifications. Example formats:
Color Palette Table:
| Role | Color | HEX | RGB |
|------------|-------------|---------|---------------|
| Primary | Brand Blue | #378DFF | 55, 141, 255 |
| Secondary | Light Blue | #A5CAFF | 165, 202, 255 |
Typography Table:
| Element | Font Family | Weight | Size (px) | Line Height |
|---------|-------------|---------|-----------|-------------|
| H1 | Inter | Bold | 48 | 1.2 |
| H2 | Inter | Bold | 36 | 1.3 |
| Body | Inter | Regular | 16 | 1.5 |
Button States Table:
| State | Appearance | Usage |
|-----------|-------------------------|--------------------------------|
| Primary | Solid fill, primary | Main call to action on a page |
| Secondary | Outline, primary color | Secondary actions |
| Tertiary | Text only | Less important actions |
PDF Generation Best Practices
Professional Formatting:
- Use consistent heading hierarchy
- Apply proper spacing between sections
- Utilize tables for structured data
- Include visual examples where possible
Typography:
- Use professional fonts (Inter, Roboto, or system fonts)
- Maintain consistent sizing hierarchy
- Ensure sufficient line height for readability
Color Usage:
- Show color swatches with hex codes
- Ensure sufficient contrast for accessibility
- Document color roles clearly
Organization:
- Number sections clearly (1.0, 1.1, 2.0, etc.)
- Include table of contents for longer guides
- Use page breaks appropriately
- Add page numbers
Accessibility:
- Ensure document is screen-reader friendly
- Use proper heading structure
- Include alt text for images
- Maintain minimum font size of 12pt
Handling Incomplete Information
When information is missing or unclear:
Make Reasonable Inferences:
- Extract colors from provided screenshots
- Infer typography from website analysis
- Estimate spacing based on visual patterns
Use Placeholders:
- "[Insert company mission statement]" for unknown content
- "[Link to design files]" for unavailable resources
- "Version 1.0" and current date as defaults
Ask Clarifying Questions:
- "What is your company's mission statement?"
- "Do you have existing brand colors or should I extract them from the website?"
- "Are there specific accessibility requirements beyond WCAG 2.1 AA?"
Provide Templates:
- Include example text for sections that need user input
- Show format for content they should provide
- Give guidance on what information would be ideal
Example User Interactions
Example 1: URL-Based Request
User: "Create a style guide for my website at example.com"
Process:
- Fetch website with web_fetch
- Analyze HTML/CSS for design system
- Extract colors, fonts, spacing
- Structure into standard template
- Generate professional PDF
- Provide download link
Example 2: Screenshot-Based Request
User: "Here are screenshots of my app. Create a style guide." [uploads images]
Process:
- Analyze images for visual elements
- Extract color palette
- Identify typography patterns
- Document component styles
- Fill in template structure
- Generate PDF with findings
- Provide download link
Example 3: Comprehensive Request
User: "Create a style guide using my website URL, these brand colors [list], and our mission statement [text]"
Process:
- Combine all provided information
- Fetch and analyze website
- Integrate provided brand elements
- Structure complete style guide
- Generate professional PDF
- Provide download link
Quality Checklist
Before delivering the style guide PDF, verify:
Resources
This skill uses the following bundled resources:
assets/template.pdf
The base template PDF that demonstrates the professional structure and formatting that all generated style guides should follow. This file serves as a reference for structure, section organization, and formatting standards.
scripts/analyze_website.py
Python script to extract design system information from websites, including colors, typography, and component patterns. Can be used to automatically gather design specifications from live URLs.
references/design_system_examples.md
Reference document containing examples of well-structured design systems and style guides from leading companies. Use this for inspiration on content organization and presentation standards.
1---2name: style-guide-generator3description: Generate comprehensive website style guides and design systems from URLs, screenshots, and existing documentation. Use this skill when users ask to create a style guide, design system documentation, brand guidelines document, or design specification from a website, app, or existing materials. This skill produces professional PDF outputs following industry-standard style guide structure.4---5
6# Style Guide Generator
7
8## Overview
9
10Generate professionally formatted website style guides and design systems by analyzing provided URLs, screenshots, uploaded files, and user requirements. Output comprehensive PDF documents that serve as the single source of truth for design and development teams.
11
12## Workflow Decision Tree
13
14When a user requests a style guide, follow this decision tree:
15
161. **Gather Information**
17 - If user provides URL → Use web_fetch to analyze the website
18 - If user provides screenshots/images → Analyze visual elements
19 - If user provides existing documentation → Extract and structure information
20 - If user provides minimal information → Ask clarifying questions about brand, goals, and requirements
21
222. **Extract Design Elements**
23 - Colors (primary, secondary, accent, text, background, success, warning, error)
24 - Typography (fonts, weights, sizes, line heights)
25 - Logo usage guidelines
26 - Iconography style
27 - Imagery preferences
28 - UI component patterns
29 - Layout and spacing systems
30 - Accessibility requirements
31
323. **Structure Content**
33 - Follow the standard template structure (see Template Structure section)
34 - Organize extracted information into appropriate sections
35 - Add mission/vision if provided or inferred
36 - Document design principles
37 - Create component specifications
38
394. **Generate PDF**
40 - Use the PDF skill to create a professional document
41 - Apply consistent formatting and typography
42 - Include tables for color palettes, typography specs, and component states
43 - Ensure accessibility with proper contrast ratios
44 - Add version number and last updated date
45
46## Standard Template Structure
47
48Every style guide should follow this professional structure (based on industry best practices):
49
50### 1.0 Introduction
51- Version number and last updated date
52- Purpose and scope statement
53- Target audience (design and development teams)
54
55### 1.1 Mission & Vision
56- Company mission statement
57- Company vision statement
58- Strategic positioning
59
60### 1.2 Design Principles
61- 4-6 core principles that guide design decisions
62- Each principle with name and description
63- Examples: "Clarity Above All", "Empowerment Through Simplicity", "Consistency Builds Trust", "Human-Centered"
64
65### 2.0 Brand Identity
66
67#### 2.1 Logo Usage
68- Primary logo specifications
69- Clear space requirements
70- Incorrect usage examples
71- Minimum size requirements
72- Color variations (full color, black, white)
73
74#### 2.2 Color Palette
75- Organized table with Role, Color Name, HEX, and RGB values
76- Primary colors (1-2)
77- Secondary colors (1-3)
78- Accent colors
79- Text colors
80- Background colors
81- System colors (Success, Warning, Error)
82- Accessibility notes for each color combination
83
84#### 2.3 Typography
85- Heading font specifications (H1, H2, H3)
86- Body text specifications
87- Caption/small text specifications
88- Font families, weights, sizes, and line heights in tabular format
89- Web font loading considerations
90- Fallback fonts
91
92#### 2.4 Iconography
93- Icon style guidelines (outlined, filled, line weight)
94- Grid system specifications
95- Size variants
96- Usage examples
97- Link to icon library
98
99#### 2.5 Imagery
100- Photography style guidelines
101- Illustration style guidelines
102- Image treatment specifications
103- Do's and don'ts
104- Quality requirements
105
106### 3.0 Content Style Guide
107
108#### 3.1 Voice and Tone
109- Voice characteristics (consistent attributes)
110- Tone variations (how voice adapts to context)
111- Examples for different scenarios
112
113#### 3.2 Grammar and Mechanics
114- Punctuation rules
115- Capitalization standards
116- Voice preference (active/passive)
117- Number formatting
118- Date and time formatting
119
120### 4.0 UI Components
121
122#### 4.1 Buttons
123- State variants (Primary, Secondary, Tertiary, Disabled)
124- Size variants
125- Usage guidelines
126- Code snippets (HTML/CSS)
127- Accessibility requirements
128
129#### 4.2 Forms
130- Input field specifications
131- Label positioning
132- Validation states
133- Required field indicators
134- Error message styling
135- Help text formatting
136
137#### 4.3 [Additional Components as needed]
138- Cards
139- Modals
140- Navigation
141- Tables
142- Alerts/Notifications
143- Tooltips
144- Badges
145- Progress indicators
146
147### 5.0 Layout & Grid
148- Grid system specifications (columns, gutters)
149- Responsive breakpoints
150- Spacing scale (base unit and multipliers)
151- Container widths
152- Margin and padding conventions
153
154### 6.0 Accessibility (A11y)
155- WCAG compliance level (2.1 AA standard)
156- Color contrast requirements
157- Alt text guidelines
158- Keyboard navigation standards
159- Screen reader considerations
160- Focus indicators
161
162### 7.0 Resources
163- Links to design files (Figma, Sketch, Adobe XD)
164- Icon library location
165- Illustration library location
166- Font files repository
167- Code repository
168- Additional documentation
169
170### 8.0 Changelog
171- Version history with dates
172- Changes summary for each version
173
174## Information Extraction Process
175
176When analyzing provided materials, extract the following systematically:
177
178### From URLs/Websites:
1791. Fetch the website using web_fetch
1802. Analyze HTML/CSS for:
181 - Color values (background-color, color properties)
182 - Font families and typography (font-family, font-size, font-weight)
183 - Spacing patterns (margin, padding values)
184 - Component structures
1853. Take note of:
186 - Visual hierarchy
187 - Button styles and states
188 - Form element treatments
189 - Navigation patterns
190 - Responsive behavior (if observable)
191
192### From Screenshots/Images:
1931. Identify color palette using visual analysis
1942. Determine typography hierarchy
1953. Note spacing and layout patterns
1964. Identify UI component variants
1975. Observe design principles in practice
198
199### From Existing Documentation:
2001. Extract mission/vision statements
2012. Gather existing brand guidelines
2023. Collect color specifications
2034. Document current typography standards
2045. Note any existing component libraries
205
206## Creating Professional Tables
207
208Use well-formatted tables for specifications. Example formats:
209
210**Color Palette Table:**
211```
212| Role | Color | HEX | RGB |
213|------------|-------------|---------|---------------|
214| Primary | Brand Blue | #378DFF | 55, 141, 255 |
215| Secondary | Light Blue | #A5CAFF | 165, 202, 255 |
216```
217
218**Typography Table:**
219```
220| Element | Font Family | Weight | Size (px) | Line Height |
221|---------|-------------|---------|-----------|-------------|
222| H1 | Inter | Bold | 48 | 1.2 |
223| H2 | Inter | Bold | 36 | 1.3 |
224| Body | Inter | Regular | 16 | 1.5 |
225```
226
227**Button States Table:**
228```
229| State | Appearance | Usage |
230|-----------|-------------------------|--------------------------------|
231| Primary | Solid fill, primary | Main call to action on a page |
232| Secondary | Outline, primary color | Secondary actions |
233| Tertiary | Text only | Less important actions |
234```
235
236## PDF Generation Best Practices
237
2381. **Professional Formatting:**
239 - Use consistent heading hierarchy
240 - Apply proper spacing between sections
241 - Utilize tables for structured data
242 - Include visual examples where possible
243
2442. **Typography:**
245 - Use professional fonts (Inter, Roboto, or system fonts)
246 - Maintain consistent sizing hierarchy
247 - Ensure sufficient line height for readability
248
2493. **Color Usage:**
250 - Show color swatches with hex codes
251 - Ensure sufficient contrast for accessibility
252 - Document color roles clearly
253
2544. **Organization:**
255 - Number sections clearly (1.0, 1.1, 2.0, etc.)
256 - Include table of contents for longer guides
257 - Use page breaks appropriately
258 - Add page numbers
259
2605. **Accessibility:**
261 - Ensure document is screen-reader friendly
262 - Use proper heading structure
263 - Include alt text for images
264 - Maintain minimum font size of 12pt
265
266## Handling Incomplete Information
267
268When information is missing or unclear:
269
2701. **Make Reasonable Inferences:**
271 - Extract colors from provided screenshots
272 - Infer typography from website analysis
273 - Estimate spacing based on visual patterns
274
2752. **Use Placeholders:**
276 - "[Insert company mission statement]" for unknown content
277 - "[Link to design files]" for unavailable resources
278 - "Version 1.0" and current date as defaults
279
2803. **Ask Clarifying Questions:**
281 - "What is your company's mission statement?"
282 - "Do you have existing brand colors or should I extract them from the website?"
283 - "Are there specific accessibility requirements beyond WCAG 2.1 AA?"
284
2854. **Provide Templates:**
286 - Include example text for sections that need user input
287 - Show format for content they should provide
288 - Give guidance on what information would be ideal
289
290## Example User Interactions
291
292**Example 1: URL-Based Request**
293User: "Create a style guide for my website at example.com"
294Process:
2951. Fetch website with web_fetch
2962. Analyze HTML/CSS for design system
2973. Extract colors, fonts, spacing
2984. Structure into standard template
2995. Generate professional PDF
3006. Provide download link
301
302**Example 2: Screenshot-Based Request**
303User: "Here are screenshots of my app. Create a style guide." [uploads images]
304Process:
3051. Analyze images for visual elements
3062. Extract color palette
3073. Identify typography patterns
3084. Document component styles
3095. Fill in template structure
3106. Generate PDF with findings
3117. Provide download link
312
313**Example 3: Comprehensive Request**
314User: "Create a style guide using my website URL, these brand colors [list], and our mission statement [text]"
315Process:
3161. Combine all provided information
3172. Fetch and analyze website
3183. Integrate provided brand elements
3194. Structure complete style guide
3205. Generate professional PDF
3216. Provide download link
322
323## Quality Checklist
324
325Before delivering the style guide PDF, verify:
326
327- [ ] All sections are complete or marked as placeholders
328- [ ] Color palette includes HEX and RGB values
329- [ ] Typography specifications are detailed (family, weight, size, line height)
330- [ ] Tables are properly formatted and aligned
331- [ ] Accessibility requirements are documented
332- [ ] Version number and date are included
333- [ ] Resources section links are provided (even if placeholder)
334- [ ] Changelog is started with version 1.0
335- [ ] PDF is professionally formatted
336- [ ] Document is ready for team distribution
337
338## Resources
339
340This skill uses the following bundled resources:
341
342### assets/template.pdf
343The base template PDF that demonstrates the professional structure and formatting that all generated style guides should follow. This file serves as a reference for structure, section organization, and formatting standards.
344
345### scripts/analyze_website.py
346Python script to extract design system information from websites, including colors, typography, and component patterns. Can be used to automatically gather design specifications from live URLs.
347
348### references/design_system_examples.md
349Reference document containing examples of well-structured design systems and style guides from leading companies. Use this for inspiration on content organization and presentation standards.