Skip to content

fix(ui): clamp short search rows before selecting visible range - #47

Merged
xiaoyumuxi merged 1 commit into
mainfrom
codex/2199-list-clamp-release
Nov 19, 2026
Merged

xiaoyumuxi merged 1 commit into
mainfrom
codex/2199-list-clamp-release

Conversation

@xiaoyumuxi

Copy link
Copy Markdown

Problem

A single large wheel event can leave a short-row List blank at the end. List picks the visible rows from the newly measured extent while the scroll offset still belongs to the previous estimate.

Change

Clamp the scroll offset before selecting the visible range. Keep the pinned/follow-to-end branch unchanged. Add a headless 400 × 24 px regression which fails before the fix and passes after it. This is required by the compact grouped search results in 1lck/Lithe-IDEA#2199.

The same patch is submitted upstream: vivaui#357.

Validation

  • go test ./ui ./base -race -count=1: passed on macOS arm64 against the fork base.
  • Upstream branch go vet ./...: passed.
  • Upstream go test ./... -count=1: all packages except cmd/viva passed. Its packaging fixture expects macOS 12.0 while this machine links 13.0; setting MACOSX_DEPLOYMENT_TARGET=12.0 did not resolve that fixture mismatch.
  • BenchmarkList100k: median 19.47 µs before / 18.66 µs after, 0 allocs/op (3 short 100-iteration samples on Apple M4). No observed regression; no speedup claim.
  • Windows native UI remains unverified.

This PR contains only the list fix; upstream synchronization and updating Lithe's Viva pin are separate release prerequisites.

@xiaoyumuxi
xiaoyumuxi marked this pull request as ready for review November 19, 2026 17:02
@xiaoyumuxi
xiaoyumuxi merged commit c7bffdd into main Nov 19, 2026
12 of 14 checks passed
@xiaoyumuxi
xiaoyumuxi deleted the codex/2199-list-clamp-release branch November 19, 2026 17:05
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