Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

X/Y layout changes when transform is applied #14

Open
OrionReed opened this issue Mar 29, 2024 · 0 comments
Open

X/Y layout changes when transform is applied #14

OrionReed opened this issue Mar 29, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@OrionReed
Copy link
Owner

OrionReed commented Mar 29, 2024

Ideally the layout should remain entirely unchanged while the Z-axis transforms are applied.

  • The body transform is set to rotateX(${state.rotationY}deg) rotateY(${state.rotationX}deg) scale(${state.zoomLevel})
  • Each node transform is set to translateZ(${THICKNESS}px) which is relative to its parent, leading to the stacking effect.

The issue is that other layout is affected by these transformations, as in this example below. I've slowed down the transformation for the layout change to become more apparent. These transforms are part of the CSS Transforms Module 2 spec, but I haven't found how/why they are affecting the rest of the layout

Screen.Recording.2024-03-29.at.03.45.28.mov
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant