From 1c5320e584187ca807dc57be4d64b4ed10a74770 Mon Sep 17 00:00:00 2001 From: Erzbir Date: Tue, 18 Nov 2025 14:04:26 +0800 Subject: [PATCH] feat: make tags display configurable --- settings.yaml | 10 +++++++++- templates/archives.html | 6 ++---- templates/index.html | 2 +- templates/modules/tag-list.html | 4 ++-- templates/post.html | 2 +- 5 files changed, 15 insertions(+), 9 deletions(-) diff --git a/settings.yaml b/settings.yaml index 0b0bb4e..d4c90cb 100644 --- a/settings.yaml +++ b/settings.yaml @@ -187,6 +187,10 @@ spec: value: "pin-left" - label: "above" value: "pin-above" + - $formkit: checkbox + name: show_tags + label: 显示文章标签 + value: true - group: post_page label: 文章页 @@ -195,6 +199,10 @@ spec: name: show_toc label: 显示文章目录 value: true + - $formkit: checkbox + name: show_tags + label: 显示文章标签 + value: true - group: categories_page label: 分类页 @@ -217,7 +225,7 @@ spec: value: - $formkit: checkbox name: show_tags - label: 归档页显示文章标签 + label: 显示文章标签 value: false - group: tags_page diff --git a/templates/archives.html b/templates/archives.html index 94df043..2882e79 100644 --- a/templates/archives.html +++ b/templates/archives.html @@ -25,10 +25,8 @@ Publish Time - Post Title - + Post Title + diff --git a/templates/index.html b/templates/index.html index cbdf24f..324065d 100644 --- a/templates/index.html +++ b/templates/index.html @@ -32,7 +32,7 @@ theme.config.style.custom_time_style : theme.config.style.time_style}__')}">Publish Time Author + th:text="${contributor.displayName}">Author
diff --git a/templates/modules/tag-list.html b/templates/modules/tag-list.html index b91df8b..2c65d52 100644 --- a/templates/modules/tag-list.html +++ b/templates/modules/tag-list.html @@ -1,5 +1,5 @@ - - + #Tag diff --git a/templates/post.html b/templates/post.html index b75794f..5c4d5c7 100644 --- a/templates/post.html +++ b/templates/post.html @@ -12,7 +12,7 @@ th:text="${#dates.format(post.spec.publishTime, '__${theme.config.style.time_style == 'custom' ? theme.config.style.custom_time_style : theme.config.style.time_style}__')}">Publish Time - Author + Author