Opened 4 years ago

Last modified 15 months ago

#10586 reopened enhancement

TabContainer: support first-character navigation of drop-down tab list

Reported by: MartinPacker Owned by:
Priority: low Milestone: future
Component: Dijit Version: 1.4.0
Keywords: keys keystrokes keyboard access a11y Cc: doughays
Blocked by: Blocking:

Description

The new drop-down list for tab selection in TabContainer is REALLY handy (and neatly reduces the height of the tab strip to a single (predictable-height) row.

I think it would aid usability if the drop-down list of tabs were able to use first-character navigation.

(I actually modified the tab titles my code generates to make the leading characters unique and first-character navigation didn't work.)

An alternative to first-character navigation is string match navigation (but I suspect that's worse from a a11y perspective).

More distantly, the ability to search in tabs would be nice.

Change History (10)

comment:1 Changed 4 years ago by MartinPacker

It also strikes me that we don't document how to drop down the tab list with the keyboard. (Maybe you can't.)

comment:2 Changed 4 years ago by bill

  • Summary changed from Support first-character navigation of drop-down tab list in TabContainer to TabContainer: support first-character navigation of drop-down tab list

Your suspicion is correct; a user can't open the drop down list via the keyboard. The reason is that navigating a menu via keyboard would be no faster than navigating the tab list via keyboard: you have to press the left/right (or up/down) arrow keys an equal number of times.

As for first character navigation, that seems like a reasonable request... we have that for Tree already (actually it does multiple character search if you type fast enough), but not for Menu or anything else. I guess it should be extracted to a dijit utility class.

comment:3 Changed 4 years ago by MartinPacker

Doesn't a11y suggest we SHOULD have a mechanism for dropping down the list via keystrokes?

But I accept it's of limited utility until character-navigation of the list is done.

Again, happy to test. (Actually I'm looking to get involved in coding but need my IBM manager to OK it before I can start. :-) And maybe this ISN'T the ticket to work on first.)

comment:4 Changed 4 years ago by bill

  • Milestone changed from tbd to future

comment:5 Changed 4 years ago by MartinPacker

Looking at the code again (and rereading this) it seems the component that needs change is dijit.Menu. I note your point about a utility class.

I think I might experiment with what's there for Tree and/or mock something up for dijit.Menu - just to see if it can be done. But I'm not signed off to formally contribute to Dojo.

comment:6 Changed 4 years ago by MartinPacker

On holiday :-) I messed with a TabContainer plus extra code to handle first-char navigation when the focus is on one of the tabs. That was quite easy to do. So maybe it's OK not to drop down the tab menu and do first-char within it but do first-char nav when focused on a tab.

(Ideally, of course, we'd do both.)

Happy to share the code - even if only as an example of someone not adequately familiar with the toolkit blundering around. :-)

comment:7 Changed 18 months ago by bill

  • Cc doughays added; becky removed
  • Resolution set to duplicate
  • Status changed from new to closed

Duplicate of #10251.
Will be handled by Doug's enhancements to _KeyNavContainer. Maybe that will even allow searching when focused on the tab labels themselves.

comment:8 Changed 18 months ago by bill

  • Milestone changed from future to 1.9
  • Resolution duplicate deleted
  • Status changed from closed to reopened

Oh, hmm, except that it doesn't work because the menu doesn't have focus. Maybe can add code to the TabContainer to forward the keystrokes to the menu when it's open.

Letter navigation while focused on the tab labels isn't working either, probably because TabController isn't extending _KeyNavContainer.

comment:9 Changed 16 months ago by bill

  • Priority changed from high to low

comment:10 Changed 15 months ago by bill

  • Milestone changed from 1.9 to future
Note: See TracTickets for help on using tickets.