Populate clues[] for every Continuum scenario (afterimage, day-one, vain-crown, silvery-moon, chopper, princes-bride), transcribed faithfully from the gm-utility console sources (CLUES arrays, gbclue GM-brief spines, and the princes-bride module). The Slice 4 clue safety-net now works against real content — essential-gap banner, act labels, and fallbacks. day-one and princes-bride carry the source's own essential/optional split; the four GM-brief spines mark each tracked clue essential (single curated list, no optional tier in-source). tests/scenarios/clues.test.js guards shape, unique ids, and solvability. 129 tests pass; build clean. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
4.3 KiB
The Director — Slice 5 Implementation Plan
Goal: Add the convention hub — a landing screen listing every slot of a convention with live "live now / up next / done / upcoming" status, that deep-links into each ported scenario and lets the GM return to the hub from a running session.
Architecture: Same pattern as the other slices — a pure engine (analyzeSchedule) that classifies
slots from a wall-clock now, a <con-hub> light-DOM component that renders the slot list + summary
and emits open-scenario, a scenario registry (src/scenarios/index.js) resolving a slot's
scenarioId to its module, and shell routing that switches between the hub and a session (hiding the
Rail/stage in hub mode) plus a 🏠 rail chip to return. No fabricated content: only AFTERIMAGE is
ported, so continuum-2026.js marks the other four slots scenarioId: null ("Not yet ported") with
startsAt: null (times TBC, not invented); a clearly-labelled example-con.js provides fully-timed
slots as the demo/test fixture.
Tech Stack: JavaScript (ES modules, no TypeScript), Web Components (light DOM), Vite, Vitest + jsdom. No new dependencies. Fully offline.
Global Constraints
- Offline-first, no runtime framework, light DOM, no TypeScript.
- Con model:
{ meta: { id, title }, slots: [ { id, scenarioId, title, slot, system?, players?, playMinutes?, startsAt? } ] }.slotis the display label;startsAt(ISO) drives timing;scenarioIddeep-links via the registry (null ⇒ not yet ported). A null/absentstartsAt⇒ unscheduled: listed, never live/next. - Determinism:
analyzeSchedule(slots, nowMs)is pure;<con-hub>takes an injectednow()like the shell. - Escaping: all author text (titles, slot labels, systems) via
escapeHtml. - Rail invariant preserved: the hub is a pre-session screen; the Rail is hidden in hub mode and restored (never removed) when a session is open.
Tasks (all complete)
- Schedule engine —
src/con/schedule.js(analyzeSchedule,slotStartMs) +tests/con/schedule.test.js(6). - Scenario registry —
src/scenarios/index.js(SCENARIOS,getScenario) +tests/scenarios/registry.test.js(2). <con-hub>component —src/components/con-hub.js+tests/components/con-hub.test.js(6).- Con data —
src/con/continuum-2026.js(real slate, honest placeholders) +src/con/example-con.js(template/fixture). - Shell + rail wiring —
gm-shell.js(loadCon/showHub/showSession/onOpenScenario,open-hub),director-rail.js(🏠 chip),styles.css, boot inmain.js→loadCon(continuum2026)+tests/components/gm-shell-hub.test.js(4).
Validation
npm test→ 122 passing (34 files); build succeeds (35 modules). Manual: hub renders the Continuum slate, "Open" deep-links AFTERIMAGE into a live Rail session, 🏠 returns to the hub. Console clean.
Follow-up (completed after the slice)
-
All six Continuum 2026 slots ported + scheduled.
continuum-2026.jsrewritten from the authoritativecon-desk.htmlSLOTS array (real days/times/systems), everystartsAtset so live/up-next is live. Five new scenario modules (day-one,vain-crown,silvery-moon,chopper,princes-bride) transcribe their timelines from the existing gm-utility consoles and are registered;tests/con/continuum-2026.test.jsguards resolvability + schedule.- Correction found while porting: the real slate is six slots (Slot 5 Silvery Moon was missing from the first hub draft), and "Another Fine Mess" is Get to the Chopper — Another Fine Mess.
-
All six scenarios' clue trails ported into the data model (transcribed from the console
CLUES/gbclue/module sources viaextract-clues.mjs), so the Slice 4 safety-net now works against real content.tests/scenarios/clues.test.jsguards shape + solvability. The four GM-brief-sourced trails (afterimage, vain-crown, silvery-moon, chopper) mark every tracked clueessential: true(their source is a single curated spine); day-one and princes-bride carry the source's own essential/optional split.
Still deferred (backlog)
- Porting each scenario's cast into the data model (still
cast: []). - A dedicated BRP dice pack — Day One currently borrows
coc-d100(d100 roll-under).