Closed (fixed)
Project:
Drupal core
Version:
8.0.x-dev
Component:
forms system
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
19 May 2011 at 17:31 UTC
Updated:
29 Jul 2014 at 19:33 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #1
liam morlandComment #3
liam morlandDoes anyone know why this failed? Is it testing for a specific string in the required message, but that string is different on purpose because of this patch?
Comment #4
tstoecklerYes, exactly.
Comment #5
liam morlandThanks for your reply. In that case, the patch is fine, even though it fails the test. Is there something I need to do to get this patch reviewed by the appropriate people and it either committed or decided that this change won't be made?
Comment #6
tstoecklerWell for it to be committed, the patch needs to update the test files so that the tests pass again.
Comment #7
liam morlandThanks. This new patch version patches both the function and the tests.
Comment #8
liam morlandComment #9
tstoecklerI just found this on w3schools:
The < abbr > tag is not supported in IE 6 or earlier versions.
So as long we support IE6 we can't submit this as is. Also, I don't know if < abbr > is really the right tag here.
The example on w3schools is:
<abbr title="World Health Organization">WHO</abbr>Hmm...
Comment #10
tstoecklerOn the other hand, that just means, that IE6 won't style this element, i.e. it won't be red, as it will in all other browsers. Don't know if that's acceptable in terms of progressive enhancement. It's not really unusable...
Hmm... :)
Comment #11
liam morlandHere is an updated patch, rolled against the latest D8 and including CSS changes which mean that the patch creates no visual changes.
Comment #12
liam morlandComment #13
Everett Zufelt commented@Liam
I'm still not completely certain that we need this, as I feel like * is universally understood to indicate a required form field.
However, if it doesn't change appearance then this is more semantic, and cannot hurt accessibility.
I would like us to role all usages of * into the same patch, it is currently used to indicate unsaved changes on blocks that have been moved on the Block administration page, perhaps it is for all table rows moved with tabledrag. This would ensure consistency.
Comment #14
tstoecklerI think we need some form of proof or usage-example or whatever, that
<abbr>actually is semantically more correct here.Comment #15
liam morlandUsing abbr around a "required" asterisk comes directly from Techniques for WCAG 2.0, "H90: Indicating required form controls", Example 2.
Abbreviations don't have to consist of letters. Just as a11y is an abbreviation for accessibility and § is an abbreviation for section, * is an abbreviation for "this field is required".
Comment #16
Everett Zufelt commented@liam
This gets a +1 from me, provided that we roll all of the uses of * into a single patch for consistency.
See #925862: Asterisk is not semantic/accessible on re-ordered table rows
Comment #17
liam morlandHere is a new patch that takes care of all uses of *.
Comment #18
liam morlandComment #19
mgiffordThat's nice and simple. Applied it and it works great!
The only thing that stopped me from marking this RTBC is this part of the diff:
Isn't this identical?
Any reason not to backport it to D7? There are no text changes. Some possible theming changes though for some themes, so perhaps it will have to stay as a D8 enhancement. Looks like it could be fixed in the Accessible Helper module though.
Comment #20
liam morlandThere were a few lines in the original code with trailing spaces. My editor stripped them automatically, so they show up in the diff. I could role a patch without those removals if needed.
It is possible that themes may style the asterisks with selectors that use the span, so this is probably best as part of the Accessible Helper module.
Comment #21
Everett Zufelt commentedGood that the trailing whitespace was removed, that is difficult to identify when visually inspecting the patch. Definitely cannot be backported to D7.
If we can get some before and after screen-shots to show that there are no visible changes we can mark this RTBC
Comment #22
liam morlandBefore and after screenshots attached.
Comment #23
liam morlandThe tiny shift on the required marker screenshots is due to my mistake when I cropped the images.
Comment #24
mgiffordExcellent. Thanks for this Liam!
Comment #25
liam morlandCorresponding D7 Accessible Helper Module issue: #1091622: Asterisk is not semantic/accessible on re-ordered table rows
Comment #26
dries commentedLooks good. Committed this to 8.x. I'm not sure we want to backport this to 7.x as it could break themes.
Comment #27
mgiffordLiam, any thoughts as to whether we could include this in the Accessible Helper Module http://drupal.org/project/accessible
Comment #28
liam morlandThere is now a patch underway in #1091622: Asterisk is not semantic/accessible on re-ordered table rows.