@hellouxpavel/cssanimation
Version:
A Powerful CSS Animation Library for Advanced Motion Design.
68 lines (57 loc) • 1.51 kB
CSS
/*!
* Module: glitchScanBurst Animation
* Usage: <div class="cssanimation ca__fx-glitchScanBurst">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) ;
}
@media (prefers-reduced-motion: reduce) {
.cssanimation,
.cssanimation span {
animation: none ;
transition: none ;
}
}
/* stylelint-enable */
.ca__fx-glitchScanBurst {
animation: glitchScanBurst 1.4s ease-out both;
}
@keyframes glitchScanBurst {
0% {
clip-path: polygon(0 100%, 100% 100%, 100% 100%, 0 100%);
transform: scaleY(1.1);
filter: brightness(0.1);
opacity: 0;
}
30% {
clip-path: polygon(0 0, 100% 0, 100% 20%, 0 20%);
filter: hue-rotate(60deg);
}
60% {
clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%);
filter: brightness(1.2);
}
100% {
transform: scaleY(1);
opacity: 1;
filter: none;
}
}