mdx-formatter

Type to search...

to open search from anywhere

Full Token Reference

Full Token Reference

Source of truth: doc/src/styles/global.css

Horizontal Spacing (hsp)

TokenValueTypical use
hsp-2xs0.125rem (2px)Tight inline padding
hsp-xs0.375rem (6px)Compact inline gaps
hsp-sm0.5rem (8px)Small buttons, small padding
hsp-md0.75rem (12px)Default gaps, list items
hsp-lg1rem (16px)Standard padding, larger gaps
hsp-xl1.5rem (24px)Generous padding, content edges
hsp-2xl2rem (32px)Large padding blocks

Vertical Spacing (vsp)

TokenValueTypical use
vsp-2xs0.4375rem (7px)Tight gaps
vsp-xs0.875rem (14px)Small gaps, list items
vsp-sm1.25rem (20px)Compact sections
vsp-md1.5rem (24px)Standard gap between blocks
vsp-lg1.75rem (28px)Section-to-section gap
vsp-xl2.5rem (40px)Large section gap
vsp-2xl3.5rem (56px)Page-level breaks

Color Palette (p0-p15)

Raw palette slots exposed as --color-p0 through --color-p15. Values change per color scheme (light/dark). Use semantic aliases instead of raw palette.

Semantic Colors

TokenLight maps toDark maps toUse
bgscheme bgscheme bgPage background
fgscheme fgscheme fgMain text
surfacep0p10Panels, cards, elevated bg
mutedp8p8Borders, secondary text
accentp5p12Links, CTAs, active states
accent-hoverp14p14Hover for accent
code-bgp10p10Code block background
code-fgp11p11Code block text
successp2p2Green, positive
dangerp1p1Red, error
warningp3p3Amber, caution
infop4p4Blue, informational

Typography

Font Families

  • font-sans / font-noto: Noto Sans, Noto Sans JP, system fallbacks
  • font-futura: Futura, Jost, Century Gothic, system fallbacks
  • font-mono: ui-monospace, monospace

Font Sizes

TokenValuerem
text-caption14px0.875rem
text-small16px1rem
text-body19.2px1.2rem
text-subheading22.4px1.4rem
text-heading48px3rem
text-display60px3.75rem

Line Heights

TokenValue
leading-tight1.25
leading-snug1.375
leading-normal1.5
leading-relaxed1.625

Font Weights

TokenValue
font-normal400
font-medium500
font-semibold600
font-bold700

Border Radius

TokenValue
rounded0.25rem (4px)
rounded-lg0.5rem (8px)
rounded-full9999px

Breakpoints

TokenValueUse
sm:640pxTablet
lg:1024pxDesktop, sidebar appears
xl:1280pxWide desktop

Content Styling (.zd-content)

Applied to article elements. Uses :where() for zero specificity.

  • Default: text-body, leading-relaxed
  • Flow spacing: > * + * gets margin-top: vsp-md
  • Headings: font-futura, normal weight
  • Links: color-accent, underlined, 4px offset
  • Lists: disc/decimal, padding-left: hsp-xl, li margin-bottom vsp-xs
  • Blockquotes: left border 3px muted, italic, padding-left: hsp-lg
  • Code blocks: text-small, leading-relaxed, Shiki dual theme
  • Tables: text-small, padding vsp-xs hsp-md

Layout Constants

  • Header height: 3.5rem (56px)
  • Sidebar width: clamp(14rem, 20vw, 22rem)
  • Main content max-width: clamp(50rem, 75vw, 90rem)
  • Content padding: px-hsp-xl py-vsp-xllg:px-hsp-2xl lg:py-vsp-2xl

Revision History