Repository navigation
Fix QuickGrid None-mode async-provider prepend viewport drift - #67931
Merged
ilonatommy merged 1 commit intoJul 21, 2026
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes a QuickGrid + Virtualize regression in AnchorMode.None when using an async ItemsProvider, where prepends could cause viewport drift due to (1) capturing an anchor snapshot during an in-flight placeholder gap and (2) a spacer callback firing during the server-side restore round-trip.
Changes:
- Keep
_pendingAnchorRestoreset duringRestoreAnchorAsync()forAnchorMode.Noneso spacer callbacks are suppressed across the async restore. - In the JS manual-anchoring path for
AnchorMode.None, ignore “mid-load gap” anchor snapshots and keep the last stable snapshot instead. - Re-enable previously disabled/quarantined QuickGrid E2E coverage for the async-provider prepend scenarios in
AnchorMode.None.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| src/Components/Web/src/Virtualization/Virtualize.cs | Defers clearing _pendingAnchorRestore during restore for AnchorMode.None to prevent stray callbacks from undoing the correction. |
| src/Components/Web.JS/src/Virtualize.ts | Skips overwriting an existing anchor snapshot in manual anchoring when a large transient gap is detected during async loads in None mode. |
| src/Components/test/E2ETest/Tests/VirtualizationTest.cs | Un-quarantines / re-enables None-mode async-provider prepend stability test coverage for QuickGrid. |
dariatiurina
approved these changes
Jul 21, 2026
This was referenced Jul 21, 2026
This was referenced Jul 21, 2026
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.
Contributes to #67865.
QuickGridrenders a<table>, so Virtualize uses the manual (non-native) scroll-anchoring path because native one wouldn't work reliably in a table layout. On a prepend with an asyncItemsProvider, the viewport drifted (top row jumped, e.g. 90->80) instead of staying stable.Two things contributed to the problem:
Fixes, both scoped to
AnchorMode.None:New QuickGrid AnchorMode test coverage summary, updated after #67783
None_AsyncProvider[Fact])