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

Misleading definition of combobox #1349

Open
JAWS-test opened this issue Oct 30, 2020 · 4 comments
Open

Misleading definition of combobox #1349

JAWS-test opened this issue Oct 30, 2020 · 4 comments
Assignees
Labels
clarification clarifying or correcting language that is either confusing, misleading or under-specified
Milestone

Comments

@JAWS-test
Copy link
Contributor

In my opinion the following definition in ARIA 1.2 for combobox is wrong:

A combobox functionally combines a named input field ...

The following sentence is clearer:

A combobox input MAY be either a single-line text field that supports editing and typing or an element that only displays the current value of the combobox

However, using MAY leaves open what else it could be.

I think the definition of combobox should be clear which elements may be used. Since I didn't create the new ARIA 1.2 combobox construct, I don't know what they are, but I suspect the following:

  • <input type=text> for "single-line text field that supports editing and typing" (maybe also an element with contenteditable???)
  • An element without role (like <div>, <span>) for "an element that only displays the current value of the combobox" (maybe also <button>???)

I think an exact definition is very important, because at the end AT has to distinguish between combobox with text input and without text input. Without a clear definition each AT will find its own way to make this distinction and then it will not be consistent.

See w3c/html-aam#46 (comment)

@scottaohara
Copy link
Member

I interpret the use of input in the initially quoted sentence as being related to the first sentence's use of the input abstract role. Especially since in the following sentence where the term "text field" is used, rather than "input".

Per that reasoning, I read the MAY is essentially saying a combobox could be:
<input role=combobox aria-label=foo>
or
<div role=combobox aria-label=foo tabindex=0 ...>value</div>

Regardless if i'm incorrect here or not, I do agree there could be some wording updates to clarify. Confusion about the use of input here strengthens my opinion that #1345 is a good idea.

@JAWS-test
Copy link
Contributor Author

I interpret the use of input in the initially quoted sentence as being related to the first sentence's use of the input abstract role.

What speaks against it are the following facts:

  • Wording: "input" versus "input field"
  • Layout: code element and no code element
  • meaning: combobox is an input (i.e. has as superclass role the abstract role input), but combobox can not combine the abstract role input with selection functionality, but only a non-abstract role with selection functionality, I would say.

@scottaohara
Copy link
Member

your points don't change my interpretation, but rather stress the need for wording updates to clarify.

@JAWS-test
Copy link
Contributor Author

I suggest to change the following sentences

A combobox functionally combines a named input field with the ability to assist value selection via a supplementary popup element. A combobox input MAY be either a single-line text field that supports editing and typing or an element that only displays the current value of the combobox.

to

A combobox functionally combines an element for value input or an element for displaying the current value with the ability to assist value selection via a supplementary popup element. If the combobox allows text input, an input field (<input type=text>) MUST be used. If the combobox does not allow text input, an element without implicit ARIA role MUST be used (e.g. <div>).

It would also be good to add a new example after Example 6 that shows a combobox at a <div> element

@jnurthen jnurthen added this to the ARIA 1.3 milestone Nov 5, 2020
@mcking65 mcking65 self-assigned this Jan 4, 2021
@spectranaut spectranaut added the clarification clarifying or correcting language that is either confusing, misleading or under-specified label Sep 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clarification clarifying or correcting language that is either confusing, misleading or under-specified
Projects
None yet
Development

No branches or pull requests

5 participants