Problem/Motivation
The revisions overview page currently fails a11y testing because the link text is the same and are not differentiated with a title attribute and the radio buttons have no labels. Also related #2834253: Missing column headings in Revisions list.
| Comment | File | Size | Author |
|---|---|---|---|
| #17 | diff-3228798-17.patch | 3.77 KB | silvi.addweb |
| #15 | diff-a11y-3228798-15.patch | 3.78 KB | smulvih2 |
| #10 | diff-a11y-3228798-10.patch | 3.97 KB | joel_osc |
| #7 | a11y_diff.png | 224.72 KB | joel_osc |
Issue fork diff-3228798
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
joel_osc commentedHere is a patch that adds text to the radios and title attributes to the revert and delete links.
Comment #3
joel_osc commentedComment #4
joel_osc commentedShoot, wrong patch - here is the correct one.
Comment #5
joel_osc commentedComment #6
miro_dietikerGreat to see accessibility contributions, thank you!
Just a quick question:
Does this change anything in the static display to the user?
Or are all these titles invisible and only show on hover?
Comment #7
joel_osc commentedHi @miro_dietiker, sorry I should have included a screenshot. Here is a screenshot of this patch along with the patch from #2834253: Missing column headings in Revisions list which is also needed for accessibility. There are changes to the static display: the first is labels on the radios, which I think also provides better usability. And the second is the tooltip (title attribute) shown on delete/revert links to differentiate them.
Comment #8
smulvih2@joel_osc this is a great improvement! My only feedback is change "Version #xxx" with "Revision #xxx". For the buttons, something like "Delete revision #xxx" and "Edit revision #xxx".
Comment #9
joel_osc commentedThanks @smulvih2, I totally agree. Here is a new patch with that text changed.
Comment #10
joel_osc commentedNoticed a small regression in that when the current row is selected on one column the label did not disappear along with the button on the other column. Patch updated.
Comment #11
smulvih2Yep good call on the JS change, now I can't select a hidden radio with it's visible label. This looks good to me, including this patch in my project. Thanks!
Comment #12
phenaproximaQuestion: I heard somewhere that using the
titleattribute on links is not the best a11y practice, and that it would be better to embed a hidden span in the link text (which can be done with thevisually-hiddenclass that ships with core). Example:Am I correct in this understanding? I'm far from an accessibility expert, so I don't feel comfortable committing this until someone with more chops than me has signed off on this one. Maybe I can loop in someone from the core accessibility team.
Comment #13
starshapedThis is correct. Using visually hidden is a better accessible experience than using a title on the link.
Comment #14
phenaproximaOkay, kicking back for that adjustment, then! Sorry about that.
Comment #15
smulvih2@phenaproxima good call on title attribute VS invisible text. Patch attached implements your feedback.
Comment #16
edmund.dunn commentedThis worked well for us!
Comment #17
silvi.addweb commentedre-roll patch according to the latest code changes.
Comment #18
acbramley commentedPlease update to use an MR
Comment #20
silvi.addweb commented