Repository navigation
Let a screenshot pair written in markup open on its change, and catalog the page of parts - #6772
Merged
Merged
Conversation
…og the page of parts `lf-shot` takes `focus-x`, `focus-y`, `focus-width` and `focus-height`, a region in the captures' CSS pixels that every view opens cropped to, and `density`, the captures' device pixel ratio, so the region is read in CSS pixels and 100% shows a 2x capture at its size in the browser. The crop, the scale and the Full frame toggle already lived in `lf-shot`, but only `lf-visual-review` could reach them, through `inspect()`. The widget now writes each case's `focus` and `deviceScaleFactor` onto its shot's attributes like any author, and `inspect()` is gone with the `labels` and `captureWidth` it carried, which nothing passed; the test step that set long custom labels at phone width goes with them. The author states the region rather than `lf-shot` deriving it from the comparison: the comparison runs after presentation, so a derived crop would resize a shot the reader already sees, and its bounds take in everything that moved, such as every row under one that grew. Four attributes rather than one list let shot.css hold the cropped frame's room before the module draws, since typed `attr()` reads one number per attribute; the hold also divides by `density`. The page of parts (examples/review-parts) joins the catalog: six cases of a console change, one part each, every capture opening on its change at true scale with its question's options in a 1440x900 window. The feature gallery shows a focused pair in Pair. Tests: a new browser test holds a focused and a 2x shot's drawn heights before upgrade (it fails on the old stylesheet); the cropped-inspection test now drives the attributes, restates and removes the focus; the visual-review focus tests pass unchanged, and the widget's six cases measure the same frames on main and this branch in Firefox.
The run list, its dark scheme and the run page each put their change in the frame's left half, where Slider's divider shows only Before on arrival. They open in Pair, the run lists on a focus narrowed to Run, Status and Trigger so both captures stand side by side at true scale. > _This was written by Claude Code on behalf of max-sixty_
> _This was written by Claude Code on behalf of max-sixty_
…ept densities below 1 The comparison reads whole images, so a new focus or density reuses the reading already shown and draws before the next frame instead of waiting for another comparison of the same pair. The number patterns accept any positive value, as the module does. The evidence reference sends a small change's pair to its subject rather than to cropped files, and the author text says the focus lies inside both captures. The hold test takes the focused and 2x shots as two more cases rather than a copy of its setup. > _This was written by Claude Code on behalf of max-sixty_
Before its module draws, a shot holds the room Slider's frame takes, and Pair's stacked layout draws taller: on the page of parts, a reload on the dark run list at a 390 px phone moved the options down 279 px as the module drew, and on the run page at 1440 x 900 by 252 px, in Firefox and Chromium alike. Each focused pair on the page of parts and in the feature gallery now opens in Slider, on a focus whose divider falls where the change begins, so the After half shows it on arrival. Held and drawn heights now agree for every part at 1440 x 900 and 390 x 844 in both engines. > _This was written by Claude Code on behalf of max-sixty_
> _This was written by Claude Code on behalf of max-sixty_
max-sixty
marked this pull request as ready for review
November 23, 2026 04:03
leaf-agent
approved these changes
Nov 23, 2026
max-sixty
added a commit
that referenced
this pull request
Nov 23, 2026
Removes the bundled `visual-review` package: the `lf-visual-review` widget, its `visual-run` contract, gallery, package card, the two eval variants that asked for it, and every reference. Nothing in Leaf writes a `visual-run`, and since #6772 a visible change goes to the user as before/after `lf-shot` pairs with a question beside each, as `examples/review-parts.html` shows. A user loses the one-case-at-a-time queue with its progress count and keys (n, Shift+n, a, i, c); the Capture details popover with capture conditions, revisions and links to the before and after pages; a typed run an agent refreshes with `leaf data set` while approvals and threads stay on stable case ids; and a two-key reopen of an answer, which takes nine on the page of parts. Not visible in the diff: tests that proved core guarantees through the widget are ported, not deleted, to plain `lf-shot`s, `lf-diff`, `lf-trace`, test widgets and the page of parts. Per-record obligations (`awaits.records`) now have no bundled user; they stay, covered by a fixture package, as a separate removal candidate. Tests: the ported and touched tests pass locally, as does `pnpm run check`; CI runs the broad suite. > _This was written by Claude Code on behalf of max-sixty_
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A screenshot pair written in markup can now open on its change:
lf-shottakesfocus-x,focus-y,focus-widthandfocus-height, a region in the captures' CSS pixels, anddensity, their pixel ratio. The crop, scale and Full frame toggle already lived inlf-shotbut onlylf-visual-reviewreached them, throughinspect(); the widget now writes its cases' focus and scale onto its shots' attributes, andinspect()goes, withlabels, which nothing passed, andcaptureWidth. The page of parts joins the catalog, each case opening on its change at true scale with its options in a 1440×900 window.To weigh: four attributes rather than one
focus="x y w h", so shot.css can hold the cropped frame's room before upgrade (typedattr()reads one number per attribute); with one list, the parts page's first shot would hold 772 px and shrink to 402 px as it draws. That hold models Slider only, so a stacked Pair still grows as its module draws (279 px measured at phone width); the example pairs open in Slider.Tests: hold, focus and visual-review browser tests,
check:browser; scored on Claude Code,visual-change-uses-captures0/1 → 2/2,shot-frames-read-at-size1/1 → 2/2.