Skip to content

fix: overlay positioning for v3 submenus (aka non viewport containers)#9343

Merged
LFDanLu merged 6 commits intomainfrom
fix_submenu_v3
Feb 9, 2026
Merged

fix: overlay positioning for v3 submenus (aka non viewport containers)#9343
LFDanLu merged 6 commits intomainfrom
fix_submenu_v3

Conversation

@LFDanLu
Copy link
Member

@LFDanLu LFDanLu commented Dec 13, 2025

Closes

✅ Pull Request Checklist:

  • Included link to corresponding React Spectrum GitHub Issue.
  • Added/updated unit tests and storybook for this change (for new code or code which already has tests).
  • Filled out test instructions.
  • Updated documentation (if it already exists for this component).
  • Looked at the Accessibility Practices for this feature - Aria Practices

📝 Test Instructions:

Go to the v3 Submenu docs and verify that the submenu renders as expected

🧢 Your Project:

@rspbot
Copy link

rspbot commented Dec 13, 2025

snowystinger
snowystinger previously approved these changes Dec 15, 2025
Copy link
Member

@snowystinger snowystinger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested against #7654 and while it doesn't cause flipping, it does stop it from rendering the popover completely out of view, so it's an improvement for that. I tested some other PRs which appear to have been fixed along the way and didn't find a regression with this change.

I tested in various popover stories with different window widths and heights as well as with position relative etc and didn't find any new issues.

@snowystinger
Copy link
Member

Other PRs to check against:
#6333

@LFDanLu LFDanLu changed the title fix: (WIP) v3 submenu positioning in the docs fix: overlay positioning for v3 submenus (aka non viewport containers) Feb 5, 2026
@rspbot
Copy link

rspbot commented Feb 5, 2026

@LFDanLu
Copy link
Member Author

LFDanLu commented Feb 6, 2026

@snowystinger I forgot to revert the previous changes where we duplicated the old calculatePosition code which may have influenced the testing results, pushed an update. Additionally, I tested against #6333 but unfortunately still got the same issue, we will have to investigate that separately. I have the test story stashed locally, lemme know if you wanna check it out

@rspbot
Copy link

rspbot commented Feb 6, 2026

@LFDanLu
Copy link
Member Author

LFDanLu commented Feb 9, 2026

merging for testing, will need to make a call if it is worth the risk over the current approach

@LFDanLu LFDanLu added this pull request to the merge queue Feb 9, 2026
Merged via the queue into main with commit 0efd2d4 Feb 9, 2026
29 checks passed
@LFDanLu LFDanLu deleted the fix_submenu_v3 branch February 9, 2026 17:40
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.

4 participants