microsoft / fluentui

Fluent UI web represents a collection of utilities, React components, and web components for building web applications.
https://react.fluentui.dev
Other
18.53k stars 2.74k forks source link

Getting accessibility issue for Dropdown component #14214

Closed saloni268 closed 4 years ago

saloni268 commented 4 years ago

Environment Information

Describe the issue:

Multi-select Dropdown component is giving the following accessibility issues:

  1. 'aria-required-children: Ensures elements with an ARIA role that require child roles contain them'

This is coming for the complete dropdown callout section. In the how to fix section, it is mentioned,

  1. 'aria-allowed-attr: Ensures ARIA attributes are allowed for an element's role'

This is coming for each option in the dropdown. In the how to fix section, it is mentioned,

This is our code snippet from where multi-select Dropdown is created,

<Dropdown label='Label' id="multiselect-filter-dropdown" placeholder='Select a value' selectedKeys={this.getSelectedKeysMethod} multiSelect options={this.getOptionsMethod} styles={styles} responsiveMode={ResponsiveMode.large} onChange={this.onChangeMethod} onRenderTitle={this.onRenderTitleMethod} />

Actual behavior:

We have not assigned any ARIA attributes to the components, still it showing accessibility issues. We are not sure how to fix this or provide/remove ARIA attributes explicitly from within the component.

Expected behavior:

No accessibility issues should come up.

paulgildea commented 4 years ago

@smhigley FYI

saloni268 commented 4 years ago

Any updates on this?

saloni268 commented 4 years ago

Hi @paulgildea @smhigley, any update on this bug?

levymsft commented 4 years ago

@Github307 I was having the same issues and got it sorted updating to the latest version.

paulgildea commented 4 years ago

Thanks for the update @levymsft.

I'll closed this as fixed in the latest issue as no repo. Thanks!