Move element placement calculations out of container-block? #2167
Unanswered
J4v4Scr1pt
asked this question in
Support
Replies: 1 comment
-
Working sandbox: The other two draggbleButtons is ouside of the main page and you need to zoom out to see them. |
Beta Was this translation helpful? Give feedback.
0 replies
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.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi!
This may be a really stupid question but Im calculating where I should place a component I'm creating. This works as long as I dont place the component inside some div deeper down the page Html hierarchy. Then the placement is calculated based on it's closest containing block. But my component uses position: fixed, this should take it out of the document flow, and no other parent element has a breaking css (like transform, filter, etc.)
Is there any way of telling useSpring to base it placment calculation on the window/viewport rather than its closest parent container?
This is a big component will provide the necessary parts of it.
This image shows the parent containers and where the components calculations is based on:

If there is anything other I need to provide or I explained badly please let me know 😊!
Beta Was this translation helpful? Give feedback.
All reactions