[drupalImage] Rename "Text alternative" field label to "Alternative text"

Created on 7 February 2024, 5 months ago
Updated 14 March 2024, 4 months ago

Problem/Motivation

The alternative text field in the CKEditor5 image dialog reads "Text alternative". It would be better if it read "Alternative text". This would be consistent with the CKEditor media dialog as well as with how this content is normally referred to in the accessibility community.

Steps to reproduce

Steps:
1. Go to simplytest.me
2. Type core in the field
3. Select Drupal core, latest version
4. Click the button to create the site
5. Log in as admin
6. If the management menu is not displayed, click Manage
7. Click content
8. Click add content
9. Click Basic page
10. Click in the body field
11. Click the image icon in the WYSIWYG toolbar

Expected result: alternative text field is labeled "Alternative text"
Actual result: alternative text field is labeled "Text alternative"

The W3C, in its discussion of decorative images, refers to a text alternative which is presented outside of the alternative text field.

I believe that "alternative text" rather than "text alternative" is the correct label for this field. This is because the wording "alternative text" specifically makes it clear that it refers to text which is destined for the alt attribute on an image when the page is rendered. A "text alternative," on the other hand, could refer to any descriptive text for the image, regardless of whether it appears in the alt attribute or, as referred to in the linked W3C content, as visible text on the web page.

Proposed resolution

Edit "Text alternative" to "Alternative text"

Merge request link

Remaining tasks

User interface changes

Visible field label in image dialog changes from "Text alternative" to "Alternative text".

API changes

Data model changes

Release notes snippet

🐛 Bug report
Status

Fixed

Version

10.2

Component
CKEditor 5 

Last updated about 4 hours ago

Created by

🇺🇸United States Charles Belov San Francisco, CA, US

Live updates comments and jobs are added and updated live.
  • Usability

    Makes Drupal easier to use. Preferred over UX, D7UX, etc.

  • Accessibility

    It affects the ability of people with disabilities or special needs (such as blindness or color-blindness) to use Drupal.

Sign in to follow issues

Merge Requests

Comments & Activities

Production build 0.69.0 2024