vikramlearning / blazorbootstrap

An Enterprise-class Blazor Bootstrap Component library built on the Blazor and Bootstrap CSS frameworks.
https://docs.blazorbootstrap.com/
Apache License 2.0
670 stars 32 forks source link

Grid default loading indicator could generate placeholders for the entire page size #798

Closed Nysosis closed 2 months ago

Nysosis commented 2 months ago

Describe the bug

When using the Grid component, the default loading indicator currently generates only 5 placeholder rows. When have a page size larger than 5, and use the pagination to navigate to the next page of results then your content will bounce up and down.

If the loading indicator instead used the PageSize to determine the number of indicators to generate, chances are there should be little-to-none shifting of content on the page

To Reproduce Steps to reproduce the behavior:

  1. Go to https://demos.blazorbootstrap.com/grid/overview#server-side-filtering-paging-sorting
  2. Click on any of the pagination buttons
  3. See the content below the grid bounce up and down as it shrinks to 5 rows then grows to back 10

Expected behavior Little to no movement when using pagination

Versions (please complete the following information):

Nysosis commented 2 months ago

Happy to raise a PR if agreed it's an issue :)