When using CSS3 selector nth-child to style even and odd rows with a different background, this is not "updated" when doing a filter (search). The data (rows) keep their previous background style and you end up with multiple of the same colour next to each other.
This is caused by CSS behaviour, as display: none does not remove the row, but just "hide" it. CSS does not care and keeps them as normal rows when "calculating" odd and even rows. I was wondering if there's anything that could be done about this issue. Perhaps store all data in an array, and remove the data that's filtered out so the table only holds the actual visible data.
Steps to reproduce the behavior:
[Enter text into a filter input, that at least gives you two rows of the same odd/even rows]
[Notice, that some rows below each other will have the same odd/even styling]
Expected behavior
Tables should keep actual visible data only, and store filtered data in an array.
Screenshots
TableFilter version: [0.6.104]
Browser and version: [Chrome, latest stable]
OS and version: [MacOS 10.15.1]
Device: [Macbook Pro Retina Early 2013]
Additional information/context:
Add any other context about the problem here.
Problem started happening recently, didn't happen in an older version of TableFilter: [No]
Problem can be reliably reproduced, doesn't happen randomly: [Yes]
When using CSS3 selector nth-child to style even and odd rows with a different background, this is not "updated" when doing a filter (search). The data (rows) keep their previous background style and you end up with multiple of the same colour next to each other.
This is caused by CSS behaviour, as display: none does not remove the row, but just "hide" it. CSS does not care and keeps them as normal rows when "calculating" odd and even rows. I was wondering if there's anything that could be done about this issue. Perhaps store all data in an array, and remove the data that's filtered out so the table only holds the actual visible data.
Steps to reproduce the behavior:
Expected behavior Tables should keep actual visible data only, and store filtered data in an array.
Screenshots
TableFilter version: [0.6.104] Browser and version: [Chrome, latest stable] OS and version: [MacOS 10.15.1] Device: [Macbook Pro Retina Early 2013]
Additional information/context: Add any other context about the problem here.