jekyll-theme-chirpy 3.2.2 → 3.3.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9a36f6248ffa49d35542f65f5243667d7e4cc7d937af7f7108a6bb07cd807d7c
4
- data.tar.gz: 04dca9dc35358c737c1abec42eb53cf1124e84b4550f0a972d04db15a22f8040
3
+ metadata.gz: d833e4ed6f7e8ec68aa2d3089a0c78378c80a67ff45f9a6bcbcf84e7f2c41d85
4
+ data.tar.gz: 51944aab8a026e3003b2eeb7e2fe7b1f2ea228f5773f4c03f287e4ef193ec1f2
5
5
  SHA512:
6
- metadata.gz: 62e1c23473be119580d580820201423118bbed6caf9b8b649fa2d7270f9a3241ac9793d7f25ce20b309705d4c7e411bcc69346427c3d3a34e92250845439ca11
7
- data.tar.gz: 821595cc8bf64a93826ca41c5d30372624cf427cc0869ce88b336fe1bbc6691bbf2c6f51f83f98b9dc1c254133c5b88461954c929865ab63fb759908338f449e
6
+ metadata.gz: 7579ca6f1d93877c8676d8bea15653f6c6d47f9080cd0eaecb3f4fc99c21dfb992dd4d9e8db4083428e56e82f87fb820fd56be914e672f7e118a7d67993a1193
7
+ data.tar.gz: e9de76b82c78fefde54aa7b8e27b69e0c88f20aaf14bfdabedda0c97d32a553944003a7907e4eddb403875036e9ae72f972f1b154e1b4af3617858a9ba2d982e
data/README.md CHANGED
@@ -12,18 +12,6 @@ A minimal, sidebar, responsive web design Jekyll theme that focuses on text pres
12
12
 
13
13
  [![Devices Mockup](https://cdn.jsdelivr.net/gh/cotes2020/chirpy-images/commons/devices-mockup.png)](https://chirpy.cotes.info)
14
14
 
15
- ## Table of Contents
16
-
17
- - [Features](#features)
18
- - [Prerequisites](#prerequisites)
19
- - [Installation](#installation)
20
- - [Usage](#usage)
21
- - [Documentation](#documentation)
22
- - [Contributing](#contributing)
23
- - [Credits](#credits)
24
- - [Support](#support)
25
- - [License](#license)
26
-
27
15
  ## Features
28
16
 
29
17
  - Pinned Posts
@@ -155,7 +143,7 @@ For security reasons, GitHub Pages build runs on `safe` mode, which restricts us
155
143
  Quickly check the files needed for GitHub Actions build:
156
144
 
157
145
  - Ensure your Jekyll site has the file `.github/workflows/pages-deploy.yml`. Otherwise, create a new one and fill in the contents of the [workflow file][workflow], and the value of the `on.push.branches` should be the same as your repo's default branch name.
158
- - Ensuer your Jekyll site has file `tools/test.sh` and `tools/deploy.sh`. Otherwise, copy them from this repo to your Jekyll site.
146
+ - Ensure your Jekyll site has file `tools/test.sh` and `tools/deploy.sh`. Otherwise, copy them from this repo to your Jekyll site.
159
147
 
160
148
  And then rename your repoistory to `<GH-USERNAME>.github.io` on GitHub.
161
149
 
@@ -207,15 +195,13 @@ This theme is mainly built with [Jekyll](https://jekyllrb.com/) ecosystem, [Boot
207
195
 
208
196
  Also, thank [JetBrains][jb] for providing the open source license.
209
197
 
210
- [![JB-logo](https://cdn.jsdelivr.net/gh/cotes2020/chirpy-images/commons/jetbrains.svg)][jb]
211
-
212
- ## Support
198
+ ## Sponsoring
213
199
 
214
200
  If you like this theme or find it helpful, please consider sponsoring me, because it will encourage and help me better maintain the project, I will be very grateful!
215
201
 
216
- [![Buy Me a Coffee](https://img.shields.io/badge/Buy%20Me%20a%20Coffee-orange?logo=buy-me-a-coffee&logoColor=white)](https://www.buymeacoffee.com/coteschung)
217
- [![Wechat Pay](https://img.shields.io/badge/WeChat%20Pay-brightgreen?logo=wechat&logoColor=white)][cn-donation]
218
- [![Alipay](https://img.shields.io/badge/Alipay-blue?logo=alipay&logoColor=white)][cn-donation]
202
+ [![Buy Me a Coffee](https://img.shields.io/badge/-Buy%20Me%20a%20Coffee-ff813f?logo=buy-me-a-coffee&logoColor=white)](https://www.buymeacoffee.com/coteschung)
203
+ [![Wechat Pay](https://img.shields.io/badge/-Tip%20Me%20on%20WeChat-brightgreen?logo=wechat&logoColor=white)][cn-donation]
204
+ [![Alipay](https://img.shields.io/badge/-Tip%20Me%20on%20Alipay-blue?logo=alipay&logoColor=white)][cn-donation]
219
205
 
220
206
  ## License
221
207
 
@@ -229,4 +215,3 @@ This work is published under [MIT](https://github.com/cotes2020/jekyll-theme-chi
229
215
 
230
216
  [jb]: https://www.jetbrains.com/?from=jekyll-theme-chirpy
231
217
  [cn-donation]: https://cotes.gitee.io/alipay-wechat-donation/
232
-
data/_config.yml CHANGED
@@ -27,8 +27,6 @@ description: >- # used by seo meta and the atom feed
27
27
  # fill in the protocol & hostname for your site, e.g., 'https://username.github.io'
28
28
  url: ''
29
29
 
30
- author: your_full_name # change to your full name
31
-
32
30
  github:
33
31
  username: github_username # change to your github username
34
32
 
@@ -36,7 +34,9 @@ twitter:
36
34
  username: twitter_username # change to your twitter username
37
35
 
38
36
  social:
39
- name: your_full_name # it will shows as the copyright owner in Footer
37
+ # Change to your full name.
38
+ # It will be displayed as the default author of the posts and the copyright owner in the Footer
39
+ name: your_full_name
40
40
  email: example@doamin.com # change to your email address
41
41
  links:
42
42
  # The first element serves as the copyright owner's link
@@ -5,7 +5,7 @@
5
5
 
6
6
  <div id="disqus" class="pt-2 pb-2">
7
7
  <p class="text-center text-muted small pb-5">
8
- Loading comments from <a href="https://disqus.com/">Disqus</a> ...
8
+ Comments powered by <a href="https://disqus.com/">Disqus</a>.
9
9
  </p>
10
10
  </div>
11
11
 
@@ -23,8 +23,25 @@
23
23
 
24
24
  {% if page.math %}
25
25
  <!-- MathJax -->
26
- <script defer src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
27
- <script defer src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-mml-chtml.js"></script>
26
+ <script>
27
+ // see: <https://docs.mathjax.org/en/latest/options/input/tex.html#tex-options>
28
+ MathJax = {
29
+ tex: {
30
+ inlineMath: [ // start/end delimiter pairs for in-line math
31
+ ['$','$'],
32
+ ['\\(','\\)']
33
+ ],
34
+ displayMath: [ // start/end delimiter pairs for display math
35
+ ['$$', '$$'],
36
+ ['\\[', '\\]']
37
+ ]
38
+ }
39
+ };
40
+ </script>
41
+ <script src="https://polyfill.io/v3/polyfill.min.js?features=es6"></script>
42
+ <script type="text/javascript" id="MathJax-script" async
43
+ src="https://cdn.jsdelivr.net/npm/mathjax@3/es5/tex-chtml.js">
44
+ </script>
28
45
  {% endif %}
29
46
 
30
47
  {% if jekyll.environment == 'production' %}
@@ -1,5 +1,6 @@
1
1
  <!--
2
2
  Date format snippet
3
+ See: /assets/js/_utils/timeage.js
3
4
  -->
4
5
 
5
6
  {% assign tooltip_df = site.data.date_format.tooltip | default: '%a, %b %e, %Y, %l:%M %p %z' %}
@@ -11,7 +12,10 @@
11
12
  data-toggle="tooltip"
12
13
  data-placement="bottom"
13
14
  title="{{ include.date | date: tooltip_df }}"
14
- {% endif %}>
15
+ {% endif %}
16
+
17
+ {% if include.prefix %}prefix="{{ include.prefix }} "{% endif%}
18
+ {% if include.prep %}prep="{{ include.prep }}"{% endif %} >
15
19
 
16
20
  {% assign this_year = site.time | date: "%Y" %}
17
21
  {% assign post_year = include.date | date: "%Y" %}
data/_layouts/post.html CHANGED
@@ -14,19 +14,18 @@ layout: default
14
14
  <div class="post-meta text-muted d-flex flex-column">
15
15
  <!-- Published date and author -->
16
16
  <div>
17
- {% include timeago.html date=page.date tooltip=true %}
18
- by
19
- <span class="author">
20
- {{ page.author | default: site.author }}
17
+ <span class="semi-bold">
18
+ {{ page.author | default: site.social.name }}
21
19
  </span>
20
+ {% include timeago.html date=page.date prep="on" tooltip=true %}
22
21
  </div>
23
22
 
24
23
  <div>
25
24
  <!-- lastmod -->
26
25
  {% if page.last_modified_at %}
27
26
  <span>
28
- Updated
29
- {% include timeago.html date=page.last_modified_at class="lastmod" tooltip=true %}
27
+ {% include timeago.html date=page.last_modified_at
28
+ class="lastmod" prefix="Updated" tooltip=true %}
30
29
  </span>
31
30
  {% endif %}
32
31
 
@@ -521,6 +521,10 @@ footer {
521
521
 
522
522
  /* --- Effects classes --- */
523
523
 
524
+ .semi-bold {
525
+ font-weight: 600 !important;
526
+ }
527
+
524
528
  .loaded {
525
529
  display: block !important;
526
530
 
@@ -34,6 +34,7 @@
34
34
  }
35
35
 
36
36
  %heading {
37
+ color: var(--heading-color);
37
38
  font-weight: 400;
38
39
  font-family: 'Lato', 'Microsoft Yahei', sans-serif;
39
40
  }
@@ -15,6 +15,7 @@
15
15
 
16
16
  /* common color */
17
17
  --text-color: rgb(175, 176, 177);
18
+ --heading-color: #cccccc;
18
19
  --text-muted-color: rgb(107, 116, 124);
19
20
  --link-color: rgb(138, 180, 248);
20
21
  --link-underline-color: rgb(82, 108, 150);
@@ -68,7 +68,7 @@
68
68
 
69
69
  /* --- custom light colors --- */
70
70
  --highlight-bg-color: #f7f7f7;
71
- --highlighter-rouge-color: #353a3d;
71
+ --highlighter-rouge-color: #505050;
72
72
  --highlight-lineno-color: #c2c6cc;
73
73
  --highlight-lineno-border-color: #e9ecef;
74
74
  --inline-code-bg: #f3f3f3;
@@ -9,7 +9,8 @@
9
9
  --main-wrapper-bg: white;
10
10
  --main-border-color: #f3f3f3;
11
11
  --btn-border-color: #e9ecef;
12
- --text-color: #333333;
12
+ --text-color: #4a4a4a;
13
+ --heading-color: black;
13
14
  --blockquote-border-color: #eee;
14
15
  --blockquote-text-color: #9a9a9a;
15
16
  --link-color: #2a408e;
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * The styles for Jekyll theme Chirpy
3
3
  *
4
- * Chirpy v3.2.2 (https://github.com/cotes2020/jekyll-theme-chirpy)
4
+ * Chirpy v3.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy)
5
5
  * © 2019 Cotes Chung
6
6
  * MIT Licensed
7
7
  */
@@ -23,6 +23,10 @@
23
23
  padding-right: $pr;
24
24
  }
25
25
 
26
+ .timeago::before {
27
+ content: attr(prefix);
28
+ }
29
+
26
30
  #post-wrapper .post-meta {
27
31
  > div:nth-child(2) {
28
32
  > span:not(:first-child)::before {
@@ -5,24 +5,28 @@ layout: compress
5
5
  ---
6
6
 
7
7
  const include = [
8
+ /* --- CSS --- */
8
9
 
9
- /*--- CSS ---*/
10
10
  '{{ "/assets/css/style.css" | relative_url }}',
11
11
 
12
- /*--- Javascripts ---*/
12
+ /* --- Javascripts --- */
13
13
  '{{ "/assets/js/dist/home.min.js" | relative_url }}',
14
14
  '{{ "/assets/js/dist/page.min.js" | relative_url }}',
15
15
  '{{ "/assets/js/dist/post.min.js" | relative_url }}',
16
16
  '{{ "/assets/js/dist/categories.min.js" | relative_url }}',
17
+ '{{ "/assets/js/data/search.json" | relative_url }}',
18
+ '{{ "/app.js" | relative_url }}',
19
+ '{{ "/sw.js" | relative_url }}',
17
20
 
18
- /*--- HTML ---*/
19
-
20
- /* Tabs */
21
+ /* --- HTML --- */
22
+ '{{ "/index.html" | relative_url }}',
23
+ '{{ "/404.html" | relative_url }}',
21
24
  {% for tab in site.tabs %}
22
25
  '{{ tab.url }}',
23
26
  {% endfor %}
24
27
 
25
- /*--- Icons ---*/
28
+
29
+ /* --- Icons --- */
26
30
 
27
31
  {%- capture icon_url -%}
28
32
  {{ "/assets/img/favicons" | relative_url }}
@@ -45,15 +49,7 @@ const include = [
45
49
  '{{ icon_url }}/favicon-16x16.png',
46
50
  '{{ icon_url }}/ms-icon-144x144.png',
47
51
  '{{ icon_url }}/manifest.json',
48
- '{{ icon_url }}/browserconfig.xml',
49
-
50
- /*--- Others ---*/
51
-
52
- '{{ "/assets/js/data/search.json" | relative_url }}',
53
- '{{ "/404.html" | relative_url }}',
54
-
55
- '{{ "/app.js" | relative_url }}',
56
- '{{ "/sw.js" | relative_url }}'
52
+ '{{ icon_url }}/browserconfig.xml'
57
53
  ];
58
54
 
59
55
  const exclude = [
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Chirpy v3.2.2 (https://github.com/cotes2020/jekyll-theme-chirpy/)
2
+ * Chirpy v3.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
3
3
  * © 2019 Cotes Chung
4
4
  * MIT Licensed
5
5
  */
6
- function copyLink(e){e&&0!==e.length||(e=window.location.href);const o=$("<input>");$("body").append(o),o.val(e).select(),document.execCommand("copy"),o.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{$(this).scrollTop()>50&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),o=$("#search-trigger"),s=$("#search-cancel"),t=$("#search-cleaner"),a=$("#main"),l=$("#topbar-title"),n=$("#search-wrapper"),d=$("#search-result-wrapper"),r=$("#search-results"),c=$("#search-input"),i=$("#search-hints"),f=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset:()=>e}}(),u={on(){e.addClass("unloaded"),l.addClass("unloaded"),o.addClass("unloaded"),n.addClass("d-flex"),s.addClass("loaded")},off(){s.removeClass("loaded"),n.removeClass("d-flex"),e.removeClass("unloaded"),l.removeClass("unloaded"),o.removeClass("unloaded")}},p=function(){let e=!1;return{on(){e||(f.block(),d.removeClass("unloaded"),a.addClass("unloaded"),e=!0)},off(){e&&(r.empty(),i.hasClass("unloaded")&&i.removeClass("unloaded"),d.addClass("unloaded"),t.removeClass("visible"),a.removeClass("unloaded"),f.release(),c.val(""),e=!1)},isVisible:()=>e}}();function h(){return s.hasClass("loaded")}o.click(function(){u.on(),p.on(),c.focus()}),s.click(function(){u.off(),p.off()}),c.focus(function(){n.addClass("input-focus")}),c.focusout(function(){n.removeClass("input-focus")}),c.on("keyup",function(e){8===e.keyCode&&""===c.val()?h()?i.removeClass("unloaded"):p.off():""!==c.val()&&(p.on(),t.hasClass("visible")||t.addClass("visible"),h()&&i.addClass("unloaded"))}),t.on("click",function(){c.val(""),h()?(i.removeClass("unloaded"),r.empty()):p.off(),c.focus(),t.removeClass("visible")})}),$(function(){const e=function(){let e=!1;const o=$("body");return{toggle(){!1===e?o.attr("sidebar-display",""):o.removeAttr("sidebar-display"),e=!e}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const e=$("#topbar-wrapper"),o=$("#toc-wrapper"),s=$(".access"),t=$("#search-input");let a,l=0;const n=5,d=e.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(a=!0)}),setInterval(function(){a&&(!function(){var a=$(this).scrollTop();Math.abs(l-a)<=n||(a>l&&a>d?(e.removeClass("topbar-down").addClass("topbar-up"),o.length>0&&o.removeClass("topbar-down"),s.length>0&&s.removeClass("topbar-down"),t.is(":focus")&&t.blur()):a+$(window).height()<$(document).height()&&(e.removeClass("topbar-up").addClass("topbar-down"),o.length>0&&o.addClass("topbar-down"),s.length>0&&s.addClass("topbar-down")),l=a)}(),a=!1)},250)}),$(function(){const e=$("#topbar-title"),o=$("div.post>h1"),s=e.text().trim();let t=o.length>0?o.text().trim():$("h1").text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(t)&&(t=t.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){if($("#post-list").length||o.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)return!1;$(this).scrollTop()>=95?e.text()!==t&&e.text(t):e.text()!==s&&e.text(s)}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){const e=$(".collapse");e.on("hide.bs.collapse",function(){const e="h_"+$(this).attr("id").substring("l_".length);e&&($(`#${e} .far.fa-folder-open`).attr("class","far fa-folder fa-fw"),$(`#${e} i.fas`).addClass("rotate"),$(`#${e}`).removeClass("hide-border-bottom"))}),e.on("show.bs.collapse",function(){const e="h_"+$(this).attr("id").substring("l_".length);e&&($(`#${e} .far.fa-folder`).attr("class","far fa-folder-open fa-fw"),$(`#${e} i.fas`).removeClass("rotate"),$(`#${e}`).addClass("hide-border-bottom"))})});
6
+ function copyLink(e){e&&0!==e.length||(e=window.location.href);const o=$("<input>");$("body").append(o),o.val(e).select(),document.execCommand("copy"),o.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{50<$(this).scrollTop()&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),o=$("#search-trigger"),t=$("#search-cancel"),s=$("#search-cleaner"),a=$("#main"),l=$("#topbar-title"),n=$("#search-wrapper"),r=$("#search-result-wrapper"),d=$("#search-results"),c=$("#search-input"),i=$("#search-hints"),u=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset(){return e}}}(),f={on(){e.addClass("unloaded"),l.addClass("unloaded"),o.addClass("unloaded"),n.addClass("d-flex"),t.addClass("loaded")},off(){t.removeClass("loaded"),n.removeClass("d-flex"),e.removeClass("unloaded"),l.removeClass("unloaded"),o.removeClass("unloaded")}},p=function(){let e=!1;return{on(){e||(u.block(),r.removeClass("unloaded"),a.addClass("unloaded"),e=!0)},off(){e&&(d.empty(),i.hasClass("unloaded")&&i.removeClass("unloaded"),r.addClass("unloaded"),s.removeClass("visible"),a.removeClass("unloaded"),u.release(),c.val(""),e=!1)},isVisible(){return e}}}();function h(){return t.hasClass("loaded")}o.click(function(){f.on(),p.on(),c.focus()}),t.click(function(){f.off(),p.off()}),c.focus(function(){n.addClass("input-focus")}),c.focusout(function(){n.removeClass("input-focus")}),c.on("keyup",function(e){8===e.keyCode&&""===c.val()?h()?i.removeClass("unloaded"):p.off():""!==c.val()&&(p.on(),s.hasClass("visible")||s.addClass("visible"),h()&&i.addClass("unloaded"))}),s.on("click",function(){c.val(""),h()?(i.removeClass("unloaded"),d.empty()):p.off(),c.focus(),s.removeClass("visible")})}),$(function(){var e=function(){const e="sidebar-display";let o=!1;const t=$("body");return{toggle(){!1===o?t.attr(e,""):t.removeAttr(e),o=!o}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const o=$("#topbar-wrapper"),t=$("#toc-wrapper"),s=$(".access"),a=$("#search-input");let l,n=0;const r=o.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(l=!0)}),setInterval(function(){l&&(function(){var e=$(this).scrollTop();Math.abs(n-e)<=5||(e>n&&e>r?(o.removeClass("topbar-down").addClass("topbar-up"),0<t.length&&t.removeClass("topbar-down"),0<s.length&&s.removeClass("topbar-down"),a.is(":focus")&&a.blur()):e+$(window).height()<$(document).height()&&(o.removeClass("topbar-up").addClass("topbar-down"),0<t.length&&t.addClass("topbar-down"),0<s.length&&s.addClass("topbar-down")),n=e)}(),l=!1)},250)}),$(function(){const e=$("#topbar-title"),o=$("div.post>h1"),t=e.text().trim();let s=(0<o.length?o:$("h1")).text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(s)&&(s=s.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){return!($("#post-list").length||o.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)&&void(95<=$(this).scrollTop()?e.text()!==s&&e.text(s):e.text()!==t&&e.text(t))}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){const e=$(".collapse");e.on("hide.bs.collapse",function(){var e="h_"+$(this).attr("id").substring("l_".length);e&&($(`#${e} .far.fa-folder-open`).attr("class","far fa-folder fa-fw"),$(`#${e} i.fas`).addClass("rotate"),$(`#${e}`).removeClass("hide-border-bottom"))}),e.on("show.bs.collapse",function(){var e="h_"+$(this).attr("id").substring("l_".length);e&&($(`#${e} .far.fa-folder`).attr("class","far fa-folder-open fa-fw"),$(`#${e} i.fas`).removeClass("rotate"),$(`#${e}`).addClass("hide-border-bottom"))})});
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Chirpy v3.2.2 (https://github.com/cotes2020/jekyll-theme-chirpy/)
2
+ * Chirpy v3.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
3
3
  * © 2019 Cotes Chung
4
4
  * MIT Licensed
5
5
  */
6
- function copyLink(e){e&&0!==e.length||(e=window.location.href);const t=$("<input>");$("body").append(t),t.val(e).select(),document.execCommand("copy"),t.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{$(this).scrollTop()>50&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),t=$("#search-trigger"),o=$("#search-cancel"),a=$("#search-cleaner"),s=$("#main"),l=$("#topbar-title"),n=$("#search-wrapper"),r=$("#search-result-wrapper"),i=$("#search-results"),c=$("#search-input"),d=$("#search-hints"),u=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset:()=>e}}(),h={on(){e.addClass("unloaded"),l.addClass("unloaded"),t.addClass("unloaded"),n.addClass("d-flex"),o.addClass("loaded")},off(){o.removeClass("loaded"),n.removeClass("d-flex"),e.removeClass("unloaded"),l.removeClass("unloaded"),t.removeClass("unloaded")}},f=function(){let e=!1;return{on(){e||(u.block(),r.removeClass("unloaded"),s.addClass("unloaded"),e=!0)},off(){e&&(i.empty(),d.hasClass("unloaded")&&d.removeClass("unloaded"),r.addClass("unloaded"),a.removeClass("visible"),s.removeClass("unloaded"),u.release(),c.val(""),e=!1)},isVisible:()=>e}}();function p(){return o.hasClass("loaded")}t.click(function(){h.on(),f.on(),c.focus()}),o.click(function(){h.off(),f.off()}),c.focus(function(){n.addClass("input-focus")}),c.focusout(function(){n.removeClass("input-focus")}),c.on("keyup",function(e){8===e.keyCode&&""===c.val()?p()?d.removeClass("unloaded"):f.off():""!==c.val()&&(f.on(),a.hasClass("visible")||a.addClass("visible"),p()&&d.addClass("unloaded"))}),a.on("click",function(){c.val(""),p()?(d.removeClass("unloaded"),i.empty()):f.off(),c.focus(),a.removeClass("visible")})}),$(function(){const e=function(){let e=!1;const t=$("body");return{toggle(){!1===e?t.attr("sidebar-display",""):t.removeAttr("sidebar-display"),e=!e}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const e=$("#topbar-wrapper"),t=$("#toc-wrapper"),o=$(".access"),a=$("#search-input");let s,l=0;const n=5,r=e.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(s=!0)}),setInterval(function(){s&&(!function(){var s=$(this).scrollTop();Math.abs(l-s)<=n||(s>l&&s>r?(e.removeClass("topbar-down").addClass("topbar-up"),t.length>0&&t.removeClass("topbar-down"),o.length>0&&o.removeClass("topbar-down"),a.is(":focus")&&a.blur()):s+$(window).height()<$(document).height()&&(e.removeClass("topbar-up").addClass("topbar-down"),t.length>0&&t.addClass("topbar-down"),o.length>0&&o.addClass("topbar-down")),l=s)}(),s=!1)},250)}),$(function(){const e=$("#topbar-title"),t=$("div.post>h1"),o=e.text().trim();let a=t.length>0?t.text().trim():$("h1").text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(a)&&(a=a.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){if($("#post-list").length||t.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)return!1;$(this).scrollTop()>=95?e.text()!==a&&e.text(a):e.text()!==o&&e.text(o)}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){let e=$(".timeago").length,t=void 0;function o(){return $(".timeago").each(function(){if($(this).children("i").length>0){$(this).text();let t=$(this).hasClass("lastmod"),o=$(this).children("i"),a=o.text();$(this).text(function(t,o){let a=new Date,s=new Date(t);if(s.getFullYear()!==a.getFullYear())return e-=1,s.toLocaleString("en-US",{year:"numeric",month:"short",day:"numeric"});if(s.getMonth()!==a.getMonth())return e-=1,s.toLocaleString("en-US",{month:"short",day:"numeric"});let l=Math.floor((a-s)/1e3),n=Math.floor(l/86400);if(n>=1)return e-=1,n+" day"+(n>1?"s":"")+" ago";let r=Math.floor(l/3600);if(r>=1)return r+" hour"+(r>1?"s":"")+" ago";let i=Math.floor(l/60);return i>=1?i+" minute"+(i>1?"s":"")+" ago":(o?"just":"Just")+" now"}(a,t)),$(this).append(o)}}),0===e&&void 0!==t&&clearInterval(t),e}0!==e&&o()>0&&(t=setInterval(o,6e4))});
6
+ function copyLink(e){e&&0!==e.length||(e=window.location.href);const o=$("<input>");$("body").append(o),o.val(e).select(),document.execCommand("copy"),o.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{50<$(this).scrollTop()&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),o=$("#search-trigger"),t=$("#search-cancel"),a=$("#search-cleaner"),s=$("#main"),n=$("#topbar-title"),l=$("#search-wrapper"),r=$("#search-result-wrapper"),i=$("#search-results"),c=$("#search-input"),d=$("#search-hints"),u=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset(){return e}}}(),h={on(){e.addClass("unloaded"),n.addClass("unloaded"),o.addClass("unloaded"),l.addClass("d-flex"),t.addClass("loaded")},off(){t.removeClass("loaded"),l.removeClass("d-flex"),e.removeClass("unloaded"),n.removeClass("unloaded"),o.removeClass("unloaded")}},f=function(){let e=!1;return{on(){e||(u.block(),r.removeClass("unloaded"),s.addClass("unloaded"),e=!0)},off(){e&&(i.empty(),d.hasClass("unloaded")&&d.removeClass("unloaded"),r.addClass("unloaded"),a.removeClass("visible"),s.removeClass("unloaded"),u.release(),c.val(""),e=!1)},isVisible(){return e}}}();function p(){return t.hasClass("loaded")}o.click(function(){h.on(),f.on(),c.focus()}),t.click(function(){h.off(),f.off()}),c.focus(function(){l.addClass("input-focus")}),c.focusout(function(){l.removeClass("input-focus")}),c.on("keyup",function(e){8===e.keyCode&&""===c.val()?p()?d.removeClass("unloaded"):f.off():""!==c.val()&&(f.on(),a.hasClass("visible")||a.addClass("visible"),p()&&d.addClass("unloaded"))}),a.on("click",function(){c.val(""),p()?(d.removeClass("unloaded"),i.empty()):f.off(),c.focus(),a.removeClass("visible")})}),$(function(){var e=function(){const e="sidebar-display";let o=!1;const t=$("body");return{toggle(){!1===o?t.attr(e,""):t.removeAttr(e),o=!o}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const o=$("#topbar-wrapper"),t=$("#toc-wrapper"),a=$(".access"),s=$("#search-input");let n,l=0;const r=o.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(n=!0)}),setInterval(function(){n&&(function(){var e=$(this).scrollTop();Math.abs(l-e)<=5||(e>l&&e>r?(o.removeClass("topbar-down").addClass("topbar-up"),0<t.length&&t.removeClass("topbar-down"),0<a.length&&a.removeClass("topbar-down"),s.is(":focus")&&s.blur()):e+$(window).height()<$(document).height()&&(o.removeClass("topbar-up").addClass("topbar-down"),0<t.length&&t.addClass("topbar-down"),0<a.length&&a.addClass("topbar-down")),l=e)}(),n=!1)},250)}),$(function(){const e=$("#topbar-title"),o=$("div.post>h1"),t=e.text().trim();let a=(0<o.length?o:$("h1")).text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(a)&&(a=a.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){return!($("#post-list").length||o.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)&&void(95<=$(this).scrollTop()?e.text()!==a&&e.text(a):e.text()!==t&&e.text(t))}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){let s=$(".timeago").length,e=void 0;function o(){return $(".timeago").each(function(){if(0<$(this).children("i").length){let e=$(this).children("i");var o=e.text();$(this).text(function(e,o){let t=new Date,a=new Date(e);return e=void 0!==o?`${o} `:"",a.getFullYear()!==t.getFullYear()?(--s,e+a.toLocaleString("en-US",{year:"numeric",month:"short",day:"numeric"})):a.getMonth()!==t.getMonth()?(--s,e+a.toLocaleString("en-US",{month:"short",day:"numeric"})):(o=Math.floor((t-a)/1e3),1<=(e=Math.floor(o/86400))?(--s,e+" day"+(1<e?"s":"")+" ago"):1<=(e=Math.floor(o/3600))?e+" hour"+(1<e?"s":"")+" ago":1<=(o=Math.floor(o/60))?o+" minute"+(1<o?"s":"")+" ago":"just now")}(o,$(this).attr("prep"))),$(this).append(e)}}),0===s&&void 0!==e&&clearInterval(e),s}0!==s&&0<o()&&(e=setInterval(o,6e4))});
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Chirpy v3.2.2 (https://github.com/cotes2020/jekyll-theme-chirpy/)
2
+ * Chirpy v3.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
3
3
  * © 2019 Cotes Chung
4
4
  * MIT Licensed
5
5
  */
6
- function copyLink(e){e&&0!==e.length||(e=window.location.href);const t=$("<input>");$("body").append(t),t.val(e).select(),document.execCommand("copy"),t.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{$(this).scrollTop()>50&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),t=$("#search-trigger"),o=$("#search-cancel"),s=$("#search-cleaner"),a=$("#main"),l=$("#topbar-title"),n=$("#search-wrapper"),c=$("#search-result-wrapper"),r=$("#search-results"),i=$("#search-input"),d=$("#search-hints"),u=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset:()=>e}}(),f={on(){e.addClass("unloaded"),l.addClass("unloaded"),t.addClass("unloaded"),n.addClass("d-flex"),o.addClass("loaded")},off(){o.removeClass("loaded"),n.removeClass("d-flex"),e.removeClass("unloaded"),l.removeClass("unloaded"),t.removeClass("unloaded")}},p=function(){let e=!1;return{on(){e||(u.block(),c.removeClass("unloaded"),a.addClass("unloaded"),e=!0)},off(){e&&(r.empty(),d.hasClass("unloaded")&&d.removeClass("unloaded"),c.addClass("unloaded"),s.removeClass("visible"),a.removeClass("unloaded"),u.release(),i.val(""),e=!1)},isVisible:()=>e}}();function h(){return o.hasClass("loaded")}t.click(function(){f.on(),p.on(),i.focus()}),o.click(function(){f.off(),p.off()}),i.focus(function(){n.addClass("input-focus")}),i.focusout(function(){n.removeClass("input-focus")}),i.on("keyup",function(e){8===e.keyCode&&""===i.val()?h()?d.removeClass("unloaded"):p.off():""!==i.val()&&(p.on(),s.hasClass("visible")||s.addClass("visible"),h()&&d.addClass("unloaded"))}),s.on("click",function(){i.val(""),h()?(d.removeClass("unloaded"),r.empty()):p.off(),i.focus(),s.removeClass("visible")})}),$(function(){const e=function(){let e=!1;const t=$("body");return{toggle(){!1===e?t.attr("sidebar-display",""):t.removeAttr("sidebar-display"),e=!e}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const e=$("#topbar-wrapper"),t=$("#toc-wrapper"),o=$(".access"),s=$("#search-input");let a,l=0;const n=5,c=e.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(a=!0)}),setInterval(function(){a&&(!function(){var a=$(this).scrollTop();Math.abs(l-a)<=n||(a>l&&a>c?(e.removeClass("topbar-down").addClass("topbar-up"),t.length>0&&t.removeClass("topbar-down"),o.length>0&&o.removeClass("topbar-down"),s.is(":focus")&&s.blur()):a+$(window).height()<$(document).height()&&(e.removeClass("topbar-up").addClass("topbar-down"),t.length>0&&t.addClass("topbar-down"),o.length>0&&o.addClass("topbar-down")),l=a)}(),a=!1)},250)}),$(function(){const e=$("#topbar-title"),t=$("div.post>h1"),o=e.text().trim();let s=t.length>0?t.text().trim():$("h1").text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(s)&&(s=s.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){if($("#post-list").length||t.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)return!1;$(this).scrollTop()>=95?e.text()!==s&&e.text(s):e.text()!==o&&e.text(o)}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){$("a[href*='#']").not("[href='#']").not("[href='#0']").click(function(e){if(this.pathname.replace(/^\//,"")===location.pathname.replace(/^\//,"")&&location.hostname===this.hostname){const t=16,o=decodeURI(this.hash);let s=RegExp(/^#fnref:/).test(o),a=RegExp(/^#fn:/).test(o),l=o.includes(":")?o.replace(/\:/,"\\:"):o,n=$(l);if(n.length){e.preventDefault(),history.pushState&&history.pushState(null,null,o);let l=$(this).offset().top,c=n.offset().top;const r=c<l,i=$("#topbar-wrapper").outerHeight();r&&s&&(c-=i+t/2),$("html,body").animate({scrollTop:c},800,()=>{const e=$(n);e.focus();if($("[scroll-focus=true]").length&&$("[scroll-focus=true]").attr("scroll-focus",!1),$(":target").length&&$(":target").attr("scroll-focus",!1),(a||s)&&e.attr("scroll-focus",!0),e.is(":focus"))return!1;e.attr("tabindex","-1"),e.focus()})}}})});
6
+ function copyLink(e){e&&0!==e.length||(e=window.location.href);const t=$("<input>");$("body").append(t),t.val(e).select(),document.execCommand("copy"),t.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{50<$(this).scrollTop()&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),t=$("#search-trigger"),o=$("#search-cancel"),s=$("#search-cleaner"),a=$("#main"),l=$("#topbar-title"),n=$("#search-wrapper"),r=$("#search-result-wrapper"),c=$("#search-results"),i=$("#search-input"),d=$("#search-hints"),u=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset(){return e}}}(),p={on(){e.addClass("unloaded"),l.addClass("unloaded"),t.addClass("unloaded"),n.addClass("d-flex"),o.addClass("loaded")},off(){o.removeClass("loaded"),n.removeClass("d-flex"),e.removeClass("unloaded"),l.removeClass("unloaded"),t.removeClass("unloaded")}},f=function(){let e=!1;return{on(){e||(u.block(),r.removeClass("unloaded"),a.addClass("unloaded"),e=!0)},off(){e&&(c.empty(),d.hasClass("unloaded")&&d.removeClass("unloaded"),r.addClass("unloaded"),s.removeClass("visible"),a.removeClass("unloaded"),u.release(),i.val(""),e=!1)},isVisible(){return e}}}();function h(){return o.hasClass("loaded")}t.click(function(){p.on(),f.on(),i.focus()}),o.click(function(){p.off(),f.off()}),i.focus(function(){n.addClass("input-focus")}),i.focusout(function(){n.removeClass("input-focus")}),i.on("keyup",function(e){8===e.keyCode&&""===i.val()?h()?d.removeClass("unloaded"):f.off():""!==i.val()&&(f.on(),s.hasClass("visible")||s.addClass("visible"),h()&&d.addClass("unloaded"))}),s.on("click",function(){i.val(""),h()?(d.removeClass("unloaded"),c.empty()):f.off(),i.focus(),s.removeClass("visible")})}),$(function(){var e=function(){const e="sidebar-display";let t=!1;const o=$("body");return{toggle(){!1===t?o.attr(e,""):o.removeAttr(e),t=!t}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const t=$("#topbar-wrapper"),o=$("#toc-wrapper"),s=$(".access"),a=$("#search-input");let l,n=0;const r=t.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(l=!0)}),setInterval(function(){l&&(function(){var e=$(this).scrollTop();Math.abs(n-e)<=5||(e>n&&e>r?(t.removeClass("topbar-down").addClass("topbar-up"),0<o.length&&o.removeClass("topbar-down"),0<s.length&&s.removeClass("topbar-down"),a.is(":focus")&&a.blur()):e+$(window).height()<$(document).height()&&(t.removeClass("topbar-up").addClass("topbar-down"),0<o.length&&o.addClass("topbar-down"),0<s.length&&s.addClass("topbar-down")),n=e)}(),l=!1)},250)}),$(function(){const e=$("#topbar-title"),t=$("div.post>h1"),o=e.text().trim();let s=(0<t.length?t:$("h1")).text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(s)&&(s=s.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){return!($("#post-list").length||t.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)&&void(95<=$(this).scrollTop()?e.text()!==s&&e.text(s):e.text()!==o&&e.text(o))}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){$("a[href*='#']").not("[href='#']").not("[href='#0']").click(function(t){if(this.pathname.replace(/^\//,"")===location.pathname.replace(/^\//,"")&&location.hostname===this.hostname){const n=decodeURI(this.hash);let o=RegExp(/^#fnref:/).test(n),s=RegExp(/^#fn:/).test(n);var l=n.includes(":")?n.replace(/\:/,"\\:"):n;let a=$(l);if(a.length){t.preventDefault(),history.pushState&&history.pushState(null,null,n);l=$(this).offset().top;let e=a.offset().top;t=e<l,l=$("#topbar-wrapper").outerHeight();t&&o&&(e-=l+8),$("html,body").animate({scrollTop:e},800,()=>{const e=$(a);e.focus();var t="scroll-focus";if($(`[${t}=true]`).length&&$(`[${t}=true]`).attr(t,!1),$(":target").length&&$(":target").attr(t,!1),(s||o)&&e.attr(t,!0),e.is(":focus"))return!1;e.attr("tabindex","-1"),e.focus()})}}})});
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Chirpy v3.2.2 (https://github.com/cotes2020/jekyll-theme-chirpy/)
2
+ * Chirpy v3.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
3
3
  * © 2019 Cotes Chung
4
4
  * MIT Licensed
5
5
  */
6
- function copyLink(e){e&&0!==e.length||(e=window.location.href);const t=$("<input>");$("body").append(t),t.val(e).select(),document.execCommand("copy"),t.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{$(this).scrollTop()>50&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),t=$("#search-trigger"),o=$("#search-cancel"),s=$("#search-cleaner"),a=$("#main"),l=$("#topbar-title"),n=$("#search-wrapper"),r=$("#search-result-wrapper"),i=$("#search-results"),c=$("#search-input"),d=$("#search-hints"),u=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset:()=>e}}(),h={on(){e.addClass("unloaded"),l.addClass("unloaded"),t.addClass("unloaded"),n.addClass("d-flex"),o.addClass("loaded")},off(){o.removeClass("loaded"),n.removeClass("d-flex"),e.removeClass("unloaded"),l.removeClass("unloaded"),t.removeClass("unloaded")}},f=function(){let e=!1;return{on(){e||(u.block(),r.removeClass("unloaded"),a.addClass("unloaded"),e=!0)},off(){e&&(i.empty(),d.hasClass("unloaded")&&d.removeClass("unloaded"),r.addClass("unloaded"),s.removeClass("visible"),a.removeClass("unloaded"),u.release(),c.val(""),e=!1)},isVisible:()=>e}}();function p(){return o.hasClass("loaded")}t.click(function(){h.on(),f.on(),c.focus()}),o.click(function(){h.off(),f.off()}),c.focus(function(){n.addClass("input-focus")}),c.focusout(function(){n.removeClass("input-focus")}),c.on("keyup",function(e){8===e.keyCode&&""===c.val()?p()?d.removeClass("unloaded"):f.off():""!==c.val()&&(f.on(),s.hasClass("visible")||s.addClass("visible"),p()&&d.addClass("unloaded"))}),s.on("click",function(){c.val(""),p()?(d.removeClass("unloaded"),i.empty()):f.off(),c.focus(),s.removeClass("visible")})}),$(function(){const e=function(){let e=!1;const t=$("body");return{toggle(){!1===e?t.attr("sidebar-display",""):t.removeAttr("sidebar-display"),e=!e}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const e=$("#topbar-wrapper"),t=$("#toc-wrapper"),o=$(".access"),s=$("#search-input");let a,l=0;const n=5,r=e.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(a=!0)}),setInterval(function(){a&&(!function(){var a=$(this).scrollTop();Math.abs(l-a)<=n||(a>l&&a>r?(e.removeClass("topbar-down").addClass("topbar-up"),t.length>0&&t.removeClass("topbar-down"),o.length>0&&o.removeClass("topbar-down"),s.is(":focus")&&s.blur()):a+$(window).height()<$(document).height()&&(e.removeClass("topbar-up").addClass("topbar-down"),t.length>0&&t.addClass("topbar-down"),o.length>0&&o.addClass("topbar-down")),l=a)}(),a=!1)},250)}),$(function(){const e=$("#topbar-title"),t=$("div.post>h1"),o=e.text().trim();let s=t.length>0?t.text().trim():$("h1").text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(s)&&(s=s.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){if($("#post-list").length||t.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)return!1;$(this).scrollTop()>=95?e.text()!==s&&e.text(s):e.text()!==o&&e.text(o)}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){let e=$(".timeago").length,t=void 0;function o(){return $(".timeago").each(function(){if($(this).children("i").length>0){$(this).text();let t=$(this).hasClass("lastmod"),o=$(this).children("i"),s=o.text();$(this).text(function(t,o){let s=new Date,a=new Date(t);if(a.getFullYear()!==s.getFullYear())return e-=1,a.toLocaleString("en-US",{year:"numeric",month:"short",day:"numeric"});if(a.getMonth()!==s.getMonth())return e-=1,a.toLocaleString("en-US",{month:"short",day:"numeric"});let l=Math.floor((s-a)/1e3),n=Math.floor(l/86400);if(n>=1)return e-=1,n+" day"+(n>1?"s":"")+" ago";let r=Math.floor(l/3600);if(r>=1)return r+" hour"+(r>1?"s":"")+" ago";let i=Math.floor(l/60);return i>=1?i+" minute"+(i>1?"s":"")+" ago":(o?"just":"Just")+" now"}(s,t)),$(this).append(o)}}),0===e&&void 0!==t&&clearInterval(t),e}0!==e&&o()>0&&(t=setInterval(o,6e4))}),$(function(){$("a:has(img)").addClass("img-hyperlink")}),$(function(){const e=new RegExp("^language-([a-z])+$");$("div[class^=language-").each(function(){$(this).attr("class").split(" ").forEach(t=>{if(e.test(t)){let e=t.substring("language-".length);$(this).attr("lang",`${e}`)}})})}),$(function(){$("a[href*='#']").not("[href='#']").not("[href='#0']").click(function(e){if(this.pathname.replace(/^\//,"")===location.pathname.replace(/^\//,"")&&location.hostname===this.hostname){const t=16,o=decodeURI(this.hash);let s=RegExp(/^#fnref:/).test(o),a=RegExp(/^#fn:/).test(o),l=o.includes(":")?o.replace(/\:/,"\\:"):o,n=$(l);if(n.length){e.preventDefault(),history.pushState&&history.pushState(null,null,o);let l=$(this).offset().top,r=n.offset().top;const i=r<l,c=$("#topbar-wrapper").outerHeight();i&&s&&(r-=c+t/2),$("html,body").animate({scrollTop:r},800,()=>{const e=$(n);e.focus();if($("[scroll-focus=true]").length&&$("[scroll-focus=true]").attr("scroll-focus",!1),$(":target").length&&$(":target").attr("scroll-focus",!1),(a||s)&&e.attr("scroll-focus",!0),e.is(":focus"))return!1;e.attr("tabindex","-1"),e.focus()})}}})});
6
+ function copyLink(e){e&&0!==e.length||(e=window.location.href);const t=$("<input>");$("body").append(t),t.val(e).select(),document.execCommand("copy"),t.remove(),alert("Link copied successfully!")}$(function(){$(window).scroll(()=>{50<$(this).scrollTop()&&"none"===$("#sidebar-trigger").css("display")?$("#back-to-top").fadeIn():$("#back-to-top").fadeOut()}),$("#back-to-top").click(()=>($("body,html").animate({scrollTop:0},800),!1))}),$(function(){$("input[type=checkbox]").addClass("unloaded"),$("input[type=checkbox][checked]").before('<i class="fas fa-check-circle checked"></i>'),$("input[type=checkbox]:not([checked])").before('<i class="far fa-circle"></i>')}),$(function(){const e=$("#sidebar-trigger"),t=$("#search-trigger"),o=$("#search-cancel"),a=$("#search-cleaner"),s=$("#main"),n=$("#topbar-title"),l=$("#search-wrapper"),r=$("#search-result-wrapper"),i=$("#search-results"),c=$("#search-input"),d=$("#search-hints"),u=function(){let e=0;return{block(){e=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(e)},getOffset(){return e}}}(),h={on(){e.addClass("unloaded"),n.addClass("unloaded"),t.addClass("unloaded"),l.addClass("d-flex"),o.addClass("loaded")},off(){o.removeClass("loaded"),l.removeClass("d-flex"),e.removeClass("unloaded"),n.removeClass("unloaded"),t.removeClass("unloaded")}},f=function(){let e=!1;return{on(){e||(u.block(),r.removeClass("unloaded"),s.addClass("unloaded"),e=!0)},off(){e&&(i.empty(),d.hasClass("unloaded")&&d.removeClass("unloaded"),r.addClass("unloaded"),a.removeClass("visible"),s.removeClass("unloaded"),u.release(),c.val(""),e=!1)},isVisible(){return e}}}();function p(){return o.hasClass("loaded")}t.click(function(){h.on(),f.on(),c.focus()}),o.click(function(){h.off(),f.off()}),c.focus(function(){l.addClass("input-focus")}),c.focusout(function(){l.removeClass("input-focus")}),c.on("keyup",function(e){8===e.keyCode&&""===c.val()?p()?d.removeClass("unloaded"):f.off():""!==c.val()&&(f.on(),a.hasClass("visible")||a.addClass("visible"),p()&&d.addClass("unloaded"))}),a.on("click",function(){c.val(""),p()?(d.removeClass("unloaded"),i.empty()):f.off(),c.focus(),a.removeClass("visible")})}),$(function(){var e=function(){const e="sidebar-display";let t=!1;const o=$("body");return{toggle(){!1===t?o.attr(e,""):o.removeAttr(e),t=!t}}}();$("#sidebar-trigger").click(e.toggle),$("#mask").click(e.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const t=$("#topbar-wrapper"),o=$("#toc-wrapper"),a=$(".access"),s=$("#search-input");let n,l=0;const r=t.outerHeight();$(window).scroll(function(e){$("#topbar-title").is(":hidden")&&(n=!0)}),setInterval(function(){n&&(function(){var e=$(this).scrollTop();Math.abs(l-e)<=5||(e>l&&e>r?(t.removeClass("topbar-down").addClass("topbar-up"),0<o.length&&o.removeClass("topbar-down"),0<a.length&&a.removeClass("topbar-down"),s.is(":focus")&&s.blur()):e+$(window).height()<$(document).height()&&(t.removeClass("topbar-up").addClass("topbar-down"),0<o.length&&o.addClass("topbar-down"),0<a.length&&a.addClass("topbar-down")),l=e)}(),n=!1)},250)}),$(function(){const e=$("#topbar-title"),t=$("div.post>h1"),o=e.text().trim();let a=(0<t.length?t:$("h1")).text().trim();($("#page-category").length||$("#page-tag").length)&&/\s/.test(a)&&(a=a.replace(/[0-9]/g,"").trim()),$(window).scroll(function(){return!($("#post-list").length||t.is(":hidden")||e.is(":hidden")||$("#sidebar.sidebar-expand").length)&&void(95<=$(this).scrollTop()?e.text()!==a&&e.text(a):e.text()!==o&&e.text(o))}),e.click(function(){$("body,html").animate({scrollTop:0},800)})}),$(function(){let s=$(".timeago").length,e=void 0;function t(){return $(".timeago").each(function(){if(0<$(this).children("i").length){let e=$(this).children("i");var t=e.text();$(this).text(function(e,t){let o=new Date,a=new Date(e);return e=void 0!==t?`${t} `:"",a.getFullYear()!==o.getFullYear()?(--s,e+a.toLocaleString("en-US",{year:"numeric",month:"short",day:"numeric"})):a.getMonth()!==o.getMonth()?(--s,e+a.toLocaleString("en-US",{month:"short",day:"numeric"})):(t=Math.floor((o-a)/1e3),1<=(e=Math.floor(t/86400))?(--s,e+" day"+(1<e?"s":"")+" ago"):1<=(e=Math.floor(t/3600))?e+" hour"+(1<e?"s":"")+" ago":1<=(t=Math.floor(t/60))?t+" minute"+(1<t?"s":"")+" ago":"just now")}(t,$(this).attr("prep"))),$(this).append(e)}}),0===s&&void 0!==e&&clearInterval(e),s}0!==s&&0<t()&&(e=setInterval(t,6e4))}),$(function(){$("a:has(img)").addClass("img-hyperlink")}),$(function(){const t="language-",o=new RegExp(`^${t}([a-z])+$`);$(`div[class^=${t}`).each(function(){let e=$(this).attr("class").split(" ");e.forEach(e=>{o.test(e)&&(e=e.substring(t.length),$(this).attr("lang",`${e}`))})})}),$(function(){$("a[href*='#']").not("[href='#']").not("[href='#0']").click(function(t){if(this.pathname.replace(/^\//,"")===location.pathname.replace(/^\//,"")&&location.hostname===this.hostname){const l=decodeURI(this.hash);let o=RegExp(/^#fnref:/).test(l),a=RegExp(/^#fn:/).test(l);var n=l.includes(":")?l.replace(/\:/,"\\:"):l;let s=$(n);if(s.length){t.preventDefault(),history.pushState&&history.pushState(null,null,l);n=$(this).offset().top;let e=s.offset().top;t=e<n,n=$("#topbar-wrapper").outerHeight();t&&o&&(e-=n+8),$("html,body").animate({scrollTop:e},800,()=>{const e=$(s);e.focus();var t="scroll-focus";if($(`[${t}=true]`).length&&$(`[${t}=true]`).attr(t,!1),$(":target").length&&$(":target").attr(t,!1),(a||o)&&e.attr(t,!0),e.is(":focus"))return!1;e.attr("tabindex","-1"),e.focus()})}}})});
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Chirpy v3.2.2 (https://github.com/cotes2020/jekyll-theme-chirpy/)
2
+ * Chirpy v3.3.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
3
3
  * © 2019 Cotes Chung
4
4
  * MIT Licensed
5
5
  */
6
- const getInitStatus=function(){let e=!1;return()=>{let t=e;return e||(e=!0),t}}(),PvOpts={isEnabled:()=>"true"===$("meta[name=pv-cache-enabled]").attr("content"),getProxyEndpoint:()=>$("meta[name=pv-proxy-endpoint]").attr("content"),getLocalData:()=>$("meta[name=pv-cache-data]").attr("content")},PvCache=function(){const e="origin",t="proxy";function a(e){return localStorage.getItem(e)}function n(e,t){localStorage.setItem(e,t)}return{getData:()=>JSON.parse(localStorage.getItem("pv")),saveOriginCache(t){n("pv",t),n("pv_source",e),n("pv_created_date",(new Date).toJSON())},saveProxyCache(e){n("pv",e),n("pv_source",t),n("pv_created_date",(new Date).toJSON())},isFromOrigin:()=>a("pv_source")===e,isFromProxy:()=>a("pv_source")===t,isExpired(){if(PvCache.isFromOrigin()){let e=new Date(a("pv_created_date"));return e.setDate(e.getDate()+1),Date.now()>=e.getTime()}if(PvCache.isFromProxy()){let e=new Date(a("pv_created_date"));return e.setHours(e.getHours()+1),Date.now()>=e.getTime()}return!1},getAllPageviews:()=>PvCache.getData().totalsForAllResults["ga:pageviews"],newerThan:e=>PvCache.getAllPageviews()>e.totalsForAllResults["ga:pageviews"],inspectKeys(){null!==localStorage.getItem("pv")&&null!==localStorage.getItem("pv_source")&&null!==localStorage.getItem("pv_created_date")||localStorage.clear()}}}();function countUp(e,t,a){if(e<t){let n=new CountUp(a,e,t);n.error?console.error(n.error):n.start()}}function countPV(e,t){let a=0;if(void 0!==t)for(let n=0;n<t.length;++n){if(t[parseInt(n,10)][0]===e){a+=parseInt(t[parseInt(n,10)][1],10);break}}return a}function tacklePV(e,t,a,n){let r=countPV(t,e);if(r=0===r?1:r,n){const e=parseInt(a.text().replace(/,/g,""),10);r>e&&countUp(e,r,a.attr("id"))}else a.text((new Intl.NumberFormat).format(r))}function displayPageviews(e){if(void 0===e)return;let t=getInitStatus();const a=e.rows;if($("#post-list").length>0)$(".post-preview").each(function(){const e=$(this).find("a").attr("href");tacklePV(a,e,$(this).find(".pageviews"),t)});else if($(".post").length>0){const e=window.location.pathname;tacklePV(a,e,$("#pv"),t)}}function fetchProxyPageviews(){$.ajax({type:"GET",url:PvOpts.getProxyEndpoint(),dataType:"jsonp",jsonpCallback:"displayPageviews",success:(e,t,a)=>{PvCache.saveProxyCache(JSON.stringify(e))},error:(e,t,a)=>{console.log("Failed to load pageviews from proxy server: "+a)}})}function fetchPageviews(e=!0,t=!1){PvOpts.isEnabled()&&e?fetch(PvOpts.getLocalData()).then(e=>e.json()).then(e=>{t&&PvCache.newerThan(e)||(displayPageviews(e),PvCache.saveOriginCache(JSON.stringify(e)))}).then(()=>fetchProxyPageviews()):fetchProxyPageviews()}$(function(){if($(".pageviews").length>0){PvCache.inspectKeys();let e=PvCache.getData();e?(displayPageviews(e),PvCache.isExpired()?fetchPageviews(!0,PvCache.isFromProxy()):PvCache.isFromOrigin()&&fetchPageviews(!1)):fetchPageviews()}});
6
+ const getInitStatus=function(){let t=!1;return()=>{var e=t;return t=t||!0,e}}(),PvOpts={isEnabled(){return"true"===$("meta[name=pv-cache-enabled]").attr("content")},getProxyEndpoint(){return $("meta[name=pv-proxy-endpoint]").attr("content")},getLocalData(){return $("meta[name=pv-cache-data]").attr("content")}},PvCache=function(){const t="pv",a="pv_created_date",r="pv_source",n={ORIGIN:"origin",PROXY:"proxy"};function o(e){return localStorage.getItem(e)}function i(e,t){localStorage.setItem(e,t)}return{getData(){return JSON.parse(localStorage.getItem(t))},saveOriginCache(e){i(t,e),i(r,n.ORIGIN),i(a,(new Date).toJSON())},saveProxyCache(e){i(t,e),i(r,n.PROXY),i(a,(new Date).toJSON())},isFromOrigin(){return o(r)===n.ORIGIN},isFromProxy(){return o(r)===n.PROXY},isExpired(){if(PvCache.isFromOrigin()){let e=new Date(o(a));return e.setDate(e.getDate()+1),Date.now()>=e.getTime()}if(PvCache.isFromProxy()){let e=new Date(o(a));return e.setHours(e.getHours()+1),Date.now()>=e.getTime()}return!1},getAllPageviews(){return PvCache.getData().totalsForAllResults["ga:pageviews"]},newerThan(e){return PvCache.getAllPageviews()>e.totalsForAllResults["ga:pageviews"]},inspectKeys(){null!==localStorage.getItem(t)&&null!==localStorage.getItem(r)&&null!==localStorage.getItem(a)||localStorage.clear()}}}();function countUp(t,a,r){if(t<a){let e=new CountUp(r,t,a);e.error?console.error(e.error):e.start()}}function countPV(t,a){let r=0;if(void 0!==a)for(let e=0;e<a.length;++e)if(a[parseInt(e,10)][0]===t){r+=parseInt(a[parseInt(e,10)][1],10);break}return r}function tacklePV(e,t,a,r){let n=countPV(t,e);n=0===n?1:n,r?(r=parseInt(a.text().replace(/,/g,""),10),n>r&&countUp(r,n,a.attr("id"))):a.text((new Intl.NumberFormat).format(n))}function displayPageviews(e){if(void 0!==e){let t=getInitStatus();const a=e.rows;0<$("#post-list").length?$(".post-preview").each(function(){var e=$(this).find("a").attr("href");tacklePV(a,e,$(this).find(".pageviews"),t)}):0<$(".post").length&&(e=window.location.pathname,tacklePV(a,e,$("#pv"),t))}}function fetchProxyPageviews(){$.ajax({type:"GET",url:PvOpts.getProxyEndpoint(),dataType:"jsonp",jsonpCallback:"displayPageviews",success:(e,t,a)=>{PvCache.saveProxyCache(JSON.stringify(e))},error:(e,t,a)=>{console.log("Failed to load pageviews from proxy server: "+a)}})}function fetchPageviews(e=!0,t=!1){PvOpts.isEnabled()&&e?fetch(PvOpts.getLocalData()).then(e=>e.json()).then(e=>{t&&PvCache.newerThan(e)||(displayPageviews(e),PvCache.saveOriginCache(JSON.stringify(e)))}).then(()=>fetchProxyPageviews()):fetchProxyPageviews()}$(function(){var e;0<$(".pageviews").length&&(PvCache.inspectKeys(),(e=PvCache.getData())?(displayPageviews(e),PvCache.isExpired()?fetchPageviews(!0,PvCache.isFromProxy()):PvCache.isFromOrigin()&&fetchPageviews(!1)):fetchPageviews())});
data/feed.xml CHANGED
@@ -10,14 +10,14 @@ layout: compress
10
10
  <subtitle>{{ site.description }}</subtitle>
11
11
  <updated>{{ site.time | date_to_xmlschema }}</updated>
12
12
  <author>
13
- <name>{{ site.author }}</name>
13
+ <name>{{ site.social.name }}</name>
14
14
  <uri>{{ "/" | absolute_url }}</uri>
15
15
  </author>
16
16
  <link rel="self" type="application/atom+xml" href="{{ page.url | absolute_url }}"/>
17
17
  <link rel="alternate" type="text/html" hreflang="{{ site.lang | default: 'en' }}"
18
18
  href="{{ '/' | absolute_url }}"/>
19
19
  <generator uri="https://jekyllrb.com/" version="{{ jekyll.version }}">Jekyll</generator>
20
- <rights> © {{ 'now' | date: '%Y' }} {{ site.author }} </rights>
20
+ <rights> © {{ 'now' | date: '%Y' }} {{ site.social.name }} </rights>
21
21
  <icon>{{ site.baseurl }}/assets/img/favicons/favicon.ico</icon>
22
22
  <logo>{{ site.baseurl }}/assets/img/favicons/favicon-96x96.png</logo>
23
23
 
@@ -35,7 +35,7 @@ layout: compress
35
35
  <id>{{ post_absolute_url }}</id>
36
36
  <content src="{{ post_absolute_url }}" />
37
37
  <author>
38
- <name>{{ site.author }}</name>
38
+ <name>{{ site.social.name }}</name>
39
39
  </author>
40
40
 
41
41
  {% if post.categories %}
data/sw.js CHANGED
@@ -7,7 +7,6 @@ self.importScripts('{{ "/assets/js/data/cache-list.js" | relative_url }}');
7
7
 
8
8
  var cacheName = 'chirpy-{{ "now" | date: "%Y%m%d.%H%M" }}';
9
9
 
10
-
11
10
  function isExcluded(url) {
12
11
  const regex = /(^http(s)?|^\/)/; /* the regex for CORS url or relative url */
13
12
  for (const rule of exclude) {
@@ -19,7 +18,6 @@ function isExcluded(url) {
19
18
  return false;
20
19
  }
21
20
 
22
-
23
21
  self.addEventListener('install', (e) => {
24
22
  self.skipWaiting();
25
23
  e.waitUntil(
@@ -29,25 +27,26 @@ self.addEventListener('install', (e) => {
29
27
  );
30
28
  });
31
29
 
32
-
33
30
  self.addEventListener('fetch', (e) => {
34
31
  e.respondWith(
35
32
  caches.match(e.request).then((r) => {
36
- /* console.log('[Service Worker] Fetching resource: ' + e.request.url); */
33
+ /* console.log(`[sw] method: ${e.request.method}, fetching: ${e.request.url}`); */
37
34
  return r || fetch(e.request).then((response) => {
38
35
  return caches.open(cacheName).then((cache) => {
39
36
  if (!isExcluded(e.request.url)) {
40
- /* console.log('[Service Worker] Caching new resource: ' + e.request.url); */
41
- cache.put(e.request, response.clone());
37
+ if (e.request.method === "GET") {
38
+ /* console.log('[sw] Caching new resource: ' + e.request.url); */
39
+ cache.put(e.request, response.clone());
40
+ }
42
41
  }
43
42
  return response;
44
43
  });
44
+
45
45
  });
46
46
  })
47
47
  );
48
48
  });
49
49
 
50
-
51
50
  self.addEventListener('activate', (e) => {
52
51
  e.waitUntil(
53
52
  caches.keys().then((keyList) => {
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-theme-chirpy
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.2
4
+ version: 3.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cotes Chung
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-03-04 00:00:00.000000000 Z
11
+ date: 2021-04-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll