-
Notifications
You must be signed in to change notification settings - Fork 561
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
Extra span in portal triggering flex issues. #902
Comments
Similar issue but causes warnings when rendered in context where span is not suited (like tbody). |
I'm thinking we should add a prop to |
chaance
added a commit
that referenced
this issue
Apr 20, 2022
Fixed in v0.17.0 |
Thanks! |
chaance
added a commit
that referenced
this issue
Jul 15, 2022
This was referenced Aug 2, 2022
This was referenced Aug 10, 2022
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
🐛 Bug report
Current Behavior
I've got a menu button inside a flex container. This extra span is causing me grief (layout shift):
menu-button.mov
Here's what it looks like before hydration:
Here it is after hydration:
Expected behavior
Wrapping the button in a flex container makes the sibling span trigger a content shift.
Reproducible example
https://stackblitz.com/edit/node-qppzt9?file=app%2Froot.tsx
Suggested solution(s)
Maybe don't render anything on the server render?
A workaround (that I'm implementing) is to wrap the
<Menu>
inside a<div>
so the sibling span doesn't end up messing up the flex flow. But this was surprising.Additional context
This seems to only be a problem when server rendering.
Your environment
The text was updated successfully, but these errors were encountered: