notepat: smooth continuous drift on spacebar — no layout jump
Rewrote sound.speaker.drawStrip (C) and its JS call site to replace the
half-strip-flipping reverse flag with a continuous `viewOffsetSec`
cursor model. On spacebar press/release the waveform now drifts
smoothly between directions instead of snapping across the needle.
New semantics (matches user's mental model: "needle is what plays the
audio", drift backwards on space hold, drift forwards on release):
drawStrip(x, y, w, h, seconds, needleFrac, viewOffsetSec)
viewOffsetSec = 0 → cursor sits at live capture edge
past extends LEFT of needle
right half stays empty
wave drifts LEFT each frame (natural)
viewOffsetSec > 0, growing → cursor retreats into past
left half: samples before cursor
right half: samples captured AFTER cursor,
proportional to offset
wave drifts RIGHT
viewOffsetSec shrinking → cursor catches back up to "now"
wave drifts LEFT faster than normal
right half empties as we converge
notepat.mjs sim() advances the offset at 1× real-time while spaceHeld
(natural-speed backwards scrub), and retreats it at 2× on release
(snappy catch-up). Cap at 2.0 s so the right half fully fills at the
limit. Needle tints orange-ish when offset>0 so the replay mode is
still visually distinct without any layout jump.
Also: revert QR to scale=1 (25×25 px) — user wanted more space BELOW
the QR in the top bar, not a bigger QR itself. Keep topBarH=54 for
the breathing room, reset qrW back to 28 px.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>