Skip to content

Theming

Use these CSS variables in your space's styles. The host does the rest — sets the values, owns the theme switcher, flips light/dark, applies user customizations. You just reference the variables.

vue
<style scoped>
.banner {
  color: var(--app-foreground);
  background: var(--app-card);
  border: 1px solid var(--app-border);
}
</style>

Surface

VariableWhen to use
--app-backgroundPage background — the canvas behind everything.
--app-foregroundDefault text color.
--app-mutedSecondary text — placeholders, captions, timestamps.
--app-borderDefault border — inputs, cards, separators.
--app-surfaceRaised surfaces — sidebars, sticky bars.
--app-canvas-bgReceding fill — large empty workspaces, areas that should sit behind content.
--app-cardCard and panel background.
--app-card-hoverCard background on hover or active row state.
--app-input-bgBackground for form controls — Input, Select, Textarea.
--app-status-bgBackground for inline status chips, count badges.

Brand

VariableWhen to use
--app-accentPrimary brand color — focused buttons, links, focus rings, active tabs.
--app-accent-foregroundText laid on top of --app-accent.
--app-accent-mutedSoft accent fill — selection background, ghost-button hover.

Status

VariableWhen to use
--app-successSuccess state — confirmations, completed timelines, online dots.
--app-dangerError / destructive state — delete buttons, validation messages.

Don't hard-code colors

Reach for var(--app-*) first. Hex/rgb literals break the moment the host adds a new theme or the user customizes their colors. The whole point of these variables is "the design system" being one declaration away from being overridden.

Released under the MIT License.