A web-based race day command center for backyard ultra running.
Three primary user types with different access patterns and capabilities.
Primary user. Logs completed laps with nutrition data (carbs, fluids, sodium, caffeine, protein, fiber). Tracks mood, run time, and pace targets. Views real-time dashboard with pace totals, cumulative nutrition bars, and remaining race time. Can end race and view race recap. Sees crew alerts and social feed cheers.
Supports the runner. Receives "runner in" notifications via Realtime broadcasts. Runs crew checklist, triggers crew alerts, views decision tree troubleshooting flowchart. Can manually log nutrition if runner forgets. Handles admin tasks like adjusting targets for weather conditions. Views crew dashboard with alerts and progress tracking.
Read-only observer. Sees live race feed with lap completions, nutrition summaries, and milestone updates. Can send cheers and emojis for encouragement. Views public race progress, finisher status, and live commentary. No data entry capabilities. Gets basic spectator privacy controls.
A quick snapshot of the system at a glance.
Six horizontal layers, top to bottom. Each depends on the layer below it. Data flows down through requests, back up through responses.
42 HTML pages grouped by category. Active V3 pages are production interfaces. Specialized pages handle specific workflows. Legacy pages are v1/v2 interfaces still deployed.
| File | Module | Lines | Purpose |
|---|---|---|---|
| index-v3.html | index-v3.js (232L) | ~560 | Command Center dashboard |
| race-day-v3.html | race-day-v3.js (2,794L) | ~1,321 | Core race logging interface with dashboard, crew alerts, nutrition tracking, social feed |
| plan-v3.html | plan-v3.js (410L) | ~787 | Race plan wizard with nutrition targets, pacing strategy, fuel menu setup |
| analysis-v3.html | analysis-v3.js (991L) | ~650 | Post-race analysis charts and insights |
| compare-v3.html | compare-v3.js (846L) | ~500 | Multi-race comparison and historical analysis |
| practice-v3.html | practice-v3.js (663L) | ~500 | Training session tracker for practice runs |
| conditions-v3.html | conditions-v3.js (586L) | ~400 | Weather adjustments and target recalculation |
| settings-v3.html | settings-v3.js (344L) | ~830 | User settings and profile configuration |
| profile-select-v3.html | profile-select-v3.js (663L) | ~560 | Profile selection and role switching |
| File | Purpose |
|---|---|
| bibboard.html | Bib number and race number display, often used on secondary monitor |
| crew-troubleshoot.html | Crew troubleshooting decision tree (decision-tree.js, 2,010L) |
| fuel-menu.html | Quick fuel button setup and customization |
| gps-planner.html | GPS route planning and course mapping |
| monitor.html | Live race monitoring dashboard for organizers |
| live-race.html | Spectator view with read-only race progress |
| admin.html | Admin panel for system management |
Approximately 21 legacy pages from earlier versions still deployed. These are gradually being replaced by v3 interfaces but remain for backward compatibility.
41 services organized by domain. Each service encapsulates specific business logic, data operations, and integrations.
11 SQL migrations create the database structure. Tables are organized into core (runtime), supporting (configuration), and social (community) domains.
1. Product DB (sweat-data.js) → 2. Race Plan Wizard creates templates → 3. fuel_items table stores custom items → 4. Race Day UI loads items via loadFuelItems() → 5. Fuel tap builds selectionTotals → 6. confirmAndLog validates nutrition targets → 7. logLap writes to laps table → 8. getLaps retrieves for dashboard → 9. Dashboard bars display cumulative totals
21 CSS files organized by feature area. All styling flows from a unified token system: primitives.css → semantic.css → specialized feature stylesheets.
Listed by line count. Larger stylesheets handle more complex UI areas.
| File | Lines | Domain |
|---|---|---|
| crew-dashboard.css | 4,365 | Crew monitoring and alerts |
| race-day-v3.css | 2,511 | Main race day interface |
| components.css | 1,426 | Component base styles |
| features.css | 960 | Feature-specific styles |
| analysis.css | 946 | Analysis and charts |
| accessibility.css | 782 | A11y and contrast rules |
| monitor.css | 791 | Race monitoring view |
| planner.css | 666 | Race plan wizard |
| layout.css | 607 | Layout primitives and grid |
| experimental.css | 585 | Experimental features |
| debrief.css | 567 | Post-race debrief UI |
| realtime.css | 379 | Realtime update animations |
| skeletons.css | 337 | Loading skeleton screens |
| conditions.css | 312 | Weather conditions UI |
| index.css | 253 | Command center dashboard |
| fonts.css | 54 | Font declarations |
Every known limitation, risk, and missing feature organized by severity. Derived from actual code inspection, not guesswork.