react
react copied to clipboard
SelectPanel inside Dialog v2 footer incorrectly chooses its anchor side on opening (memex)
Description
Hi!
While using a SelectPanel inside of the Dialog V2 footer (via the renderFooter prop); it appears that the SelectPanel does not correctly pick the direction to open in, which leads to the panel opening off the page downwards.
Such as:
However, I am unable to reproduce this when rendering the same SelectPanel inside of the dialog's body, which indicates most likely an issue with the dialog footer wrapping container not properly communicating it's position on the screen (probably related to the anchor positioning logic: https://github.com/primer/behaviors/blob/main/docs/anchored-position.md)
Steps to reproduce
- Create a Dialog V2
- Ensure that the dialog has enough contents such that it fills most of the screen
- Render a Select Panel in the dialogs footer
- Open the panel, and observe it will always go off the bottom of the screen (opening downwards) regardless if it overflows.
Version
v36.0.0
Browser
Firefox
👋 @keithamus curious if you think this might be something we could easily solve as part of the active work on Dialog with <dialog> https://github.com/github/primer/issues/2531?
Yeah this should be resolved implicitly. I’ll double check as we get a shippable version.
👋 from the Issues team, @lesliecdubs would you happen to have an estimate for when this would be fixed? I see an epic being linked here but the last update was from 3 weeks ago (and it has no target date).
👋 Hi @japf, we're currently on target for 8 December for completion of the Dialog refactor, including fix of this bug.
@lesliecdubs - 👋 Based on @keithamus 's last update, are we on track for the Dialog updates here? Can we test out the updates in Issues?
We failed to reach the target date due to the holiday period and so work has rolled over into this Q. As we start integrating I can take a look at this particular bug to ensure it has been resolved.
@keithamus has this been resolved?
Other work was prioritised over this so it has not been resolved.
@keithamus do we have a timeline for when this could be resolved?
It's not in our OKRs for this quarter so it's unlikely for us to get around to this in the next few months. Perhaps we will pick this work up in September.