[wp-trac] [WordPress Trac] #47456: Improve the user interface to ensure correct usage of the image alt text

WordPress Trac noreply at wordpress.org
Mon Jan 27 23:17:09 UTC 2020


#47456: Improve the user interface to ensure correct usage of the image alt text
-------------------------------------------------+-------------------------
 Reporter:  afercia                              |       Owner:  (none)
     Type:  defect (bug)                         |      Status:  new
 Priority:  high                                 |   Milestone:  5.4
Component:  Media                                |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  wpcampus-report needs-design-        |     Focuses:
  feedback needs-patch                           |  accessibility
-------------------------------------------------+-------------------------

Comment (by azaozz):

 Replying to [comment:13 joedolson]:
 > Just thinking about some of what would need to be done for this, it's a
 pretty substantial challenge

 Yes, it will require a lot of changes to how things currently work. Also
 to user "workflows" and UI.

 > Need to be able to account for multiple uses in a single instance. E.g.,
 a featured image used on the single post screen serves a different purpose
 than a featured image linked from an archive page.

 Right. As "featured images" are a specific use case, the image alt text
 should be handled specifically for them. That would mean adding (some) UI
 for entering alternate strings, and having a simple, bulletproof way for
 themes to get the correct string for each context. Then will need to look
 at what is the best way to store these alternate text strings, where and
 how (but these are implementation details, they are relatively "easy" once
 the workflow(s) and the UI are decided).

 > Handling alt attributes in posts is relatively trivial; the inserter
 places the image in a direct context that can be decided on at the time.
 Programmatically associated images would be much, much harder to handle

 Yes, providing context for "programmatically associated" images will (most
 likely) need to be done on a case by case basis. As featured images are
 the most common case, getting the alt attribute text to work well there
 will most likely be reused elsewhere.

 > There are a lot of mechanisms that would need to be created to make that
 work - the editor interface is relatively trivial, but usages of media
 outside of post content raise a lot of questions.

 Yeah, thinking this should probably be done in stages as it would need a
 lot of changes in many different places.

 Perhaps the first stage should be to ensure there is suitable/good UI for
 adding (contextual) alt text in all blocks that add images. Then hide the
 field in the media modal and stop auto-adding alt text when inserting
 images in the editor.

 Then update the featured image UI and the way it works, and suggest
 (require?) the user enters appropriate alt text for at least the "known"
 contexts. It may be possible to make (some of) this into an API for more
 general use for adding contextual alt text(s) for programmatically
 associated images.

 Thinking that the sooner this - the better, but it most likely will take
 more than a single release cycle to accomplish. At the same time there are
 other tickets about handling image alt text, like #30180, that would
 depend on progress on this ticket.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/47456#comment:14>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list