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

Fix: close nav menu when theme is toggled #745

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

afaaaq85
Copy link

@afaaaq85 afaaaq85 commented Nov 8, 2024

Description

This solved the issue #735. The issue was to enhance user experience by closing the mobile nav when switching between theme
Fixes #735

Changes:
I have used useRef hook to hook into menu icon and then use a function to set the value to unchecked of input (the menu icon is basically an input with type checked or unchecked). so when a user toggles the theme, this function is called that sets the input to unchecked, (making the menu close)

Type of change

  • New feature (non-breaking change which adds functionality)

Copy link

vercel bot commented Nov 8, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
developer-folio ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 8, 2024 3:33pm

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.

Make the navbar automatically close once we toggle the mode(light/dark) for a better user experience.
1 participant