Small gap between fixed header's cells, misaligned fixed header
Small gap between fixed header's cells, misaligned fixed header
BreenL
Posts: 3Questions: 2Answers: 0
Hello.
I have a table with fixed header. When fixed header is visible and you scroll table horizontally, you can see a small 1px gap between first and second cell, also there is another gap after last cell of fixed header. These gaps make underlying elements visible. Also, whole fixed header is misaligned with table by ~1px.
How can I fix this?
link to example: https://live.datatables.net/jakikowa/1/edit
Answers
Thanks for the test case.
I'm not actually seeing it in either Chrome or Firefox (Linux). What browser, version and OS are you using?
Thanks,
Allan
Hello, Allan. I'm using opera 97, and edge 112, OS is win 10 x64.
To clarify the test case. You should choose to show 25 rows or more, then scroll down a little bit so sticky fixed header could appear, then scroll right slowly, it allows me to see underlying characters in gaps I explained.
I chose a page length of 50 and I'm not seeing the issue either (Ubuntu 20 / Chrome 112).
Would you be able to post a screenshot of the issue, please.
Colin
I've just tried it again - I hadn't clicked that FixedHeader was enabled on the page, since there was no vertical scrolling on my monitor.
I am actually seeing the 1px shift that is shown in your screenshot, when FixedHeader is active.
It looks like it is probably due to the table border not being applied on the fixed header:
I'll need to look into that.
Allan