gskinnerteam/flutter-hatcha-app/theming
Claude Code and agent skill by gskinnerteam/flutter-hatcha-app
- community
Checking that the SKILL.md file is still in the repository.
Theme system for the Hatcha app. Use when: working with colors, typography, spacing, dark/light mode, design tokens, AppStyle, context.styles, $theme, $palette, AppColors, AppText, or any styling. Covers all design token tables, palette system, file structure, and customization patterns.
Install
npx vskill@latest install gskinnerteam/flutter-hatcha-app/themingSKILL.md
Theme System Guide
NOTE: This system is not in a complete state — it has been stubbed in.
The app uses a centralized theme system with design tokens accessible via context.styles (BuildContext extension) and $theme / $palette from service_locator.dart.
When to Use
- Styling any widget (colors, typography, spacing, corners, shadows)
- Adding new design tokens
- Working with dark/light mode or palette switching
- Understanding the responsive scaling system
Quick Reference
File Structure
Accessing Styles
AppStyleContext Extension (preferred)
Defined in styles.dart, provides three getters on BuildContext:
AppStyleScope is an InheritedWidget set up in app_scaffold.dart that provides AppStyle to all descendants.
`$styles` is deprecated. Always usecontext.stylesinstead.
Colors (context.colors)
Background
| Token | Light | Dark | Use Case | |
|---|---|---|---|---|
surface | White | Black (#000000) | Main surface | |
container | Light grey | 5% white opacity | Containers, subtle depth | |
highlight | Medium grey | 30% white opacity | Highlighted areas |
Text
| Token | Use Case | |
|---|---|---|
textPrimary | Primary text content | |
textSecondary | Body text, secondary content (50% opacity) | |
textTertiary | Tertiary/muted text |
Raised (Elevated Surfaces)
| Token | Use Case | |
|---|---|---|
raisedStrong | Strong elevation | |
raisedMedium | Medium elevation (cards) | |
raisedFaint | Subtle elevation |
Inset (Recessed Areas)
| Token | Use Case | |
|---|---|---|
insetStrong | Deep inset (30% black) | |
insetMedium | Medium inset (20% black) | |
insetFaint | Subtle inset (10% black) |
Stroke (Borders & Dividers)
| Token | Use Case | |
|---|---|---|
stkPrimary | Primary borders, strong lines | |
stkSecondary | Standard borders | |
stkTertiary | Subtle dividers, separators |
Status
| Token | Use Case | |
|---|---|---|
success | Success messages, completed steps | |
attention | Warnings, cautions, pending items | |
critical | Errors, destructive actions |
Palette System ($palette / context.colors)
Colors are not hardcoded — they come from a swappable AppColorPalette. This enables per-event theming and brand switching.
AppColorPalette (4 swappable tokens)
| Token | Default | Description | |
|---|---|---|---|
primaryA1 | #FFE5C07B (gold) | Primary theme color | |
supportA2 | #FF5E4A26 (dark brown) | Support accent | |
complementB1 | #FF8A7BFF (purple) | Complement color | |
supportB2 | #FF2B2452 (dark purple) | Support secondary |
Factory Constructors
| Factory | Description | |
|---|---|---|
AppColorPalette.defaultPalette() | Gold/warm brand (home/event hub) | |
AppColorPalette.noTheme() | Grayscale baseline | |
AppColorPalette.eventDefault() | Event context (same as default) |
PaletteController ($palette)
A ChangeNotifier that manages palette switching:
Palette → AppColors Integration
Palette tokens are directly accessible via context.colors:
Derived gradients:
Theme-Scoped Palette Changes
Use EventThemeBuilder widget to apply a palette to a widget subtree. updateAppStyle() in service_locator.dart accepts an optional palette parameter to rebuild AppStyle with new colors.
Typography (context.textStyles)
Display text uses EB Garamond; body/UI text uses Lato. All styles scale responsively.
| Token | Size | Weight | Font | Use Case | |
|---|---|---|---|---|---|
displayLarge | 45px | Regular (400) | EB Garamond | Hero text | |
h1 | 32px | Medium (500) | EB Garamond | Page titles | |
h2 | 24px | Medium (500) | Lato | Section headers | |
body1 | 16px | Medium (500) | Lato | Primary body text | |
body1Light | 16px | Light (300) | Lato | Secondary body text | |
body2 | 14px | Medium (500) | Lato | Small body text | |
caption | 12px | Medium (500) | Lato | Captions, labels | |
captionLight | 12px | Regular (400) | Lato | Light captions | |
btn | 14px | Medium (500) | Lato | Button text |
Apply color with copyWith:
Spacing (context.styles.insets)
Values scale responsively based on device size.
| Token | Base Value | Description | |
|---|---|---|---|
xxs | 4px | Micro spacing | |
xs | 8px | Tight spacing | |
sm | 12px | Compact spacing | |
md | 16px | Standard spacing | |
lg | 24px | Comfortable spacing | |
xl | 32px | Section spacing | |
xxl | 40px | Large section spacing | |
offset | 80px | Special offset layouts |
Corners (context.styles.corners)
| Token | Value | Use Case | |
|---|---|---|---|
sm | 4px | Subtle rounding | |
md | 8px | Standard cards | |
lg | 16px | Prominent elements | |
xl | 24px | Modals, sheets | |
full | 999px | Pills, circular elements |
Shadows (context.styles.shadows)
| Token | Type | Description | |
|---|---|---|---|
textSoft | List<Shadow> | Subtle text depth | |
text | List<Shadow> | Standard text shadow | |
textStrong | List<Shadow> | High contrast text | |
cardSoft | List<BoxShadow> | Subtle card elevation | |
card | List<BoxShadow> | Standard card elevation | |
cardStrong | List<BoxShadow> | High elevation (modals) | |
insetHighlight | List<BoxShadow> | Inner highlight effect |
Animation Timings (context.styles.times)
| Token | Duration | Use Case | |
|---|---|---|---|
fast | 300ms | Micro-interactions | |
med | 600ms | Standard transitions | |
slow | 900ms | Emphasis | |
extraSlow | 1300ms | Dramatic effect | |
pageTransition | 200ms | Page transitions |
Sizes (context.styles.sizes)
| Token | Value | Description | |
|---|---|---|---|
maxContentWidth1 | 800px | Large containers | |
maxContentWidth2 | 600px | Medium containers | |
maxContentWidth3 | 500px | Small containers | |
minAppSize | 380×650 | Minimum app constraint |
Dark/Light Mode
How it works: ThemeController (ChangeNotifier in GetIt) → AppScaffold watches it → AppStyle recreated with isDark flag → all tokens auto-switch.
Customization
Adding colors
Edit lib/design_system/styles/colours.dart:
Adding text styles
Edit AppText in styles.dart:
Adding spacing
Edit AppInsets in styles.dart:
Rules
- Access styles ONLY via
context.styles,context.colors,context.textStyles— never use$styles(deprecated) or hardcode colors - Extend styles with
copyWith— don't createTextStyle()from scratch (loses font family and scaling) - Use the spacing scale consistently — don't use arbitrary pixel values
- Use semantic token names —
context.colors.criticalnotColor(0xFFE01F1B) - Use palette tokens for brand/accent colors —
context.colors.primaryA1not hardcoded hex
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryChecking.github/skills/theming/SKILL.md
Popularity
- Repository stars
- 66
- Repository forks
- 7
- 7-day trend score
- 21
Stars and forks are for the whole GitHub repository, not this skill alone. Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/gskinnerteam/flutter-hatcha-app/theming)