[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: website: publications: Add scientific publication
From: |
Ludovic Courtès |
Subject: |
branch master updated: website: publications: Add scientific publication mark. |
Date: |
Fri, 04 Jun 2021 11:36:51 -0400 |
This is an automated email from the git hooks/post-receive script.
civodul pushed a commit to branch master
in repository guix-artwork.
The following commit(s) were added to refs/heads/master by this push:
new b8c921f website: publications: Add scientific publication mark.
b8c921f is described below
commit b8c921f27fc54824a6c6f96ac088894dda3379ce
Author: Luis Felipe <luis.felipe.la@protonmail.com>
AuthorDate: Thu Jun 3 14:22:14 2021 -0500
website: publications: Add scientific publication mark.
* website/apps/media/types.scm (<publication>): Add "scientific?" field.
* website/apps/media/data.scm (publications): Use the new field.
* website/apps/media/templates/components.scm (publication->shtml): Show
graduate cap for scientific publications.
* website/static/media/css/publications.css (.scientific-mark): New
class.
* website/static/media/img/scientific-mark.svg: New image.
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
website/apps/media/data.scm | 3 +-
website/apps/media/templates/components.scm | 12 +++
website/apps/media/types.scm | 14 ++-
website/static/media/css/publications.css | 7 ++
website/static/media/img/scientific-mark.svg | 154 +++++++++++++++++++++++++++
5 files changed, 185 insertions(+), 5 deletions(-)
diff --git a/website/apps/media/data.scm b/website/apps/media/data.scm
index c2b404d..340078d 100644
--- a/website/apps/media/data.scm
+++ b/website/apps/media/data.scm
@@ -137,7 +137,8 @@ Alexander Gosdschan, Katarzyna Wreczycka, Jonathan Ronen,
Altuna Akalin"
#:url "https://ambrevar.xyz/guix-advance/index.html"
#:authors "Pierre Neidhardt"
#:date (string->date "2019-01-14" "~Y-~m-~d")
- #:type (C_ "publication type" "Article"))
+ #:type (C_ "publication type" "Article")
+ #:scientific? #false)
(publication
#:title "Scalable Workflows and Reproducible Data Analysis for Genomics"
#:url "https://link.springer.com/protocol/10.1007%2F978-1-4939-9074-0_24"
diff --git a/website/apps/media/templates/components.scm
b/website/apps/media/templates/components.scm
index 20fa3a9..a1a6072 100644
--- a/website/apps/media/templates/components.scm
+++ b/website/apps/media/templates/components.scm
@@ -42,6 +42,18 @@
(h3
(@ (lang ,(publication-language publication))
(class "publication-title"))
+ ,(if (publication-scientific? publication)
+ `((img
+ (@ (class "scientific-mark")
+ (src ,(guix-url "static/media/img/scientific-mark.svg"))
+ ;; TRANSLATORS: This is a tag that indicates a
+ ;; publication is scientific.
+ (alt ,(G_ "[Scientific]"))
+ ;; TRANSLATORS: This is a help text indicating a
+ ;; publication is scientific.
+ (title ,(G_ "Scientific"))))
+ " ")
+ "")
,(publication-title publication))
(p
diff --git a/website/apps/media/types.scm b/website/apps/media/types.scm
index 2c219e5..ac9bbda 100644
--- a/website/apps/media/types.scm
+++ b/website/apps/media/types.scm
@@ -8,6 +8,7 @@
#:export (publication
publication?
publication-authors
+ publication-scientific?
publication-date
publication-language
publication-title
@@ -71,22 +72,27 @@
;;; The kind of publication. See the list of publications in the
;;; (apps media data) module for examples.
;;;
+;;; scientific? (boolean)
+;;; Whether the publication is scientific or not.
+;;;
;;;
(define-record-type <publication>
- (make-publication title url authors date language type)
+ (make-publication title url authors date language type scientific?)
publication?
(title publication-title)
(url publication-url)
(authors publication-authors)
(date publication-date)
(language publication-language)
- (type publication-type))
+ (type publication-type)
+ (scientific? publication-scientific?))
;;; Helper procedures.
-(define* (publication #:key title url authors date (language "en") type)
+(define* (publication #:key title url authors date (language "en") type
+ (scientific? #true))
"Return a <publication> object with the given attributes."
- (make-publication title url authors date language type))
+ (make-publication title url authors date language type scientific?))
;;; Screenshot (record type)
diff --git a/website/static/media/css/publications.css
b/website/static/media/css/publications.css
index 797918f..11a8542 100644
--- a/website/static/media/css/publications.css
+++ b/website/static/media/css/publications.css
@@ -33,3 +33,10 @@
.publication-info {
margin-bottom: 0px;
}
+
+.scientific-mark {
+ display: inline-block;
+ cursor: help;
+ height: 28px;
+ width: 28px;
+}
diff --git a/website/static/media/img/scientific-mark.svg
b/website/static/media/img/scientific-mark.svg
new file mode 100644
index 0000000..d301307
--- /dev/null
+++ b/website/static/media/img/scientific-mark.svg
@@ -0,0 +1,154 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<svg
+ xmlns:dc="http://purl.org/dc/elements/1.1/"
+ xmlns:cc="http://creativecommons.org/ns#"
+ xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+ xmlns:svg="http://www.w3.org/2000/svg"
+ xmlns="http://www.w3.org/2000/svg"
+ xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+ xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+ width="180"
+ height="180"
+ id="svg2"
+ version="1.1"
+ inkscape:version="1.0.2 (e86c870879, 2021-01-15)"
+ sodipodi:docname="scientific-mark.svg"
+ inkscape:export-filename="manual-latest-icon.png"
+ inkscape:export-xdpi="96"
+ inkscape:export-ydpi="96">
+ <defs
+ id="defs4" />
+ <sodipodi:namedview
+ id="base"
+ pagecolor="#ffffff"
+ bordercolor="#666666"
+ borderopacity="1.0"
+ inkscape:pageopacity="0.0"
+ inkscape:pageshadow="2"
+ inkscape:zoom="1"
+ inkscape:cx="338.63228"
+ inkscape:cy="-97.758331"
+ inkscape:document-units="px"
+ inkscape:current-layer="layer1"
+ showgrid="true"
+ inkscape:window-width="1920"
+ inkscape:window-height="1016"
+ inkscape:window-x="0"
+ inkscape:window-y="27"
+ inkscape:window-maximized="1"
+ inkscape:showpageshadow="false"
+ inkscape:snap-global="false"
+ inkscape:snap-nodes="true"
+ inkscape:snap-bbox="true"
+ inkscape:bbox-paths="true"
+ showguides="true"
+ inkscape:guide-bbox="true"
+ inkscape:document-rotation="0"
+ inkscape:snap-grids="false"
+ inkscape:snap-to-guides="false"
+ inkscape:bbox-nodes="true"
+ inkscape:snap-page="false">
+ <inkscape:grid
+ type="xygrid"
+ id="grid3245"
+ empspacing="1"
+ visible="true"
+ enabled="true"
+ snapvisiblegridlinesonly="true"
+ spacingx="100"
+ spacingy="100"
+ originx="40"
+ originy="40" />
+ </sodipodi:namedview>
+ <metadata
+ id="metadata7">
+ <rdf:RDF>
+ <cc:Work
+ rdf:about="">
+ <dc:format>image/svg+xml</dc:format>
+ <dc:type
+ rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+ <dc:title />
+ <dc:date />
+ <dc:creator>
+ <cc:Agent>
+ <dc:title />
+ </cc:Agent>
+ </dc:creator>
+ <dc:rights>
+ <cc:Agent>
+ <dc:title />
+ </cc:Agent>
+ </dc:rights>
+ <cc:license
+ rdf:resource="http://creativecommons.org/publicdomain/zero/1.0/" />
+ </cc:Work>
+ <cc:License
+ rdf:about="http://creativecommons.org/publicdomain/zero/1.0/">
+ <cc:permits
+ rdf:resource="http://creativecommons.org/ns#Reproduction" />
+ <cc:permits
+ rdf:resource="http://creativecommons.org/ns#Distribution" />
+ <cc:permits
+ rdf:resource="http://creativecommons.org/ns#DerivativeWorks" />
+ </cc:License>
+ </rdf:RDF>
+ </metadata>
+ <g
+ inkscape:label="Cap"
+ inkscape:groupmode="layer"
+ id="layer1"
+ transform="translate(0,-872.36218)">
+ <path
+ id="rect240"
+ style="fill:#333333;fill-opacity:1;stroke-width:1.99999"
+ d="M 90.000198,939.32109 5.5123166,969.80392 v 4.56318 l
42.5012864,15.33389 v 32.52601 h 0.01118 a 42.779802,11.407948 0 0 0
42.768622,11.1763 42.779802,11.407948 0 0 0 42.770885,-11.1763 h 0.008 v
-33.09864 l 40.91539,-14.76126 v -4.56318 z m 0.494643,5.18926
-77.050437,30.24445 -4.1509766,-1.68669 z m -3.328805,20.4452 c
0.202755,-4.6e-4 0.405519,-4.6e-4 0.608275,0 18.149719,-3.6e-4
34.458049,3.62068 41.133229,9.13302 -8.25757,-3.90965 -21.87171,-6.24378
-36.414081,-6.24316 -7. [...]
+ <g
+ transform="translate(-1160.0177,610.69615)"
+ inkscape:label="referencia"
+ id="layer2-3" />
+ <g
+ inkscape:label="Layer 1"
+ id="g3194"
+ transform="translate(-381.66039,1217.4341)" />
+ <g
+ id="layer2"
+ inkscape:label="referencia"
+ transform="translate(-577.51401,231.92014)"
+ sodipodi:insensitive="true" />
+ <g
+ transform="translate(200.84331,838.65809)"
+ id="g3194-5"
+ inkscape:label="Layer 1" />
+ <g
+ inkscape:label="Layer 1"
+ id="g7737"
+ transform="translate(415.21682,1076.3667)" />
+ <text
+ xml:space="preserve"
+
style="font-style:normal;font-weight:normal;line-height:0%;font-family:'Bitstream
Vera Sans';fill:#000000;fill-opacity:1;stroke:none"
+ x="-225.51039"
+ y="1257.8601"
+ id="text3665"><tspan
+ sodipodi:role="line"
+ id="tspan3667"
+ x="-225.51039"
+ y="1257.8601"
+ style="font-size:40px;line-height:1.25">Â </tspan></text>
+ <circle
+ style="fill:#333333;fill-opacity:1;stroke:none;stroke-width:2"
+ id="path256"
+ cx="161.13716"
+ cy="994.64807"
+ r="4.4626188" />
+ <path
+ id="rect258"
+ style="fill:#333333;fill-opacity:1;stroke:none;stroke-width:2"
+ d="m 159.53711,1001.2723 c -2.216,0 -3.80552,1.3775 -4,3.0723 l
-2,17.4277 c -0.19448,1.6947 1.784,3.0723 4,3.0723 h 7.19922 c 2.216,0
4.19448,-1.3776 4,-3.0723 l -2,-17.4277 c -0.19448,-1.6948 -1.784,-3.0723
-4,-3.0723 z m -0.11914,2.334 -1.125,19.0254 c -1.15101,0 -1.46128,0.136
-2.22852,-0.834 l 2.12891,-16.8164 z" />
+ <path
+ id="rect263"
+ style="fill:#333333;fill-opacity:1;stroke:none;stroke-width:2"
+ d="m 159.35468,983.98439 3.56496,-1.28041 V 990.92 h -3.56496 z"
+ sodipodi:nodetypes="ccccc" />
+ </g>
+</svg>
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: website: publications: Add scientific publication mark.,
Ludovic Courtès <=