Skip to content
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

Set scroll bar size to account for all items ASAP during Progressive Ajax Loading #3372

Open
aeauseth opened this issue Aug 13, 2021 · 1 comment
Labels
Enhancement Possible small update to an existing feature

Comments

@aeauseth
Copy link

aeauseth commented Aug 13, 2021

Describe the solution you'd like
During Progressive Ajax Loading the server could return an optional total item count. It would be nice if Tabulator would set the scroll bar size to match the entire contents ASAP, which would be upon loading of page 1.

The standard Progressive Ajax Loading has an awkward user interface when the user drags the scroll bar down, before the content has loaded.

There is an associated bug. Repeatedly dragging the scrollbar to the bottom of the table before progressive loading is complete. Once progressive loading is done, drag the scrollbar back to the top. UI is awkward, mouse moves a lot, but scroll bar moves little. Eventually you get back to the top with missing rows. Could be a Chrome issue.

Describe alternatives you've considered
I'm not sure if you can directly set the size of the scrollbar, but you could include the last row as a placeholder (with null data). You could alternatively calculate the CSS padding-top and padding-bottom values on the tabulator-table div based on the total item count. You could load the last page early (just after page 1, but before page 2), but not sure Tabulator can handle out of order page loads. You may also be able to estimate the scrollbar size by multiplying cell height * pageSize * LastPage.

@aeauseth aeauseth added the Suggested Feature A suggested feature that is waiting review label Aug 13, 2021
@olifolkerd olifolkerd added Enhancement Possible small update to an existing feature and removed Suggested Feature A suggested feature that is waiting review labels Feb 20, 2022
@olifolkerd
Copy link
Owner

Hey @aeauseth

In the 5.1 release, Tabulator added the ability to send back the total record count to the table. So it seems a logical addition to try and bring in this functionality along side this.

I will consider this for a future release.

Cheers

Oli :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Enhancement Possible small update to an existing feature
Projects
None yet
Development

No branches or pull requests

2 participants