OpenVibe Tokens

Your theme, as code

Take any OpenVibe theme into your own app, its light and dark halves together: the web, Android, iOS, Flutter or Figma. The colours are the ones the network paints.

MaterialApp(theme: ThemeData(colorScheme: vaporLightScheme), darkTheme: ThemeData(colorScheme: vaporDarkScheme)). The raw values are on VaporDarkTokens and VaporLightTokens.

// Vapor (dark) — generated by openvibe-shared/tokens v1 from the OpenVibe theme "vapor". Regenerate instead of editing.
import 'package:flutter/material.dart';

/// Magenta and teal, straight off a VHS tape.
class VaporDarkTokens {
  VaporDarkTokens._();
  static const colorBgBase = Color(0xFF0E0A14);
  static const colorBgSurface = Color(0xFF14101C);
  static const colorBgSubtle = Color(0xFF1C1628);
  static const colorBgRaised = Color(0xFF181220);
  static const colorBgHover = Color(0xFF241A34);
  static const colorBgInput = Color(0xFF100C16);
  static const colorTextPrimary = Color(0xFFF0E0FF);
  static const colorTextSecondary = Color(0xFFC090E0);
  static const colorTextMuted = Color(0xFF967BBB);
  static const colorAccentBase = Color(0xFFE040FB);
  static const colorAccentLight = Color(0xFFEA80FC);
  static const colorAccentDark = Color(0xFFAA00D4);
  static const colorAccentStrong = Color(0xFFBC36D3);
  static const colorAccentOn = Color(0xFFFFFFFF);
  static const colorAccentOnStrong = Color(0xFFFFFFFF);
  static const colorAccentGlow = Color(0x59E040FB);
  static const colorLineBase = Color(0xFF2A1A40);
  static const colorLineStrong = Color(0xFF3A2A50);
  static const colorStatusOkBase = Color(0xFF69F0AE);
  static const colorStatusOkText = Color(0xFF69F0AE);
  static const colorStatusWarnBase = Color(0xFFF59E0B);
  static const colorStatusWarnText = Color(0xFFF59E0B);
  static const colorStatusBadBase = Color(0xFFEF4444);
  static const colorStatusBadText = Color(0xFFF04B4B);
  static const colorStatusInfoBase = Color(0xFF00E5FF);
  static const colorStatusInfoText = Color(0xFF00E5FF);
  static const colorStatusLiveBase = Color(0xFFEF4444);
  static const colorStatusLiveText = Color(0xFFF04B4B);
}

const vaporDarkScheme = ColorScheme(
  brightness: Brightness.dark,
  primary: VaporDarkTokens.colorAccentBase,
  onPrimary: VaporDarkTokens.colorAccentOn,
  primaryContainer: VaporDarkTokens.colorAccentStrong,
  onPrimaryContainer: VaporDarkTokens.colorAccentOnStrong,
  secondary: VaporDarkTokens.colorAccentLight,
  onSecondary: VaporDarkTokens.colorAccentOn,
  tertiary: VaporDarkTokens.colorStatusInfoBase,
  background: VaporDarkTokens.colorBgBase,
  onBackground: VaporDarkTokens.colorTextPrimary,
  surface: VaporDarkTokens.colorBgRaised,
  onSurface: VaporDarkTokens.colorTextPrimary,
  onSurfaceVariant: VaporDarkTokens.colorTextSecondary,
  outline: VaporDarkTokens.colorLineStrong,
  outlineVariant: VaporDarkTokens.colorLineBase,
  error: VaporDarkTokens.colorStatusBadBase,
  onError: VaporDarkTokens.colorAccentOnStrong,
);

/// Vapor in pastel daylight: magenta on lilac.
class VaporLightTokens {
  VaporLightTokens._();
  static const colorBgBase = Color(0xFFFCF6FF);
  static const colorBgSurface = Color(0xFFF6ECFC);
  static const colorBgSubtle = Color(0xFFEEDFF8);
  static const colorBgRaised = Color(0xFFFEFAFF);
  static const colorBgHover = Color(0xFFF2E5FA);
  static const colorBgInput = Color(0xFFF9F1FE);
  static const colorTextPrimary = Color(0xFF22122C);
  static const colorTextSecondary = Color(0xFF533F5F);
  static const colorTextMuted = Color(0xFF715C7E);
  static const colorAccentBase = Color(0xFFA21CAF);
  static const colorAccentLight = Color(0xFFA921BA);
  static const colorAccentDark = Color(0xFF701A75);
  static const colorAccentStrong = Color(0xFFA21CAF);
  static const colorAccentOn = Color(0xFFFFFFFF);
  static const colorAccentOnStrong = Color(0xFFFFFFFF);
  static const colorAccentGlow = Color(0x59A21CAF);
  static const colorLineBase = Color(0xFFE6D3F1);
  static const colorLineStrong = Color(0xFFDBC0EA);
  static const colorStatusOkBase = Color(0xFF22C55E);
  static const colorStatusOkText = Color(0xFF147237);
  static const colorStatusWarnBase = Color(0xFFF59E0B);
  static const colorStatusWarnText = Color(0xFF895806);
  static const colorStatusBadBase = Color(0xFFEF4444);
  static const colorStatusBadText = Color(0xFFBA3535);
  static const colorStatusInfoBase = Color(0xFF38BDF8);
  static const colorStatusInfoText = Color(0xFF1F6A8B);
  static const colorStatusLiveBase = Color(0xFFEF4444);
  static const colorStatusLiveText = Color(0xFFBA3535);
}

const vaporLightScheme = ColorScheme(
  brightness: Brightness.light,
  primary: VaporLightTokens.colorAccentBase,
  onPrimary: VaporLightTokens.colorAccentOn,
  primaryContainer: VaporLightTokens.colorAccentStrong,
  onPrimaryContainer: VaporLightTokens.colorAccentOnStrong,
  secondary: VaporLightTokens.colorAccentLight,
  onSecondary: VaporLightTokens.colorAccentOn,
  tertiary: VaporLightTokens.colorStatusInfoBase,
  background: VaporLightTokens.colorBgBase,
  onBackground: VaporLightTokens.colorTextPrimary,
  surface: VaporLightTokens.colorBgRaised,
  onSurface: VaporLightTokens.colorTextPrimary,
  onSurfaceVariant: VaporLightTokens.colorTextSecondary,
  outline: VaporLightTokens.colorLineStrong,
  outlineVariant: VaporLightTokens.colorLineBase,
  error: VaporLightTokens.colorStatusBadBase,
  onError: VaporLightTokens.colorAccentOnStrong,
);

/// The OpenVibe kit's radius, space, size and type scales: the same in every theme.
class OvScale {
  OvScale._();
  static const double radiusSm = 10;
  static const double radiusMd = 14;
  static const double radiusLg = 20;
  static const double radiusPill = 999;
  static const double spaceXs = 4;
  static const double spaceSm = 8;
  static const double spaceMd = 12;
  static const double spaceLg = 16;
  static const double spaceXl = 24;
  static const double spaceXxl = 32;
  static const double sizeTap = 44;
  static const double sizeIcon = 20;
  static const double sizeAvatar = 34;
  static const double typeSizeCaption = 12;
  static const double typeSizeMeta = 13;
  static const double typeSizeBody = 15;
  static const double typeSizeLead = 17;
  static const double typeSizeTitle = 20;
  static const double typeSizeHeadline = 24;
  static const double typeSizeDisplay = 34;
}

Files your tools can fetch

This theme on its own, with the motion every OpenVibe page shares and the mark’s colours. Each one has a lasting address a build or a design tool can read straight from here.

Every colour token · 28 of them
  • color.bg.base#0e0a14#fcf6ffThe page behind everything
  • color.bg.surface#14101c#f6ecfcBands and side panels
  • color.bg.subtle#1c1628#eedff8Wells, tracks and quiet fills
  • color.bg.raised#181220#fefaffCards, rows and sheets
  • color.bg.hover#241a34#f2e5faA control under the pointer or finger
  • color.bg.input#100c16#f9f1feText fields
  • color.text.primary#f0e0ff#22122cBody text and titles
  • color.text.secondary#c090e0#533f5fSupporting text
  • color.text.muted#967bbb#715c7eHints and meta lines
  • color.accent.base#e040fb#a21cafLinks, icons, focus rings
  • color.accent.light#ea80fc#a921baThe accent a step lighter
  • color.accent.dark#aa00d4#701a75The accent a step darker
  • color.accent.strong#bc36d3#a21cafFilled buttons
  • color.accent.on#ffffff#ffffffText on the accent
  • color.accent.onStrong#ffffff#ffffffText on a filled button
  • color.accent.glowrgba(224,64,251,0.35)rgba(162,28,175,0.35)Glows and halos
  • color.line.base#2a1a40#e6d3f1Dividers and outlines
  • color.line.strong#3a2a50#dbc0eaOutlines that must show
  • color.status.ok.base#69f0ae#22c55eSuccess fills
  • color.status.ok.text#69f0ae#147237Success text on any surface
  • color.status.warn.base#f59e0b#f59e0bWarning fills
  • color.status.warn.text#f59e0b#895806Warning text on any surface
  • color.status.bad.base#ef4444#ef4444Danger fills
  • color.status.bad.text#f04b4b#ba3535Danger text on any surface
  • color.status.info.base#00e5ff#38bdf8Information fills
  • color.status.info.text#00e5ff#1f6a8bInformation text on any surface
  • color.status.live.base#ef4444#ef4444LIVE badges
  • color.status.live.text#f04b4b#ba3535LIVE text on any surface

Every theme also carries the kit's scales: radius.*, space.* (4 to 32), size.tap (44), type.size.*, type.weight.* and motion.*.

Why tokens, and what is next

A theme on OpenVibe is one set of design tokens: semantic names such as color.accent.strong and space.lg, kept apart from any one platform. The web reads them as CSS variables today. An Android or iOS app reads the same values in Compose or SwiftUI, so a native app wears your theme without being a web page in a frame.

The format is the W3C Design Tokens one, so the same file works in Style Dictionary, Tokens Studio and Figma. Next: the kit's components described the same way (anatomy, states, roles), so a page made on OpenVibe.Design can be drawn natively too.

Change this theme in the studio The tokens API