Skip to content

Conversation

@swati99gup
Copy link

Summary

This PR fixes issue #431 by updating the theme switcher UI so the button displays the mode that will be applied when clicked (i.e. it now shows the next theme icon). Previously the button showed the current theme, which is confusing.

What I changed

  • Updated theme toggle logic so the button shows the target mode (sun icon for switching to light, moon icon for switching to dark).
  • Fixed footer logo filename and visibility classes so correct logo appears in each theme.
  • Added a small script to keep the toggle icon and logos in sync when html[data-theme] changes.

Why this fixes the issue

Users expect a toggle to indicate the action that will happen when pressed. Showing the opposite icon reduces confusion and follows common UI patterns.

Testing

  1. Open site in light mode — the theme toggle should display the dark icon (moon).
  2. Click the toggle — site switches to dark and the toggle now displays the light icon (sun).
  3. Open site in dark mode — the toggle should display the light icon (sun).
  4. Verify footer logos show the proper variant for each theme.

@netlify
Copy link

netlify bot commented Dec 11, 2025

Deploy Preview for stupendous-kringle-a86e81 failed.

Name Link
🔨 Latest commit c0ef7fb
🔍 Latest deploy log https://app.netlify.com/projects/stupendous-kringle-a86e81/deploys/693b2861da7cd70008aa5a37

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.

1 participant