[GH-DEV #2969] Scaled down handsontable shows incorrect cell selection borders

Hi all!

I have encountered an issue with handsontable (only after upgrading to v16 like related to this) inside a downscaled version of handsontable.

We have an automated visual testing tool in place that compares screenshots. We’re also using testem and QUnit for our automated testing, where the default behavior is to show the test view in the bottom right corner, while test results are being listed in full-screen in the background. This downscaled (50%) version shows a selected cell’s borders only in the top half of the cell, so it seems the cell’s height is not being respected during border placement calculation:

Before (handsontable v.14.6):

After (handsontable v16.1):

It’s not ideal to have diff showing that’s not in our control. Fixing it for us and only for our test cases only fixes the actual placement, not the calculation that’s behind it.

Thanks for an help on this!

Patrick

Hi @rossnagel

Thank you for sharing screenshots. It seems that the position of the table is incorrect. It shows based on the hgap between the JAN header and the rest of the table. The layers of Handsontable DOM structure are misaligned.

Could you share a demo that demonstrates how Handsontable instance is placed in the container?

Hi Aleksandra,

thanks for the quick reply! Here’s a minimal example where I simply followed the installation instructions to create a handsontable instance. As you can see, also here selecting a cell does not mark the entire cell as marked but only the top half, which is exactly what we experienced. There’s no need for further CSS to apply for reproduction, the basic example w/o customization already shows the issue.

https://codepen.io/Yeehaw90/pen/KwzqoEB

Please let me know if you need further info.

Thanks in advance and best regards

Patrick

Thank you for sharing the demo, Patrick.

You are right. That is a regression introduced in v16.1.0, in 16.0.1 it all worked well.

I’ve added this issue report to our internal to-do list. I will inform you once it is solved.

Hi Aleksandra, thanks for the quick follow-up!

Happy to get to know any info whenever this is being investigated and possibly resolved.

Until then, best regards

Patrick