github-dark-theme icon indicating copy to clipboard operation
github-dark-theme copied to clipboard

Improve text contrast so theme does not fail accessibility rules

Open AndrewRayCode opened this issue 3 years ago • 3 comments

Most of the text is gray text on a gray background which fails accessibility guidelines. The most important place to address this is in places with large blocks of text: Readmes, wikis, and tickets.

Also in case there's a misconception: There doesn't need to be a separate "high contrast" accessible theme. This theme itself should be accessible by default.

AndrewRayCode avatar Oct 13 '20 03:10 AndrewRayCode

I assume that you mean text such as my username shown in the picture below

Vanilla Github dark theme
Before After

The title text on this PR passes for the most part and so does the text of the comments.

The slightly muted text (like the sub text under Assignees, Labels, Projects etc) on this issue do fail across the board which is an issue.

It would be a small but effective change to the project and I don't see why a PR would be straight up denied so if you're interested in doing it then go on right ahead and if not then I'm sure I can find some time to do it :)

IamCathal avatar Oct 13 '20 23:10 IamCathal

It would be cool to have a parameter to select the text color. It's too close from the background color making the read difficult. The contrast isn't enough.

ErwanAliasr1 avatar Nov 19 '20 09:11 ErwanAliasr1

Yes, the contrast is not right, for example in the comment boxes. It fails AAA and barely passes AA. Moreover, the WCAG ratings are for what they call "normal text", which is 18px, while the text on GitHub is 14px. So I believe the theme actually fails WCAG AA too at this pixel size.

To be honest, if you don't have a high DPI, high quality screen, it's easy to see that the text is hard to read.

laurent22 avatar Dec 03 '20 11:12 laurent22