Skip to content

Commit

Permalink
improve animation
Browse files Browse the repository at this point in the history
  • Loading branch information
GrandSchtroumpf committed Dec 18, 2024
1 parent bd2b8a4 commit ca70ab0
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
13 changes: 13 additions & 0 deletions src/components/activity/ActivityExport.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -48,3 +48,16 @@
.export-button:disabled .loading {
transition-delay: 200ms;
}
.export-button:disabled .loading path {
transform-origin: center;
animation: rotate 0.6s linear infinite;
}

@keyframes rotate {
from {
transform: 0;
}
to {
transform: rotate(360deg);
}
}
11 changes: 1 addition & 10 deletions src/components/activity/ActivityExport.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -120,16 +120,7 @@ export const ActivityExport = () => {
<path
fill="currentColor"
d="M43.935,25.145c0-10.318-8.364-18.683-18.683-18.683c-10.318,0-18.683,8.365-18.683,18.683h4.068c0-8.071,6.543-14.615,14.615-14.615c8.072,0,14.615,6.543,14.615,14.615H43.935z"
>
<animateTransform
attributeName="transform"
type="rotate"
from="0 25 25"
to="360 25 25"
dur="0.6s"
repeatCount="indefinite"
/>
</path>
/>
</svg>
</button>
{!!size && size > limit && (
Expand Down

0 comments on commit ca70ab0

Please sign in to comment.