Skip to content

Conversation

@Brynanders
Copy link
Collaborator

@Brynanders Brynanders commented Sep 11, 2018

Closes issue: (#215 )

How to Review And Approve

  • Go to the “files changed” tab, there you will have the option to leave comments on different lines.
  • Once the review is completed, find the “Review changes” button in the top right, select “approve” and click “Submit review”.

Valid use of duplicate accessible names
…-1-valid-duplicate-accessible-name-for-image.md

changed name and file name to reference "image(s)"
@Brynanders Brynanders self-assigned this Sep 11, 2018
@Brynanders Brynanders added reviewer wanted Rule Use this label for a new rule that does not exist already labels Sep 11, 2018
@Brynanders Brynanders changed the title Create SC1-1-1-valid-duplicate-accessible-name Rule: SC1-1-1-valid-duplicate-accessible-name Sep 11, 2018

## 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.

This comment was marked as resolved.

This comment was marked as resolved.

@audreymaniez

This comment has been minimized.

@Brynanders Brynanders changed the title Rule: SC1-1-1-valid-duplicate-accessible-name Rule: SC1-1-1-image-has-valid-duplicate-accessible-name Sep 11, 2018
@Brynanders

This comment has been minimized.

@Brynanders Brynanders changed the title Rule: SC1-1-1-image-has-valid-duplicate-accessible-name SC1-1-1-image-has-valid-duplicate-accessible-name Sep 11, 2018
@Brynanders Brynanders requested review from WilcoFiers, annethyme and audreymaniez and removed request for WilcoFiers September 11, 2018 15:55
@WilcoFiers

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>
```
Copy link
Collaborator

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.

Copy link
Collaborator Author

@Brynanders Brynanders Sep 13, 2018

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.

Copy link
Collaborator

@audreymaniez audreymaniez Sep 14, 2018

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.

@audreymaniez

This comment has been minimized.

@WilcoFiers
Copy link
Member

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 img elements and alt attributes. I don't think this happens with role=img elements, or with aria-label type stuff.

annethyme pushed a commit that referenced this pull request Sep 14, 2018
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
@Brynanders Brynanders changed the title SC1-1-1-image-has-valid-duplicate-accessible-name SC1-1-1-Image-accessible-name-uses-duplicate-placeholder-text Sep 17, 2018
…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).
Copy link
Contributor

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" or area element, or any HTML element with a semantic role of img, 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.
Brynanders added a commit that referenced this pull request Oct 15, 2018
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)
Copy link
Collaborator

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?

Copy link
Collaborator

@nitedog nitedog left a 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).
Copy link
Member

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

Copy link
Member

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

Copy link
Collaborator Author

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.
@Brynanders Brynanders changed the title SC1-1-1-Image-accessible-name-is-placeholder-text SC1-1-1-Placeholder-text-is-valid-accessible-name Feb 4, 2019
@Brynanders Brynanders changed the title SC1-1-1-Placeholder-text-is-valid-accessible-name SC1-1-1-placeholder-text-is-valid-accessible-name Feb 4, 2019
@jeeyyy
Copy link
Collaborator

jeeyyy commented Mar 21, 2019

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.

@jeeyyy jeeyyy closed this Mar 21, 2019
Brynanders added a commit that referenced this pull request Mar 26, 2019
* 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
@Jym77 Jym77 deleted the Brynanders-patch-1 branch November 26, 2020 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Agenda item On hold Rule Use this label for a new rule that does not exist already

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants