Skip to content

Conversation

@Subham-KRLX
Copy link
Contributor

Implements Material theme palette toggle with three modes:

Automatic mode (follows system preference)
Light mode (default scheme)
Dark mode (slate scheme)
Users can now toggle between themes using the icon in the header. All modes preserve the existing deep orange primary and green accent colors.

Closes #2444

Implements Material theme palette toggle with three modes:
- Automatic mode (follows system preference)
- Light mode (default scheme)
- Dark mode (slate scheme)

Users can now toggle between themes using the icon in the header.
All modes preserve the existing deep orange primary and green accent colors.

Addresses apache#2444
@Subham-KRLX Subham-KRLX requested a review from jiayuasu as a code owner November 9, 2025 06:28
@github-actions github-actions bot added the root label Nov 9, 2025
@jiayuasu
Copy link
Member

jiayuasu commented Nov 9, 2025

can you show screenshots of both modes?

@Subham-KRLX
Copy link
Contributor Author

Screenshot 2025-11-09 at 12 15 09 PM Screenshot 2025-11-09 at 12 14 55 PM

@petern48
Copy link
Collaborator

petern48 commented Nov 9, 2025

Wonder why it's showing the old website (before the remodel). The branch is branched off recently, so it should have the commits. Maybe there's an extra step you need to take to apply the fancy formatting?

Here's what the current website looks like: https://sedona.apache.org/latest/

image

@petern48
Copy link
Collaborator

petern48 commented Nov 9, 2025

Anyways, this part of the screenshot doesn't look right (e.g "Apache Sedona" is shown twice). I'm not sure why it looks like that looking at your changes 🤔

image

@Subham-KRLX
Copy link
Contributor Author

Thanks for reviewing @petern48!

I'm not sure why the screenshot is showing the old website design or the duplicate "Apache Sedona" text. My changes only modified the theme.palette section in mkdocs.yml to add the light/dark/auto mode toggle - I didn't touch any template files or other styling.
When I tested locally with uv run mkdocs serve, the site rendered correctly with the current design and the theme toggle working as expected in the header.
Could this be a caching issue or something with how the preview is being generated? The duplicate title seems odd since I only added palette configuration, not any HTML/template changes.

@petern48
Copy link
Collaborator

petern48 commented Nov 9, 2025

I agree the behavior is odd. Regardless of your good intentions, we need to make sure this change only does what we want it to do any not modify things unintentionally. To check, you should build the docs on main (ie. without your changes) and compare it to the display of the docs after you apply these changes. Post screenshots here.

When I tested locally with uv run mkdocs serve, the site rendered correctly with the current design and the theme toggle working as expected in the header.
Could this be a caching issue or something with how the preview is being generated?

This is your screenshot. If it really did render correctly, why don't you attach a screenshot of that? If that's the case, what was the screenshot you sent earlier than?

@Subham-KRLX
Copy link
Contributor Author

@petern48 I verified the layout issues you mentioned
Screenshot 2025-11-10 at 11 01 33 AM
they’re not caused by my changes.
Master branch: Layout issues present no theme toggle
My branch: Same layout issues, but theme toggle works perfectly
I only modified the palette section in mkdocs.yml (no template or layout changes). The issues appear to come from the local mkdocs serve setup, not this PR.
Attaching screenshots for reference. The theme toggle correctly switches between light, dark, and auto modes.
Uploading Screenshot 2025-11-10 at 10.49.28 AM.png…

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Idea: We should implement Dark and Light Theme Switch on the website

3 participants