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

Make repositioning less glitchy #61

Open
rijk opened this issue Jan 21, 2021 · 1 comment
Open

Make repositioning less glitchy #61

rijk opened this issue Jan 21, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@rijk
Copy link
Contributor

rijk commented Jan 21, 2021

Here's a screen capture of what I mean:

Screen.Recording.2021-01-21.at.10.34.06.mov

There's a 1 frame glitch where the tooltip grows and is then repositioned:

image

This looks bad. Ideas for improvement:

  • Maybe it's possible to do a calculation before render, like Framer Motion?
  • Be smarter how to position the layer. In this case, use bottom instead of top.
  • Add an option to disable repositioning after initial positioning (related to auto prop not acting as expected #55)
@rijk rijk added the bug Something isn't working label Jan 21, 2021
@rijk
Copy link
Contributor Author

rijk commented Feb 4, 2021

Be smarter how to position the layer. In this case, use bottom instead of top.

Popper JS does this BTW: https://popper.js.org/docs/v2/modifiers/compute-styles/#adaptive

Add an option to disable repositioning after initial positioning

I also enjoy the way Popper gives you more control over this (with an update() function you can call when you see fit). But it might not fit your vision for this library.

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