← tasteMarkdown

Dark mode and data viz

Condensed from: Hallmark (https://github.com/Nutlope/hallmark), Taste Skill (https://github.com/Leonxlnx/taste-skill), Open Design (https://github.com/nexu-io/open-design), UI UX Pro Max (https://github.com/nextlevelbuilder/ui-ux-pro-max-skill)

Part 1: Dark mode

Stance

Derivation (hex/ratios computed; ground = #0f1215)

Token Dark rule Example
Ground L 16-18%, chroma 0.008-0.012 on the anchor hue. Never #000. oklch(18% .008 250) #0f1215
Surfaces Lighter by +3% L per level (light mode steps darker) 21% #16191c, 24% #1c2023, 27% #24272a
Borders L 27-32%, check against surface-2 too; or rgba(255,255,255,.08) oklch(32% .008 250) #303337
Ink L 92-96%, tinted. Never #fff for body. oklch(94% .008 250) #e7ecf0, 15.8:1
Secondary text L ~75% #aaaeb3, 8.5:1
Meta text L ~65% #8c9094, 5.8:1 on ground, 5.1:1 on surface-2
Accent Chroma −0.02 to −0.04, L +5 to +10 light oklch(55% .18 255) = 3.8:1 here (fails); dark oklch(70% .14 255) #5fa1f3 = 7.0:1
Accent ink / focus Re-verify ≥4.5:1 on the new fill; focus ring 3:1 vs both grounds

Dark discipline

Implementation

:root{ color-scheme: light dark; /* light tokens */ }
[data-mode="dark"]{ /* only re-derived tokens */ }
@media (prefers-color-scheme: dark){
  :root:not([data-mode]){ /* same overrides for OS auto mode */ }
}
<script>try{const m=localStorage.getItem('mode');if(m)document.documentElement.dataset.mode=m}catch(e){}</script>

Inline it in <head> before first paint (no wrong-mode flash). Update <meta name="theme-color"> per mode. Test both modes separately.

Part 2: Data viz and dashboards

Pick the form first

Question Form
One value Stat: big figure + worded qualifier. Never a one-bar chart
2-5 values compared Stat row, or sorted horizontal bars
Moving over time? One line, straight segments (smoothing invents values)
How much per period? Columns, square or ≤4px top radius at the data end, zero baseline
Who ranks? Sorted horizontal bar list
Share of a whole 100% stacked bar with 2px seams, or a thin ring (3-5px stroke) for 3-5 parts. Never pie, fat donut, gauge
Distribution Histogram, equal bins
More than ~7 categories A table
Progress to target Bar at the true ratio, both ends labelled ("12.7k of 20.0k"), no stub at zero
Forecast Dashed after today, end value labelled
Two units Two small charts. Never dual y-axes

Few numbers → no chart.

Construction

Colour

Legends and labels

Numbers

Dashboard composition

States and accessibility

Read by your agent through get_guide("dark-mode-dataviz") in the taste MCP.