Repository navigation
60 ux improvement implement safe triangle for nested menu navigation - #714
Merged
NJevric merged 4 commits intoNov 16, 2026
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…for-nested-menu-navigation
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Adds a "safe triangle" to
TieredMenu,ContextMenu,MenubarandMegaMenu. Moving the mouse diagonally from a parent item towards its open submenu no longer switches to the sibling items the pointer passes over on the way. This follows the approach from Amazon's mega dropdown.How it works:
SafeTriangleutil in@openvue/core/utilsbuilds a safe area from the point where the pointer left the active item to the open submenu's box. It works for submenus opening to the right, to the left (flipped or RTL) and below (Menubar, MegaMenu).pointermovelistener is only attached while a submenu is open and is removed on close and unmount.No props, events, slots or pass-through keys changed. If the submenu element can't be found (for example its
idis overridden throughpt), the menu falls back to the old instant switching.Related issue
Closes #60
Checklist
pnpm run lintandpnpm run formatpass## [Unreleased]inCHANGELOG.md(skip for internal refactors, tests, CI, and docs typos)