Description
- I have searched the Issues to see if this bug has already been reported
- I have tested the latest version
Summary
Describe how it should work, and provide examples of the solution, which might include screenshots or code snippets.
Hello and thanks for providing this reference implementation for Flowbite. I have a use case for the Popover that is not currently covered but can easily be added.
I am using a Popover component inside of a parent which is overflow: auto
set. This means the popover is cut off. See screen shot.
This is due to @floating-ui/react
using position: absolute
by default.
The good news is that useFloating
has a strategy
prop that can be passed to override this if necessary. In scenarios like mine, position: fixed
is needed. I did some testing, and it works well. See screen shot.
The popover is still attached to the reference element and scrolls along with it.
Context
What are you trying to accomplish? How is your use case affected by not having this feature?
Popover
should be updated to accept a strategy
prop of type:
strategy?: 'absolute' | 'fixed';
This is passed to useFloating
from the @floating-ui/react
library.
Without this feature, popovers are cut off in parents that have overflow other than visible
.
I'm happy to create a PR for this if it will help.