mirror of
https://github.com/carbon-design-system/carbon-components-svelte.git
synced 2025-09-15 18:31:06 +00:00
fix(multi-select): resolve a11y violations (#1072)
- role="listbox" children require the role="option" attribute - add a "aria-multiselectable" attribute to the listbox menu - move "aria-label" attribute from listbox to listbox menu - listbox field should not have a "combobox" role when expanded (the non-filterable variant serves as a button)
This commit is contained in:
parent
a5f5550aa0
commit
30a5f2c201
2 changed files with 10 additions and 4 deletions
|
@ -45,7 +45,7 @@
|
|||
|
||||
<div
|
||||
bind:this="{ref}"
|
||||
role="{ariaExpanded ? 'combobox' : role}"
|
||||
role="{role}"
|
||||
aria-expanded="{ariaExpanded}"
|
||||
aria-owns="{(ariaExpanded && menuId) || undefined}"
|
||||
aria-controls="{(ariaExpanded && menuId) || undefined}"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue