- From: Marc Haunschild (Accessibility Consulting) <marc.haunschild@accessibility.consulting>
- Date: Sun, 7 Jul 2024 17:30:35 +0200
- To: Jan Hellbusch <jan@hellbusch.de>
- Cc: Bernat Lleonart <bernat.lleonart@proton.me>, w3c-wai-ig@w3.org
Hi Bernat, I always forget that I have to reply to all… Now that Jan already wrote the same, I’d like to add, that summary is the only native element with button role that allow heading semantics as a descendant - but no other roles afaik. So it’s a very exceptional exception. It’s because it’s meant for this very common topic. The power of native elements! Before using components and frameworks one should learn HTML - it’s necessary to understand everything else. Maybe look into aria-rules, details and summary, buttons, headings and how aria is different from native elements. If you don’t know the standards your code will never work like expected. -- Mit freundlichen Grüßen Marc Haunschild https://Accessibility.Consulting > Am 07.07.2024 um 13:50 schrieb Jan Hellbusch <jan@hellbusch.de>: > > Hi, > > children inside a button element are presentational, i.e. they won't be passed on to the accessibility tree. The button must be inside the heading. > > You might want to try > <details> > <summary><h4>heading</h4></summary> > ... expandable content ... > </details> > > Jan > >> -----Original Message----- >> From: Bernat Lleonart <bernat.lleonart@proton.me> >> Sent: Sunday, July 7, 2024 8:19 AM >> To: w3c-wai-ig@w3.org >> Subject: Aria role="heading" and aria-level inside buttons >> >> Hi >> >> I have this markup, and although the validator doesn't show any error, I'd like >> to know if it would create any problem to users with assistive technologies: >> >> <h1>Main heading</h1> >> <button><span role="heading" aria-level="2">Button with heading >> 2</span></button> <button><span role="heading" aria-level="3">Button with >> heading 3</span></button> >> >> <h4>Heading 4</h4> >> >> >> The validator outline shows that headings 2 and 3 are being skipped. >> >> Any help will be really appreciated. >> >> Thanks. >> >> -- >> >> Bernat Lleonart >> >> >> Enviat amb el correu segur de Proton Mail <https://proton.me/> . > >
Received on Sunday, 7 July 2024 15:31:12 UTC