Theming without forking
The Privacy Portal connects to Alberta.ca Account. It needed its own look, approved by the Minister, on a hard deadline. The easy answer was to copy the components and restyle them, which would have cut the portal off from every future fix. Instead we added design tokens at the component level, so the portal could adjust its visual design and still get every update.
- Role
- Product owner. I wrote the work plan.
- Partner
- The Privacy Portal team
- Deadline
- 29 November 2024
- Result
- Shipped early, no fork
How does one team's request make the whole system better?
That's how a single portal's deadline gave everyone a new drawer component, a reusable way to theme and later an experimental dark theme.
Sorting every component into five groups
My work plan put each request from the portal into one of five groups. The group decided how much the core system had to change.
| Group | What it meant | Examples |
|---|---|---|
| No change | Existing options were enough | Table |
| Style through tokens | New component-level tokens | Callout, accordion, container, button, side menu |
| New behaviour | A small feature added to the core component | Header (click event on the menu button) |
| New core component | Built for the portal, useful for other teams | Drawer |
| Experimental component | Not an approved design system pattern, kept in a separate package with its own lifecycle | Form stepper |
What a component-level token looks like
This excerpt is from the public token package. The callout has 51 tokens of its own, and each one points to a global value. A service can change its own callout without forking the component.
"callout-border-radius": { "value": "{borderRadius.xl}" },
"callout-heading-color": { "value": "{color.text.default}" },
"callout-info-heading-bg-color": { "value": "{color.info.light}" },
"callout-info-content-bg-color": { "value": "{color.greyscale.white}" },
"callout-h-info-border-color": { "value": "{color.info.border}" }
The same approach for dark mode
Several teams were building their own dark modes. Each one was a different take on the Alberta brand. I wrote the strategy for one shared version: an experimental theme first, a one to three month trial, structured feedback, then a review with the government's Communications and Public Engagement team.
The experimental theme is now public on design.alberta.ca, with guidance for designers and for developers.
Impact
- Shipped earlyEvery component shipped before the 29 November 2024 deadline, so the portal team could ship more than planned.
- No forkThe portal still runs on the core system and gets every fix.
- A reusable patternComponent-level tokens became the answer for any service that needs its own look.