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

[BUG] Dark/LIght mode button is not functioning #252

Open
aniket05singh opened this issue Jan 8, 2025 · 2 comments
Open

[BUG] Dark/LIght mode button is not functioning #252

aniket05singh opened this issue Jan 8, 2025 · 2 comments
Assignees
Labels
bug Something isn't working INTERMEDIATE SWOC Social Winter Of Code

Comments

@aniket05singh
Copy link

Description

1. Problem Statement
Currently, the website includes a button designed to toggle between light mode and dark mode, but the functionality is not working. This means users are unable to switch between different themes according to their preferences, which can negatively impact user experience. Light mode and dark mode are essential features for modern websites, as they provide users with the ability to select a theme that is most comfortable for them, based on lighting conditions or personal preference.

The absence of this functionality leaves the button inactive, leading to:

Reduced accessibility for users who prefer one theme over the other.
Limited personalization since users cannot switch to their desired visual preference.
Inconsistent user experience, especially on a website that promises such functionality but doesn't provide it.

2. Proposed Solution
To address this problem, I propose the following steps to implement a fully functional light mode/dark mode toggle for the website:

a) Detect User Preferences:
System-level detection: Leverage the prefers-color-scheme media query to detect whether the user prefers a light or dark theme based on their system settings.
Override with User Selection: Allow users to override this system preference by manually switching between light and dark modes through the theme toggle button.
b) Toggle Functionality:
Implement JavaScript (or relevant framework-specific methods) to switch between light and dark themes. This can be achieved by toggling a CSS class or updating local storage to remember the user's preference.

Please assign me this under SWOC

Screenshots

Screenshot (1042)
Screenshot (1043)

Any additional information?

No response

What browser are you seeing the problem on?

No response

@aniket05singh aniket05singh added the bug Something isn't working label Jan 8, 2025
@hirdeshds
Copy link

dear sir/mam please assign me this task under SWOC

@Mujtabaa07 Mujtabaa07 added the SWOC Social Winter Of Code label Jan 9, 2025
@Mujtabaa07
Copy link
Owner

@aniket05singh Assigned

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working INTERMEDIATE SWOC Social Winter Of Code
Projects
None yet
Development

No branches or pull requests

3 participants