UNPKG

@hellouxpavel/cssanimation

Version:

A Powerful CSS Animation Library for Advanced Motion Design.

72 lines (61 loc) 1.5 kB
/*! * Module: bouncyDrop Animation * Usage: <div class="cssanimation ca__fx-bouncyDrop">Your Content</div> */ /* stylelint-disable */ :root { --cssanimation-duration: 1s; --cssanimation-fill-mode: both; --cssanimation-infinite: infinite; --cssanimation-backface-visibility: hidden; --cssanimation-transform-style: preserve-3d; --cssanimation-will-change: transform, opacity; --cssanimation-display: inline-block; --move-distance: -800px; } .cssanimation { animation-duration: var(--cssanimation-duration, 1s); animation-fill-mode: var(--cssanimation-fill-mode, both); } .cssanimation span { display: var(--cssanimation-display, inline-block); } .infinite { animation-iteration-count: var(--cssanimation-infinite, infinite) !important; } @media (prefers-reduced-motion: reduce) { .cssanimation, .cssanimation span { animation: none !important; transition: none !important; } } /* stylelint-enable */ .ca__fx-bouncyDrop { animation: bouncyDrop 1.5s ease-in-out infinite; transform-origin: top center; display: inline-block; } @keyframes bouncyDrop { 0% { transform: translateY(-100%) scaleY(1.2); opacity: 0; } 30% { transform: translateY(10%) scaleY(0.8); opacity: 1; } 60% { transform: translateY(-5%) scaleY(1.1); } 100% { transform: translateY(0) scaleY(1); } } /** * Module: Bounce In * Filename: ca__BounceIn.css */ .ca__fx-bounceInTop { animation-name: bounceInTop; }