Full technical details in your project at
/docs/modules/DesignSystem.mdWhat You Get
- ✅ Token system - Colors, spacing, typography, radius (never hardcode values)
- ✅ 5 themes - System, Light, Dark, Aurora, Obsidian
- ✅ Liquid Glass primitive -
SAIGlasswith iOS 26 glass and iOS 17–25 Material fallback (new in v2.0) - ✅ Premium components - Buttons, inputs, cards, bubbles
- ✅ BrandConfig - Single place to customize app identity
- ✅ Accessibility - Dynamic Type, VoiceOver, Reduce Motion
- ✅ Gradients & motion - Premium visual effects
Liquid Glass
v2.0 introducesSAIGlass, a Liquid Glass primitive that uses the iOS 26 Glass material on iOS 26+ and falls back to SwiftUI Material on iOS 17–25. Same call sites, progressive enhancement at runtime.
Location: Packages/DesignSystem/Sources/DesignSystem/Materials/SAIGlass.swift
SAIGlassStyle
The .saiGlass modifier
One-call glass treatment for any view:
SAIGlassContainer
Use when multiple glass surfaces sit near each other so they sample the same background instead of stacking visually:SAITabBarMinimizeStyle
BrandConfig (Customize Your App)
Single file to customize app identity. FromBrandConfig.swift:
- Change
appDisplayName→ Your app name - Update the
AccentPrimarycolor set inResources/Assets.xcassets - Change
avatarFallbackSymbol→ Your SF Symbol - Set the legal URL strings to your live HTTPS pages before shipping
- Entire app updates automatically
The
// generator:brand markers are stable anchors for the App Generator’s identity transforms — a separate product (coming soon). Keep one declaration per line and do not remove the markers. They are inert in the boilerplate itself.Design Tokens (Production System)
DSColors - Theme-Aware
Every color adapts to the active theme:- Text:
textPrimary,textSecondary - Surfaces:
background,surface,surfaceElevated - Accents:
accentPrimary,accentSecondary - Borders:
borderHairline,borderSubtle - Semantic:
success,warning,danger
DSSpacing
Consistent spacing scale:DSTypography
Text styles with Dynamic Type:DSRadius
Corner radius values:UI Components
- Inputs
- Cards & Rows
- Other
Theme System
5 Built-in Themes
System
Follows iOS light/dark mode
Light
Always light appearance
Dark
Always dark appearance
Aurora
Premium light — warm cream with coral/peach accents
Obsidian
Premium dark — deep navy with electric cyan accents
Applying Themes
From Settings, persist and apply a theme in one call (SettingsDTO.Theme):
ThemeManager (in the Core package) owns the live theme and is also reachable directly:
How It Works
Customization Examples
Create Custom Theme
1
Add Color Set
In
Resources/Assets.xcassets, add a color set per token you want to override (e.g. AccentPrimary, Background). Themed values can also be returned in code (see step 3).2
Add Theme Cases
Add
case myTheme to both theme enums — the persisted SettingsDTO.Theme
(Packages/Storage/.../SettingsDTO.swift) and the live ThemeManager.Theme
(Packages/Core/Sources/Core/Theme/ThemeManager.swift). Then add the
.myTheme branch to the mapping in SettingsViewModel.setTheme(_:), and add a
matching case to DSColors.ThemePalette + DSColors.setTheme(_:colorScheme:).3
Map Colors
In
DSColors.swift, branch on activeTheme:4
Surface in the Picker
The settings appearance picker iterates
SettingsDTO.Theme.allCases, so the
new case appears automatically once the cases above are wired up.Create Custom Component
Animations
Standard motion timings live inSAIMotion and respect Reduce Motion:
Accessibility
Built-in support for:- ✅ Dynamic Type - All text scales automatically
- ✅ VoiceOver - All components labeled
- ✅ High Contrast - Semantic colors adapt
- ✅ Reduced Motion - Respects system preference
- ✅ Minimum Touch Targets - 44pt minimum
Key Files
Dependencies
- None - DesignSystem is independent
Used By
- All features - Every UI component
- App Shell - Main app screens
- Feature modules - Chat, Rating, Settings
Best Practices
Using Tokens
Using Tokens
- Never hardcode colors
- Never hardcode spacing
- Use semantic names
- Test in all themes
Creating Components
Creating Components
- Use design tokens exclusively
- Support all themes
- Add accessibility labels
- Test Dynamic Type
- Include preview
Theming
Theming
- Semantic colors only
- Support light + dark
- Instant switching
- Persist preference
Learn More
Full Documentation
Complete DesignSystem guide
Feature Settings
Theme selection UI
Building Guide
Customize themes
Architecture
See how modules use DesignSystem
Test Coverage
TheDesignSystemTests target (token + snapshot tests) runs as part of the
workspace suite — ~598 tests across 12 package test targets plus the app test
suites, all in one Boilerplate.xctestplan pass.
Tests include:
- Theme switching
- Color mapping
- Component snapshots
- Accessibility
- Dynamic Type
