LGBTQ-of-the-day-bot icon indicating copy to clipboard operation
LGBTQ-of-the-day-bot copied to clipboard

TOP PRIORITY: Check image for a11y before posting

Open VickiLanger opened this issue 5 years ago • 3 comments
trafficstars

Describe the bug Sometimes text just isn't legible and therefore not accessible.

Expected behavior Background and text should be verified to be WCAG compliant together before being allowed to post

Screenshots

image with text that is def not accessible with the background

https://twitter.com/lgbtqotd/status/1321920117551353856

Additional context

A suggested fix I was given:

  • read rgb value of pixel wit python pillow
  • then use the map function to apply the side by side contrast formula
  • Then use map again to set the pixels meeting the contrast threshold to white and the rest to black, then flatten the numpy array and feed back to the image library to make a contrast image.

Don't forget to follow the bot on Twitter to see the hard work you put in.

VickiLanger avatar Oct 30 '20 01:10 VickiLanger

@VickiLanger do you still need help with this? :)

LuNoX avatar Jan 12 '23 08:01 LuNoX

@VickiLanger do you still need help with this? :)

This definitely still needs work. You're welcome to it if you like

VickiLanger avatar Apr 27 '23 23:04 VickiLanger