StoicBuilder

HandbookVI the AtriumDesign systems and tokens

VIthe Atrium, Design the experience

Design systems and tokens

1 min readUpdated 28 November

In plain words

A design system is your app's shared kit of components and rules, and tokens are its named values, like brand colour or card radius, used instead of raw numbers.

Where you see it

In a Lovable project, the colour variables near the top of src/index.css, such as --primary and --background, and the shared shadcn/ui components in src/components/ui. Figma keeps its version under variables and styles.

src/index.cssconfig
@theme { --color-brand: #0f766e; --color-danger: #b91c1c; --radius-card: 0.75rem; --font-sans: "Inter", system-ui, sans-serif;}
Tailwind v4 turns these into classes like bg-brand and rounded-card. Change a value here and every screen follows.

What goes wrong

  1. Hex codes scattered through the code

    The brand green appears as #0f766e in 40 files, plus a slightly different green in three where the agent guessed. A rebrand turns into a search-and-replace hunt.

    <button className="bg-[#0f766e]">
  2. A new button style with every prompt

    Ask for five features and you may get five slightly different buttons. Point the agent at the existing Button component and forbid new variants unless it asks first.

  3. Dark mode that only half works

    Components that use tokens switch to dark colours; ones with a hard-coded white background stay glaring white. Tokens are what let a theme change reach everything.

What to tell your agent

Copy this into Lovable, Bolt, Cursor or any agent
Find every hard-coded colour, font size, radius and spacing value in our components and list them. Replace each with a token from our theme file, add a new token only where none fits, and reuse our existing shared components instead of creating new variants.

Quick check

Sign in to earn +10 XP for it

You change Harbor's brand colour in the theme file, but a third of the buttons keep the old colour. Why?

Got a prompt that touches design systems and tokens?

Paste it. You get a better prompt first, then the cards that explain it.

Check your own prompt

Free, no sign-up.