Skip to content

Instantly share code, notes, and snippets.

@una
Created February 9, 2015 17:14
Show Gist options
  • Save una/6a3d70e394fa22d64b73 to your computer and use it in GitHub Desktop.
Save una/6a3d70e394fa22d64b73 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
<div class="box"></div>
// ----
// Sass (v3.4.11)
// Compass (v1.0.3)
// ----
// Animations
@keyframes fadeIn {
0% { opacity: 0; }
100% { opacity: 1; }
}
@keyframes fadeOut {
0% { opacity: 1; }
100% { opacity: 0; }
}
@keyframes scaleBounce {
0% { transform: scale(1);}
80% { transform: scale(3);}
100% { transform: scale(2.8);}
}
@mixin animate($args...) {
.info {
arg-length : length($args);
all-args: $args;
}
@each $animation in $args {
.animation {
content: $animation;
}
}
}
@include animate( fadeIn 2s ease-in 0,
scaleBounce 2s ease-in 0,
fadeOut 3s ease-in 5s )
@keyframes fadeIn {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
@keyframes fadeOut {
0% {
opacity: 1;
}
100% {
opacity: 0;
}
}
@keyframes scaleBounce {
0% {
transform: scale(1);
}
80% {
transform: scale(3);
}
100% {
transform: scale(2.8);
}
}
.info {
arg-length: 3;
all-args: fadeIn 2s ease-in 0, scaleBounce 2s ease-in 0, fadeOut 3s ease-in 5s;
}
.animation {
content: fadeIn 2s ease-in 0;
}
.animation {
content: scaleBounce 2s ease-in 0;
}
.animation {
content: fadeOut 3s ease-in 5s;
}
<div class="box"></div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment