Open CoreyGinnivan opened 4 years ago
I should have specified what this what relating to a bit more haha (still learning). This was to make the Low Vision, Cataracts and Glaucoma type be affected by smaller text (so it would fail under 12px or so).
The big reason for scrapping the font-size requirement was that it felt super wrong to have something that was very high contrast immediately fail everything if it was under 15px.
The WCAG spec is great most of the time, but some things just don't make too much sense.
But, you're right – it's just bare bones and based on the WCAG spec for now. We should be showing off the maths behind it a bit better. Maybe we could have the vision type rows clickable, and expand to show all the different fields it's passing/failing so it's easy to understand what's wrong.
Ah that makes more sense! I hadn't noticed that the WCAG spec didn't specify that. Definitely makes sense to drop the 15px requirement.
What would the fields be that it could pass or fail on under each field?
Potentially it could auto expand on each field if it fails to make it easy to quickly see what is going wrong? Although that could be too much information if it fails on too many fields.
It would be interesting to try and convey the math going on, maybe pull out the calculation from the tooltip on the grading and put it under the overall score. To stop it from crowding the screen could make that an expandable field as well to show more details if you're interested?
Actually I don't see font size taken into account at all? I tried using 1px font size and it still passes 🫣😅
Try this: https://www.whocanuse.com/?bg=663399&fg=ffffff&fs=1&fw=
As far as I know, WCAG doesn't specify a minimum font size for several reasons:
@cstrobbe ah yes good point! I learned about this recently, after trying to dig deeper into minimum font sizes (it is recommended to keep at least 12 from what I've read). Thanks for clarifying that!
Hey guys, love this project! It's exactly what we need at work right now. I found it wasn't very obvious how the font field affects the final score, is this issue to adjust how font size works in the algorithm that decides the final rating?
I found the getWcagScore.js file which looks like it’s based on 1.4.6 of the WCAG spec? And I can see that the requirement to be over 15px in font size was dropped.
Really happy to help out with this issue if I can, just wondering what the thinking is to build out the enhancement?