Skip to content

Support for ARIA 1.1 combo boxes in Firefox and Chrome.#10046

Merged
michaelDCurran merged 1 commit intonvaccess:masterfrom
jcsteh:aria1.1Combo
Sep 13, 2019
Merged

Support for ARIA 1.1 combo boxes in Firefox and Chrome.#10046
michaelDCurran merged 1 commit intonvaccess:masterfrom
jcsteh:aria1.1Combo

Conversation

@jcsteh
Copy link
Copy Markdown
Contributor

@jcsteh jcsteh commented Aug 7, 2019

Link to issue number:

Fixes #9616 .

Summary of the issue:

ARIA 1.1 combo boxes (where the combo box contains a text box and a pop-up such as a list box) often weren't rendered in browse mode at all, making them effectively non-existent. Even if they were, you couldn't read the value or press enter to interact with the text box.

Description of how this pull request fixes the issue:

  1. If the first child of a combo box is a text box, render that text box in browse mode.
  2. Previously, we treated anything inside a combo box as being outside a browse mode document (Improve support for combo boxes in all browsers #8687). Don't do this for text boxes. Otherwise, you can't switch back to browse mode when the text box has focus.

Testing performed:

  1. In Firefox, tested the ARIA 1.1 Combobox with Listbox Popup Examples. Ensured that the combo box and its text box were rendered in browse mode, that pressing enter focused the text box and switched to focus mode and that it's possible to switch back to browse mode with escape or NVDA+space.
  2. In Firefox, tested a simple HTML select with size 1. Confirmed that the behaviour is unchanged; i.e. the combo box and its value are rendered in browse mode.

Known issues with pull request:

This assumes that a text box will always be the first child of the combo box. All the examples (including the official spec examples) do this and this is what I've seen in the wild. We could change this to scan all children, but I'm reluctant to do this unless we have to.

Change log entry:

Bug Fixes:
- ARIA 1.1 combo boxes are now supported in Mozilla Firefox and Google Chrome. (#9616)

@jcsteh jcsteh requested a review from feerrenrut August 7, 2019 12:13
@AppVeyorBot
Copy link
Copy Markdown

PR introduces Flake8 errors 😲

See test results for Failed build of commit 52fcc10938

@jcsteh jcsteh force-pushed the aria1.1Combo branch 2 times, most recently from 94df760 to d872d91 Compare August 7, 2019 12:56
@AppVeyorBot
Copy link
Copy Markdown

PR introduces Flake8 errors 😲

See test results for Failed build of commit 939e177bc6

1. If the first child of a combo box is a text box, render that text box in browse mode.
2. Previously, we treated anything inside a combo box as being outside a browse mode document (nvaccess#8687). Don't do this for text boxes. Otherwise, you can't switch back to browse mode when the text box has focus.
@LeonarddeR
Copy link
Copy Markdown
Collaborator

Some things I observed.

  1. The aria comboboxes aren't expandable with alt+down arrow. I expected that that would happen.
  2. The third example, opening it and pressing down arrow populates the edit box with apple. ANother press of down arrow focuses the list. This might be expected behavior based on the widget's implementation, though.
  3. When the list gets focus instead of the edit box, the name of the control is repeated. I would expected that only list is announced, but again, this might be related to the implementation.

@jcsteh
Copy link
Copy Markdown
Contributor Author

jcsteh commented Aug 29, 2019

1. The aria comboboxes aren't expandable with alt+down arrow. I expected that that would happen.

Do you mean pressing alt+downArrow from browse mode or focus mode? Those combo boxes seem to have weird behaviour with alt+downArrow. That said, downArrow is usually enough to open an autocomplete if appropriate.

2. The third example, opening it and pressing down arrow populates the edit box with apple. ANother press of down arrow focuses the list. This might be expected behavior based on the widget's implementation, though.

When you say "opening it", do you mean alt+downArrow? That behaves strangely for me with these examples; it seems to open, but when you release alt, it collapses.

3. When the list gets focus instead of the edit box, the name of the control is repeated. I would expected that only list is announced, but again, this might be related to the implementation.

The implementation has the label on both the text box and the list, so yes, this is related to the implementation. If that's common, we could potentially filter this out, but I think that's out of scope for this PR.

@LeonarddeR
Copy link
Copy Markdown
Collaborator

1. The aria comboboxes aren't expandable with alt+down arrow. I expected that that would happen.

Do you mean pressing alt+downArrow from browse mode or focus mode? Those combo boxes seem to have weird behaviour with alt+downArrow. That said, downArrow is usually enough to open an autocomplete if appropriate.

In both browse and focus mode.

  1. The third example, opening it and pressing down arrow populates the edit box with apple. ANother press of down arrow focuses the list. This might be expected behavior based on the widget's implementation, though.

When you say "opening it", do you mean alt+downArrow? That behaves strangely for me with these examples; it seems to open, but when you release alt, it collapses.

Exact sstr are:

  1. Go to the third example in browse mode
  2. Press space on the combo box to activate it (switch to focus mode)
  3. Press down arrow: I hear apple
  4. Press down arrow again, i hear Choice 3 Fruit or Vegetable list, Artichoke

@jcsteh
Copy link
Copy Markdown
Contributor Author

jcsteh commented Sep 9, 2019

1. The aria comboboxes aren't expandable with alt+down arrow. I expected that that would happen.

Do you mean pressing alt+downArrow from browse mode or focus mode?

In both browse and focus mode.

The fact that this doesn't work in focus mode is because the test cases don't support it. I don't know of any ARIA 1.1 combo boxes that do. They tend to expand when you start typing or when you press down arrow.

My feeling is that we shouldn't do anything for browse mode here unless we can find a combo box that actually supports this. That can be done as a follow-up. Does that work for you?

1. Go to the third example in browse mode

2. Press space on the combo box to activate it (switch to focus mode)

3. Press down arrow: I hear apple

For me, the list gets focus when I press down arrow here. However, I'm using Firefox nightly. I suspect you're being bitten by https://bugzilla.mozilla.org/show_bug.cgi?id=1571327 , which I fixed a month ago (targeting Firefox 70).

@LeonarddeR
Copy link
Copy Markdown
Collaborator

My feeling is that we shouldn't do anything for browse mode here unless we can find a combo box that actually supports this. That can be done as a follow-up. Does that work for you?

Sure!

For me, the list gets focus when I press down arrow here. However, I'm using Firefox nightly. I suspect you're being bitten by https://bugzilla.mozilla.org/show_bug.cgi?id=1571327 , which I fixed a month ago (targeting Firefox 70).

Ah, in that case, let's assume it will be fixed in FF70 for me as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Handling ARIA 1.1 Combobox is broken in Chrome and Firefox

5 participants