Last fixed column is shifting to cover previous fixed columns (Version 4.0.1)

Last fixed column is shifting to cover previous fixed columns (Version 4.0.1)

ZeshueToralZeshueToral Posts: 4Questions: 1Answers: 0

There appears to be an issue with the "left" styling so that the last fixed column will overlap all previous fixed columns. While putting together the test case, I discovered that it might be related to the table being created while in a bootstrap collapse element that's not showing its contents when the page is loaded.

Test Case: http://live.datatables.net/xivahiqa/4/edit?html,css,js,output

This question has an accepted answers - jump to answer

Answers

  • colincolin Posts: 14,610Questions: 1Answers: 2,493
    edited November 2021

    I took a look but I'm not sure what the issue is - there's a lot going on there. Please can you say what you expect to happen, and what is happening instead,

    Colin

  • ZeshueToralZeshueToral Posts: 4Questions: 1Answers: 0

    Yeah, sorry about that. So the issue is, if the datatable is hidden by the bootstrap 5 collapse (the "Packaging Check Items" collapsible menu in the example) when it's initialized with 2 fixed columns, when you scroll to the right in the table, the 2nd column ("Item" in the example) appears to slide over the first column ("Category") instead of them both remaining in place as is the expected behavior for having fixed columns.

  • ZeshueToralZeshueToral Posts: 4Questions: 1Answers: 0

    Updated cleaner test case: http://live.datatables.net/xivahiqa/6/edit

  • colincolin Posts: 14,610Questions: 1Answers: 2,493

    Thanks for that, we'll take a look and report - probably towards the end of next week. I must have missed your previous reply, apologies for that,

    Colin

  • sandysandy Posts: 913Questions: 0Answers: 236
    Answer ✓

    Hi @ZeshueToral ,

    Thanks for pointing this out. I've just made an addition so that FixedColumns will recalculate it's values when columns.adjust() is called. You should call this whenever the dropdown is triggered and the table is visible - then FixedColumns will be able to work it's values out.

    This will be available in the next FixedColumns release which we hope will be in the next few weeks. Until then you can access the fix from the nightly builds.

    Thanks,
    Sandy

  • ZeshueToralZeshueToral Posts: 4Questions: 1Answers: 0

    Just updated to release 4.0.2 and this issue is now resolved!

Sign In or Register to comment.