The playhead's head is as wide as its number

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Olive Vaughn 2026-10-10 20:38:41 -04:00
parent e72d63214c
commit 285a195fee
2 changed files with 6 additions and 4 deletions

View file

@ -1316,9 +1316,11 @@
to move two elements' `left`. That cost more than painting the frame did and
starved the rAF loop painting it, which ran at 16fps against a 60fps ceiling."
[tag frames]
(let [f @(rf/subscribe [::render/open-frame])]
[tag {:style {:left (edge% f frames) :width (edge% 1 frames)}}
(when (= tag :div.tl-knob) f)]))
(let [f @(rf/subscribe [::render/open-frame])
head? (= tag :div.tl-knob)]
;; The head is as wide as its number needs and never narrower than the frame.
[tag {:style {:left (edge% f frames) (if head? :min-width :width) (edge% 1 frames)}}
(when head? f)]))
(defn- outside-marks
"The frames playback leaves out, shaded, and the span it plays, banded on the