Replies: 1 comment 1 reply
-
You can store what the computed placement (as a result of any flipping) is when it mounts for the first time in state, then pass that as the preferred/option |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, I'm trying to resolve an issue in Mantine with Popover dropdown positioning and could not figure out whether it is possible from floating UI docs. In Mantine we have components that have dynamic content which impacts the dropdown height. Currently, all dropdowns are used with
flip
middleware, which does not work well for dynamic content as it flips with height changes (see attached video).In this case, I think the better behavior will be to flip once when the dropdown node is mounted and then never flip again until the dropdown is unmounted.
What I've tried:
autoUpdate
. Does not work for me – I still need to usesize
middleware to make dropdown the samewidth as the target
Is there a way to implement this behavior as I've described or fix it other way?
video.mov
Beta Was this translation helpful? Give feedback.
All reactions