Tabbing in DT 3.0.1 with FixedHeader
Tabbing in DT 3.0.1 with FixedHeader
I think I might've found a bug if you have a fixed header and need to tab. Tabbing forward is fine, but once down to the pagination, and you shift tab backwards, the focus disappears briefly before appearing again.
What I observed is it's missing for 4 tabs backwards. That also happens to be the amount of filters in the header. After those it carries on backwards through the 4 filters. I'm guessing this could be because of four duplicate filter selects inside .dt-scroll-body. If I set fixedHeader: false this isn't a problem.
Answers
Interesting - thank you. When you say "filters" are you using ColumnControl, or something like that to add
inputelements in the table header? If you are able to link to a test case showing the issue, that would be useful.Many thanks,
Allan
Actually @allan I've created a minimal demo for you to demonstrate this better. This way you'll be able to see with only 10 entries tabbing forward and back works. Select 100 records and when the fixed header is activated tabbing goes through the sort icons and gets to the pagination. Once you start tabbing back, the fixed header is skipped and focus goes pagination > search box. I did try a test case but couldn't get that to work. I'll PM the files.
Got it - many thanks. I'll let you know when I've got an answer.
Allan
I've been digging into this a bit more, and the issue is coming about due (in part) to where the fixed header is being inserted into the document (a child of
body). I can change that so that it is alongside thetablehost - since the floating element isposition: fixedit doesn't really impact it.That does let you shift tab back from paging to the floating header, but it brings its own problems. When you try to tab from the header (when not floating), it will cause the header to float and thus gain focus again.
I'm not sure what the fix will be at the moment I'm afraid. I'll need to mull it over and come back to it.
Allan
That's OK @allan. I don't think it's a big issue for most people. I thought I'd flag it, because it could affect accessibility and anyone using screen readers. I was just playing around with focus when I found it.