jspreadsheet / ce

Jspreadsheet is a lightweight vanilla javascript plugin to create amazing web-based interactive tables and spreadsheets compatible with other spreadsheet software.
https://bossanova.uk/jspreadsheet/v4
MIT License
6.75k stars 826 forks source link

Cell navigation is not working properly, if hidden column is available #321

Closed Ilayaraja-n closed 5 years ago

Ilayaraja-n commented 5 years ago

Hi, While navigating to cell using arrow keys, cell selection is getting set for the hidden columns also. Kindly set cell selection only for the visible columns.

SFoster84 commented 5 years ago

How would you approach this, something like detect on entry when you're in a hidden cell and repeat the last keyboard action (such as arrow-right)?

Ilayaraja-n commented 5 years ago

Thank you so much for your response. As you said while navigation we need to identify previous/next visible elements. We can use the jQuery methods to get the previous/next visible elements. I have modified few changes in the “keyDownControls” method to make it work. Please check attached screen shot. We need to do similar changes for Home and End key also. Keyboard_Navigation

SFoster84 commented 5 years ago

Thanks for adjusting the code, could you start a branch with those changes or provide a text version as an attachment? (I'd like to try it out)

pphod commented 5 years ago

Could you kindly send a pull request, I am happy to merge it to the master.

Ilayaraja-n commented 5 years ago

Thank you. I have attached the modified jquery.jexcel.js file. The changes are done in the keyDownControls method.

jquery.jexcel.zip