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

Grid keyboard/accesability navigation inside window

2 Answers 98 Views
Window
This is a migrated thread and some comments may be shown as answers.
Emanuel
Top achievements
Rank 1
Emanuel asked on 20 Jun 2016, 08:11 AM

Hello we are using kwindow service as described here: http://docs.telerik.com/kendo-ui/AngularJS/how-to/window-service

We experience the followoing issues, regarding keyboard accessibility:

1.We have grid inside window, and one of the columns of that grid is a dropdown. to access this dropdown, we press Enter and Alt + arrow up. This behavior is different (and even incorrect), from outside modal, where enter and arrow down is enough. We want a way to achieve same behavior inside modal.

2. we want to prevent access to underlying screen when the modal is open.

3. I noticed that sometimes when editing cells, and the user presses shift + Tab, there focusing cell jumps elsewhere, I even could see this in a demo (try to check /uncheck  a checkbox with keyboard only)

Here: http://jsbin.com/kuzezelada/edit?html,js,output

Is there a way to ensure the focus goes to previous cell? (the user moves between cells with tabs/shit+tabs.

 

Thank you in advanve

2 Answers, 1 is accepted

Sort by
0
Emanuel
Top achievements
Rank 1
answered on 21 Jun 2016, 04:08 PM
Hi, I hope you read the question, please give a feedback. Thanks in Advance.
0
Dimo
Telerik team
answered on 22 Jun 2016, 08:33 AM
Hi Emanuel,

Here are some tips on your questions.

1. We are not familiar with such a behavior. Can you provide a simple test page for inspection?

2. The Kendo UI Window does not prevent keyboard access via tabbing to the page content behind the modal overlay. It is possible to achieve the desired behavior by using a focus handler for the page <body>, check which is the focused element and return focus inside the Window if needed.

3. The issue is caused by using a custom editor in display mode. It is possible to restore the focused (current) cell by using the dataBinding and dataBound events. Here is how:

var cellIndex = null;
var rowIndex = null;
 
$("#grid").kendoGrid({
  dataBinding: function(e) {
    var current = e.sender.current() || [];
    if (current[0]) {
      cellIndex = current.index();
      rowIndex = current.parent().index();
    }
  },
  dataBound: function(e) {
    if (!isNaN(cellIndex)) {
      e.sender.current(e.sender.tbody.children().eq(rowIndex).children().eq(cellIndex));
    }
  }
})


Regards,
Dimo
Telerik
Get started with Kendo UI in days. Online training courses help you quickly implement components into your apps.
Tags
Window
Asked by
Emanuel
Top achievements
Rank 1
Answers by
Emanuel
Top achievements
Rank 1
Dimo
Telerik team
Share this question
or