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

Allow role=combobox for button and input type=button #3353

Closed
Tracked by #396
scottaohara opened this issue Jan 15, 2022 · 7 comments
Closed
Tracked by #396

Allow role=combobox for button and input type=button #3353

scottaohara opened this issue Jan 15, 2022 · 7 comments
Labels
fix Bug fixes pr A pr has been created for the issue standards Issues in the ARIA standards objects (lib/standards)

Comments

@scottaohara
Copy link
Contributor

ARIA in HTML is planning to allow role=combobox on a button and input type=button element.

button role=combobox test case

Additionally, the ARIA in HTML PR adds role=checkbox as an allowed role for input type=button to match the button element allowances. This was an oversight in the spec which this PR will help correct.

scottaohara added a commit to scottaohara/axe-core that referenced this issue Jan 16, 2022
closes dequelabs#3353

- Adds `role=combobox` to the `<button>` element.
- Adds `role=combobox` and `role=checkbox` to the `<input type=button>` element.
@WilcoFiers WilcoFiers added fix Bug fixes standards Issues in the ARIA standards objects (lib/standards) labels Jan 19, 2022
@MattyBalaam
Copy link

How do I configure the latest version of Axe to pass when a button has the role of combobox?

@scottaohara
Copy link
Contributor Author

I don't think the PR for this change has landed yet, @MattyBalaam.

@WilcoFiers what else needs to happen here? I think I addressed what I needed to in the PR? Understood if other priorities have punted this, but it's unclear what else is needed if not just 'time'?

@MattyBalaam
Copy link

I was wondering if someone had a tip for some config which can be used as a workaround while we wait for this to land.

@straker
Copy link
Contributor

straker commented Nov 15, 2022

For a workaround you can configure the standards object to allow it, similar to what the pr is doing

axe.configure({
  standards: {
    htmlElms: {
      button: {
        allowedRoles: [
          'checkbox',
          'combobox',
          'link',
          'menuitem',
          'menuitemcheckbox',
          'menuitemradio',
          'option',
          'radio',
          'switch',
          'tab'
        ]
      }
    }
  }
})

@scottaohara I think this might have fallen through the cracks (as well as a few other of your prs). I'll go back and look into them.

@straker straker added the pr A pr has been created for the issue label Nov 22, 2022
@adcortes
Copy link

adcortes commented Dec 1, 2022

@straker , hi, i am using the axe DevTools plugin on chrome and the <button role=combobox"> seems not updated yet.
Is it in process?
I am using:
DevTools
extension: v4.41.0
axe-core: v4.4.2

@straker
Copy link
Contributor

straker commented Dec 1, 2022

@adcortes We are planning a release later this month which should include this change. After axe-core releases, it'll probably be another couple of weeks or so before it is released into the extension.

@padmavemulapati
Copy link

padmavemulapati commented Dec 5, 2022

Validated with the latest axe-core develop branch code base,
test-snippet:


  <button id=b role=combobox>test 1</button>
  <input id="c" role="checkbox" />

seeing aria-allowed-role failing on button , role=combobox and for input - role=checkbox

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fix Bug fixes pr A pr has been created for the issue standards Issues in the ARIA standards objects (lib/standards)
Projects
None yet
Development

No branches or pull requests

6 participants