Remove tag prefix from html, head, body partials
This commit is contained in:
36
layouts/partials/paige/head.html
Normal file
36
layouts/partials/paige/head.html
Normal file
@@ -0,0 +1,36 @@
|
||||
{{ $page := . }}
|
||||
|
||||
{{ $title := $page.Title }}
|
||||
|
||||
{{ if and $page.IsHome (not $title) }}
|
||||
{{ $title = $page.Param "paige.title" | default (site.Title) }}
|
||||
{{ end }}
|
||||
|
||||
{{ $title = $title | markdownify | plainify | htmlUnescape }}
|
||||
|
||||
{{ $titles := slice $title }}
|
||||
|
||||
{{ range .Ancestors }}
|
||||
{{ $title := .Title }}
|
||||
|
||||
{{ if and .IsHome (not $title) }}
|
||||
{{ $title = $page.Param "paige.title" | default (site.Title) }}
|
||||
{{ end }}
|
||||
|
||||
{{ $titles = $titles | append ($title | markdownify | plainify | htmlUnescape) }}
|
||||
{{ end }}
|
||||
|
||||
{{ $title = delimit $titles " · " }}
|
||||
|
||||
<head>
|
||||
{{ partial "paige/func-include.html" (dict "name" "head-first%s.html" "page" $page) }}
|
||||
{{ partial "paige/metas.html" $page }}
|
||||
|
||||
{{ with $title }}
|
||||
<title>{{ . }}</title>
|
||||
{{ end }}
|
||||
|
||||
{{ partial "paige/links.html" $page }}
|
||||
{{ partial "paige/style.html" $page }}
|
||||
{{ partial "paige/func-include.html" (dict "name" "head-last%s.html" "page" $page) }}
|
||||
</head>
|
Reference in New Issue
Block a user