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

DataTable: #loading templates broken with lazy virtual scroller #4723

Closed
zachlearnscode opened this issue Oct 30, 2023 · 6 comments
Closed
Assignees
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Milestone

Comments

@zachlearnscode
Copy link

zachlearnscode commented Oct 30, 2023

Describe the bug

It appears an update sometime after 3.31 has broken the loading templates on lazy loaded, virtual scroller datatables.

Repro is link to PrimeVue example for that component linked in the docs here: https://primevue.org/datatable/#lazy_virtualscroll

Reproducer

https://stackblitz.com/edit/wdtncx?file=src%2FApp.vue

PrimeVue version

3.37.0

Vue version

3.x

Language

ALL

Build / Runtime

Vite

Browser(s)

No response

Steps to reproduce the behavior

Go to repro link
After the table loads, scroll anywhere in the table beyond the initial set of loaded results
Note that the #loading templates do not appear (the table appears completely empty)
Scroll back to the top of the table
Note that the #loading templates appear for the very first set of results
Continue to scroll anywhere in the table but within range of the first set of results at the top
Note that the #loading templates do not appear

Expected behavior

The loading templates should appear whenever the loading property in virtualScrollerOptions is true

@zachlearnscode zachlearnscode added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Oct 30, 2023
@tugcekucukoglu
Copy link
Member

Could you update the reproducer link?

@zachlearnscode
Copy link
Author

zachlearnscode commented Oct 31, 2023

Sorry about that. I have updated the link. I had to fork the PV StackBlitz in order to share. If that doesn't work for whatever reason, the repro is the same code linked under Virtual Scroll > Lazy here: https://primevue.org/datatable/#lazy_virtualscroll

@tugcekucukoglu tugcekucukoglu added Type: Bug Issue contains a bug related to a specific component. Something about the component is not working and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Nov 30, 2023
@zachlearnscode
Copy link
Author

@tugcekucukoglu I ran a git bisect between versions 3.31 and 3.37 and it returned this commit of yours from September as the commit that potentially introduced this issue. It looks like that code is tied to the @layers implementation.

Do you think the @layers implementation could have created this bug?

@mertsincan mertsincan added this to the 3.45.0 milestone Dec 20, 2023
@zachlearnscode
Copy link
Author

thank you!

@mertsincan mertsincan self-assigned this Dec 21, 2023
@zachlearnscode
Copy link
Author

zachlearnscode commented Jan 4, 2024

@mertsincan So, the loading templates are behaving differently than they were before, but they still appear to be broken.

Previously, all sets of results past the first failed to display the loading template. Now, you can see loading templates down to the second or third set up results, but they eventually move of out view.

Again, you can see the issue in the docs here.

Should we reopen this issue?

@zachlearnscode
Copy link
Author

@mertsincan Please see my comment above

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a bug related to a specific component. Something about the component is not working
Projects
None yet
Development

No branches or pull requests

3 participants