-
Notifications
You must be signed in to change notification settings - Fork 77
docs(Grid,TreeList): Revamp Virtual Scrolling documentation #2811
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
56ae5b5
docs(Grid,TreeList): Revamp Virtual Scrolling documentation
dimodi 9ec5f03
Update components/treelist/virtual-scrolling.md
dimodi 19f179a
Update knowledge-base/grid-virtualization-many-records.md
dimodi 5fe5889
Update knowledge-base/grid-virtualization-many-records.md
dimodi d1fb700
Update knowledge-base/grid-virtualization-many-records.md
dimodi 567b959
Update knowledge-base/grid-virtualization-many-records.md
dimodi 6965bb2
Update components/grid/virtual-scrolling.md
dimodi File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
Large diffs are not rendered by default.
Oops, something went wrong.
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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
--- | ||
title: Hide Grid Virtual Row Skeletons | ||
description: Learn how to hide / remove / disable the Grid and TreeList cell placeholder skeletons during virtual row scrolling. | ||
type: how-to | ||
page_title: How To Hide Row Skeletons During Virtual Grid Scrolling | ||
slug: grid-kb-hide-virtual-row-skeletons | ||
tags: blazor, grid, treelist, skeleton, styles, css | ||
ticketid: 1658135, 1642794 | ||
res_type: kb | ||
--- | ||
|
||
## Environment | ||
|
||
<table> | ||
<tbody> | ||
<tr> | ||
<td>Product</td> | ||
<td>Grid for Blazor, <br /> TreeList for Blazor</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
|
||
## Description | ||
|
||
This KB article answers the following questions: | ||
|
||
* How to remove the Grid row placeholders during virtual scrolling? | ||
* How to hide the skeletons that appear in empty table cells during virtual scrolling? | ||
* How to disable the Grid cell placeholders? | ||
* How to turn off the Grid loader indicators inside the virtual rows? | ||
|
||
## Solution | ||
|
||
Apply a `display:none` or `visibility:hidden` CSS style to the `.k-skeleton` selector inside Grid table cells. | ||
|
||
>caption Removing placeholder skeletons during virtual Grid scrolling | ||
|
||
````RAZOR | ||
<TelerikGrid Data="@GridData" | ||
Height="360px" | ||
PageSize="20" | ||
RowHeight="40" | ||
ScrollMode="@GridScrollMode.Virtual" | ||
Class="no-skeletons"> | ||
<GridColumns> | ||
<GridColumn Field="@nameof(Product.Name)" /> | ||
<GridColumn Field="@nameof(Product.Price)" DisplayFormat="{0:c2}" /> | ||
<GridColumn Field="@nameof(Product.Quantity)" /> | ||
</GridColumns> | ||
</TelerikGrid> | ||
|
||
<style> | ||
.no-skeletons .k-table-td > .k-skeleton { | ||
display: none; | ||
} | ||
</style> | ||
|
||
@code { | ||
private List<Product> GridData { get; set; } = new(); | ||
|
||
protected override void OnInitialized() | ||
{ | ||
for (int i = 1; i <= 1000; i++) | ||
{ | ||
GridData.Add(new Product() | ||
{ | ||
Id = i, | ||
Name = $"Name {i}", | ||
Price = Random.Shared.Next(1, 100) * 1.23m, | ||
Quantity = Random.Shared.Next(0, 1000) | ||
}); | ||
} | ||
} | ||
|
||
public class Product | ||
{ | ||
public int Id { get; set; } | ||
public string Name { get; set; } = string.Empty; | ||
public decimal Price { get; set; } | ||
public int Quantity { get; set; } | ||
} | ||
} | ||
```` | ||
|
||
## See Also | ||
|
||
* [Virtual Grid Scrolling](slug:components/grid/virtual-scrolling) | ||
* [Virtual TreeList Scrolling](slug:treelist-virtual-scrolling) |
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.