Skip to content

Commit

Permalink
Hide cards until animation starts
Browse files Browse the repository at this point in the history
  • Loading branch information
tekktrik committed Jan 31, 2024
1 parent a71c713 commit 8e4d84e
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
19 changes: 16 additions & 3 deletions flask_app/static/css/animations.css
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,18 @@
InitClear calc(var(--duration, 1s) + var(--delay, 0s)) ease-out var(--delay, 0s) 1;
}

@keyframes Reveal {
0% {
height: 0;
opacity: 0;
}

100% {
height: auto;
opacity: 1;
}
}

@keyframes RecentLoadIn {
0% {
transform: rotate(-15deg) scale(0.5);
Expand All @@ -48,9 +60,10 @@

.recent-load-in {
animation:
InitClear var(--delay, 0s) step-end 0s 1,
RecentLoadIn var(--duration, 0.5s) ease-out calc(var(--delay, 0s));
}
InitClear var(--delay, 0s) step-end 0s,
RecentLoadIn var(--duration, 0.5s) ease-out calc(var(--delay, 0s)),
Reveal var(--delay, 0s) step-start 0s forwards;
}

@keyframes LandingImageGlow {
0% {
Expand Down
2 changes: 1 addition & 1 deletion flask_app/templates/recent.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
<div class="row m-2">
{% endif %}
<div class="col-md-6">
<div class="card recent-load-in" style="--delay: {{ loop.index0 * 0.2 + 0.2}}s">
<div class="card recent-load-in" style="--delay: {{ loop.index0 * 0.2 + 0.2}}s; height: 0; opacity: 0;">
<a href="{{ repo.url }}"><img src="/static/img/gh_cards/{{ current_datetime }}/card{{ loop.index0 }}.png" class="card-img-top"/></a>
<div class="card-body" style="background-color: white;">
{% if repo.languages.nodes|length == 0 %}
Expand Down

0 comments on commit 8e4d84e

Please sign in to comment.