diff --git a/layouts/partials/header.html b/layouts/partials/header.html index 52e0df0d31..90efba22ec 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -10,11 +10,15 @@ {{- partial "meta.html" . }} {{- $page := . }} {{- $link := "" }} - {{- $title := "" }} - {{- if and .Title (not (eq .Title .Site.Title)) }} - {{- $title = printf "%s %s " .Title (default "::" .Site.Params.titleSeparator) }} + {{- $title := .Title }} + {{- if eq $outputFormat "searchpage" }} + {{- $title = T "Search" }} + {{- else if eq .Kind "term" }} + {{- $title = printf "%s %s" (.Data.Singular | humanize) $title }} + {{- end }} + {{- if and $title (not (eq $title .Site.Title)) }} + {{- $title = printf "%s %s %s" $title (default "::" .Site.Params.titleSeparator) .Site.Title }} {{- end }} - {{- $title = printf "%s%s" $title .Site.Title }}