Overview
The Style Library is the centralized system that stores all your design tokens. It ensures visual consistency and lets you update the design of all emails by changing tokens once. Think of it like a brand kit built specifically for email.Core Principle
Centralization
All styles are defined once in the Style Library.
Reference, don't duplicate
Emails and components reference these tokens instead of using manual color codes.
Automatic propagation
Change a token, and all elements using it update automatically.
Enforced consistency
You can only use styles defined in the library → guarantees brand consistency.
Token Types
Colors
Colors are reusable tokens you define once (e.g., “Primary”, “Background”).Structure
- Name: Human-readable name (e.g., “Primary Orange”)
- Value: Color code (e.g., “#F97316”)
- Usage: Where it can be used (button, text, background)
Usage
Used in color pickers for elements.
Text Styles
Text styles define your typography (size, weight, font family).Structure
- Name: e.g., “Heading 1”, “Body Text”
- Font Size: e.g., “32px”
- Font Weight: Bold, normal, etc.
- Font Family: Your chosen font
- Line Height: Spacing between lines
Usage
Applied to Text and Button elements.
Button Styles
Button styles define complete button appearance.Structure
- Name: e.g., “Primary CTA”
- Background Color: Reference to a color token
- Text Style: Reference to a text style
- Padding: Inner spacing
- Border Radius: Rounded corners
Usage
Applied to Button elements.
Link Styles
Link styles define how links look within text.Structure
- Name: e.g., “Standard Link”
- Color: Link color
- Decoration: Underline or none
- Font Weight: Bold or normal
Usage
Applied to links within Text elements.
Managing the Style Library
Adding Tokens
Modifying Tokens
When you modify an existing token:This is the main advantage of the Style Library: one central change propagates everywhere instantly.
Deleting Tokens
If a token is in use, you’ll need to replace it in elements that use it before deleting.Importing Styles
You can import styles from an existing email:Best Practices
Consistent naming
Consistent naming
Use clear names (e.g., “Primary”, “Secondary”, “Heading 1”, “Body”).
Reuse existing tokens
Reuse existing tokens
Reuse tokens rather than creating duplicates.
Test after changes
Test after changes
After modifying a token, check a few emails using that token to ensure the result looks correct.
Benefits
🎨 Consistency
No off-brand colors or fonts.
⚡ Maintenance
One central change updates all emails.
🚀 Productivity
Select pre-defined styles instead of manually entering values.
🔄 Rebranding
Change your entire brand look by modifying a few tokens.
