Is your feature request related to a problem? Please describe.
When I scroll the parent, react-laag tries to reposition open layers. Mostly this works quite nicely, but sometimes I get very strange positioning (e.g. off the page, so it becomes invisible). An extreme example is when I have nested menus with scrolling parents layers (needed sometimes for long lists). Here is an example (also see screenshots).
Describe the solution you'd like
I would like react-laag to propose a solution to the repositioning problem when a parent layer scrolls. If that's not possible I'd like some advice on what to do in this scenario.
Taking inspiration from native browser elements (e.g. the native select input), they seem to handle it by closing the child layer when the parent scrolls. Is that an approach react-laag can do for me automatically? If not, any implementation tips?
Describe alternatives you've considered
I've considering adding an onScroll event listener to the parent layer, and using that to trigger closing of child layers
I've considered preventing scroll on the parent when the layer is open (more like a 'modal' approach)
Is your feature request related to a problem? Please describe.
When I scroll the parent, react-laag tries to reposition open layers. Mostly this works quite nicely, but sometimes I get very strange positioning (e.g. off the page, so it becomes invisible). An extreme example is when I have nested menus with scrolling parents layers (needed sometimes for long lists). Here is an example (also see screenshots).
Describe the solution you'd like I would like
react-laag
to propose a solution to the repositioning problem when a parent layer scrolls. If that's not possible I'd like some advice on what to do in this scenario.Taking inspiration from native browser elements (e.g. the native select input), they seem to handle it by closing the child layer when the parent scrolls. Is that an approach react-laag can do for me automatically? If not, any implementation tips?
Describe alternatives you've considered
onScroll
event listener to the parent layer, and using that to trigger closing of child layers(Optional) Do you want to work on this feature?
Additional context