Skip to content
Theme
endue.ai

Start

Use it in a product

endue AI, ID, OS, Space and Live read the same tokens and follow the same rules. This is how a product takes them in.

1. Take the files

  • tokens.css holds the values as CSS custom properties.tokens.json is the same set for anything that is not CSS.
  • components.css is a plain CSS implementation of the components documented here. Use it as it is, or as the reference your own components match.
  • Copy the files into the product's repository. Don't link to this site at runtime: a change here should reach a product through a release, not by itself.

2. Load the tokens first

Tokens come before component styles, and both come before the product's own styles.

<link rel="stylesheet" href="/styles/endue/tokens.css" />
<link rel="stylesheet" href="/styles/endue/components.css" />
<link rel="stylesheet" href="/styles/app.css" />

Text is Inter, with SUIT Variable for Korean, and code is JetBrains Mono. Load them the way the product already loads fonts.

3. Set the theme

The theme is one attribute on the root element. Which surface uses which theme is on thethemes page. If a product has one theme only, give it that one. Don't open a second theme just to have it.

<!-- A public page: Stone, fixed -->
<html data-theme="dark">

<!-- The console: the person's choice, Stone by default -->
<html data-theme="dark">  or  <html data-theme="light">

4. Write roles, not values

Screen code names what a color is for. It never names the color. The same rule holds for spacing, corner radius and shadow.

.panel {
  background: var(--card);
  color: var(--foreground);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
}

.panel-note {
  color: var(--muted-foreground);
}

.row:hover,
.row[aria-selected='true'] {
  background: var(--accent);
}
  • The fill is ink in every product. A product does not bring its own fill color.
  • Colors that carry data stay: a chart series, a module, an API method, the color a person picked for an agent. Those are data, not decoration.
  • Outside the web, read tokens.json and generate values for the platform. Keep the token names the same.

5. Check the screen

Look at every screen in each theme the product has, and at 360px wide.

  1. Is there exactly one filled button in each group: each form, dialog, card and page header?
  2. Is the star the only thing that has color? No colored buttons, headings, surfaces or borders.
  3. Is each status a sentence, with a colored surface only for warnings, failures and needs attention?
  4. Is selection the accent surface, and never a fill?
  5. Do only floating things have a border and a shadow? Lists are rows divided by hairlines.
  6. Does anything other than the star move on its own?
  7. Are links told apart by an underline?
  8. Is every color a role token? No hex, no rgba, no brand base value in screen code.
  9. Does text meet 4.5:1 and do control borders, focus rings and icons meet 3:1, in both themes?
  10. Does every screen hold at 360px wide?

Where to look next