Bounce Animation
A bounce animation for elements
Demo
MAX
Acquire the MAX Plan
Unlock unlimited potential with our most advanced features and priority support.
Bounce Animation
This is a simple bounce animation that can be used for elements entering the viewport.
Installation
Copy and paste the following code into your project.
Add the class animate-bounce-custom
to the element you want to animate.
@layer utilities {
.animate-bounce {
animation: bounce 1s infinite;
}
@keyframes bounce {
from {
transform: translateY(0);
opacity: 1;
}
to {
transform: translateY(-25%);
opacity: 1;
}
}
}
Use the class animate-bounce-custom
to apply the animation to an element.
<div class="animate-bounce-custom">
<!-- Your content here -->
</div>