Skip to content

feat(player): play guides like narrated videos - #5

Merged
djdevpro merged 1 commit into
mainfrom
feat/player-screen-padding
Nov 20, 2026
Merged

djdevpro merged 1 commit into
mainfrom
feat/player-screen-padding

Conversation

@djdevpro

Copy link
Copy Markdown
Owner

The player can now show a guide like a narrated screen recording.

What changes

  • Browser window: frame="browser" shows the video in a macOS browser window, with the page address of each step in its title bar. The screen gets 12 px of room (--il-screen-padding).
  • Clean corners: one antialiased cut (clip-path plus a plain mask) rounds the whole stage. Chrome clipped the composited screenshot with the outer curve of the window, over its border, so a dark page poked out of the corners at a 1.5 pixel ratio.
  • Zoom toward the click: a step with zoom (1 to 4) closes in on its click while the cursor gets there, holds, then goes back before the markers appear.
  • Camera framing: action that sits low on screen, under the captions and the controls, is lifted toward the middle by a closer frame (up to 1.45×), never past the screenshot. The camera glides from one framing to the next.
  • Voice over: a story line can carry audio. It plays in step with the guide (pause, seek, speed), behind a speaker button; muted starts without it.
  • Captions: a voiced line can carry its words with their timing. They show over the screen a few at a time, white with a dark outline, each lit when it is said, above the controls or near the edge when the controls fade. The story under the screen then gives way to them (screen readers keep it).
  • Narrow players: the arrow, the markers and the click ripple shrink with the player (down to 60 %) and keep their place.

The protocol keeps zoom, audio and words, with tests. The changeset bumps the player and the recorder (minor).

Checks

  • vitest: protocol and player tests pass; tsc --noEmit passes for both.
  • Corners checked pixel by pixel at 1 and 1.5 pixel ratios, with and without the window.
  • Played in a browser on a 27-step guide with an ElevenLabs voice over: voices load and play after Play, captions follow them.

🤖 Generated with Claude Code

A guide now reads like a screen recording with a voice over:

- frame="browser" puts the video in a macOS browser window, with the
  address of the page in its title bar, and the screen gets room
  around it (--il-screen-padding).
- One antialiased cut rounds the stage. Chrome clipped composited
  layers with the outer curve of the window, over its border, and a
  dark page poked out of the corners.
- A step can zoom toward its click (zoom), and the camera frames each
  step: action low on screen, under the captions and the controls, is
  lifted toward the middle, within the screenshot.
- A story line can carry its voice (audio), played in step with the
  guide, and its words with their timing, shown over the screen as
  captions lit as they are said, above the controls or near the edge
  when they fade.
- The arrow, the markers and the click ripple shrink with a narrow
  player and keep their place on the screenshot.
@djdevpro
djdevpro merged commit b51f722 into main Nov 20, 2026
2 checks passed
@djdevpro
djdevpro deleted the feat/player-screen-padding branch November 20, 2026 02:48
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