hello friends of rblind. I am a sighted person who follows the kbin-core repo. I saw an issue #1143 opened recently regarding the use of alt
in markdown. I am having a hard time discerning whether it is a productive request or not.
I understand that rblind is not a free-of-charge accessibility consultation company. But I thought I would point out this issue in case anyone had an interest in contributing to the discussion.
If I am posting in error, please either remove it or notify me so I can remove or edit the post.
Here is the text of the issue:
See this post
Current widespread wisdom is that you should specify alt text with the format
![alt text](url)
but this ISN'T behaving as alt text. It's behaving as a label. It needs to be set to the alt text attribute on the image.True alt text doesn't need to be rendered out. It's a nice feature that apps like pixelfed give you a button to see the alt text, because it can give extra context, but this is a secondary feature. This would be great to add as well, but it's out of scope here.
Labels are meant for things like crediting the photographer. See any well written news articles for examples of this. This one has an image of some sharks as a header. You'll see underneath that it has an explanation and credits NIWA for the image.
There IS a way to specify labels in markdown, and leave the alt text in tact. The correct format is
![alt text](link "label goes here")
but this isn't currently recognised by kbin and the label gets completely stripped out. (link)You can verify this by using something like this plugin.
Notice how all the post images are marked as "Missing alt attribute"
Notice how things like the magazine icon don't render out their alt text "ArtemisAppPlayground Icon"
Further, see codberg's handling of images:
![alt text](https://upload.wikimedia.org/wikipedia/commons/thumb/6/66/SMPTE_Color_Bars.svg/320px-SMPTE_Color_Bars.svg.png "Label text here")
results in the following html:
<img src="https://upload.wikimedia.org/wikipedia/commons/thumb/6/66/SMPTE_Color_Bars.svg/320px-SMPTE_Color_Bars.svg.png" alt="alt text" title="Label text here">
(codeberg displays labels as tooltips)
I honestly think it's fine to keep using the first
[part]
as labels, mostly because this syntax is already widely in use, but I think the second(link "this bit")
should be set to the image's alt text attribute.
Hi, I've tried to clarify on the ticket, but I'll post it here as well. Please note this is specifically for Kbin, not Lemmy.
This is applicable to anywhere markdown text is supported. Mostly thread text, and comments.
I've only tried externally hosted images (URL)
Yes, this is specifically about supporting hand written markdown. There are two variants:
A)
![alt text here](url)
B)
![alt text here](url "label")
This ticket is both a bug report:
neither variant actually populates the
alttext html attribute
And a feature request:
Support variant B) above in some way to allow more meaningful alt text
Example rendered currently:
A)
![alt text here](url)
This format should at least populate the
alt
attributeB)
![alt text here](url "label")
Currently renders exactly the same as A) with the
"label"
being completely stripped out.There are two possibilities for this format:
Either 1)
Or 2)