Skip to content

Demo, from David's evening review: one click in, start over, the bubble beside the simulator, a steady chase camera, CodeSpace's rail - #127

Merged
david-firia merged 3 commits into
mainfrom
demo-polish
Nov 25, 2026
Merged

david-firia merged 3 commits into
mainfrom
demo-polish

Conversation

@david-firia

Copy link
Copy Markdown
Contributor

From David's evening review of the demo (Nov 24), all six points, in two commits.

Demo and rail (first commit)

  • One click (1). Try a Demo! opens the demo's first step at once, with no opening card to click past. "Meet CodeBot!" moved into the first step's words. A journey started with now skips its opening card; other journeys keep theirs.
  • Start over or carry on (2). Tried before and left part way, Try a Demo! asks "Start the demo over?": Start over goes to the first step, in blocks (a student who went on to Python is taken back), Carry on goes to where they were. A finished demo starts over without asking, as there is nothing to carry on.
  • The bubble beside the simulator (3). "Meet CodeBot" and its "Nice view!" sit to the left of the simulator, pointing right, clear of its buttons and the terminal. A phone has no room there, so it stays below.
  • No Done after the palette (5). A step may be onward: once met it goes straight on, with no Next. The demo's "Open Lights" is one, so the "drag the LED block in" bubble comes at once. In Python, Lights stays open and the step points straight at the card.
  • The rail, as CodeSpace's (6). The pack's picture with its name alone as the tooltip ("BitsWorkbench demo"), the mission's with its name ("Drive CodeBot"), no Mission 1. Then every objective's number: a green check in the corner of a done one, a grey number with a lock in the corner of a locked one, the objective's name as the tooltip. Screen readers still hear what each does.

Simulator (second commit)

  • The chase camera lurched (4). The cause was not the camera alone: the robot itself was drawn between the two newest snapshots by when each arrived. Snapshots come about every 16 ms but unevenly, and a screen frame may get none or two, so a steady drive sped up and stalled by turns. The chase camera, following it with two per-frame lerps at different rates, made the whole room lurch with it. It was the same before Simulator: sharp from the first frame on a capable machine; the demo watches CodeBot's front #125; the demo's chase view made it obvious. Now:

    • the robot is drawn on a playout clock in simulated time, about two snapshots behind the newest, running at the simulation's measured pace;
    • chase eases after the robot's place and heading by time, on the screen's clock, and sits rigidly at its offset from that eased pose, as Babylon.js's FollowCamera does.

    Measured on a 4 s drive at 60 frames a second:

    main this branch
    robot speed, frame to frame 52% 2%
    frames with the robot's step off by over a third 41 of 96 0 of 97
    camera aim, frame to frame 8% 1%
  • The settings panel grew and shrank (4). Its frame-rate line changes words as drawing starts and rests, sometimes wrapping to a second line. The panel is anchored at its foot, so it grew and shrank (358 to 362 px). The line now always keeps two lines.

Tests. learn-demo updated for the new flow, with new checks for start over and carry on, the bubble's side, onward, and the rail's badges. sim-ui gains a steady-drive check in chase and a panel-height check: both fail on main and pass here. Locally learn-demo (laptop and phone width), learn-pack, learn-checks, i18n, learn-journey, learn-guided and learn-ui pass; the rest are running in CI.

🤖 Generated with Claude Code

david-firia and others added 3 commits November 24, 2026 17:51
…on, the bubble beside the simulator, no Done after the palette, CodeSpace's rail

- Try a Demo! opens the demo's first step at once: no opening card to click
  past (its "Meet CodeBot!" is now the first step's words). A journey started
  with `now` skips its opening card; others keep theirs.
- Tried before and left part way, Try a Demo! asks: Start over (the first
  step, in blocks, a student who went on to Python taken back) or Carry on
  (where they were). Finished, it starts over without asking.
- The coach's bubble for the simulator sits to its left, pointing in, clear of
  the simulator's buttons and the terminal, where there is room (a phone has
  none: below, as before).
- A journey step may be `onward`: met, straight on to the next step, no Next.
  The demo's "Open Lights" is one, so the next bubble (drag the LED block in)
  comes at once.
- The guided rail, as CodeSpace's: the pack's and the mission's pictures, each
  with only its name as a tooltip ("BitsWorkbench demo", "Drive CodeBot"), no
  Mission 1; every objective's number, a green check in the corner of a done
  one, a lock in the corner of a locked one (grey), its name as the tooltip.
  Screen readers still hear what each does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…, chase glides after it, the settings panel keeps its size

- The robot is drawn on a playout clock in simulated time, about two
  snapshots behind the newest, at the simulation's measured pace, between
  the snapshots either side. Drawn by when each snapshot arrived, as before,
  a steady drive varied by half its speed from frame to frame (four frames in
  ten a third off); now by 2%, none off.
- Chase eases after the robot's place and heading by time, on the screen's
  clock, and sits rigidly at its offset from the eased pose (as Babylon.js's
  FollowCamera): one easing rather than two per-frame lerps at different
  rates. Camera and aim now vary by 1% on a steady drive.
- The settings panel's frame-rate line keeps two lines whatever it says, so
  the panel, anchored at its foot, no longer grows and shrinks as drawing
  starts and rests.
- sim-ui checks both: a 4 s drive in chase, measured frame by frame, and the
  panel's height with each wording.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…it leaves the simulator at 4x)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

Visit the preview URL for this PR (updated for commit 77686f4):

https://firialabs-open-editor--pr127-demo-polish-ggtqg1wu.web.app

(expires Wed, 02 Dec 2026 00:11:33 GMT)

🔥 via Firebase Hosting GitHub Action 🌎

Sign: 81259a1fec315ca1af3747d225d9c7424890be3e

@david-firia
david-firia merged commit 51f2268 into main Nov 25, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant