Repository navigation
Grids: type virtual scrolling - #36065
Merged
bit-byte0 merged 13 commits intoOct 30, 2026
Merged
Conversation
Comment on lines
+58
to
+72
| if ( | ||
| beginPageIndex < 0 | ||
| || ( | ||
| ( | ||
| that.viewportSize() >= 0 | ||
| && that.getViewportItemIndex() >= 0 | ||
| && ( | ||
| beginPageIndex * that.pageSize() > that.getViewportItemIndex() | ||
| || beginPageIndex * that.pageSize() + that.itemsCount() | ||
| < that.getViewportItemIndex() + that.viewportSize() | ||
| ) | ||
| ) | ||
| && that._dataSource.isLoading() | ||
| ) | ||
| ) { |
Contributor
There was a problem hiding this comment.
make it more readable, please, by introducing variables
| clearTimeout(this._resizeTimeout); | ||
| public dispose(): void { | ||
| super.dispose(); | ||
| clearTimeout(this._resizeTimeout ?? undefined); |
Contributor
There was a problem hiding this comment.
suggestion: can we use undefined instead of null for cleared _resizeTimeout value and remove this ??
| this._lastTime = new Date(); | ||
| } else { | ||
| result = super.resize.apply(this); | ||
| result = super.resize(); |
Contributor
There was a problem hiding this comment.
lets use early returns instead of mutations
| // eslint-disable-next-line @typescript-eslint/prefer-nullish-coalescing | ||
| return super._needUpdateRowHeight.apply(this, arguments as any) || (itemsCount > 0 | ||
| && (isInfiniteMode(this) && !gridCoreUtils.isVirtualRowRendering(this)) | ||
| protected _needUpdateRowHeight(itemsCount: number): boolean | undefined { |
Contributor
There was a problem hiding this comment.
is undefined value meaningful here or we can make it to return boolean always?
Comment on lines
+41
to
+42
| const isVirtualMode = (that: VirtualScrollController): boolean => that.option('scrolling.mode') === SCROLLING_MODE_VIRTUAL || that.isVirtual(); | ||
| const isAppendMode = (that: VirtualScrollController): boolean => that.option('scrolling.mode') === SCROLLING_MODE_INFINITE && !that.isVirtual(); |
Contributor
There was a problem hiding this comment.
those should be methods or take as arguments scrollingMode and isVirtual -- if not fixed with common utils (see card follow ups section)
anna-shakhova
previously approved these changes
Oct 30, 2026
anna-shakhova
approved these changes
Oct 30, 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.
What
Typed DataGrid and TreeList virtual scrolling: fields, params, return types
How
Data source adapter calls the virtual scroll controller directly instead of a string proxy. Rows view reaches the data controller through typed extension interfaces, rendered-view directives became guards, unused rows view members removed