From 231615198a788d643e3d090773c85b1859bfece8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=8A=98=E5=BD=B1=E8=BD=BB=E6=A2=A6?= Date: Fri, 13 Aug 2021 09:24:31 +0800 Subject: [PATCH] =?UTF-8?q?#13=20=E6=A0=87=E7=AD=BE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- _config.yml | 2 +- layout/archive.ejs | 5 +++++ layout/post.ejs | 10 ++++++---- source/css/style.css | 16 +++++++++++++++- 4 files changed, 27 insertions(+), 6 deletions(-) diff --git a/_config.yml b/_config.yml index e15fb24..e210d2f 100644 --- a/_config.yml +++ b/_config.yml @@ -3,7 +3,7 @@ favicon: type: image/x-icon # 图标类型,可能的值有(image/png, image/vnd.microsoft.icon, image/x-icon, image/gif) search: https://cn.bing.com/search?q= # https://www.google.com/search?q== order_by: date # date,-date,title,url,... -head: `` # 在 中添加自定义的内容 +head: '' # 在 中添加自定义的内容 menu: 归档: archives diff --git a/layout/archive.ejs b/layout/archive.ejs index 725215b..830ab9c 100644 --- a/layout/archive.ejs +++ b/layout/archive.ejs @@ -6,6 +6,11 @@
+ <%- list_tags({ + show_count: true, + style: "unordered list", + separator: ", " + }) %> <% // 参考:https://github.com/SukkaW/hexo-theme-suka/blob/master/layout/_pages/archive.ejs %> <% function buildArchive(posts, year) { %>

<%= year %>

diff --git a/layout/post.ejs b/layout/post.ejs index fe03a7e..1abce1d 100644 --- a/layout/post.ejs +++ b/layout/post.ejs @@ -20,11 +20,13 @@ <%- page.content %>
-
-
- <%- is_post() ? partial('_partial/post-nav') : '' %> + <% if(is_post()){ %> +
+
+ <%- partial('_partial/post-nav') %> +
-
+ <% } %>
<%- theme.comment ? partial('_partial/_comment/' + theme.comment) : '' %>
diff --git a/source/css/style.css b/source/css/style.css index c2172d3..fc1e741 100644 --- a/source/css/style.css +++ b/source/css/style.css @@ -278,7 +278,7 @@ a:hover { width: 100%; display: flex; justify-content: space-between; - flex-flow:row-reverse + flex-flow: row-reverse } .content .post-nav span { @@ -347,6 +347,19 @@ a:hover { position: relative; } +.content .tag-unordered { + word-break: break-word; +} + +.content .tag-unordered .list-count::before { + content: "(" +} + +.content .tag-unordered .list-count::after { + content: ")" +} + + .comment { padding: 3em 1em; } @@ -367,6 +380,7 @@ article p { article a { color: #aa874b; + word-break: break-all; } article > table { -- GitLab