jekyll-theme-chirpy 6.2.2 → 6.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +34 -35
- data/_data/locales/de-DE.yml +8 -1
- data/_data/locales/en.yml +1 -1
- data/_data/locales/ru-RU.yml +28 -18
- data/_data/origin/basic.yml +3 -5
- data/_data/origin/cors.yml +12 -14
- data/_includes/comments/disqus.html +1 -1
- data/_includes/comments/giscus.html +1 -0
- data/_includes/comments/utterances.html +22 -23
- data/_includes/embed/twitch.html +7 -3
- data/_includes/embed/youtube.html +5 -2
- data/_includes/head.html +4 -0
- data/_includes/js-selector.html +2 -2
- data/_includes/post-sharing.html +27 -12
- data/_includes/refactor-content.html +59 -79
- data/_includes/related-posts.html +2 -2
- data/_includes/toc.html +1 -1
- data/_layouts/default.html +15 -23
- data/_layouts/home.html +50 -43
- data/_layouts/page.html +3 -9
- data/_layouts/post.html +102 -102
- data/_sass/addon/commons.scss +66 -75
- data/_sass/addon/module.scss +19 -1
- data/_sass/addon/syntax.scss +2 -2
- data/_sass/addon/variables.scss +3 -2
- data/_sass/colors/syntax-dark.scss +26 -0
- data/_sass/colors/syntax-light.scss +35 -0
- data/_sass/colors/typography-dark.scss +1 -0
- data/_sass/colors/typography-light.scss +3 -1
- data/_sass/layout/home.scss +8 -21
- data/_sass/layout/post.scss +40 -95
- 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/pwa/sw.js +1 -1
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 37820e3e111cbdf11fa68f85cdda700105a567fe6c991de6dfaa4fda3944b2b1
|
4
|
+
data.tar.gz: a2918e424cef8dcf29b01e6b7aabc12aa33732d9727e063cbea63789531c393c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 154ecf741a74587402e58bf869011998a80003606a5c8e7dba337ab10160cecdc08ecc96387eb5d32aac58fbaabfd9bca60517e906b20b7b84494837b6f1b2e3
|
7
|
+
data.tar.gz: 59af752aea2a3c7b53758ac4ca840234573430e1f49f4bda59507ff699346b06c58c1b56e558f0b0dd3b18be660fcedd9d51bea6a485039152101e1379e3157d
|
data/README.md
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
|
3
3
|
# Chirpy Jekyll Theme
|
4
4
|
|
5
|
-
A minimal, responsive and feature-rich Jekyll theme for technical writing.
|
5
|
+
A minimal, responsive, and feature-rich Jekyll theme for technical writing.
|
6
6
|
|
7
7
|
[![Gem Version](https://img.shields.io/gem/v/jekyll-theme-chirpy?color=brightgreen)][gem]
|
8
8
|
[![CI](https://github.com/cotes2020/jekyll-theme-chirpy/actions/workflows/ci.yml/badge.svg?branch=master&event=push)][ci]
|
@@ -19,46 +19,45 @@
|
|
19
19
|
## Features
|
20
20
|
|
21
21
|
<details>
|
22
|
-
<summary>
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
- SEO & Performance Optimization
|
45
|
-
|
46
|
-
</p>
|
22
|
+
<summary>Click to expand/close details</summary>
|
23
|
+
|
24
|
+
|
25
|
+
- Dark / Light Theme Mode
|
26
|
+
- Localized UI language
|
27
|
+
- Pinned Posts on Home Page
|
28
|
+
- Hierarchical Categories
|
29
|
+
- Trending Tags
|
30
|
+
- Table of Contents
|
31
|
+
- Last Modified Date
|
32
|
+
- Syntax Highlighting
|
33
|
+
- Mathematical Expressions
|
34
|
+
- Mermaid Diagrams & Flowcharts
|
35
|
+
- Dark / Light Mode Images
|
36
|
+
- Embed Videos
|
37
|
+
- Disqus / Giscus / Utterances Comments
|
38
|
+
- Built-in Search
|
39
|
+
- Atom Feeds
|
40
|
+
- PWA
|
41
|
+
- Google Analytics
|
42
|
+
- SEO & Performance Optimization
|
43
|
+
|
47
44
|
</details>
|
48
45
|
|
49
46
|
## Documentation
|
50
47
|
|
51
|
-
To
|
48
|
+
To learn how to use, develop, and upgrade the project, please refer to the [Wiki][wiki].
|
52
49
|
|
53
50
|
## Contributing
|
54
51
|
|
55
|
-
Contributions (
|
52
|
+
Contributions (_pull requests_, _issues_, and _discussions_) are what make the open-source community such an amazing place
|
53
|
+
to learn, inspire, and create. Any contributions you make are greatly appreciated.
|
54
|
+
For details, see the "[Contributing Guidelines][contribute-guide]".
|
56
55
|
|
57
56
|
## Credits
|
58
57
|
|
59
|
-
This
|
60
|
-
[Bootstrap][bootstrap], [Font Awesome][icons] and some other [wonderful tools][lib].
|
61
|
-
The avatar and favicon design
|
58
|
+
This project was built primarily with the [Jekyll][jekyllrb] ecosystem,
|
59
|
+
[Bootstrap][bootstrap], [Font Awesome][icons], and some other [wonderful tools][lib].
|
60
|
+
The avatar and favicon design from [Clipart Max][image].
|
62
61
|
|
63
62
|
Many thanks to the [contributors][contributors] who participated in the development
|
64
63
|
and to the folks who reported bugs or shared ideas.
|
@@ -67,15 +66,15 @@ Last but not least, thanks to [JetBrains][jetbrains] for providing the _Open Sou
|
|
67
66
|
|
68
67
|
## Sponsoring
|
69
68
|
|
70
|
-
If you
|
69
|
+
If you like this project or have built something through it, please consider sponsoring it, and your support would be greatly appreciated.
|
71
70
|
|
72
71
|
[![Ko-fi](https://img.shields.io/badge/Support_Me_on_Ko--fi-ff5e5b?logo=ko-fi&logoColor=white)][ko-fi]
|
73
|
-
[![Wechat Pay](https://img.shields.io/badge/
|
74
|
-
[![Alipay](https://img.shields.io/badge/
|
72
|
+
[![Wechat Pay](https://img.shields.io/badge/Support_Me_on_WeChat-brightgreen?logo=wechat&logoColor=white)][donation]
|
73
|
+
[![Alipay](https://img.shields.io/badge/Support_Me_on_Alipay-blue?logo=alipay&logoColor=white)][donation]
|
75
74
|
|
76
75
|
## License
|
77
76
|
|
78
|
-
This
|
77
|
+
This project is published under [MIT License][license].
|
79
78
|
|
80
79
|
[gem]: https://rubygems.org/gems/jekyll-theme-chirpy
|
81
80
|
[ci]: https://github.com/cotes2020/jekyll-theme-chirpy/actions/workflows/ci.yml?query=event%3Apush+branch%3Amaster
|
data/_data/locales/de-DE.yml
CHANGED
@@ -58,7 +58,7 @@ post:
|
|
58
58
|
pageview_measure: Aufrufe
|
59
59
|
read_time:
|
60
60
|
unit: Minuten
|
61
|
-
prompt:
|
61
|
+
prompt: Lesezeit
|
62
62
|
relate_posts: Weiterlesen
|
63
63
|
share: Teilen
|
64
64
|
button:
|
@@ -70,6 +70,13 @@ post:
|
|
70
70
|
title: Link kopieren
|
71
71
|
succeed: Link erfolgreich kopiert!
|
72
72
|
|
73
|
+
# Date time format.
|
74
|
+
# See: <http://strftime.net/>, <https://day.js.org/docs/en/display/format>
|
75
|
+
df:
|
76
|
+
post:
|
77
|
+
strftime: "%d.%m.%Y"
|
78
|
+
dayjs: "DD.MM.YYYY"
|
79
|
+
|
73
80
|
# categories page
|
74
81
|
categories:
|
75
82
|
category_measure:
|
data/_data/locales/en.yml
CHANGED
@@ -40,7 +40,7 @@ copyright:
|
|
40
40
|
Except where otherwise noted, the blog posts on this site are licensed
|
41
41
|
under the Creative Commons Attribution 4.0 International (CC BY 4.0) License by the author.
|
42
42
|
|
43
|
-
meta: Using the :
|
43
|
+
meta: Using the :THEME theme for :PLATFORM.
|
44
44
|
|
45
45
|
not_found:
|
46
46
|
statment: Sorry, we've misplaced that URL or it's pointing to something that doesn't exist.
|
data/_data/locales/ru-RU.yml
CHANGED
@@ -3,14 +3,14 @@
|
|
3
3
|
# ----- Commons label -----
|
4
4
|
|
5
5
|
layout:
|
6
|
-
post:
|
6
|
+
post: Пост
|
7
7
|
category: Категория
|
8
8
|
tag: Тег
|
9
9
|
|
10
10
|
# The tabs of sidebar
|
11
11
|
tabs:
|
12
12
|
# format: <filename_without_extension>: <value>
|
13
|
-
home:
|
13
|
+
home: Главная
|
14
14
|
categories: Категории
|
15
15
|
tags: Теги
|
16
16
|
archives: Архив
|
@@ -19,8 +19,8 @@ tabs:
|
|
19
19
|
# the text displayed in the search bar & search results
|
20
20
|
search:
|
21
21
|
hint: поиск
|
22
|
-
cancel:
|
23
|
-
no_results:
|
22
|
+
cancel: Отмена
|
23
|
+
no_results: Упс! Ничего не найдено.
|
24
24
|
|
25
25
|
panel:
|
26
26
|
lastmod: Недавно обновлено
|
@@ -30,48 +30,58 @@ panel:
|
|
30
30
|
copyright:
|
31
31
|
# Shown at the bottom of the post
|
32
32
|
license:
|
33
|
-
template:
|
33
|
+
template: Авторский пост защищен лицензией :LICENSE_NAME.
|
34
34
|
name: CC BY 4.0
|
35
35
|
link: https://creativecommons.org/licenses/by/4.0/
|
36
36
|
|
37
37
|
# Displayed in the footer
|
38
38
|
brief: Некоторые права защищены.
|
39
39
|
verbose: >-
|
40
|
-
|
41
|
-
если в тексте публикации не указано иное.
|
40
|
+
Если не указано иное, авторские посты на этом сайте защищены лицензией Creative Commons Attribution 4.0 International (CC BY 4.0).
|
42
41
|
|
43
|
-
meta:
|
42
|
+
meta: Использует тему :THEME для :PLATFORM
|
44
43
|
|
45
44
|
not_found:
|
46
|
-
statment: Извините,
|
45
|
+
statment: Извините, мы перепутали URL-адрес или он указывает на что-то несуществующее.
|
47
46
|
|
48
47
|
notification:
|
49
48
|
update_found: Доступна новая версия контента.
|
50
|
-
update:
|
49
|
+
update: Обновить
|
51
50
|
|
52
51
|
# ----- Posts related labels -----
|
53
52
|
|
54
53
|
post:
|
55
54
|
written_by: Автор
|
56
|
-
posted:
|
55
|
+
posted: Опубликовано
|
57
56
|
updated: Обновлено
|
58
57
|
words: слов
|
59
58
|
pageview_measure: просмотров
|
60
59
|
read_time:
|
61
|
-
unit:
|
60
|
+
unit: мин.
|
62
61
|
prompt: чтения
|
63
|
-
relate_posts:
|
62
|
+
relate_posts: Похожие посты
|
64
63
|
share: Поделиться
|
65
64
|
button:
|
66
|
-
next:
|
67
|
-
previous:
|
65
|
+
next: Следующий пост
|
66
|
+
previous: Предыдущий пост
|
68
67
|
copy_code:
|
69
|
-
succeed:
|
68
|
+
succeed: Скопировано!
|
70
69
|
share_link:
|
71
70
|
title: Скопировать ссылку
|
72
71
|
succeed: Ссылка успешно скопирована!
|
73
72
|
|
73
|
+
# Date time format.
|
74
|
+
# See: <http://strftime.net/>, <https://day.js.org/docs/en/display/format>
|
75
|
+
df:
|
76
|
+
post:
|
77
|
+
strftime: "%d.%m.%Y"
|
78
|
+
dayjs: "DD.MM.YYYY"
|
79
|
+
|
74
80
|
# categories page
|
75
81
|
categories:
|
76
|
-
category_measure:
|
77
|
-
|
82
|
+
category_measure:
|
83
|
+
singular: категория
|
84
|
+
plural: категории
|
85
|
+
post_measure:
|
86
|
+
singular: пост
|
87
|
+
plural: посты
|
data/_data/origin/basic.yml
CHANGED
@@ -35,14 +35,12 @@ magnific-popup:
|
|
35
35
|
css: /assets/lib/magnific-popup/magnific-popup.css
|
36
36
|
js: /assets/lib/magnific-popup/jquery.magnific-popup.min.js
|
37
37
|
|
38
|
-
|
39
|
-
|
38
|
+
lazy-polyfill:
|
39
|
+
css: /assets/lib/loading-attribute-polyfill/loading-attribute-polyfill.min.css
|
40
|
+
js: /assets/lib/loading-attribute-polyfill/loading-attribute-polyfill.umd.min.js
|
40
41
|
|
41
42
|
clipboard:
|
42
43
|
js: /assets/lib/clipboard/clipboard.min.js
|
43
44
|
|
44
|
-
polyfill:
|
45
|
-
js: /assets/lib/polyfill-v3-es6/polyfill.min.js
|
46
|
-
|
47
45
|
mathjax:
|
48
46
|
js: /assets/lib/mathjax/tex-chtml.js
|
data/_data/origin/cors.yml
CHANGED
@@ -19,12 +19,12 @@ jquery:
|
|
19
19
|
js: https://cdn.jsdelivr.net/npm/jquery@3.7.1/dist/jquery.min.js
|
20
20
|
|
21
21
|
bootstrap:
|
22
|
-
css: https://cdn.jsdelivr.net/npm/bootstrap@5.3.
|
23
|
-
js: https://cdn.jsdelivr.net/npm/bootstrap@5.3.
|
22
|
+
css: https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css
|
23
|
+
js: https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/js/bootstrap.bundle.min.js
|
24
24
|
|
25
25
|
toc:
|
26
|
-
css: https://cdn.jsdelivr.net/npm/tocbot@4.21.
|
27
|
-
js: https://cdn.jsdelivr.net/npm/tocbot@4.21.
|
26
|
+
css: https://cdn.jsdelivr.net/npm/tocbot@4.21.3/dist/tocbot.min.css
|
27
|
+
js: https://cdn.jsdelivr.net/npm/tocbot@4.21.3/dist/tocbot.min.js
|
28
28
|
|
29
29
|
fontawesome:
|
30
30
|
css: https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.4.2/css/all.min.css
|
@@ -33,27 +33,25 @@ search:
|
|
33
33
|
js: https://cdn.jsdelivr.net/npm/simple-jekyll-search@1.10.0/dest/simple-jekyll-search.min.js
|
34
34
|
|
35
35
|
mermaid:
|
36
|
-
js: https://cdn.jsdelivr.net/npm/mermaid@10.
|
36
|
+
js: https://cdn.jsdelivr.net/npm/mermaid@10.6.0/dist/mermaid.min.js
|
37
37
|
|
38
38
|
dayjs:
|
39
39
|
js:
|
40
|
-
common: https://cdn.jsdelivr.net/npm/dayjs@1.11.
|
41
|
-
locale: https://cdn.jsdelivr.net/npm/dayjs@1.11.
|
42
|
-
relativeTime: https://cdn.jsdelivr.net/npm/dayjs@1.11.
|
43
|
-
localizedFormat: https://cdn.jsdelivr.net/npm/dayjs@1.11.
|
40
|
+
common: https://cdn.jsdelivr.net/npm/dayjs@1.11.10/dayjs.min.js
|
41
|
+
locale: https://cdn.jsdelivr.net/npm/dayjs@1.11.10/locale/:LOCALE.min.js
|
42
|
+
relativeTime: https://cdn.jsdelivr.net/npm/dayjs@1.11.10/plugin/relativeTime.min.js
|
43
|
+
localizedFormat: https://cdn.jsdelivr.net/npm/dayjs@1.11.10/plugin/localizedFormat.min.js
|
44
44
|
|
45
45
|
magnific-popup:
|
46
46
|
css: https://cdn.jsdelivr.net/npm/magnific-popup@1.1.0/dist/magnific-popup.min.css
|
47
47
|
js: https://cdn.jsdelivr.net/npm/magnific-popup@1.1.0/dist/jquery.magnific-popup.min.js
|
48
48
|
|
49
|
-
|
50
|
-
|
49
|
+
lazy-polyfill:
|
50
|
+
css: https://cdn.jsdelivr.net/npm/loading-attribute-polyfill@2.1.1/dist/loading-attribute-polyfill.min.css
|
51
|
+
js: https://cdn.jsdelivr.net/npm/loading-attribute-polyfill@2.1.1/dist/loading-attribute-polyfill.umd.min.js
|
51
52
|
|
52
53
|
clipboard:
|
53
54
|
js: https://cdn.jsdelivr.net/npm/clipboard@2.0.11/dist/clipboard.min.js
|
54
55
|
|
55
|
-
polyfill:
|
56
|
-
js: https://polyfill.io/v3/polyfill.min.js?features=es6
|
57
|
-
|
58
56
|
mathjax:
|
59
57
|
js: https://cdn.jsdelivr.net/npm/mathjax@3.2.2/es5/tex-chtml.js
|
@@ -1,51 +1,50 @@
|
|
1
1
|
<!-- https://utteranc.es/ -->
|
2
|
-
<script
|
3
|
-
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
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>
|
8
9
|
|
9
10
|
<script type="text/javascript">
|
10
|
-
|
11
|
-
const origin =
|
12
|
-
const iframe =
|
13
|
-
const lightTheme =
|
14
|
-
const darkTheme =
|
11
|
+
(function () {
|
12
|
+
const origin = 'https://utteranc.es';
|
13
|
+
const iframe = 'iframe.utterances-frame';
|
14
|
+
const lightTheme = 'github-light';
|
15
|
+
const darkTheme = 'github-dark';
|
15
16
|
let initTheme = lightTheme;
|
17
|
+
const html = document.documentElement;
|
16
18
|
|
17
|
-
if (
|
18
|
-
|
19
|
-
|
19
|
+
if (
|
20
|
+
(html.hasAttribute('data-mode') && html.getAttribute('data-mode') === 'dark') ||
|
21
|
+
(!html.hasAttribute('data-mode') && window.matchMedia('(prefers-color-scheme: dark)').matches)
|
22
|
+
) {
|
20
23
|
initTheme = darkTheme;
|
21
24
|
}
|
22
25
|
|
23
|
-
addEventListener(
|
26
|
+
addEventListener('message', (event) => {
|
24
27
|
let theme;
|
25
28
|
|
26
29
|
/* credit to <https://github.com/utterance/utterances/issues/170#issuecomment-594036347> */
|
27
30
|
if (event.origin === origin) {
|
28
31
|
/* page initial */
|
29
32
|
theme = initTheme;
|
30
|
-
|
31
|
-
} else if (event.source === window && event.data &&
|
32
|
-
event.data.direction === ModeToggle.ID) {
|
33
|
+
} else if (event.source === window && event.data && event.data.direction === ModeToggle.ID) {
|
33
34
|
/* global theme mode changed */
|
34
35
|
const mode = event.data.message;
|
35
|
-
theme =
|
36
|
-
|
36
|
+
theme = mode === ModeToggle.DARK_MODE ? darkTheme : lightTheme;
|
37
37
|
} else {
|
38
38
|
return;
|
39
39
|
}
|
40
40
|
|
41
41
|
const message = {
|
42
|
-
type:
|
42
|
+
type: 'set-theme',
|
43
43
|
theme: theme
|
44
44
|
};
|
45
45
|
|
46
46
|
const utterances = document.querySelector(iframe).contentWindow;
|
47
47
|
utterances.postMessage(message, origin);
|
48
48
|
});
|
49
|
-
|
50
|
-
});
|
49
|
+
})();
|
51
50
|
</script>
|
data/_includes/embed/twitch.html
CHANGED
@@ -1,4 +1,8 @@
|
|
1
|
-
<iframe
|
1
|
+
<iframe
|
2
|
+
class="embed-video twitch"
|
3
|
+
loading="lazy"
|
2
4
|
src="https://player.twitch.tv/?video={{ include.id }}&parent={{ site.url | split: '://' | last | remove: '/' }}"
|
3
|
-
frameborder="0"
|
4
|
-
|
5
|
+
frameborder="0"
|
6
|
+
allowfullscreen="true"
|
7
|
+
scrolling="no"
|
8
|
+
></iframe>
|
@@ -1,6 +1,9 @@
|
|
1
|
-
<iframe
|
1
|
+
<iframe
|
2
|
+
class="embed-video youtube"
|
3
|
+
loading="lazy"
|
2
4
|
src="https://www.youtube.com/embed/{{ include.id }}"
|
3
5
|
title="YouTube video player"
|
4
6
|
frameborder="0"
|
5
7
|
allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture"
|
6
|
-
allowfullscreen
|
8
|
+
allowfullscreen
|
9
|
+
></iframe>
|
data/_includes/head.html
CHANGED
@@ -80,6 +80,10 @@
|
|
80
80
|
<link rel="stylesheet" href="{{ site.data.origin[type].toc.css | relative_url }}">
|
81
81
|
{% endif %}
|
82
82
|
|
83
|
+
{% if page.layout == 'post' or page.layout == 'page' or page.layout == 'home' %}
|
84
|
+
<link rel="stylesheet" href="{{ site.data.origin[type]['lazy-polyfill'].css | relative_url }}">
|
85
|
+
{% endif %}
|
86
|
+
|
83
87
|
{% if page.layout == 'page' or page.layout == 'post' %}
|
84
88
|
<!-- Manific Popup -->
|
85
89
|
<link rel="stylesheet" href="{{ site.data.origin[type].magnific-popup.css | relative_url }}">
|
data/_includes/js-selector.html
CHANGED
@@ -12,7 +12,7 @@
|
|
12
12
|
<!-- layout specified -->
|
13
13
|
|
14
14
|
{% if page.layout == 'post' or page.layout == 'page' or page.layout == 'home' %}
|
15
|
-
{% assign urls = urls | append: ',' | append: site.data.origin[type].
|
15
|
+
{% assign urls = urls | append: ',' | append: site.data.origin[type]['lazy-polyfill'].js %}
|
16
16
|
|
17
17
|
{% unless page.layout == 'home' %}
|
18
18
|
<!-- image lazy-loading & popup & clipboard -->
|
@@ -87,7 +87,7 @@
|
|
87
87
|
}
|
88
88
|
};
|
89
89
|
</script>
|
90
|
-
<script src="
|
90
|
+
<script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
|
91
91
|
<script id="MathJax-script" async src="{{ site.data.origin[type].mathjax.js | relative_url }}"></script>
|
92
92
|
{% endif %}
|
93
93
|
|
data/_includes/post-sharing.html
CHANGED
@@ -1,23 +1,38 @@
|
|
1
1
|
<!-- Post sharing snippet -->
|
2
2
|
|
3
3
|
<div class="share-wrapper d-flex align-items-center">
|
4
|
-
<span class="share-label text-muted
|
4
|
+
<span class="share-label text-muted">{{ site.data.locales[include.lang].post.share }}</span>
|
5
5
|
<span class="share-icons">
|
6
6
|
{% capture title %}{{ page.title }} - {{ site.title }}{% endcapture %}
|
7
7
|
{% assign title = title | uri_escape %}
|
8
8
|
{% assign url = page.url | absolute_url | url_encode %}
|
9
9
|
|
10
|
-
{% for share in site.data.share.platforms
|
10
|
+
{% for share in site.data.share.platforms -%}
|
11
|
+
{%- capture tooltip -%}
|
12
|
+
data-bs-toggle="tooltip" data-bs-placement="top" title="{{ share.type }}" aria-label="{{ share.type }}"
|
13
|
+
{%- endcapture -%}
|
14
|
+
|
15
|
+
{% if share.type == 'Mastodon' %}
|
16
|
+
<script defer type="module" src="https://cdn.jsdelivr.net/npm/@justinribeiro/share-to-mastodon/+esm"></script>
|
17
|
+
<button class="btn text-start" {{ tooltip }}>
|
18
|
+
<share-to-mastodon
|
19
|
+
class="share-mastodon"
|
20
|
+
message="{{ title }}"
|
21
|
+
url="{{ url }}"
|
22
|
+
{%- if share.instances -%}
|
23
|
+
customInstanceList="{{ share.instances | jsonify | xml_escape }}"
|
24
|
+
{%- endif %}
|
25
|
+
>
|
26
|
+
<i class="fa-fw {{ share.icon }}"></i>
|
27
|
+
</share-to-mastodon>
|
28
|
+
</button>
|
29
|
+
|
30
|
+
{% continue %}
|
31
|
+
{% endif %}
|
32
|
+
|
11
33
|
{% assign link = share.link | replace: 'TITLE', title | replace: 'URL', url %}
|
12
|
-
|
13
|
-
|
14
|
-
data-bs-toggle="tooltip"
|
15
|
-
data-bs-placement="top"
|
16
|
-
title="{{ share.type }}"
|
17
|
-
target="_blank"
|
18
|
-
rel="noopener"
|
19
|
-
aria-label="{{ share.type }}"
|
20
|
-
>
|
34
|
+
|
35
|
+
<a href="{{ link }}" target="_blank" rel="noopener" {{ tooltip }}>
|
21
36
|
<i class="fa-fw {{ share.icon }}"></i>
|
22
37
|
</a>
|
23
38
|
{% endfor %}
|
@@ -31,7 +46,7 @@
|
|
31
46
|
title="{{ site.data.locales[include.lang].post.button.share_link.title }}"
|
32
47
|
data-title-succeed="{{ site.data.locales[include.lang].post.button.share_link.succeed }}"
|
33
48
|
>
|
34
|
-
<i class="fa-fw fas fa-link pe-none"></i>
|
49
|
+
<i class="fa-fw fas fa-link pe-none fs-6"></i>
|
35
50
|
</button>
|
36
51
|
</span>
|
37
52
|
</div>
|