Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Select-Only Combobox: Clicking the label does not focus the combobox #2859

Closed
silviuaavram opened this issue Nov 12, 2023 · 2 comments · Fixed by #2889
Closed

Select-Only Combobox: Clicking the label does not focus the combobox #2859

silviuaavram opened this issue Nov 12, 2023 · 2 comments · Fixed by #2889
Assignees
Labels
bug Code defects; not for inaccurate prose Example Page Related to a page containing an example implementation of a pattern Feedback Issue raised by or for collecting input from people outside APG task force

Comments

@silviuaavram
Copy link

Hello everyone!

A user of downshift useSelect hook asked about the lack of action when you click on the label corresponding to a select element. At the moment, the example for ARIA 1.2 performs no action when clicking the label.

https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-select-only/

Since Downshift follows the ARIA 1.2 pattern, we also don't perform any action when the label is clicked. However, should this behaviour be changed?

According to the MDN HTML <select>, when clicking the label, the select element is focused.

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/select

Should we also do the same and update the 1.2 pattern? Also, should we also add the htmlFor attribute again for the <label> pointing to the select?

Thank you very much and looking forward to your thoughts on this!

The issue we are tracking in downshift: downshift-js/downshift#1557

@mcking65 mcking65 added bug Code defects; not for inaccurate prose Example Page Related to a page containing an example implementation of a pattern Feedback Issue raised by or for collecting input from people outside APG task force labels Dec 19, 2023
@css-meeting-bot
Copy link
Member

The ARIA Authoring Practices (APG) Task Force just discussed [Select-Only Combobox] Clicking the label behaviour · Issue #2859 · w3c/aria-practices.

The full IRC log of that discussion <jugglinmike> Subtopic: [Select-Only Combobox] Clicking the label behaviour · Issue #2859 · w3c/aria-practices
<jugglinmike> github: https://github.com//issues/2859
<jugglinmike> Matt_King: This is something I can't test
<jugglinmike> jugglinmike: I can reproduce the reported bug
<jugglinmike> Matt_King: Then I'll label the GitHub issue as a bug
<jongund> present +jongund
<jugglinmike> jongund: I can work on a fix

@mcking65 mcking65 added this to the H1/2024 APG Improvements milestone Apr 7, 2024
mcking65 pushed a commit that referenced this issue Apr 7, 2024
…n label is clicked (pull #2889)

Resolves #2859 so clicking the label focuses the combobox.
@mcking65 mcking65 changed the title [Select-Only Combobox] Clicking the label behaviour Select-Only Combobox: Clicking the label does not focus the combobox Apr 7, 2024
@mcking65
Copy link
Contributor

mcking65 commented Apr 7, 2024

@silviuaavram, thank you for raising this issue. The fix will be live in production on April 9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Code defects; not for inaccurate prose Example Page Related to a page containing an example implementation of a pattern Feedback Issue raised by or for collecting input from people outside APG task force
4 participants