Skip to content

Instantly share code, notes, and snippets.

@developertugrul
Created August 5, 2023 13:28
Show Gist options
  • Save developertugrul/489a084011b852cad6b16b2c3b722419 to your computer and use it in GitHub Desktop.
Save developertugrul/489a084011b852cad6b16b2c3b722419 to your computer and use it in GitHub Desktop.
a sahke animation for a button
.non-animated-btn-btn:hover {
transform: scale(1.05);
animation: svelte-k9qwtc-jittery 4s infinite;
}
@keyframes svelte-k9qwtc-jittery {
5%,
50% {
transform: scale(1);
}
10% {
transform: scale(0.9);
}
15% {
transform: scale(1.05);
}
20% {
transform: scale(1.05) rotate(-3.5deg);
}
23% {
transform: scale(1.05) rotate(3.5deg);
}
26% {
transform: scale(1.05) rotate(-2.5deg);
}
30% {
transform: scale(1.05) rotate(2.5deg);
}
35% {
transform: scale(1.05) rotate(0);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment