Repository navigation
Fix Virtualize jumping away rom the bottom - #69926
Merged
ilonatommy merged 4 commits intoOct 23, 2026
Merged
Conversation
…ry and assert that stale anchor correction cannot undo the bottom pin.
…res the scroll position. Check again after restoration so the last items are loaded instead of leaving blank space at the bottom.
ilonatommy
marked this pull request as ready for review
October 20, 2026 10:57
ilonatommy
requested review from
dariatiurina
and
a balanced review from Copilot
October 20, 2026 10:57
Contributor
There was a problem hiding this comment.
🔵 Needs a closer look
Timing-sensitive observer and interop behavior still needs real-browser regression verification.
No open issues 🎉
What changed in this PR
Fixes Virtualize end anchoring so loading older history does not undo bottom scrolling, and retries viewport filling suppressed during anchor restoration.
Changes:
- Clear stale scroll corrections after pinning to the bottom.
- Refresh spacer observation when viewport-fill requests were deferred.
- Add a browser regression scenario for sorted history loading.
| File | Description |
|---|---|
src/Components/Web/src/Virtualization/VirtualizeJsInterop.cs |
Pass the viewport-refresh flag to JavaScript. |
src/Components/Web/src/Virtualization/Virtualize.cs |
Track deferred viewport-fill requests. |
src/Components/Web.JS/src/Virtualize.ts |
Reset stale corrections and refresh spacer observation. |
src/Components/test/testassets/BasicTestApp/VirtualizationEndAnchorHistory.razor |
Add a sorted-history test scenario. |
src/Components/test/testassets/BasicTestApp/Index.razor |
Register the new scenario. |
src/Components/test/E2ETest/Tests/VirtualizationTest.cs |
Detect bottom-pin rollback in browser coverage. |
Review effort: Balanced
dariatiurina
approved these changes
Oct 21, 2026
dariatiurina
left a comment
Contributor
There was a problem hiding this comment.
Looks good, the only question is test. It's a bit hard to read
Co-authored-by: Copilot App <[email protected]> Copilot-Session: aff37fd2-5a5e-43e4-a438-446e4254957b
ilonatommy
enabled auto-merge (squash)
October 21, 2026 16:30
dariatiurina
approved these changes
Oct 23, 2026
ilonatommy
disabled auto-merge
October 23, 2026 16:57
ilonatommy
temporarily deployed
to
copilot-pat-pool
October 23, 2026 16:57 — with
GitHub Actions
Inactive
Member
Author
|
/backport to release/11.0 |
Contributor
|
Started backporting to |
ilonatommy
temporarily deployed
to
copilot-pat-pool
October 23, 2026 16:57 — with
GitHub Actions
Inactive
5 of 11 tasks
ilonatommy
temporarily deployed
to
copilot-pat-pool
October 23, 2026 16:58 — with
GitHub Actions
Inactive
ilonatommy
temporarily deployed
to
copilot-pat-pool
October 23, 2026 17:00 — with
GitHub Actions
Inactive
ilonatommy
temporarily deployed
to
copilot-pat-pool
October 23, 2026 17:01 — with
GitHub Actions
Inactive
ilonatommy
temporarily deployed
to
copilot-pat-pool
October 23, 2026 17:02 — with
GitHub Actions
Inactive
Contributor
|
✅ No documentation PR was created. Confidence that documentation is needed: 5% No docs needed: internal bug fix to Virtualize scroll anchoring with E2E tests; no signals detected. Documentation surfaces considered
|
ilonatommy
temporarily deployed
to
copilot-pat-pool
October 23, 2026 17:02 — with
GitHub Actions
Inactive
wtgodbe
pushed a commit
that referenced
this pull request
Nov 3, 2026
* Reproduce automatic loading of older, timestamp-sorted provider history and assert that stale anchor correction cannot undo the bottom pin. * Fix stale anchor correction undoing Virtualize end pin. * A request to load visible items can be ignored while Virtualize restores the scroll position. Check again after restoration so the last items are loaded instead of leaving blank space at the bottom. * Simplify end-anchor history regression test --------- Co-authored-by: Ilona Tomkowicz <[email protected]> Co-authored-by: Copilot App <[email protected]> Copilot-Session: aff37fd2-5a5e-43e4-a438-446e4254957b
1 task done
1 task done
This branch was previously deployed
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.
Keep the end scroll when older log history is loaded.
Description
With end anchoring,
Virtualizecan scroll to the bottom and then jump back to an old item. An old scroll correction runs after the bottom scroll and undoes it.Clear that correction when scrolling to the bottom. Add a browser test that loads older log history and checks that the bottom scroll is not undone.
To visualize the problem, the before and after behavior are same as in microsoft/aspire#21055.
Details
Before (append clicked 3x, each of them look like a double append due to the mid-state):aspire-issue.mp4
After:
after-fix.mp4
After fixing the original report, some appends were producing blank space on pinning, intermittently. It happens because Virtualize ignores requests to fill the viewport while restoring the scroll position to avoid responding to spacer notifications during the process. With specific timing, that might leave blank viewport. That timing depends when "empty space is visible" notification from the spacer observer reaches .net - if it happens when
_pendingAnchorRestoreis stilltruethen the bug happens.The fix saves the info about
FillViewportbeing ignored. If any like this happened, we ask JS to refresh observation to make sure if no newFillViewportcallback wouldn't be issued.Details
aspire-blank-tail-demo.mp4
Fixes #69823