Adding disableGpuAcceleration prop to prevent blurriness caused by Popper.js gpuAcceleration #807
Closed
esinarta
started this conversation in
Show and tell
Replies: 3 comments
|
0 replies
|
I migrated the positioning to @floating-ui in v3.0.0, probably easy to achieve with it. Full migration guide: https://react-joyride.com/docs/migration Thanks |
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.
Background
Hi and thanks for your work on this great library! Apologies if this isn't the best place to put this suggestion because it's a little complicated. @johnnyoshika and I ran into this issue while using your library with our app and we made some changes that could be a potential contribution.
We made these changes to an older version of
react-floater(v.0.7.3) since that's the versionreact-joyridecurrently uses. We then changedreact-joyrideto reference this modified version ofreact-floater.If you decide this would be a worthwhile contribution, let us know how to best proceed.
Issue
When zooming in/out with the browser, the content inside the floater can be blurry due to Popper.js' use of CSS translate3d.
This can be fixed by disabling
computeStyle.gpuAccelerationin Popper.js: https://popper.js.org/docs/v1/#modifiers..computeStyle.gpuAccelerationThe difference is subtle, especially on high-res displays, and it may be difficult to see but here are screenshots for comparison:
computeStyle.gpuAccelerationenabledcomputeStyle.gpuAccelerationdisableddisableGpuAcceleration Prop
We added an optional
disableGpuAccelerationprop intoreact-floaterthat adds this option when a new Popper is created:examind-ai/react-floater@28c47e1
Then, we used this modified version of
react-floaterwithreact-joyrideto allow us to specifydisableGpuAccelerationthrough JoyRide'sfloaterProps.You can view the 2 repos here:
All reactions