Skip to content

Theme Toggle Icon Does Not Switch Between Light and Dark Modes #237

@aryashantanu405

Description

@aryashantanu405

Description

The current theme toggle button always displays a sun icon (feather-sun), even when the theme is set to dark mode. This results in inconsistent UX, as the icon does not reflect the active theme (i.e., it should show a moon icon in dark mode).

✅ Expected Behavior

The icon should dynamically reflect the current theme:
🌞 Sun icon when theme is light.
🌙 Moon icon when theme is dark.

🛠️ Suggested Solution

Include both sun and moon icons inside the button element.
Toggle their visibility via JavaScript based on data-theme.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions