Feat: add feature end of post flag support (#236)

This commit is contained in:
Cell
2022-10-28 16:52:18 +08:00
parent 848704ee9f
commit 41050ee3db
6 changed files with 19 additions and 8 deletions
+2 -1
View File
@@ -7,7 +7,8 @@ All notable changes to this project will be documented in this file.
> Snapshot: <>
- :sparkles: Feat: add feature post reward support ([#216](https://github.com/hugo-fixit/FixIt/issues/216))
- :sparkles: Feat: add feature post reward support ([#216](https://github.com/hugo-fixit/FixIt/issues/216), @Lruihao[#234](https://github.com/hugo-fixit/FixIt/pull/234))
- :sparkles: Feat: add feature end of post flag support ([#236](https://github.com/hugo-fixit/FixIt/issues/236))
- :sparkles: Feat: add params to close wordcount and readingTime in post ([#209](https://github.com/hugo-fixit/FixIt/issues/209))
- :truck: Feat: migrate parameter `params.autoBookmark` to `params.page.autoBookmark` ([#55](https://github.com/hugo-fixit/FixIt/issues/55))
- :zap: Perf: optimize close comment feature when the post has expired ([#204](https://github.com/hugo-fixit/FixIt/issues/204))
+9
View File
@@ -78,6 +78,15 @@
}
}
#content[data-end-flag]:not([data-password])::after {
content: attr(data-end-flag);
display: block;
text-align: center;
color: $global-font-secondary-color;
font-size: 15px;
padding: 5px;
}
.content {
> h1,
> h2 {
File diff suppressed because one or more lines are too long
+2
View File
@@ -342,6 +342,8 @@
wordCount = true
# FixIt 0.2.17 | NEW whether to enable readingTime
readingTime = true
# FixIt 0.2.17 | NEW end of post flag
endFlag = ""
# FixIt 0.2.15 | NEW Repost config
[params.page.repost]
+1 -1
Submodule docs updated: e78b9cd88c...4826c17d67
+4 -5
View File
@@ -176,11 +176,10 @@
(substr $base64EncodeContent $saltLen)
-}}
{{- end -}}
<div
class="content"
id="content"
{{ with $params.password }}data-password="{{ md5 $params.password }}"{{ end }}
{{ with $params.password }}data-content="{{ $content }}"{{ end }}
<div class="content" id="content"
{{- with $params.endFlag }} data-end-flag="{{ . }}"{{- end -}}
{{- with $params.password }} data-password="{{ md5 . }}"{{- end -}}
{{- with $params.password }} data-content="{{ $content }}"{{- end -}}
>
{{- if not $params.password -}}
{{- /* Expiration Reminder */ -}}