elixir-toolkit-theme 1.26.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6ef4ebf40b6e201b710ec252b5333ab05e29a1ab2d498f3ae08a68eb070897f3
4
- data.tar.gz: df3e16d7a670713d0fe8e93547884721aad320d15e572749cbed49b96dabfc76
3
+ metadata.gz: d91cddf69b140287160ff9a1f638bce7e8b416abba6d619c7e8f4f0e1bc0d973
4
+ data.tar.gz: ec0aafd09178d0268b5f46d3c7bc3263b6a13d8cd26de8468c35029d5c12b8bb
5
5
  SHA512:
6
- metadata.gz: 6a16e5224092c6774408a45a127c181a0f8e1683af2dfe139254faf8ce968ab09f8337deff75f010d9ca0ca9ea59b7c7465cb2ec9509f37cc59f7e72acdce583
7
- data.tar.gz: 8de88b386adcdd70a791627acea9d1fddd448115aa765b32f83b445e1cc7eff869673cc4a4aa5b9b84490017d13495bb4112ed5782d6e47baa9de06615a092dc
6
+ metadata.gz: 0cc43b9750b9c2f3e0b4f5bc3d1e2fb04956e0841e8ea934725d4ee7aa1d77e3066e9c168a1567aaf3cba48a5a8a43e58e237a6b142913287dfac9062c1ad6ba
7
+ data.tar.gz: 687fd76b471bc58b39994daae3a63c23cd0efd52d49054a9f320d39a6933463b0384725b3c6203c3e5ac4c5fa85681433b6dc47c00266bd833ab590eadc19d9a
data/README.md CHANGED
@@ -1,3 +1,7 @@
1
+ ---
2
+ permalink: /
3
+ ---
4
+
1
5
  [![Gem Version](https://badge.fury.io/rb/elixir-toolkit-theme.svg)](https://badge.fury.io/rb/elixir-toolkit-theme) [![Jekyll site CI](https://github.com/ELIXIR-Belgium/elixir-toolkit-theme/actions/workflows/jekyll.yml/badge.svg)](https://github.com/ELIXIR-Belgium/elixir-toolkit-theme/actions/workflows/jekyll.yml) [![DOI](https://zenodo.org/badge/421495867.svg)](https://zenodo.org/badge/latestdoi/421495867)
2
6
 
3
7
 
@@ -19,30 +23,35 @@ Its key features:
19
23
  - Easy side navigation, top navigation and footer management
20
24
  - Mobile friendly
21
25
  - Create website sections with each section having its own sidebar
22
- - Out of the box search engine optimizations including schema.org attributes and many other matadata attributes
23
- - Support for Google Analytics and Plausible
24
-
25
- ## Installation
26
+ - Out of the box search engine optimizations including schema.org attributes and many other metadata attributes
27
+ - Support for Google Analytics, Matomo and Plausible
26
28
 
27
- ### via GitHub Pages remote theme (installation free!)
29
+ ## Enabling the theme on your Jekyll project
28
30
 
29
- The quickest way to use the elixir-toolkit-theme is to use the GitHub pages [remote theme](https://blog.github.com/2017-11-29-use-any-theme-with-github-pages/) feature in your `config.yml` file:
31
+ The quickest way to use the elixir-toolkit-theme is setting it as a [remote theme](https://blog.github.com/2017-11-29-use-any-theme-with-github-pages/) in your `config.yml` file:
30
32
 
31
33
  ```yaml
32
34
  remote_theme: ELIXIR-Belgium/elixir-toolkit-theme
33
35
  ```
34
36
 
35
- It also allows you to use a specific version of the theme by add `@X.X.X` to make sure your website keeps working iif breaking changes get introduced.
37
+ You can lock it onto a specific version like using:
36
38
 
37
- ### via RubyGems:
39
+ ```yaml
40
+ remote_theme: ELIXIR-Belgium/elixir-toolkit-theme@1.25.0
41
+ ```
38
42
 
39
- Alternatively you can install it as a Ruby Gem (preferred way if you use GitLab).
43
+ ### Using Ruby Gems (alternative)
40
44
 
41
- Add this line to your Jekyll site's Gemfile:
45
+ Alternatively you can use the Ruby Gem of the theme (needed when using GitLab) by adding this line to your Jekyll site's Gemfile:
42
46
 
43
47
  ```ruby
44
48
  gem "elixir-toolkit-theme"
45
49
  ```
50
+ You can lock it onto a specific version like this:
51
+
52
+ ```ruby
53
+ gem "elixir-toolkit-theme", "~> 1.25.0"
54
+ ```
46
55
 
47
56
  And add this line to your Jekyll site's `_config.yml`:
48
57
 
@@ -50,26 +59,53 @@ And add this line to your Jekyll site's `_config.yml`:
50
59
  theme: elixir-toolkit-theme
51
60
  ```
52
61
 
53
- ## Usage
62
+ ## Deployment
54
63
 
55
- [View the documentation](https://elixir-belgium.github.io/elixir-toolkit-theme/) for usage information (under development).
64
+ ### Via GitHub Actions
56
65
 
57
- ## Deployment
66
+ 1. Make sure you have a GitHub workflow file setup similar to the one in this repo at [.github/workflows/jekyll.yml](https://github.com/ELIXIR-Belgium/elixir-toolkit-theme/.github/workflows/jekyll.yml).
58
67
 
59
- ### Using GitHub pages
68
+ 2. Go to Settings > Pages and enable GitHub Actions as a source
69
+ 3. Go to Environments > github-pages and remove the rule under Deployment branches if you want to deploy other branches than master or main via Workflow Dispatch (manually triggered action)
60
70
 
61
- This theme can be used to deploy the website using GitHub pages. Visit the [GitHub documentation](https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll/) to find out more about how to setup GitHub pages.
71
+ ### Via GitHub Pages
62
72
 
63
- ### Locally using Jekyll
73
+ This is the quickest way to deploy the elixir-toolkit-theme, but gives less flexibility and does not allow you to make use of the new way of tagging tools. Visit the [GitHub documentation](https://docs.github.com/en/pages/setting-up-a-github-pages-site-with-jekyll/) to find out more about how to setup GitHub pages.
64
74
 
65
- 1. If not already present on your machine, install ruby. Note that incompatibility issues may arise with ruby 3.0.0 (released 25.12.20) or newer versions.
75
+ NOTE: This way of deploying does not support the tool-tag in the text of the markdown file to tag tools and resources.
66
76
 
77
+ ### Via GitLab Pages
67
78
 
68
- 1. Install Jekyll
69
- If you have never installed or run a Jekyll site locally on your computer, follow these instructions to install Jekyll:
70
- * Install Jekyll on MacOS/Ubuntu/Other_Linux/Windows: [https://jekyllrb.com/docs/installation/](https://jekyllrb.com/docs/installation/)
79
+ Add an extra `.gitlab-ci.yml` file in the root of the repo with:
80
+
81
+ ```yml
82
+ image: ruby:2.7
71
83
 
72
- 1. Install Bundler and Jekyll
84
+ variables:
85
+ JEKYLL_ENV: production
86
+
87
+ before_script:
88
+ - bundle install
89
+
90
+ pages:
91
+ stage: deploy
92
+ script:
93
+ - bundle exec jekyll build -d public
94
+ artifacts:
95
+ paths:
96
+ - public
97
+ only:
98
+ - master
99
+
100
+ ```
101
+
102
+
103
+ ### Locally using Jekyll
104
+
105
+ 1. If not already present on your machine, install **ruby**.
106
+
107
+ 1. Install Jekyll
108
+ If you have never installed or run a Jekyll site locally on your computer, follow these instructions to install Jekyll: [https://jekyllrb.com/docs/installation/](https://jekyllrb.com/docs/installation/)
73
109
 
74
110
  ```
75
111
  gem install jekyll bundler
@@ -90,11 +126,11 @@ If you have never installed or run a Jekyll site locally on your computer, follo
90
126
  Additional information can be found at the following link: [https://docs.github.com/en/free-pro-team@latest/github/working-with-github-pages/testing-your-github-pages-site-locally-with-jekyll](https://docs.github.com/en/free-pro-team@latest/github/working-with-github-pages/testing-your-github-pages-site-locally-with-jekyll)
91
127
 
92
128
 
93
- ### Using Docker
129
+ ### Locally using Docker
94
130
 
95
131
  If not already installed on your machine, install Docker. From the root of the `elixir-toolkit-theme` directory, run:
96
132
 
97
- ```
133
+ ```sh
98
134
  docker run -it --rm -p [::1]:4000:4000 -v $PWD:/srv/jekyll jekyll/jekyll:latest /bin/bash -c "chmod a+w /srv/jekyll/Gemfile.lock && chmod 777 /srv/jekyll && bundle install && bundle exec jekyll serve --host 0.0.0.0"
99
135
  ```
100
136
 
@@ -113,7 +149,7 @@ This will start the docker container and serve the website locally. Make sure th
113
149
  - [ERIM Research Toolbox](https://eur-nl.github.io/erim-research-toolbox/)
114
150
  - [ELIXIR-UK Fellowship](https://elixir-uk-dash.github.io/rdmkit/)
115
151
 
116
- ## Used packages
152
+ ## Dependencies
117
153
 
118
154
  This theme would not be possible without following open source projects:
119
155
 
@@ -1,6 +1,6 @@
1
1
  {%- if page.affiliations and page.affiliations.size != 0 %}
2
2
  <span class="d-block h2-like fs-2">Affiliations</span>
3
- <div class="p-4 rounded mt-4 page-contributors d-flex flex-wrap gap-2">
3
+ <div class="mt-4 d-flex flex-wrap gap-2">
4
4
  {%- assign affiliations = site.data.affiliations %}
5
5
  {%- assign page_affiliations = page.affiliations | sort %}
6
6
  {%- assign allcountries = site.data.countries %}
@@ -1,10 +1,22 @@
1
1
  {%- assign contributors = site.data.CONTRIBUTORS %}
2
- {%- assign nr = include.nr | default: 5 %}
2
+ {%- assign nr = include.col | default: 5 %}
3
3
  {%- if include.custom %}
4
- {%- assign allcontributors = include.custom | split: ", " | sort %}
4
+ {%- assign allcontrstr = include.custom %}
5
+ {%- elsif include.role %}
6
+ {%- assign rolefilter = include.role | downcase %}
7
+ {%- for contr in contributors %}
8
+ {%- assign contrrole = contr[1]['role'] | downcase %}
9
+ {%- if include.role == contrrole %}
10
+ {%- if allcontrstr %}
11
+ {%- assign allcontrstr = allcontrstr | append: ", " | append: contr[0] %}
12
+ {%- else %}
13
+ {%- assign allcontrstr = allcontrstr | append: contr[0] %}
14
+ {%- endif %}
15
+ {%- endif %}
16
+ {%- endfor %}
5
17
  {%- else %}
6
18
  {%- for page in site.pages %}
7
- {%- if page.contributors and page.search_exclude != true %}
19
+ {%- if page.contributors and page.search_exclude != true and page.contributors.size != 0 %}
8
20
  {%- assign pagecontr = page.contributors | join: ", " %}
9
21
  {%- if allcontrstr %}
10
22
  {%- assign allcontrstr = allcontrstr | append: ", " | append: pagecontr %}
@@ -14,10 +26,18 @@
14
26
  {%- endif %}
15
27
  {%- endfor %}
16
28
  {%- for contr in contributors %}
29
+ {%- if allcontrstr %}
17
30
  {%- assign allcontrstr = allcontrstr | append: ", " | append: contr[0] %}
31
+ {%- else %}
32
+ {%- assign allcontrstr = allcontrstr | append: contr[0] %}
33
+ {%- endif %}
18
34
  {%- endfor %}
19
- {%- assign allcontributors = allcontrstr | split: ", " | uniq | sort %}
20
35
  {%- endif %}
36
+ {%- unless include.sort == false %}
37
+ {%- assign allcontributors = allcontrstr | split: ", " | uniq | sort %}
38
+ {%- else %}
39
+ {%- assign allcontributors = allcontrstr | split: ", " | uniq %}
40
+ {%- endunless %}
21
41
  <div id="contributors-carousel" class="carousel carousel-dark slide my-4" data-ride="carousel" data-bs-interval="7000">
22
42
  <div class="carousel-inner">
23
43
  {%- assign counter = 0 %}
@@ -29,12 +49,12 @@
29
49
  </div>
30
50
  {%- endif %}
31
51
  <div class="carousel-item {% if counter == 0 %}active{% endif %}">
32
- <div class="row row-cols-5 contributor-cards g-1 g-sm-4 ">
52
+ <div class="row row-cols-{{nr}} contributor-cards g-1 g-xl-4 ">
33
53
  {%- endif %}
34
54
  <div class="col">
35
55
  <div class="card h-100">
36
56
  {%- assign id = contributors[contributor].git | default: 'no_github' %}
37
- <div>
57
+ <div class="position-relative">
38
58
  {%- if contributors[contributor].image_url %}
39
59
  <div class="p-3">
40
60
  <div class="ratio ratio-1x1">
@@ -61,6 +81,9 @@
61
81
  </div>
62
82
  {%- endif %}
63
83
  {%- endif %}
84
+ {%- if contributors[contributor].role %}
85
+ <span class="badge position-absolute top-0 end-0">{{ contributors[contributor].role | capitalize }}</span>
86
+ {%- endif %}
64
87
  </div>
65
88
  <div class="card-body text-center py-0">
66
89
  <p class="card-title">{{ contributor }}</p>
@@ -70,15 +93,15 @@
70
93
  </div>
71
94
  {%- if contributors[contributor].git or contributors[contributor].email or contributors[contributor].orcid %}
72
95
  <div class="card-footer">
73
- <div class="d-flex justify-content-center">
96
+ <div class="d-flex justify-content-center gap-1 gap-md-2">
74
97
  {%- if contributors[contributor].git %}
75
- <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="fa-brands fa-github"></i></a></div>
98
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://github.com/{{id}}"><i class="fa-brands fa-github"></i></a>
76
99
  {%- endif %}
77
100
  {%- if contributors[contributor].email %}
78
- <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="fa-solid fa-envelope"></i></a></div>
101
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="mailto:{{contributors[contributor].email}}"><i class="fa-solid fa-envelope"></i></a>
79
102
  {%- endif %}
80
103
  {%- if contributors[contributor].orcid %}
81
- <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="fa-brands fa-orcid"></i></a></div>
104
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://orcid.org/{{contributors[contributor].orcid}}"><i class="fa-brands fa-orcid"></i></a>
82
105
  {%- endif %}
83
106
  </div>
84
107
  </div>
@@ -2,7 +2,11 @@
2
2
  <span class="d-block h2-like fs-2">Contributors</span>
3
3
  <div class="p-4 rounded mt-4 page-contributors d-flex flex-wrap gap-2">
4
4
  {%- assign contributors = site.data.CONTRIBUTORS %}
5
+ {%- unless include.sort == false %}
5
6
  {%- assign page_contributors = page.contributors | sort %}
7
+ {%- else %}
8
+ {%- assign page_contributors = page.contributors %}
9
+ {%- endunless %}
6
10
  {%- for contributor in page_contributors %}
7
11
  {%- assign id = contributors[contributor].git | default: 'no_github' %}
8
12
  <div class="dropup-center dropup d-inline-block">
@@ -89,15 +93,15 @@
89
93
  </div>
90
94
  {%- if contributors[contributor].git or contributors[contributor].email or contributors[contributor].orcid %}
91
95
  <div class="card-footer">
92
- <div class="d-flex justify-content-center">
96
+ <div class="d-flex justify-content-center gap-2">
93
97
  {%- if contributors[contributor].git %}
94
- <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="fa-brands fa-github"></i></a></div>
98
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://github.com/{{id}}"><i class="fa-brands fa-github"></i></a>
95
99
  {%- endif %}
96
100
  {%- if contributors[contributor].email %}
97
- <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="fa-solid fa-envelope"></i></a></div>
101
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="mailto:{{contributors[contributor].email}}"><i class="fa-solid fa-envelope"></i></a>
98
102
  {%- endif %}
99
103
  {%- if contributors[contributor].orcid %}
100
- <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="fa-brands fa-orcid"></i></a></div>
104
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://orcid.org/{{contributors[contributor].orcid}}"><i class="fa-brands fa-orcid"></i></a>
101
105
  {%- endif %}
102
106
  </div>
103
107
  </div>
@@ -1,6 +1,19 @@
1
1
  {%- assign contributors = site.data.CONTRIBUTORS %}
2
+ {%- assign nr = include.col | default: 5 %}
2
3
  {%- if include.custom %}
3
- {%- assign allcontributors = include.custom | split: ", " | sort %}
4
+ {%- assign allcontrstr = include.custom %}
5
+ {%- elsif include.role %}
6
+ {%- assign rolefilter = include.role | downcase %}
7
+ {%- for contr in contributors %}
8
+ {%- assign contrrole = contr[1]['role'] | downcase %}
9
+ {%- if include.role == contrrole %}
10
+ {%- if allcontrstr %}
11
+ {%- assign allcontrstr = allcontrstr | append: ", " | append: contr[0] %}
12
+ {%- else %}
13
+ {%- assign allcontrstr = allcontrstr | append: contr[0] %}
14
+ {%- endif %}
15
+ {%- endif %}
16
+ {%- endfor %}
4
17
  {%- else %}
5
18
  {%- for page in site.pages %}
6
19
  {%- if page.contributors and page.search_exclude != true and page.contributors.size != 0 %}
@@ -19,9 +32,13 @@
19
32
  {%- assign allcontrstr = allcontrstr | append: contr[0] %}
20
33
  {%- endif %}
21
34
  {%- endfor %}
22
- {%- assign allcontributors = allcontrstr | split: ", " | uniq | sort %}
23
35
  {%- endif %}
24
- <div class="row row-cols-2 row-cols-sm-3 row-cols-md-4 row-cols-xl-5 g-4 contributor-cards">
36
+ {%- unless include.sort == false %}
37
+ {%- assign allcontributors = allcontrstr | split: ", " | uniq | sort %}
38
+ {%- else %}
39
+ {%- assign allcontributors = allcontrstr | split: ", " | uniq %}
40
+ {%- endunless %}
41
+ <div class="row row-cols-2 row-cols-sm-3 row-cols-md-4 row-cols-xl-{{nr}} g-4 contributor-cards">
25
42
  {%- for contributor in allcontributors %}
26
43
  <div class="col">
27
44
  <div class="card h-100">
@@ -65,15 +82,15 @@
65
82
  </div>
66
83
  {%- if contributors[contributor].git or contributors[contributor].email or contributors[contributor].orcid %}
67
84
  <div class="card-footer">
68
- <div class="d-flex justify-content-center">
85
+ <div class="d-flex justify-content-center gap-2">
69
86
  {%- if contributors[contributor].git %}
70
- <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="fa-brands fa-github"></i></a></div>
87
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://github.com/{{id}}"><i class="fa-brands fa-github"></i></a>
71
88
  {%- endif %}
72
89
  {%- if contributors[contributor].email %}
73
- <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="fa-solid fa-envelope"></i></a></div>
90
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="mailto:{{contributors[contributor].email}}"><i class="fa-solid fa-envelope"></i></a>
74
91
  {%- endif %}
75
92
  {%- if contributors[contributor].orcid %}
76
- <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="fa-brands fa-orcid"></i></a></div>
93
+ <a class="btn bg-white text-primary hover-primary rounded-circle social-icons p-0" href="https://orcid.org/{{contributors[contributor].orcid}}"><i class="fa-brands fa-orcid"></i></a>
77
94
  {%- endif %}
78
95
  </div>
79
96
  </div>
@@ -11,7 +11,7 @@
11
11
  {%- if column.title != nil %}
12
12
  <span class="footer-title">{{column.title}}</span>
13
13
  {%- endif %}
14
- <ul class="mb-0">
14
+ <ul class="mb-0 list-unstyled">
15
15
  {%- for link in column.children %}
16
16
  {%- if link.url != nil and link.external_url == nil%}
17
17
  <li><a href="{{ link.url | relative_url }}">{{link.url_text}}</a></li>
@@ -1,4 +1,8 @@
1
- {%- assign tools = site.data.tool_and_resource_list | where:"related_pages", include.tag %}
1
+ {%- if include.tag %}
2
+ {%- assign tools = site.data.tool_and_resource_list | add_related_pages | where:"related_pages", include.tag | sort_natural: "name" %}
3
+ {%- else %}
4
+ {%- assign tools = site.data.tool_and_resource_list | add_related_pages | sort_natural: "name" %}
5
+ {%- endif %}
2
6
  {%- assign country_pages = site.pages | where_exp: "item", "item.search_exclude != true" | where_exp:"item","item.national_resources != nil" %}
3
7
  {%- unless tools.size == 0 or tools == nil %}
4
8
  {%- if include.tag %}
@@ -24,13 +28,13 @@
24
28
  </tr>
25
29
  </thead>
26
30
  <tbody>
27
- {%- for tool in tools | sort %}
31
+ {%- for tool in tools %}
28
32
  <tr>
29
33
  {%- assign instances_tool = 0 %}
30
34
  {%- assign total_county_tools = 0 %}
31
35
  {%- assign query = "related_pages." | append: page.type %}
32
36
  {%- for country_page in country_pages %}
33
- {%- assign instance_matches = country_page.national_resources | where: "instance_of", tool.name | where_exp:"resource","resource.related_pages != nil" | where: query, include.tag %}
37
+ {%- assign instance_matches = country_page.national_resources | where: "instance_of", tool.id | where_exp:"resource","resource.related_pages != nil" | where: query, include.tag %}
34
38
  {%- assign tool_matches = country_page.national_resources | where_exp:"resource","resource.related_pages != nil" | where: query, include.tag %}
35
39
  {%- unless tool_matches.size == 0 %}
36
40
  {%- assign total_county_tools = total_county_tools | plus: tool_matches.size %}
@@ -45,10 +49,11 @@
45
49
  <td>{{tool.name}}</td>
46
50
  {%- endif %}
47
51
  <td>{{tool.description}}
48
- {%- if instances_tool != 0 and total_county_tools != 0 and include.tag != nil or tool.instance_of or tool.how_to_access %}
52
+ {%- if tool.instance_of or tool.how_to_access or instances_tool != 0 and total_county_tools != 0 and include.tag != nil %}
53
+ {%- assign linked_tool = site.data.tool_and_resource_list | where:"id", tool.instance_of | first %}
49
54
  <div class="d-block mt-1">
50
- {%- if tool.instance_of %}
51
- <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{tool.instance_of}}"><span class="badge text-primary border border-primary">{{tool.instance_of}}</span></span>
55
+ {%- if linked_tool %}
56
+ <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{linked_tool.name}}"><span class="badge text-primary border border-primary">{{linked_tool.name}}</span></span>
52
57
  {%- endif %}
53
58
  {%- if tool.how_to_access %}
54
59
  <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="{{tool.how_to_access}}"><span class="badge text-primary border border-primary"> <i class="fa-solid fa-key"></i></span></span>
@@ -94,9 +99,9 @@
94
99
  {%- assign hide_ids = "resource_title" %}
95
100
  {%- for country_page in country_pages %}
96
101
  {%- if include.tag %}
97
- {%- assign tool_matches = country_page.national_resources| where_exp:"resource","resource.related_pages != nil" | where: query, include.tag %}
102
+ {%- assign tool_matches = country_page.national_resources | where_exp:"resource","resource.related_pages != nil" | where: query, include.tag | sort_natural: "name" %}
98
103
  {%- else %}
99
- {%- assign tool_matches = country_page.national_resources %}
104
+ {%- assign tool_matches = country_page.national_resources | sort_natural: "name" %}
100
105
  {%- endif %}
101
106
  {%- for tool in tool_matches %}
102
107
  {%- assign tool_id = tool.name | slugify %}
@@ -109,8 +114,11 @@
109
114
  {%- endif %}
110
115
  <td>{{tool.description | markdownify }}
111
116
  {%- if tool.instance_of or tool.how_to_access %}
117
+ {%- assign linked_tool = site.data.tool_and_resource_list | where:"id", tool.instance_of | first %}
112
118
  <div class="d-block mt-1">
113
- <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{tool.instance_of}}"><span class="badge text-primary border border-primary">{{tool.instance_of}}</span></span>
119
+ {%- if linked_tool %}
120
+ <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{linked_tool.name}}"><span class="badge text-primary border border-primary">{{linked_tool.name}}</span></span>
121
+ {%- endif %}
114
122
  {%- if tool.how_to_access %}
115
123
  <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="{{tool.how_to_access}}"><span class="badge text-primary border border-primary"> <i class="fa-solid fa-key"></i></span></span>
116
124
  {%- endif %}
@@ -29,8 +29,11 @@
29
29
  {%- endif %}
30
30
  <td>{{tool.description | markdownify }}
31
31
  {%- if tool.instance_of or tool.how_to_access %}
32
+ {%- assign linked_tool = site.data.tool_and_resource_list | where:"id", tool.instance_of | first %}
32
33
  <div class="d-block mt-1">
33
- <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{tool.instance_of}}"><span class="badge text-primary border border-primary">{{tool.instance_of}}</span></span>
34
+ {%- if linked_tool %}
35
+ <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{linked_tool.name}}"><span class="badge text-primary border border-primary">{{linked_tool.name}}</span></span>
36
+ {%- endif %}
34
37
  {%- if tool.how_to_access %}
35
38
  <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="{{tool.how_to_access}}"><span class="badge text-primary border border-primary"> <i class="fa-solid fa-key"></i></span></span>
36
39
  {%- endif %}
@@ -76,7 +79,7 @@
76
79
  <div id="skip-tool-table-1"></div>
77
80
  {%- endif %}
78
81
  {%- if page.ref_to_main_resources %}
79
- {%- assign tool_names = page.ref_to_main_resources %}
82
+ {%- assign tool_ids = page.ref_to_main_resources %}
80
83
  <h3>{{page.title}} contributes to</h3>
81
84
  <p>Institutions and organisations in {{page.title}} are actively involved in the development of the following tools and resources.</p>
82
85
  <a class="visually-hidden-focusable" href='#skip-tool-table-2'>Skip tool table</a>
@@ -95,8 +98,8 @@
95
98
  </tr>
96
99
  </thead>
97
100
  <tbody>
98
- {%- for tool_name in tool_names | sort %}
99
- {%- assign tool = site.data.tool_and_resource_list | where:"name", tool_name | first %}
101
+ {%- for tool_id in tool_ids | sort %}
102
+ {%- assign tool = site.data.tool_and_resource_list | where:"id", tool_id | first %}
100
103
  <tr>
101
104
  {% if tool.url %}
102
105
  <td><a href="{{tool.url}}">{{tool.name}}</a>
@@ -106,9 +109,11 @@
106
109
  {%- endif %}
107
110
  <td>{{tool.description | markdownify }}
108
111
  {%- if tool.instance_of or tool.how_to_access %}
112
+ {%- assign linked_tool = site.data.tool_and_resource_list | where:"id", tool.instance_of | first %}
109
113
  <div class="d-block mt-1">
110
- <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{tool.instance_of}}"><span class="badge text-primary border border-primary">{{tool.instance_of}}</span></span>
111
- {%- if tool.how_to_access %}
114
+ {%- if linked_tool %}
115
+ <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="This resource is an instance of {{linked_tool.name}}"><span class="badge text-primary border border-primary">{{linked_tool.name}}</span></span>
116
+ {%- endif %} {%- if tool.how_to_access %}
112
117
  <span class="d-inline-block" tabindex="0" data-bs-toggle="tooltip" title="{{tool.how_to_access}}"><span class="badge text-primary border border-primary"> <i class="fa-solid fa-key"></i></span></span>
113
118
  {%- endif %}
114
119
  </div>
@@ -1,6 +1,6 @@
1
1
  {%- assign allcountries = site.data.countries %}
2
2
  {%- assign except = include.except | split: ", " %}
3
- <div class="row row-cols-1 row-cols-md-2 g-3 my-4 navigation-tiles">
3
+ <div class="row row-cols-1 row-cols-md-2 row-cols-lg-{{ include.col | default: 2 }} g-3 my-4 navigation-tiles">
4
4
  {%- for current_page in site.pages | sorted %}
5
5
  {%- if current_page.title and current_page.search_exclude != true and current_page.type == include.type %}
6
6
  {%- unless except contains current_page.name %}
@@ -46,7 +46,7 @@
46
46
  {%- endunless %}
47
47
  </div>
48
48
  {%- endunless %}
49
- <div class="row row-cols-1 row-cols-md-2 g-4 mb-5 navigation-tiles">
49
+ <div class="row row-cols-1 row-cols-md-2 row-cols-lg-{{ include.col | default: 2 }} g-4 mb-5 navigation-tiles">
50
50
  {%- for current_page in site.pages | sorted %}
51
51
  {%- assign affiliations_classes = "" %}
52
52
  {%- assign related_pages_classes = "" %}
@@ -21,7 +21,7 @@
21
21
  <a class="btn text-start d-block mb-1 sidebar-title disabled" aria-disabled="true">{{sidebar.title}} {{sidebar.version}}</a>
22
22
  {%- endif %}
23
23
  {%- endif %}
24
- <ul class="list-unstyled mb-4 mb-lg-0">
24
+ <ul class="list-unstyled mb-4">
25
25
  {%- for folder in sidebar.subitems %}
26
26
  {%- if page.url == folder.url %}
27
27
  <li class="active{%- if folder.hr %} mt-3{% endif %}">
data/_includes/toc.html CHANGED
@@ -1,8 +1,11 @@
1
+ {%- unless page.toc == false %}
1
2
  <script>
2
3
  $(document).ready(function () {
3
- $('#toc').toc({ minimumHeaders: {{site.theme_variables.toc.min_headers | default: 2 }}, listType: 'ul', noBackToTopLinks: true, showSpeed: 0, headers: '{{site.theme_variables.toc.headers | default: 'main h2' }}' , title: '', classes:{toc:'p-3 rounded my-4'} });
4
+ $('#toc-contents').toc({ minimumHeaders: {{site.theme_variables.toc.min_headers | default: 2 }}, listType: 'ul', classes: { list: 'list-unstyled' }, noBackToTopLinks: true, showSpeed: 0, headers: '{{site.theme_variables.toc.headers | default: 'main h2' }}' , title: '<strong class="my-2">On this page</strong><hr class="my-2">' });
4
5
  });
5
6
  </script>
6
- <div class="col-12 col-sm-7 col-xl-5">
7
- <div id="toc"></div>
8
- </div>
7
+ <button id="btn-toc-hide" class="btn bg-light d-lg-none hover-primary mb-3" type="button" data-bs-toggle="collapse" data-bs-target="#toc-contents" aria-expanded="true" aria-controls="toc-contents">
8
+ <i class="fa-solid fa-up-right-and-down-left-from-center me-2"></i>On this page
9
+ </button>
10
+ <nav id="toc-contents" class="collapse" aria-label="Table of contents"></nav>
11
+ {%- endunless %}
@@ -9,11 +9,11 @@
9
9
  <i title="navbar-toggler" class="fa-solid fa-bars"></i>
10
10
  </button>
11
11
  <div class="collapse navbar-collapse justify-content-end" id="navbarCollapse">
12
- <ul class="navbar-nav">
12
+ <ul class="navbar-nav gap-2">
13
13
  <!-- navigation entries -->
14
14
  {%- assign topnav = site.data.topnav %}
15
15
  {%- for item in topnav.subitems %}
16
- <li class="nav-item {% if item.subitems %}dropdown {% endif %}ms-0 ms-lg-3 mt-2 mt-lg-0">
16
+ <li class="nav-item {% if item.subitems %}dropdown {% endif %}">
17
17
  {%- assign page_sidebar = page.sidebar | downcase | replace: "-", "_" | replace: " ", "_" %}
18
18
  {%- assign nav_title = item.title | downcase | replace: "-", "_" | replace: " ", "_" %}
19
19
  {%- if item.external_url %}
@@ -49,15 +49,15 @@
49
49
  {%- else %}
50
50
  {%- assign break_color = "light" %}
51
51
  {%- endif -%}
52
- <li class="nav-item ms-0 ms-lg-3 mt-2 mt-lg-0 nav-break bg-{{break_color}} opacity-25"></li>
52
+ <li class="nav-item nav-break bg-{{break_color}} opacity-25"></li>
53
53
  {%- endif %}
54
54
  {%- if site.theme_variables.topnav.twitter %}
55
- <li class="nav-item ms-0 ms-lg-3 mt-2 mt-lg-0">
55
+ <li class="nav-item">
56
56
  <a class="nav-link ps-2 d-flex align-items-center" href="{{site.theme_variables.topnav.twitter}}"><i class="fa-brands fa-twitter me-2"></i>Twitter</a>
57
57
  </li>
58
58
  {%- endif %}
59
59
  {%- if site.theme_variables.topnav.github or site.theme_variables.topnav.github == nil %}
60
- <li class="nav-item ms-0 ms-lg-3 mt-2 mt-lg-0">
60
+ <li class="nav-item">
61
61
  <a class="nav-link ps-2 d-flex align-items-center" href="{{site.github.repository_url}}">
62
62
  {%- assign git_host = site.theme_variables.git_host | downcase %}
63
63
  {%- if git_host == 'gitlab' %}
@@ -71,7 +71,7 @@
71
71
  {%- endif %}
72
72
  {%- unless include.search == false %}
73
73
  <!--start search-->
74
- <li class="nav-item ms-0 ms-lg-3 my-2 my-lg-0">
74
+ <li class="nav-item">
75
75
  <div class="position-relative">
76
76
  <form role="search" class="input-group">
77
77
  <span class="input-group-text" id="search-label"><i class="fa-solid fa-magnifying-glass"></i></span><input type="search" id="search-input" class="search-input form-control" tabindex="0" placeholder="Search {{ site.title }}" aria-label="Search {{ site.title }}" autocomplete="off">
@@ -7,17 +7,13 @@
7
7
  <!-- Page Content -->
8
8
  <div class="container flex-grow-1">
9
9
  <!-- Content Row -->
10
- <div class="row gx-0 gx-lg-5">
11
- {%- assign content_col_size = "col-lg-12" %}{% unless page.hide_sidebar %}
12
- <!-- Sidebar Column -->
13
- <div class="col-lg-3 mb-0 mb-lg-4">
10
+ <div id="layout" class="gap-5">
11
+ <!-- Sidebar -->
12
+ <aside id="sidebar">
14
13
  {% include sidebar.html %}
15
- </div>
16
- {%- assign content_col_size = "col-lg-9" %}{% endunless %}
17
- <!-- Content Column -->
18
- <div class="{{content_col_size}}">
19
- {{content}}
20
- </div>
14
+ </aside>
15
+ <!-- Content -->
16
+ {{content}}
21
17
  </div>
22
18
  </div>
23
19
  {%- if site.theme_variables.back_to_top or site.theme_variables.back_to_top == nil %}
data/_layouts/page.html CHANGED
@@ -1,38 +1,43 @@
1
1
  ---
2
2
  layout: default
3
3
  ---
4
- <main id="main" class="mb-5">
5
- {%- if page.title %}
6
- {%- if page.type %}
7
- {%- assign subtitle = page.type | replace: "_", " " | capitalize %}
8
- <h1 class="has-subtitle"><span class="d-block text-secondary fs-4 ff-body">{{subtitle}}</span><span class="visually-hidden">:</span> {{ page.title }}
9
- {%- else %}
10
- <h1>{{ page.title }}
11
- {%- endif %}
12
- {%- if site.theme_variables.github_buttons.position == "top" or site.theme_variables.github_buttons.position == nil %}
13
- {% include github-buttons.html %}
14
- {%- endif %}
15
- </h1>
16
- {%- endif %}
17
- {%- if page.summary %}
18
- <div class="summary">{{page.summary}}</div>
19
- {%- endif %}
20
- {%- unless page.toc == false %}
21
- {%- include toc.html %}
22
- {%- endunless %}
23
- {{content}}
24
- {% include resource-table-page.html %}
25
- {% include related-pages.html %}
26
- {% include more-information-tiles.html %}
27
- {%- if page.page_id %}
28
- {% include resource-table-all.html tag=page.page_id %}
29
- {%- endif %}
30
- {% include affiliation-tiles-page.html %}
31
- {% include contributor-minitiles-page.html %}
32
- {%- if site.theme_variables.github_buttons.position == "bottom" %}
33
- <div id="github-buttons-wrapper" class="d-flex mt-5">
34
- {% include github-buttons.html %}
4
+ <main id="main" class="order-1">
5
+ <div id="intro">
6
+ {%- if page.title %}
7
+ {%- if page.type %}
8
+ {%- assign subtitle = page.type | replace: "_", " " | capitalize %}
9
+ <h1 class="has-subtitle"><span class="d-block text-secondary fs-4 ff-body">{{subtitle}}</span><span class="visually-hidden">:</span> {{ page.title }}
10
+ {%- else %}
11
+ <h1>{{ page.title }}
12
+ {%- endif %}
13
+ {%- if site.theme_variables.github_buttons.position == "top" or site.theme_variables.github_buttons.position == nil %}
14
+ {% include github-buttons.html %}
15
+ {%- endif %}
16
+ </h1>
17
+ {%- endif %}
18
+ {%- if page.summary %}
19
+ <div class="summary">{{page.summary}}</div>
20
+ {%- endif %}
21
+ </div>
22
+ <div id="toc" class="text-muted sticky-lg-top">
23
+ {%- include toc.html %}
24
+ </div>
25
+ <div id="content" class="mb-5" data-bs-spy="scroll" data-bs-target="#toc-contents" data-bs-smooth-scroll="true" tabindex="0">
26
+ {{content}}
27
+ {% include resource-table-page.html %}
28
+ {% include related-pages.html %}
29
+ {% include more-information-tiles.html %}
30
+ {%- if page.page_id %}
31
+ {% include resource-table-all.html tag=page.page_id %}
32
+ {%- endif %}
33
+ {% include affiliation-tiles-page.html %}
34
+ {% include contributor-minitiles-page.html %}
35
+ {%- if site.theme_variables.github_buttons.position == "bottom" %}
36
+ <div id="github-buttons-wrapper" class="d-flex mt-5">
37
+ {% include github-buttons.html %}
38
+ </div>
39
+ {%- endif %}
35
40
  </div>
36
- {%- endif %}
37
41
  </main>
38
42
 
43
+
@@ -1,4 +1,4 @@
1
- @import "bootstrap/functions";
1
+
2
2
 
3
3
  /*-----Theme colors-----*/
4
4
  $primary: #0d6efd;
@@ -8,5 +8,3 @@ $dark: #212529;
8
8
 
9
9
  /*-----Custom values for Bootstrap variables-----*/
10
10
  $link-decoration: none;
11
-
12
- @import "bootstrap/variables";
@@ -24,9 +24,6 @@ $sidebar-lvl3-color: $dark;
24
24
  $sidebar-bg-active: $primary;
25
25
  $sidebar-color-active: $white;
26
26
 
27
- /*-----TOC-----*/
28
- $toc-bg: $light;
29
-
30
27
  /*-----Section navigation tiles-----*/
31
28
  $nav-card-bg: $light;
32
29
  $nav-card-header-bg: $secondary;
data/assets/css/main.scss CHANGED
@@ -1,23 +1,34 @@
1
1
  ---
2
2
  layout: none
3
- permalink: assets/css/main.css
3
+ permalink: assets/css/main
4
4
  ---
5
5
 
6
6
  /*-----Default theme variables-----*/
7
+
8
+ @import "bootstrap/functions";
7
9
  $popover-max-width: 12em;
8
10
  $enable-caret: false;
9
11
  $card-border-width: 0;
12
+ $custom-container-max-widths: (
13
+ xxxl: 1500px,
14
+ );
10
15
 
11
- /*-----Include other SASS files-----*/
16
+ /*-----Initialize Bootstrap variables-----*/
12
17
 
13
18
  @import "bootstrap_variables";
19
+ @import "bootstrap/variables";
20
+
21
+ /*-----Custom maps-----*/
22
+ $container-max-widths: map-merge($container-max-widths, $custom-container-max-widths);
23
+
24
+ /*-----Include other SASS files-----*/
14
25
  @import "bootstrap/bootstrap";
15
26
  @import "variables";
16
27
  @import "custom_variables";
17
28
 
18
29
  /*-----General styling-----*/
19
30
 
20
- main {
31
+ #content {
21
32
  h1 {
22
33
  font-family: $font-family-theme;
23
34
  font-weight: 400;
@@ -67,10 +78,10 @@ main {
67
78
  font-weight: 600;
68
79
  }
69
80
  }
81
+ }
70
82
 
71
- img {
72
- @extend .img-fluid;
73
- }
83
+ body img {
84
+ @extend .img-fluid;
74
85
  }
75
86
 
76
87
  .ff-body {
@@ -81,6 +92,78 @@ main {
81
92
  font-family: $font-family-theme !important;
82
93
  }
83
94
 
95
+ /*-----Layout-----*/
96
+
97
+ #main {
98
+ grid-area: main;
99
+ }
100
+
101
+
102
+
103
+ @include media-breakpoint-up(md) {
104
+ #main {
105
+ display: grid;
106
+ grid-template-areas:
107
+ "intro"
108
+ "toc"
109
+ "content";
110
+ grid-template-rows: auto auto 1fr;
111
+ }
112
+ }
113
+ @include media-breakpoint-up(lg) {
114
+ #main {
115
+ grid-template-areas:
116
+ "intro toc"
117
+ "content toc";
118
+ grid-template-rows: auto 1fr;
119
+ }
120
+
121
+ .add-grid {
122
+ grid-template-columns: 5fr 2fr;
123
+ }
124
+ }
125
+
126
+ #toc {
127
+ grid-area: toc;
128
+ display: none;
129
+ }
130
+
131
+ @include media-breakpoint-up(lg) {
132
+ #toc {
133
+ top: $spacer * 3;
134
+ right: 0;
135
+ z-index: 2;
136
+ height: calc(100vh - 7rem);
137
+ overflow-y: auto;
138
+ margin-left: $spacer * 3;
139
+ }
140
+ }
141
+
142
+ #intro {
143
+ grid-area: intro;
144
+ }
145
+
146
+ #sidebar {
147
+ grid-area: sidebar;
148
+ }
149
+
150
+ #content {
151
+ grid-area: content;
152
+ min-width: 1px;
153
+ position: relative;
154
+ h2:first-child {
155
+ margin-top: 0;
156
+ }
157
+ }
158
+
159
+ @include media-breakpoint-up(lg) {
160
+ #layout {
161
+ display: grid;
162
+ grid-template-areas: "sidebar main";
163
+ grid-template-columns: 2fr 9fr;
164
+ }
165
+ }
166
+
84
167
  /*-----Blockquote-----*/
85
168
 
86
169
  blockquote {
@@ -153,7 +236,7 @@ header .navbar {
153
236
  color: $topnav-title-color;
154
237
 
155
238
  img {
156
- height: $topnav-brand-height;
239
+ max-height: $topnav-brand-height;
157
240
  }
158
241
  }
159
242
  }
@@ -169,7 +252,7 @@ header .navbar {
169
252
  font-weight: 900;
170
253
  margin-left: 0.25rem;
171
254
  content: "\f0d7";
172
- transition: transform 0.2s ease-in-out;
255
+ transition: transform 0.15s ease-in-out;
173
256
  }
174
257
 
175
258
  .dropdown-toggle[aria-expanded="true"]::after {
@@ -292,15 +375,13 @@ header .navbar {
292
375
  /*-----Sidebar-----*/
293
376
 
294
377
  @include media-breakpoint-up(lg) {
295
- #side-nav {
378
+ #sidebar > nav {
296
379
  display: block !important;
297
380
  }
298
381
  }
299
382
 
300
- #side-nav .btn.sidebar-title {
383
+ #sidebar > nav .btn.sidebar-title {
301
384
  color: $sidebar-color;
302
- background-color: transparent;
303
- border-color: transparent;
304
385
  }
305
386
 
306
387
  .sidebar-collapse {
@@ -318,7 +399,7 @@ header .navbar {
318
399
  background-color: $sidebar-bg-active;
319
400
  }
320
401
 
321
- #side-nav > ul {
402
+ #sidebar > nav > ul {
322
403
  > li:not(.sidebar-title) > a {
323
404
  background-color: $sidebar-bg;
324
405
  color: $sidebar-color;
@@ -341,7 +422,7 @@ header .navbar {
341
422
  font-family: "Font Awesome 6 Free";
342
423
  font-weight: 900;
343
424
  content: "\f078";
344
- transition: transform 0.2s ease-in-out;
425
+ transition: transform 0.15s ease-in-out;
345
426
  }
346
427
  }
347
428
 
@@ -391,25 +472,32 @@ header .navbar {
391
472
 
392
473
  /*-----TOC-----*/
393
474
 
394
- #toc {
395
- background-color: $toc-bg;
396
- // Indent the lists and reset any other padding
397
-
475
+ #toc-contents {
476
+ @include media-breakpoint-up(lg) {
477
+ display: block !important;
478
+ } // Indent the lists and reset any other padding
398
479
  ul {
399
- padding: 0 0 0 20px;
480
+ // highlighting active links
481
+ a {
482
+ color: inherit;
483
+ padding-left: 0.25rem;
484
+ border-left: 0.125rem solid transparent;
485
+ display: block;
486
+ transition: border-left 0.15s ease-in-out;
487
+ &.active,
488
+ &:hover {
489
+ text-decoration: none !important;
490
+ border-left: 0.125rem solid $primary;
491
+ color: $primary;
492
+ }
493
+ }
400
494
  }
401
495
 
402
496
  // Consistent vertical space between list items
403
497
 
404
498
  li,
405
499
  ul ul li {
406
- margin: 8px 0 0 0;
407
- }
408
-
409
- // Sublists
410
-
411
- ul ul {
412
- list-style: circle outside;
500
+ margin: 13px 0 0 0;
413
501
  }
414
502
  }
415
503
 
@@ -495,11 +583,11 @@ footer {
495
583
  }
496
584
 
497
585
  #ett-logo {
498
- transition: color .15s ease-in-out;
586
+ transition: color 0.15s ease-in-out;
499
587
 
500
588
  .cls-1 {
501
589
  fill: $footer-ett;
502
- transition: fill .15s ease-in-out;
590
+ transition: fill 0.15s ease-in-out;
503
591
  }
504
592
  &:hover {
505
593
  .cls-1 {
@@ -552,17 +640,31 @@ footer {
552
640
  }
553
641
 
554
642
  @include media-breakpoint-down(md) {
555
- #contributors-carousel .card-title {
556
- font-size: 0.5em;
557
- }
643
+ #contributors-carousel {
644
+ .card-title {
645
+ font-size: 0.5em;
646
+ }
558
647
 
559
- #contributors-carousel .card-affiliation {
560
- color: $primary;
561
- font-size: 0.4em;
562
- }
648
+ .card-affiliation,
649
+ .badge {
650
+ font-size: 0.4em;
651
+ }
652
+
653
+ .card-body,
654
+ .card-footer {
655
+ padding: 0.5rem 0.25rem;
656
+ }
563
657
 
564
- #contributors-carousel .card-body {
565
- padding: 0rem 0.5rem 0.5rem 0.5rem;
658
+ .social-icons {
659
+ line-height: 2ex;
660
+ width: 2.2ex;
661
+ height: 2.2ex;
662
+ i {
663
+ font-size: 0.625em;
664
+ line-height: 0.1em;
665
+ vertical-align: 0.225em;
666
+ }
667
+ }
566
668
  }
567
669
  }
568
670
 
@@ -587,14 +689,6 @@ footer {
587
689
  text-align: center;
588
690
  }
589
691
 
590
- @include media-breakpoint-down(md) {
591
- #contributors-carousel .social-icons {
592
- line-height: 1.2ex;
593
- width: 1.2ex;
594
- height: 1.2ex;
595
- }
596
- }
597
-
598
692
  /*--------Page contributors---------*/
599
693
  .page-contributors {
600
694
  background-color: $contr-bg;
@@ -669,6 +763,30 @@ footer {
669
763
  transition-delay: 1000ms;
670
764
  }
671
765
 
766
+ /*-----Tools-----*/
767
+
768
+ .tool {
769
+ cursor: pointer;
770
+ white-space: nowrap;
771
+ color: $link-color;
772
+ background-color: rgba($link-color, 0.05);
773
+ border-radius: $border-radius;
774
+ padding: 0.1rem 0.25rem;
775
+
776
+ &:hover {
777
+ text-decoration: none !important;
778
+ color: $primary;
779
+ }
780
+ }
781
+
782
+ .popover-tool {
783
+ max-width: 20rem;
784
+
785
+ h5 {
786
+ font-weight: bold;
787
+ }
788
+ }
789
+
672
790
  /*-----Hoover classes-----*/
673
791
 
674
792
  .hover-primary:hover,
data/assets/js/main.js CHANGED
@@ -31,7 +31,7 @@ $(document).ready(function () {
31
31
  */
32
32
  $(document).ready(function () {
33
33
  // Initialize navgoco with default options
34
- $("#side-nav>ul").navgoco({
34
+ $("#sidebar>nav>ul").navgoco({
35
35
  caretHtml: '',
36
36
  accordion: true,
37
37
  openClass: 'active', // open
@@ -163,3 +163,14 @@ $(function () {
163
163
  })
164
164
  })
165
165
  })
166
+
167
+ /**
168
+ * Activate popovers
169
+ */
170
+
171
+ $(function () {
172
+ var popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'))
173
+ var popoverList = popoverTriggerList.map(function (popoverTriggerEl) {
174
+ return new bootstrap.Popover(popoverTriggerEl)
175
+ })
176
+ })
data/assets/js/toc.js CHANGED
@@ -1,6 +1,6 @@
1
1
  // https://github.com/ghiculescu/jekyll-table-of-contents
2
- (function($){
3
- $.fn.toc = function(options) {
2
+ (function ($) {
3
+ $.fn.toc = function (options) {
4
4
  var defaults = {
5
5
  noBackToTopLinks: false,
6
6
  title: '<i>Jump to...</i>',
@@ -9,36 +9,39 @@
9
9
  listType: 'ol', // values: [ol|ul]
10
10
  showEffect: 'show', // values: [show|slideDown|fadeIn|none]
11
11
  showSpeed: 'slow', // set to 0 to deactivate effect
12
- classes: { list: '',
13
- item: '',
14
- link: '',
15
- toc: ''
16
- }
12
+ classes: {
13
+ list: '',
14
+ item: '',
15
+ link: '',
16
+ toc: ''
17
+ }
17
18
  },
18
- settings = $.extend(defaults, options);
19
+ settings = $.extend(defaults, options);
19
20
 
20
- function fixedEncodeURIComponent (str) {
21
- return encodeURIComponent(str).replace(/[!'()*]/g, function(c) {
21
+ function fixedEncodeURIComponent(str) {
22
+ return encodeURIComponent(str).replace(/[!'()*]/g, function (c) {
22
23
  return '%' + c.charCodeAt(0).toString(16);
23
24
  });
24
25
  }
25
26
 
26
- function createLink (header) {
27
+ function createLink(header) {
27
28
  var innerText = (header.textContent === undefined) ? header.innerText : header.textContent;
28
- return "<a class='"+settings.classes.link+"' href='#" + fixedEncodeURIComponent(header.id) + "'>" + innerText + "</a>";
29
+ return "<a class='" + settings.classes.link + "' href='#" + fixedEncodeURIComponent(header.id) + "'>" + innerText + "</a>";
29
30
  }
30
31
 
31
- var headers = $(settings.headers).filter(function() {
32
+ var headers = $(settings.headers).filter(function () {
32
33
  // get all headers with an ID
33
- var previousSiblingName = $(this).prev().attr( "name" );
34
+ var previousSiblingName = $(this).prev().attr("name");
34
35
  if (!this.id && previousSiblingName) {
35
- this.id = $(this).attr( "id", previousSiblingName.replace(/\./g, "-") );
36
+ this.id = $(this).attr("id", previousSiblingName.replace(/\./g, "-"));
36
37
  }
37
38
  return this.id;
38
39
  }), output = $(this);
39
40
  if (!headers.length || headers.length < settings.minimumHeaders || !output.length) {
40
- $(this).hide();
41
41
  return;
42
+ } else {
43
+ $('#main').addClass("add-grid");
44
+ $("#toc").show();
42
45
  }
43
46
 
44
47
  if (0 === settings.showSpeed) {
@@ -48,50 +51,50 @@
48
51
  $(this).addClass(settings.classes.toc)
49
52
 
50
53
  var render = {
51
- show: function() { output.hide().html(html).show(settings.showSpeed); },
52
- slideDown: function() { output.hide().html(html).slideDown(settings.showSpeed); },
53
- fadeIn: function() { output.hide().html(html).fadeIn(settings.showSpeed); },
54
- none: function() { output.html(html); }
54
+ show: function () { output.hide().html(html).show(settings.showSpeed); },
55
+ slideDown: function () { output.hide().html(html).slideDown(settings.showSpeed); },
56
+ fadeIn: function () { output.hide().html(html).fadeIn(settings.showSpeed); },
57
+ none: function () { output.html(html); }
55
58
  };
56
59
 
57
- var get_level = function(ele) { return parseInt(ele.nodeName.replace("H", ""), 10); };
58
- var highest_level = headers.map(function(_, ele) { return get_level(ele); }).get().sort()[0];
60
+ var get_level = function (ele) { return parseInt(ele.nodeName.replace("H", ""), 10); };
61
+ var highest_level = headers.map(function (_, ele) { return get_level(ele); }).get().sort()[0];
59
62
  var return_to_top = '<i class="icon-arrow-up back-to-top"> </i>';
60
63
 
61
64
  var level = get_level(headers[0]),
62
65
  this_level,
63
- html = settings.title + " <" +settings.listType + " class=\"" + settings.classes.list +"\">";
64
- headers.on('click', function() {
66
+ html = settings.title + " <" + settings.listType + " class=\"" + settings.classes.list + "\">";
67
+ headers.on('click', function () {
65
68
  if (!settings.noBackToTopLinks) {
66
69
  window.location.hash = this.id;
67
70
  }
68
71
  })
69
- .addClass('clickable-header')
70
- .each(function(_, header) {
71
- this_level = get_level(header);
72
- if (!settings.noBackToTopLinks && this_level === highest_level) {
73
- $(header).addClass('top-level-header').after(return_to_top);
74
- }
75
- if (this_level === level) // same level as before; same indenting
76
- html += "<li class=\"" + settings.classes.item + "\">" + createLink(header);
77
- else if (this_level <= level){ // higher level than before; end parent ol
78
- for(var i = this_level; i < level; i++) {
79
- html += "</li></"+settings.listType+">"
72
+ .addClass('clickable-header')
73
+ .each(function (_, header) {
74
+ this_level = get_level(header);
75
+ if (!settings.noBackToTopLinks && this_level === highest_level) {
76
+ $(header).addClass('top-level-header').after(return_to_top);
80
77
  }
81
- html += "<li class=\"" + settings.classes.item + "\">" + createLink(header);
82
- }
83
- else if (this_level > level) { // lower level than before; expand the previous to contain a ol
84
- for(i = this_level; i > level; i--) {
85
- html += "<" + settings.listType + " class=\"" + settings.classes.list +"\">" +
86
- "<li class=\"" + settings.classes.item + "\">"
78
+ if (this_level === level) // same level as before; same indenting
79
+ html += "<li class=\"" + settings.classes.item + "\">" + createLink(header);
80
+ else if (this_level <= level) { // higher level than before; end parent ol
81
+ for (var i = this_level; i < level; i++) {
82
+ html += "</li></" + settings.listType + ">"
83
+ }
84
+ html += "<li class=\"" + settings.classes.item + "\">" + createLink(header);
87
85
  }
88
- html += createLink(header);
89
- }
90
- level = this_level; // update for the next one
91
- });
92
- html += "</"+settings.listType+">";
86
+ else if (this_level > level) { // lower level than before; expand the previous to contain a ol
87
+ for (i = this_level; i > level; i--) {
88
+ html += "<" + settings.listType + " class=\"" + settings.classes.list + "\">" +
89
+ "<li class=\"" + settings.classes.item + "\">"
90
+ }
91
+ html += createLink(header);
92
+ }
93
+ level = this_level; // update for the next one
94
+ });
95
+ html += "</" + settings.listType + ">";
93
96
  if (!settings.noBackToTopLinks) {
94
- $(document).on('click', '.back-to-top', function() {
97
+ $(document).on('click', '.back-to-top', function () {
95
98
  $(window).scrollTop(0);
96
99
  window.location.hash = '';
97
100
  });
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: elixir-toolkit-theme
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.26.0
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - bedroesb
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-04-25 00:00:00.000000000 Z
11
+ date: 2023-06-23 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -16,14 +16,28 @@ dependencies:
16
16
  requirements:
17
17
  - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '3.9'
19
+ version: 4.3.1
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '3.9'
26
+ version: 4.3.1
27
+ - !ruby/object:Gem::Dependency
28
+ name: elixir-toolkit-theme-plugins
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: 0.1.2
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: 0.1.2
27
41
  - !ruby/object:Gem::Dependency
28
42
  name: bundler
29
43
  requirement: !ruby/object:Gem::Requirement