datalog-theme 0.9.0 → 0.9.2
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 +4 -4
- data/CHANGELOG.md +30 -0
- data/CITATION.cff +2 -2
- data/_data/i18n/en.yml +24 -0
- data/_data/i18n/es.yml +24 -0
- data/_data/i18n/pt.yml +24 -0
- data/_includes/components/academic-dashboard.html +4 -4
- data/_includes/components/author-list.html +1 -1
- data/_includes/components/breadcrumbs.html +6 -4
- data/_includes/components/citation-tools.html +5 -53
- data/_includes/components/comments-thread.html +1 -1
- data/_includes/components/contact-form.html +1 -1
- data/_includes/components/correction-report.html +1 -1
- data/_includes/components/hero.html +1 -1
- data/_includes/components/moderation-inbox.html +1 -1
- data/_includes/components/post-hero.html +2 -2
- data/_includes/components/reactions.html +1 -1
- data/_includes/components/reading-list.html +3 -0
- data/_includes/components/reading-mode-toggle.html +2 -0
- data/_includes/components/reading-state-panel.html +0 -9
- data/_includes/components/reading-state-resume.html +17 -0
- data/_includes/components/subscribe-form.html +1 -1
- data/_includes/components/subscription-manage.html +2 -1
- data/_includes/components/visualization-card.html +1 -1
- data/_includes/components/webmentions.html +1 -1
- data/_includes/footer/nav-column.html +1 -1
- data/_includes/footer.html +2 -2
- data/_includes/head.html +13 -12
- data/_includes/header/navigation.html +2 -2
- data/_includes/header.html +1 -1
- data/_includes/layouts/default/article.html +2 -2
- data/_includes/meta/math-config.html +3 -0
- data/_includes/meta/person-json.html +7 -7
- data/_includes/meta/publisher.html +1 -1
- data/_includes/meta/schema.html +32 -30
- data/_includes/meta/scholarly.html +4 -3
- data/_includes/post/related-posts.html +1 -1
- data/_layouts/dataset.html +1 -1
- data/_layouts/home.html +2 -2
- data/_layouts/notebook.html +1 -1
- data/_layouts/package.html +5 -5
- data/_layouts/portfolio.html +1 -1
- data/_layouts/post.html +12 -7
- data/_layouts/project.html +3 -3
- data/_layouts/research.html +7 -67
- data/_plugins/authors.rb +22 -4
- data/_plugins/citation_exports.rb +93 -0
- data/_plugins/image_optimizer.rb +24 -16
- data/_plugins/licenses.rb +15 -3
- data/_plugins/math_preprocessor.rb +65 -3
- data/_plugins/references.rb +30 -8
- data/_plugins/reproducibility.rb +20 -3
- data/_plugins/responsive_content.rb +40 -0
- data/_plugins/revisions.rb +1 -0
- data/_plugins/scholarly.rb +5 -0
- data/_plugins/statements.rb +2 -2
- data/_sass/_base.scss +5 -0
- data/_sass/_layout.scss +18 -1
- data/_sass/_mathematical.scss +11 -1
- data/_sass/_print.scss +16 -8
- data/_sass/_syntax-highlighting.scss +1 -1
- data/assets/js/dist/chunks/chunk-VZ5WKQVA.js +1 -0
- data/assets/js/dist/chunks/chunk-WIRUK3OZ.js +1 -0
- data/assets/js/dist/comments.js +2 -2
- data/assets/js/dist/contact.js +1 -1
- data/assets/js/dist/corrections.js +1 -1
- data/assets/js/dist/moderation.js +1 -1
- data/assets/js/dist/reactions.js +1 -1
- data/assets/js/dist/reading-state.js +1 -1
- data/assets/js/dist/sources.json +16 -16
- data/assets/js/dist/subscriptions.js +1 -1
- data/assets/js/dist/visualizations.js +2 -2
- data/assets/js/dist/webmentions.js +1 -1
- data/lib/datalog/theme/version.rb +1 -1
- metadata +7 -4
- data/assets/js/dist/chunks/chunk-2DYDWUFX.js +0 -1
- data/assets/js/dist/chunks/chunk-V7734B2G.js +0 -1
data/_includes/head.html
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
{% assign page_title = page.seo_title | default: page.title | default: site.title %}
|
|
2
|
-
{% assign
|
|
2
|
+
{% assign excerpt_description = page.excerpt | strip_html %}
|
|
3
|
+
{% assign page_description = page.seo_description | default: page.description | default: excerpt_description | default: site.description %}
|
|
3
4
|
{% assign canonical_url = page.url | default: page.permalink | default: '/' | absolute_url %}
|
|
4
5
|
{% assign raw_keywords = page.keywords | default: page.tags | default: site.keywords %}
|
|
5
6
|
{% assign localization_config = site.theme_options.localization %}
|
|
@@ -23,7 +24,7 @@
|
|
|
23
24
|
{% include csp-meta.html %}
|
|
24
25
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
25
26
|
<meta name="theme-color" content="#0b1d3d" />
|
|
26
|
-
<meta name="description" content="{{ page_description |
|
|
27
|
+
<meta name="description" content="{{ page_description | normalize_whitespace | escape }}" />
|
|
27
28
|
{% assign head_authors = page | page_authors %}
|
|
28
29
|
<meta name="author" content="{{ head_authors | map: 'name' | join: ', ' | escape }}" />
|
|
29
30
|
{% if keyword_list %}
|
|
@@ -34,15 +35,15 @@
|
|
|
34
35
|
{%- comment -%} `robots:` in front matter keeps a page out of search results, as the 404, search and admin pages do. {%- endcomment %}
|
|
35
36
|
<meta name="robots" content="{{ page.robots | default: 'index,follow' }}" />
|
|
36
37
|
<meta name="format-detection" content="telephone=no" />
|
|
37
|
-
<meta name="application-name" content="{{ site.title }}" />
|
|
38
|
-
<meta property="og:site_name" content="{{ site.title }}" />
|
|
38
|
+
<meta name="application-name" content="{{ site.title | escape }}" />
|
|
39
|
+
<meta property="og:site_name" content="{{ site.title | escape }}" />
|
|
39
40
|
{% if page.layout == 'post' or page.collection == 'posts' %}
|
|
40
41
|
<meta property="og:type" content="article" />
|
|
41
42
|
{% else %}
|
|
42
43
|
<meta property="og:type" content="website" />
|
|
43
44
|
{% endif %}
|
|
44
|
-
<meta property="og:title" content="{{ page_title |
|
|
45
|
-
<meta property="og:description" content="{{ page_description |
|
|
45
|
+
<meta property="og:title" content="{{ page_title | normalize_whitespace | escape }}" />
|
|
46
|
+
<meta property="og:description" content="{{ page_description | normalize_whitespace | escape }}" />
|
|
46
47
|
<meta property="og:url" content="{{ canonical_url }}" />
|
|
47
48
|
{% if page.og_image or page.image %}
|
|
48
49
|
<meta property="og:image" content="{{ page.og_image | default: page.image | absolute_url }}" />
|
|
@@ -53,8 +54,8 @@
|
|
|
53
54
|
<meta property="og:see_also" content="{{ site.url }}" />
|
|
54
55
|
<meta name="twitter:card" content="summary_large_image" />
|
|
55
56
|
<meta name="twitter:site" content="{{ site.social.twitter | default: site.twitter_username }}" />
|
|
56
|
-
<meta name="twitter:title" content="{{ page_title |
|
|
57
|
-
<meta name="twitter:description" content="{{ page_description |
|
|
57
|
+
<meta name="twitter:title" content="{{ page_title | normalize_whitespace | escape }}" />
|
|
58
|
+
<meta name="twitter:description" content="{{ page_description | normalize_whitespace | escape }}" />
|
|
58
59
|
{% if page.twitter_image or page.og_image or page.image %}
|
|
59
60
|
<meta name="twitter:image" content="{{ page.twitter_image | default: page.og_image | default: page.image | absolute_url }}" />
|
|
60
61
|
{% elsif site.social.default_image %}
|
|
@@ -154,11 +155,11 @@
|
|
|
154
155
|
<meta name="msapplication-TileColor" content="#0b1d3d" />
|
|
155
156
|
|
|
156
157
|
{% if page.seo_title %}
|
|
157
|
-
<title>{{ page.seo_title |
|
|
158
|
+
<title>{{ page.seo_title | normalize_whitespace | escape }} | {{ site.title | escape }}</title>
|
|
158
159
|
{% elsif page.title and page.title != site.title %}
|
|
159
|
-
<title>{{ page.title |
|
|
160
|
+
<title>{{ page.title | normalize_whitespace | escape }} | {{ site.title | escape }}</title>
|
|
160
161
|
{% else %}
|
|
161
|
-
<title>{{ site.title }}</title>
|
|
162
|
+
<title>{{ site.title | escape }}</title>
|
|
162
163
|
{% endif %}
|
|
163
164
|
|
|
164
165
|
{%- comment -%}
|
|
@@ -355,7 +356,7 @@
|
|
|
355
356
|
{%- comment -%} Highwire and Dublin Core tags, for a page read as a research article; the include decides which. {%- endcomment -%}
|
|
356
357
|
{% include meta/scholarly.html %}
|
|
357
358
|
|
|
358
|
-
<link rel="alternate" type="application/atom+xml" title="{{ site.title }}" href="{{ '/feed.xml' | absolute_url }}" />
|
|
359
|
+
<link rel="alternate" type="application/atom+xml" title="{{ site.title | escape }}" href="{{ '/feed.xml' | absolute_url }}" />
|
|
359
360
|
<meta http-equiv="Permissions-Policy" content="interest-cohort=()" />
|
|
360
361
|
{%- comment -%} A verification tag renders only when the site sets its code: an empty one verifies nothing. {%- endcomment %}
|
|
361
362
|
{% if site.google_site_verification and site.google_site_verification != "" %}
|
|
@@ -35,9 +35,9 @@ page language gets its own copy of any translated descriptions.
|
|
|
35
35
|
{%- assign nav_description = nav_section | default: nav_title -%}
|
|
36
36
|
{%- assign nav_description = nav_description | append: ' resources' -%}
|
|
37
37
|
{%- endif -%}
|
|
38
|
-
<li class="nav-item" data-section="{{ item.section | default: nav_title | downcase }}">
|
|
38
|
+
<li class="nav-item" data-section="{{ item.section | default: nav_title | downcase | escape }}">
|
|
39
39
|
<a class="nav-link{% if is_active %} is-active{% endif %}" href="{{ item_url }}"{% if is_active %} aria-current="page"{% endif %}>
|
|
40
|
-
<span class="nav-title">{{ nav_title }}</span>
|
|
40
|
+
<span class="nav-title">{{ nav_title | escape }}</span>
|
|
41
41
|
<span class="nav-description">{{ nav_description | strip }}</span>
|
|
42
42
|
</a>
|
|
43
43
|
</li>
|
data/_includes/header.html
CHANGED
|
@@ -39,7 +39,7 @@ and is cached for each distinct set.
|
|
|
39
39
|
</svg>
|
|
40
40
|
</span>
|
|
41
41
|
<span class="site-title-group">
|
|
42
|
-
<span class="site-title">{{ site.name | default: site.title }}</span>
|
|
42
|
+
<span class="site-title">{{ site.name | default: site.title | escape }}</span>
|
|
43
43
|
<span class="site-tagline">{{ brand_symbol }}</span>
|
|
44
44
|
</span>
|
|
45
45
|
</a>
|
|
@@ -24,10 +24,10 @@ Renders the standard article scaffold used by the default layout.
|
|
|
24
24
|
page or layout that renders its own heading, so the page has one.
|
|
25
25
|
{%- endcomment -%}
|
|
26
26
|
{%- if article_page.title and article_page.show_title != false and layout.show_title != false -%}
|
|
27
|
-
<h1 class="article-title" itemprop="headline">{{ article_page.title }}</h1>
|
|
27
|
+
<h1 class="article-title" itemprop="headline">{{ article_page.title | escape }}</h1>
|
|
28
28
|
{%- endif -%}
|
|
29
29
|
{%- if article_page.subtitle -%}
|
|
30
|
-
<p class="article-subtitle">{{ article_page.subtitle }}</p>
|
|
30
|
+
<p class="article-subtitle">{{ article_page.subtitle | escape }}</p>
|
|
31
31
|
{%- endif -%}
|
|
32
32
|
{%- endunless -%}
|
|
33
33
|
{%- if article_page.excerpt -%}
|
|
@@ -37,6 +37,9 @@ only on pages that opt in.
|
|
|
37
37
|
{%- if math_load == nil -%}
|
|
38
38
|
{%- assign math_load = site.features.mathjax -%}
|
|
39
39
|
{%- endif -%}
|
|
40
|
+
{%- if math_load == nil -%}
|
|
41
|
+
{%- assign math_load = 'auto' -%}
|
|
42
|
+
{%- endif -%}
|
|
40
43
|
{%- if include.page.math != nil -%}
|
|
41
44
|
{%- assign math_enabled = include.page.math -%}
|
|
42
45
|
{%- elsif include.page.mathjax != nil -%}
|
|
@@ -8,20 +8,20 @@ One schema.org Person, as JSON, for a record from `page | page_authors` or
|
|
|
8
8
|
record names no url of its own.
|
|
9
9
|
{%- endcomment -%}
|
|
10
10
|
{%- assign person_url = include.person.url -%}
|
|
11
|
-
{%- if person_url == nil and include.person.site_author -%}{%- assign person_url =
|
|
11
|
+
{%- if person_url == nil and include.person.site_author -%}{%- assign person_url = '/' -%}{%- endif -%}
|
|
12
12
|
{
|
|
13
|
-
"@type": "Person",
|
|
14
|
-
"name": {{ include.person.name |
|
|
13
|
+
"@type": {% if include.person.type == 'Organization' %}"Organization"{% else %}"Person"{% endif %},
|
|
14
|
+
"name": {{ include.person.name | jsonify_script }}
|
|
15
15
|
{%- if person_url -%},
|
|
16
|
-
"url": {{ person_url | absolute_url |
|
|
16
|
+
"url": {{ person_url | absolute_url | jsonify_script }}
|
|
17
17
|
{%- endif -%}
|
|
18
18
|
{%- if include.person.affiliation -%},
|
|
19
19
|
"affiliation": {
|
|
20
20
|
"@type": "Organization",
|
|
21
|
-
"name": {{ include.person.affiliation |
|
|
21
|
+
"name": {{ include.person.affiliation | jsonify_script }}
|
|
22
22
|
}
|
|
23
23
|
{%- endif -%}
|
|
24
24
|
{%- if include.person.same_as.size > 0 -%},
|
|
25
|
-
"sameAs": {{ include.person.same_as |
|
|
25
|
+
"sameAs": {{ include.person.same_as | jsonify_script }}
|
|
26
26
|
{%- endif -%}
|
|
27
|
-
}
|
|
27
|
+
}
|
|
@@ -31,7 +31,7 @@ on the author.
|
|
|
31
31
|
{%- if site.publisher.url -%}
|
|
32
32
|
{%- assign publisher_url = site.publisher.url | absolute_url -%}
|
|
33
33
|
{%- else -%}
|
|
34
|
-
{%- assign publisher_url =
|
|
34
|
+
{%- assign publisher_url = '/' | absolute_url -%}
|
|
35
35
|
{%- endif -%}
|
|
36
36
|
{%- assign publisher_logo = nil -%}
|
|
37
37
|
{%- assign publisher_logo_default = false -%}
|
data/_includes/meta/schema.html
CHANGED
|
@@ -7,13 +7,13 @@ optional:
|
|
|
7
7
|
---
|
|
8
8
|
Outputs comprehensive JSON-LD metadata for the current page.
|
|
9
9
|
Provides rich structured data for:
|
|
10
|
-
- Article/BlogPosting/
|
|
10
|
+
- Article/BlogPosting/TechArticle schema for posts
|
|
11
11
|
- WebPage schema for standard pages
|
|
12
12
|
- Author information with social profile links
|
|
13
13
|
- Publisher: a Person or an Organization, from `publisher` in _config.yml
|
|
14
14
|
- Images, keywords, and content metadata
|
|
15
15
|
|
|
16
|
-
Defaults to
|
|
16
|
+
Defaults to TechArticle for posts, WebPage for other pages.
|
|
17
17
|
{%- endcomment -%}
|
|
18
18
|
{%- assign schema_page = include.page -%}
|
|
19
19
|
{%- include meta/publisher.html -%}
|
|
@@ -23,13 +23,15 @@ Defaults to TechnicalArticle for posts, WebPage for other pages.
|
|
|
23
23
|
{%- endif -%}
|
|
24
24
|
{%- assign default_type = 'WebPage' -%}
|
|
25
25
|
{%- if is_post -%}
|
|
26
|
-
{%- assign default_type = '
|
|
26
|
+
{%- assign default_type = 'TechArticle' -%}
|
|
27
27
|
{%- endif -%}
|
|
28
|
-
{%- assign schema_type = include.type | default: schema_page.schema_type | default: default_type -%}
|
|
28
|
+
{%- assign schema_type = include.type | default: schema_page.schema_type | default: layout.schema_type | default: default_type -%}
|
|
29
|
+
{%- if schema_type == 'TechnicalArticle' -%}{%- assign schema_type = 'TechArticle' -%}{%- endif -%}
|
|
29
30
|
{%- assign csp_registry = site.data.csp | default: {} -%}
|
|
30
31
|
{%- assign nonce_lookup = csp_registry.nonces | default: {} -%}
|
|
31
32
|
{%- assign schema_nonce = schema_page.csp_nonce | default: page.csp_nonce | default: nonce_lookup[schema_page.path] | default: nonce_lookup[page.path] | default: nonce_lookup[page.url] -%}
|
|
32
|
-
{%- assign
|
|
33
|
+
{%- assign schema_excerpt = schema_page.excerpt | strip_html -%}
|
|
34
|
+
{%- assign description = schema_page.seo_description | default: schema_page.description | default: schema_excerpt | default: site.description | strip_newlines | truncate: 300 -%}
|
|
33
35
|
{%- assign page_url = schema_page.url | absolute_url -%}
|
|
34
36
|
{%- assign schema_authors = schema_page | page_authors -%}
|
|
35
37
|
{%- assign schema_contributors = schema_page | page_contributors -%}
|
|
@@ -38,28 +40,28 @@ Defaults to TechnicalArticle for posts, WebPage for other pages.
|
|
|
38
40
|
<script type="application/ld+json" nonce="{{ schema_nonce }}">
|
|
39
41
|
{
|
|
40
42
|
"@context": "https://schema.org",
|
|
41
|
-
"@type":
|
|
43
|
+
"@type": {{ schema_type | jsonify_script }},
|
|
42
44
|
"mainEntityOfPage": {
|
|
43
45
|
"@type": "WebPage",
|
|
44
|
-
"@id": {{ page_url |
|
|
46
|
+
"@id": {{ page_url | jsonify_script }}
|
|
45
47
|
},
|
|
46
|
-
"headline": {{ schema_page.title | default: site.title | truncate: 110 |
|
|
48
|
+
"headline": {{ schema_page.title | default: site.title | truncate: 110 | jsonify_script }},
|
|
47
49
|
{%- comment -%} Values the page doesn't have are left out: "description": "" and "dateModified": "" are invalid structured data. {%- endcomment -%}
|
|
48
50
|
{%- if description and description != "" -%}
|
|
49
|
-
"description": {{ description |
|
|
51
|
+
"description": {{ description | jsonify_script }},
|
|
50
52
|
{%- endif -%}
|
|
51
|
-
"url": {{ page_url |
|
|
53
|
+
"url": {{ page_url | jsonify_script }},
|
|
52
54
|
{%- if schema_page.image or schema_page.og_image -%}
|
|
53
55
|
"image": {
|
|
54
56
|
"@type": "ImageObject",
|
|
55
|
-
"url": {{ schema_page.image | default: schema_page.og_image | absolute_url |
|
|
57
|
+
"url": {{ schema_page.image | default: schema_page.og_image | absolute_url | jsonify_script }},
|
|
56
58
|
"width": {{ schema_page.image_width | default: 1200 }},
|
|
57
59
|
"height": {{ schema_page.image_height | default: 630 }}
|
|
58
60
|
},
|
|
59
61
|
{%- elsif site.social.default_image -%}
|
|
60
62
|
"image": {
|
|
61
63
|
"@type": "ImageObject",
|
|
62
|
-
"url": {{ site.social.default_image | absolute_url |
|
|
64
|
+
"url": {{ site.social.default_image | absolute_url | jsonify_script }},
|
|
63
65
|
"width": 1200,
|
|
64
66
|
"height": 630
|
|
65
67
|
},
|
|
@@ -74,10 +76,10 @@ Defaults to TechnicalArticle for posts, WebPage for other pages.
|
|
|
74
76
|
"wordCount": {{ word_count }},
|
|
75
77
|
{%- endif -%}
|
|
76
78
|
{%- if schema_page.tags and schema_page.tags.size > 0 -%}
|
|
77
|
-
"keywords": {{ schema_page.tags |
|
|
79
|
+
"keywords": {{ schema_page.tags | jsonify_script }},
|
|
78
80
|
{%- endif -%}
|
|
79
81
|
{%- if schema_page.categories and schema_page.categories.size > 0 -%}
|
|
80
|
-
"articleSection": {{ schema_page.categories | first |
|
|
82
|
+
"articleSection": {{ schema_page.categories | first | jsonify_script }},
|
|
81
83
|
{%- endif -%}
|
|
82
84
|
{%- if is_post -%}
|
|
83
85
|
"inLanguage": "{{ schema_page.lang | default: site.locale | default: 'en' | split: '_' | first }}",
|
|
@@ -98,13 +100,13 @@ Defaults to TechnicalArticle for posts, WebPage for other pages.
|
|
|
98
100
|
],
|
|
99
101
|
{%- endif -%}
|
|
100
102
|
"publisher": {
|
|
101
|
-
"@type": {{ publisher_type |
|
|
102
|
-
"name": {{ publisher_name |
|
|
103
|
-
"url": {{ publisher_url |
|
|
103
|
+
"@type": {{ publisher_type | jsonify_script }},
|
|
104
|
+
"name": {{ publisher_name | jsonify_script }},
|
|
105
|
+
"url": {{ publisher_url | jsonify_script }}
|
|
104
106
|
{%- if publisher_logo -%},
|
|
105
107
|
"logo": {
|
|
106
108
|
"@type": "ImageObject",
|
|
107
|
-
"url": {{ publisher_logo |
|
|
109
|
+
"url": {{ publisher_logo | jsonify_script }}
|
|
108
110
|
{%- if publisher_logo_default -%},
|
|
109
111
|
"width": 512,
|
|
110
112
|
"height": 512
|
|
@@ -116,27 +118,27 @@ Defaults to TechnicalArticle for posts, WebPage for other pages.
|
|
|
116
118
|
"identifier": {
|
|
117
119
|
"@type": "PropertyValue",
|
|
118
120
|
"propertyID": "doi",
|
|
119
|
-
"value": {{ schema_page.doi |
|
|
121
|
+
"value": {{ schema_page.doi | jsonify_script }}
|
|
120
122
|
}
|
|
121
123
|
{%- endif -%}
|
|
122
124
|
{%- if schema_page.citation_key -%},
|
|
123
|
-
"citation": {{ schema_page.citation_key |
|
|
125
|
+
"citation": {{ schema_page.citation_key | jsonify_script }}
|
|
124
126
|
{%- endif -%}
|
|
125
127
|
{%- comment -%} The licence of the text and figures, and who holds the copyright. {%- endcomment -%}
|
|
126
128
|
{%- assign content_license = schema_page | page_license -%}
|
|
127
129
|
{%- if content_license -%}
|
|
128
130
|
{%- if content_license.url -%},
|
|
129
|
-
"license": {{ content_license.url |
|
|
131
|
+
"license": {{ content_license.url | jsonify_script }}
|
|
130
132
|
{%- endif -%}
|
|
131
133
|
{%- if content_license.year -%},
|
|
132
|
-
"copyrightYear": {{ content_license.year |
|
|
134
|
+
"copyrightYear": {{ content_license.year | jsonify_script }}
|
|
133
135
|
{%- endif -%}
|
|
134
136
|
{%- if content_license.holder -%},
|
|
135
137
|
"copyrightHolder": {% if content_license.people %}{% if content_license.holders.size > 1 %}[{% endif %}
|
|
136
138
|
{%- for holder in content_license.holders -%}
|
|
137
|
-
{ "@type": "Person", "name": {{ holder |
|
|
139
|
+
{ "@type": "Person", "name": {{ holder | jsonify_script }} }{% unless forloop.last %},{% endunless %}
|
|
138
140
|
{%- endfor -%}
|
|
139
|
-
{% if content_license.holders.size > 1 %}]{% endif %}{% else %}{ "@type": "Organization", "name": {{ content_license.holder |
|
|
141
|
+
{% if content_license.holders.size > 1 %}]{% endif %}{% else %}{ "@type": "Organization", "name": {{ content_license.holder | jsonify_script }} }{% endif %}
|
|
140
142
|
{%- endif -%}
|
|
141
143
|
{%- endif -%}
|
|
142
144
|
{%- comment -%} Each correction in the revision history, with its date, summary and link. {%- endcomment -%}
|
|
@@ -147,11 +149,11 @@ Defaults to TechnicalArticle for posts, WebPage for other pages.
|
|
|
147
149
|
{
|
|
148
150
|
"@type": "CorrectionComment",
|
|
149
151
|
"datePublished": "{{ correction.date | date_to_xmlschema }}",
|
|
150
|
-
"text": {{ correction.summary |
|
|
152
|
+
"text": {{ correction.summary | jsonify_script }}
|
|
151
153
|
{%- if correction.details_url -%}
|
|
152
154
|
{%- assign correction_url = correction.details_url -%}
|
|
153
155
|
{%- unless correction_url contains '://' -%}{%- assign correction_url = correction_url | absolute_url -%}{%- endunless -%},
|
|
154
|
-
"url": {{ correction_url |
|
|
156
|
+
"url": {{ correction_url | jsonify_script }}
|
|
155
157
|
{%- endif -%}
|
|
156
158
|
}{% unless forloop.last %},{% endunless %}
|
|
157
159
|
{%- endfor -%}
|
|
@@ -170,19 +172,19 @@ Defaults to TechnicalArticle for posts, WebPage for other pages.
|
|
|
170
172
|
"@type": "ListItem",
|
|
171
173
|
"position": 1,
|
|
172
174
|
"name": "Home",
|
|
173
|
-
"item": {{
|
|
175
|
+
"item": {{ '/' | absolute_url | jsonify_script }}
|
|
174
176
|
},
|
|
175
177
|
{
|
|
176
178
|
"@type": "ListItem",
|
|
177
179
|
"position": 2,
|
|
178
180
|
"name": "Blog",
|
|
179
|
-
"item": {{ '/blog/' | absolute_url |
|
|
181
|
+
"item": {{ '/blog/' | absolute_url | jsonify_script }}
|
|
180
182
|
},
|
|
181
183
|
{
|
|
182
184
|
"@type": "ListItem",
|
|
183
185
|
"position": 3,
|
|
184
|
-
"name": {{ schema_page.title | truncate: 50 |
|
|
185
|
-
"item": {{ page_url |
|
|
186
|
+
"name": {{ schema_page.title | truncate: 50 | jsonify_script }},
|
|
187
|
+
"item": {{ page_url | jsonify_script }}
|
|
186
188
|
}
|
|
187
189
|
]
|
|
188
190
|
}
|
|
@@ -14,7 +14,7 @@ the indexed authors alone.
|
|
|
14
14
|
{%- assign is_scholarly = page | scholarly -%}
|
|
15
15
|
{%- if is_scholarly and page.title -%}
|
|
16
16
|
{%- include meta/publisher.html -%}
|
|
17
|
-
{%- assign scholarly_title = page.citation_title | default: page.title |
|
|
17
|
+
{%- assign scholarly_title = page.citation_title | default: page.title | normalize_whitespace -%}
|
|
18
18
|
{%- assign scholarly_url = page.url | absolute_url -%}
|
|
19
19
|
{%- assign scholarly_authors = page | page_authors -%}
|
|
20
20
|
{%- assign scholarly_names = scholarly_authors | map: 'name' -%}
|
|
@@ -26,7 +26,7 @@ the indexed authors alone.
|
|
|
26
26
|
{%- if citation_source_first == '[' -%}
|
|
27
27
|
{%- assign scholarly_names = page.citation_authors -%}
|
|
28
28
|
{%- else -%}
|
|
29
|
-
{%- assign scholarly_names = page.citation_authors |
|
|
29
|
+
{%- assign scholarly_names = page.citation_authors | split: ';' -%}
|
|
30
30
|
{%- endif -%}
|
|
31
31
|
{%- endif -%}
|
|
32
32
|
{%- assign scholarly_pdf = page.pdf_url | default: page.citation_pdf -%}
|
|
@@ -36,7 +36,8 @@ the indexed authors alone.
|
|
|
36
36
|
{%- assign scholarly_publisher = page.publisher | default: publisher_name -%}
|
|
37
37
|
{%- assign scholarly_language = page.lang | default: site.locale | default: 'en' | split: '_' | first | split: '-' | first -%}
|
|
38
38
|
{%- assign scholarly_license = page | page_license -%}
|
|
39
|
-
{%- assign
|
|
39
|
+
{%- assign scholarly_excerpt = page.excerpt | strip_html -%}
|
|
40
|
+
{%- assign scholarly_description = page.seo_description | default: page.description | default: scholarly_excerpt | normalize_whitespace | truncate: 300 -%}
|
|
40
41
|
<meta name="citation_title" content="{{ scholarly_title | escape }}" />
|
|
41
42
|
{%- if scholarly_override %}
|
|
42
43
|
{%- for name in scholarly_names %}
|
|
@@ -41,7 +41,7 @@ Falls back to a friendly message when no related content is available.
|
|
|
41
41
|
{%- if candidate.teaser -%}
|
|
42
42
|
<a class="related-post__media" href="{{ candidate.url | relative_url }}" tabindex="-1" aria-hidden="true"><img src="{{ candidate.teaser | relative_url }}" alt="" loading="lazy" decoding="async" /></a>
|
|
43
43
|
{%- endif -%}
|
|
44
|
-
<h3><a href="{{ candidate.url | relative_url }}">{{ candidate.title }}</a></h3>
|
|
44
|
+
<h3><a href="{{ candidate.url | relative_url }}">{{ candidate.title | escape }}</a></h3>
|
|
45
45
|
<p class="related-post-meta">
|
|
46
46
|
{% include helpers/date-format.html date=candidate.date format=include.date_format %} · {{ candidate.excerpt | strip_html | default: '' | truncate: 140 }}
|
|
47
47
|
</p>
|
data/_layouts/dataset.html
CHANGED
|
@@ -6,7 +6,7 @@ show_title: false # this layout renders the page's <h1>
|
|
|
6
6
|
{% assign date_format = page.date_format | default: localization_config.date_format | default: 'long' %}
|
|
7
7
|
<article class="dataset">
|
|
8
8
|
<header class="dataset-header">
|
|
9
|
-
<h1>{{ page.title }}</h1>
|
|
9
|
+
<h1>{{ page.title | escape }}</h1>
|
|
10
10
|
{% if page.updated %}<p class="dataset-meta"><strong>{% t 'dataset.last_updated' %}</strong> {{ page.updated | localize_date: date_format }}</p>{% endif %}
|
|
11
11
|
{% assign dataset_license = page | page_license %}
|
|
12
12
|
{% if dataset_license %}<p class="dataset-meta"><strong>{% t 'dataset.license' %}</strong> {% include components/license-link.html license=dataset_license %}</p>{% endif %}
|
data/_layouts/home.html
CHANGED
|
@@ -13,7 +13,7 @@ layout: default
|
|
|
13
13
|
{% if post.teaser %}
|
|
14
14
|
<a class="card-media" href="{{ post.url | relative_url }}" tabindex="-1" aria-hidden="true"><img src="{{ post.teaser | relative_url }}" alt="" loading="lazy" decoding="async" /></a>
|
|
15
15
|
{% endif %}
|
|
16
|
-
<h3><a href="{{ post.url | relative_url }}">{{ post.title }}</a></h3>
|
|
16
|
+
<h3><a href="{{ post.url | relative_url }}">{{ post.title | escape }}</a></h3>
|
|
17
17
|
{% assign home_date_format = localization_config.date_format | default: 'long' %}
|
|
18
18
|
{% assign reading_minutes = post.reading_time | default: post.content | number_of_words | divided_by: 180 | ceil %}
|
|
19
19
|
{% capture reading_label %}
|
|
@@ -43,7 +43,7 @@ layout: default
|
|
|
43
43
|
{% assign featured = site.portfolio | sort: 'weight' | slice: 0, 3 %}
|
|
44
44
|
{% for item in featured %}
|
|
45
45
|
<article class="card">
|
|
46
|
-
<h3><a href="{{ item.url | relative_url }}">{{ item.title }}</a></h3>
|
|
46
|
+
<h3><a href="{{ item.url | relative_url }}">{{ item.title | escape }}</a></h3>
|
|
47
47
|
<p>{{ item.summary | default: item.excerpt | strip_html | truncate: 120 }}</p>
|
|
48
48
|
<a class="card-link" href="{{ item.url | relative_url }}">{% t 'home.view_project' %}</a>
|
|
49
49
|
</article>
|
data/_layouts/notebook.html
CHANGED
|
@@ -20,7 +20,7 @@ show_title: false # this layout renders the page's <h1>
|
|
|
20
20
|
|
|
21
21
|
<header class="notebook-article__header">
|
|
22
22
|
<p class="notebook-article__label">{% t 'notebook.label' %}</p>
|
|
23
|
-
<h1 class="notebook-article__title" itemprop="headline">{{ page.title }}</h1>
|
|
23
|
+
<h1 class="notebook-article__title" itemprop="headline">{{ page.title | escape }}</h1>
|
|
24
24
|
<p class="notebook-article__summary">{{ page.summary | default: page.excerpt }}</p>
|
|
25
25
|
|
|
26
26
|
<ul class="notebook-article__meta">
|
data/_layouts/package.html
CHANGED
|
@@ -12,7 +12,7 @@ show_title: false # this layout renders the page's <h1>
|
|
|
12
12
|
{% if page.icon %}
|
|
13
13
|
<span class="package-docs__icon">{{ page.icon }}</span>
|
|
14
14
|
{% endif %}
|
|
15
|
-
{{ page.title }}
|
|
15
|
+
{{ page.title | escape }}
|
|
16
16
|
</h1>
|
|
17
17
|
{% if page.tagline %}
|
|
18
18
|
<p class="package-docs__tagline">{{ page.tagline }}</p>
|
|
@@ -90,12 +90,12 @@ show_title: false # this layout renders the page's <h1>
|
|
|
90
90
|
{% if page.nav_sections %}
|
|
91
91
|
{% for section in page.nav_sections %}
|
|
92
92
|
<div class="package-nav__section">
|
|
93
|
-
<h3 class="package-nav__section-title">{{ section.title }}</h3>
|
|
93
|
+
<h3 class="package-nav__section-title">{{ section.title | escape }}</h3>
|
|
94
94
|
<ul class="package-nav__list">
|
|
95
95
|
{% for item in section.items %}
|
|
96
96
|
<li class="package-nav__item">
|
|
97
97
|
<a href="#{{ item.id }}" class="package-nav__link">
|
|
98
|
-
{{ item.title }}
|
|
98
|
+
{{ item.title | escape }}
|
|
99
99
|
</a>
|
|
100
100
|
</li>
|
|
101
101
|
{% endfor %}
|
|
@@ -171,7 +171,7 @@ show_title: false # this layout renders the page's <h1>
|
|
|
171
171
|
</svg>
|
|
172
172
|
<div>
|
|
173
173
|
<span class="package-docs__footer-nav-label">Previous</span>
|
|
174
|
-
<span class="package-docs__footer-nav-title">{{ page.previous_page.title }}</span>
|
|
174
|
+
<span class="package-docs__footer-nav-title">{{ page.previous_page.title | escape }}</span>
|
|
175
175
|
</div>
|
|
176
176
|
</a>
|
|
177
177
|
{% endif %}
|
|
@@ -180,7 +180,7 @@ show_title: false # this layout renders the page's <h1>
|
|
|
180
180
|
<a href="{{ page.next_page.url | relative_url }}" class="package-docs__footer-nav-link package-docs__footer-nav-link--next">
|
|
181
181
|
<div>
|
|
182
182
|
<span class="package-docs__footer-nav-label">Next</span>
|
|
183
|
-
<span class="package-docs__footer-nav-title">{{ page.next_page.title }}</span>
|
|
183
|
+
<span class="package-docs__footer-nav-title">{{ page.next_page.title | escape }}</span>
|
|
184
184
|
</div>
|
|
185
185
|
<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2">
|
|
186
186
|
<polyline points="9 18 15 12 9 6"></polyline>
|
data/_layouts/portfolio.html
CHANGED
|
@@ -4,7 +4,7 @@ show_title: false # this layout renders the page's <h1>
|
|
|
4
4
|
---
|
|
5
5
|
<article class="portfolio-item">
|
|
6
6
|
<header class="portfolio-header">
|
|
7
|
-
<h1>{{ page.title }}</h1>
|
|
7
|
+
<h1>{{ page.title | escape }}</h1>
|
|
8
8
|
{% if page.hero_image %}
|
|
9
9
|
<div class="portfolio-hero-media">
|
|
10
10
|
{% assign hero_alt = page.hero_alt | default: page.title %}
|
data/_layouts/post.html
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
layout: default
|
|
3
|
-
schema_type:
|
|
3
|
+
schema_type: TechArticle
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
{% assign localization_config = site.theme_options.localization %}
|
|
@@ -39,6 +39,10 @@ schema_type: TechnicalArticle
|
|
|
39
39
|
|
|
40
40
|
{%- comment -%} Tag/Category flags {%- endcomment -%}
|
|
41
41
|
{% assign post_tags = page.tags %}
|
|
42
|
+
{% assign tag_archive_path = site.tag_archive.path | default: '/tags/' %}
|
|
43
|
+
{% assign category_archive_path = site.category_archive.path | default: '/categories/' %}
|
|
44
|
+
{% assign tag_archive_page = site.pages | where: 'url', tag_archive_path | first %}
|
|
45
|
+
{% assign category_archive_page = site.pages | where: 'url', category_archive_path | first %}
|
|
42
46
|
{% assign has_tags = false %}
|
|
43
47
|
{% if post_tags and post_tags.size > 0 %}{% assign has_tags = true %}{% endif %}
|
|
44
48
|
{% assign has_categories = false %}
|
|
@@ -50,7 +54,7 @@ schema_type: TechnicalArticle
|
|
|
50
54
|
{%- comment -%} Breadcrumb navigation {%- endcomment -%}
|
|
51
55
|
{% include components/breadcrumbs.html %}
|
|
52
56
|
|
|
53
|
-
<div class="post-wrapper" itemscope itemtype="https://schema.org/
|
|
57
|
+
<div class="post-wrapper" itemscope itemtype="https://schema.org/TechArticle">
|
|
54
58
|
<meta itemprop="url" content="{{ canonical_url }}" />
|
|
55
59
|
<meta itemprop="datePublished" content="{{ page.date | date_to_xmlschema }}" />
|
|
56
60
|
{% if page.last_modified_at or page.updated %}
|
|
@@ -127,6 +131,7 @@ schema_type: TechnicalArticle
|
|
|
127
131
|
{% include components/reading-state-bookmark.html %}
|
|
128
132
|
{% include components/reading-mode-toggle.html %}
|
|
129
133
|
</div>
|
|
134
|
+
{% include components/reading-state-resume.html %}
|
|
130
135
|
<p class="post-print-source print-only">{% t 'post.print.source' %} {{ canonical_url }}{% if page.doi %} · DOI {{ page.doi | escape }}{% endif %}</p>
|
|
131
136
|
|
|
132
137
|
{%- comment -%} The newest correction or update, with a link to the revision history {%- endcomment -%}
|
|
@@ -139,13 +144,13 @@ schema_type: TechnicalArticle
|
|
|
139
144
|
{% if has_tags %}
|
|
140
145
|
{% for tag in post_tags %}
|
|
141
146
|
{% assign tag_slug = tag | slugify %}
|
|
142
|
-
<li
|
|
147
|
+
<li>{% if tag_archive_page %}<a class="post-tag" href="{{ tag_archive_path | append: '#' | append: tag_slug | relative_url }}">{{ tag | escape }}</a>{% else %}<span class="post-tag">{{ tag | escape }}</span>{% endif %}</li>
|
|
143
148
|
{% endfor %}
|
|
144
149
|
{% endif %}
|
|
145
150
|
{% if has_categories %}
|
|
146
151
|
{% for category in page.categories %}
|
|
147
152
|
{% assign cat_slug = category | slugify %}
|
|
148
|
-
<li
|
|
153
|
+
<li>{% if category_archive_page %}<a class="post-tag post-category" href="{{ category_archive_path | append: '#' | append: cat_slug | relative_url }}">{{ category | escape }}</a>{% else %}<span class="post-tag post-category">{{ category | escape }}</span>{% endif %}</li>
|
|
149
154
|
{% endfor %}
|
|
150
155
|
{% endif %}
|
|
151
156
|
</ul>
|
|
@@ -195,7 +200,7 @@ schema_type: TechnicalArticle
|
|
|
195
200
|
<ul class="post-interactive-list">
|
|
196
201
|
{% for demo in page.interactive_components %}
|
|
197
202
|
<li>
|
|
198
|
-
<strong>{{ demo.title }}</strong>
|
|
203
|
+
<strong>{{ demo.title | escape }}</strong>
|
|
199
204
|
{% if demo.description %}<p>{{ demo.description }}</p>{% endif %}
|
|
200
205
|
{% if demo.url %}<p><a href="{{ demo.url | relative_url }}" target="_blank" rel="noopener noreferrer">{% t 'post.interactive.launch' %}</a></p>{% endif %}
|
|
201
206
|
</li>
|
|
@@ -283,7 +288,7 @@ schema_type: TechnicalArticle
|
|
|
283
288
|
{% if page.previous %}
|
|
284
289
|
<div class="post-prev">
|
|
285
290
|
<span class="post-pagination-label">Previous</span>
|
|
286
|
-
<a href="{{ page.previous.url | relative_url }}">{{ page.previous.title }}</a>
|
|
291
|
+
<a href="{{ page.previous.url | relative_url }}">{{ page.previous.title | escape }}</a>
|
|
287
292
|
{% if page.previous.tags and page.tags %}
|
|
288
293
|
{% assign shared_prev = '' %}
|
|
289
294
|
{% for tag in page.tags %}
|
|
@@ -302,7 +307,7 @@ schema_type: TechnicalArticle
|
|
|
302
307
|
{% if page.next %}
|
|
303
308
|
<div class="post-next">
|
|
304
309
|
<span class="post-pagination-label">Next</span>
|
|
305
|
-
<a href="{{ page.next.url | relative_url }}">{{ page.next.title }}</a>
|
|
310
|
+
<a href="{{ page.next.url | relative_url }}">{{ page.next.title | escape }}</a>
|
|
306
311
|
{% if page.next.tags and page.tags %}
|
|
307
312
|
{% assign shared_next = '' %}
|
|
308
313
|
{% for tag in page.tags %}
|
data/_layouts/project.html
CHANGED
|
@@ -8,9 +8,9 @@ show_title: false # this layout renders the page's <h1>
|
|
|
8
8
|
<header class="project-case__header">
|
|
9
9
|
<div class="project-case__intro">
|
|
10
10
|
<p class="project-case__eyebrow">{% t 'project.header.eyebrow' %}</p>
|
|
11
|
-
<h1 class="project-case__title" itemprop="name">{{ page.title }}</h1>
|
|
11
|
+
<h1 class="project-case__title" itemprop="name">{{ page.title | escape }}</h1>
|
|
12
12
|
{% if page.description %}
|
|
13
|
-
<p class="project-case__description" itemprop="description">{{ page.description }}</p>
|
|
13
|
+
<p class="project-case__description" itemprop="description">{{ page.description | escape }}</p>
|
|
14
14
|
{% endif %}
|
|
15
15
|
</div>
|
|
16
16
|
<div class="project-case__meta">
|
|
@@ -192,7 +192,7 @@ show_title: false # this layout renders the page's <h1>
|
|
|
192
192
|
<ul class="project-case__related">
|
|
193
193
|
{% for project in page.related_projects %}
|
|
194
194
|
<li>
|
|
195
|
-
{% if project.url %}<a href="{{ project.url | relative_url }}">{{ project.title | default: project }}</a>{% else %}<span>{{ project.title | default: project }}</span>{% endif %}
|
|
195
|
+
{% if project.url %}<a href="{{ project.url | relative_url }}">{{ project.title | default: project | escape }}</a>{% else %}<span>{{ project.title | default: project | escape }}</span>{% endif %}
|
|
196
196
|
{% if project.description %}<p>{{ project.description }}</p>{% endif %}
|
|
197
197
|
</li>
|
|
198
198
|
{% endfor %}
|