8000 Is there a way to position the popover with left and top instead of using translate ? · Issue #145 · alexkatz/react-tiny-popover · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Is there a way to position the popover with left and top instead of using translate ? #145

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

Open
jeffersonswartz opened this issue Dec 3, 2021 · 3 comments

Comments

@jeffersonswartz
Copy link

Thanks for making this awesome plugin.

Recently I have migrated from v4 to v7, I have made all the necessary code changes to make it work, but during render the popup is positioning itself with CSS translate property which makes components inside the popover position differently. As the popover content is dynamic in our project it is not possible to change all the content components. So is there a way to use CSS left and top property to position the popover?

Thanks in advance.

@hu1da
Copy link
hu1da commented Jan 6, 2022

'translate' property makes it very problematic with some resolution on chrome because it moves all the time and it rerenders itself constantly. I resolved it locally by overriding translate property with top and left. Can you consider fixing this chrome bug in future releases, please?

@tudor2004
Copy link

@hu1da how did you resolved it locally with overriding the translate property? can you provide an example

@peteygao
Copy link
peteygao commented Mar 6, 2023

Ditto on the issue experienced. Upgraded from v4 to v7 and the new translate positioning is causing positional rendering errors.

FYI for those investigating at home, this change was made during the switch to v6 (present in the earliest beta 6.0.0-beta release).

Will try to patch locally translate into top/left in a fork.

@tudor2004 The code for translate is here and here, presumably just replace it with top and left and that should work 🤷🏼‍♂️ .

EDIT: Created a fork, you can use it directly in your package.json via github:peteygao/react-tiny-popover-no-transform#3796802. The dist/ folder is included in master so it's pre-built.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants
0