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

[Feature]: Improve NavigationMenu behavior for click-based triggers #1304

Open
2 tasks
blesildaramirez opened this issue Sep 19, 2024 · 2 comments
Open
2 tasks

Comments

@blesildaramirez
Copy link

Describe the feature

Currently, the disableHoverTrigger prop allows toggling the hover trigger for the NavigationMenu, which works as expected. When set to true, the menu will activate only on click. However, if the user loses focus or moves the cursor away from the submenu items, the menu closes immediately. I propose keeping the submenu visible until the parent menu is clicked again, providing a more consistent and user-friendly experience.

Additional information

  • I intend to submit a PR for this feature.
  • I have already implemented and/or tested this feature.
@zernonia
Copy link
Member

Hi @blesildaramirez ! When you mentioned submenu you mean the item inside <NavigationMenuContent />? Perhaps similar to #1315 ? 😁

@blesildaramirez
Copy link
Author

Hi @zernonia , you're right. It's the <NavigationMenuContent />. And yes it's similar to #1315, although my request is to only close the NavigationMenuContent when the NavigationMenuTrigger is clicked again, similar to how clicking it displays the NavigationMenuContent when disableHoverTrigger=true.

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

No branches or pull requests

2 participants