datatable vertical scroll, with fixed column widths
Forum rules
Please note that response time for technical support is within 3-5 business days.
Please note that response time for technical support is within 3-5 business days.
- undermensch
- Posts: 140
- Joined: 08 Jul 2010, 14:37
- Location: Florida, United States
If the datatable is scrollable and one or more column widths have been set, the table header column widths don't match up.
PrimeFaces-11.0.6 / Wildfly 24
-
- Posts: 5281
- Joined: 29 Jun 2013, 12:38
I think it is not a Harmony Layout or Theme issue. Please use core forum; viewforum.php?f=3
Could you please try it without Harmony?
Also, maybe you can try tableStyle="table-layout:auto" or tableStyle="width:auto" on DataTable.
Could you please try it without Harmony?
Also, maybe you can try tableStyle="table-layout:auto" or tableStyle="width:auto" on DataTable.
Github Profile: https://github.com/mertsincan
- undermensch
- Posts: 140
- Joined: 08 Jul 2010, 14:37
- Location: Florida, United States
The problem was not present when I had Ultima theme installed. It appeared when I switched to harmony. I just switched to cupertino to check. It worked fine with cupertino, but when I switched to Harmony, the problem returned. I changed no markup, just the themes. I should add that the problem occurs regardless of whether any column widths are set. Just set scrollable= true and the issue occurs.
Thanks
Thanks
PrimeFaces-11.0.6 / Wildfly 24
-
- Posts: 5281
- Joined: 29 Jun 2013, 12:38
Thanks a lot for the screenshot. Could you please try the following css?
Code: Select all
.ui-datatable-scrollable-header *,
.ui-datatable-scrollable-theadclone * {
-moz-box-sizing: content-box;
-webkit-box-sizing: content-box;
box-sizing: content-box;
}
Github Profile: https://github.com/mertsincan
- undermensch
- Posts: 140
- Joined: 08 Jul 2010, 14:37
- Location: Florida, United States
That makes things much better. The alignment is still off very slightly compared with cupertino.
Thanks
Thanks
PrimeFaces-11.0.6 / Wildfly 24
-
- Posts: 5281
- Joined: 29 Jun 2013, 12:38
Could you please try the following css code?
Code: Select all
.ui-datatable-scrollable-header *,
.ui-datatable-scrollable-theadclone * {
-moz-box-sizing: content-box;
-webkit-box-sizing: content-box;
box-sizing: content-box;
}
body .ui-datatable .ui-datatable-scrollable-body::-webkit-scrollbar {
width: 15px;
}
Github Profile: https://github.com/mertsincan
- undermensch
- Posts: 140
- Joined: 08 Jul 2010, 14:37
- Location: Florida, United States
That seems to be the magic sauce! The header and table columns now seem perfectly aligned.
Thanks.
Thanks.
PrimeFaces-11.0.6 / Wildfly 24
-
- Posts: 5281
- Joined: 29 Jun 2013, 12:38
Glad to hear, thanks a lot for the update!
Github Profile: https://github.com/mertsincan
-
- Prime
- Posts: 18616
- Joined: 05 Jan 2009, 00:21
- Location: Cybertron
- Contact:
We'll have this fixed in next maintenance release as well.
what about the problem if the columns are more than in the given size can be printed ?
in this case a horizontal scroll bar is rendered on the bottom of the table
and if you scroll to the other columns the sticky header will not refresh !
so it doesn't make sense to use the sticky header when you have more columns than all that can be printed !
Please fix this !
in this case a horizontal scroll bar is rendered on the bottom of the table
and if you scroll to the other columns the sticky header will not refresh !
so it doesn't make sense to use the sticky header when you have more columns than all that can be printed !
Please fix this !
-
- Information
-
Who is online
Users browsing this forum: No registered users and 10 guests