Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Animate running button #51

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions bin/sparky-web.raku
Original file line number Diff line number Diff line change
Expand Up @@ -292,6 +292,7 @@ sub css {
<link rel="stylesheet" href="https://unpkg.com/bulmaswatch/$theme/bulmaswatch.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/markdown-it/12.0.4/markdown-it.min.js" integrity="sha512-0DkA2RqFvfXBVeti0R1l0E8oMkmY0X+bAA2i02Ld8xhpjpvqORUcE/UBe+0KOPzi5iNah0aBpW6uaNNrqCk73Q==" crossorigin="anonymous"></script>
<script defer src="https://use.fontawesome.com/releases/v5.14.0/js/all.js"></script>
<link rel="stylesheet" href="/blink.css">
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/10.4.1/styles/default.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/10.4.1/highlight.min.js"></script>
<script>hljs.initHighlightingOnLoad();</script>
Expand Down
39 changes: 39 additions & 0 deletions public/blink.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
.flash-button{
animation-name: flash;
animation-duration: 1s;
animation-timing-function: linear;
animation-iteration-count: infinite;

//Firefox 1+
-webkit-animation-name: flash;
-webkit-animation-duration: 1s;
-webkit-animation-timing-function: linear;
-webkit-animation-iteration-count: infinite;

//Safari 3-4
-moz-animation-name: flash;
-moz-animation-duration: 1s;
-moz-animation-timing-function: linear;
-moz-animation-iteration-count: infinite;
}

@keyframes flash {
0% { opacity: 1.0; }
50% { opacity: 0.5; }
100% { opacity: 1.0; }
}

//Firefox 1+
@-webkit-keyframes flash {
0% { opacity: 1.0; }
50% { opacity: 0.5; }
100% { opacity: 1.0; }
}

//Safari 3-4
@-moz-keyframes flash {
0% { opacity: 1.0; }
50% { opacity: 0.5; }
100% { opacity: 1.0; }
}

2 changes: 1 addition & 1 deletion views/builds.tt
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
<span class="tag is-danger">failed</span>
% }
% if %r<state> == 0 {
<span class="tag is-primary">running</span>
<span class="tag is-primary flash-button">running</span>
% }
% if %r<state> == 1 {
<span class="tag is-success">succeed</span>
Expand Down
2 changes: 1 addition & 1 deletion views/projects.tt
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ function run( project ){
<span class="tag is-danger">failed</span>
% }
% if %r<state> == 0 {
<span class="tag is-primary">running</span>
<span class="tag is-primary flash-button">running</span>
% }
% if %r<state> == 1 {
<span class="tag is-success">succeed</span>
Expand Down