Skip to content

Commit 8533350

Browse files
authored
Merge pull request #26 from ELIXIR-Belgium/plausible
Adding support for plausible
2 parents d7ba60e + 207723d commit 8533350

21 files changed

+227
-229
lines changed

_config.yml

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,22 @@ title: Jekyll bootstrap theme
22
# This appears in the html browser tab for the site title (seen mostly by search engines, not users)
33

44
topnav_title: Jekyll bootstrap theme
5-
# Optional: this appears on the top navigation bar next to the home button
5+
# Optional: this appears on the top navigation bar next to the main_logo.svg icon
66

77
description: "Flexible Jekyll theme using bootstrap 5 as CSS framework."
88
# Metadata description of the website
99

1010
dsw_deep_link_prefix:
1111
# prefix for DSW deep links to a certain question
1212

13+
gtag:
14+
# Google analytics tag
15+
16+
plausible:
17+
# Plausible tag
18+
plausible_src:
19+
# default: 'https://plausible.io/js/plausible.js
20+
1321
exclude:
1422
- .gitignore
1523
- var/
@@ -43,4 +51,6 @@ plugins:
4351
- jekyll-github-metadata
4452

4553
theme_variables:
46-
theme_color: 0d6efd
54+
theme_color: 0d6efd
55+
fonts:
56+
# List of urls towards google fonts
Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
{%- assign alllogos = site.data.affiliations %}
22
<div class="row row-cols-2 row-cols-sm-3 row-cols-md-4 g-5 my-3">
3-
{%- assign filtered_logos = alllogos | where: "type", include.type %}
4-
{%- for affiliation in filtered_logos %}
5-
{%- if affiliation.image_url and affiliation.expose == true %}
6-
<div class="col">
7-
<div class="card h-100 border-0">
8-
<div class="my-auto">
9-
{% if affiliation.url %}<a href="{{ affiliation.url }}">{% endif %}<img class="card-img-top" src="{{ affiliation.image_url | relative_url }}" alt="{{ affiliation.name }}">{%- if affiliation.url %}</a>{% endif %}
10-
</div>
3+
{%- assign filtered_logos = alllogos | where: "type", include.type %}
4+
{%- for affiliation in filtered_logos %}
5+
{%- if affiliation.image_url and affiliation.expose == true %}
6+
<div class="col">
7+
<div class="card h-100 border-0">
8+
<div class="my-auto">
9+
{% if affiliation.url %}<a href="{{ affiliation.url }}">{% endif %}<img class="card-img-top" src="{{ affiliation.image_url | relative_url }}" alt="{{ affiliation.name }}">{%- if affiliation.url %}</a>{% endif %}
1110
</div>
1211
</div>
13-
{%- endif %}
14-
{%- endfor %}
12+
</div>
13+
{%- endif %}
14+
{%- endfor %}
1515
</div>

_includes/contributor-minitiles-page.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,9 @@
2626
{%- endif %}
2727
</div>
2828
{%- endcapture %}
29-
<a tabindex="0" role="button" class="btn contributor-link hover-primary m-1 position-relative" data-bs-trigger="focus" data-bs-html="true" data-bs-container="body" data-bs-toggle="popover" data-bs-placement="top" data-bs-content='{{html_code}}' title="{{contributor}}">
29+
<a tabindex="0" role="button" class="btn contributor-link hover-primary m-1 position-relative" data-bs-trigger="focus" data-bs-html="true" data-bs-container="body" data-bs-toggle="popover" data-bs-placement="top" data-bs-content='{{html_code}}' title="{{contributor}}">
3030
<div class="d-flex align-items-center">
31-
<div class="flex-shrink-0">
31+
<div class="flex-shrink-0">
3232
{%- if contributors[contributor].image_url %}
3333
<img class="img-fluid rounded-circle contributor-img-sm" src="{{ contributors[contributor].image_url }}" alt="Avatar of the contributor {{ stripped_name }}">
3434
{%- else %}

_includes/contributor-tiles-all.html

Lines changed: 36 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -9,55 +9,55 @@
99
{%- assign allcontrstr = allcontrstr | append: ", " | append: pagecontr %}
1010
{%- else %}
1111
{%- assign allcontrstr = allcontrstr | append: pagecontr %}
12-
{%- endif %}
13-
{%- endif %}
12+
{%- endif %}
13+
{%- endif %}
1414
{%- endfor %}
1515
{%- for contr in contributors %}
1616
{%- if allcontrstr %}
1717
{%- assign allcontrstr = allcontrstr | append: ", " | append: contr[0] %}
1818
{%- else %}
1919
{%- assign allcontrstr = allcontrstr | append: contr[0] %}
20-
{%- endif %}
20+
{%- endif %}
2121
{%- endfor %}
2222
{%- assign allcontributors = allcontrstr | split: ", " | uniq | sort %}
23-
{%- endif %}
23+
{%- endif %}
2424
<div class="row row-cols-2 row-cols-sm-3 row-cols-md-4 row-cols-xl-5 g-4 contributor-cards">
25-
{%- for contributor in allcontributors %}
26-
<div class="col">
27-
<div class="card h-100">
28-
{%- assign id = contributors[contributor].git | default: 'no_github' %}
29-
<div class="position-relative">
30-
{%- if contributors[contributor].image_url %}
31-
<img src="{{ contributors[contributor].image_url }}" class="card-img-top p-3 rounded-circle" alt="{{ contributor }}">
32-
{%- else %}
33-
<img src="https://avatars.githubusercontent.com/{{id}}" class="card-img-top p-3 rounded-circle" alt="{{ contributor }}">
25+
{%- for contributor in allcontributors %}
26+
<div class="col">
27+
<div class="card h-100">
28+
{%- assign id = contributors[contributor].git | default: 'no_github' %}
29+
<div class="position-relative">
30+
{%- if contributors[contributor].image_url %}
31+
<img src="{{ contributors[contributor].image_url }}" class="card-img-top p-3 rounded-circle" alt="{{ contributor }}">
32+
{%- else %}
33+
<img src="https://avatars.githubusercontent.com/{{id}}" class="card-img-top p-3 rounded-circle" alt="{{ contributor }}">
34+
{%- endif %}
35+
{%- if contributors[contributor].role %}
36+
<span class="badge position-absolute top-0 end-0">{{ contributors[contributor].role | capitalize }}</span>
37+
{%- endif %}
38+
</div>
39+
<div class="card-body text-center py-0">
40+
<p class="card-title">{{ contributor }}</p>
41+
{%- if contributors[contributor].affiliation %}
42+
<p class="card-affiliation">{{ contributors[contributor].affiliation }}</p>
43+
{%- endif %}
44+
</div>
45+
{%- if contributors[contributor].git or contributors[contributor].email or contributors[contributor].orcid %}
46+
<div class="card-footer">
47+
<div class="d-flex justify-content-center">
48+
{%- if contributors[contributor].git %}
49+
<div class="mx-1"><a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://github.com/{{id}}"><i class="fab fa-github"></i></a></div>
3450
{%- endif %}
35-
{%- if contributors[contributor].role %}
36-
<span class="badge position-absolute top-0 end-0">{{ contributors[contributor].role | capitalize }}</span>
51+
{%- if contributors[contributor].email %}
52+
<div class="mx-1"><a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="mailto:{{contributors[contributor].email}}"><i class="fas fa-envelope"></i></a></div>
3753
{%- endif %}
38-
</div>
39-
<div class="card-body text-center py-0">
40-
<p class="card-title">{{ contributor }}</p>
41-
{%- if contributors[contributor].affiliation %}
42-
<p class="card-affiliation">{{ contributors[contributor].affiliation }}</p>
54+
{%- if contributors[contributor].orcid %}
55+
<div class="mx-1"><a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://orcid.org/{{contributors[contributor].orcid}}"><i class="fab fa-orcid"></i></a></div>
4356
{%- endif %}
4457
</div>
45-
{%- if contributors[contributor].git or contributors[contributor].email or contributors[contributor].orcid %}
46-
<div class="card-footer">
47-
<div class="d-flex justify-content-center">
48-
{%- if contributors[contributor].git %}
49-
<div class="mx-1"><a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://github.com/{{id}}"><i class="fab fa-github"></i></a></div>
50-
{%- endif %}
51-
{%- if contributors[contributor].email %}
52-
<div class="mx-1"><a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="mailto:{{contributors[contributor].email}}"><i class="fas fa-envelope"></i></a></div>
53-
{%- endif %}
54-
{%- if contributors[contributor].orcid %}
55-
<div class="mx-1"><a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://orcid.org/{{contributors[contributor].orcid}}"><i class="fab fa-orcid"></i></a></div>
56-
{%- endif %}
57-
</div>
58-
</div>
59-
{%- endif %}
6058
</div>
59+
{%- endif %}
6160
</div>
62-
{%- endfor %}
61+
</div>
62+
{%- endfor %}
6363
</div>

_includes/cookie-popup.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
<div class="alert text-center cookiealert rounded-0" role="alert">
44
We use cookies to ensure you get the best experience on our website. Read our
55
<a class="fw-bold" href="{{ '/privacy.html' | relative_url}}">privacy policy</a> to find out more.
6-
<button type="button" id="acceptcookies" class="btn btn-primary ms-2" >
6+
<button type="button" id="acceptcookies" class="btn btn-primary ms-2">
77
Got it!
88
</button>
99
</div>
@@ -13,7 +13,7 @@
1313
* https://github.com/Wruczek/Bootstrap-Cookie-Alert
1414
* Released under MIT license
1515
*/
16-
!function(){"use strict";var n=document.querySelector(".cookiealert"),e=document.querySelector("#acceptcookies");n&&(n.offsetHeight,function(e){for(var t=e+"=",o=decodeURIComponent(document.cookie).split(";"),c=0;c<o.length;c++){for(var n=o[c];" "===n.charAt(0);)n=n.substring(1);if(0===n.indexOf(t))return n.substring(t.length,n.length)}return""}("acceptCookies")||n.classList.add("show"),e.addEventListener("click",function(){var e,t,o,c;e="acceptCookies",t=!0,o=365,(c=new Date).setTime(c.getTime()+24*o*60*60*1e3),c="expires="+c.toUTCString(),document.cookie=e+"="+t+";"+c+";path=/",n.classList.remove("show"),window.dispatchEvent(new Event("cookieAlertAccept"))}))}();
16+
!function () { "use strict"; var n = document.querySelector(".cookiealert"), e = document.querySelector("#acceptcookies"); n && (n.offsetHeight, function (e) { for (var t = e + "=", o = decodeURIComponent(document.cookie).split(";"), c = 0; c < o.length; c++) { for (var n = o[c]; " " === n.charAt(0);)n = n.substring(1); if (0 === n.indexOf(t)) return n.substring(t.length, n.length) } return "" }("acceptCookies") || n.classList.add("show"), e.addEventListener("click", function () { var e, t, o, c; e = "acceptCookies", t = !0, o = 365, (c = new Date).setTime(c.getTime() + 24 * o * 60 * 60 * 1e3), c = "expires=" + c.toUTCString(), document.cookie = e + "=" + t + ";" + c + ";path=/", n.classList.remove("show"), window.dispatchEvent(new Event("cookieAlertAccept")) })) }();
1717
</script>
1818
<!-- END Bootstrap-Cookie-Alert -->
1919
{%- endif %}

_includes/events.html

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,30 @@
1-
21
<div class="events {{include.event_type}}s">
32
{%- if include.title == "true" %}
43
<h2 class="mt-5 text-dark">{{include.event_type | replace: "_", " " | capitalize}}s</h2>
54
{%- endif %}
6-
{%- assign events = site.data.events %}
7-
<ul class="list-unstyled mt-3">
8-
{%- for event in events %}
9-
<li class='{{include.event_type}}' data-start='{{ event.startDate}}'>
10-
<span class="title mb-1">{{ event.name | escape }}</span>
11-
<p class="text-muted mb-0"><i class="far fa-calendar me-2"></i><time datetime="{{ event.startDate | date: '%e %B, %Y %H:%M' }}">{{ event.startDate | date_to_long_string }} {{event.startTime}}</time>
12-
{% if event.endDate or event.endTime %} - <time datetime="{{ event.endDate | date: '%e %B, %Y %H:%M %Z' }}">{{ event.endDate | date_to_long_string }} {{event.endTime}}</time>{% endif %}</p>
13-
{%- if event.location %}
14-
<i class="fas fa-map-marker-alt me-2 text-muted"></i><div class="d-inline-block text-muted">{{ event.location | markdownify }}</div>
15-
{%- endif %}
16-
{%- if event.description %}
17-
{{ event.description | markdownify }}
18-
{%- endif %}
19-
</li>
20-
{%- endfor %}
21-
</ul>
22-
{%- if include.caption == "true" %}
23-
<small>An overview of all our events can be fount on the <a href="/events.html">events page</a>.</small>
24-
{%- endif %}
5+
{%- assign events = site.data.events %}
6+
<ul class="list-unstyled mt-3">
7+
{%- for event in events %}
8+
<li class='{{include.event_type}}' data-start='{{ event.startDate}}'>
9+
<span class="title mb-1">{{ event.name | escape }}</span>
10+
<p class="text-muted mb-0"><i class="far fa-calendar me-2"></i><time datetime="{{ event.startDate | date: '%e %B, %Y %H:%M' }}">{{ event.startDate | date_to_long_string }} {{event.startTime}}</time>
11+
{% if event.endDate or event.endTime %} - <time datetime="{{ event.endDate | date: '%e %B, %Y %H:%M %Z' }}">{{ event.endDate | date_to_long_string }} {{event.endTime}}</time>{% endif %}</p>
12+
{%- if event.location %}
13+
<i class="fas fa-map-marker-alt me-2 text-muted"></i>
14+
<div class="d-inline-block text-muted">{{ event.location | markdownify }}</div>
15+
{%- endif %}
16+
{%- if event.description %}
17+
{{ event.description | markdownify }}
18+
{%- endif %}
19+
</li>
20+
{%- endfor %}
21+
</ul>
22+
{%- if include.caption == "true" %}
23+
<small>An overview of all our events can be fount on the <a href="/events.html">events page</a>.</small>
24+
{%- endif %}
2525
</div>
2626
<script>
2727
$(function () {
28-
show_{{include.event_type}}s();
28+
show_{ { include.event_type } } s();
2929
});
3030
</script>

_includes/footer.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
{%- for column in site.data.footer.columns %}
55
{%- if column.type == "image" %}
66
<div class="col-lg-{{column.width}} col-sm-6 d-flex justify-content-center">
7-
<img class="my-auto" width="{{column.image_width}}" src="{{ column.src | relative_url }}" alt="{{column.alt}}"/>
7+
<img class="my-auto" width="{{column.image_width}}" src="{{ column.src | relative_url }}" alt="{{column.alt}}" />
88
</div>
99
{%- elsif column.type == "links" %}
1010
<div class="col-lg-{{column.width}} col-sm-6">

_includes/gtag.html

Lines changed: 0 additions & 10 deletions
This file was deleted.

_includes/head.html

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
{%- capture keywords %}
77
{%- if page.related_pages %}
88
{%- for section in page.related_pages %}
9-
{%- unless section[1] == nil %}{{ section[1] | join: ', ' }}
9+
{%- unless section[1] == nil %}{{ section[1] | join: ', ' }}
1010
{%- endunless %}
1111
{%- endfor %}
1212
{%- endif %}
@@ -59,7 +59,7 @@
5959
$(document).ready(function () {
6060
$('div.datatable-begin').nextUntil('div.datatable-end', 'table').addClass('display');
6161
$('table.display').DataTable({
62-
lengthMenu: [ [25, 50, 100, -1], [25, 50, 100, "All"] ],
62+
lengthMenu: [[25, 50, 100, -1], [25, 50, 100, "All"]],
6363
stateSave: true,
6464
searching: true,
6565
language: {
@@ -78,6 +78,13 @@
7878
<link rel="shortcut icon" href="{{ 'assets/img/favicon.ico' | relative_url }}">
7979
<!-- Schema.org metadata -->
8080
{% include schemasorg.html %}
81+
{%- if site.gtag and jekyll.environment == "production"%}
8182
<!-- Google analytics -->
82-
{% include gtag.html %}
83+
<script async src="https://www.googletagmanager.com/gtag/js?id={{ site.gtag }}"></script>
84+
<script> window.dataLayer = window.dataLayer || []; function gtag() { dataLayer.push(arguments); } gtag('js', new Date()); gtag('config', '{{ site.gtag }}');</script>
85+
{%- endif %}
86+
{%- if site.plausible and jekyll.environment == "production"%}
87+
<!-- Plausible -->
88+
<script defer data-domain="{{site.plausible}}" src="{{site.plausible_src | default: 'https://plausible.io/js/plausible.js'}}"></script>
89+
{%- endif %}
8390
</head>

_includes/more-information-tiles.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ <h2>More information</h2>
4343
{%- if page.faircookbook %}
4444
{%- for recipe in page.faircookbook %}
4545
<li class="d-grid">
46-
<a class="btn bg-white hover-primary text-start"data-bs-toggle="tooltip" data-bs-placement="right" title="FAIRCookbook" href="{{ recipe.url }}">
46+
<a class="btn bg-white hover-primary text-start" data-bs-toggle="tooltip" data-bs-placement="right" title="FAIRCookbook" href="{{ recipe.url }}">
4747
<div class="row g-1">
4848
<div class="col-2 d-flex align-items-center justify-content-center">
4949
<img alt="FAIRCookbook logo" class="img-fluid h-40px" src="assets/img/fairplus.svg">

_includes/news.html

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,21 @@
1-
2-
31
<div class="news">
42
{%- if include.title == "true" %}
53
<h2 class="mt-5 text-dark">Whats new?</h2>
64
{%- endif %}
75
{%- assign news = site.data.news | sort: "date"%}
86
{%- assign count = 0 %}
97
<ul class="list-unstyled mt-3">
10-
{%- for new in news reversed%}
11-
<li>
12-
<span class="title mb-1">{{ new.name | escape }}</span>
13-
<p class="text-muted"><i class="far fa-calendar me-2"></i><time>{{ new.date | date_to_long_string }}</time>{% if new.linked_pr %}<b> - </b><i class="fas fa-code-branch"></i><a href="{{ site.github.repository_url | append: '/pull/' | append: new.linked_pr }}">{{new.linked_pr }}</a>{% endif %}</p>
14-
{{ new.description | markdownify }}
15-
</li>
16-
{%- assign count = count | plus: 1 %}
17-
{%- if include.limit and count == include.limit %}
18-
{%- break %}
19-
{%- endif %}
20-
{%- endfor %}
8+
{%- for new in news reversed%}
9+
<li>
10+
<span class="title mb-1">{{ new.name | escape }}</span>
11+
<p class="text-muted"><i class="far fa-calendar me-2"></i><time>{{ new.date | date_to_long_string }}</time>{% if new.linked_pr %}<b> - </b><i class="fas fa-code-branch"></i><a href="{{ site.github.repository_url | append: '/pull/' | append: new.linked_pr }}">{{new.linked_pr }}</a>{% endif %}</p>
12+
{{ new.description | markdownify }}
13+
</li>
14+
{%- assign count = count | plus: 1 %}
15+
{%- if include.limit and count == include.limit %}
16+
{%- break %}
17+
{%- endif %}
18+
{%- endfor %}
2119
</ul>
2220
{%- if include.caption == "true" %}
2321
<small>For more news please visit our <a href="/news.html">news page</a>.</small>

_includes/pageids-overview.html

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
{%- assign sidebar = site.data.sidebars[include.sidebar]['subitems'] -%}
32
{%- for sections in sidebar %}
43
{%- assign section = sections.title | downcase | replace: " ", "_" %}

_includes/related-pages.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{%- assign actual_related = nil %}
22
{%- for section in page.related_pages %}
3-
{%- unless section[1].size == 0 %}
3+
{%- unless section[1].size == 0 %}
44
{%- assign actual_related = 1 %}
55
{%- endunless %}
66
{%- endfor %}

0 commit comments

Comments
 (0)