jekyll-theme-chirpy 7.1.1 → 7.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/_data/locales/hu-HU.yml +20 -7
- data/_data/origin/cors.yml +4 -4
- data/_includes/analytics/cloudflare.html +0 -1
- data/_includes/analytics/fathom.html +2 -3
- data/_includes/analytics/google.html +1 -1
- data/_includes/analytics/matomo.html +6 -7
- data/_includes/comments/disqus.html +36 -29
- data/_includes/comments/giscus.html +14 -30
- data/_includes/comments/utterances.html +26 -37
- data/_includes/head.html +24 -5
- data/_includes/js-selector.html +3 -26
- data/_includes/jsdelivr-combine.html +4 -4
- data/_includes/pageviews/goatcounter.html +16 -14
- data/_includes/search-loader.html +22 -20
- data/_includes/sidebar.html +1 -3
- data/_includes/toc-status.html +10 -0
- data/_includes/toc.html +4 -8
- data/_layouts/default.html +8 -4
- data/_layouts/home.html +26 -19
- data/_layouts/post.html +29 -2
- data/_sass/abstracts/_breakpoints.scss +73 -0
- data/_sass/abstracts/_index.scss +4 -0
- data/_sass/abstracts/_mixins.scss +80 -0
- data/_sass/{addon/module.scss → abstracts/_placeholders.scss} +22 -55
- data/_sass/{addon/variables.scss → abstracts/_variables.scss} +0 -4
- data/_sass/base/_base.scss +476 -0
- data/_sass/base/_index.scss +4 -0
- data/_sass/base/_reset.scss +41 -0
- data/_sass/{addon/syntax.scss → base/_syntax.scss} +46 -85
- data/_sass/base/_typography.scss +266 -0
- data/_sass/components/_buttons.scss +51 -0
- data/_sass/components/_index.scss +2 -0
- data/_sass/components/_popups.scss +172 -0
- data/_sass/layout/_footer.scss +36 -0
- data/_sass/layout/_index.scss +4 -0
- data/_sass/layout/_panel.scss +70 -0
- data/_sass/layout/_sidebar.scss +258 -0
- data/_sass/layout/_topbar.scss +86 -0
- data/_sass/main.bundle.scss +2 -2
- data/_sass/main.scss +4 -13
- data/_sass/{layout/archives.scss → pages/_archives.scss} +12 -16
- data/_sass/{layout/categories.scss → pages/_categories.scss} +5 -6
- data/_sass/{layout/category-tag.scss → pages/_category-tag.scss} +11 -20
- data/_sass/{layout/home.scss → pages/_home.scss} +54 -70
- data/_sass/pages/_index.scss +7 -0
- data/_sass/{layout/post.scss → pages/_post.scss} +184 -49
- data/_sass/pages/_search.scss +184 -0
- data/_sass/{layout/tags.scss → pages/_tags.scss} +7 -3
- data/_sass/{colors/typography-dark.scss → themes/_dark.scss} +163 -7
- data/_sass/themes/_light.scss +313 -0
- data/_sass/vendors/_bootstrap.scss +5 -0
- data/assets/css/jekyll-theme-chirpy.scss +1 -1
- data/assets/feed.xml +1 -1
- data/assets/js/dist/app.min.js +1 -1
- data/assets/js/dist/categories.min.js +2 -2
- data/assets/js/dist/commons.min.js +2 -2
- data/assets/js/dist/home.min.js +2 -2
- data/assets/js/dist/misc.min.js +2 -2
- data/assets/js/dist/page.min.js +2 -2
- data/assets/js/dist/post.min.js +2 -2
- data/assets/js/dist/sw.min.js +1 -1
- data/assets/js/dist/theme.min.js +4 -0
- metadata +35 -22
- data/_includes/mermaid.html +0 -62
- data/_includes/mode-toggle.html +0 -116
- data/_sass/addon/commons.scss +0 -1542
- data/_sass/colors/syntax-dark.scss +0 -164
- data/_sass/colors/syntax-light.scss +0 -210
- data/_sass/colors/typography-light.scss +0 -112
- data/_sass/dist/bootstrap.css +0 -5
- data/_sass/variables-hook.scss +0 -3
- /data/_includes/{comments.html → comment.html} +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a994290ae896f99b32a77d6d0307aefb631954b3c3ed347e9c1a5b8f3b554760
|
4
|
+
data.tar.gz: 06d9f949b32628e510474bfb56ee571abd5d657ab27f11bc84296545bb1ec21f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c1e29c51383d8a9a9ddbfa46253289e680f6b25b6acc9a83730e72e9be5b094612f1d974b01c765eb036ab7288b520b9e2656ce48d4e613181e91aa937187ccc
|
7
|
+
data.tar.gz: b139a0f3d3c1f04bb24fbe58964d17803632829105d93fc42ea136156da480d221d29970caf652a9dd26dcde8a4537948e4b1aea6a011e42181dbe832b9d48f3
|
data/_data/locales/hu-HU.yml
CHANGED
@@ -14,24 +14,23 @@ tabs:
|
|
14
14
|
categories: Kategóriák
|
15
15
|
tags: Címkék
|
16
16
|
archives: Archívum
|
17
|
-
about:
|
17
|
+
about: Bemutatkozás
|
18
18
|
|
19
19
|
# the text displayed in the search bar & search results
|
20
20
|
search:
|
21
21
|
hint: keresés
|
22
22
|
cancel: Mégse
|
23
|
-
no_results:
|
23
|
+
no_results: Hoppá! Nincs találat a keresésre.
|
24
24
|
|
25
25
|
panel:
|
26
26
|
lastmod: Legutóbb frissítve
|
27
27
|
trending_tags: Népszerű Címkék
|
28
28
|
toc: Tartalom
|
29
|
-
links: Blog linkek
|
30
29
|
|
31
30
|
copyright:
|
32
31
|
# Shown at the bottom of the post
|
33
32
|
license:
|
34
|
-
template: A
|
33
|
+
template: A bejegyzést a szerző :LICENSE_NAME licenc alatt engedélyezte.
|
35
34
|
name: CC BY 4.0
|
36
35
|
link: https://creativecommons.org/licenses/by/4.0/
|
37
36
|
|
@@ -42,7 +41,7 @@ copyright:
|
|
42
41
|
Creative Commons Attribution 4.0 International (CC BY 4.0) licenccel rendelkeznek,
|
43
42
|
hacsak másképp nincs jelezve.
|
44
43
|
|
45
|
-
meta: Készítve :
|
44
|
+
meta: Készítve :THEME témával a :PLATFORM platformra.
|
46
45
|
|
47
46
|
not_found:
|
48
47
|
statement: Sajnáljuk, az URL-t rosszul helyeztük el, vagy valami nem létezőre mutat.
|
@@ -73,7 +72,21 @@ post:
|
|
73
72
|
title: Link másolása
|
74
73
|
succeed: Link sikeresen másolva!
|
75
74
|
|
75
|
+
# Date time format.
|
76
|
+
# See: <http://strftime.net/>, <https://day.js.org/docs/en/display/format>
|
77
|
+
df:
|
78
|
+
post:
|
79
|
+
strftime: "%Y. %B. %e."
|
80
|
+
dayjs: "YYYY. MMMM D."
|
81
|
+
archives:
|
82
|
+
strftime: "%B"
|
83
|
+
dayjs: "MMM"
|
84
|
+
|
76
85
|
# categories page
|
77
86
|
categories:
|
78
|
-
category_measure:
|
79
|
-
|
87
|
+
category_measure:
|
88
|
+
singular: kategória
|
89
|
+
plural: kategória
|
90
|
+
post_measure:
|
91
|
+
singular: bejegyzés
|
92
|
+
plural: bejegyzés
|
data/_data/origin/cors.yml
CHANGED
@@ -20,17 +20,17 @@ webfonts: https://fonts.googleapis.com/css2?family=Lato:wght@300;400&family=Sour
|
|
20
20
|
# Libraries
|
21
21
|
|
22
22
|
toc:
|
23
|
-
css: https://cdn.jsdelivr.net/npm/tocbot@4.
|
24
|
-
js: https://cdn.jsdelivr.net/npm/tocbot@4.
|
23
|
+
css: https://cdn.jsdelivr.net/npm/tocbot@4.32.2/dist/tocbot.min.css
|
24
|
+
js: https://cdn.jsdelivr.net/npm/tocbot@4.32.2/dist/tocbot.min.js
|
25
25
|
|
26
26
|
fontawesome:
|
27
|
-
css: https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.
|
27
|
+
css: https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.7.1/css/all.min.css
|
28
28
|
|
29
29
|
search:
|
30
30
|
js: https://cdn.jsdelivr.net/npm/simple-jekyll-search@1.10.0/dest/simple-jekyll-search.min.js
|
31
31
|
|
32
32
|
mermaid:
|
33
|
-
js: https://cdn.jsdelivr.net/npm/mermaid@11.0
|
33
|
+
js: https://cdn.jsdelivr.net/npm/mermaid@11.4.0/dist/mermaid.min.js
|
34
34
|
|
35
35
|
dayjs:
|
36
36
|
js:
|
@@ -1,7 +1,7 @@
|
|
1
1
|
<!-- Global site tag (gtag.js) - Google Analytics -->
|
2
2
|
<script defer src="https://www.googletagmanager.com/gtag/js?id={{ site.analytics.google.id }}"></script>
|
3
3
|
<script>
|
4
|
-
document.addEventListener('DOMContentLoaded',
|
4
|
+
document.addEventListener('DOMContentLoaded', () => {
|
5
5
|
window.dataLayer = window.dataLayer || [];
|
6
6
|
function gtag() {
|
7
7
|
dataLayer.push(arguments);
|
@@ -1,14 +1,13 @@
|
|
1
1
|
<!-- Matomo -->
|
2
|
-
<script
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
2
|
+
<script>
|
3
|
+
document.addEventListener('DOMContentLoaded', () => {
|
4
|
+
var _paq = (window._paq = window._paq || []);
|
5
|
+
_paq.push(['trackPageView']);
|
6
|
+
_paq.push(['enableLinkTracking']);
|
7
7
|
var u="//{{ site.analytics.matomo.domain }}/";
|
8
8
|
_paq.push(['setTrackerUrl', u+'matomo.php']);
|
9
9
|
_paq.push(['setSiteId', {{ site.analytics.matomo.id }}]);
|
10
10
|
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
|
11
11
|
g.type='text/javascript'; g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
|
12
|
-
})
|
12
|
+
});
|
13
13
|
</script>
|
14
|
-
<!-- End Matomo Code -->
|
@@ -1,38 +1,25 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
<div id="disqus_thread">
|
4
|
-
<p class="text-center text-muted small">Comments powered by <a href="https://disqus.com/">Disqus</a>.</p>
|
5
|
-
</div>
|
6
|
-
|
7
|
-
<script type="text/javascript">
|
1
|
+
<script>
|
8
2
|
var disqus_config = function () {
|
9
3
|
this.page.url = '{{ page.url | absolute_url }}';
|
10
4
|
this.page.identifier = '{{ page.url }}';
|
11
5
|
};
|
12
6
|
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
if (entries[0].isIntersecting) {
|
17
|
-
(function () {
|
18
|
-
var d = document,
|
19
|
-
s = d.createElement('script');
|
20
|
-
s.src = 'https://{{ site.comments.disqus.shortname }}.disqus.com/embed.js';
|
21
|
-
s.setAttribute('data-timestamp', +new Date());
|
22
|
-
(d.head || d.body).appendChild(s);
|
23
|
-
})();
|
24
|
-
|
25
|
-
disqus_observer.disconnect();
|
26
|
-
}
|
27
|
-
},
|
28
|
-
{ threshold: [0] }
|
29
|
-
);
|
7
|
+
function addDisqus() {
|
8
|
+
let disqusThread = document.createElement('div');
|
9
|
+
let paragraph = document.createElement('p');
|
30
10
|
|
31
|
-
|
11
|
+
disqusThread.id = 'disqus_thread';
|
12
|
+
paragraph.className = 'text-center text-muted small';
|
13
|
+
paragraph.innerHTML = 'Comments powered by <a href="https://disqus.com/">Disqus</a>.';
|
14
|
+
disqusThread.appendChild(paragraph);
|
15
|
+
|
16
|
+
const footer = document.querySelector('footer');
|
17
|
+
footer.insertAdjacentElement("beforebegin", disqusThread);
|
18
|
+
}
|
32
19
|
|
33
20
|
{%- comment -%} Auto switch theme {%- endcomment -%}
|
34
|
-
function reloadDisqus() {
|
35
|
-
if (event.source === window && event.data && event.data.
|
21
|
+
function reloadDisqus(event) {
|
22
|
+
if (event.source === window && event.data && event.data.id === Theme.ID) {
|
36
23
|
{%- comment -%} Disqus hasn't been loaded {%- endcomment -%}
|
37
24
|
if (typeof DISQUS === 'undefined') {
|
38
25
|
return;
|
@@ -44,7 +31,27 @@
|
|
44
31
|
}
|
45
32
|
}
|
46
33
|
|
47
|
-
|
48
|
-
|
34
|
+
addDisqus();
|
35
|
+
|
36
|
+
if (Theme.switchable) {
|
37
|
+
addEventListener('message', reloadDisqus);
|
49
38
|
}
|
39
|
+
|
40
|
+
{%- comment -%} Lazy loading {%- endcomment -%}
|
41
|
+
var disqusObserver = new IntersectionObserver(
|
42
|
+
function (entries) {
|
43
|
+
if (entries[0].isIntersecting) {
|
44
|
+
var d = document,
|
45
|
+
s = d.createElement('script');
|
46
|
+
s.src = 'https://{{ site.comments.disqus.shortname }}.disqus.com/embed.js';
|
47
|
+
s.setAttribute('data-timestamp', +new Date());
|
48
|
+
(d.head || d.body).appendChild(s);
|
49
|
+
|
50
|
+
disqusObserver.disconnect();
|
51
|
+
}
|
52
|
+
},
|
53
|
+
{ threshold: [0] }
|
54
|
+
);
|
55
|
+
|
56
|
+
disqusObserver.observe(document.getElementById('disqus_thread'));
|
50
57
|
</script>
|
@@ -1,21 +1,8 @@
|
|
1
1
|
<!-- https://giscus.app/ -->
|
2
|
-
<script
|
2
|
+
<script>
|
3
3
|
(function () {
|
4
|
-
const
|
5
|
-
const
|
6
|
-
const darkTheme = 'dark_dimmed';
|
7
|
-
|
8
|
-
let initTheme = lightTheme;
|
9
|
-
const html = document.documentElement;
|
10
|
-
|
11
|
-
if (
|
12
|
-
(html.hasAttribute('data-mode') &&
|
13
|
-
html.getAttribute('data-mode') === 'dark') ||
|
14
|
-
(!html.hasAttribute('data-mode') &&
|
15
|
-
window.matchMedia('(prefers-color-scheme: dark)').matches)
|
16
|
-
) {
|
17
|
-
initTheme = darkTheme;
|
18
|
-
}
|
4
|
+
const themeMapper = Theme.getThemeMapper('light', 'dark_dimmed');
|
5
|
+
const initTheme = themeMapper[Theme.visualState];
|
19
6
|
|
20
7
|
let lang = '{{ site.comments.giscus.lang | default: lang }}';
|
21
8
|
{%- comment -%} https://github.com/giscus/giscus/tree/main/locales {%- endcomment -%}
|
@@ -41,30 +28,27 @@
|
|
41
28
|
async: ''
|
42
29
|
};
|
43
30
|
|
44
|
-
let
|
31
|
+
let giscusNode = document.createElement('script');
|
45
32
|
Object.entries(giscusAttributes).forEach(([key, value]) =>
|
46
|
-
|
33
|
+
giscusNode.setAttribute(key, value)
|
47
34
|
);
|
48
|
-
|
35
|
+
|
36
|
+
const $footer = document.querySelector('footer');
|
37
|
+
$footer.insertAdjacentElement("beforebegin", giscusNode);
|
49
38
|
|
50
39
|
addEventListener('message', (event) => {
|
51
|
-
if (
|
52
|
-
|
53
|
-
event.data &&
|
54
|
-
event.data.direction === ModeToggle.ID
|
55
|
-
) {
|
56
|
-
{%- comment -%} global theme mode changed {%- endcomment -%}
|
57
|
-
const mode = event.data.message;
|
58
|
-
const theme = mode === ModeToggle.DARK_MODE ? darkTheme : lightTheme;
|
40
|
+
if (event.source === window && event.data && event.data.id === Theme.ID) {
|
41
|
+
const newTheme = themeMapper[Theme.visualState];
|
59
42
|
|
60
43
|
const message = {
|
61
44
|
setConfig: {
|
62
|
-
theme:
|
45
|
+
theme: newTheme
|
63
46
|
}
|
64
47
|
};
|
65
48
|
|
66
|
-
const giscus =
|
67
|
-
|
49
|
+
const giscus =
|
50
|
+
document.getElementsByClassName('giscus-frame')[0].contentWindow;
|
51
|
+
giscus.postMessage({ giscus: message }, 'https://giscus.app');
|
68
52
|
}
|
69
53
|
});
|
70
54
|
})();
|
@@ -1,49 +1,38 @@
|
|
1
1
|
<!-- https://utteranc.es/ -->
|
2
|
-
<script
|
3
|
-
src="https://utteranc.es/client.js"
|
4
|
-
repo="{{ site.comments.utterances.repo }}"
|
5
|
-
issue-term="{{ site.comments.utterances.issue_term }}"
|
6
|
-
crossorigin="anonymous"
|
7
|
-
async
|
8
|
-
></script>
|
9
|
-
|
10
|
-
<script type="text/javascript">
|
2
|
+
<script>
|
11
3
|
(function () {
|
12
4
|
const origin = 'https://utteranc.es';
|
13
|
-
const
|
14
|
-
const
|
15
|
-
|
16
|
-
|
5
|
+
const themeMapper = Theme.getThemeMapper('github-light', 'github-dark');
|
6
|
+
const initTheme = themeMapper[Theme.visualState];
|
7
|
+
|
8
|
+
let script = document.createElement('script');
|
9
|
+
script.src = 'https://utteranc.es/client.js';
|
10
|
+
script.setAttribute('repo', '{{ site.comments.utterances.repo }}');
|
11
|
+
script.setAttribute('issue-term', '{{ site.comments.utterances.issue_term }}');
|
12
|
+
script.setAttribute('theme', initTheme);
|
13
|
+
script.crossOrigin = 'anonymous';
|
14
|
+
script.async = true;
|
17
15
|
|
18
|
-
|
19
|
-
|
20
|
-
(!html.hasAttribute('data-mode') && window.matchMedia('(prefers-color-scheme: dark)').matches)
|
21
|
-
) {
|
22
|
-
initTheme = darkTheme;
|
23
|
-
}
|
16
|
+
const $footer = document.querySelector('footer');
|
17
|
+
$footer.insertAdjacentElement('beforebegin', script);
|
24
18
|
|
25
19
|
addEventListener('message', (event) => {
|
26
|
-
let
|
20
|
+
let newTheme;
|
27
21
|
|
28
|
-
{%- comment -%}
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
{%- comment -%} global theme mode changed {%- endcomment -%}
|
34
|
-
const mode = event.data.message;
|
35
|
-
theme = mode === ModeToggle.DARK_MODE ? darkTheme : lightTheme;
|
36
|
-
} else {
|
37
|
-
return;
|
38
|
-
}
|
22
|
+
{%- comment -%}
|
23
|
+
Credit to <https://github.com/utterance/utterances/issues/170#issuecomment-594036347>
|
24
|
+
{%- endcomment -%}
|
25
|
+
if (event.source === window && event.data && event.data.id === Theme.ID) {
|
26
|
+
newTheme = themeMapper[Theme.visualState];
|
39
27
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
28
|
+
const message = {
|
29
|
+
type: 'set-theme',
|
30
|
+
theme: newTheme
|
31
|
+
};
|
44
32
|
|
45
|
-
|
46
|
-
|
33
|
+
const utterances = document.querySelector('.utterances-frame').contentWindow;
|
34
|
+
utterances.postMessage(message, origin);
|
35
|
+
}
|
47
36
|
});
|
48
37
|
})();
|
49
38
|
</script>
|
data/_includes/head.html
CHANGED
@@ -70,7 +70,7 @@
|
|
70
70
|
|
71
71
|
<!-- Bootstrap -->
|
72
72
|
{% unless jekyll.environment == 'production' %}
|
73
|
-
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.
|
73
|
+
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css">
|
74
74
|
{% endunless %}
|
75
75
|
|
76
76
|
<!-- Theme style -->
|
@@ -97,11 +97,30 @@
|
|
97
97
|
<link rel="stylesheet" href="{{ site.data.origin[type].glightbox.css | relative_url }}">
|
98
98
|
{% endif %}
|
99
99
|
|
100
|
-
<!--
|
100
|
+
<!-- Scripts -->
|
101
101
|
|
102
|
-
{
|
103
|
-
|
104
|
-
{%
|
102
|
+
<script src="{{ '/assets/js/dist/theme.min.js' | relative_url }}"></script>
|
103
|
+
|
104
|
+
{% include js-selector.html lang=lang %}
|
105
|
+
|
106
|
+
{% if jekyll.environment == 'production' %}
|
107
|
+
<!-- PWA -->
|
108
|
+
{% if site.pwa.enabled %}
|
109
|
+
<script
|
110
|
+
defer
|
111
|
+
src="{{ '/app.min.js' | relative_url }}?baseurl={{ site.baseurl | default: '' }}®ister={{ site.pwa.cache.enabled }}"
|
112
|
+
></script>
|
113
|
+
{% endif %}
|
114
|
+
|
115
|
+
<!-- Web Analytics -->
|
116
|
+
{% for analytics in site.analytics %}
|
117
|
+
{% capture str %}{{ analytics }}{% endcapture %}
|
118
|
+
{% assign platform = str | split: '{' | first %}
|
119
|
+
{% if site.analytics[platform].id and site.analytics[platform].id != empty %}
|
120
|
+
{% include analytics/{{ platform }}.html %}
|
121
|
+
{% endif %}
|
122
|
+
{% endfor %}
|
123
|
+
{% endif %}
|
105
124
|
|
106
125
|
{% include metadata-hook.html %}
|
107
126
|
</head>
|
data/_includes/js-selector.html
CHANGED
@@ -62,12 +62,12 @@
|
|
62
62
|
|
63
63
|
{% capture script %}/assets/js/dist/{{ js }}.min.js{% endcapture %}
|
64
64
|
|
65
|
-
<script src="{{ script | relative_url }}"></script>
|
65
|
+
<script defer src="{{ script | relative_url }}"></script>
|
66
66
|
|
67
67
|
{% if page.math %}
|
68
68
|
<!-- MathJax -->
|
69
|
-
<script src="{{ '/assets/js/data/mathjax.js' | relative_url }}"></script>
|
70
|
-
<script src="https://cdnjs.cloudflare.com/polyfill/v3/polyfill.min.js?features=es6"></script>
|
69
|
+
<script async src="{{ '/assets/js/data/mathjax.js' | relative_url }}"></script>
|
70
|
+
<script async src="https://cdnjs.cloudflare.com/polyfill/v3/polyfill.min.js?features=es6"></script>
|
71
71
|
<script id="MathJax-script" async src="{{ site.data.origin[type].mathjax.js | relative_url }}"></script>
|
72
72
|
{% endif %}
|
73
73
|
|
@@ -84,26 +84,3 @@
|
|
84
84
|
{% endcase %}
|
85
85
|
{% endif %}
|
86
86
|
{% endif %}
|
87
|
-
|
88
|
-
{% if page.mermaid %}
|
89
|
-
{% include mermaid.html %}
|
90
|
-
{% endif %}
|
91
|
-
|
92
|
-
{% if jekyll.environment == 'production' %}
|
93
|
-
<!-- PWA -->
|
94
|
-
{% if site.pwa.enabled %}
|
95
|
-
<script
|
96
|
-
defer
|
97
|
-
src="{{ 'app.min.js' | relative_url }}?baseurl={{ site.baseurl | default: '' }}®ister={{ site.pwa.cache.enabled }}"
|
98
|
-
></script>
|
99
|
-
{% endif %}
|
100
|
-
|
101
|
-
<!-- Web Analytics -->
|
102
|
-
{% for analytics in site.analytics %}
|
103
|
-
{% capture str %}{{ analytics }}{% endcapture %}
|
104
|
-
{% assign type = str | split: '{' | first %}
|
105
|
-
{% if site.analytics[type].id and site.analytics[type].id != empty %}
|
106
|
-
{% include analytics/{{ type }}.html %}
|
107
|
-
{% endif %}
|
108
|
-
{% endfor %}
|
109
|
-
{% endif %}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
{% assign urls = include.urls | split: ',' %}
|
2
2
|
|
3
|
-
{% assign combined_urls =
|
3
|
+
{% assign combined_urls = null %}
|
4
4
|
|
5
5
|
{% assign domain = 'https://cdn.jsdelivr.net/' %}
|
6
6
|
|
@@ -15,12 +15,12 @@
|
|
15
15
|
{% endif %}
|
16
16
|
|
17
17
|
{% elsif url contains '//' %}
|
18
|
-
<script src="{{ url }}"></script>
|
18
|
+
<script defer src="{{ url }}"></script>
|
19
19
|
{% else %}
|
20
|
-
<script src="{{ url | relative_url }}"></script>
|
20
|
+
<script defer src="{{ url | relative_url }}"></script>
|
21
21
|
{% endif %}
|
22
22
|
{% endfor %}
|
23
23
|
|
24
24
|
{% if combined_urls %}
|
25
|
-
<script src="{{ combined_urls }}"></script>
|
25
|
+
<script defer src="{{ combined_urls }}"></script>
|
26
26
|
{% endif %}
|
@@ -1,19 +1,21 @@
|
|
1
1
|
<!-- Display GoatCounter pageviews -->
|
2
2
|
<script>
|
3
|
-
|
3
|
+
document.addEventListener('DOMContentLoaded', () => {
|
4
|
+
const pv = document.getElementById('pageviews');
|
4
5
|
|
5
|
-
|
6
|
-
|
7
|
-
|
6
|
+
if (pv !== null) {
|
7
|
+
const uri = location.pathname.replace(/\/$/, '');
|
8
|
+
const url = `https://{{ site.analytics.goatcounter.id }}.goatcounter.com/counter/${encodeURIComponent(uri)}.json`;
|
8
9
|
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
17
|
-
|
18
|
-
|
10
|
+
fetch(url)
|
11
|
+
.then((response) => response.json())
|
12
|
+
.then((data) => {
|
13
|
+
const count = data.count.replace(/\s/g, '');
|
14
|
+
pv.innerText = new Intl.NumberFormat().format(count);
|
15
|
+
})
|
16
|
+
.catch((error) => {
|
17
|
+
pv.innerText = '1';
|
18
|
+
});
|
19
|
+
}
|
20
|
+
});
|
19
21
|
</script>
|
@@ -19,29 +19,31 @@
|
|
19
19
|
{% capture not_found %}<p class="mt-5">{{ site.data.locales[include.lang].search.no_results }}</p>{% endcapture %}
|
20
20
|
|
21
21
|
<script>
|
22
|
-
{
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
if (
|
32
|
-
|
33
|
-
|
34
|
-
|
22
|
+
{% comment %} Note: dependent library will be loaded in `js-selector.html` {% endcomment %}
|
23
|
+
document.addEventListener('DOMContentLoaded', () => {
|
24
|
+
SimpleJekyllSearch({
|
25
|
+
searchInput: document.getElementById('search-input'),
|
26
|
+
resultsContainer: document.getElementById('search-results'),
|
27
|
+
json: '{{ '/assets/js/data/search.json' | relative_url }}',
|
28
|
+
searchResultTemplate: '{{ result_elem | strip_newlines }}',
|
29
|
+
noResultsText: '{{ not_found }}',
|
30
|
+
templateMiddleware: function(prop, value, template) {
|
31
|
+
if (prop === 'categories') {
|
32
|
+
if (value === '') {
|
33
|
+
return `${value}`;
|
34
|
+
} else {
|
35
|
+
return `<div class="me-sm-4"><i class="far fa-folder fa-fw"></i>${value}</div>`;
|
36
|
+
}
|
35
37
|
}
|
36
|
-
}
|
37
38
|
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
39
|
+
if (prop === 'tags') {
|
40
|
+
if (value === '') {
|
41
|
+
return `${value}`;
|
42
|
+
} else {
|
43
|
+
return `<div><i class="fa fa-tag fa-fw"></i>${value}</div>`;
|
44
|
+
}
|
43
45
|
}
|
44
46
|
}
|
45
|
-
}
|
47
|
+
});
|
46
48
|
});
|
47
49
|
</script>
|
data/_includes/sidebar.html
CHANGED
@@ -11,9 +11,7 @@
|
|
11
11
|
{%- endif -%}
|
12
12
|
</a>
|
13
13
|
|
14
|
-
<
|
15
|
-
<a href="{{ '/' | relative_url }}">{{ site.title }}</a>
|
16
|
-
</h1>
|
14
|
+
<a class="site-title d-block" href="{{ '/' | relative_url }}">{{ site.title }}</a>
|
17
15
|
<p class="site-subtitle fst-italic mb-0">{{ site.tagline }}</p>
|
18
16
|
</header>
|
19
17
|
<!-- .profile-wrapper -->
|
@@ -0,0 +1,10 @@
|
|
1
|
+
{% comment %}
|
2
|
+
Determine TOC state and return it through variable "enable_toc"
|
3
|
+
{% endcomment %}
|
4
|
+
|
5
|
+
{% assign enable_toc = false %}
|
6
|
+
{% if site.toc and page.toc %}
|
7
|
+
{% if page.content contains '<h2' or page.content contains '<h3' %}
|
8
|
+
{% assign enable_toc = true %}
|
9
|
+
{% endif %}
|
10
|
+
{% endif %}
|
data/_includes/toc.html
CHANGED
@@ -1,13 +1,9 @@
|
|
1
|
-
{%
|
2
|
-
{% if site.toc and page.toc %}
|
3
|
-
{% if page.content contains '<h2' or page.content contains '<h3' %}
|
4
|
-
{% assign enable_toc = true %}
|
5
|
-
{% endif %}
|
6
|
-
{% endif %}
|
1
|
+
{% include toc-status.html %}
|
7
2
|
|
8
3
|
{% if enable_toc %}
|
9
|
-
<
|
10
|
-
|
4
|
+
<div class="toc-border-cover z-3"></div>
|
5
|
+
<section id="toc-wrapper" class="invisible position-sticky ps-0 pe-4 pb-4">
|
6
|
+
<h2 class="panel-heading ps-3 pb-2 mb-0">{{- site.data.locales[include.lang].panel.toc -}}</h2>
|
11
7
|
<nav id="toc"></nav>
|
12
8
|
</section>
|
13
9
|
{% endif %}
|
data/_layouts/default.html
CHANGED
@@ -33,7 +33,7 @@ layout: compress
|
|
33
33
|
</main>
|
34
34
|
|
35
35
|
<!-- panel -->
|
36
|
-
<aside aria-label="Panel" id="panel-wrapper" class="col-xl-3 ps-2
|
36
|
+
<aside aria-label="Panel" id="panel-wrapper" class="col-xl-3 ps-2 text-muted">
|
37
37
|
<div class="access">
|
38
38
|
{% include_cached update-list.html lang=lang %}
|
39
39
|
{% include_cached trending-tags.html lang=lang %}
|
@@ -68,14 +68,18 @@ layout: compress
|
|
68
68
|
</aside>
|
69
69
|
</div>
|
70
70
|
|
71
|
-
<div id="mask"></div>
|
71
|
+
<div id="mask" class="d-none position-fixed w-100 h-100 z-1"></div>
|
72
72
|
|
73
73
|
{% if site.pwa.enabled %}
|
74
74
|
{% include_cached notification.html lang=lang %}
|
75
75
|
{% endif %}
|
76
76
|
|
77
|
-
<!--
|
78
|
-
|
77
|
+
<!-- Embedded scripts -->
|
78
|
+
|
79
|
+
{% for _include in layout.script_includes %}
|
80
|
+
{% assign _include_path = _include | append: '.html' %}
|
81
|
+
{% include {{ _include_path }} %}
|
82
|
+
{% endfor %}
|
79
83
|
|
80
84
|
{% include_cached search-loader.html lang=lang %}
|
81
85
|
</body>
|