primefaces-extensions: Layout: dataTable with percentage scrollHeight is wrongly sized
Describe the bug dataTable with scrollHeight=“100%” calculates its actual height wrong, resulting in overflow with no scrollbar and other problems of this nature.
Reproducer primefaces-extensions-layout-datatable-scroll-height.zip
Environment:
- PF+PFE Version: 6.2.30+6.2.10, 10.0.0+10.0.6, 11.0.0-SNAPSHOT+10.0.6
- JSF + version: __
- Affected browsers: Firefox, Chrome
To Reproduce Steps to reproduce the behavior:
- Open non-maximized browser window.
- Go to http://localhost:8080/primefaces-test/
- See only some rows visible out of 25. See no scrollbar.
- Resize the window by dragging. See scrollbar appear.
- Maximize the window. See wrong table height again.
Expected behavior dataTable should be correctly sized and with a proper scrollbar.
Sample XHTML
<h:body style="width: 100%;">
<pe:layout>
<pe:layoutPane position="north" resizable="false" size="200" />
<pe:layoutPane position="center" resizable="false" styleContent="overflow:hidden;">
<p:dataTable value="#{[1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25]}" var="row" scrollable="true" scrollHeight="100%" style="height: 100%">
<p:column>
row #{row}
</p:column>
</p:dataTable>
</pe:layoutPane>
<pe:layoutPane position="south" resizable="false" size="200" />
</pe:layout>
</h:body>
Sample Bean None.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Comments: 21 (12 by maintainers)
Commits related to this issue
- Layout: dataTable with percentage scrollHeight is wrongly sized #563 Partially reverted 44bd0b84 to bring back markup buffering to render the widget with options first. — committed to VsevolodGolovanov/primefaces-extensions-core by VsevolodGolovanov 3 years ago
- Layout: dataTable with percentage scrollHeight is wrongly sized (#566) #563 Partially reverted 44bd0b84 to bring back markup buffering to render the widget with options first. — committed to primefaces-extensions/primefaces-extensions by VsevolodGolovanov 3 years ago
- Fix #563: Layout: dataTable with percentage scrollHeight is wrongly sized — committed to Rapster/core by melloware 3 years ago
OK this will be in 10.0.7 and 11.0.0! Thanks for the PR!