Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dark mode colors have low contrast #38525

Closed
3 tasks done
Clashsoft opened this issue Apr 28, 2023 · 4 comments
Closed
3 tasks done

Dark mode colors have low contrast #38525

Clashsoft opened this issue Apr 28, 2023 · 4 comments

Comments

@Clashsoft
Copy link

Clashsoft commented Apr 28, 2023

Prerequisites

Describe the issue

The new darkmode colors make text very hard to read due to bad contrast. Compare these screenshots:

Unmodified:

Unmodified

Text Color #eee:

Text Color #eee

Text Color #eee and Body Color #111 (bootstrap-darkmode):

Text Color #eee and Body Color #111 (bootstrap-darkmode)

I propose changing the $body-color-dark to something brighter like #eee for improved readability.

Reduced test cases

What operating system(s) are you seeing the problem on?

Windows, macOS, Android, iOS, Linux

What browser(s) are you seeing the problem on?

Chrome, Safari, Firefox, Microsoft Edge, Opera

What version of Bootstrap are you using?

v5.3.0-alpha3

@Clashsoft Clashsoft changed the title Provide a general summary of the issue Dark mode colors have low contrast Apr 28, 2023
@kusma
Copy link
Contributor

kusma commented May 25, 2023

FWIW, we've using the dark-mode (based on preference with JS) on docs.mesa3d.org, and we've gotten complaints from users about the lack of contrast in the dark-mode as well.

@mdo
Copy link
Member

mdo commented Jun 1, 2023

The color contrast in dark mode (#adb5bd to #1a1c20) is 8.26. I could see us going a little darker on the background and perhaps brighter on the foreground.

@Clashsoft
Copy link
Author

I see that the contrast works in theory, but as mentioned by @kusma and in my opinion, in practice it is still not readable for everyday text. Compare the comments here on GitHub, with a contrast ratio of 12.26:1.

kusma added a commit to kusma/bootstrap that referenced this issue Jun 23, 2023
This increases the default brightness for the body text-color in dark
mode, which inceases readability a bit.

It was also suggested to darken the background a bit, but we
unfortunately don't have a darker gray in our color palette. So for now,
let's increase the text-color by two notches, and leave the background
color as-is instead.
mdo pushed a commit that referenced this issue Jun 25, 2023
This increases the default brightness for the body text-color in dark
mode, which inceases readability a bit.

It was also suggested to darken the background a bit, but we
unfortunately don't have a darker gray in our color palette. So for now,
let's increase the text-color by two notches, and leave the background
color as-is instead.
@mdo
Copy link
Member

mdo commented Jun 25, 2023

Fixed by #38815.

@mdo mdo closed this as completed Jun 25, 2023
romankupchak93 pushed a commit to romankupchak93/bootstrap that referenced this issue Jan 5, 2024
This increases the default brightness for the body text-color in dark
mode, which inceases readability a bit.

It was also suggested to darken the background a bit, but we
unfortunately don't have a darker gray in our color palette. So for now,
let's increase the text-color by two notches, and leave the background
color as-is instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Status: Done
Development

No branches or pull requests

4 participants