Repository navigation
Synchronize expanded drawing layout updates - #674
Conversation
jserv
left a comment
There was a problem hiding this comment.
Clarify what prevented scripts/test.sh from completing, resolve the local Python/task-tools setup issues, and rerun the full test suite so we can confidently verify the changes.
There was a problem hiding this comment.
Reviewed 8ad41ac on Ubuntu with Node.js v22.23.4 and npm 10.9.9.
Ran:
node --test tests/browser/interview-layout.test.js tests/browser/example-board.test.js tests/browser/example-board-ui.test.js
Result: 56 passed, 0 failed, 0 skipped.
The two inline suggestions concern regression coverage for synchronous shrink behavior: Jim's stage restoration and horizontal scroll restoration. For each, an immediate assertion passed on the original implementation and failed with the corresponding update deferred.
The full scripts/test.sh gate was not run. All temporary local changes were restored.
8ad41ac to
5479d46
Compare
|
Rebased on upstream |
Shrinking the Example drawing relies on observer microtasks running before scroll restoration. Notify the drawer and Jim's stage directly so the docked height is measured before restoring scroll, including after a resize while expanded. Keep the layout unchanged and check that the updates finish synchronously. Close sysprog21#641 Change-Id: Ie4c4deaf15d7942c276b53dc1c6f3be8cf296a2c
5479d46 to
5362abe
Compare
|
Thank @Ericko00o for contributing! |
Shrinking the Example drawing after a viewport resize can clamp the saved scroll position if it is restored before the drawer measures the docked height. An optional synchronous callback updates the drawer and Jim's stage on expand and shrink, so the docked height is ready before scroll restoration. This removes the two observers on
data-expanded. The stage returnsfitfor #713 to use; itshiddenobservers are still needed for the ending and report overlays.Validation: all 62 focused Chromium tests passed. Five separate delay probes failed at the intended assertions for stage layout, Escape, horizontal scroll, outer panel scroll, and programmatic
shrink(). The Rust gate passed on the current head with a receipt (optionalcargo-denyskipped). The prior fullscripts/test.shran on Linux before the rebase onto the gate evidence workflow: the static browser suite had 3,451 passes and 30 skips (Java and ffmpeg unavailable). Four tooling gates failed locally and reproduced on upstreammainat 21c45b1 in the same environment.Close #641
Summary by cubic
Synchronizes expanded drawing layout updates so shrinking the Example drawing measures the docked height before restoring scroll, fixing the strip's scroll position after a resize while expanded.
data-expandedmutation observers andqueueMicrotaskinshrinkBoardwith a new synchronousonExpandedChangecallback that runs the drawer'spaintand Jim'sfitJimStagebefore scroll restoration.mountInterviewDrawerandcompactJimStageBesideNarrowPanelnow returnpaintandfitso callers can invoke them directly;mountExampleBoardaccepts the newonExpandedChangeoption.Closes #641.
Written for commit 5362abe. Summary will update on new commits.