Session 26: Cross-sport tab counts, scan copy fix, game card visual polish, empty section auto-hide (1579 tests)

This commit is contained in:
Kev
2026-06-12 20:18:55 -04:00
parent 956cdb863a
commit f8a51cd9d0
8 changed files with 164 additions and 31 deletions
+56
View File
@@ -4,6 +4,62 @@
2026-06-12
## Current Phase
SHIP BUILD v26.0 — Cross-sport tab counts, scan copy, game-card visual polish, empty-section auto-hide (Session 26)
## Session 26 (2026-06-12) — SHIPPED
Finished making every sport visible and polished the presentation. Traced
the MLB/WNBA "no count" symptom to its real cause before touching code.
Backend unchanged: **1579 tests**, 125 suites, zero regressions. Web build
clean.
### PHASE 1 — MLB/WNBA tab counts (traced)
- TRACE: hit ESPN live — MLB returns 15 events, WNBA 2, with exactly the
shape `scheduleService.normalizeEvent` expects. The backend was correct;
Session 25's proxy fix already unblocked the data flow.
- Real gap: the Slate's tab counts were derived ONLY from the active tab's
loaded games, so a sport showed no count until you clicked its tab.
- FIX: a mount-time effect fetches schedule counts for nba/wnba/mlb (free,
cached) so every tab shows "MLB (15)" / "WNBA (2)" regardless of which
tab is active. `tabCount` prefers loaded data, falls back to the count.
### PHASE 2 — Scan copy
- Removed "Books usually open player props 23 hours before tip" from
`scan/page.tsx` and `game/[id]/page.tsx` (we don't assume book timing).
Kept Features' "30 min before tip" — that's a lineup-intel claim, not a
book-line timing assumption.
### PHASE 3 — Game-card visual polish
- Header: 18px/800 abbreviations, 16×20 padding for breathing room.
- Game-lines strip: aligned 4-column grid (book · away · home · O/U) with
em-dash placeholders, more padding.
- Inline streaks: accent-colored label + subtle red gradient wash, premium.
- Empty-props line: smaller, left-aligned, dimmed — informational, not an
error wall.
- Verified StatFilterPills (filled active pill) and the Hero sport-badge
strip (active filled / coming-soon dimmed, all 9 sports) already match
the design spec; notice banner already neutral (no red).
### PHASE 4 — Empty-section auto-hide
- "Most parlayed tonight" now hides entirely when loaded-but-empty instead
of showing a "be the first" prompt (dead space on a fresh platform).
### PHASE 5 — BACKEND_URL (verified)
- All proxies (new + odds) default to `http://localhost:3000`, consistent
with `odds-cache.ts`. Prod sets `BACKEND_URL`; the new routes inherit it.
No change — deliberately kept consistent with the working odds proxies
rather than introducing a 3001 default that would diverge from them.
### Files modified
- `web/src/components/Slate.tsx` (schedule-count effect, tabCount fallback)
- `web/src/components/GameCard.tsx` (header, lines strip, streaks, empty)
- `web/src/app/scan/page.tsx`, `web/src/app/game/[id]/page.tsx` (copy)
- `web/src/app/dashboard/page.tsx` (auto-hide Most-parlayed)
---
## Previous Phase
SHIP BUILD v25.0 — Fix every data-rendering bug: the frontend now actually SHOWS the backend's data (Session 25)
## Session 25 (2026-06-12) — SHIPPED