jekyll-theme-chirpy 5.1.0 → 5.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/_config.yml +3 -0
  3. data/_data/authors.yml +17 -0
  4. data/_data/locales/en.yml +11 -6
  5. data/_data/locales/es-ES.yml +79 -0
  6. data/_data/locales/fr-FR.yml +79 -0
  7. data/_data/locales/id-ID.yml +4 -3
  8. data/_data/locales/ko-KR.yml +4 -3
  9. data/_data/locales/my-MM.yml +4 -3
  10. data/_data/locales/pt-BR.yml +79 -0
  11. data/_data/locales/ru-RU.yml +4 -3
  12. data/_data/locales/uk-UA.yml +4 -3
  13. data/_data/locales/vi-VN.yml +77 -0
  14. data/_data/locales/zh-CN.yml +4 -3
  15. data/_includes/datetime.html +21 -0
  16. data/_includes/footer.html +5 -6
  17. data/_includes/head.html +33 -7
  18. data/_includes/js-selector.html +9 -5
  19. data/_includes/mermaid.html +1 -1
  20. data/_includes/post-nav.html +4 -4
  21. data/_includes/post-paginator.html +2 -2
  22. data/_includes/post-sharing.html +3 -2
  23. data/_includes/refactor-content.html +9 -4
  24. data/_includes/related-posts.html +1 -4
  25. data/_includes/search-loader.html +1 -1
  26. data/_includes/sidebar.html +2 -2
  27. data/_includes/toc.html +1 -1
  28. data/_includes/topbar.html +2 -2
  29. data/_layouts/archives.html +15 -4
  30. data/_layouts/categories.html +25 -4
  31. data/_layouts/category.html +3 -3
  32. data/_layouts/default.html +19 -6
  33. data/_layouts/home.html +3 -7
  34. data/_layouts/page.html +8 -10
  35. data/_layouts/post.html +52 -44
  36. data/_layouts/tag.html +3 -3
  37. data/_layouts/tags.html +3 -1
  38. data/_sass/addon/commons.scss +115 -186
  39. data/_sass/addon/syntax.scss +1 -1
  40. data/_sass/addon/variables.scss +3 -3
  41. data/_sass/jekyll-theme-chirpy.scss +1 -1
  42. data/_sass/layout/post.scss +3 -6
  43. data/assets/404.html +0 -15
  44. data/assets/js/data/search.json +5 -5
  45. data/assets/js/dist/categories.min.js +2 -2
  46. data/assets/js/dist/commons.min.js +2 -2
  47. data/assets/js/dist/home.min.js +2 -2
  48. data/assets/js/dist/misc.min.js +2 -2
  49. data/assets/js/dist/page.min.js +2 -2
  50. data/assets/js/dist/post.min.js +2 -2
  51. data/assets/js/dist/pvreport.min.js +2 -2
  52. data/assets/js/pwa/app.js +55 -4
  53. data/assets/js/pwa/sw.js +42 -40
  54. data/assets/js/pwa/unregister.js +12 -0
  55. metadata +11 -5
  56. data/_includes/timeago.html +0 -15
@@ -5,7 +5,7 @@
5
5
  html {
6
6
  @media (prefers-color-scheme: light) {
7
7
  &:not([data-mode]),
8
- [data-mode=light] {
8
+ &[data-mode=light] {
9
9
  @include light-scheme;
10
10
  }
11
11
 
@@ -126,6 +126,11 @@ blockquote {
126
126
  @include prompt("danger", "\f071");
127
127
  }
128
128
 
129
+ mjx-container {
130
+ overflow-x: auto;
131
+ overflow-y: hidden;
132
+ }
133
+
129
134
  kbd {
130
135
  font-family: inherit;
131
136
  display: inline-block;
@@ -143,18 +148,15 @@ kbd {
143
148
  }
144
149
 
145
150
  footer {
146
- position: absolute;
147
- bottom: 0;
148
- padding: 0 1rem;
149
- height: $footer-height;
151
+ @include pl-pr(1.5rem);
152
+
150
153
  font-size: 0.8rem;
151
154
 
152
155
  > div.d-flex {
156
+ height: $footer-height;
153
157
  line-height: 1.2rem;
154
- width: 95%;
155
- max-width: 1045px;
158
+ padding-bottom: 1rem;
156
159
  border-top: 1px solid var(--main-border-color);
157
- margin-bottom: 1rem;
158
160
 
159
161
  > div {
160
162
  width: 350px;
@@ -222,7 +224,6 @@ img[data-src] {
222
224
  .access {
223
225
  top: 2rem;
224
226
  transition: top 0.2s ease-in-out;
225
- margin-right: 1.5rem;
226
227
  margin-top: 3rem;
227
228
  margin-bottom: 4rem;
228
229
 
@@ -436,7 +437,7 @@ img[data-src] {
436
437
  margin-right: 2px;
437
438
  }
438
439
 
439
- &:hover {
440
+ &:not([class]):hover {
440
441
  @extend %link-hover;
441
442
  }
442
443
  }
@@ -871,6 +872,7 @@ $sidebar-display: "sidebar-display";
871
872
  #search-result-wrapper {
872
873
  display: none;
873
874
  height: 100%;
875
+ width: 100%;
874
876
  overflow: auto;
875
877
 
876
878
  .post-content {
@@ -928,7 +930,7 @@ $sidebar-display: "sidebar-display";
928
930
 
929
931
  #search-wrapper {
930
932
  display: flex;
931
- width: 85%;
933
+ width: 100%;
932
934
  border-radius: 1rem;
933
935
  border: 1px solid var(--search-wrapper-border-color);
934
936
  background: var(--search-wrapper-bg);
@@ -997,7 +999,7 @@ $sidebar-display: "sidebar-display";
997
999
  }
998
1000
 
999
1001
  #search-results {
1000
- padding-bottom: 6rem;
1002
+ padding-bottom: 3rem;
1001
1003
 
1002
1004
  a {
1003
1005
  &:hover {
@@ -1050,7 +1052,7 @@ $sidebar-display: "sidebar-display";
1050
1052
  }
1051
1053
 
1052
1054
  #core-wrapper {
1053
- min-height: calc(100vh - #{$topbar-height} - #{$footer-height} - #{$bottom-min-height}) !important;
1055
+ min-height: calc(100vh - #{$topbar-height} - #{$footer-height});
1054
1056
 
1055
1057
  .categories,
1056
1058
  #tags,
@@ -1083,29 +1085,13 @@ $sidebar-display: "sidebar-display";
1083
1085
  background-color: var(--main-wrapper-bg);
1084
1086
  position: relative;
1085
1087
  min-height: 100vh;
1086
- padding-bottom: $footer-height;
1087
1088
 
1088
1089
  @include pl-pr(0);
1089
1090
  }
1090
1091
 
1091
- #main {
1092
- .row:first-child {
1093
- > div {
1094
- &:nth-child(1),
1095
- &:nth-child(2) {
1096
- margin-top: $topbar-height; /* same as the height of topbar */
1097
- }
1098
-
1099
- &:first-child {
1100
- /* 3rem for topbar, 6rem for footer */
1101
- min-height: calc(100vh - #{$topbar-height} - #{$footer-height} - #{$bottom-min-height});
1102
- }
1103
- }
1104
- }
1105
-
1106
- div.row:first-of-type:last-of-type { /* alone */
1107
- margin-bottom: 4rem;
1108
- }
1092
+ #core-wrapper,
1093
+ #panel-wrapper {
1094
+ margin-top: $topbar-height; /* same as the height of topbar */
1109
1095
  }
1110
1096
 
1111
1097
  #topbar-wrapper.row,
@@ -1145,6 +1131,51 @@ $sidebar-display: "sidebar-display";
1145
1131
  -webkit-transform: translate3d(0, -5px, 0);
1146
1132
  }
1147
1133
 
1134
+ #notification {
1135
+ @keyframes popup {
1136
+ from {
1137
+ opacity: 0;
1138
+ bottom: 0;
1139
+ }
1140
+ }
1141
+
1142
+ .toast-header {
1143
+ background: none;
1144
+ border-bottom: none;
1145
+ color: inherit;
1146
+ }
1147
+
1148
+ .toast-body {
1149
+ font-family: 'Lato';
1150
+ line-height: 1.25rem;
1151
+
1152
+ button {
1153
+ font-size: 90%;
1154
+ min-width: 4rem;
1155
+ }
1156
+ }
1157
+
1158
+ &.toast {
1159
+ display: none;
1160
+
1161
+ &.show {
1162
+ display: block;
1163
+ min-width: 20rem;
1164
+ border-radius: 0.5rem;
1165
+ -webkit-backdrop-filter: blur(10px);
1166
+ backdrop-filter: blur(10px);
1167
+ background-color: rgba(255, 255, 255, 0.5);
1168
+ color: #1b1b1eba;
1169
+ position: fixed;
1170
+ left: 50%;
1171
+ bottom: 20%;
1172
+ transform: translateX(-50%);
1173
+ animation: popup 0.8s;
1174
+ }
1175
+ }
1176
+
1177
+ }
1178
+
1148
1179
  /*
1149
1180
  Responsive Design:
1150
1181
 
@@ -1155,16 +1186,11 @@ $sidebar-display: "sidebar-display";
1155
1186
  */
1156
1187
 
1157
1188
  @media all and (max-width: 576px) {
1158
-
1159
- $footer-height: $footer-height-mobile; /* overwrite */
1160
-
1161
1189
  footer {
1162
- height: $footer-height;
1190
+ height: $footer-height-mobile;
1163
1191
 
1164
1192
  > div.d-flex {
1165
- width: 100%;
1166
1193
  padding: 1.5rem 0;
1167
- margin-bottom: 0.3rem;
1168
1194
  flex-wrap: wrap;
1169
1195
  -ms-flex-pack: distribute !important;
1170
1196
  justify-content: space-around !important;
@@ -1176,12 +1202,8 @@ $sidebar-display: "sidebar-display";
1176
1202
  }
1177
1203
  }
1178
1204
 
1179
- #main > div.row:first-child > div:first-child {
1180
- min-height: calc(100vh - #{$topbar-height} - #{$footer-height});
1181
- }
1182
-
1183
1205
  #core-wrapper {
1184
- min-height: calc(100vh - #{$topbar-height} - #{$footer-height} - #{$bottom-min-height}) !important;
1206
+ min-height: calc(100vh - #{$topbar-height} - #{$footer-height-mobile}) !important;
1185
1207
 
1186
1208
  h1 {
1187
1209
  margin-top: 2.2rem;
@@ -1206,10 +1228,21 @@ $sidebar-display: "sidebar-display";
1206
1228
  @include ml-mr(1.8rem);
1207
1229
  }
1208
1230
 
1209
- #main-wrapper {
1210
- padding-bottom: $footer-height;
1231
+ }
1232
+
1233
+ @media all and (max-width: 768px) {
1234
+ %full-width {
1235
+ max-width: 100%;
1211
1236
  }
1212
1237
 
1238
+ #topbar {
1239
+ @extend %full-width;
1240
+ }
1241
+
1242
+ #main {
1243
+ @extend %full-width;
1244
+ @include pl-pr(0);
1245
+ }
1213
1246
  }
1214
1247
 
1215
1248
  /* hide sidebar and panel */
@@ -1260,6 +1293,11 @@ $sidebar-display: "sidebar-display";
1260
1293
  padding-top: $topbar-height;
1261
1294
  }
1262
1295
 
1296
+ #topbar,
1297
+ #main {
1298
+ max-width: 100%;
1299
+ }
1300
+
1263
1301
  #search-result-wrapper {
1264
1302
  width: 100%;
1265
1303
  }
@@ -1275,8 +1313,8 @@ $sidebar-display: "sidebar-display";
1275
1313
  left: 0;
1276
1314
  }
1277
1315
 
1278
- #main > div.row:first-child > div:nth-child(1),
1279
- #main > div.row:first-child > div:nth-child(2) {
1316
+ #core-wrapper,
1317
+ #panel-wrapper {
1280
1318
  margin-top: 0;
1281
1319
  }
1282
1320
 
@@ -1286,17 +1324,6 @@ $sidebar-display: "sidebar-display";
1286
1324
  display: block;
1287
1325
  }
1288
1326
 
1289
- #search-wrapper {
1290
- &.loaded ~ a {
1291
- margin-right: 1rem;
1292
- }
1293
- }
1294
-
1295
- #search-input {
1296
- margin-left: 0;
1297
- width: 95%;
1298
- }
1299
-
1300
1327
  #search-result-wrapper .post-content {
1301
1328
  letter-spacing: 0;
1302
1329
  }
@@ -1345,17 +1372,17 @@ $sidebar-display: "sidebar-display";
1345
1372
  margin-top: 3rem;
1346
1373
  }
1347
1374
 
1348
- #search-wrapper {
1349
- width: 22%;
1350
- min-width: 150px;
1351
- }
1352
-
1353
1375
  #search-hints {
1354
1376
  display: none;
1355
1377
  }
1356
1378
 
1379
+ #search-wrapper {
1380
+ max-width: $search-max-width;
1381
+ }
1382
+
1357
1383
  #search-result-wrapper {
1358
1384
  margin-top: 3rem;
1385
+ max-width: $main-content-max-width;
1359
1386
  }
1360
1387
 
1361
1388
  div.post-content .table-wrapper > table {
@@ -1365,15 +1392,15 @@ $sidebar-display: "sidebar-display";
1365
1392
  /* button 'back-to-Top' position */
1366
1393
  #back-to-top {
1367
1394
  bottom: 5.5rem;
1368
- right: 1.2rem;
1395
+ right: 5%;
1369
1396
  }
1370
1397
 
1371
- #topbar-title {
1372
- text-align: left;
1398
+ #topbar {
1399
+ @include pl-pr(2rem);
1373
1400
  }
1374
1401
 
1375
- footer > div.d-flex {
1376
- width: 92%;
1402
+ #topbar-title {
1403
+ text-align: left;
1377
1404
  }
1378
1405
 
1379
1406
  }
@@ -1449,10 +1476,6 @@ $sidebar-display: "sidebar-display";
1449
1476
  display: none;
1450
1477
  }
1451
1478
 
1452
- #topbar {
1453
- padding: 0;
1454
- }
1455
-
1456
1479
  #main > div.row {
1457
1480
  -webkit-box-pack: center !important;
1458
1481
  -ms-flex-pack: center !important;
@@ -1463,26 +1486,12 @@ $sidebar-display: "sidebar-display";
1463
1486
  /* --- desktop mode, both sidebar and panel are visible --- */
1464
1487
 
1465
1488
  @media all and (min-width: 1200px) {
1466
- #main > div.row > div.col-xl-8 {
1467
- -webkit-box-flex: 0;
1468
- -ms-flex: 0 0 75%;
1469
- flex: 0 0 75%;
1470
- max-width: 75%;
1471
- padding-left: 3%;
1472
- }
1473
-
1474
- #topbar {
1475
- padding: 0;
1476
- max-width: 1070px;
1477
- }
1478
-
1479
- #panel-wrapper {
1480
- max-width: $panel-max-width;
1481
- }
1482
-
1483
1489
  #back-to-top {
1484
1490
  bottom: 6.5rem;
1485
- right: 4.3rem;
1491
+ }
1492
+
1493
+ #search-wrapper {
1494
+ margin-right: 4rem;
1486
1495
  }
1487
1496
 
1488
1497
  #search-input {
@@ -1518,62 +1527,36 @@ $sidebar-display: "sidebar-display";
1518
1527
  }
1519
1528
 
1520
1529
  @media all and (min-width: 1400px) {
1521
- #main > div.row {
1522
- padding-left: calc((100% - #{$main-content-max-width}) / 2);
1523
-
1524
- > div.col-xl-8 {
1525
- max-width: 850px;
1526
- }
1527
- }
1528
-
1529
- #search-result-wrapper {
1530
- padding-right: 2rem;
1531
-
1532
- > div {
1533
- max-width: 1110px;
1534
- }
1535
- }
1536
-
1537
- }
1538
-
1539
- @media all and (min-width: 1400px) and (max-width: 1650px) {
1540
- #topbar {
1541
- padding-right: 2rem;
1530
+ #back-to-top {
1531
+ right: calc((100vw - #{$sidebar-width} - 1140px) / 2 + 3rem);
1542
1532
  }
1543
1533
  }
1544
1534
 
1545
1535
  @media all and (min-width: 1650px) {
1546
- #breadcrumb {
1547
- padding-left: 0;
1548
- }
1549
-
1550
- #main > div.row > div.col-xl-8 {
1551
- padding-left: 0;
1552
-
1553
- > div:first-child {
1554
- padding-left: 0.55rem !important;
1555
- padding-right: 1.9rem !important;
1556
- }
1557
- }
1558
-
1559
1536
  #main-wrapper {
1560
1537
  margin-left: $sidebar-width-large;
1561
1538
  }
1562
1539
 
1563
- #panel-wrapper {
1564
- margin-left: calc((100% - #{$main-content-max-width}) / 10);
1565
- }
1566
-
1567
1540
  #topbar-wrapper {
1568
1541
  left: $sidebar-width-large;
1569
1542
  }
1570
1543
 
1571
- #topbar {
1572
- max-width: #{$main-content-max-width};
1544
+ #search-wrapper {
1545
+ margin-right: calc(#{$main-content-max-width} * 0.25 - #{$search-max-width});
1573
1546
  }
1574
1547
 
1575
- #search-wrapper {
1576
- margin-right: 3%;
1548
+ #topbar,
1549
+ #main {
1550
+ max-width: $main-content-max-width;
1551
+ }
1552
+
1553
+ #core-wrapper,
1554
+ #tail-wrapper {
1555
+ padding-right: 4.5rem !important;
1556
+ }
1557
+
1558
+ #back-to-top {
1559
+ right: calc((100vw - #{$sidebar-width-large} - #{$main-content-max-width}) / 2 + 2rem);
1577
1560
  }
1578
1561
 
1579
1562
  #sidebar {
@@ -1694,58 +1677,4 @@ $sidebar-display: "sidebar-display";
1694
1677
 
1695
1678
  } /* #sidebar */
1696
1679
 
1697
- footer > div.d-flex {
1698
- width: 92%;
1699
- max-width: 1140px;
1700
- }
1701
-
1702
- #search-result-wrapper {
1703
- > div {
1704
- max-width: #{$main-content-max-width};
1705
- }
1706
- }
1707
-
1708
1680
  } /* min-width: 1650px */
1709
-
1710
- @media all and (min-width: 1700px) {
1711
- #topbar-wrapper {
1712
- /* 100% - 350px - (1920px - 350px); */
1713
- padding-right: calc(100% - #{$sidebar-width-large} - (1920px - #{$sidebar-width-large}));
1714
- }
1715
-
1716
- #topbar {
1717
- max-width: calc(#{$main-content-max-width} + 20px);
1718
- }
1719
-
1720
- #main > div.row {
1721
- padding-left: calc((100% - #{$main-content-max-width} - 2%) / 2);
1722
- }
1723
-
1724
- #panel-wrapper {
1725
- margin-left: 3%;
1726
- }
1727
-
1728
- footer {
1729
- padding-left: 0;
1730
- padding-right: calc(100% - #{$sidebar-width-large} - 1180px);
1731
- }
1732
-
1733
- #back-to-top {
1734
- right: calc(100% - 1920px + 15rem);
1735
- }
1736
-
1737
- }
1738
-
1739
- @media (min-width: 1920px) {
1740
- #main > div.row {
1741
- padding-left: 190px;
1742
- }
1743
-
1744
- #search-result-wrapper {
1745
- padding-right: calc(100% - #{$sidebar-width-large} - 1180px);
1746
- }
1747
-
1748
- #panel-wrapper {
1749
- margin-left: 41px;
1750
- }
1751
- }
@@ -8,7 +8,7 @@
8
8
  html {
9
9
  @media (prefers-color-scheme: light) {
10
10
  &:not([data-mode]),
11
- [data-mode=light] {
11
+ &[data-mode=light] {
12
12
  @include light-syntax;
13
13
  }
14
14
 
@@ -20,12 +20,12 @@ $cursor-width: 2px !default; /* the cursor width of the selected tab */
20
20
 
21
21
  $topbar-height: 3rem !default;
22
22
 
23
+ $search-max-width: 210px !default;
24
+
23
25
  $footer-height: 5rem !default;
24
26
  $footer-height-mobile: 6rem !default; /* screen width: <= 576px */
25
27
 
26
- $main-content-max-width: 1150px !default;
27
-
28
- $panel-max-width: 300px !default;
28
+ $main-content-max-width: 1250px !default;
29
29
 
30
30
  $bottom-min-height: 35rem !default;
31
31
 
@@ -1,7 +1,7 @@
1
1
  /*!
2
2
  * The styles for Jekyll theme Chirpy
3
3
  *
4
- * Chirpy v5.1.0 (https://github.com/cotes2020/jekyll-theme-chirpy)
4
+ * Chirpy v5.2.0 (https://github.com/cotes2020/jekyll-theme-chirpy)
5
5
  * © 2019 Cotes Chung
6
6
  * MIT Licensed
7
7
  */
@@ -41,8 +41,7 @@ h1 + .post-meta {
41
41
  }
42
42
 
43
43
  img.preview-img {
44
- margin-top: 3.75rem;
45
- margin-bottom: 0;
44
+ margin: 0;
46
45
  border-radius: 6px;
47
46
 
48
47
  &.bg[data-loaded=true] {
@@ -173,6 +172,8 @@ nav[data-toggle=toc] {
173
172
 
174
173
  em {
175
174
  @extend %normal-font-style;
175
+
176
+ color: var(--relate-post-date);
176
177
  }
177
178
 
178
179
  .card {
@@ -194,10 +195,6 @@ nav[data-toggle=toc] {
194
195
  }
195
196
  }
196
197
 
197
- .timeago {
198
- color: var(--relate-post-date);
199
- }
200
-
201
198
  p {
202
199
  font-size: 0.9rem;
203
200
  margin-bottom: 0.5rem;
data/assets/404.html CHANGED
@@ -12,20 +12,5 @@ redirect_from:
12
12
  {% include lang.html %}
13
13
 
14
14
  <div class="lead">
15
-
16
- {%- capture _head_back -%}
17
- <a href="{{ '/' | relative_url }}">{{ site.data.locales[lang].not_found.head_back }}</a>
18
- {%- endcapture -%}
19
-
20
- {%- capture _archives_page -%}
21
- <a href="{{ 'archives' | relative_url }}">{{ site.data.locales[lang].not_found.archives_page }}</a>
22
- {%- endcapture -%}
23
-
24
15
  <p>{{site.data.locales[lang].not_found.statment }}</p>
25
-
26
- <p>{{ site.data.locales[lang].not_found.hint_template
27
- | replace: ':HEAD_BAK', _head_back
28
- | replace: ':ARCHIVES_PAGE', _archives_page }}
29
- </p>
30
-
31
16
  </div>
@@ -6,13 +6,13 @@ swcache: true
6
6
  [
7
7
  {% for post in site.posts %}
8
8
  {
9
- "title": "{{ post.title | escape }}",
10
- "url": "{{ post.url | relative_url }}",
11
- "categories": "{{ post.categories | join: ', '}}",
12
- "tags": "{{ post.tags | join: ', ' }}",
9
+ "title": {{ post.title | jsonify }},
10
+ "url": {{ post.url | relative_url | jsonify }},
11
+ "categories": {{ post.categories | join: ', ' | jsonify }},
12
+ "tags": {{ post.tags | join: ', ' | jsonify }},
13
13
  "date": "{{ post.date }}",
14
14
  {% include no-linenos.html content=post.content %}
15
- "snippet": "{{ content | strip_html | strip_newlines | remove_chars | escape | replace: '\', '\\\\' }}"
15
+ "snippet": {{ content | strip_html | strip_newlines | jsonify }}
16
16
  }{% unless forloop.last %},{% endunless %}
17
17
  {% endfor %}
18
18
  ]
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Chirpy v5.1.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
2
+ * Chirpy v5.2.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
3
3
  * © 2019 Cotes Chung
4
4
  * MIT Licensed
5
5
  */
6
- $(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))});const LocaleHelper=function(){const e=$('meta[name="prefer-datetime-locale"]'),o=0<e.length?e.attr("content").toLowerCase():$("html").attr("lang").substr(0,2),t="data-ts",a="data-df";return{locale:()=>o,attrTimestamp:()=>t,attrDateFormat:()=>a,getTimestamp:e=>Number(e.attr(t)),getDateFormat:e=>e.attr(a)}}();$(function(){$(".mode-toggle").click(e=>{const o=$(e.target);let t=o.prop("tagName")==="button".toUpperCase()?o:o.parent();t.blur(),flipMode()})});const ScrollHelper=function(){const e=$("body"),o="data-topbar-visible",t=$("#topbar-wrapper").outerHeight();let a=0,r=!1,l=!1;return{hideTopbar:()=>e.attr(o,!1),showTopbar:()=>e.attr(o,!0),addScrollUpTask:()=>{a+=1,r=r||!0},popScrollUpTask:()=>--a,hasScrollUpTask:()=>0<a,topbarLocked:()=>!0===r,unlockTopbar:()=>r=!1,getTopbarHeight:()=>t,orientationLocked:()=>!0===l,lockOrientation:()=>l=!0,unLockOrientation:()=>l=!1}}();$(function(){const e=$("#sidebar-trigger"),o=$("#search-trigger"),t=$("#search-cancel"),a=$("#main"),r=$("#topbar-title"),l=$("#search-wrapper"),n=$("#search-result-wrapper"),s=$("#search-results"),i=$("#search-input"),c=$("#search-hints"),d=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"),r.addClass("unloaded"),o.addClass("unloaded"),l.addClass("d-flex"),t.addClass("loaded")},off(){t.removeClass("loaded"),l.removeClass("d-flex"),e.removeClass("unloaded"),r.removeClass("unloaded"),o.removeClass("unloaded")}},u=function(){let e=!1;return{on(){e||(d.block(),n.removeClass("unloaded"),a.addClass("unloaded"),e=!0)},off(){e&&(s.empty(),c.hasClass("unloaded")&&c.removeClass("unloaded"),n.addClass("unloaded"),a.removeClass("unloaded"),d.release(),i.val(""),e=!1)},isVisible(){return e}}}();function f(){return t.hasClass("loaded")}o.click(function(){p.on(),u.on(),i.focus()}),t.click(function(){p.off(),u.off()}),i.focus(function(){l.addClass("input-focus")}),i.focusout(function(){l.removeClass("input-focus")}),i.on("input",()=>{""===i.val()?f()?c.removeClass("unloaded"):u.off():(u.on(),f()&&c.addClass("unloaded"))})}),$(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=$("#search-input"),t=ScrollHelper.getTopbarHeight();let e,a=0;function r(){0!==$(window).scrollTop()&&(ScrollHelper.lockOrientation(),ScrollHelper.hideTopbar())}screen.orientation?screen.orientation.onchange=()=>{var e=screen.orientation.type;"landscape-primary"!==e&&"landscape-secondary"!==e||r()}:$(window).on("orientationchange",()=>{$(window).width()<$(window).height()&&r()}),$(window).scroll(()=>{e=e||!0}),setInterval(()=>{e&&(function(){var e=$(this).scrollTop();if(!(Math.abs(a-e)<=t)){if(e>a)ScrollHelper.hideTopbar(),o.is(":focus")&&o.blur();else if(e+$(window).height()<$(document).height()){if(ScrollHelper.hasScrollUpTask())return;ScrollHelper.topbarLocked()?ScrollHelper.unlockTopbar():ScrollHelper.orientationLocked()?ScrollHelper.unLockOrientation():ScrollHelper.showTopbar()}a=e}}(),e=!1)},250)}),$(function(){var o="div.post>h1:first-of-type";const t=$(o),n=$("#topbar-title");if(0!==t.length&&!t.hasClass("dynamic-title")&&!n.is(":hidden")){const s=n.text().trim();let a=t.text().trim(),r=!1,l=0;($("#page-category").length||$("#page-tag").length)&&/\s/.test(a)&&(a=a.replace(/[0-9]/g,"").trim()),t.offset().top<$(window).scrollTop()&&n.text(a);let e=new IntersectionObserver(e=>{var o,t;r?(o=$(window).scrollTop(),t=l<o,l=o,e=e[0],t?0===e.intersectionRatio&&n.text(a):1===e.intersectionRatio&&n.text(s)):r=!0},{rootMargin:"-48px 0px 0px 0px",threshold:[0,1]});e.observe(document.querySelector(o)),n.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"))})});
6
+ $(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(){$(".mode-toggle").click(o=>{const e=$(o.target);let t=e.prop("tagName")==="button".toUpperCase()?e:e.parent();t.blur(),flipMode()})});const ScrollHelper=function(){const o=$("body"),e="data-topbar-visible",t=$("#topbar-wrapper").outerHeight();let l=0,a=!1,r=!1;return{hideTopbar:()=>o.attr(e,!1),showTopbar:()=>o.attr(e,!0),addScrollUpTask:()=>{l+=1,a=a||!0},popScrollUpTask:()=>--l,hasScrollUpTask:()=>0<l,topbarLocked:()=>!0===a,unlockTopbar:()=>a=!1,getTopbarHeight:()=>t,orientationLocked:()=>!0===r,lockOrientation:()=>r=!0,unLockOrientation:()=>r=!1}}();$(function(){const o=$("#sidebar-trigger"),e=$("#search-trigger"),t=$("#search-cancel"),l=$("#main"),a=$("#topbar-title"),r=$("#search-wrapper"),n=$("#search-result-wrapper"),s=$("#search-results"),i=$("#search-input"),c=$("#search-hints"),d=function(){let o=0;return{block(){o=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(o)},getOffset(){return o}}}(),p={on(){o.addClass("unloaded"),a.addClass("unloaded"),e.addClass("unloaded"),r.addClass("d-flex"),t.addClass("loaded")},off(){t.removeClass("loaded"),r.removeClass("d-flex"),o.removeClass("unloaded"),a.removeClass("unloaded"),e.removeClass("unloaded")}},f=function(){let o=!1;return{on(){o||(d.block(),n.removeClass("unloaded"),l.addClass("unloaded"),o=!0)},off(){o&&(s.empty(),c.hasClass("unloaded")&&c.removeClass("unloaded"),n.addClass("unloaded"),l.removeClass("unloaded"),d.release(),i.val(""),o=!1)},isVisible(){return o}}}();function u(){return t.hasClass("loaded")}e.click(function(){p.on(),f.on(),i.focus()}),t.click(function(){p.off(),f.off()}),i.focus(function(){r.addClass("input-focus")}),i.focusout(function(){r.removeClass("input-focus")}),i.on("input",()=>{""===i.val()?u()?c.removeClass("unloaded"):f.off():(f.on(),u()&&c.addClass("unloaded"))})}),$(function(){var o=function(){const o="sidebar-display";let e=!1;const t=$("body");return{toggle(){!1===e?t.attr(o,""):t.removeAttr(o),e=!e}}}();$("#sidebar-trigger").click(o.toggle),$("#mask").click(o.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const e=$("#search-input"),t=ScrollHelper.getTopbarHeight();let o,l=0;function a(){0!==$(window).scrollTop()&&(ScrollHelper.lockOrientation(),ScrollHelper.hideTopbar())}screen.orientation?screen.orientation.onchange=()=>{var o=screen.orientation.type;"landscape-primary"!==o&&"landscape-secondary"!==o||a()}:$(window).on("orientationchange",()=>{$(window).width()<$(window).height()&&a()}),$(window).scroll(()=>{o=o||!0}),setInterval(()=>{o&&(!function(){var o=$(this).scrollTop();if(!(Math.abs(l-o)<=t)){if(o>l)ScrollHelper.hideTopbar(),e.is(":focus")&&e.blur();else if(o+$(window).height()<$(document).height()){if(ScrollHelper.hasScrollUpTask())return;ScrollHelper.topbarLocked()?ScrollHelper.unlockTopbar():ScrollHelper.orientationLocked()?ScrollHelper.unLockOrientation():ScrollHelper.showTopbar()}l=o}}(),o=!1)},250)}),$(function(){var e="div.post>h1:first-of-type";const t=$(e),n=$("#topbar-title");if(0!==t.length&&!t.hasClass("dynamic-title")&&!n.is(":hidden")){const s=n.text().trim();let l=t.text().trim(),a=!1,r=0;($("#page-category").length||$("#page-tag").length)&&/\s/.test(l)&&(l=l.replace(/[0-9]/g,"").trim()),t.offset().top<$(window).scrollTop()&&n.text(l);let o=new IntersectionObserver(o=>{var e,t;a?(t=$(window).scrollTop(),e=r<t,r=t,t=o[0],e?0===t.intersectionRatio&&n.text(l):1===t.intersectionRatio&&n.text(s)):a=!0},{rootMargin:"-48px 0px 0px 0px",threshold:[0,1]});o.observe(document.querySelector(e)),n.click(function(){$("body,html").animate({scrollTop:0},800)})}}),$(function(){const o=$(".collapse");o.on("hide.bs.collapse",function(){var o="h_"+$(this).attr("id").substring("l_".length);o&&($(`#${o} .far.fa-folder-open`).attr("class","far fa-folder fa-fw"),$(`#${o} i.fas`).addClass("rotate"),$("#"+o).removeClass("hide-border-bottom"))}),o.on("show.bs.collapse",function(){var o="h_"+$(this).attr("id").substring("l_".length);o&&($(`#${o} .far.fa-folder`).attr("class","far fa-folder-open fa-fw"),$(`#${o} i.fas`).removeClass("rotate"),$("#"+o).addClass("hide-border-bottom"))})});
@@ -1,6 +1,6 @@
1
1
  /*!
2
- * Chirpy v5.1.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
2
+ * Chirpy v5.2.0 (https://github.com/cotes2020/jekyll-theme-chirpy/)
3
3
  * © 2019 Cotes Chung
4
4
  * MIT Licensed
5
5
  */
6
- $(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))});const LocaleHelper=function(){const e=$('meta[name="prefer-datetime-locale"]'),o=0<e.length?e.attr("content").toLowerCase():$("html").attr("lang").substr(0,2),t="data-ts",a="data-df";return{locale:()=>o,attrTimestamp:()=>t,attrDateFormat:()=>a,getTimestamp:e=>Number(e.attr(t)),getDateFormat:e=>e.attr(a)}}();$(function(){$(".mode-toggle").click(e=>{const o=$(e.target);let t=o.prop("tagName")==="button".toUpperCase()?o:o.parent();t.blur(),flipMode()})});const ScrollHelper=function(){const e=$("body"),o="data-topbar-visible",t=$("#topbar-wrapper").outerHeight();let a=0,r=!1,l=!1;return{hideTopbar:()=>e.attr(o,!1),showTopbar:()=>e.attr(o,!0),addScrollUpTask:()=>{a+=1,r=r||!0},popScrollUpTask:()=>--a,hasScrollUpTask:()=>0<a,topbarLocked:()=>!0===r,unlockTopbar:()=>r=!1,getTopbarHeight:()=>t,orientationLocked:()=>!0===l,lockOrientation:()=>l=!0,unLockOrientation:()=>l=!1}}();$(function(){const e=$("#sidebar-trigger"),o=$("#search-trigger"),t=$("#search-cancel"),a=$("#main"),r=$("#topbar-title"),l=$("#search-wrapper"),n=$("#search-result-wrapper"),s=$("#search-results"),c=$("#search-input"),i=$("#search-hints"),d=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"),r.addClass("unloaded"),o.addClass("unloaded"),l.addClass("d-flex"),t.addClass("loaded")},off(){t.removeClass("loaded"),l.removeClass("d-flex"),e.removeClass("unloaded"),r.removeClass("unloaded"),o.removeClass("unloaded")}},u=function(){let e=!1;return{on(){e||(d.block(),n.removeClass("unloaded"),a.addClass("unloaded"),e=!0)},off(){e&&(s.empty(),i.hasClass("unloaded")&&i.removeClass("unloaded"),n.addClass("unloaded"),a.removeClass("unloaded"),d.release(),c.val(""),e=!1)},isVisible(){return e}}}();function f(){return t.hasClass("loaded")}o.click(function(){p.on(),u.on(),c.focus()}),t.click(function(){p.off(),u.off()}),c.focus(function(){l.addClass("input-focus")}),c.focusout(function(){l.removeClass("input-focus")}),c.on("input",()=>{""===c.val()?f()?i.removeClass("unloaded"):u.off():(u.on(),f()&&i.addClass("unloaded"))})}),$(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=$("#search-input"),t=ScrollHelper.getTopbarHeight();let e,a=0;function r(){0!==$(window).scrollTop()&&(ScrollHelper.lockOrientation(),ScrollHelper.hideTopbar())}screen.orientation?screen.orientation.onchange=()=>{var e=screen.orientation.type;"landscape-primary"!==e&&"landscape-secondary"!==e||r()}:$(window).on("orientationchange",()=>{$(window).width()<$(window).height()&&r()}),$(window).scroll(()=>{e=e||!0}),setInterval(()=>{e&&(function(){var e=$(this).scrollTop();if(!(Math.abs(a-e)<=t)){if(e>a)ScrollHelper.hideTopbar(),o.is(":focus")&&o.blur();else if(e+$(window).height()<$(document).height()){if(ScrollHelper.hasScrollUpTask())return;ScrollHelper.topbarLocked()?ScrollHelper.unlockTopbar():ScrollHelper.orientationLocked()?ScrollHelper.unLockOrientation():ScrollHelper.showTopbar()}a=e}}(),e=!1)},250)}),$(function(){var o="div.post>h1:first-of-type";const t=$(o),n=$("#topbar-title");if(0!==t.length&&!t.hasClass("dynamic-title")&&!n.is(":hidden")){const s=n.text().trim();let a=t.text().trim(),r=!1,l=0;($("#page-category").length||$("#page-tag").length)&&/\s/.test(a)&&(a=a.replace(/[0-9]/g,"").trim()),t.offset().top<$(window).scrollTop()&&n.text(a);let e=new IntersectionObserver(e=>{var o,t;r?(o=$(window).scrollTop(),t=l<o,l=o,e=e[0],t?0===e.intersectionRatio&&n.text(a):1===e.intersectionRatio&&n.text(s)):r=!0},{rootMargin:"-48px 0px 0px 0px",threshold:[0,1]});e.observe(document.querySelector(o)),n.click(function(){$("body,html").animate({scrollTop:0},800)})}});
6
+ $(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(){$(".mode-toggle").click(o=>{const e=$(o.target);let t=e.prop("tagName")==="button".toUpperCase()?e:e.parent();t.blur(),flipMode()})});const ScrollHelper=function(){const o=$("body"),e="data-topbar-visible",t=$("#topbar-wrapper").outerHeight();let l=0,r=!1,a=!1;return{hideTopbar:()=>o.attr(e,!1),showTopbar:()=>o.attr(e,!0),addScrollUpTask:()=>{l+=1,r=r||!0},popScrollUpTask:()=>--l,hasScrollUpTask:()=>0<l,topbarLocked:()=>!0===r,unlockTopbar:()=>r=!1,getTopbarHeight:()=>t,orientationLocked:()=>!0===a,lockOrientation:()=>a=!0,unLockOrientation:()=>a=!1}}();$(function(){const o=$("#sidebar-trigger"),e=$("#search-trigger"),t=$("#search-cancel"),l=$("#main"),r=$("#topbar-title"),a=$("#search-wrapper"),n=$("#search-result-wrapper"),s=$("#search-results"),i=$("#search-input"),c=$("#search-hints"),d=function(){let o=0;return{block(){o=window.scrollY,$("html,body").scrollTop(0)},release(){$("html,body").scrollTop(o)},getOffset(){return o}}}(),p={on(){o.addClass("unloaded"),r.addClass("unloaded"),e.addClass("unloaded"),a.addClass("d-flex"),t.addClass("loaded")},off(){t.removeClass("loaded"),a.removeClass("d-flex"),o.removeClass("unloaded"),r.removeClass("unloaded"),e.removeClass("unloaded")}},u=function(){let o=!1;return{on(){o||(d.block(),n.removeClass("unloaded"),l.addClass("unloaded"),o=!0)},off(){o&&(s.empty(),c.hasClass("unloaded")&&c.removeClass("unloaded"),n.addClass("unloaded"),l.removeClass("unloaded"),d.release(),i.val(""),o=!1)},isVisible(){return o}}}();function f(){return t.hasClass("loaded")}e.click(function(){p.on(),u.on(),i.focus()}),t.click(function(){p.off(),u.off()}),i.focus(function(){a.addClass("input-focus")}),i.focusout(function(){a.removeClass("input-focus")}),i.on("input",()=>{""===i.val()?f()?c.removeClass("unloaded"):u.off():(u.on(),f()&&c.addClass("unloaded"))})}),$(function(){var o=function(){const o="sidebar-display";let e=!1;const t=$("body");return{toggle(){!1===e?t.attr(o,""):t.removeAttr(o),e=!e}}}();$("#sidebar-trigger").click(o.toggle),$("#mask").click(o.toggle)}),$(function(){$('[data-toggle="tooltip"]').tooltip()}),$(function(){const e=$("#search-input"),t=ScrollHelper.getTopbarHeight();let o,l=0;function r(){0!==$(window).scrollTop()&&(ScrollHelper.lockOrientation(),ScrollHelper.hideTopbar())}screen.orientation?screen.orientation.onchange=()=>{var o=screen.orientation.type;"landscape-primary"!==o&&"landscape-secondary"!==o||r()}:$(window).on("orientationchange",()=>{$(window).width()<$(window).height()&&r()}),$(window).scroll(()=>{o=o||!0}),setInterval(()=>{o&&(!function(){var o=$(this).scrollTop();if(!(Math.abs(l-o)<=t)){if(o>l)ScrollHelper.hideTopbar(),e.is(":focus")&&e.blur();else if(o+$(window).height()<$(document).height()){if(ScrollHelper.hasScrollUpTask())return;ScrollHelper.topbarLocked()?ScrollHelper.unlockTopbar():ScrollHelper.orientationLocked()?ScrollHelper.unLockOrientation():ScrollHelper.showTopbar()}l=o}}(),o=!1)},250)}),$(function(){var e="div.post>h1:first-of-type";const t=$(e),n=$("#topbar-title");if(0!==t.length&&!t.hasClass("dynamic-title")&&!n.is(":hidden")){const s=n.text().trim();let l=t.text().trim(),r=!1,a=0;($("#page-category").length||$("#page-tag").length)&&/\s/.test(l)&&(l=l.replace(/[0-9]/g,"").trim()),t.offset().top<$(window).scrollTop()&&n.text(l);let o=new IntersectionObserver(o=>{var e,t;r?(t=$(window).scrollTop(),e=a<t,a=t,t=o[0],e?0===t.intersectionRatio&&n.text(l):1===t.intersectionRatio&&n.text(s)):r=!0},{rootMargin:"-48px 0px 0px 0px",threshold:[0,1]});o.observe(document.querySelector(e)),n.click(function(){$("body,html").animate({scrollTop:0},800)})}});