Skip to content

aria-valid-attr-value should not fail aria-controls when aria-haspopup is used #4363

@WilcoFiers

Description

@WilcoFiers

Axe reports the following as an issue under aria-valied-attr-value because the #settings element doesn't exist until the button is activated.

<button aria-haspopup="true" aria-controls="settings">
  Settings
</button>

Axe-core has logic that allows this when aria-expanded="false" is on the button, but not without it. I think this exception should be extended to elements with aria-haspopup. Perhaps here it would be appropriate to report it as needs review instead of pass. We don't know whether the control is expanded or not.

Metadata

Metadata

Assignees

Labels

fixBug fixesrulesIssue or false result from an axe-core rulesupport

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions