DevX Design System

A technical UI system for developer resource pages — minimal, content-led, and built around a consistent token architecture.

A comprehensive showcase of every design token, surface pattern, typographic scale, spacing rhythm, and interactive component that powers the DevX experience across light and dark themes. Each example renders live from the underlying CSS custom properties — no hardcoded values, no mockups.

15+CSS Tokens
2Themes
6Typography Levels
4Border Radii
Design SystemCSS VariablesTheme TokensComponent LibraryDark ModeResponsive

Border Styles

Three border variants used across the system: standard for cards and controls, primary-tinted for active states, and dashed for hint containers.

Standard1px solid, 66% opacityUsed for default card borders, field outlines, and surface edges. The reduced opacity keeps the border present but unobtrusive, allowing content to remain the focal point of every component.border: 1px solid color-mix(in srgb, var(--border) 66%, transparent);
ActivePrimary-tinted borderApplied to focused inputs, selected items, and active navigation states. The primary hue blends into the border to signal interactivity without overwhelming the interface design.border: 1px solid color-mix(in srgb, var(--primary) 40%, var(--border) 60%);
DashedFor hint/note containersReserved for drop zones, placeholder areas, and informational callouts. The dashed stroke visually distinguishes supplementary content from primary surfaces.border: 1px dashed color-mix(in srgb, var(--border) 66%, transparent);

Light Palette

Light mode swatches sourced from the documented theme tokens, including the six CSS custom properties and the X theme brand accent colors used in navbar icons and interactive states.

BackgroundMain page surface
ForegroundPrimary readable text
PrimaryActive states, accents
Text MutedSecondary copy
BorderSeparators, outlines
Card BGSurface blending helper
#fc618dIcon RedNavbar icons, brand (color1)
#ffc400Icon GoldHover states, xfetch CTA

Light mode swatches sourced from the project theme tokens defined in globals.css. The background (#ffffff) is a clean white for optimal readability. Foreground (#171717) is a deep near-black for primary text. The violet primary (#4328a8) provides accessible accents across buttons, links, and active indicators. Stone (#6b7280) handles muted secondary text, while border (#e5e7eb) separates content layers with a subtle line. Card backgrounds (#f9fafb) sit slightly above the page surface.

Dark Palette

Dark mode swatches with the same token structure. The background deepens while accent colors remain consistent across both modes.

BackgroundMain page surface
ForegroundPrimary readable text
PrimaryActive states, accents
Text MutedSecondary copy
BorderSeparators, outlines
Card BGSurface blending helper
#fc618dIcon RedNavbar icons, brand (color1)
#ffc400Icon GoldHover states, xfetch CTA

Dark mode swatches shift to a near-black background (#0a0a0a) with a soft off-white foreground (#ededed) that reduces eye strain in low-light environments. The gold primary (#fbbf24) provides warm, accessible accents across buttons, links, and active indicators. Zinc muted text (#9ca3af) provides consistent secondary contrast. Border (#27272a) deepens to a cool charcoal that maintains visual separation without introducing glare. Card background (#18181b) sits slightly above the page surface, creating a subtle elevation effect for layered containers.

When comparing light and dark palettes, the most significant shift occurs in the background (from #ffffff to #0a0a0a) and primary (from #4328a8 to #fbbf24) tokens. The light-mode violet primary (#4328a8) shifts to a warm gold (#fbbf24) in dark mode to maintain WCAG AA contrast ratios against the dark surface. The card-bg token in dark mode (#18181b) is slightly lighter than the page background, creating a subtle elevation effect that helps layered surfaces feel physically stacked.

Typography Scale

A compact, purposeful type system where hierarchy is expressed through weight and spacing rather than decorative flourishes.

h1The quick brown fox
h2The quick brown fox
bodyThe quick brown fox jumps over the lazy dog.
mutedSecondary metadata text
codeconst x = await fetchData();
h3The quick brown fox jumps over the lazy dog near the riverbank under a pale moon.
code (inline)npx opencode install devx --theme=dark --output=json
captionPhoto credit: Unsplash / Design Studio — typically used for image captions, timestamps, and helper text beneath form fields where the information supports but does not compete with primary content.
labelACTIVE SESSION — uppercase labels used for section headings, sidebar categories, and form field labels that require clear hierarchical distinction.
overlineSection Overline — micro text appearing above headings as a contextual cue for grouping related content.

Line Height Contrast

Three line heights create the reading rhythm: tight for headings, normal for body copy, and relaxed for introductory passages.

tight (1.2)

A compact line height ideal for headings where vertical economy matters and every word carries weight across narrow layouts. Commonly used for page titles, section headings, and callout headers that need to stay visually dense without wasting vertical space between lines of text.

normal (1.6)

The standard reading rhythm for body text, balancing readability with information density across paragraphs and descriptions. This is the default applied to all prose content, card descriptions, documentation text blocks, and UI copy throughout the entire design system.

relaxed (1.8)

A spacious line height used for introductory content and extended descriptions, giving each line room to breathe for longer reading sessions. Best suited for hero subtitles, feature overviews, and any block of text where comprehension and reading comfort are the highest priority.

Font Families

The system uses a primary monospace stack for code and data, with the interface font inherited from the project theme for headings and body text.

SerifHeadings, display text, long-form articles

The quick brown fox jumps over the lazy dog near the bank of the river. A serene landscape unfolds with every passing moment, inviting the reader to linger just a little longer on the page and absorb the carefully crafted words that follow across the columns below.

font-family: Georgia, 'Times New Roman', serif;
Sans-SerifBody, UI labels, navigation, buttons

The quick brown fox jumps over the lazy dog near the bank of the river. A serene landscape unfolds with every passing moment, inviting the reader to linger just a little longer on the page and absorb the carefully crafted words that follow across the columns below.

font-family: ui-sans-serif, system-ui, sans-serif;
MonoCode, CLI output, tokens, config

const theme = { palette: { primary: "#6C63FF", muted: "#8E8E9A", border: "#D4D4DC", cardBg: "#F0F0F5" } }; const tokens = createThemeTokens(theme); export default tokens;

font-family: ui-monospace, 'SF Mono', monospace;

Three font families serve distinct roles. Serif provides a traditional, authoritative voice for headings and long-form content. Sans-serif handles the bulk of UI text with clean readability at small sizes. Mono ensures precise alignment for code and configuration blocks where character-level spacing and legibility are critical for accuracy.

Spacing Rhythm

A disciplined spacing scale that creates hierarchy through contrast before introducing borders or dividers.

Tight0.25rem
Standard0.75rem
Section1.25rem
Major3.5rem

The spacing scale progresses from tight (0.25rem) through standard (0.75rem) and section (1.25rem) to major (3.5rem). Each step is tuned for a specific purpose: tight for inline gaps between closely related elements, standard for card padding and inner gutters, section for separating distinct page segments, and major for hero margins, modal padding, and full-width banner spacing. This logarithmic progression ensures visual rhythm is maintained at every layout level without arbitrary values.

Section Composition

Each section follows a three-part structure: identity, main content surface, and supporting utility or call to action.

1. Identity / Context
2. Main Content Surface
3. Supporting Utility / CTA

Each section block follows a three-layer rhythm: identity context at the top (badge, icon, or label), the main content surface in the middle (text, controls, or interactive elements), and a supporting utility layer at the bottom (metadata, secondary actions, or CTAs). This predictable vertical structure helps users scan and navigate content quickly across every page in the system, reducing cognitive load through consistent spatial hierarchy.

Surface Patterns

Two surface recipes cover every container in the system: a standard bordered surface for controls and cards, and a darker code block surface for technical content.

Standard Surface

The default bordered container used for controls, command cards, and theme cards across all resource pages.

border: 1px solid color-mix(in srgb, var(--border) 66%, transparent); background: color-mix(in srgb, var(--background) 94%, var(--card-bg) 6%);
Code Block Surface

Darker background for code examples, used in install instructions and config previews.

background: color-mix(in srgb, var(--background) 86%, #050505 14%);

Two surface variants cover the majority of UI containers. The standard surface uses a subtle border and near-transparent card background blend for general-purpose cards and panels. The code block surface uses a darker tint that signals a technical context, helping developers quickly identify areas of the interface that contain runnable or configurable content.

Color Token Application

The six color tokens applied as surface fills, demonstrating their visual weight and hierarchy across both light and dark modes.

--backgroundMain page surface
--foregroundPrimary readable text
--primaryActive states, accents
--text-mutedSecondary copy
--borderSeparators, outlines
--card-bgSurface blending helper

Each token maps to a semantic CSS custom property consumed across every component in the system. Buttons inherit --primary for their fill color, cards blend --card-bg with the base background via color-mix, and text nodes reference --foreground or --text-muted depending on their hierarchy level. When the theme toggles, every token updates in unison — no manual overrides or per-component adjustments are needed. This centralized approach guarantees visual consistency across the entire interface regardless of page depth or component type.

--primaryButton fills, link text, active indicators, focus outlines, toggle switches
--foregroundHeadings, body text, table cells, list items, label text
--text-mutedSecondary copy, captions, timestamps, placeholder text, metadata labels
--borderCard outlines, input borders, dividers, table cell separators, section rules
--backgroundPage background, modal backdrops, empty state areas
--card-bgCard surface blending, sidebar panels, dropdown menus, tooltip backgrounds

SVG Graphics

Inline SVG examples demonstrating how theme-aware strokes, fills, and gradients adapt automatically between light and dark modes using CSS custom properties and color-mix.

Rounded rectangle Empty circle Dashed connector Smooth bezier curve Dot grid with ties
Bar chart Active bar Axis line
Peak
Area chart Gradient fill Annotation line

All SVG primitives inherit var(--primary) as their stroke color, ensuring they adapt automatically between light and dark themes without additional media queries or per-theme redefinitions. Opacity, gradients, and color-mix are used to create visual hierarchy among overlapping elements within the same graphic.

Common use cases include: animated loading indicators, decorative section dividers, icon placeholders during prototyping, data visualisation stubs for proof-of-concept dashboards, and transition elements that respond to theme state changes in real time.

Because SVGs reference CSS custom properties directly, switching between light and dark mode requires zero JavaScript intervention — the browser repaints strokes and fills automatically when the property values update at the root level.

For gradient fills, the <linearGradient> element references var(--primary) via color-mix at varying opacities. This technique allows gradients to remain theme-aware without requiring duplicate gradient definitions for light and dark mode.

Border Radius

Four radius levels define the surface language: square for technical elements, soft for cards, rounded for media, and full pill for badges.

square0Code blocks, data tables, alert bars, toolbar items
soft4pxCards, inputs, buttons, side panels, containers
rounded8pxModals, dropdowns, floating panels, tooltips
pill999pxBadges, tags, toggle handles, circular avatars, counters

Button Patterns

Three button tiers: primary filled for main actions, secondary outlined for alternatives, and ghost for subtle inline controls.

PrimarySolid fill, highest emphasisbackground: var(--primary); color: var(--background);
SecondaryBordered, medium emphasisborder: 1px solid var(--border); background: transparent;
GhostNo surface, low emphasisbackground: transparent; border: none; color: var(--text-muted);

Three button tiers provide a clear visual hierarchy across the interface. The primary button uses var(--primary) as its solid fill and stands out as the main call to action on any surface. Secondary buttons use a subtle border and transparent background, ideal for alternative actions that should remain visible but not compete with the primary action. Ghost buttons carry no surface or border at all — they are used for tertiary controls that must exist in the layout but should not draw the user's focus away from primary and secondary actions. A disabled variant demonstrates the reduced-opacity fallback applied when actions are unavailable.

Fixed Light Mode

Button appearance under a fixed light palette (#ffffff background, #4328a8 primary, #6b7280 muted), independent of the global theme.

Fixed Dark Mode

Button appearance under a fixed dark palette (#0a0a0a background, #fbbf24 primary, #9ca3af muted), independent of the global theme.

The DevX system proves that restraint in tokens, spacing, and typography creates interfaces that are both visually cohesive and easy to extend.

Every token, swatch, surface pattern, and typographic scale documented on this page is live — pulled directly from the same CSS custom properties that drive every component in the DevX design system. Change a variable value at the root level and every consumer across the entire interface updates in unison. No recompilation, no rebuild, no extra deploy. That is the power of a token-driven system built on CSS custom properties. The patterns shown here form the foundation for every resource page, skill showcase, and interactive component across the platform.