The dark mode site is using the logo from Light mode instead of Dark mode?

I just upgraded to the latest commit. The dark mode site is using the logo from Light mode instead of Dark mode. The new commit has some code related to dark mode logo.

@pmusaraj

FIX: do not override logo markup when loading page in dark mode · discourse/discourse@1a7391a · GitHub

Could you please check.

Thanks.

1 Like

Can you describe your settings a bit please?

I’m guessing you have set a dark scheme and also added logos in the new dark mode logo settings?

2 Likes

I have the following settings:

  • Dark theme enabled (Theme is enabled by default)
  • Color Palette - Dark
  • Both Logo dark and Mobile logo dark are added in Settings (different than the light mode logos)

When I am in the dark mode site, the logo that I added for Light mode is used instead of Dark mode logo.

This happened after i upgraded to the latest version today.

2 Likes

Thanks, I can reproduce your issue and I am working on a fix.

6 Likes

If you go into your Chrome (if you are using Chrome) Settings, there is a Beta setting that will allow all Image / Video elements on a webpage to be inversed (colorwise) after the webpage is set to dark mode. If that helps, then I guess you could do that for now.

@Moksh this should be fixed now via https://github.com/discourse/discourse/commit/3c06dd9b9994a171f6571186429db84090c983bc.

3 Likes

@pmusaraj

I rebuilt discourse with your latest commit.

Here is the proof for latest version:

There are multiple problems:

On Desktop:

  1. Under themes, Enabled the Light theme as default, the instance doesn’t switch to Light :frowning: for anonymous user.

  2. If I am logged in, if I set the theme as Light for the user, the light theme works

On mobile:

  1. Both for logged in and anonymous user, the instance is not picking up the color palette that was set for the dark and light theme but it picks up the default dark and light palette. Basically on mobile both Dark and Light themes are broken.

  2. The light theme for anonymous user doesn’t work even though it was enabled as default.

Thank you.

1 Like

Hmm… the items you are raising now are different from the issue raised in the original post. After rebuilding, did the correct logo show up when you opened the site in dark mode (and had the Dark theme set as default)?

1 Like

Yes, both the logos are picked up but something fundamental on how Light and Dark themes must work based on the color palette is broken. This broke just now after your bug fix.

I am sure that the dark/light theme logos broke today morning when I took the latest version. I don’t know what is the cause for this issue and from which commit in the latest version.

Thank you

1 Like

Just to close the loop here, I discussed this issue privately with @Moksh and he was seeing the dark theme because the default dark mode color scheme id site setting was set to the Dark color scheme and the device/browser was in dark mode.

Will close this topic now and post a new topic in #feature:announcements about this very new feature.

3 Likes