Prometheus Design System v0.2.0 — WIP

Design Tokens

Color, typography, spacing, motion, and elevation tokens derived from the Prometheus codebase.

Health Status Colors

The five-state health color system. Each state has light and dark mode variants for both badge backgrounds/text and panel borders.

Badge Colors — Light Mode

ok (bg) green-1 / #ebfbee
err (bg) red-1 / #fff5f5
warn (bg) yellow-1 / #fff9db
info (bg) blue-1 / #e7f5ff
unknown (bg) gray-2 / #f1f3f5

Badge Colors — Dark Mode

ok (bg) green-9 / #2b8a3e
err (bg) red-9 75% + black
warn (bg) yellow-9 / #e67700
info (bg) blue-9 / #1864ab
unknown (bg) gray-7 / #495057

Panel Border Colors (Light / Dark)

ok bordergreen-3 / green-8
err borderred-3 / red-9
warn borderorange-3 / yellow-9
info borderblue-3 / blue-8
unknown bordergray-3 / gray-6

Live Badge Examples

Health Badges
up ok active down firing pending info unknown inactive dropped
Stats Badges
3 / 3 active 42 targets

Brand & Surface Colors

Brand Orange#e6522c
Header BGrgb(65, 73, 81)
Primary Blue#228be6
Card BG (light)#ffffff
Card BG (dark)dark-6 / #25262b
Codebox BG (light)gray-1 / #f1f3f5
Codebox BG (dark)gray-9 / #212529

Codebox Background Scale

A 10-step gray scale registered as a custom Mantine color:

PromQL Syntax Colors

TokenLightDarkLightDark
keyword / function#008080#14bfad
labelName#800000#ff8585
string#a31515#fca5a5
number / duration#09885a#22c55e

Typography

TokenValueUsage
fontFamilies.bodySystem UI stackAll body text, headings, UI elements
fontFamilies.mono"DejaVu Sans Mono", monospace fallbackPromQL, code, metric values, config YAML
fontFamilies.completionTooltip"Open Sans", "Lucida Sans Unicode"CodeMirror autocomplete tooltip

Font Sizes (Mantine scale)

TokenCSS VariableDefault
xs--mantine-font-size-xs12px
sm--mantine-font-size-sm14px
md--mantine-font-size-md16px
lg--mantine-font-size-lg18px
xl--mantine-font-size-xl20px

Font Weights

TokenValueUsage
regular400Body text
medium500Emphasis, empty states
semibold600Card titles, table headers
bold700Page headings

Line Heights

TokenValue
tight1.25
normal1.5
relaxed1.75

Text Styles

Register these as Figma text styles with the naming convention shown below.

Figma Text Style NameFont FamilySizeWeightLine HeightUsage
heading/pageSystem UI20px (xl)700 (bold)1.25Page titles (h1)
heading/sectionSystem UI18px (lg)600 (semibold)1.25Section headings (h2)
heading/cardSystem UI16px (md)600 (semibold)1.25Card titles, panel headers
body/defaultSystem UI14px (sm)400 (regular)1.5Default body text
body/emphasisSystem UI14px (sm)500 (medium)1.5Empty-state messages, emphasis text
body/smallSystem UI12px (xs)400 (regular)1.5Secondary text, table cells, descriptions
label/badgeSystem UI11px600 (semibold)1.25Status badges, label badges
label/sectionSystem UI11px700 (bold)1.25Section labels (uppercase + letter-spacing 0.08em)
label/navSystem UI13px500 (medium)1.5Nav links, active state is 500 weight
code/defaultDejaVu Sans Mono13px400 (regular)1.6Code blocks, inline code
code/metricDejaVu Sans Mono13px500 (medium)1.5Metric names in SeriesName
code/labelDejaVu Sans Mono11px400 (regular)1.5Label badge text, key-value pairs
stats/badgeSystem UI11px600 (semibold)1.25Stats badges (e.g., "3 / 3 active")

Spacing

Uses Mantine's default spacing scale. No custom overrides.

xs
8px
sm
12px
md
16px
lg
20px
xl
32px

Semantic Spacing

TokenValueUsage
headerLogoNavGapxl (32px)Gap between logo and navigation
headerNavLinksGapsm (12px)Gap between nav links
logoGroupGapxs (8px)Gap inside logo group
mainPaddingmd (16px)AppShell main area padding
cardPaddingmd (16px)Card / InfoCard padding
infoPageMaxWidth1000pxMax width of info pages
pageSectionGaplg (20px)Gap between page sections
filterToolbarGapsm (12px)Gap in filter toolbar
healthPanelBorderWidth5pxHealth panel left border
actionIconSize32pxStandard action icon size

Border Radius

TokenCSS VariableUsage
default--mantine-radius-default (4px)Default component radius
sm--mantine-radius-smNav links, small elements
md--mantine-radius-mdMedium elements
lg--mantine-radius-lgLarge containers
xl--mantine-radius-xlRounded containers
pillcalc(62.5rem * var(--mantine-scale))Status badges, label badges

Elevation / Shadows

Mantine shadow scale with light and dark mode values. Shadows are softer in dark mode using higher opacity.

TokenLight ValueDark ValueUsage
nonenonenoneInline code blocks, rule definition cards
xs0 1px 3px rgba(0,0,0,0.05), 0 1px 2px rgba(0,0,0,0.1)0 1px 3px rgba(0,0,0,0.2), 0 1px 2px rgba(0,0,0,0.25)InfoCard, AlertsPage card, RulesPage card
sm0 1px 3px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.06)0 1px 3px rgba(0,0,0,0.3), 0 2px 6px rgba(0,0,0,0.2)Light elevated surfaces
md0 2px 8px rgba(0,0,0,0.09), 0 4px 12px rgba(0,0,0,0.07)0 2px 8px rgba(0,0,0,0.35), 0 4px 12px rgba(0,0,0,0.25)Popovers, menus, notifications, SettingsPanel
lg0 4px 16px rgba(0,0,0,0.1), 0 8px 24px rgba(0,0,0,0.08)0 4px 16px rgba(0,0,0,0.4), 0 8px 24px rgba(0,0,0,0.3)Modals, heavy overlays
xl0 8px 32px rgba(0,0,0,0.12), 0 16px 48px rgba(0,0,0,0.1)0 8px 32px rgba(0,0,0,0.5), 0 16px 48px rgba(0,0,0,0.35)Maximum elevation

Border Tokens

TokenLight ValueDark ValueUsage
border-default1px solid #dee2e61px solid #373a40Card borders, table borders, inputs
border-light1px solid #e9ecef1px solid #2c2e33Subtle dividers, table cell borders
border-heavy2px solid #dee2e62px solid #373a40Table header bottom borders
health-panel-border5px solid <status-color>HealthPanel left accent border

Elevation Usage Map

ComponentElevation Token
InfoCardxs
HealthPanelnone (border-only)
CodeBlocknone
SettingsPanelmd
Dropdown / Popovermd
Modallg
Notificationmd

Motion / Transitions

TokenValueCSS ShorthandUsage
hoverReveal100ms ease-in-outopacity 100ms ease-in-outInline control reveal on hover
accordionChevron200ms easetransform 200ms easeAccordion chevron rotation
backgroundTransition150ms easebackground-color 150ms easeAccordion item bg change
interactiveHover100ms easeall 100ms easeGeneral hover state changes
dataTransition200ms easeLoading state changes

Breakpoints

TokenValuePixelsUsage
xs36em576pxAction icons visibility threshold
sm48em768pxNav collapse, burger visibility
md62em992pxLogo text visibility
lg75em1200px
xl88em1408px

Responsive Patterns

PatternBreakpointBehavior
Navbar collapsesm (768px)Below sm: drawer mode. Above sm: inline
Navbar width300px (mobile drawer)
Logo textmd (992px)Hidden below md
Action iconsxs (576px)Hidden below xs
Burger menusm (768px)Hidden above sm

CSS Variable Reference

All --prom-* CSS custom properties proposed by this design system:

VariableValue
--prom-brand-orange#e6522c
--prom-header-bgrgb(65, 73, 81)
--prom-header-text#ffffff
--prom-header-height56px
--prom-nav-link-colorgray-0
--prom-nav-link-hover-bggray-6
--prom-nav-link-active-bgprimary-color-filled
--prom-nav-link-active-color#ffffff
--prom-nav-link-radiusradius-sm
--prom-badge-ok-bglight-dark(green-1, green-9)
--prom-badge-ok-colorlight-dark(green-9, green-1)
--prom-badge-err-bglight-dark(red-1, darken(red-9))
--prom-badge-err-colorlight-dark(red-9, red-1)
--prom-badge-warn-bglight-dark(yellow-1, yellow-9)
--prom-badge-warn-colorlight-dark(yellow-9, yellow-1)
--prom-badge-info-bglight-dark(blue-1, blue-9)
--prom-badge-info-colorlight-dark(blue-9, blue-1)
--prom-badge-unknown-bglight-dark(gray-2, gray-7)
--prom-badge-unknown-colorlight-dark(gray-7, gray-4)
--prom-badge-stats-bglight-dark(gray-1, gray-8)
--prom-badge-stats-colorlight-dark(gray-7, gray-5)
--prom-label-badge-bglight-dark(gray-1, gray-8)
--prom-panel-border-width5px
--prom-panel-border-oklight-dark(green-3, green-8)
--prom-panel-border-errlight-dark(red-3, red-9)
--prom-panel-border-warnlight-dark(orange-3, yellow-9)
--prom-panel-border-infolight-dark(blue-3, blue-8)
--prom-panel-border-unknownlight-dark(gray-3, gray-6)
--prom-font-mono"DejaVu Sans Mono", monospace stack
--prom-logo-font-size1.25rem
--prom-info-page-max-width1000px
--prom-card-bglight-dark(white, dark-6)
--prom-accordion-item-bglight-dark(gray-0, dark-5)
--prom-codebox-bglight-dark(gray-1, gray-9)
--prom-promql-keywordlight-dark(#008080, #14bfad)
--prom-promql-label-namelight-dark(#800000, #ff8585)
--prom-promql-stringlight-dark(#a31515, #fca5a5)
--prom-promql-numberlight-dark(#09885a, #22c55e)
--prom-transition-hover-revealopacity 100ms ease-in-out
--prom-transition-bgbackground-color 150ms ease
--prom-transition-chevrontransform 200ms ease
--prom-transition-interactive100ms ease