Add dark mode toggle to Discourse

Can the forum admin please add a dark mode toggle switch for the Discourse forum theme?

Something like this Dark/Light Mode Toggle - theme-component - Discourse Meta

1 Like

It’s already available.

3 Likes

You’re misunderstanding the request. Did you look at the example link I posted?

The request is for a toggle switch on the main page, right next to the search icon and hamburger menu. One click.

Not the built-in setting that is five clicks deep.

1 Like

Given the nature of the constituents, I’ve always wanted to see a dork mode.

2 Likes

Is there an option to make it follow automatically the system color scheme? The Discourse instances of GNOME and Fedora communities allow that, but I do not know what extension they use. I would prefer to have the theme changed automatically instead of having to click anywhere to change it each time.

2 Likes

That’s what I would prefer as well, but I couldn’t find any examples on how to install or enable that feature.

If you can find any, please update this thread with a link.

Toggle switch is my second choice.

2 Likes

Yes:

2 Likes

@JCS ?

2 Likes

I made these changes. Toggle works in a private window but not with my logged-in user for some reason…

4 Likes

Great work. Due to a bug, you will need to change your Discourse theme preference to Light for the toggle to function properly.

1 Like

Looks as if “Light” is now broken though.

1 Like

Explain how it is broken.

I don’t want dark mode but it seems there is no way to make it look the way it did before. When I choose light mode, it looks more like dusk mode. :wink:

1 Like

Right, light mode does look quite different, but the theme itself is not broken. The contrast of the interface’s symbols are not web accessible.

Looks strange. This is with my darkened, enlarged fonts active.

1 Like

Unsure what you mean by that.

While composing this reply … I now have grey icons against a grey background - and I have black text against a grey background. That seems like poorer contrast than before.

I had no problems with, you know, black icons and text against a white background - and I have absolutely no problem with someone preferring and choosing a “dark” theme in order to get approximately the opposite of that.

1 Like

In @amarok’s screenshot, the heart, link, and ellipsis icons are only slightly darker than the gray background, so they are difficult to notice.

1 Like

That’s what I am saying. Something is “broken”.

1 Like

Looking at other Discourse forums, that gray background is supposed to be white when using the light theme.

Looks even worse without my font adjustments applied:


Very low contrast.

1 Like