sticky header offsetY not working
See original GitHub issueHello Thanks for this project - First time using it today and its really useful!
I have been trying the sticky Header extention and it seems to be working - Unless you try and add the stickyHeaderOffsetY
using Local host - Uniserver - apache / php and Google chrome
Downloaded today build to 1.15.5
Using config
$table.bootstrapTable({ stickyHeader: true, stickyHeaderOffsetY: 0 , stickyHeaderOffsetLeft: '3em', stickyHeaderOffsetRight: '3em', });
Outputs Table looks good
On scroll - Sticky seems fine … needs offset
checking on inspect : top:0px inline style
Update Config :
$table.bootstrapTable({ stickyHeader: true, stickyHeaderOffsetY: 60 , stickyHeaderOffsetLeft: '3em', stickyHeaderOffsetRight: '3em', });
Header is no longer Sticky :
On inspect top inline style is no longer applied
Unfortunately there is no on-line example at the moment, Just trying on local
I have a quick fix by adding extra CSS
.sticky-header-container.fix-sticky.fixed-table-container {top: 60px;}
Issue Analytics
- State:
- Created 4 years ago
- Comments:15 (7 by maintainers)
Top GitHub Comments
this.$stickyContainer.css(‘top’, “”.concat(this.options.stickyHeaderOffsetY)); ===> this.$stickyContainer.css(‘top’, “”.concat(this.options.stickyHeaderOffsetY)+‘px’);
https://live.bootstrap-table.com/code/dreamerworks/1701
No matter what value you pass to stickyHeaderOffsetY, it refuses to work.