Skip to content

[EuiPopover] Added will-change via JS to help with fuzzy animation#4527

Merged
cchaos merged 4 commits intoelastic:masterfrom
cchaos:fix/popover_fuzzy
Feb 17, 2021
Merged

[EuiPopover] Added will-change via JS to help with fuzzy animation#4527
cchaos merged 4 commits intoelastic:masterfrom
cchaos:fix/popover_fuzzy

Conversation

@cchaos
Copy link
Contributor

@cchaos cchaos commented Feb 16, 2021

Fixes #4521

According to these two links:

The best way to enhance animations in the browser is with will-change but adding this statically to class in CSS is costly so it's best to add it via JS only on instantiation. Luckily, we already were applying a style prop to the EuiPopover panel only when mounted so it was an obvious place to add this property.

before

Screen.Recording.2021-02-16.at.12.44.32.PM.mp4

after

Screen.Recording.2021-02-16.at.12.45.22.PM.mp4

Checklist

  • Check against all themes for compatibility in both light and dark modes
  • Checked in mobile
  • Checked in Chrome, Safari, Edge, and Firefox
  • [ ] Props have proper autodocs and playground toggles
  • [ ] Added documentation
  • [ ] Checked Code Sandbox works for the any docs examples
  • Added or updated jest tests
  • [ ] Checked for breaking changes and labeled appropriately
  • [ ] Checked for accessibility including keyboard-only and screenreader modes
  • A changelog entry exists and is marked appropriately

@kibanamachine
Copy link

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

@cchaos
Copy link
Contributor Author

cchaos commented Feb 16, 2021

One oddity that I noticed in Safari is the the contents of the super date picker's popover blinks upon opening. I checked with the published docs though and it's happening there too, so it's not related to this change.

Screen.Recording.2021-02-16.at.12.48.21.PM.mp4

@cchaos cchaos marked this pull request as ready for review February 16, 2021 17:53
@kibanamachine
Copy link

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

Copy link
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

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

Added a question, but this LGTM! I don't see any reason to avoid will-change in these instances.

@kibanamachine
Copy link

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

Copy link
Contributor

@snide snide left a comment

Choose a reason for hiding this comment

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

Tested and checked code. LGTM.

@kibanamachine
Copy link

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

@cchaos
Copy link
Contributor Author

cchaos commented Feb 17, 2021

Jenkins, test this

@kibanamachine
Copy link

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

@cchaos
Copy link
Contributor Author

cchaos commented Feb 17, 2021

Jenkins, test this

@kibanamachine
Copy link

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

@cchaos cchaos merged commit ee74aac into elastic:master Feb 17, 2021
@cchaos cchaos deleted the fix/popover_fuzzy branch February 17, 2021 19:08
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.

[EuiPopover][EuiSuperDatePicker] Blurry popover content when opening in Chrome

4 participants