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

New Tweak: Respect user's theme when in blog-view. #880

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

alleycatboy
Copy link
Contributor

Description

This tweak is great for users with dark color pallets that wish to not have blinding light when viewing other user's blogs with lighter themes.

I got the idea from this Suggestion Box comment here on how they'd like to still see the theme while keeping posts readable.

This allows for more comfortable post viewing while still seeing the splash of flair from

Note: this is only for the posts themselves. The surrounding theme of the blog is preserved.

Additional note: this respects all the color pallets (True Blue, Goth Rave, Cybernetic, etc.)

Inquiry

Since this doesn't truly affect the dashboard, simply the blog-view, is it appropriate to be included in Tweaks? Tweaks is defined to the users as "Miscellaneous dashboard options".

Would it be more appropriate for this to be a stand-alone script?

Note: this is not the same behavior as Themed Posts, as this is the user's pallet and not the target blog's theme.

Note: this is not the same behavior as disabling "Use blog colors when viewing blogs" as mentioned here. It preserves the surrounding theme.

firefox_BU0WVMVOcm

Technical Explanation

All this does is prevent the CSS variables of the blog from overriding the user's color pallet on posts by setting the color variables to inherit !important; and appends the style to the document head.

Testing steps

Just enable "Respect the user's theme on blog pages" under Tweaks!

It should only change the theme of posts in blog-view.

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.

None yet

2 participants