react-clamp-lines icon indicating copy to clipboard operation
react-clamp-lines copied to clipboard

Clamping doesn't work if the ClampLines element is inside a RelativePortal

Open Flixbox opened this issue 4 years ago • 1 comments

https://codesandbox.io/embed/clamplines-weirdness-relativeportal-yo87m

Basically, the react-relative-portal package creates a new element at the exact position it would be at normally but the element is moved straight to the body. This causes issues with ClampLines - The lines are shown, but not clamped.

Flixbox avatar Aug 26 '19 11:08 Flixbox

I've added another example to the codesandbox with a ClampLines element in the root div. It's working perfectly fine in the root div, but doesn't clamp anything in the Portal.

Flixbox avatar Aug 29 '19 07:08 Flixbox