[a11y] Compatibility with RGAA (French WCAG) #16109
Unanswered
cspiga
asked this question in
Ideas / Proposals
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello ! My team is working on an app that will be used by french universities. For the frontend, we've chosen to work with Vue and Quasar.
An external agency made an accessibility audit. Following it, we've made some fixes to our code to improve our app, but we've listed some changes we think can't be made without modifying Quasar directly.
Missing tags and attributes, customize all aria-labels.
According to RGAA, field must be accessible through screen readers.
QStepper
current header step must have aaria-current="step"
attribute.QTable
must include a<caption>
tag.QTh
sorting button must have anaria-sort
attribute.aria-label
s are misplaced, it could be simpler to add/remove those fields, or to define slots to change them (onQBtnDropdown
,QExpansionItem
).Change span tags to buttons.
According to RGAA, field must be accessible through keyboard navigation.
The spacebar may be used to "click" on some elements of the interface, so
<button>
tags are needed on some elements.QChip
must be rendered with a<button>
if used in a<select>
.QExpansionItem
must be rendered with a<button>
. Then,tabindex
should not be a descendant of this element.QField
clearable
: the generated<div>
must include a<button>
tag with atitle
attribute.QTh
sorting button must be rendered with a<button>
.HTML Validation.
According to RGAA, generated source code must be valid.
Testing an app with the W3C Markup Validation Service returns various errors :
QBreadcrumbs
,QBreadcrumbsEl
: Attributehref
not allowed on element<a role="listitem">
at this point. (roleslist
andlistitem
are needed)QBtnDropdown
: An element with the attributetabindex
must not appear as a descendant of thebutton
element.QBtnDropdown
,QSelect
: Thearia-controls
attribute must point to an element in the same document.QField
: Elementdiv
not allowed as child of elementlabel
in this context.QImg
: Animg
element must have analt
attribute, except under certain conditions. (some images can have an emptyalt
attribute, but the component removes them)QOptionGroup
in aQField
: Anyinput
descendant of alabel
element with a for attribute must have anid
value that matches that for attribute.QOptionGroup
in aQField
: Thelabel
element may contain at most onebutton
,input
,meter
,output
,progress
,select
, ortextarea
descendant.QOptionGroup
in aQField
: The value of thefor
attribute of thelabel
element must be the ID of a non-hidden form control.QSeparator
: Attributearia-orientation
not allowed on element<hr role="presentation">
at this point. (role
is needed)Customize all roles.
According to RGAA, we should pay attention to the presentation tags and attributes.
Some roles are misplaced it could be simpler to add/remove those fields, or to define slots to change them (on
QBtnDropdown
,QTabPanel
,QToolbar
).Structure lists.
According to RGAA, list must be correctly structured.
QPagination
buttons must be structured with<ul>
and<li>
tags.QStepper
headers steps must be structured with<ol>
and<li>
tags.[Bug ?] Restructure error management.
According to RGAA, field control is needed.
An attribute
aria-invalid="true"
must be set onQField
if control is not met. May be already implemented through this pull request #9988 , but the attribute doesn't show in our app (even if an error message is shown).Also, error message must be structured with
<p>
tags, which can be done withv-slot:error
, but we haven't seen if it's possible to set this slot with therules
attribute, to get multiple error messages.Maybe some of those changes can be made in our code directly. We haven't used Quasar a lot, so there may be some tweaks we can do on our side.
Thanks in advance !
Beta Was this translation helpful? Give feedback.
All reactions