Open ddouglasz opened 1 month ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
mc-app-kit-playground | ❌ Failed (Inspect) | Jun 17, 2024 8:36am | ||
merchant-center-application-kit-components-playground | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Jun 17, 2024 8:36am |
Latest commit: dcc992804f3196591c893461e17fc91d1a5fd3af
The changes in this PR will be included in the next version bump.
Not sure what this means? Click here to learn what changesets are.
Click here if you're a maintainer who wants to add another changeset to this PR
Thank you @ddouglasz for working on this ❤️ I've briefly checked it in the playground and for the most part it works fine, when the cursor motion is steady. However, if I stop in the middle / change the pace of the movement, then the submenu hides.
I've noticed in the screencast from the description that the safe triangle only changes when cursor moves within the menu item boundaries. If it goes beyond the menu item, the triangle is set for good.
In case of the implementation the triangle shrinks whenever cursor moves towards the submenu, so maybe this makes the behaviour not consistent
Thank you Kacper 🙏🏾 I will look into it and push a fix.
I've noticed in the screencast from the description that the safe triangle only changes when cursor moves within the menu item boundaries. If it goes beyond the menu item, the triangle is set for good.
@kark thanks for your feedback again, after a couple of findings, I discovered a flaw with this implementation: When a user begins to navigate diagonally and then stops halfway to move to the next item, vertically, they are blocked because the triangle is set for good until we close the submenu.
Perhaps the current implementation that allows the the safe-start
point of the triangle to move is what I see is consistent with most implementations:
If the users delays in the diagonal navigation, then it closes the submenu and focuses on the next item the cursor is hovering on.
Would be nice to know what @FilPob also thinks about this 🙏🏾
I've noticed in the screencast from the description that the safe triangle only changes when cursor moves within the menu item boundaries. If it goes beyond the menu item, the triangle is set for good.
@kark thanks for your feedback again, after a couple of findings, I discovered a flaw with this implementation: When a user begins to navigate diagonally and then stops halfway to move to the next item, vertically, they are blocked because the triangle is set for good until we close the submenu.
Thanks! Perhaps we should consider adding a timeout for the triangle, similar to what we can see in your MacOS screencast. 🤔
I've noticed in the screencast from the description that the safe triangle only changes when cursor moves within the menu item boundaries. If it goes beyond the menu item, the triangle is set for good.
@kark thanks for your feedback again, after a couple of findings, I discovered a flaw with this implementation: When a user begins to navigate diagonally and then stops halfway to move to the next item, vertically, they are blocked because the triangle is set for good until we close the submenu.
Thanks! Perhaps we should consider adding a timeout for the triangle, similar to what we can see in your MacOS screencast. 🤔
Updated here: https://github.com/commercetools/merchant-center-application-kit/pull/3536/commits/25c5b476da0f27e4acf695003b7eb8d09869fbb3 Thank you.
This PR is missing a Jira ticket reference in the title or description. Please add a Jira ticket reference to the title or description of this PR.
🥷 Code experts: emmenko
emmenko has most 🧠 knowledge in the files.
To learn more about /:\ gitStream - Visit our Docs
Summary
Using the Safe triangle pattern to improve submenu navigation
Description
Improve the submenu navigation by adding a safe area for users to smoothly navigate diagonally between the main menu and the submenu items, without awkwardly going out of focus.
Background: https://x.com/shadeed9/status/1745707615517032449?t=XnNt9gNwPHLyfrMfHEnFuA&s=03
Before:
After (The visible triangle is only for the demo. It is not included in the PR):