This is a migrated thread and some comments may be shown as answers.

Kendo React Grid reacts on pressing "Space" key

1 Answer 17 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
Alexey
Top achievements
Rank 1
Veteran
Alexey asked on 13 Aug 2020, 10:18 AM

I have a Switch component as a cell. When I press "Space" key the grid scrolls down. Is there a way to turn it off?

Thanks

1 Answer, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 13 Aug 2020, 01:11 PM

Hello, Alexey,

This is expected as space will make every scrollable container including the page itself to scroll. This come directly from the browsers and the KendoReact Grid has no control over it.

In this case, I can suggest attaching an onkeydown event over the Grid DOM element or over the body and preventing it if it is space and also based on the target as otherwise, the user will not be able to type space inside text: 

https://stackoverflow.com/questions/22559830/html-prevent-space-bar-from-scrolling-page

 

Regards,
Stefan
Progress Telerik

Tags
General Discussions
Asked by
Alexey
Top achievements
Rank 1
Veteran
Answers by
Stefan
Telerik team
Share this question
or