Start a new topic

Stop displaying the image description as a caption in lightbox (and ideally allow for writing both separately)

(I don't really know html, please excuse me if I confuse terms and concepts!)


When I first joined cohost I was excited to see that you're able to set a caption for the lightbox view of an image. Only later reading this forum I realized this is supposed to be an alt text for screen readers in the first place. I think it is a bad idea to display an image description as a caption. I see in the inspector that it is both inserted as an alt and as a title but I don't know which of these then turn into a lightbox caption, but I think displaying what is supposed to be an alt text in the tooltip is also a bad idea.


I think tumblr way of making the image description also easily reachable to sighted users who don't use screen readers is perfect: the icon that indicates a description is present is displayed directly on the image, but contrarily to twitter's solution, very very faint (that way it doesn't distract from the image itself or obscure any details). Only when you mouseover the image the icon is displayed in full opacity and then you can easily notice and click on it!

image     image


The way it is done on cohost right now may potentially discourage from writing proper descriptions because it clutters the screen. Both in lightbox and when displayed in tooltip. (that is even not counting the issue right now that the longer the description is the smaller the image will display in the lightbox, because I have no doubts it will be eventually fixed)


I'm worried that bringing this to attention will make people think I'm indifferent to sacrificing accessibility for the aesthetics of my page, but my perspective is as a visual artist so it really does matter to me how the images are displayed. I also feel like what I personally post would be inherently uninteresting to blind users but I am concerned with my posts being an obstruction when shared by others and encountered on the homepage. (I have not talked to any screen reader users about that so I'm open to being corrected on any point!)


So what I ask for is:

• don't display the alt text as a caption in lightbox

• don't copy the alt text into the title attribute (I'm reading on the MDN that it is also bad from accessibility standpoint, aside from displaying in a tooltip)

• maybe copy tumblr's solution for accessing the alt text as a sighted user?

• ideally: also allow for writing a caption for the lightbox that is separate from the alt text (maybe it could be the title attribute and also display as a tooltip but I don't know if that's a bad html practice, maybe it is)


17 people like this idea

I was also thinking about suggesting something like this! It really isn't clear that the "caption" is meant to be alt text, and alt text and captions are, as far as I'm aware, different things that have different purposes in most contexts.  Many users do not add alternative text at all and I think this lack of clarity is part of the reason why.


Many users are already using the feature as a caption, adding additional information not in the image or adding an extra little joke. The jokes are fun and are nice to have but the additional information is often actually useful - e.g. saying what game a screenshot is from.


If there is a way to keep these kinds of additional captions while also allowing alternative text to be shown to users who need it then I think that would be ideal - but at the very least it should be made clearer to the user that there is a system for adding alternative text and that they are encouraged to do so.


I should add that I too am not a screen reader user so I can't say what would be ideal for them, and any changes should put their needs first.


1 person likes this

somewhatnifty, those are great points! I wrote this post from the perspective of already having learned that "description" is supposed to be an alt text but I don't know I would've learned that at all by now if I wasn't reading this forum! As a sighted user I put something in that field as a test and am rewarded with a caption (that is, like you noted, something entirely different than an alt text) so I conclude that this is what that field is for, adding a caption! I don't go into web inspector to see what attributes were added to the image, I just see there's a caption so this must be for that, right?

I have no idea why this comment posted in bold text! I deleted it to post it anew and to be very careful not to click on any formatting on accident, but it happened again. I apologize, I don't know what's going on ¯\_(ツ)_/¯

it's alt text if you mouse over the unexpanded version in a post.


mostly I'd prefer it stay just as alt text because the way it is now, adding alt text to make an image accessible also heavily impacts its expanded presentation, shrinking it and obscuring it. when I'm posting my photography, I want the image to speak for itself for folks who don't need a description.


1 person likes this
I think it'll be too difficult to get users that already don't caption images to start also writing separate alt text if it was separate from the caption. As an advanced user I would love to have more control over the lightbox images, but the current setup is at least serviceable to normal users. The current setup with the "caption" being copied to both the alt text and title fields means that screen readers will read them twice, which would be incredibly annoying for very long captions. Using the fields effectively and writing short dense descriptions is a bit of an art form. People using the title field in divs to make a joke tooltip mess up screen readers' ability to find and read the correct content on the screen and I don't think they know they're doing that. Unfortunately I don't have any ideas for how to get people to write captions in the first place nor how to handle having two separate fields in a good way... Making the text box for the caption way bigger would be a good start, which IIRC has been reported separately.

The thing is that caption is never necessary. It's just a bonus, a comment, an addendum. What should be encouraged are alt texts but:


1. them being displayed as caption suggests that the "description" field is actually for… writing captions (which is not at all the same as image description for screen readers). I wouldn't know it's supposed to be for an alt text if I wasn't reading this forum. You don't want users to treat a field for an alt text like if it was a field for a caption and you don't want to get people to write captions if what you actually want them to do is to write descriptions


2. displaying an alt text as a caption doesn't make any sense. An alt text is a replacement for an image, you don't need both of them on the screen at once. It would be nice to have a granular control over the post and to be able to write a caption separate from the alt text but what I'm really asking for in this thread is to not display the latter like if it was the former


You can have the text box for the description bigger if you want to encourage people to use it and also you can have a separate field for a caption tucked away somewhere under a menu, both at the same time.

And the current setup with the same text being copied to alt and title attributes should be changed instead of expected to be worked around by users. For the reason you mentioned, so that the screen readers don't read the same thing twice


3 people like this

realizing a further consequence of what I said above: alt text functioning the way it does currently actively discourages me from putting alt text on my photographs because it makes them even harder to see


3 people like this

re: atomicthumbs, that was one of my points also! I was nervous talking about it because I didn't want it seem like I disregard the needs of screen reader users just for the presentations sake… but when I make a page specifically to build a visual art archive then I feel it's justifiable for me to care about visual presentation of content that only has visual value in the first place (not implying that for your photographs, talking about my art specifically!)


1 person likes this

I would love to have alt text work more like Twitter. I feel very strongly about adding descriptive text for accessibility and always try to do it, but if I'm using the caption field I have to choose between paring it down to a few details or basically telling people who can see my work how to look at it (which is especially weird if they don't know they're reading alt text, a thing I had not considered). That's much easier when I know people who aren't using screenreaders will probably never bother to look at the text.


3 people like this
Login or Signup to post a comment