-
Notifications
You must be signed in to change notification settings - Fork 15
Description
I really like the idea behind this action! However, the first few images I tried to test it with didn’t get flagged like I expected.
In the first instance, I happened to drag an image into the text area that had a filename that wasn’t “Screenshot ” (it was “edit-link.png”). I’m not sure if there’s a good way to identify stuff like this (maybe check alt-text with no spaces against a dictionary? tough to handle lots of languages, though…).
In the second instance, I tried just deleting the alt text entirely (all the variations of <img alt="" ...>, <img ...> (no alt attribute at all), and ). These seem more obviously straightforward to identify, and it would be nice if they were caught by this action.
As a side note, I thought I’d configured something wrong because of the above. The first thing I did was look at the action’s logging output, and it would have been a little bit helpful to have the two outputs (whether an image was flagged and the type of thing being checked) labeled so I knew what they were:
accessibility-alt-text-bot/action.yml
Lines 62 to 63 in b8484e1
| echo $flag | |
| echo $type |
(e.g. echo "Detected bad alt text: ${flag}" would have been helpful.)