-
Notifications
You must be signed in to change notification settings - Fork 79
SC1-1-1-placeholder-text-is-valid-accessible-name #251
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
Conversation
Valid use of duplicate accessible names
…cate-accessible-name.md
…-1-valid-duplicate-accessible-name-for-image.md changed name and file name to reference "image(s)"
|
|
||
| ## Accessibility support | ||
|
|
||
| There is a known combination of a popular browser and assistive technology that does not by default support `title` as an accessible name. |
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
This comment was marked as resolved.
This comment was marked as resolved.
Sorry, something went wrong.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
| ```html | ||
| <a href="https://twitter.com/brynanders"> <img src="/twitter_largeicon.png" alt="Twitter"> </a> | ||
| <a href="https://twitter.com"> <img src="/twitter_smallicon.png" alt="twitter"> </a> | ||
| ``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand the example, but it mixes two elements : link and image.
If we want to keep that example, I think it would be necessary to add in the description, that the links both have the same context, so we can consider the two identical.
In fact, in that example, I think we don't evaluate the accessible name of the image, but of the link, and the accessible name of a link can be evaluate using the context (level AA 2.4.4 Link Purpose (In Context) : see for example the H78 technique (using enclosing paragraph), or H79 (using table context) etc... So, it's not because two links has the same accessible name (made of the alt attribute of the image in our eample) that they are the same, because of the context they may be part of.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@audreymaniez interesting. Are you suggesting that functional images should be non-applicable because they would be covered by #220 ? That would certainly make sense to me.
That would leave informative, complex and groups of images applicable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would leave informative, complex and groups of images applicable.
Well, in fact, I think that any kind of images you list (informative, complex...) become innaplicable if the image is included in a link. At the moment, an image is included in a link (complex or not), its alt attribute is not used anymore to describe the image but to give the link a name. And even more : an image that can be evaluated as a decorative one, must have an alt text if its included in a link.
So yes, I think that images, both within a link, with the same alt attribute and the same context, but that lead to different destination is a failed example for the test about identical links #220.
This comment has been minimized.
This comment has been minimized.
|
Thinking about it some more, I don't think unique image names in context makes sense. I think what I'd rather us do is rename this. It's kind of hiding its true intent: To catch "default" alt attributes. Duplicate alt attributes aren't a problem. What is a problem, is if you're leaving the default value of an editor in the image alt. E.g. alt="image description". Instead of suggesting this rule is looking for inappropriate duplicates, lets be explicit that this is testing for default values from authoring tools. I'd even feel comfortable to just look at |
Adding new paragraph on comparing acc names, that has so far been note in these rules: https://auto-wcag.github.io/auto-wcag/rules/SC2-5-3-label-content-name-mismatch.html #220 #251
Changing rule to address the use of placeholder text by identifying duplicate accessible names.
…d to SC1-1-1-image-accessible-name-has-placeholder-text.md
…md to SC1-1-1-image-accessible-name-is-placeholder-text.md Made significant changes to the rule which is now implementation specific so that authors can determine "placeholder texts" specifically with in reference to the (to be created) "placeholder text" definition.
| ### Applicability | ||
|
|
||
| The rule applies to HTML `input type="image" `and `area` elements or any HTML element with the semantic role of `img` [exposed to assistive technologies](#exposed-to-assistive-technologies), where the [accessible name](#accessible-name) exclusively uses [generic placeholder text](#generic-placeholder-text). | ||
| The rule applies to HTML `input type="image"` and `area` elements, or any HTML element with the semantic role of `img` [exposed to assistive technologies](#exposed-to-assistive-technologies), where the [accessible name](#accessible-name) exclusively uses [generic placeholder text](#generic-placeholder-text). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are input type="image" and area elements only applicable if they're exposed to AT? If so, the sentence should be restructured to reflect this:
The rule applies to any HTML
input type="image"orareaelement, or any HTML element with a semantic role ofimg, where the element is exposed to assistive technologies and has an accessible name that exclusively uses generic placeholder text.
Updated applicability to apply exposed to AT to all applicable elements.
Updated applicability to align as closely as possible with #251
| The element's accessible name uses generic placeholder text which accurately describes the image. | ||
|
|
||
| ```html | ||
| <img alt="oage"> (need a source file) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How can we judge that this is generic placeholder text without the surrounding context?
nitedog
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the logic for this rule is wrong. I think determining "generic placheholder text" (defined as "text content that is ambiguous in its meaning") should the condition check in the expectation rather than in the applicability. Also, this rule needs many more convincing test cases.
|
|
||
| ### Applicability | ||
|
|
||
| The rule applies to HTML `input type="image"` or `area` elements, or any HTML element with the semantic role of `img`, where the element is [exposed to assistive technologies](#exposed-to-assistive-technologies) and has an [accessible name](#accessible-name) that exclusively uses [generic placeholder text](#generic-placeholder-text). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
link semantic role to its definition
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Additionally, this should be applicable only to non-decorative images
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know what you mean but non-decorative is considered subjective and their fore cannot be included as part of the applicability as per Wilco's comment on the ACT rules format #263 (comment)
Removed the applicability note about 'decorative images' and added it to the 'decorative' definition.
Added a second sentence explaining what is meant by a decorative image technically speaking.
|
It was agreed on the WCAG call, that, this is not a failure rule, but this is a nice to have or needs review rule, so closing for now. |
* Create SC1-1-1-accessible-name-is-image-file-name.md * Update SC1-1-1-accessible-name-is-image-file-name.md Simplified applicability Changed 1st inapplicable test case. Added 2nd inapplicable test case * Update SC1-1-1-accessible-name-is-image-file-name.md * Update SC1-1-1-accessible-name-is-image-file-name.md Updated title and description to target `alt` instead of accessible name * Update SC1-1-1-accessible-name-is-image-file-name.md * Update SC1-1-1-accessible-name-is-image-file-name.md Updated Description and Applicability to limit rule to `img` `src` file name Updated test cases to use W3C image sources Updates Expectation to not reference WCAG failure technique * Update SC1-1-1-accessible-name-is-image-file-name.md * Update SC1-1-1-accessible-name-is-image-file-name.md Changed file name > filename. Updated applicability to include `input type="image"` and `area`. Changed "parameter" to "query string". Removed URL extension from Pass example 1 Added Inapplicable example 4 to include an example of `aria-label` overriding `alt`. * Update and rename SC1-1-1-accessible-name-is-image-file-name.md to SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md Minor text edit to Inapplicable example 4 * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md Made a load of minor edits but still need to agree on the filename match including file extensions or not. * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md Corrected **Pass example 1** * Update SC1-1-1-accessible-name-is-image-filename.md Changed description of **Inapplicable example 4** and updated all other descriptions to be more consistent. * Update SC1-1-1-accessible-name-is-image-filename.md Minor grammatical edit * Update SC1-1-1-accessible-name-is-image-filename.md Text edits and added a link out to the WCAG 2.1 definition of "Non-text content" * Update SC1-1-1-accessible-name-is-image-filename.md Updated applicability to align as closely as possible with #251 * Update SC1-1-1-accessible-name-is-image-filename.md Updated Expectation * Update SC1-1-1-accessible-name-is-image-filename.md Updated applicability * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md Grammer and consistency changes requested Audrey Maniez * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md Added non-decorative to the applicability. * Update decorative.md * Update SC1-1-1-image-has-name.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Updated applicability to use "non-decoratively" more broadly, to account for decorative `area` elements. * Added "Failure example 2" * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Fixed typo * Update SC1-1-1-accessible-name-is-image-filename.md Made grammatical changes and linked "semantic role" * Update SC1-1-1-accessible-name-is-image-filename.md Removed `area` from the applicability as it doesn't support `src`. Added Pass and Fail test cases for `input type="image"` * Update SC1-1-1-accessible-name-is-image-filename.md minor editorial edit * Update SC1-1-1-accessible-name-is-image-filename.md Changed title and bane to reflect expectations * Update decorative.md Added implementation detail as a note instead of including it as art of the main definition. * Update decorative.md * Update SC1-1-1-accessible-name-is-image-filename.md Fixed test case format * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md Updated applicability to remove "included in accessibility tree" and "decorative" * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md Re-included "included in the accessibility tree" in the applicability. Changed Inapplicable example 1 description to better describe the test case. Changed Inapplicable example 2 to reflect not "included in the accessibility tree". * Update SC1-1-1-accessible-name-is-image-filename.md * fixed spelling/typing errors * Update SC1-1-1-accessible-name-is-image-filename.md Minor editorial edit. * Update SC1-1-1-accessible-name-is-image-filename.md Minor template edits * Update SC1-1-1-accessible-name-is-image-filename.md * Update SC1-1-1-accessible-name-is-image-filename.md
Closes issue: (#215 )
How to Review And Approve