Skip to content

Bug - SimpleList: arialabel should be applied to inner ul element #8249

@thatblindgeye

Description

@thatblindgeye

Describe the problem
When passing in aria-label to the SimpleList component, the attribute gets applied to the outer div. This causes axe to flag it as aria labels aren't well supported on div elements.

The aria-label should instead be applied to the ul element that gets rendered instead (currently the isGrouped variation applies an aria-labelledby, so this fix would most likely only need to be applied at line ~77 of the SimpleList code:

<div className={css(styles.simpleList, className)} {...props}>
{isGrouped && children}
{!isGrouped && <ul>{children}</ul>}
</div>

Metadata

Metadata

Type

No type

Projects

Status

Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions