-
Notifications
You must be signed in to change notification settings - Fork 0
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
fix: enusre sheet is animated correctly with new framer motion #2407
fix: enusre sheet is animated correctly with new framer motion #2407
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Amazing work @loodde and @Hadlabergman! ⭐
A properly working exit animation really makes it so much smoother as well!
Let's just rebase this on #2408 before merging, to make sure checks are passing and also to make sure a new version is released when merging.
|
Storybook Preview: https://606dcc0a2208ee00215fb2d9-ahxqjztygo.chromatic.com/ |
0f21208
to
c916466
Compare
With the framer-motion 11.0.18 update the sheet opening animation stopped working. This commit fixes that by moving the motion animation to wrap the dialog content and overlay. The sheet exit animation has been broken prior to the 11.0.18 patch and this commit also fixes that by conditionally rendering the dialog root with isOpen, as is described in the framer motion docs.
c916466
to
3dff286
Compare
I took the opportunity to fix the failing test and to also fix the commitlint issue. FYI @loodde |
Feel free to merge when you're ready @loodde. I'm off now, back in November 😅👶 |
With the framer-motion 11.0.18 update the sheet opening animation stopped working. This commit fixes that by moving the motion animation to wrap the dialog content and overlay. The sheet exit animation has been broken prior to the 11.0.18 patch and this commit also fixes that by conditionally rendering the dialog root with isOpen, as is described in the framer motion docs.
Kudos to @Hadlabergman for debugging!