-
Notifications
You must be signed in to change notification settings - Fork 71
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
Inner content gets instantly changed #39
Comments
My first impression was that this was implementation specific and outside the scope of the project, but the readme does say:
So my impression now is that this is a legitimate and unexpected issue. Interested in why it occurs. |
I'm having the same issue, however I think this is actually expected— it's the counter-scale at work. When the animation starts, the DOM elements have already changed dimensions (nothing can be done about that, since the CSS has already been updated via the triggering class change), the scale on the parent is the thing doing the animation from the previous size of the DOM node to the current size of the DOM node. The counter-scale is just taking the current size of the child DOM node and making sure it doesn't get warped/distorted by the parent's scaling, by scaling it back to the current size of the DOM node. Unfortunate, but expected. Here's a screenshot of the DOM mid-transition. You can see that the My first thought is that maybe if this lib were to resize the parent node (rather than scale), it might solve this, and even remove the need for a counter-scale all together. However, I have no idea if the author has tried that already and it's just a bad idea for other reasons. |
Hey, this is an edited version of the original demo. It doesn't behave as I'd expect it to.
https://codepen.io/MrG0lden/pen/mdVxvRp
I want the inner content to get transitioned smoothly as well.
The text was updated successfully, but these errors were encountered: