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

[EuiAccordion] Replace translateZ with will-change #5806

Merged
merged 2 commits into from
Apr 20, 2022

Conversation

thompsongl
Copy link
Contributor

@thompsongl thompsongl commented Apr 15, 2022

Summary

Closes #3548

Using translateZ causes any position: fixed; content to render in the wrong location.
My guess is that transform: translatez(0); was used to either 1) force hardware acceleration of transition effects or 2) resolve rendering a bug in an old/unsupported browser.
If the latter, we're no longer affected. If the former, we can achieve hardware acceleration with will-change: opacity;; the other values are nice-to-haves in this case.

It's also very possible that we don't need to engage the GPU at all and even transform: translatez(0); was a preoptimization. In that case, we can remove will-change, too, but the current method will render more similarly to using translateZ.

Screen.Recording.2022-04-15.at.2.37.32.PM.mov

Checklist

  • Checked in Chrome, Safari, Edge, and Firefox
  • Checked for breaking changes and labeled appropriately
  • A changelog entry exists and is marked appropriately

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_5806/

@elizabetdev elizabetdev self-requested a review April 19, 2022 17:16
Copy link
Contributor

@elizabetdev elizabetdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! 🎉

Tested locally in Chrome, Safari, Firefox, and Edge.

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

Successfully merging this pull request may close these issues.

[EuiDragDrop] Draggable is way out of the context when start dragging
3 participants