0π
As you stated, -webkit-line-clamp: 2
may be a reason the animation wonβt play. However, overflow: hidden
should not prevent this if we use the animation property with a keyframe, to delay its timing.
In addition we can create the dropdown effect by using the transition property, and max-height.
Below is a version of your css, that will get you the transition you want π
You can adjust the property values for height, and timings for animation and transition, as you see fit.
Let me know if this helps π !
.description {
margin-bottom: 36px;
max-height: 500px;
transition: all ease-in 0.3s;
overflow: auto;
}
@keyframes delay-overflow {
from { overflow: auto; }
}
.description--hidden {
max-height: 40px;
overflow:hidden;
animation: 1s delay-overflow;
}
- [Vuejs]-How can I make a request and NOT wait for response before redirecting?
- [Vuejs]-Nuxt access component's method or data in hook fetch/asyncData
Source:stackexchange.com