Feat: add param params.indexWithSubtitle

This commit is contained in:
Cell
2023-12-28 16:46:55 +08:00
parent fbe58346e5
commit 7e8e2e9431
3 changed files with 11 additions and 1 deletions
+1 -1
Submodule docs updated: f3e1a05a22...4120618e08
+3
View File
@@ -280,6 +280,9 @@ enableEmoji = true
withSiteTitle = true
# FixIt 0.3.0 | NEW title delimiter when the site title is be added to the title of every page
titleDelimiter = "-"
# FixIt 0.3.0 | NEW whether to add site subtitle to the title of index page
# remember to set up your site subtitle by `params.header.subtitle.name`
indexWithSubtitle = false
# FixIt 0.2.14 | NEW FixIt will, by default, inject a theme meta tag in the HTML head on the home page only.
# You can turn it off, but we would really appreciate if you dont, as this is a good way to watch FixIt's popularity on the rise.
disableThemeInject = false
+7
View File
@@ -1,3 +1,10 @@
{{- define "title" -}}
{{- .Site.Title -}}
{{- if .Site.Params.indexWithSubtitle | and .Site.Params.header.subtitle.name -}}
{{- printf " - %v" .Site.Params.header.subtitle.name -}}
{{- end -}}
{{- end -}}
{{- define "content" -}}
{{- $params := .Scratch.Get "params" -}}
{{- $profile := .Site.Params.home.profile -}}