Conversation
Adds an auto-piloted walkthrough triggered by appending ?demo to the URL, plus a Playwright-based recording driver. Used to produce a short demo video showing scenario → values → side-by-side compare with view-transition morphs between screens. Implementation: - guide.js exposes a window.__demo hook (gated on ?demo) and adds the 3↔5 step pair to the morph list so the Personal Values → Compare jump animates smoothly. - demo.js polls for the hook, scripts goToStep/setValue with timed waits, shows a title intro, and signals completion via body.dataset.demoDone. - demo.css hides the top nav / TOC / Back-Next buttons, flattens the background gradient (compresses better), centers headers, and slows view-transition animations to 1.4s so the morph reads on video. - index.html gates demo.js loading on ?demo and sets html.demo + the flat background synchronously so the page never flashes the gradient. - record_demo.py serves static/ on a local port, drives Playwright at logical 1280×600 with DPR=3 (true 4K bitmap), waits for the demo to signal done, and trims the first 0.5s with ffmpeg so the title is on frame 0. Outputs are gitignored.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds an auto-piloted walkthrough activated by appending
?demoto the URL, plus a Playwright-based recording driver. Used to produce a ~22 s 4K demo clip stepping through scenario+baseline → values → side-by-side compare, with view-transition morphs between screens.The mode is gated entirely on the
?demoquery — zero impact on normal users visiting the site.What's in the commit
static/demo.js(new, ~30 lines) — drivesgoToStep/setValuewith timed waits, shows the title intro, signals completion.static/demo.css(new, ~50 lines) — hides top nav / TOC / Back-Next; flat background; centered headers; bumps view-transitionanimation-durationto 1.4 s so the morph reads on video.record_demo.py(new) — servesstatic/on a local port, runs Playwright at logical 1280×600 with DPR=3 (true 4K bitmap), trims first 0.5 s with ffmpeg so the title is on frame 0.static/index.html— gatesdemo.jsimport on?demo; setshtml.demo+ flat background synchronously so the page never flashes the gradient.static/guide.js— exposeswindow.__demohook (gated on?demo); adds 3↔5 to the `isMorph` list so Personal Values → Compare animates smoothly..gitignore— excludes `spark-demo-*.{mp4,webm}` outputs and `_video/` temp dir.README.md— "Recording a demo clip" section.Test plan