]> git.ipfire.org Git - thirdparty/patchwork.git/commit
css: make diff colors more accessible
authorRobin Jarry <robin@jarry.cc>
Wed, 5 Oct 2022 14:24:05 +0000 (16:24 +0200)
committerStephen Finucane <stephen@that.guru>
Thu, 31 Oct 2024 23:11:16 +0000 (23:11 +0000)
commitc443cd9c0e96ca21842a188f9101b1a8244535ee
treebf63e9a2477bc1d83f8fe04b98c2a739d5142da9
parentfa14cf8480d9e515ed7a769adbd9eab33c6d82d9
css: make diff colors more accessible

The colors used to display patch diffs are confusing. The context color
is very similar to the added line color and the contrast between added
and removed lines is very low.

Originally, the choice of purple/blue (instead of the more common
red/green palette) may have been made with colorblindness accessibility
in mind. However, after inspecting the current colors with
colorblindness "simulators", I found that the low contrast was
consistent no matter what vision deficiency (if any) you might have.

Update the colors to use a more common red/green palette. Add background
colors to increase contrast for colorblind people. Use less confusing
colors for context and diff hunks. Use normal line height to prevent
background colors from overlapping. Use a different color for email
quotes (blue) to avoid confusion with added lines.

I have made a compilation of the current and updated color palette
previews for normal vision and all common color deficiencies. I also
included the same diff as seen from Github interface for reference.

Link: http://files.diabeteman.com/patchwork-diff-colors/
Signed-off-by: Robin Jarry <robin@jarry.cc>
htdocs/css/style.css
releasenotes/notes/make-diff-colors-more-accessible-82eda58a89984d46.yaml [new file with mode: 0644]