hexo-theme-ayeria 1.9.10 → 1.9.13

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.
Files changed (95) hide show
  1. package/LICENSE +37 -37
  2. package/README.en.md +560 -560
  3. package/README.md +560 -560
  4. package/_config.yml +271 -271
  5. package/_scaffolds/post.md +8 -8
  6. package/index.js +11 -2
  7. package/languages/de.yml +39 -39
  8. package/languages/default.yml +40 -39
  9. package/languages/en.yml +40 -39
  10. package/languages/es.yml +39 -39
  11. package/languages/fr.yml +39 -39
  12. package/languages/ja.yml +39 -39
  13. package/languages/ko.yml +39 -39
  14. package/languages/nl.yml +39 -39
  15. package/languages/no.yml +39 -39
  16. package/languages/pt.yml +39 -39
  17. package/languages/ru.yml +39 -39
  18. package/languages/vi.yml +39 -39
  19. package/languages/zh-CN.yml +40 -39
  20. package/languages/zh-TW.yml +40 -39
  21. package/layout/_partial/ads.ejs +8 -8
  22. package/layout/_partial/after-footer.ejs +84 -84
  23. package/layout/_partial/archive-post.ejs +13 -13
  24. package/layout/_partial/archive.ejs +61 -61
  25. package/layout/_partial/article.ejs +94 -94
  26. package/layout/_partial/ayeria.ejs +53 -53
  27. package/layout/_partial/baidu-analytics.ejs +11 -11
  28. package/layout/_partial/broadcast.ejs +19 -19
  29. package/layout/_partial/float-btns.ejs +7 -7
  30. package/layout/_partial/footer.ejs +61 -61
  31. package/layout/_partial/google-analytics.ejs +10 -10
  32. package/layout/_partial/head.ejs +64 -68
  33. package/layout/_partial/katex.ejs +21 -21
  34. package/layout/_partial/lock.ejs +37 -37
  35. package/layout/_partial/mathjax.ejs +18 -18
  36. package/layout/_partial/modal.ejs +70 -76
  37. package/layout/_partial/music.ejs +15 -15
  38. package/layout/_partial/post/albums.ejs +16 -16
  39. package/layout/_partial/post/author.ejs +7 -7
  40. package/layout/_partial/post/busuanzi.ejs +4 -4
  41. package/layout/_partial/post/category.ejs +9 -9
  42. package/layout/_partial/post/clipboard.ejs +54 -54
  43. package/layout/_partial/post/date.ejs +2 -2
  44. package/layout/_partial/post/gallery.ejs +15 -15
  45. package/layout/_partial/post/giscus.ejs +40 -40
  46. package/layout/_partial/post/gitalk.ejs +12 -12
  47. package/layout/_partial/post/justifiedGallery.ejs +8 -8
  48. package/layout/_partial/post/nav.ejs +22 -22
  49. package/layout/_partial/post/search.ejs +3 -3
  50. package/layout/_partial/post/share.ejs +53 -53
  51. package/layout/_partial/post/tag.ejs +5 -5
  52. package/layout/_partial/post/title.ejs +16 -16
  53. package/layout/_partial/post/tocbot.ejs +6 -6
  54. package/layout/_partial/post/topping.ejs +2 -2
  55. package/layout/_partial/post/twikoo.ejs +7 -7
  56. package/layout/_partial/post/valine.ejs +48 -48
  57. package/layout/_partial/post/word.ejs +19 -19
  58. package/layout/_partial/sidebar.ejs +48 -33
  59. package/layout/_partial/viewer.ejs +105 -105
  60. package/layout/categories.ejs +8 -8
  61. package/layout/friends.ejs +19 -19
  62. package/layout/index.ejs +4 -4
  63. package/layout/layout.ejs +35 -30
  64. package/layout/page.ejs +2 -2
  65. package/layout/plain-page.ejs +4 -4
  66. package/layout/post.ejs +2 -2
  67. package/layout/tags.ejs +88 -88
  68. package/package.json +39 -39
  69. package/scripts/default_config.js +6 -6
  70. package/scripts/events/index.js +11 -11
  71. package/scripts/events/lib/hello.js +38 -38
  72. package/scripts/events/lib/merge-configs.js +28 -28
  73. package/scripts/filters/index.js +13 -13
  74. package/scripts/filters/meta_generator.js +17 -17
  75. package/scripts/helpers/ayeria-plus-vendors.js +9 -9
  76. package/scripts/helpers/category-tree.js +90 -90
  77. package/scripts/helpers/wordcount.js +39 -39
  78. package/scripts/lib/core.js +25 -25
  79. package/scripts/utils/join-path.js +12 -12
  80. package/scripts/utils/object.js +31 -31
  81. package/source/404.html +187 -187
  82. package/source/css/ayeria-layout.styl +48 -48
  83. package/source/css/clipboard.styl +37 -37
  84. package/source/css/custom.styl +17 -17
  85. package/source/css/fonts/remixicon.css +1816 -1816
  86. package/source/css/fonts/remixicon.svg +5329 -5329
  87. package/source/data/random-sentences.txt +2629 -141
  88. package/source/dist/main.css +1 -1
  89. package/source/dist/main.js +1 -1
  90. package/source/js/clickBoom1.js +152 -152
  91. package/source/js/clickBoom2.js +180 -180
  92. package/source/js/jquery-3.6.0.min.js +2 -2
  93. package/source/js/lazyload.min.js +7 -7
  94. package/source/js/search.js +126 -126
  95. package/source/js/random-sentences.js +0 -166
@@ -1,54 +1,54 @@
1
- <script src="https://cdn.staticfile.org/clipboard.js/2.0.10/clipboard.min.js"></script>
2
- <script>
3
- function wait(callback, seconds) {
4
- var timelag = null;
5
- timelag = window.setTimeout(callback, seconds);
6
- }
7
- !function (e, t, a) {
8
- var initCopyCode = function(){
9
- var copyHtml = '';
10
- copyHtml += '<button class="btn-copy" data-clipboard-snippet="">';
11
- copyHtml += '<i class="ri-file-copy-2-line"></i><span>COPY</span>';
12
- copyHtml += '</button>';
13
- $(".highlight .code pre").before(copyHtml);
14
- $(".article pre code").before(copyHtml);
15
- var clipboard = new ClipboardJS('.btn-copy', {
16
- target: function(trigger) {
17
- return trigger.nextElementSibling;
18
- }
19
- });
20
- clipboard.on('success', function(e) {
21
- let $btn = $(e.trigger);
22
- $btn.addClass('copied');
23
- let $icon = $($btn.find('i'));
24
- $icon.removeClass('ri-file-copy-2-line');
25
- $icon.addClass('ri-checkbox-circle-line');
26
- let $span = $($btn.find('span'));
27
- $span[0].innerText = 'COPIED';
28
-
29
- wait(function () { // 等待两秒钟后恢复
30
- $icon.removeClass('ri-checkbox-circle-line');
31
- $icon.addClass('ri-file-copy-2-line');
32
- $span[0].innerText = 'COPY';
33
- }, 2000);
34
- });
35
- clipboard.on('error', function(e) {
36
- e.clearSelection();
37
- let $btn = $(e.trigger);
38
- $btn.addClass('copy-failed');
39
- let $icon = $($btn.find('i'));
40
- $icon.removeClass('ri-file-copy-2-line');
41
- $icon.addClass('ri-time-line');
42
- let $span = $($btn.find('span'));
43
- $span[0].innerText = 'COPY FAILED';
44
-
45
- wait(function () { // 等待两秒钟后恢复
46
- $icon.removeClass('ri-time-line');
47
- $icon.addClass('ri-file-copy-2-line');
48
- $span[0].innerText = 'COPY';
49
- }, 2000);
50
- });
51
- }
52
- initCopyCode();
53
- }(window, document);
54
- </script>
1
+ <script src="https://cdn.staticfile.org/clipboard.js/2.0.10/clipboard.min.js"></script>
2
+ <script>
3
+ function wait(callback, seconds) {
4
+ var timelag = null;
5
+ timelag = window.setTimeout(callback, seconds);
6
+ }
7
+ !function (e, t, a) {
8
+ var initCopyCode = function(){
9
+ var copyHtml = '';
10
+ copyHtml += '<button class="btn-copy" data-clipboard-snippet="">';
11
+ copyHtml += '<i class="ri-file-copy-2-line"></i><span>COPY</span>';
12
+ copyHtml += '</button>';
13
+ $(".highlight .code pre").before(copyHtml);
14
+ $(".article pre code").before(copyHtml);
15
+ var clipboard = new ClipboardJS('.btn-copy', {
16
+ target: function(trigger) {
17
+ return trigger.nextElementSibling;
18
+ }
19
+ });
20
+ clipboard.on('success', function(e) {
21
+ let $btn = $(e.trigger);
22
+ $btn.addClass('copied');
23
+ let $icon = $($btn.find('i'));
24
+ $icon.removeClass('ri-file-copy-2-line');
25
+ $icon.addClass('ri-checkbox-circle-line');
26
+ let $span = $($btn.find('span'));
27
+ $span[0].innerText = 'COPIED';
28
+
29
+ wait(function () { // 等待两秒钟后恢复
30
+ $icon.removeClass('ri-checkbox-circle-line');
31
+ $icon.addClass('ri-file-copy-2-line');
32
+ $span[0].innerText = 'COPY';
33
+ }, 2000);
34
+ });
35
+ clipboard.on('error', function(e) {
36
+ e.clearSelection();
37
+ let $btn = $(e.trigger);
38
+ $btn.addClass('copy-failed');
39
+ let $icon = $($btn.find('i'));
40
+ $icon.removeClass('ri-file-copy-2-line');
41
+ $icon.addClass('ri-time-line');
42
+ let $span = $($btn.find('span'));
43
+ $span[0].innerText = 'COPY FAILED';
44
+
45
+ wait(function () { // 等待两秒钟后恢复
46
+ $icon.removeClass('ri-time-line');
47
+ $icon.addClass('ri-file-copy-2-line');
48
+ $span[0].innerText = 'COPY';
49
+ }, 2000);
50
+ });
51
+ }
52
+ initCopyCode();
53
+ }(window, document);
54
+ </script>
@@ -1,3 +1,3 @@
1
- <a href="<%- url_for(post.path) %>" class="<%= class_name %>">
2
- <time datetime="<%= date_xml(post.date) %>" itemprop="datePublished"><%= date(post.date, date_format) %></time>
1
+ <a href="<%- url_for(post.path) %>" class="<%= class_name %>">
2
+ <time datetime="<%= date_xml(post.date) %>" itemprop="datePublished"><%= date(post.date, date_format) %></time>
3
3
  </a>
@@ -1,15 +1,15 @@
1
- <% if (post.photos && post.photos.length){ %>
2
- <div class="article-gallery">
3
- <div class="article-gallery-photos">
4
- <% post.photos.forEach(function(photo, i){ %>
5
- <% if (index){ %>
6
- <a class="article-gallery-img" href="<%- url_for(post.path) %>" rel="gallery_<%= post._id %>">
7
- <img src="<%- url_for(photo) %>" itemprop="image">
8
- </a>
9
- <% } else { %>
10
- <img src="<%- url_for(photo) %>" itemprop="image">
11
- <% } %>
12
- <% }) %>
13
- </div>
14
- </div>
15
- <% } %>
1
+ <% if (post.photos && post.photos.length){ %>
2
+ <div class="article-gallery">
3
+ <div class="article-gallery-photos">
4
+ <% post.photos.forEach(function(photo, i){ %>
5
+ <% if (index){ %>
6
+ <a class="article-gallery-img" href="<%- url_for(post.path) %>" rel="gallery_<%= post._id %>">
7
+ <img src="<%- url_for(photo) %>" itemprop="image">
8
+ </a>
9
+ <% } else { %>
10
+ <img src="<%- url_for(photo) %>" itemprop="image">
11
+ <% } %>
12
+ <% }) %>
13
+ </div>
14
+ </div>
15
+ <% } %>
@@ -1,40 +1,40 @@
1
- <% if (theme.giscus && theme.giscus.enable && post.comments !== false) { %>
2
- <div class="giscus-container" style="margin-top: 2rem; padding: 0 1rem;">
3
- <script
4
- src="https://giscus.app/client.js"
5
- data-repo="<%- theme.giscus.repo %>"
6
- data-repo-id="<%- theme.giscus.repo_id %>"
7
- data-category="<%- theme.giscus.category %>"
8
- data-category-id="<%- theme.giscus.category_id %>"
9
- data-mapping="<%- theme.giscus.mapping || 'pathname' %>"
10
- data-strict="0"
11
- data-reactions-enabled="<%- theme.giscus.reactions_enabled || 1 %>"
12
- data-emit-metadata="<%- theme.giscus.emit_metadata || 0 %>"
13
- data-input-position="<%- theme.giscus.input_position || 'top' %>"
14
- data-theme="dark"
15
- data-lang="<%- theme.giscus.lang || 'zh-CN' %>"
16
- crossorigin="anonymous"
17
- async
18
- ></script>
19
- <script>
20
- /* giscus 通过 async 加载,iframe 可能在 ayeria.js 初始化之后才就绪。
21
- 站点默认暗色模式所以 data-theme="dark" 覆盖多数情况,
22
- 但若用户之前选择了亮色模式(sessionStorage darkmode==0),
23
- 需要在 iframe 就绪后修正主题。 */
24
- if (sessionStorage.getItem("darkmode") == 0) {
25
- window.addEventListener("message", function _giscusThemeFix(e) {
26
- if (e.origin !== "https://giscus.app") return;
27
- if (!(typeof e.data === "object" && e.data.giscus)) return;
28
- var f = document.querySelector("iframe.giscus-frame");
29
- if (f) {
30
- f.contentWindow.postMessage(
31
- { giscus: { setConfig: { theme: "light" } } },
32
- "https://giscus.app"
33
- );
34
- }
35
- window.removeEventListener("message", _giscusThemeFix);
36
- });
37
- }
38
- </script>
39
- </div>
40
- <% } %>
1
+ <% if (theme.giscus && theme.giscus.enable && post.comments !== false) { %>
2
+ <div class="giscus-container" style="margin-top: 2rem; padding: 0 1rem;">
3
+ <script
4
+ src="https://giscus.app/client.js"
5
+ data-repo="<%- theme.giscus.repo %>"
6
+ data-repo-id="<%- theme.giscus.repo_id %>"
7
+ data-category="<%- theme.giscus.category %>"
8
+ data-category-id="<%- theme.giscus.category_id %>"
9
+ data-mapping="<%- theme.giscus.mapping || 'pathname' %>"
10
+ data-strict="0"
11
+ data-reactions-enabled="<%- theme.giscus.reactions_enabled || 1 %>"
12
+ data-emit-metadata="<%- theme.giscus.emit_metadata || 0 %>"
13
+ data-input-position="<%- theme.giscus.input_position || 'top' %>"
14
+ data-theme="dark"
15
+ data-lang="<%- theme.giscus.lang || 'zh-CN' %>"
16
+ crossorigin="anonymous"
17
+ async
18
+ ></script>
19
+ <script>
20
+ /* giscus 通过 async 加载,iframe 可能在 ayeria.js 初始化之后才就绪。
21
+ 站点默认暗色模式所以 data-theme="dark" 覆盖多数情况,
22
+ 但若用户之前选择了亮色模式(sessionStorage darkmode==0),
23
+ 需要在 iframe 就绪后修正主题。 */
24
+ if (sessionStorage.getItem("darkmode") == 0) {
25
+ window.addEventListener("message", function _giscusThemeFix(e) {
26
+ if (e.origin !== "https://giscus.app") return;
27
+ if (!(typeof e.data === "object" && e.data.giscus)) return;
28
+ var f = document.querySelector("iframe.giscus-frame");
29
+ if (f) {
30
+ f.contentWindow.postMessage(
31
+ { giscus: { setConfig: { theme: "light" } } },
32
+ "https://giscus.app"
33
+ );
34
+ }
35
+ window.removeEventListener("message", _giscusThemeFix);
36
+ });
37
+ }
38
+ </script>
39
+ </div>
40
+ <% } %>
@@ -1,12 +1,12 @@
1
- <%#
2
- [已停用] Gitalk 评论系统模板
3
- 停用时间: 2026-03
4
- 停用原因: OAuth clientSecret 泄露 + 纯前端架构的固有安全缺陷
5
- 迁移目标: giscus (基于 GitHub Discussions)
6
- 详情参见: doc/audit-report.md #1 #9
7
- 历史评论: 保留在 blog-comments 仓库的 GitHub Issues 中
8
-
9
- 如需恢复,需要重新创建 OAuth App 并在 _config.ayeria.yml 中
10
- 设置 gitalk.enable: true 及对应的 clientID / clientSecret。
11
- 原始模板代码可在 git 历史记录中查看。
12
- %>
1
+ <%#
2
+ [已停用] Gitalk 评论系统模板
3
+ 停用时间: 2026-03
4
+ 停用原因: OAuth clientSecret 泄露 + 纯前端架构的固有安全缺陷
5
+ 迁移目标: giscus (基于 GitHub Discussions)
6
+ 详情参见: doc/audit-report.md #1 #9
7
+ 历史评论: 保留在 blog-comments 仓库的 GitHub Issues 中
8
+
9
+ 如需恢复,需要重新创建 OAuth App 并在 _config.ayeria.yml 中
10
+ 设置 gitalk.enable: true 及对应的 clientID / clientSecret。
11
+ 原始模板代码可在 git 历史记录中查看。
12
+ %>
@@ -1,9 +1,9 @@
1
- <% if (post.albums && post.albums.length){ %>
2
- <div class="justified-gallery" id="gallery">
3
- <% post.albums.forEach(function(photo){ %>
4
- <div>
5
- <img src="<%- url_for(photo[0]) %>" itemprop="image" alt="<%- photo[1] %>" style="cursor: pointer;">
6
- </div>
7
- <% }) %>
8
- </div>
1
+ <% if (post.albums && post.albums.length){ %>
2
+ <div class="justified-gallery" id="gallery">
3
+ <% post.albums.forEach(function(photo){ %>
4
+ <div>
5
+ <img src="<%- url_for(photo[0]) %>" itemprop="image" alt="<%- photo[1] %>" style="cursor: pointer;">
6
+ </div>
7
+ <% }) %>
8
+ </div>
9
9
  <% } %>
@@ -1,22 +1,22 @@
1
- <% if (post.prev || post.next){ %>
2
- <nav class="article-nav">
3
- <% if (post.prev){ %>
4
- <a href="<%- url_for(post.prev.path) %>" class="article-nav-link">
5
- <strong class="article-nav-caption"><%- theme.nav_text.post_prev %></strong>
6
- <div class="article-nav-title">
7
- <% if (post.prev.title){ %>
8
- <%= post.prev.title %>
9
- <% } else { %>
10
- (no title)
11
- <% } %>
12
- </div>
13
- </a>
14
- <% } %>
15
- <% if (post.next){ %>
16
- <a href="<%- url_for(post.next.path) %>" class="article-nav-link">
17
- <strong class="article-nav-caption"><%- theme.nav_text.post_next %></strong>
18
- <div class="article-nav-title"><%= post.next.title %></div>
19
- </a>
20
- <% } %>
21
- </nav>
22
- <% } %>
1
+ <% if (post.prev || post.next){ %>
2
+ <nav class="article-nav">
3
+ <% if (post.prev){ %>
4
+ <a href="<%- url_for(post.prev.path) %>" class="article-nav-link">
5
+ <strong class="article-nav-caption"><%- theme.nav_text.post_prev %></strong>
6
+ <div class="article-nav-title">
7
+ <% if (post.prev.title){ %>
8
+ <%= post.prev.title %>
9
+ <% } else { %>
10
+ (no title)
11
+ <% } %>
12
+ </div>
13
+ </a>
14
+ <% } %>
15
+ <% if (post.next){ %>
16
+ <a href="<%- url_for(post.next.path) %>" class="article-nav-link">
17
+ <strong class="article-nav-caption"><%- theme.nav_text.post_next %></strong>
18
+ <div class="article-nav-title"><%= post.next.title %></div>
19
+ </a>
20
+ <% } %>
21
+ </nav>
22
+ <% } %>
@@ -1,4 +1,4 @@
1
- <div class="local-search local-search-plugin">
2
- <input type="search" id="local-search-input" class="local-search-input" placeholder="Search...">
3
- <div id="local-search-result" class="local-search-result"></div>
1
+ <div class="local-search local-search-plugin">
2
+ <input type="search" id="local-search-input" class="local-search-input" placeholder="Search...">
3
+ <div id="local-search-result" class="local-search-result"></div>
4
4
  </div>
@@ -1,53 +1,53 @@
1
- <%
2
- var sUrl = url.replace(/index\.html$/, '');
3
- sUrl = /^(http:|https:)\/\//.test(sUrl) ? sUrl : 'http:' + sUrl;
4
- %>
5
- <div class="share-btn">
6
- <span class="share-sns share-outer">
7
- <i class="ri-share-forward-line"></i>
8
- <%- theme.share_text %>
9
- </span>
10
- <div class="share-wrap">
11
- <i class="arrow"></i>
12
- <div class="share-icons">
13
- <% if( theme.share_china ){ %>
14
- <a class="weibo share-sns" href="javascript:;" data-type="weibo">
15
- <i class="ri-weibo-fill"></i>
16
- </a>
17
- <a class="weixin share-sns wxFab" href="javascript:;" data-type="weixin">
18
- <i class="ri-wechat-fill"></i>
19
- </a>
20
- <a class="qq share-sns" href="javascript:;" data-type="qq">
21
- <i class="ri-qq-fill"></i>
22
- </a>
23
- <a class="douban share-sns" href="javascript:;" data-type="douban">
24
- <i class="ri-douban-line"></i>
25
- </a>
26
- <!-- <a class="qzone share-sns" href="javascript:;" data-type="qzone">
27
- <i class="icon icon-qzone"></i>
28
- </a> -->
29
- <% } %>
30
- <a class="facebook share-sns" href="javascript:;" data-type="facebook">
31
- <i class="ri-facebook-circle-fill"></i>
32
- </a>
33
- <a class="twitter share-sns" href="javascript:;" data-type="twitter">
34
- <i class="ri-twitter-fill"></i>
35
- </a>
36
- <a class="google share-sns" href="javascript:;" data-type="google">
37
- <i class="ri-google-fill"></i>
38
- </a>
39
- </div>
40
- </div>
41
- </div>
42
-
43
- <div class="wx-share-modal">
44
- <div class="wx-modal-close">
45
- <i class="ri-close-line"></i>
46
- </div>
47
- <p class="wx-modal-caption">扫一扫,分享到微信</p>
48
- <div class="wx-qrcode-frame">
49
- <img class="wx-qrcode-img" src="" data-url="<%- 'qrcode' in locals ? qrcode(sUrl) : '//api.qrserver.com/v1/create-qr-code/?size=150x150&data=' + encodeURIComponent(sUrl) %>" alt="微信分享二维码">
50
- </div>
51
- </div>
52
-
53
- <div id="share-mask"></div>
1
+ <%
2
+ var sUrl = url.replace(/index\.html$/, '');
3
+ sUrl = /^(http:|https:)\/\//.test(sUrl) ? sUrl : 'http:' + sUrl;
4
+ %>
5
+ <div class="share-btn">
6
+ <span class="share-sns share-outer">
7
+ <i class="ri-share-forward-line"></i>
8
+ <%- theme.share_text %>
9
+ </span>
10
+ <div class="share-wrap">
11
+ <i class="arrow"></i>
12
+ <div class="share-icons">
13
+ <% if( theme.share_china ){ %>
14
+ <a class="weibo share-sns" href="javascript:;" data-type="weibo">
15
+ <i class="ri-weibo-fill"></i>
16
+ </a>
17
+ <a class="weixin share-sns wxFab" href="javascript:;" data-type="weixin">
18
+ <i class="ri-wechat-fill"></i>
19
+ </a>
20
+ <a class="qq share-sns" href="javascript:;" data-type="qq">
21
+ <i class="ri-qq-fill"></i>
22
+ </a>
23
+ <a class="douban share-sns" href="javascript:;" data-type="douban">
24
+ <i class="ri-douban-line"></i>
25
+ </a>
26
+ <!-- <a class="qzone share-sns" href="javascript:;" data-type="qzone">
27
+ <i class="icon icon-qzone"></i>
28
+ </a> -->
29
+ <% } %>
30
+ <a class="facebook share-sns" href="javascript:;" data-type="facebook">
31
+ <i class="ri-facebook-circle-fill"></i>
32
+ </a>
33
+ <a class="twitter share-sns" href="javascript:;" data-type="twitter">
34
+ <i class="ri-twitter-fill"></i>
35
+ </a>
36
+ <a class="google share-sns" href="javascript:;" data-type="google">
37
+ <i class="ri-google-fill"></i>
38
+ </a>
39
+ </div>
40
+ </div>
41
+ </div>
42
+
43
+ <div class="wx-share-modal">
44
+ <div class="wx-modal-close">
45
+ <i class="ri-close-line"></i>
46
+ </div>
47
+ <p class="wx-modal-caption">扫一扫,分享到微信</p>
48
+ <div class="wx-qrcode-frame">
49
+ <img class="wx-qrcode-img" src="" data-url="<%- 'qrcode' in locals ? qrcode(sUrl) : '//api.qrserver.com/v1/create-qr-code/?size=150x150&data=' + encodeURIComponent(sUrl) %>" alt="微信分享二维码">
50
+ </div>
51
+ </div>
52
+
53
+ <div id="share-mask"></div>
@@ -1,6 +1,6 @@
1
- <% if (post.tags && post.tags.length){ %>
2
- <%- list_tags(post.tags, {
3
- show_count: false,
4
- class: 'article-tag'
5
- }) %>
1
+ <% if (post.tags && post.tags.length){ %>
2
+ <%- list_tags(post.tags, {
3
+ show_count: false,
4
+ class: 'article-tag'
5
+ }) %>
6
6
  <% } %>
@@ -1,16 +1,16 @@
1
- <% if (post.link){ %>
2
- <h2 itemprop="name">
3
- <a class="<%= class_name %>" href="<%- url_for(post.link) %>" itemprop="url"
4
- ><%= post.title %></a
5
- >
6
- </h2>
7
- <% } else if (post.title){ %> <% if (index){ %>
8
- <h2 itemprop="name">
9
- <a class="<%= class_name %>" href="<%- url_for(post.path) %>"
10
- ><%= post.title %><%- partial('topping') %></a>
11
- </h2>
12
- <% } else { %>
13
- <h1 class="<%= class_name %> sea-center" style="border-left:0" itemprop="name">
14
- <%= post.title %>
15
- </h1>
16
- <% } %> <% } %>
1
+ <% if (post.link){ %>
2
+ <h2 itemprop="name">
3
+ <a class="<%= class_name %>" href="<%- url_for(post.link) %>" itemprop="url"
4
+ ><%= post.title %></a
5
+ >
6
+ </h2>
7
+ <% } else if (post.title){ %> <% if (index){ %>
8
+ <h2 itemprop="name">
9
+ <a class="<%= class_name %>" href="<%- url_for(post.path) %>"
10
+ ><%= post.title %><%- partial('topping') %></a>
11
+ </h2>
12
+ <% } else { %>
13
+ <h1 class="<%= class_name %> sea-center" style="border-left:0" itemprop="name">
14
+ <%= post.title %>
15
+ </h1>
16
+ <% } %> <% } %>
@@ -1,6 +1,6 @@
1
- <% if (post.toc != false && toc(page.content).length!==0){ %>
2
- <div class="tocbot"></div>
3
- <% } %>
4
-
5
-
6
-
1
+ <% if (post.toc != false && toc(page.content).length!==0){ %>
2
+ <div class="tocbot"></div>
3
+ <% } %>
4
+
5
+
6
+
@@ -1,3 +1,3 @@
1
- <% if (is_home() && post.top) { %>
2
- <i class="article-topping"><%= __('post.sticky') %></i>
1
+ <% if (is_home() && post.top) { %>
2
+ <i class="article-topping"><%= __('post.sticky') %></i>
3
3
  <% } %>
@@ -1,7 +1,7 @@
1
- <%#
2
- [已停用] Twikoo 评论系统模板
3
- 说明: 该系统从未实际启用(envId 始终为空),随 Gitalk → giscus 迁移一并清理
4
- 迁移时间: 2026-03
5
- 详情参见: doc/audit-report.md #9
6
- 原始模板代码可在 git 历史记录中查看。
7
- %>
1
+ <%#
2
+ [已停用] Twikoo 评论系统模板
3
+ 说明: 该系统从未实际启用(envId 始终为空),随 Gitalk → giscus 迁移一并清理
4
+ 迁移时间: 2026-03
5
+ 详情参见: doc/audit-report.md #9
6
+ 原始模板代码可在 git 历史记录中查看。
7
+ %>
@@ -1,48 +1,48 @@
1
- <% if (!index && theme.leancloud && theme.leancloud.enable && post.comments){ %>
2
- <!-- valine评论 -->
3
- <div id="vcomments-box">
4
- <div id="vcomments"></div>
5
- </div>
6
- <script src="//cdn1.lncld.net/static/js/3.0.4/av-min.js"></script>
7
- <script src="https://cdn.staticfile.org/valine/1.4.16/Valine.min.js"></script>
8
- <script>
9
- new Valine({
10
- el: "#vcomments",
11
- app_id: "<%- theme.leancloud.app_id %>",
12
- app_key: "<%- theme.leancloud.app_key %>",
13
- path: window.location.pathname,
14
- avatar: "<%- theme.valine.avatar %>",
15
- placeholder: "<%- theme.valine.placeholder %>",
16
- recordIP: true,
17
- });
18
- const infoEle = document.querySelector("#vcomments .info");
19
- if (infoEle && infoEle.childNodes && infoEle.childNodes.length > 0) {
20
- infoEle.childNodes.forEach(function (item) {
21
- item.parentNode.removeChild(item);
22
- });
23
- }
24
- </script>
25
- <style>
26
- #vcomments-box {
27
- padding: 5px 30px;
28
- }
29
-
30
- @media screen and (max-width: 800px) {
31
- #vcomments-box {
32
- padding: 5px 0px;
33
- }
34
- }
35
-
36
- #vcomments-box #vcomments {
37
- background-color: #fff;
38
- }
39
-
40
- .v .vlist .vcard .vh {
41
- padding-right: 20px;
42
- }
43
-
44
- .v .vlist .vcard {
45
- padding-left: 10px;
46
- }
47
- </style>
48
- <% } %>
1
+ <% if (!index && theme.leancloud && theme.leancloud.enable && post.comments){ %>
2
+ <!-- valine评论 -->
3
+ <div id="vcomments-box">
4
+ <div id="vcomments"></div>
5
+ </div>
6
+ <script src="//cdn1.lncld.net/static/js/3.0.4/av-min.js"></script>
7
+ <script src="https://cdn.staticfile.org/valine/1.4.16/Valine.min.js"></script>
8
+ <script>
9
+ new Valine({
10
+ el: "#vcomments",
11
+ app_id: "<%- theme.leancloud.app_id %>",
12
+ app_key: "<%- theme.leancloud.app_key %>",
13
+ path: window.location.pathname,
14
+ avatar: "<%- theme.valine.avatar %>",
15
+ placeholder: "<%- theme.valine.placeholder %>",
16
+ recordIP: true,
17
+ });
18
+ const infoEle = document.querySelector("#vcomments .info");
19
+ if (infoEle && infoEle.childNodes && infoEle.childNodes.length > 0) {
20
+ infoEle.childNodes.forEach(function (item) {
21
+ item.parentNode.removeChild(item);
22
+ });
23
+ }
24
+ </script>
25
+ <style>
26
+ #vcomments-box {
27
+ padding: 5px 30px;
28
+ }
29
+
30
+ @media screen and (max-width: 800px) {
31
+ #vcomments-box {
32
+ padding: 5px 0px;
33
+ }
34
+ }
35
+
36
+ #vcomments-box #vcomments {
37
+ background-color: #fff;
38
+ }
39
+
40
+ .v .vlist .vcard .vh {
41
+ padding-right: 20px;
42
+ }
43
+
44
+ .v .vlist .vcard {
45
+ padding-left: 10px;
46
+ }
47
+ </style>
48
+ <% } %>