-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Update the alt text description #14668
Conversation
help={ __( 'Alternative text describes your image to people who can’t see it. Add a short description with its key details.' ) } | ||
help={ | ||
<Fragment> | ||
<ExternalLink href={ __( 'https://www.w3.org/WAI/tutorials/images/decision-tree' ) }> |
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.
Is it intended this link value be localized?
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.
We're planning to copy the W3C alt decision tree tutorial to the Handbook so it can be translated. But yes, can be non-translatable for now, will adjust.
I expect it should be It may be reasonable to omit |
Last commit also removes a few trailing spaces (because my editor does that automatically). |
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.
Code looks good and it tests well.
Fixes #14326.
In core, the alt text description in the media views has been updated with the new text discussed and recommended by the accessibility team. See https://core.trac.wordpress.org/changeset/44900. See screenshots on https://core.trac.wordpress.org/ticket/41612#comment:39. Example:
Note: I'm going to update the core string to include the word "Describe" within the link.
This PR updates the equivalent descriptions in Gutenberg for the Image and Media+Text blocks.
The new text links to the W3C "alt decision tree" tutorial and clarifies to leave the alt text empty "when the image is purely decorative". Previously, this part of the text was "if the image is not a key part of the content". Agreed the terms "key part" added cognitive load and needed to be clarified.
ExternalLink
componenthelp
prop accepts also components: given the currentBaseControl
implementation there's no reason why it shouldn't accept components and this seems correct to mehelp
prop documentation inBaseControl
and all the derived components needs to be updated- Type: String|WPComponent|null
be appropriate?Screenshot: