hexo-theme-gnix 5.0.1 → 5.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -34,7 +34,7 @@ module.exports = class extends Component {
34
34
  return (
35
35
  <Fragment>
36
36
  {/* Main content */}
37
- <div class="card article-wrapper">
37
+ <div class="card">
38
38
  {/* Cover image */}
39
39
  {cover ? (
40
40
  <ArticleCover
@@ -38,23 +38,8 @@ class Navbar extends Component {
38
38
  return (
39
39
  <nav class="navbar navbar-main" onclick="handleNavbarClick(event);">
40
40
  <div class="navbar-container">
41
- <a href={siteUrl}>
42
- <svg
43
- fill="var(--flamingo)"
44
- viewBox="0 0 1182.000000 750.000000"
45
- width="5em"
46
- height="100%"
47
- role="img"
48
- aria-label="Blog Logo"
49
- >
50
- <g
51
- transform="translate(0.000000,930.000000) scale(0.100000,-0.100000)"
52
- stroke="none"
53
- >
54
- <path d="M4915 7175 c-238 -39 -533 -139 -794 -270 -549 -275 -1067 -758 -1291 -1205 -73 -145 -95 -225 -94 -345 0 -120 23 -188 86 -260 203 -231 774 -132 1521 262 185 97 298 161 372 209 l30 19 -19 -30 c-11 -16 -50 -74 -88 -130 l-69 -100 -102 -46 c-564 -253 -1269 -905 -1508 -1394 -118 -241 -121 -414 -9 -525 149 -150 390 -86 629 165 150 158 405 524 664 951 80 132 212 348 294 480 l148 239 70 24 c84 28 203 38 262 22 57 -16 100 -54 115 -102 20 -69 78 -90 123 -45 l24 24 15 -22 c9 -15 11 -28 5 -37 -16 -26 -9 -34 10 -11 12 13 31 22 48 22 39 0 46 6 88 78 73 125 268 348 406 464 115 98 227 147 230 101 3 -48 -7 -88 -58 -232 -91 -257 -76 -348 63 -374 88 -17 295 69 544 226 l135 85 5 -92 c10 -163 74 -226 232 -226 155 0 283 58 523 235 61 45 141 107 179 138 38 32 72 57 76 57 4 0 18 -31 30 -69 l22 -70 -79 -93 c-139 -162 -240 -309 -300 -433 -48 -101 -43 -157 17 -170 44 -10 77 15 91 67 18 70 161 276 292 423 l44 50 41 -37 c102 -92 323 -101 573 -22 97 30 292 121 394 184 98 60 293 207 306 231 17 33 7 80 -22 102 -35 25 -52 19 -136 -50 -232 -191 -517 -330 -761 -370 -130 -21 -200 -13 -248 29 -18 16 -34 36 -34 44 0 7 55 63 123 125 304 277 553 444 736 495 61 17 62 17 77 -4 10 -14 26 -22 45 -22 45 0 67 16 75 56 5 29 2 40 -17 61 -41 43 -92 63 -162 63 -174 0 -434 -158 -805 -491 -68 -61 -125 -109 -126 -107 -1 1 -17 34 -35 71 -34 70 -76 108 -133 122 -22 6 -36 -3 -99 -60 -97 -89 -338 -270 -433 -324 -144 -82 -255 -110 -304 -75 -44 30 -24 141 53 294 24 47 52 94 64 104 29 26 26 52 -8 87 -22 21 -39 29 -66 29 -49 0 -69 -12 -104 -63 -33 -48 -307 -240 -486 -340 -108 -60 -241 -117 -274 -117 -27 0 -26 12 5 85 99 233 127 382 85 462 -33 66 -73 88 -156 88 -106 -1 -183 -45 -337 -194 -43 -41 -78 -71 -78 -68 0 10 60 118 82 146 63 82 -57 168 -131 94 -33 -34 -137 -260 -241 -522 l-77 -194 -17 49 c-22 68 -63 115 -134 152 -70 37 -173 54 -266 45 l-60 -6 79 114 c143 210 249 343 339 429 229 217 236 225 242 257 5 26 1 37 -19 57 -16 16 -37 26 -54 26 -39 0 -142 -80 -250 -193 -99 -104 -201 -187 -378 -305 -429 -286 -1057 -565 -1435 -636 -95 -18 -257 -21 -315 -5 -51 14 -110 73 -124 124 -47 168 80 462 316 736 425 490 995 840 1638 1004 235 60 436 71 493 27 23 -17 27 -26 24 -61 -3 -52 9 -76 47 -89 60 -21 101 26 101 116 0 85 -34 132 -125 174 -45 20 -68 23 -215 25 -107 1 -197 -3 -255 -12z m-536 -2152 c-13 -21 -54 -87 -93 -148 -38 -60 -130 -211 -204 -335 -156 -261 -360 -571 -492 -750 -203 -275 -393 -411 -497 -356 -117 60 -104 230 34 458 176 292 619 737 985 990 88 61 271 177 281 177 5 1 -2 -16 -14 -36z" />{" "}
55
- <path d="M7073 6016 c-60 -27 -83 -120 -42 -165 49 -53 119 -51 168 5 82 93 -11 212 -126 160z" />{" "}
56
- </g>
57
- </svg>
41
+ <a href={siteUrl} style={"font-family: homemade-apple; color: var(--text); display: flex; align-items: center; padding: 0 1em;"}>
42
+ GnixAij
58
43
  </a>
59
44
  <div class="navbar-menu">
60
45
  {Object.keys(menu).length ? (
package/layout/layout.jsx CHANGED
@@ -19,7 +19,7 @@ module.exports = class extends Component {
19
19
  <Navbar config={config} helper={helper} page={page} />
20
20
  <ThemeSelector />
21
21
  <section class="section">
22
- <div class="main-content" dangerouslySetInnerHTML={{ __html: body }} ></div>
22
+ <div class="main-content" id="swup" dangerouslySetInnerHTML={{ __html: body }} ></div>
23
23
  </section>
24
24
  <Footer site={site} config={config} helper={helper} />
25
25
  <Scripts site={site} config={config} helper={helper} page={page} />
@@ -6,12 +6,22 @@ class Swup extends Component {
6
6
  return null;
7
7
  }
8
8
 
9
- const swupScript =
10
- 'const swup = new Swup({ containers: [".main-content"], });';
9
+ const swupScript = `
10
+ const swup = new Swup({
11
+ containers: ["#swup"],
12
+ cache: true,
13
+ plugins: [
14
+ new SwupHeadPlugin({
15
+ persistTags: true
16
+ })
17
+ ]
18
+ });
19
+ `;
11
20
  return (
12
21
  <Fragment>
13
22
  <script src="/js/host/swup/Swup.umd.min.js"></script>
14
- <script dangerouslySetInnerHTML={{ __html: swupScript }}> </script>
23
+ <script src="/js/host/swup/head-plugin.umd.min.js"></script>
24
+ <script dangerouslySetInnerHTML={{ __html: swupScript }}></script>
15
25
  </Fragment>
16
26
  );
17
27
  }
package/layout/tag.jsx CHANGED
@@ -1,5 +1,33 @@
1
1
  const { Component, Fragment } = require("../include/util/common");
2
2
  const Index = require("./index");
3
+ const breadcrumb_css = `
4
+ .breadcrumb {
5
+ color: var(--blue);
6
+ white-space: nowrap;
7
+ font-family: Monaspace Radon, var(--font-mono);
8
+
9
+ a {
10
+ align-items: center;
11
+ display: flex;
12
+ justify-content: center;
13
+ padding: 0 0.1em;
14
+ }
15
+
16
+ ul {
17
+ align-items: flex-start;
18
+ display: flex;
19
+ flex-wrap: wrap;
20
+ justify-content: flex-start;
21
+ }
22
+
23
+ li {
24
+ align-items: center;
25
+ display: flex;
26
+ a {
27
+ color: var(--yellow);
28
+ }
29
+ }
30
+ }`;
3
31
 
4
32
  module.exports = class extends Component {
5
33
  render() {
@@ -8,15 +36,15 @@ module.exports = class extends Component {
8
36
 
9
37
  return (
10
38
  <Fragment>
39
+ <style>{breadcrumb_css}</style>
11
40
  <nav class="breadcrumb" aria-label="breadcrumbs">
12
41
  <ul>
13
42
  <li>
14
- {" "}
15
43
  <font style="color: var(--green)">$</font>&nbsp;ls&nbsp;
16
- <a href={url_for("/tags/")}>{_p("common.tag", Infinity)}</a>
44
+ <a href={url_for("/tags/")}>{_p("common.tag", Infinity)}/</a>
17
45
  </li>
18
- <li class="is-active">
19
- <a href="#" aria-current="page">
46
+ <li>
47
+ <a href="#" aria-current="page" style="cursor: default; pointer-events: none; color: var(--mauve);">
20
48
  {page.tag}
21
49
  </a>
22
50
  </li>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hexo-theme-gnix",
3
- "version": "5.0.1",
3
+ "version": "5.0.3",
4
4
  "author": "Efterklang <gaojiaxing0220@gmail.com>",
5
5
  "license": "MIT",
6
6
  "description": "Second generation of Hexo theme Icarus, now with Catppuccin flavor and night mode support.",
@@ -4,9 +4,9 @@
4
4
  --font-serif:
5
5
  "PT Serif", Georgia, "Times New Roman", Times, "Songti SC", "STSong", serif;
6
6
  --font-sans-serif:
7
- Avenir, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
8
- Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
9
- --font-monospace:
7
+ Avenir, system-ui, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell,
8
+ "Open Sans", "Helvetica Neue", sans-serif;
9
+ --font-mono:
10
10
  "Maple Mono NF CN Local", "Maple Mono NF CN", "SF Mono", "SF Pro", Monaco,
11
11
  Consolas, "Liberation Mono", "Courier New", monospace;
12
12
  --font-article:
@@ -14,6 +14,8 @@
14
14
  "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC",
15
15
  "Source Han Sans CN", sans-serif;
16
16
  --font-handwriting: "Bradley Hand", "homemade-apple", cursive;
17
+ --radius: 12px;
18
+ --spaceing: 0.25rem;
17
19
  }
18
20
 
19
21
  /* #region Color */
@@ -205,39 +207,6 @@ a:hover {
205
207
  color: var(--blue);
206
208
  }
207
209
 
208
- a.header-anchor:hover::after {
209
- margin-left: 0.2em;
210
- color: var(--surface0);
211
- }
212
-
213
- a.header-anchor {
214
- color: var(--text);
215
- }
216
-
217
- h3 a.header-anchor {
218
- &:hover::after {
219
- content: "###";
220
- }
221
- }
222
-
223
- h4 a.header-anchor {
224
- &:hover::after {
225
- content: "####";
226
- }
227
- }
228
-
229
- h5 a.header-anchor {
230
- &:hover::after {
231
- content: "#####";
232
- }
233
- }
234
-
235
- h6 a.header-anchor {
236
- &:hover::after {
237
- content: "######";
238
- }
239
- }
240
-
241
210
  mark {
242
211
  background-color: var(--yellow);
243
212
  }
@@ -250,10 +219,6 @@ mark {
250
219
  accent-color: var(--mauve);
251
220
  }
252
221
 
253
- blockquote::before {
254
- color: var(--red);
255
- }
256
-
257
222
  .article-licensing {
258
223
  color: var(--subtext1);
259
224
  border-top: 0.1px dashed var(--surface0);
@@ -262,7 +227,7 @@ blockquote::before {
262
227
  .navbar-main,
263
228
  .navbar-menu {
264
229
  user-select: none;
265
- background: hsl(from var(--mantle) h s l / 0.95);
230
+ background: var(--mantle);
266
231
  }
267
232
 
268
233
  body {
@@ -270,19 +235,11 @@ body {
270
235
  color: var(--text);
271
236
  }
272
237
 
273
- .card {
274
- border: 0.5px dashed var(--surface0);
275
- }
276
-
277
238
  input.task-list-item-checkbox:checked {
278
239
  background-color: var(--green);
279
240
  border-color: var(--green);
280
241
  }
281
242
 
282
- .navbar-item {
283
- color: var(--text);
284
- }
285
-
286
243
  hr {
287
244
  background-color: var(--surface0);
288
245
  }
@@ -361,15 +318,14 @@ input:-webkit-autofill {
361
318
 
362
319
  @font-face {
363
320
  font-family: homemade-apple;
364
- font-style: normal;
365
- font-weight: 400;
366
- font-display: swap;
367
- src: url(/css/font/woff2/HomemadeApple.woff2) format("woff2");
321
+ src:
322
+ local("Homemade Apple"),
323
+ local("HomemadeApple-Regular"),
324
+ url(/css/font/woff2/HomemadeApple.woff2) format("woff2");
368
325
  }
369
326
 
370
327
  /* #endregion */
371
328
 
372
- blockquote,
373
329
  body,
374
330
  dd,
375
331
  dl,
@@ -423,7 +379,6 @@ body {
423
379
  flex-direction: column;
424
380
  }
425
381
 
426
- .breadcrumb,
427
382
  .pagination-ellipsis,
428
383
  .pagination-link,
429
384
  .pagination-next,
@@ -435,49 +390,10 @@ body {
435
390
  user-select: none;
436
391
  }
437
392
 
438
- .breadcrumb:not(:last-child),
439
393
  .pagination:not(:last-child) {
440
394
  margin-bottom: 0.5rem;
441
395
  }
442
396
 
443
- .breadcrumb {
444
- white-space: nowrap;
445
- font-family: "Monaspace Radon", var(--font-monospace);
446
- }
447
-
448
- .breadcrumb a {
449
- align-items: center;
450
- display: flex;
451
- justify-content: center;
452
- padding: 0 0.1em;
453
- }
454
-
455
- .breadcrumb li {
456
- align-items: center;
457
- display: flex;
458
- }
459
-
460
- .breadcrumb li:first-child a {
461
- padding-left: 0;
462
- }
463
-
464
- .breadcrumb li.is-active a {
465
- cursor: default;
466
- pointer-events: none;
467
- }
468
-
469
- .breadcrumb li + li::before {
470
- content: "\0002f";
471
- }
472
-
473
- .breadcrumb ol,
474
- .breadcrumb ul {
475
- align-items: flex-start;
476
- display: flex;
477
- flex-wrap: wrap;
478
- justify-content: flex-start;
479
- }
480
-
481
397
  .toc-text,
482
398
  .footer,
483
399
  .widget {
@@ -487,8 +403,9 @@ body {
487
403
  .card {
488
404
  max-width: 100%;
489
405
  position: relative;
490
- border-radius: 24px;
491
406
  overflow: visible;
407
+ border-radius: var(--radius);
408
+ border: 0.5px dashed var(--surface0);
492
409
  }
493
410
 
494
411
  .card + .card {
@@ -511,6 +428,7 @@ body {
511
428
  transition: transform 0.3s ease-in-out;
512
429
  z-index: 100;
513
430
  font-family: var(--font-sans-serif);
431
+ border-bottom: 0.5px solid var(--surface0);
514
432
  }
515
433
 
516
434
  .navbar-container {
@@ -531,27 +449,18 @@ body {
531
449
  transform: translateY(-100%);
532
450
  }
533
451
 
534
- .navbar-menu {
535
- display: none;
536
- }
537
-
538
452
  .navbar-item {
453
+ color: var(--subtext1);
539
454
  align-items: center;
540
455
  display: flex;
541
456
  font-size: 1.1rem;
542
- padding: 0 0.4rem;
457
+ padding: 0 0.5rem;
543
458
  position: relative;
544
459
  flex-grow: 0;
545
460
  flex-shrink: 0;
546
- }
547
-
548
- .navbar-item svg {
549
- width: 15px;
550
- }
551
-
552
- .navbar-menu {
553
- flex-grow: 1;
554
- flex-shrink: 0;
461
+ svg {
462
+ width: 15px;
463
+ }
555
464
  }
556
465
 
557
466
  /* #endregion Navbar */
@@ -612,7 +521,7 @@ body {
612
521
  .theme-selector-hint {
613
522
  font-size: 0.875rem;
614
523
  color: var(--subtext0);
615
- font-family: var(--font-monospace);
524
+ font-family: var(--font-mono);
616
525
  }
617
526
 
618
527
  .theme-selector-list {
@@ -795,7 +704,7 @@ body {
795
704
  flex-grow: 1;
796
705
  margin: 0 auto;
797
706
  position: relative;
798
- max-width: 980px;
707
+ max-width: 1080px;
799
708
  }
800
709
 
801
710
  /* #region Footer */
@@ -882,6 +791,15 @@ body {
882
791
  text-decoration-color: var(--mauve);
883
792
  }
884
793
 
794
+ a.header-anchor {
795
+ color: var(--text);
796
+
797
+ &:hover::after {
798
+ margin-left: 0.2em;
799
+ color: var(--surface0);
800
+ }
801
+ }
802
+
885
803
  h2 {
886
804
  font-size: 2.25em;
887
805
  font-weight: 700;
@@ -890,9 +808,7 @@ body {
890
808
  margin: 1rem 0 1rem;
891
809
  border-bottom: 0.8px solid var(--surface0);
892
810
 
893
- a.header-anchor {
894
- color: var(--text);
895
-
811
+ > a.header-anchor {
896
812
  &:hover::after {
897
813
  content: "##";
898
814
  }
@@ -905,6 +821,12 @@ body {
905
821
  line-height: 1.25;
906
822
  letter-spacing: -0.015em;
907
823
  margin: 1.2rem 0 1rem;
824
+
825
+ > a.header-anchor {
826
+ &:hover::after {
827
+ content: "###";
828
+ }
829
+ }
908
830
  }
909
831
 
910
832
  h4 {
@@ -913,6 +835,12 @@ body {
913
835
  line-height: 1.25;
914
836
  letter-spacing: -0.01em;
915
837
  margin: 1.2rem 0 1rem;
838
+
839
+ > a.header-anchor {
840
+ &:hover::after {
841
+ content: "####";
842
+ }
843
+ }
916
844
  }
917
845
 
918
846
  h5 {
@@ -921,6 +849,12 @@ body {
921
849
  line-height: 1.25;
922
850
  letter-spacing: -0.005em;
923
851
  margin: 1.2rem 0 1rem;
852
+
853
+ > a.header-anchor {
854
+ &:hover::after {
855
+ content: "#####";
856
+ }
857
+ }
924
858
  }
925
859
 
926
860
  h6 {
@@ -928,6 +862,12 @@ body {
928
862
  font-weight: 600;
929
863
  line-height: 1.25;
930
864
  margin: 1.2rem 0 1rem;
865
+
866
+ > a.header-anchor {
867
+ &:hover::after {
868
+ content: "######";
869
+ }
870
+ }
931
871
  }
932
872
 
933
873
  .p:not(:last-child) {
@@ -935,37 +875,34 @@ body {
935
875
  }
936
876
 
937
877
  p,
938
- blockquote,
939
878
  ol,
940
879
  dl,
941
880
  pre,
942
881
  details {
943
- margin-top: 0;
944
882
  margin-bottom: 1rem;
945
883
  }
946
884
 
947
885
  p:last-child,
948
- ul:last-child,
949
- ol:last-child,
950
886
  .tabs-tabs-wrapper:last-child {
951
887
  margin-bottom: 0;
952
888
  }
953
889
 
954
- li + li {
955
- margin-top: 0.25em;
956
- }
957
-
958
890
  img,
959
891
  video {
960
892
  display: block;
961
893
  max-width: 100%;
962
- margin: 0 auto 0 auto;
894
+ margin: 0 auto;
963
895
 
964
896
  &:hover {
965
897
  cursor: pointer;
966
898
  }
967
899
  }
968
900
 
901
+ video,
902
+ .pic {
903
+ margin: 1em auto;
904
+ }
905
+
969
906
  ol {
970
907
  list-style-position: outside;
971
908
  padding-left: 2em;
@@ -1035,14 +972,12 @@ body {
1035
972
 
1036
973
  code {
1037
974
  font-size: 0.85em;
1038
- font-weight: 400;
1039
- font-family: var(--font-monospace);
1040
- padding: 0 0.15em;
1041
- margin: 0 0.1em;
975
+ font-family: var(--font-mono);
976
+ padding: 0 0.25em;
1042
977
  background-color: var(--base);
1043
978
  color: var(--subtext1);
1044
979
  border: 1px solid var(--surface0);
1045
- border-radius: 6px;
980
+ border-radius: 4px;
1046
981
  }
1047
982
 
1048
983
  sub,
@@ -1060,7 +995,7 @@ body {
1060
995
  a[href*="github"]::before,
1061
996
  a[href*="wikipedia"]::before,
1062
997
  a[href*="youtube"]::before {
1063
- font-family: var(--font-monospace);
998
+ font-family: var(--font-mono);
1064
999
  font-size: 1em;
1065
1000
  padding-left: 0.5em;
1066
1001
  color: var(--lavender);
@@ -1089,6 +1024,8 @@ body {
1089
1024
  }
1090
1025
 
1091
1026
  table {
1027
+ table-layout: fixed;
1028
+ word-wrap: break-word;
1092
1029
  width: 100%;
1093
1030
  border-collapse: separate;
1094
1031
  border-spacing: 0;
@@ -1131,20 +1068,18 @@ blockquote {
1131
1068
  border-left: 2px solid var(--red);
1132
1069
  border-radius: 0 8px 8px 0;
1133
1070
  font-family: var(--font-serif);
1134
- font-style: italic;
1135
- font-size: 1rem;
1136
- line-height: 1.5;
1137
- }
1138
1071
 
1139
- blockquote:before {
1140
- content: "”";
1141
- position: absolute;
1142
- left: 0.5rem;
1143
- top: 0.2rem;
1144
- font-size: 3rem;
1145
- font-weight: 700;
1146
- opacity: 0.3;
1147
- line-height: 1;
1072
+ &:before {
1073
+ content: "”";
1074
+ color: var(--red);
1075
+ position: absolute;
1076
+ left: 0.5rem;
1077
+ top: 0.2rem;
1078
+ font-size: 3rem;
1079
+ font-weight: 700;
1080
+ opacity: 0.3;
1081
+ line-height: 1;
1082
+ }
1148
1083
  }
1149
1084
 
1150
1085
  ul.contains-task-list {
@@ -1172,7 +1107,7 @@ input.task-list-item-checkbox {
1172
1107
 
1173
1108
  input.task-list-item-checkbox:checked::before {
1174
1109
  content: "";
1175
- font-family: var(--font-monospace);
1110
+ font-family: var(--font-mono);
1176
1111
  color: var(--base);
1177
1112
  position: absolute;
1178
1113
  top: 50%;
@@ -1263,15 +1198,14 @@ section {
1263
1198
  letter-spacing: -0.02em;
1264
1199
  margin-bottom: 0.3em;
1265
1200
  color: var(--text);
1266
- word-break: break-word;
1267
- }
1268
1201
 
1269
- .article-title a {
1270
- color: inherit;
1202
+ > a {
1203
+ color: inherit;
1204
+ }
1271
1205
  }
1272
1206
 
1273
1207
  .article-header-meta {
1274
- font-family: var(--font-monospace);
1208
+ font-family: var(--font-mono);
1275
1209
  overflow: auto;
1276
1210
  padding-bottom: 0.5em;
1277
1211
  margin-bottom: 1rem;
@@ -1370,7 +1304,7 @@ section {
1370
1304
  width: 100%;
1371
1305
  height: 100%;
1372
1306
  z-index: 100;
1373
- font-family: monospace, var(--font-monospace);
1307
+ font-family: monospace, var(--font-mono);
1374
1308
  line-height: 0;
1375
1309
  opacity: 0;
1376
1310
  visibility: hidden;
@@ -1471,7 +1405,7 @@ input.searchbox-input {
1471
1405
  position: relative;
1472
1406
  display: block;
1473
1407
  overflow: hidden;
1474
- border-radius: 24px 24px 0 0;
1408
+ border-radius: var(--radius) var(--radius) 0 0;
1475
1409
  height: 380px;
1476
1410
 
1477
1411
  .cover-image-placeholder {
@@ -1496,4 +1430,3 @@ input.searchbox-input {
1496
1430
  }
1497
1431
 
1498
1432
  /* #endregion Article Cover */
1499
-
@@ -12,28 +12,28 @@
12
12
  }
13
13
 
14
14
  /* navbar */
15
- .navbar-main .navbar-menu,
16
- .navbar-main .navbar-start,
17
- .navbar-main .navbar-end {
15
+ .navbar-menu,
16
+ .navbar-start,
17
+ .navbar-end {
18
18
  align-items: stretch;
19
19
  display: flex;
20
20
  padding: 0;
21
21
  flex-shrink: 0;
22
22
  }
23
23
 
24
- .navbar-main .navbar-menu {
24
+ .navbar-menu {
25
25
  flex-grow: 1;
26
26
  flex-shrink: 0;
27
27
  overflow-x: auto;
28
28
  background-color: transparent;
29
29
  }
30
30
 
31
- .navbar-main .navbar-start {
31
+ .navbar-start {
32
32
  justify-content: flex-start;
33
33
  margin-right: auto;
34
34
  }
35
35
 
36
- .navbar-main .navbar-end {
36
+ .navbar-end {
37
37
  justify-content: flex-end;
38
38
  margin-left: auto;
39
39
  }
@@ -161,4 +161,4 @@
161
161
  padding: 0;
162
162
  margin: 0;
163
163
  display: contents;
164
- }
164
+ }
@@ -13,6 +13,7 @@ span.year {
13
13
 
14
14
  table {
15
15
  font-size: 14px;
16
+ word-wrap: break-word;
16
17
  }
17
18
 
18
19
  table th,
@@ -1,7 +1,8 @@
1
1
  /* This is used for mobile and tablet devices */
2
2
  /* #region Navbar */
3
3
  /* Navbar Burger */
4
- .navbar-main .navbar-menu {
4
+ .navbar-menu {
5
+ display: none;
5
6
  padding: 0.5rem 0;
6
7
  }
7
8
 
@@ -1,5 +1,5 @@
1
1
  .code-title {
2
- font-size: .75em;
2
+ font-size: 0.75em;
3
3
  font-style: italic;
4
4
  }
5
5
 
@@ -33,20 +33,39 @@ code span {
33
33
  }
34
34
 
35
35
  figure.shiki {
36
- margin: 0 0 24px;
36
+ margin: 0.5em 0;
37
37
  border-radius: 8px;
38
38
  border: 0.5px solid var(--surface0);
39
39
  overflow: auto;
40
40
  background: var(--mantle);
41
41
  color: var(--text);
42
+
43
+ iconify-icon {
44
+ color: transparent;
45
+ cursor: pointer;
46
+ transition:
47
+ color 0.3s,
48
+ transform 0.3s ease;
49
+ }
50
+
51
+ &:hover {
52
+ iconify-icon {
53
+ color: var(--text);
54
+
55
+ &:hover {
56
+ color: var(--blue);
57
+ transform: scale(1.2);
58
+ }
59
+ }
60
+ }
42
61
  }
43
62
 
44
63
  .shiki-tools {
45
64
  display: flex;
46
65
  min-height: 1.5em;
47
66
  justify-content: space-between;
48
- font-family: var(--font-monospace);
49
- padding: 0 15px;
67
+ font-family: var(--font-mono);
68
+ padding: 0.3em 1em;
50
69
  user-select: none;
51
70
  overflow: hidden;
52
71
  position: relative;
@@ -66,18 +85,6 @@ figure.shiki {
66
85
  min-width: 0;
67
86
  }
68
87
 
69
- iconify-icon {
70
- cursor: pointer;
71
- transition:
72
- color 0.3s,
73
- transform 0.3s ease;
74
-
75
- &:hover {
76
- transform: scale(1.1);
77
- color: var(--blue);
78
- }
79
- }
80
-
81
88
  > .right {
82
89
  gap: 10px;
83
90
  display: flex;
@@ -85,15 +92,6 @@ figure.shiki {
85
92
  }
86
93
  }
87
94
 
88
- .shiki-tools .expand {
89
- font-size: 1.2em;
90
- margin-left: -2px;
91
- }
92
-
93
- .shiki-tools .expand.closed {
94
- transform: rotate(90deg);
95
- }
96
-
97
95
  .shiki-tools > .right > .copy-notice {
98
96
  position: absolute;
99
97
  white-space: nowrap;
@@ -115,15 +113,14 @@ figure.shiki {
115
113
  .traffic-lights {
116
114
  display: flex;
117
115
  align-items: center;
118
- padding-right: 8px;
119
- margin-left: -7px;
116
+ margin-left: -0.5em;
120
117
  }
121
118
 
122
119
  .traffic-light {
123
- width: 14px;
124
- height: 14px;
120
+ width: 0.8em;
121
+ height: 0.8em;
125
122
  border-radius: 50%;
126
- margin-left: 8px;
123
+ margin-left: 0.5em;
127
124
  position: relative;
128
125
 
129
126
  &.red {
@@ -140,7 +137,6 @@ figure.shiki {
140
137
  }
141
138
 
142
139
  @keyframes code-expand-pulse {
143
-
144
140
  0%,
145
141
  to {
146
142
  opacity: 0.6;
@@ -186,23 +182,7 @@ pre.shiki {
186
182
  border: none !important;
187
183
  width: 100%;
188
184
  margin: 0;
189
- font-family: var(--font-monospace);
190
-
191
- > span.line {
192
- display: block;
193
- width: fit-content;
194
- min-width: 100%;
195
-
196
- &:before {
197
- content: counter(step);
198
- counter-increment: step;
199
- width: 1.2rem;
200
- margin-right: 1.2rem;
201
- display: inline-block;
202
- text-align: right;
203
- color: #738a9466;
204
- }
205
- }
185
+ font-family: var(--font-mono);
206
186
  }
207
187
  }
208
188
 
@@ -225,10 +205,12 @@ figure.shiki[data-collapsible="true"]:not(.expanded) > pre.shiki:after {
225
205
  height: 80px;
226
206
  pointer-events: none;
227
207
  z-index: 1;
228
- background: linear-gradient(transparent 0%,
229
- hsl(from var(--mantle) h s l / 0.8),
230
- 30%,
231
- var(--mantle) 100%);
208
+ background: linear-gradient(
209
+ transparent 0%,
210
+ hsl(from var(--mantle) h s l / 0.8),
211
+ 30%,
212
+ var(--mantle) 100%
213
+ );
232
214
  opacity: 1;
233
215
  }
234
216
 
@@ -236,6 +218,22 @@ figure.shiki[data-collapsible="true"].expanded > .code-expand-btn {
236
218
  transform: translateY(0);
237
219
  }
238
220
 
221
+ span.line {
222
+ display: block;
223
+ width: fit-content;
224
+ min-width: 100%;
225
+
226
+ &:before {
227
+ content: counter(step);
228
+ counter-increment: step;
229
+ width: 1.2rem;
230
+ margin-right: 1.2rem;
231
+ display: inline-block;
232
+ text-align: right;
233
+ color: var(--subtext0);
234
+ }
235
+ }
236
+
239
237
  span.line.diff {
240
238
  &.remove {
241
239
  background-color: hsl(from var(--red) h s l / 0.2);
@@ -1655,4 +1653,4 @@ pre.shiki.has-focused > code {
1655
1653
  --shiki-nord-font-weight: inherit;
1656
1654
  --shiki-tokyo: #89ddff;
1657
1655
  --shiki-tokyo-font-weight: bold;
1658
- }
1656
+ }
@@ -0,0 +1,2 @@
1
+ !function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e||self).SwupHeadPlugin=t()}(this,function(){function e(){return e=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},e.apply(this,arguments)}const t=e=>String(e).split(".").map(e=>String(parseInt(e||"0",10))).concat(["0","0"]).slice(0,3).join(".");class n{constructor(){this.isSwupPlugin=!0,this.swup=void 0,this.version=void 0,this.requires={},this.handlersToUnregister=[]}mount(){}unmount(){this.handlersToUnregister.forEach(e=>e()),this.handlersToUnregister=[]}_beforeMount(){if(!this.name)throw new Error("You must define a name of plugin when creating a class.")}_afterUnmount(){}_checkRequirements(){return"object"!=typeof this.requires||Object.entries(this.requires).forEach(([e,n])=>{if(!function(e,n,r){const s=function(e,t){var n;if("swup"===e)return null!=(n=t.version)?n:"";{var r;const n=t.findPlugin(e);return null!=(r=null==n?void 0:n.version)?r:""}}(e,r);return!!s&&((e,n)=>n.every(n=>{const[,r,s]=n.match(/^([\D]+)?(.*)$/)||[];var o,i;return((e,t)=>{const n={"":e=>0===e,">":e=>e>0,">=":e=>e>=0,"<":e=>e<0,"<=":e=>e<=0};return(n[t]||n[""])(e)})((i=s,o=t(o=e),i=t(i),o.localeCompare(i,void 0,{numeric:!0})),r||">=")}))(s,n)}(e,n=Array.isArray(n)?n:[n],this.swup)){const t=`${e} ${n.join(", ")}`;throw new Error(`Plugin version mismatch: ${this.name} requires ${t}`)}}),!0}on(e,t,n={}){var r;t=!(r=t).name.startsWith("bound ")||r.hasOwnProperty("prototype")?t.bind(this):t;const s=this.swup.hooks.on(e,t,n);return this.handlersToUnregister.push(s),s}once(t,n,r={}){return this.on(t,n,e({},r,{once:!0}))}before(t,n,r={}){return this.on(t,n,e({},r,{before:!0}))}replace(t,n,r={}){return this.on(t,n,e({},r,{replace:!0}))}off(e,t){return this.swup.hooks.off(e,t)}}function r(e){return"title"!==e.localName&&!e.matches("[data-swup-theme]")}function s(e,t){return e.outerHTML===t.outerHTML}function o(e,t){void 0===t&&(t=[]);const n=Array.from(e.attributes);return t.length?n.filter(e=>{let{name:n}=e;return t.some(e=>e instanceof RegExp?e.test(n):n===e)}):n}function i(e){return e.matches("link[rel=stylesheet][href]")}return class extends n{constructor(e){void 0===e&&(e={}),super();const t=this;this.name="SwupHeadPlugin",this.requires={swup:">=4.6"},this.defaults={persistTags:!1,persistAssets:!1,awaitAssets:!1,attributes:["lang","dir"],timeout:3e3},this.options=void 0,this.updateHead=function(e,n){try{const{awaitAssets:n,attributes:u,timeout:a}=t.options,l=e.to.document,{removed:c,added:h}=function(e,t,n){let{shouldPersist:o=()=>!1}=void 0===n?{}:n;const i=Array.from(e.children),u=Array.from(t.children),a=(l=i,u.reduce((e,t,n)=>(l.some(e=>s(t,e))||e.push({el:t,index:n}),e),[]));var l;const c=function(e,t){return e.reduce((e,n)=>(t.some(e=>s(n,e))||e.push({el:n}),e),[])}(i,u);c.reverse().filter(e=>{let{el:t}=e;return r(t)}).filter(e=>{let{el:t}=e;return!o(t)}).forEach(t=>{let{el:n}=t;return e.removeChild(n)});const h=a.filter(e=>{let{el:t}=e;return r(t)}).map(t=>{let n=t.el.cloneNode(!0);return e.insertBefore(n,e.children[(t.index||0)+1]||null),{...t,el:n}});return{removed:c.map(e=>{let{el:t}=e;return t}),added:h.map(e=>{let{el:t}=e;return t})}}(document.head,l.head,{shouldPersist:e=>t.isPersistentTag(e)});t.swup.log(`Removed ${c.length} / added ${h.length} tags in head`),u?.length&&function(e,t,n){void 0===n&&(n=[]);const r=new Set;for(const{name:s,value:i}of o(t,n))e.setAttribute(s,i),r.add(s);for(const{name:t}of o(e,n))r.has(t)||e.removeAttribute(t)}(document.documentElement,l.documentElement,u);const d=function(){if(n){const n=(void 0===(e=a)&&(e=0),h.filter(i).map(t=>function(e,t){let n;void 0===t&&(t=0);const r=t=>{e.sheet?t():n=setTimeout(()=>r(t),10)};return new Promise(s=>{r(()=>s(e)),t>0&&setTimeout(()=>{n&&clearTimeout(n),s(e)},t)})}(t,e))),r=function(){if(n.length)return t.swup.log(`Waiting for ${n.length} assets to load`),Promise.resolve(Promise.all(n)).then(function(){})}();if(r&&r.then)return r.then(function(){})}var e}();return Promise.resolve(d&&d.then?d.then(function(){}):void 0)}catch(e){return Promise.reject(e)}},this.options={...this.defaults,...e},this.options.persistAssets&&!this.options.persistTags&&(this.options.persistTags="link[rel=stylesheet], script[src], style")}mount(){this.before("content:replace",this.updateHead)}isPersistentTag(e){const{persistTags:t}=this.options;return"function"==typeof t?t(e):"string"==typeof t&&t.length>0?e.matches(t):Boolean(t)}}});
2
+ //# sourceMappingURL=index.umd.js.map
@@ -120,6 +120,7 @@
120
120
  const maxIndex = themeOptions.length - 1;
121
121
 
122
122
  switch (event.key) {
123
+ case "j":
123
124
  case "ArrowDown":
124
125
  case "Down":
125
126
  event.preventDefault();
@@ -127,6 +128,7 @@
127
128
  updateFocus(themeOptions);
128
129
  break;
129
130
 
131
+ case "k":
130
132
  case "ArrowUp":
131
133
  case "Up":
132
134
  event.preventDefault();