summaryrefslogtreecommitdiff
path: root/website/www
diff options
context:
space:
mode:
authorRoel Janssen <roel@gnu.org>2016-01-04 21:05:02 +0100
committerLudovic Courtès <ludo@gnu.org>2016-01-06 14:09:46 +0100
commit60b334d508bb6a191ad13f8a717438b6133517b8 (patch)
tree1359f1f24f81b807ca19c1aff7d9fdfd881e5b96 /website/www
parent7236643b44c49b37523d063454e41223ccc83c35 (diff)
downloadguix-artwork-60b334d508bb6a191ad13f8a717438b6133517b8.tar
guix-artwork-60b334d508bb6a191ad13f8a717438b6133517b8.tar.gz
website: packages: Add build status icons in the expanded view.
* website/www/packages.scm (package->sxml): Wrap the build status link in a div and prepend an icon to the div. * website/static/base/js/packages.js (show_hide): Fetch build status on expand. * website/static/base/css/packages.css (img.status-icon): Added css for icon padding. * website/static/base/img/status-icons/0.png: Add icon. * website/static/base/img/status-icons/1.png: Add icon. * website/static/base/img/status-icons/2.png: Add icon. * website/static/base/img/status-icons/3.png: Add icon. * website/static/base/img/status-icons/4.png: Add icon. * website/static/base/img/status-icons/5.png: Add icon. * website/static/base/img/status-icons/undefined.png: Add icon. Signed-off-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'website/www')
-rw-r--r--website/www/packages.scm15
1 files changed, 10 insertions, 5 deletions
diff --git a/website/www/packages.scm b/website/www/packages.scm
index 6ea974b..69b0623 100644
--- a/website/www/packages.scm
+++ b/website/www/packages.scm
@@ -167,14 +167,18 @@ decreasing, is 1."
(define (status package)
(define (url system)
- `(a (@ (href ,(string-append "http://hydra.gnu.org/job/gnu/master/"
+ `(div (img (@ (src ,(image-url "status-icons/undefined.png"))
+ (id ,(string-append "icon-" (package-full-name package) "." system))
+ (class "status-icon")
+ (alt "Unknown")
+ (title "Unknown")))
+ (a (@ (href ,(string-append "http://hydra.gnu.org/job/gnu/master/"
(package-full-name package) "."
system))
(title "View the status of this architecture's build at Hydra"))
- ,system))
+ ,system)))
- `(div "status: "
- ,(list-join (map url
+ `(div ,(list-join (map url
(lset-intersection
string=?
%hydra-supported-systems
@@ -229,8 +233,9 @@ description-ids as formal parameters."
(a (@ (href ,(package-home-page package))
(title "Link to the package's website"))
,(package-home-page package))
- ,(status package)
,(patches package)
+ (br)
+ ,(status package)
,(if js?
(insert-js-call description-ids)
""))))))