jekyll-theme-abd3lraouf 5.2.5 → 5.2.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE +21 -21
- data/README.md +105 -105
- data/_config.yml +1 -1
- data/_data/assets/cross_origin.yml +62 -62
- data/_data/assets/self_host.yml +51 -51
- data/_data/authors.yml +17 -17
- data/_data/contact.yml +30 -30
- data/_data/locales/bg-BG.yml +83 -83
- data/_data/locales/en.yml +83 -83
- data/_data/locales/es-ES.yml +79 -79
- data/_data/locales/fr-FR.yml +79 -79
- data/_data/locales/hu-HU.yml +81 -81
- data/_data/locales/id-ID.yml +79 -79
- data/_data/locales/ko-KR.yml +79 -79
- data/_data/locales/my-MM.yml +79 -79
- data/_data/locales/pt-BR.yml +79 -79
- data/_data/locales/ru-RU.yml +79 -79
- data/_data/locales/tr-TR.yml +79 -79
- data/_data/locales/uk-UA.yml +79 -79
- data/_data/locales/vi-VN.yml +77 -77
- data/_data/locales/zh-CN.yml +78 -78
- data/_data/share.yml +27 -27
- data/_includes/assets-origin.html +12 -12
- data/_includes/comments/disqus.html +54 -54
- data/_includes/comments/giscus.html +56 -56
- data/_includes/comments/utterances.html +51 -51
- data/_includes/comments.html +5 -5
- data/_includes/datetime.html +21 -21
- data/_includes/favicons.html +17 -17
- data/_includes/footer.html +17 -36
- data/_includes/google-analytics.html +14 -14
- data/_includes/head.html +116 -116
- data/_includes/js-selector.html +104 -104
- data/_includes/jsdelivr-combine.html +32 -32
- data/_includes/lang.html +8 -8
- data/_includes/language-alias.html +70 -70
- data/_includes/mermaid.html +57 -57
- data/_includes/mode-toggle.html +129 -129
- data/_includes/no-linenos.html +10 -10
- data/_includes/post-nav.html +30 -30
- data/_includes/post-paginator.html +88 -88
- data/_includes/post-sharing.html +27 -27
- data/_includes/read-time.html +30 -30
- data/_includes/refactor-content.html +282 -282
- data/_includes/related-posts.html +103 -103
- data/_includes/search-loader.html +46 -46
- data/_includes/search-results.html +11 -11
- data/_includes/sidebar.html +93 -93
- data/_includes/toc.html +16 -16
- data/_includes/topbar.html +70 -70
- data/_includes/trending-tags.html +50 -50
- data/_includes/update-list.html +40 -40
- data/_layouts/archives.html +48 -48
- data/_layouts/categories.html +120 -120
- data/_layouts/category.html +24 -24
- data/_layouts/compress.html +10 -10
- data/_layouts/default.html +74 -74
- data/_layouts/home.html +103 -103
- data/_layouts/page.html +64 -64
- data/_layouts/post.html +159 -159
- data/_layouts/tag.html +23 -23
- data/_layouts/tags.html +23 -23
- data/_plugins/posts-lastmod-hook.rb +14 -14
- data/_sass/addon/commons.scss +1678 -1680
- data/_sass/addon/module.scss +151 -151
- data/_sass/addon/syntax.scss +289 -289
- data/_sass/addon/variables.scss +34 -34
- data/_sass/colors/dark-syntax.scss +88 -88
- data/_sass/colors/dark-typography.scss +157 -157
- data/_sass/colors/light-syntax.scss +84 -84
- data/_sass/colors/light-typography.scss +94 -94
- data/_sass/jekyll-theme-abd3lraouf.scss +1 -1
- data/_sass/layout/archives.scss +147 -147
- data/_sass/layout/categories.scss +67 -67
- data/_sass/layout/category-tag.scss +73 -73
- data/_sass/layout/home.scss +184 -184
- data/_sass/layout/post.scss +369 -369
- data/_sass/layout/tags.scss +19 -19
- data/_sass/variables-hook.scss +3 -3
- data/_tabs/about.md +8 -8
- data/_tabs/archives.md +7 -7
- data/_tabs/categories.md +6 -6
- data/_tabs/tags.md +6 -6
- data/assets/404.html +71 -16
- data/assets/css/style.scss +12 -12
- data/assets/feed.xml +61 -61
- data/assets/img/404.png +0 -0
- data/assets/img/favicons/browserconfig.xml +13 -13
- data/assets/img/favicons/site.webmanifest +26 -26
- data/assets/js/data/search.json +18 -18
- data/assets/js/data/swcache.js +55 -55
- data/assets/js/dist/categories.min.js +1 -1
- data/assets/js/dist/commons.min.js +1 -1
- data/assets/js/dist/home.min.js +1 -1
- data/assets/js/dist/misc.min.js +1 -1
- data/assets/js/dist/page.min.js +1 -1
- data/assets/js/dist/post.min.js +1 -1
- data/assets/js/dist/pvreport.min.js +1 -1
- data/assets/js/pwa/app.js +47 -47
- data/assets/js/pwa/sw.js +89 -89
- data/assets/js/pwa/unregister.js +12 -12
- data/assets/robots.txt +10 -10
- data/index.html +4 -4
- metadata +8 -7
@@ -1,103 +1,103 @@
|
|
1
|
-
<!--
|
2
|
-
Recommend the other 3 posts according to the tags and categories of the current post,
|
3
|
-
if the number is not enough, use the other latest posts to supplement.
|
4
|
-
-->
|
5
|
-
|
6
|
-
<!-- The total size of related posts -->
|
7
|
-
{% assign TOTAL_SIZE = 3 %}
|
8
|
-
|
9
|
-
<!-- An random integer that bigger than 0 -->
|
10
|
-
{% assign TAG_SCORE = 1 %}
|
11
|
-
|
12
|
-
<!-- Equals to TAG_SCORE / {max_categories_hierarchy} -->
|
13
|
-
{% assign CATEGORY_SCORE = 0.5 %}
|
14
|
-
|
15
|
-
{% assign SEPARATOR = ":" %}
|
16
|
-
|
17
|
-
{% assign score_list = "" | split: "" %}
|
18
|
-
{% assign last_index = site.posts.size | minus: 1 %}
|
19
|
-
|
20
|
-
{% for i in (0..last_index) %}
|
21
|
-
{% assign post = site.posts[i] %}
|
22
|
-
|
23
|
-
{% if post.url == page.url %}
|
24
|
-
{% continue %}
|
25
|
-
{% endif %}
|
26
|
-
|
27
|
-
{% assign score = 0 %}
|
28
|
-
|
29
|
-
{% for tag in post.tags %}
|
30
|
-
{% if page.tags contains tag %}
|
31
|
-
{% assign score = score | plus: TAG_SCORE %}
|
32
|
-
{% endif %}
|
33
|
-
{% endfor %}
|
34
|
-
|
35
|
-
{% for category in post.categories %}
|
36
|
-
{% if page.categories contains category %}
|
37
|
-
{% assign score = score | plus: CATEGORY_SCORE %}
|
38
|
-
{% endif %}
|
39
|
-
{% endfor %}
|
40
|
-
|
41
|
-
{% if score > 0 %}
|
42
|
-
{% capture score_item %}{{ score }}{{ SEPARATOR }}{{ i }}{% endcapture %}
|
43
|
-
{% assign score_list = score_list | push: score_item %}
|
44
|
-
{% endif %}
|
45
|
-
|
46
|
-
{% endfor %}
|
47
|
-
|
48
|
-
|
49
|
-
{% assign index_list = "" | split: "" %}
|
50
|
-
|
51
|
-
{% if score_list.size > 0 %}
|
52
|
-
{% assign score_list = score_list | sort | reverse %}
|
53
|
-
{% for entry in score_list limit: TOTAL_SIZE %}
|
54
|
-
{% assign index = entry | split: SEPARATOR | last %}
|
55
|
-
{% assign index_list = index_list | push: index %}
|
56
|
-
{% endfor %}
|
57
|
-
{% endif %}
|
58
|
-
|
59
|
-
<!-- Fill with the other newlest posts -->
|
60
|
-
{% assign less = TOTAL_SIZE | minus: index_list.size %}
|
61
|
-
|
62
|
-
{% if less > 0 %}
|
63
|
-
{% for i in (0..last_index) %}
|
64
|
-
{% assign post = site.posts[i] %}
|
65
|
-
{% if post.url != page.url %}
|
66
|
-
{% capture cur_index %}{{ i }}{% endcapture %}
|
67
|
-
{% unless index_list contains cur_index %}
|
68
|
-
{% assign index_list = index_list | push: cur_index %}
|
69
|
-
{% assign less = less | minus: 1 %}
|
70
|
-
{% if less <= 0 %}
|
71
|
-
{% break %}
|
72
|
-
{% endif %}
|
73
|
-
{% endunless %}
|
74
|
-
{% endif %}
|
75
|
-
{% endfor %}
|
76
|
-
{% endif %}
|
77
|
-
|
78
|
-
{% if index_list.size > 0 %}
|
79
|
-
<div id="related-posts" class="mt-5 mb-2 mb-sm-4">
|
80
|
-
<h3 class="pt-2 mt-1 mb-4 ml-1"
|
81
|
-
data-toc-skip>{{ site.data.locales[lang].post.relate_posts }}</h3>
|
82
|
-
<div class="card-deck mb-4">
|
83
|
-
{% for entry in index_list %}
|
84
|
-
{% assign index = entry | plus: 0 %}
|
85
|
-
{% assign post = site.posts[index] %}
|
86
|
-
<div class="card">
|
87
|
-
<a href="{{ post.url | relative_url }}">
|
88
|
-
<div class="card-body">
|
89
|
-
{% include datetime.html date=post.date class="small" %}
|
90
|
-
<h3 class="pt-0 mt-1 mb-3" data-toc-skip>{{ post.title }}</h3>
|
91
|
-
<div class="text-muted small">
|
92
|
-
<p>
|
93
|
-
{% include no-linenos.html content=post.content %}
|
94
|
-
{{ content | markdownify | strip_html | truncate: 200 | escape }}
|
95
|
-
</p>
|
96
|
-
</div>
|
97
|
-
</div>
|
98
|
-
</a>
|
99
|
-
</div>
|
100
|
-
{% endfor %}
|
101
|
-
</div> <!-- .card-deck -->
|
102
|
-
</div> <!-- #related-posts -->
|
103
|
-
{% endif %}
|
1
|
+
<!--
|
2
|
+
Recommend the other 3 posts according to the tags and categories of the current post,
|
3
|
+
if the number is not enough, use the other latest posts to supplement.
|
4
|
+
-->
|
5
|
+
|
6
|
+
<!-- The total size of related posts -->
|
7
|
+
{% assign TOTAL_SIZE = 3 %}
|
8
|
+
|
9
|
+
<!-- An random integer that bigger than 0 -->
|
10
|
+
{% assign TAG_SCORE = 1 %}
|
11
|
+
|
12
|
+
<!-- Equals to TAG_SCORE / {max_categories_hierarchy} -->
|
13
|
+
{% assign CATEGORY_SCORE = 0.5 %}
|
14
|
+
|
15
|
+
{% assign SEPARATOR = ":" %}
|
16
|
+
|
17
|
+
{% assign score_list = "" | split: "" %}
|
18
|
+
{% assign last_index = site.posts.size | minus: 1 %}
|
19
|
+
|
20
|
+
{% for i in (0..last_index) %}
|
21
|
+
{% assign post = site.posts[i] %}
|
22
|
+
|
23
|
+
{% if post.url == page.url %}
|
24
|
+
{% continue %}
|
25
|
+
{% endif %}
|
26
|
+
|
27
|
+
{% assign score = 0 %}
|
28
|
+
|
29
|
+
{% for tag in post.tags %}
|
30
|
+
{% if page.tags contains tag %}
|
31
|
+
{% assign score = score | plus: TAG_SCORE %}
|
32
|
+
{% endif %}
|
33
|
+
{% endfor %}
|
34
|
+
|
35
|
+
{% for category in post.categories %}
|
36
|
+
{% if page.categories contains category %}
|
37
|
+
{% assign score = score | plus: CATEGORY_SCORE %}
|
38
|
+
{% endif %}
|
39
|
+
{% endfor %}
|
40
|
+
|
41
|
+
{% if score > 0 %}
|
42
|
+
{% capture score_item %}{{ score }}{{ SEPARATOR }}{{ i }}{% endcapture %}
|
43
|
+
{% assign score_list = score_list | push: score_item %}
|
44
|
+
{% endif %}
|
45
|
+
|
46
|
+
{% endfor %}
|
47
|
+
|
48
|
+
|
49
|
+
{% assign index_list = "" | split: "" %}
|
50
|
+
|
51
|
+
{% if score_list.size > 0 %}
|
52
|
+
{% assign score_list = score_list | sort | reverse %}
|
53
|
+
{% for entry in score_list limit: TOTAL_SIZE %}
|
54
|
+
{% assign index = entry | split: SEPARATOR | last %}
|
55
|
+
{% assign index_list = index_list | push: index %}
|
56
|
+
{% endfor %}
|
57
|
+
{% endif %}
|
58
|
+
|
59
|
+
<!-- Fill with the other newlest posts -->
|
60
|
+
{% assign less = TOTAL_SIZE | minus: index_list.size %}
|
61
|
+
|
62
|
+
{% if less > 0 %}
|
63
|
+
{% for i in (0..last_index) %}
|
64
|
+
{% assign post = site.posts[i] %}
|
65
|
+
{% if post.url != page.url %}
|
66
|
+
{% capture cur_index %}{{ i }}{% endcapture %}
|
67
|
+
{% unless index_list contains cur_index %}
|
68
|
+
{% assign index_list = index_list | push: cur_index %}
|
69
|
+
{% assign less = less | minus: 1 %}
|
70
|
+
{% if less <= 0 %}
|
71
|
+
{% break %}
|
72
|
+
{% endif %}
|
73
|
+
{% endunless %}
|
74
|
+
{% endif %}
|
75
|
+
{% endfor %}
|
76
|
+
{% endif %}
|
77
|
+
|
78
|
+
{% if index_list.size > 0 %}
|
79
|
+
<div id="related-posts" class="mt-5 mb-2 mb-sm-4">
|
80
|
+
<h3 class="pt-2 mt-1 mb-4 ml-1"
|
81
|
+
data-toc-skip>{{ site.data.locales[lang].post.relate_posts }}</h3>
|
82
|
+
<div class="card-deck mb-4">
|
83
|
+
{% for entry in index_list %}
|
84
|
+
{% assign index = entry | plus: 0 %}
|
85
|
+
{% assign post = site.posts[index] %}
|
86
|
+
<div class="card">
|
87
|
+
<a href="{{ post.url | relative_url }}">
|
88
|
+
<div class="card-body">
|
89
|
+
{% include datetime.html date=post.date class="small" %}
|
90
|
+
<h3 class="pt-0 mt-1 mb-3" data-toc-skip>{{ post.title }}</h3>
|
91
|
+
<div class="text-muted small">
|
92
|
+
<p>
|
93
|
+
{% include no-linenos.html content=post.content %}
|
94
|
+
{{ content | markdownify | strip_html | truncate: 200 | escape }}
|
95
|
+
</p>
|
96
|
+
</div>
|
97
|
+
</div>
|
98
|
+
</a>
|
99
|
+
</div>
|
100
|
+
{% endfor %}
|
101
|
+
</div> <!-- .card-deck -->
|
102
|
+
</div> <!-- #related-posts -->
|
103
|
+
{% endif %}
|
@@ -1,46 +1,46 @@
|
|
1
|
-
<!--
|
2
|
-
Jekyll Simple Search loader
|
3
|
-
See: <https://github.com/christian-fei/Simple-Jekyll-Search>
|
4
|
-
-->
|
5
|
-
|
6
|
-
{% capture result_elem %}
|
7
|
-
<div class="pl-1 pr-1 pl-sm-2 pr-sm-2 pl-lg-4 pr-lg-4 pl-xl-0 pr-xl-0">
|
8
|
-
<a href="{url}">{title}</a>
|
9
|
-
<div class="post-meta d-flex flex-column flex-sm-row text-muted mt-1 mb-1">
|
10
|
-
{categories}
|
11
|
-
{tags}
|
12
|
-
</div>
|
13
|
-
<p>{snippet}</p>
|
14
|
-
</div>
|
15
|
-
{% endcapture %}
|
16
|
-
|
17
|
-
{% capture not_found %}<p class="mt-5">{{ site.data.locales[lang].search.no_results }}</p>{% endcapture %}
|
18
|
-
|
19
|
-
<script src="{{ site.data.assets[origin].search.js | relative_url }}"></script>
|
20
|
-
|
21
|
-
<script>
|
22
|
-
SimpleJekyllSearch({
|
23
|
-
searchInput: document.getElementById('search-input'),
|
24
|
-
resultsContainer: document.getElementById('search-results'),
|
25
|
-
json: '{{ '/assets/js/data/search.json' | relative_url }}',
|
26
|
-
searchResultTemplate: '{{ result_elem | strip_newlines }}',
|
27
|
-
noResultsText: '{{ not_found }}',
|
28
|
-
templateMiddleware: function(prop, value, template) {
|
29
|
-
if (prop === 'categories') {
|
30
|
-
if (value === '') {
|
31
|
-
return `${value}`;
|
32
|
-
} else {
|
33
|
-
return `<div class="mr-sm-4"><i class="far fa-folder fa-fw"></i>${value}</div>`;
|
34
|
-
}
|
35
|
-
}
|
36
|
-
|
37
|
-
if (prop === 'tags') {
|
38
|
-
if (value === '') {
|
39
|
-
return `${value}`;
|
40
|
-
} else {
|
41
|
-
return `<div><i class="fa fa-tag fa-fw"></i>${value}</div>`;
|
42
|
-
}
|
43
|
-
}
|
44
|
-
}
|
45
|
-
});
|
46
|
-
</script>
|
1
|
+
<!--
|
2
|
+
Jekyll Simple Search loader
|
3
|
+
See: <https://github.com/christian-fei/Simple-Jekyll-Search>
|
4
|
+
-->
|
5
|
+
|
6
|
+
{% capture result_elem %}
|
7
|
+
<div class="pl-1 pr-1 pl-sm-2 pr-sm-2 pl-lg-4 pr-lg-4 pl-xl-0 pr-xl-0">
|
8
|
+
<a href="{url}">{title}</a>
|
9
|
+
<div class="post-meta d-flex flex-column flex-sm-row text-muted mt-1 mb-1">
|
10
|
+
{categories}
|
11
|
+
{tags}
|
12
|
+
</div>
|
13
|
+
<p>{snippet}</p>
|
14
|
+
</div>
|
15
|
+
{% endcapture %}
|
16
|
+
|
17
|
+
{% capture not_found %}<p class="mt-5">{{ site.data.locales[lang].search.no_results }}</p>{% endcapture %}
|
18
|
+
|
19
|
+
<script src="{{ site.data.assets[origin].search.js | relative_url }}"></script>
|
20
|
+
|
21
|
+
<script>
|
22
|
+
SimpleJekyllSearch({
|
23
|
+
searchInput: document.getElementById('search-input'),
|
24
|
+
resultsContainer: document.getElementById('search-results'),
|
25
|
+
json: '{{ '/assets/js/data/search.json' | relative_url }}',
|
26
|
+
searchResultTemplate: '{{ result_elem | strip_newlines }}',
|
27
|
+
noResultsText: '{{ not_found }}',
|
28
|
+
templateMiddleware: function(prop, value, template) {
|
29
|
+
if (prop === 'categories') {
|
30
|
+
if (value === '') {
|
31
|
+
return `${value}`;
|
32
|
+
} else {
|
33
|
+
return `<div class="mr-sm-4"><i class="far fa-folder fa-fw"></i>${value}</div>`;
|
34
|
+
}
|
35
|
+
}
|
36
|
+
|
37
|
+
if (prop === 'tags') {
|
38
|
+
if (value === '') {
|
39
|
+
return `${value}`;
|
40
|
+
} else {
|
41
|
+
return `<div><i class="fa fa-tag fa-fw"></i>${value}</div>`;
|
42
|
+
}
|
43
|
+
}
|
44
|
+
}
|
45
|
+
});
|
46
|
+
</script>
|
@@ -1,11 +1,11 @@
|
|
1
|
-
<!--
|
2
|
-
The Search results
|
3
|
-
-->
|
4
|
-
<div id="search-result-wrapper" class="d-flex justify-content-center unloaded">
|
5
|
-
<div class="col-12 col-sm-11 post-content">
|
6
|
-
<div id="search-hints">
|
7
|
-
{% include trending-tags.html %}
|
8
|
-
</div>
|
9
|
-
<div id="search-results" class="d-flex flex-wrap justify-content-center text-muted mt-3"></div>
|
10
|
-
</div>
|
11
|
-
</div>
|
1
|
+
<!--
|
2
|
+
The Search results
|
3
|
+
-->
|
4
|
+
<div id="search-result-wrapper" class="d-flex justify-content-center unloaded">
|
5
|
+
<div class="col-12 col-sm-11 post-content">
|
6
|
+
<div id="search-hints">
|
7
|
+
{% include trending-tags.html %}
|
8
|
+
</div>
|
9
|
+
<div id="search-results" class="d-flex flex-wrap justify-content-center text-muted mt-3"></div>
|
10
|
+
</div>
|
11
|
+
</div>
|
data/_includes/sidebar.html
CHANGED
@@ -1,93 +1,93 @@
|
|
1
|
-
<!--
|
2
|
-
The Side Bar
|
3
|
-
-->
|
4
|
-
|
5
|
-
<div id="sidebar" class="d-flex flex-column align-items-end">
|
6
|
-
<div class="profile-wrapper text-center">
|
7
|
-
<div id="avatar">
|
8
|
-
<a href="{{ '/' | relative_url }}" class="mx-auto">
|
9
|
-
{% if site.avatar != empty and site.avatar %}
|
10
|
-
{% capture avatar_url %}
|
11
|
-
{% if site.avatar contains '://' %}
|
12
|
-
{{ site.avatar }}
|
13
|
-
{% elsif site.img_cdn != empty and site.img_cdn %}
|
14
|
-
{{ site.avatar | prepend: site.img_cdn }}
|
15
|
-
{% else %}
|
16
|
-
{{ site.avatar | relative_url }}
|
17
|
-
{% endif %}
|
18
|
-
{% endcapture %}
|
19
|
-
<img src="{{ avatar_url | strip }}" alt="avatar" onerror="this.style.display='none'">
|
20
|
-
{% endif %}
|
21
|
-
</a>
|
22
|
-
</div>
|
23
|
-
|
24
|
-
<div class="site-title mt-3">
|
25
|
-
<a href="{{ '/' | relative_url }}">{{ site.title }}</a>
|
26
|
-
</div>
|
27
|
-
<div class="site-subtitle font-italic">{{ site.tagline }}</div>
|
28
|
-
|
29
|
-
</div><!-- .profile-wrapper -->
|
30
|
-
|
31
|
-
<ul class="w-100">
|
32
|
-
|
33
|
-
<!-- home -->
|
34
|
-
<li class="nav-item{% if page.layout == 'home' %}{{ " active" }}{% endif %}">
|
35
|
-
<a href="{{ '/' | relative_url }}" class="nav-link">
|
36
|
-
<i class="fa-fw fas fa-home ml-xl-3 mr-xl-3 unloaded"></i>
|
37
|
-
<span>{{ site.data.locales[lang].tabs.home | upcase }}</span>
|
38
|
-
</a>
|
39
|
-
</li>
|
40
|
-
<!-- the real tabs -->
|
41
|
-
{% for tab in site.tabs %}
|
42
|
-
<li class="nav-item{% if tab.url == page.url %}{{ " active" }}{% endif %}">
|
43
|
-
<a href="{{ tab.url | relative_url }}" class="nav-link">
|
44
|
-
<i class="fa-fw {{ tab.icon }} ml-xl-3 mr-xl-3 unloaded"></i>
|
45
|
-
{% capture tab_name %}{{ tab.url | split: '/' }}{% endcapture %}
|
46
|
-
|
47
|
-
<span>{{ site.data.locales[lang].tabs.[tab_name] | default: tab.title | upcase }}</span>
|
48
|
-
</a>
|
49
|
-
</li> <!-- .nav-item -->
|
50
|
-
{% endfor %}
|
51
|
-
|
52
|
-
</ul> <!-- ul.nav.flex-column -->
|
53
|
-
|
54
|
-
<div class="sidebar-bottom mt-auto d-flex flex-wrap justify-content-center align-items-center">
|
55
|
-
|
56
|
-
{% unless site.theme_mode %}
|
57
|
-
<button class="mode-toggle btn" aria-label="Switch Mode">
|
58
|
-
<i class="fas fa-adjust"></i>
|
59
|
-
</button>
|
60
|
-
|
61
|
-
{% if site.data.contact.size > 0 %}
|
62
|
-
<span class="icon-border"></span>
|
63
|
-
{% endif %}
|
64
|
-
{% endunless %}
|
65
|
-
|
66
|
-
{% for entry in site.data.contact %}
|
67
|
-
{% capture url %}
|
68
|
-
{%- if entry.type == 'github' -%}
|
69
|
-
https://github.com/{{ site.github.username }}
|
70
|
-
{%- elsif entry.type == 'twitter' -%}
|
71
|
-
https://twitter.com/{{ site.twitter.username }}
|
72
|
-
{%- elsif entry.type == 'email' -%}
|
73
|
-
{% assign email = site.social.email | split: '@' %}
|
74
|
-
javascript:location.href = 'mailto:' + ['{{ email[0] }}','{{ email[1] }}'].join('@')
|
75
|
-
{%- elsif entry.type == 'rss' -%}
|
76
|
-
{{ "/feed.xml" | relative_url }}
|
77
|
-
{%- else -%}
|
78
|
-
{{ entry.url }}
|
79
|
-
{%- endif -%}
|
80
|
-
{% endcapture %}
|
81
|
-
|
82
|
-
{% if url %}
|
83
|
-
<a href="{{ url }}" aria-label="{{ entry.type }}"
|
84
|
-
{% unless entry.noblank %}target="_blank" rel="noopener"{% endunless %}>
|
85
|
-
<i class="{{ entry.icon }}"></i>
|
86
|
-
</a>
|
87
|
-
{% endif %}
|
88
|
-
|
89
|
-
{% endfor %}
|
90
|
-
|
91
|
-
</div> <!-- .sidebar-bottom -->
|
92
|
-
|
93
|
-
</div><!-- #sidebar -->
|
1
|
+
<!--
|
2
|
+
The Side Bar
|
3
|
+
-->
|
4
|
+
|
5
|
+
<div id="sidebar" class="d-flex flex-column align-items-end">
|
6
|
+
<div class="profile-wrapper text-center">
|
7
|
+
<div id="avatar">
|
8
|
+
<a href="{{ '/' | relative_url }}" class="mx-auto">
|
9
|
+
{% if site.avatar != empty and site.avatar %}
|
10
|
+
{% capture avatar_url %}
|
11
|
+
{% if site.avatar contains '://' %}
|
12
|
+
{{ site.avatar }}
|
13
|
+
{% elsif site.img_cdn != empty and site.img_cdn %}
|
14
|
+
{{ site.avatar | prepend: site.img_cdn }}
|
15
|
+
{% else %}
|
16
|
+
{{ site.avatar | relative_url }}
|
17
|
+
{% endif %}
|
18
|
+
{% endcapture %}
|
19
|
+
<img src="{{ avatar_url | strip }}" alt="avatar" onerror="this.style.display='none'">
|
20
|
+
{% endif %}
|
21
|
+
</a>
|
22
|
+
</div>
|
23
|
+
|
24
|
+
<div class="site-title mt-3">
|
25
|
+
<a href="{{ '/' | relative_url }}">{{ site.title }}</a>
|
26
|
+
</div>
|
27
|
+
<div class="site-subtitle font-italic">{{ site.tagline }}</div>
|
28
|
+
|
29
|
+
</div><!-- .profile-wrapper -->
|
30
|
+
|
31
|
+
<ul class="w-100">
|
32
|
+
|
33
|
+
<!-- home -->
|
34
|
+
<li class="nav-item{% if page.layout == 'home' %}{{ " active" }}{% endif %}">
|
35
|
+
<a href="{{ '/' | relative_url }}" class="nav-link">
|
36
|
+
<i class="fa-fw fas fa-home ml-xl-3 mr-xl-3 unloaded"></i>
|
37
|
+
<span>{{ site.data.locales[lang].tabs.home | upcase }}</span>
|
38
|
+
</a>
|
39
|
+
</li>
|
40
|
+
<!-- the real tabs -->
|
41
|
+
{% for tab in site.tabs %}
|
42
|
+
<li class="nav-item{% if tab.url == page.url %}{{ " active" }}{% endif %}">
|
43
|
+
<a href="{{ tab.url | relative_url }}" class="nav-link">
|
44
|
+
<i class="fa-fw {{ tab.icon }} ml-xl-3 mr-xl-3 unloaded"></i>
|
45
|
+
{% capture tab_name %}{{ tab.url | split: '/' }}{% endcapture %}
|
46
|
+
|
47
|
+
<span>{{ site.data.locales[lang].tabs.[tab_name] | default: tab.title | upcase }}</span>
|
48
|
+
</a>
|
49
|
+
</li> <!-- .nav-item -->
|
50
|
+
{% endfor %}
|
51
|
+
|
52
|
+
</ul> <!-- ul.nav.flex-column -->
|
53
|
+
|
54
|
+
<div class="sidebar-bottom mt-auto d-flex flex-wrap justify-content-center align-items-center">
|
55
|
+
|
56
|
+
{% unless site.theme_mode %}
|
57
|
+
<button class="mode-toggle btn" aria-label="Switch Mode">
|
58
|
+
<i class="fas fa-adjust"></i>
|
59
|
+
</button>
|
60
|
+
|
61
|
+
{% if site.data.contact.size > 0 %}
|
62
|
+
<span class="icon-border"></span>
|
63
|
+
{% endif %}
|
64
|
+
{% endunless %}
|
65
|
+
|
66
|
+
{% for entry in site.data.contact %}
|
67
|
+
{% capture url %}
|
68
|
+
{%- if entry.type == 'github' -%}
|
69
|
+
https://github.com/{{ site.github.username }}
|
70
|
+
{%- elsif entry.type == 'twitter' -%}
|
71
|
+
https://twitter.com/{{ site.twitter.username }}
|
72
|
+
{%- elsif entry.type == 'email' -%}
|
73
|
+
{% assign email = site.social.email | split: '@' %}
|
74
|
+
javascript:location.href = 'mailto:' + ['{{ email[0] }}','{{ email[1] }}'].join('@')
|
75
|
+
{%- elsif entry.type == 'rss' -%}
|
76
|
+
{{ "/feed.xml" | relative_url }}
|
77
|
+
{%- else -%}
|
78
|
+
{{ entry.url }}
|
79
|
+
{%- endif -%}
|
80
|
+
{% endcapture %}
|
81
|
+
|
82
|
+
{% if url %}
|
83
|
+
<a href="{{ url }}" aria-label="{{ entry.type }}"
|
84
|
+
{% unless entry.noblank %}target="_blank" rel="noopener"{% endunless %}>
|
85
|
+
<i class="{{ entry.icon }}"></i>
|
86
|
+
</a>
|
87
|
+
{% endif %}
|
88
|
+
|
89
|
+
{% endfor %}
|
90
|
+
|
91
|
+
</div> <!-- .sidebar-bottom -->
|
92
|
+
|
93
|
+
</div><!-- #sidebar -->
|
data/_includes/toc.html
CHANGED
@@ -1,16 +1,16 @@
|
|
1
|
-
{% assign enable_toc = false %}
|
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 %}
|
7
|
-
|
8
|
-
{% if enable_toc %}
|
9
|
-
<!-- BS-toc.js will be loaded at medium priority -->
|
10
|
-
<script src="{{ site.data.assets[origin].bootstrap-toc.js | relative_url }}"></script>
|
11
|
-
|
12
|
-
<div id="toc-wrapper" class="pl-0 pr-4 mb-5">
|
13
|
-
<div class="panel-heading pl-3 pt-2 mb-2">{{- site.data.locales[lang].panel.toc -}}</div>
|
14
|
-
<nav id="toc" data-toggle="toc"></nav>
|
15
|
-
</div>
|
16
|
-
{% endif %}
|
1
|
+
{% assign enable_toc = false %}
|
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 %}
|
7
|
+
|
8
|
+
{% if enable_toc %}
|
9
|
+
<!-- BS-toc.js will be loaded at medium priority -->
|
10
|
+
<script src="{{ site.data.assets[origin].bootstrap-toc.js | relative_url }}"></script>
|
11
|
+
|
12
|
+
<div id="toc-wrapper" class="pl-0 pr-4 mb-5">
|
13
|
+
<div class="panel-heading pl-3 pt-2 mb-2">{{- site.data.locales[lang].panel.toc -}}</div>
|
14
|
+
<nav id="toc" data-toggle="toc"></nav>
|
15
|
+
</div>
|
16
|
+
{% endif %}
|