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

fix: Respect user's preferred theme even when JavaScript isn't enabled #169

Merged
merged 3 commits into from
May 21, 2020

Conversation

palant
Copy link
Collaborator

@palant palant commented May 20, 2020

Currently, theme selection won't work at all if JavaScript is disabled. This is unnecessary, media queries can be performed with CSS only. Only switching themes and storing user's preference requires JavaScript.

@palant palant requested a review from reuixiy May 20, 2020 14:35
Copy link
Owner

@reuixiy reuixiy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@palant palant merged commit 46522c6 into master May 21, 2020
@palant palant deleted the media-queries-nojs branch May 21, 2020 06:16
palant added a commit that referenced this pull request Jun 5, 2020
palant added a commit that referenced this pull request Jun 7, 2020
* refactor: Do not rely on JavaScript for code highlighting, make dark and light themes consistent

* fix: Image brightness reduction in dark mode should work with implicitly selected theme (regression from #169)

* chore: Rename dark-theme style file into them-switcher and removed unused code

* chore: Update resources folder

BREAKING CHANGE: Highlighting customization now works by overriding CSS variables, no longer by overriding theme-specific files
ulmefors pushed a commit to ulmefors/hugo-theme-meme that referenced this pull request Nov 22, 2020
ulmefors pushed a commit to ulmefors/hugo-theme-meme that referenced this pull request Nov 22, 2020
* refactor: Do not rely on JavaScript for code highlighting, make dark and light themes consistent

* fix: Image brightness reduction in dark mode should work with implicitly selected theme (regression from reuixiy#169)

* chore: Rename dark-theme style file into them-switcher and removed unused code

* chore: Update resources folder

BREAKING CHANGE: Highlighting customization now works by overriding CSS variables, no longer by overriding theme-specific files
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants