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

Default color-schema seems to be "system", not "light" #934

Open
3 tasks done
tht opened this issue May 6, 2024 · 1 comment
Open
3 tasks done

Default color-schema seems to be "system", not "light" #934

tht opened this issue May 6, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@tht
Copy link

tht commented May 6, 2024

Expected Behavior

When disabling "dark"-mode I expect the site to be in "light".

Current Behavior

Disabling "dark"-mode (features.darkMode.enable = false) seems to switch to "system", instead of light. Disabling dark-Mode only seems to be hiding the icon to switch the color scheme.

So there seems no way to fix the site to dark or light. The switch only disables the icon to toggle it manually.

Possible Solution

IMO the default should be "light", not "system". When "dark"-mode is disabled the theme should always be "light" and not switch depending on the browser settings. This is just my two cents, maybe your view on this is different.

Steps to Reproduce

  1. Follow quick-start tutorial on https://toha-guides.netlify.app/posts/quickstart/
  2. Change config.yaml features.darkMode.enabled to false
  3. Start serving site with hugo server -w
  4. Check in a browser where dark-mode is default

Screenshots

Browsers Affected

Tested on these browsers, all of them show the same behavior.

  • Chrome
  • Firefox
  • Safari 17

Detailed Description

@hossainemruz
Copy link
Member

When "dark"-mode is disabled the theme should always be "light" and not switch depending on the browser settings.

Yes. I agree on that. When dark mode is disabled, it should set theme to light. If dark mode is enabled, then the default should be System. I will look into it.

@hossainemruz hossainemruz added the bug Something isn't working label May 7, 2024
dev-mkrause added a commit to dev-mkrause/mk-homepage that referenced this issue May 12, 2024
Enable theme toggle until hugo-toha/toha#934
is fixed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants