Virtual Scroll breaks on second Table, when using more than one TabPanel, each Panel containing a Table with Virtual Scroll and LazyLoad
If you have a PrimeNG PRO Support subscription please post your issue at;
https://pro.primefaces.org
where our team will respond within 4 business hours.
If you do not have a PrimeNG PRO Support subscription, fill-in the report below. Please note that your issue will be added to the waiting list of community issues and will be reviewed on a first-come first-serve basis, as a result, the support team is unable to guarantee a specific schedule on when it will be reviewed. Thank you for your understanding.
Current Queue Time for Review Without PRO Support: ~8-12 weeks. With PRO Support: 1 hour
I'm submitting a ... (check one with "x")
[X] bug report => Search github for a similar issue or PR before submitting
[ ] feature request => Please check if request is not on the roadmap already https://github.com/primefaces/primeng/wiki/Roadmap
[ ] support request => Please do not submit support request here, instead see http://forum.primefaces.org/viewforum.php?f=35
Plunkr Case (Bug Reports) Please demonstrate your case at stackblitz by using the issue template below. Issues without a test case have much less possibility to be reviewd in detail and assisted. Modified PrimeNg Virtual Scroll Demo Stackblitz: https://stackblitz.com/edit/primeng-tablevirtualscroll-tab-bug?file=src/app/app.component.html
Current behavior When using PrimeNg TabView and having at least two TabPanels, each containing a Table with virtualScroll and lazy activated, scrolling on the second and all following tables breaks. It seems that the height of the ".cdk-virtual-scroll-content-wrapper" container is not calculated properly, shrinking the height. The same happens when using SelectButtons or similar things to display only one table at a time and being able to switch between them. It only works, when using the tables by themselves.
Expected behavior The tables are displayed properly, one at a time, depending on the active TabPanel, virtual scrolling works.
Minimal reproduction of the problem with instructions
- Click on Tab "Broken Table"
- Start Scrolling
What is the motivation / use case for changing the behavior? I'd like to display multiple tables, all of them functioning properly.
Please tell us about your environment:
Windows 10, VS Code, npm, nodejs
-
Angular version: 5.X Broken since at least 9.0.0 currently in 11.2.5
-
PrimeNG version: 5.X Broke since at least 9.0.0 currently in 11.3.1 on my setup, (I'm using your own table demo stackblitz, seems like version is 11.3.0 there)
-
Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ] Chrome 91.0.4472.114, Firefox 89.0.2, Edge 91.0.864.54
-
Language: [all | TypeScript X.X | ES6/7 | ES5] Typescript 4.1.3
-
Node (for AoT issues):
node --version=
I'm having this same issue on v10.1.2-lts
Any movement on this issue?
Any update on this issue? Can confirm it is occurring on 13.4.1
I'm having this same issue on v13 Also when screen is resized, height of scroller will be shrinked and show only one record.
This behavior is showing on v14. The element p-table > div.p-datatable-wrapper > div.p-scroller is being assigned "height; 0px'"
@CharlesLampmanSH, could you please attach a stackblitz link for us to replicate v14 + new virtualScoller API issue? Thanks a lot!
Hi,
So sorry for the delayed response! Improvements have been made to many components recently, both in terms of performance and enhancement. Therefore, this improvement may have been developed in another issue ticket without realizing it. You can check this in the documentation. If there is no improvement on this, can you reopen the issue so we can include it in our roadmap? Please don't forget to add your feedback as a comment after reopening the issue. These will be taken into account by us and will contribute to the development of this feature. Thanks a lot for your understanding!
Best Regards,