Skip to content

chore: Update Juice and tweak dark theme #978

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

Merged
merged 1 commit into from
Apr 14, 2025

Conversation

lanesawyer
Copy link
Contributor

@lanesawyer lanesawyer commented Apr 12, 2025

I was looking at the site tonight and it blinded me with the lack of a dark theme lol 🙈

This PR adds support for a dark theme by:

  • Updating the juice submodule to the latest version
  • Renaming generate_feed to generate_feeds to get the Zola site building again
  • Adding an override on the CSS for the codeblocks to fix a bad look with dark mode turned on
  • Adding an empty sideblock section to remove the placeholder from the Juice theme

Question

  • Should I look into tweaking the code styling? It's readable, but not fantastic...

Screenshot

Homepage

image

One of the sub-pages

image

@@ -4,7 +4,7 @@ title = "Trunk | Build, bundle & ship your Rust WASM application to the web"

compile_sass = true
build_search_index = true
generate_feed = true
Copy link
Contributor Author

@lanesawyer lanesawyer Apr 12, 2025

Choose a reason for hiding this comment

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

Saw this blast from the past when the git blame showed my name on this line lol. I put this in 4 years ago to add RSS feed support for the blog (#178)!

I noticed there is no more blog though, so maybe I do another PR to remove all the blog-specific templating and this config value?


// Fix the background color of the juice theme
.content pre {
background-color: var(--code-background-color) !important;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The !important is annoying, but Juice is applying a white background directly on the element so I can't override it otherwise...

Copy link
Collaborator

@ctron ctron left a comment

Choose a reason for hiding this comment

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

❤️

@ctron ctron enabled auto-merge April 14, 2025 07:17
@ctron ctron added this pull request to the merge queue Apr 14, 2025
Merged via the queue into trunk-rs:main with commit 6ec5f70 Apr 14, 2025
60 checks passed
@lanesawyer lanesawyer deleted the lane/update-juice branch April 14, 2025 16:43
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