Dashboard Design
| Property |
Value |
| Domain |
Data Analytics |
| Category |
Dashboard Architecture & Layout |
| Components |
SKILL.md + dashboard-design.instructions.md + dashboard.prompt.md |
| Depends |
data-visualization (chart content), data-analysis (KPIs and segments) |
Staleness Watch: See EXTERNAL-API-REGISTRY.md for source URLs and recheck cadence
Overview
Design dashboards that tell stories through layout. A dashboard is not a collection of charts -- it's a guided reading experience where position, size, and interaction design control what the viewer understands and in what order.
The cardinal rule: reading order = story order. KPIs answer "what?", charts answer "why?", tables answer "how much?", and drill-downs answer "show me more."
Module 1: Layout Patterns
| Pattern |
Best For |
Reading Flow |
Use When |
| Inverted Pyramid |
Executive dashboards |
KPIs → hero chart → supporting → detail |
Audience scans from top, drills as needed |
| Z-Pattern |
Marketing / consumer |
Top-left → top-right → bottom-left → end |
Two primary metrics side-by-side |
| F-Pattern |
Data-heavy analytics |
Left column scanned top-down, right detail |
Dense detail dashboards for analysts |
| Hub-and-Spoke |
Exploration dashboards |
Central question, surrounding perspectives |
When multiple equally important views exist |
| Narrative Scroll |
Data stories / reports |
Top-to-bottom linear reading |
Self-contained HTML stories with guided arc |
Reference Pattern: Inverted Pyramid (from population.html)
┌────────────────────────────────────────────────────┐
│ HEADER: Title + subtitle + badge │
├────────────────────────────────────────────────────┤
│ KPI ROW: 3-6 cards (auto-fit grid) │
├────────────────────────────────────────────────────┤
│ CONTROLS: Search + filter buttons │
├────────────────────────────────────────────────────┤
│ HERO CHART: Full-width, clickable │
├───────────────────────┬────────────────────────────┤
│ SUPPORTING CHART 1 │ SUPPORTING CHART 2 │
├───────────────────────┴────────────────────────────┤
│ DATA TABLE: Sortable, ranked, inline indicators │
├────────────────────────────────────────────────────┤
│ FOOTER: Data source + attribution + last updated │
└────────────────────────────────────────────────────┘
┌── DRILL-DOWN MODAL ──┐
│ Detail stats grid │
│ Horizontal bar │
│ Detail table │
└───────────────────────┘
Module 2: KPI Card Design
Each KPI card follows the metric + delta + context pattern:
| Element |
Purpose |
Example |
| Primary value |
The headline number |
"334M" |
| Label |
What it measures |
"Total Population" |
| Delta |
Change indicator (arrow + %) |
"↑ 2.1% YoY" |
| Sparkline |
Trend miniature (optional) |
Tiny 30-day line |
| Subtitle |
Time range or source |
"2024 Census estimate" |
| Icon/Emoji |
Visual anchor |
"👥" |
| Accent color |
Category signal |
Brand purple |
KPI Selection Rules
| Rule |
Why |
| 3-6 KPIs maximum |
More overwhelms; fewer under-informs |
| Each answers a different "what?" |
Redundant KPIs waste prime real estate |
| Include at least one delta |
Static numbers lack context |
| Lead with the most important |
Top-left KPI gets the most attention |
| Color thresholds if applicable |
Green/amber/red for status-driven metrics |
Module 3: Filter Architecture
| Filter Type |
Placement |
Behavior |
Example |
| Global filter |
Top, below KPIs |
Affects all charts and table |
Region buttons, date range |
| Chart filter |
Inline on chart |
Affects only parent chart |
Sort toggle, limit slider |
| Cross-filter |
Click on chart |
Highlights related data elsewhere |
Click bar → table highlights |
| Drill-through |
Click on item |
Opens detail modal or new view |
Click state → city breakdown |
| Search |
Top controls |
Text filter across primary column |
Search box for state names |
Filter Design Rules
- Global filters visible at all times (sticky if page scrolls)
- Active filter state clearly indicated (colored buttons, badges)
- "All" or "Reset" always available as first option
- Filter changes animate smoothly (transition: 300ms)
- Filter state reflected in chart titles or subtitles
Module 4: Narrative Flow
The dashboard tells a story through panel arrangement:
| Layer |
Component |
Answers |
Time to Absorb |
| 1 |
KPI cards |
"What's the story?" |
2 seconds |
| 2 |
Hero chart |
"Show me the shape" |
10 seconds |
| 3 |
Supporting charts |
"What else?" |
15 seconds |
| 4 |
Data table |
"Give me the details" |
As needed |
| 5 |
Drill-down modal |
"Tell me more about X" |
On demand |
Progressive Disclosure
- Above the fold: KPIs + hero chart (must convey the main story without scrolling)
- Below the fold: Supporting views + table (deeper evidence)
- On demand: Drill-down modals, tooltips, expandable rows
Module 5: Self-Contained HTML Pattern
Every dashboard outputs as a single HTML file:
| Requirement |
Implementation |
| Zero build step |
Open in browser, no npm/webpack/build |
| Embedded data |
JavaScript arrays/objects, not external API calls |
| Single CDN dependency |
Chart.js 4.x via jsdelivr |
| Responsive |
CSS grid with auto-fit, minmax, media queries |
| Themeable |
CSS custom properties for colors, spacing, fonts |
| Accessible |
Semantic HTML, ARIA labels, alt text on charts |
| Print-friendly |
@media print styles for clean output |
CSS Custom Properties Template
:root {
--bg-primary: #0f0f23;
--bg-card: #1a1a2e;
--text-primary: #e8e8f0;
--text-secondary: #888;
--accent-1: #6366f1;
--accent-2: #3b82f6;
--accent-3: #10b981;
--accent-4: #f59e0b;
--accent-5: #ec4899;
--border-radius: 12px;
--shadow: 0 2px 8px rgba(0,0,0,0.3);
--transition: 0.3s ease;
}
Module 6: Platform Targets
| Platform |
Output Format |
Key Differences |
| HTML (primary) |
Self-contained |
Chart.js + Canvas, embedded data |
| Power BI |
Report spec |
DAX measures, M queries, visual config |
| Streamlit |
Python app |
Plotly charts, st.columns, st.metric |
| React |
Component tree |
Recharts/Nivo, state management, props |
Default to HTML unless the user specifies otherwise.
Module 7: Chart Grid Pattern (from visuals.html)
For dashboards that showcase multiple chart types or let users explore:
| Component |
Purpose |
Implementation |
| Category filter |
Show charts by category |
Button row with colored states |
| Card grid |
Visual index of available charts |
CSS grid, auto-fit, minmax(280px) |
| Mini preview |
Quick visual (130px height canvas) |
Chart.js render at small scale |
| Metadata badges |
"Best for", "Data type" |
Tags below chart preview |
| Modal detail |
Full chart + metadata + examples |
Fixed overlay, arrow key nav |
Module 8: Interaction Patterns
| Pattern |
Trigger |
Effect |
| Hover tooltip |
Mouse over bar |
Show exact value + label |
| Click drill-down |
Click chart item |
Open modal with detail view |
| Filter select |
Click button |
Filter all charts to selection |
| Sort toggle |
Click column head |
Re-sort table ascending/descending |
| Search highlight |
Type in search |
Fade non-matching, highlight match |
| Responsive collapse |
Screen < 768px |
Stack columns, hide secondary charts |
Module 9: 5-Visual Rule (VT BIT 5424)
Executive dashboards follow the 5-Visual Rule:
- 1 KPI row (3-6 metric cards)
- 1 hero chart (the main story)
- 2 supporting charts (different lenses on same data)
- 1 data table (detail on demand)
Maximum 5 visual elements above the fold. More than 5 creates cognitive overload for executive audiences. Analysts get more through drill-down, not more panels.
Anti-Patterns
| Anti-Pattern |
Problem |
Fix |
| Chart soup |
Too many charts with no narrative connection |
Apply 5-Visual Rule, add story arc |
| Dashboard as database |
Every field shown "just in case" |
Show only what answers the KPI questions |
| Inconsistent colors |
Same category = different color across charts |
Use semantic color map (region → color) |
| No drill-down escape |
Modal/detail has no clear close/back |
Always show close button + ESC handler |
| Tiny charts |
Cramming 10 charts into one screen |
Fewer, larger charts with drill paths |
| Static title |
"Revenue Dashboard" |
"Revenue grew 34% -- but growth is slowing" |
1---2name: dashboard-design3description: Dashboard layout patterns, KPI card design, filter architecture, narrative flow through panels, and self-contained HTML generation4---56# Dashboard Design78| Property | Value |9| ------------ | ---------------------------------------------------------------------- |10| **Domain** | Data Analytics |11| **Category** | Dashboard Architecture & Layout |12| **Components** | SKILL.md + dashboard-design.instructions.md + dashboard.prompt.md |13| **Depends** | data-visualization (chart content), data-analysis (KPIs and segments) |1415> **Staleness Watch**: See [EXTERNAL-API-REGISTRY.md](../../EXTERNAL-API-REGISTRY.md) for source URLs and recheck cadence1617## Overview1819Design dashboards that tell stories through layout. A dashboard is not a collection of charts -- it's a guided reading experience where position, size, and interaction design control what the viewer understands and in what order.2021The cardinal rule: **reading order = story order**. KPIs answer "what?", charts answer "why?", tables answer "how much?", and drill-downs answer "show me more."2223## Module 1: Layout Patterns2425| Pattern | Best For | Reading Flow | Use When |26| ----------------- | ------------------------- | ------------------------------------------ | ---------------------------------------------- |27| Inverted Pyramid | Executive dashboards | KPIs → hero chart → supporting → detail | Audience scans from top, drills as needed |28| Z-Pattern | Marketing / consumer | Top-left → top-right → bottom-left → end | Two primary metrics side-by-side |29| F-Pattern | Data-heavy analytics | Left column scanned top-down, right detail | Dense detail dashboards for analysts |30| Hub-and-Spoke | Exploration dashboards | Central question, surrounding perspectives | When multiple equally important views exist |31| Narrative Scroll | Data stories / reports | Top-to-bottom linear reading | Self-contained HTML stories with guided arc |3233### Reference Pattern: Inverted Pyramid (from population.html)3435```36┌────────────────────────────────────────────────────┐37│ HEADER: Title + subtitle + badge │38├────────────────────────────────────────────────────┤39│ KPI ROW: 3-6 cards (auto-fit grid) │40├────────────────────────────────────────────────────┤41│ CONTROLS: Search + filter buttons │42├────────────────────────────────────────────────────┤43│ HERO CHART: Full-width, clickable │44├───────────────────────┬────────────────────────────┤45│ SUPPORTING CHART 1 │ SUPPORTING CHART 2 │46├───────────────────────┴────────────────────────────┤47│ DATA TABLE: Sortable, ranked, inline indicators │48├────────────────────────────────────────────────────┤49│ FOOTER: Data source + attribution + last updated │50└────────────────────────────────────────────────────┘5152 ┌── DRILL-DOWN MODAL ──┐53 │ Detail stats grid │54 │ Horizontal bar │55 │ Detail table │56 └───────────────────────┘57```5859## Module 2: KPI Card Design6061Each KPI card follows the **metric + delta + context** pattern:6263| Element | Purpose | Example |64| ------------ | --------------------------------- | -------------------------- |65| Primary value| The headline number | "334M" |66| Label | What it measures | "Total Population" |67| Delta | Change indicator (arrow + %) | "↑ 2.1% YoY" |68| Sparkline | Trend miniature (optional) | Tiny 30-day line |69| Subtitle | Time range or source | "2024 Census estimate" |70| Icon/Emoji | Visual anchor | "👥" |71| Accent color | Category signal | Brand purple |7273### KPI Selection Rules7475| Rule | Why |76| ---------------------------- | ------------------------------------------------------ |77| 3-6 KPIs maximum | More overwhelms; fewer under-informs |78| Each answers a different "what?"| Redundant KPIs waste prime real estate |79| Include at least one delta | Static numbers lack context |80| Lead with the most important | Top-left KPI gets the most attention |81| Color thresholds if applicable | Green/amber/red for status-driven metrics |8283## Module 3: Filter Architecture8485| Filter Type | Placement | Behavior | Example |86| --------------- | --------------- | ---------------------------------- | ------------------------------ |87| Global filter | Top, below KPIs | Affects all charts and table | Region buttons, date range |88| Chart filter | Inline on chart | Affects only parent chart | Sort toggle, limit slider |89| Cross-filter | Click on chart | Highlights related data elsewhere | Click bar → table highlights |90| Drill-through | Click on item | Opens detail modal or new view | Click state → city breakdown |91| Search | Top controls | Text filter across primary column | Search box for state names |9293### Filter Design Rules94951. Global filters visible at all times (sticky if page scrolls)962. Active filter state clearly indicated (colored buttons, badges)973. "All" or "Reset" always available as first option984. Filter changes animate smoothly (transition: 300ms)995. Filter state reflected in chart titles or subtitles100101## Module 4: Narrative Flow102103The dashboard tells a story through panel arrangement:104105| Layer | Component | Answers | Time to Absorb |106| ----- | ------------------ | -------------------- | -------------- |107| 1 | KPI cards | "What's the story?" | 2 seconds |108| 2 | Hero chart | "Show me the shape" | 10 seconds |109| 3 | Supporting charts | "What else?" | 15 seconds |110| 4 | Data table | "Give me the details"| As needed |111| 5 | Drill-down modal | "Tell me more about X"| On demand |112113### Progressive Disclosure114115- **Above the fold**: KPIs + hero chart (must convey the main story without scrolling)116- **Below the fold**: Supporting views + table (deeper evidence)117- **On demand**: Drill-down modals, tooltips, expandable rows118119## Module 5: Self-Contained HTML Pattern120121Every dashboard outputs as a single HTML file:122123| Requirement | Implementation |124| -------------------------- | ----------------------------------------------------------- |125| Zero build step | Open in browser, no npm/webpack/build |126| Embedded data | JavaScript arrays/objects, not external API calls |127| Single CDN dependency | Chart.js 4.x via jsdelivr |128| Responsive | CSS grid with `auto-fit`, `minmax`, media queries |129| Themeable | CSS custom properties for colors, spacing, fonts |130| Accessible | Semantic HTML, ARIA labels, alt text on charts |131| Print-friendly | `@media print` styles for clean output |132133### CSS Custom Properties Template134135```css136:root {137 --bg-primary: #0f0f23;138 --bg-card: #1a1a2e;139 --text-primary: #e8e8f0;140 --text-secondary: #888;141 --accent-1: #6366f1;142 --accent-2: #3b82f6;143 --accent-3: #10b981;144 --accent-4: #f59e0b;145 --accent-5: #ec4899;146 --border-radius: 12px;147 --shadow: 0 2px 8px rgba(0,0,0,0.3);148 --transition: 0.3s ease;149}150```151152## Module 6: Platform Targets153154| Platform | Output Format | Key Differences |155| ------------------- | ----------------- | ------------------------------------------ |156| **HTML** (primary) | Self-contained | Chart.js + Canvas, embedded data |157| **Power BI** | Report spec | DAX measures, M queries, visual config |158| **Streamlit** | Python app | Plotly charts, st.columns, st.metric |159| **React** | Component tree | Recharts/Nivo, state management, props |160161Default to HTML unless the user specifies otherwise.162163## Module 7: Chart Grid Pattern (from visuals.html)164165For dashboards that showcase multiple chart types or let users explore:166167| Component | Purpose | Implementation |168| ------------------ | ----------------------------------- | --------------------------------- |169| Category filter | Show charts by category | Button row with colored states |170| Card grid | Visual index of available charts | CSS grid, auto-fit, minmax(280px) |171| Mini preview | Quick visual (130px height canvas) | Chart.js render at small scale |172| Metadata badges | "Best for", "Data type" | Tags below chart preview |173| Modal detail | Full chart + metadata + examples | Fixed overlay, arrow key nav |174175## Module 8: Interaction Patterns176177| Pattern | Trigger | Effect |178| --------------------- | ---------------- | ----------------------------------- |179| Hover tooltip | Mouse over bar | Show exact value + label |180| Click drill-down | Click chart item | Open modal with detail view |181| Filter select | Click button | Filter all charts to selection |182| Sort toggle | Click column head| Re-sort table ascending/descending |183| Search highlight | Type in search | Fade non-matching, highlight match |184| Responsive collapse | Screen < 768px | Stack columns, hide secondary charts|185186## Module 9: 5-Visual Rule (VT BIT 5424)187188Executive dashboards follow the 5-Visual Rule:1891901. **1 KPI row** (3-6 metric cards)1912. **1 hero chart** (the main story)1923. **2 supporting charts** (different lenses on same data)1934. **1 data table** (detail on demand)194195Maximum 5 visual elements above the fold. More than 5 creates cognitive overload for executive audiences. Analysts get more through drill-down, not more panels.196197## Anti-Patterns198199| Anti-Pattern | Problem | Fix |200| ---------------------- | -------------------------------------------- | -------------------------------------- |201| Chart soup | Too many charts with no narrative connection | Apply 5-Visual Rule, add story arc |202| Dashboard as database | Every field shown "just in case" | Show only what answers the KPI questions|203| Inconsistent colors | Same category = different color across charts | Use semantic color map (region → color) |204| No drill-down escape | Modal/detail has no clear close/back | Always show close button + ESC handler |205| Tiny charts | Cramming 10 charts into one screen | Fewer, larger charts with drill paths |206| Static title | "Revenue Dashboard" | "Revenue grew 34% -- but growth is slowing" |