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

Document List: Add aria-expanded to dropdown menu example button #2561

Closed
timveld opened this issue Feb 28, 2024 · 10 comments · Fixed by #2623
Closed

Document List: Add aria-expanded to dropdown menu example button #2561

timveld opened this issue Feb 28, 2024 · 10 comments · Fixed by #2623
Assignees
Labels
♿ accessibility 🐛 bug Something isn't working
Milestone

Comments

@timveld
Copy link

timveld commented Feb 28, 2024

Waar

html|css - docunment list

Aanleiding

Op de uitvouwbare knopjes ("AFDELING 1.1 Algemeen") ontbreekt aria-expanded.

Werkzaamheden

aria-expanded toevoegen

Gebruikersimpact

Kritiek: als dit ook in de implementatie zit weet een blinde gebruiker niet dat de knop iets uitvouwt.

@tfrijsewijk
Copy link
Member

Aria attributen toevoegen in dropdown-menu.css-template.ts.

@tfrijsewijk tfrijsewijk added the 🐛 bug Something isn't working label Mar 18, 2024
@tfrijsewijk tfrijsewijk changed the title Document list: aria-expanded ontbreekt op uitvouwbare knopjes Document List: aria-expanded ontbreekt op uitvouwbare knopjes Apr 8, 2024
@hansgrimm
Copy link
Contributor

hansgrimm commented Apr 10, 2024

  • De issue gaat over document-list, maar de aanpassing moet in dropdown-menu.css-template.ts. Hebben we het dan niet over een aanpassing van dropdown-menu?
  • Als ik naar dropdown-menu.css-template.ts kijk, dan ga ik ervan uit dat de aanpassing in de button moet. Daar is neem ik aan een conditional voor nodig, net als de andere attributen. hoe doe ik dat?
  • De role in die button is menuitem of menuitemradio. Volgens https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles/menuitem_role is aria-expanded daar geen geldig attribuut voor.` @timveld wa vinde gij?

@hansgrimm
Copy link
Contributor

Okee, aria-expanded schijnt tegenwoordig te kunnen op role = menuitem: w3c/aria#454

Nu alleen nog op de knop toggelen, ik ga kijken of ik daar op eigen kracht uit ga komen :)

@hansgrimm
Copy link
Contributor

Volledig op het verkeerde been gezet vermoed ik. De aria-expanded moet volgens mij op de knop die het menu opent. Klopt dat, @timveld ?

@timveld
Copy link
Author

timveld commented Apr 11, 2024

@hansgrimm klopt, aria-expanded moet op de knop die het menu opent.

@tfrijsewijk
Copy link
Member

De issue gaat over document-list, maar de aanpassing moet in dropdown-menu.css-template.ts. Hebben we het dan niet over een aanpassing van dropdown-menu?

Klopt! Aangepast.

@tfrijsewijk tfrijsewijk changed the title Document List: aria-expanded ontbreekt op uitvouwbare knopjes Dropdown Menu: aria-expanded ontbreekt op uitvouwbare knopjes Apr 11, 2024
@hansgrimm
Copy link
Contributor

hansgrimm commented Apr 11, 2024

@timveld het dropdown menu webcomponent in Storybook (https://storybook.dso-toolkit.nl/62.18.0/?path=/story/core-dropdown-menu--anchors) doet het conform WCAG. Het probleem in deze issue is dat het statische uitgeklapte voorbeeld in html/css document-list geen (statisch) aria-expanded="true" attribuut heeft.
Is dit iets dat we toch moeten aanvullen? want als je het webcomponent inzet, moet het namelijk gewoon goed gaan.

@timveld
Copy link
Author

timveld commented Apr 11, 2024

@tfrijsewijk Web component is inderdaad wel correct.
Het voorbeeld moet ook kloppen, en volgens mij was de aanleiding ook dat dit ergens in een implementatie niet goed zat.
Maar als het web vomponent zeker wordt ingezet, is er misschien inderdaad weinig aan de hand.

@hansgrimm
Copy link
Contributor

@tfrijsewijk Web component is inderdaad wel correct. Het voorbeeld moet ook kloppen, en volgens mij was de aanleiding ook dat dit ergens in een implementatie niet goed zat. Maar als het web vomponent zeker wordt ingezet, is er misschien inderdaad weinig aan de hand.

Ik heb het voor de volledigheid toch maar aangepast :)

@hansgrimm hansgrimm changed the title Dropdown Menu: aria-expanded ontbreekt op uitvouwbare knopjes Dropdown Menu: Add aria-expanded to example button Apr 11, 2024
@hansgrimm hansgrimm changed the title Dropdown Menu: Add aria-expanded to example button Document List: Add aria-expanded to dropdown menu example button Apr 11, 2024
@tfrijsewijk
Copy link
Member

De Web Component implementatie van "Dropdown Menu" was goed, (de markupvoorschriften van de) HTML/CSS implementatie was niet goed.

Vooralsnog ondersteunen we beide implementaties. Hans heeft het bijgewerkt 👍

hansgrimm added a commit that referenced this issue Apr 11, 2024
…le button

fix lorem ipsum danger.js error by replacing it with corporate BS
@tfrijsewijk tfrijsewijk added this to the Next milestone Apr 11, 2024
iterox pushed a commit that referenced this issue Apr 15, 2024
…le button

fix lorem ipsum danger.js error by replacing it with corporate BS
iterox pushed a commit that referenced this issue Apr 15, 2024
…le button

* #2561 [Fixed] Document List: Add aria-expanded to dropdown menu example button

* #2561 [Fixed] Document List: Add aria-expanded to dropdown menu example button

fix lorem ipsum danger.js error by replacing it with corporate BS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
♿ accessibility 🐛 bug Something isn't working
Projects
Status: ✅ Done
4 participants