templates.autogen.go (hugo-0.80.0) | : | templates.autogen.go (hugo-0.81.0) | ||
---|---|---|---|---|
skipping to change at line 66 | skipping to change at line 66 | |||
<description>{{ .Summary | html }}</description> | <description>{{ .Summary | html }}</description> | |||
</item> | </item> | |||
{{ end }} | {{ end }} | |||
</channel> | </channel> | |||
</rss> | </rss> | |||
`}, | `}, | |||
{`_default/sitemap.xml`, `{{ printf "<?xml version=\"1.0\" encoding=\"utf -8\" standalone=\"yes\"?>" | safeHTML }} | {`_default/sitemap.xml`, `{{ printf "<?xml version=\"1.0\" encoding=\"utf -8\" standalone=\"yes\"?>" | safeHTML }} | |||
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" | <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" | |||
xmlns:xhtml="http://www.w3.org/1999/xhtml"> | xmlns:xhtml="http://www.w3.org/1999/xhtml"> | |||
{{ range .Data.Pages }} | {{ range .Data.Pages }} | |||
{{- if .Permalink -}} | ||||
<url> | <url> | |||
<loc>{{ .Permalink }}</loc>{{ if not .Lastmod.IsZero }} | <loc>{{ .Permalink }}</loc>{{ if not .Lastmod.IsZero }} | |||
<lastmod>{{ safeHTML ( .Lastmod.Format "2006-01-02T15:04:05-07:00" ) }}</las tmod>{{ end }}{{ with .Sitemap.ChangeFreq }} | <lastmod>{{ safeHTML ( .Lastmod.Format "2006-01-02T15:04:05-07:00" ) }}</las tmod>{{ end }}{{ with .Sitemap.ChangeFreq }} | |||
<changefreq>{{ . }}</changefreq>{{ end }}{{ if ge .Sitemap.Priority 0.0 }} | <changefreq>{{ . }}</changefreq>{{ end }}{{ if ge .Sitemap.Priority 0.0 }} | |||
<priority>{{ .Sitemap.Priority }}</priority>{{ end }}{{ if .IsTranslated }}{ { range .Translations }} | <priority>{{ .Sitemap.Priority }}</priority>{{ end }}{{ if .IsTranslated }}{ { range .Translations }} | |||
<xhtml:link | <xhtml:link | |||
rel="alternate" | rel="alternate" | |||
hreflang="{{ .Language.Lang }}" | hreflang="{{ .Language.Lang }}" | |||
href="{{ .Permalink }}" | href="{{ .Permalink }}" | |||
/>{{ end }} | />{{ end }} | |||
<xhtml:link | <xhtml:link | |||
rel="alternate" | rel="alternate" | |||
hreflang="{{ .Language.Lang }}" | hreflang="{{ .Language.Lang }}" | |||
href="{{ .Permalink }}" | href="{{ .Permalink }}" | |||
/>{{ end }} | />{{ end }} | |||
</url> | </url> | |||
{{- end -}} | ||||
{{ end }} | {{ end }} | |||
</urlset> | </urlset> | |||
`}, | `}, | |||
{`_default/sitemapindex.xml`, `{{ printf "<?xml version=\"1.0\" encoding= \"utf-8\" standalone=\"yes\"?>" | safeHTML }} | {`_default/sitemapindex.xml`, `{{ printf "<?xml version=\"1.0\" encoding= \"utf-8\" standalone=\"yes\"?>" | safeHTML }} | |||
<sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> | <sitemapindex xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> | |||
{{ range . }} | {{ range . }} | |||
<sitemap> | <sitemap> | |||
<loc>{{ .SitemapAbsURL }}</loc> | <loc>{{ .SitemapAbsURL }}</loc> | |||
{{ if not .LastChange.IsZero }} | {{ if not .LastChange.IsZero }} | |||
<lastmod>{{ .LastChange.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</ lastmod> | <lastmod>{{ .LastChange.Format "2006-01-02T15:04:05-07:00" | safeHTML }}</ lastmod> | |||
skipping to change at line 196 | skipping to change at line 198 | |||
{{ end }} | {{ end }} | |||
{{- end -}} | {{- end -}} | |||
`}, | `}, | |||
{`google_news.html`, `{{ if .IsPage }}{{ with .Params.news_keywords }} | {`google_news.html`, `{{ if .IsPage }}{{ with .Params.news_keywords }} | |||
<meta name="news_keywords" content="{{ range $i, $kw := first 10 . }}{{ if $i }},{{ end }}{{ $kw }}{{ end }}" /> | <meta name="news_keywords" content="{{ range $i, $kw := first 10 . }}{{ if $i }},{{ end }}{{ $kw }}{{ end }}" /> | |||
{{ end }}{{ end }}`}, | {{ end }}{{ end }}`}, | |||
{`opengraph.html`, `<meta property="og:title" content="{{ .Title }}" /> | {`opengraph.html`, `<meta property="og:title" content="{{ .Title }}" /> | |||
<meta property="og:description" content="{{ with .Description }}{{ . }}{{ else } }{{if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . } }{{ end }}{{ end }}{{ end }}" /> | <meta property="og:description" content="{{ with .Description }}{{ . }}{{ else } }{{if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . } }{{ end }}{{ end }}{{ end }}" /> | |||
<meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}" /> | <meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}" /> | |||
<meta property="og:url" content="{{ .Permalink }}" /> | <meta property="og:url" content="{{ .Permalink }}" /> | |||
{{ with $.Params.images }}{{ range first 6 . -}} | ||||
<meta property="og:image" content="{{ . | absURL }}" /> | {{- with $.Params.images -}} | |||
{{ end }}{{ else -}} | {{- range first 6 . }}<meta property="og:image" content="{{ . | absURL }}" />{{ | |||
end -}} | ||||
{{- else -}} | ||||
{{- $images := $.Resources.ByType "image" -}} | {{- $images := $.Resources.ByType "image" -}} | |||
{{- $featured := $images.GetMatch "*feature*" -}} | {{- $featured := $images.GetMatch "*feature*" -}} | |||
{{- if not $featured }}{{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" } }{{ end -}} | {{- if not $featured }}{{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" } }{{ end -}} | |||
{{- with $featured -}} | {{- with $featured -}} | |||
<meta property="og:image" content="{{ $featured.Permalink }}"/> | <meta property="og:image" content="{{ $featured.Permalink }}"/> | |||
{{ else -}} | {{- else -}} | |||
{{- with $.Site.Params.images -}} | {{- with $.Site.Params.images }}<meta property="og:image" content="{{ index . 0 | |||
<meta property="og:image" content="{{ index . 0 | absURL }}"/> | | absURL }}"/>{{ end -}} | |||
{{ end }}{{ end }}{{ end }} | {{- end -}} | |||
{{- end -}} | ||||
{{- $iso8601 := "2006-01-02T15:04:05-07:00" -}} | ||||
{{- if .IsPage }} | {{- if .IsPage }} | |||
{{- if not .PublishDate.IsZero }}<meta property="article:published_time" {{ .Pub | {{- $iso8601 := "2006-01-02T15:04:05-07:00" -}} | |||
lishDate.Format $iso8601 | printf "content=%q" | safeHTMLAttr }} /> | <meta property="article:section" content="{{ .Section }}" /> | |||
{{ else if not .Date.IsZero }}<meta property="article:published_time" {{ .Date.F | {{ with .PublishDate }}<meta property="article:published_time" content="{{ .Form | |||
ormat $iso8601 | printf "content=%q" | safeHTMLAttr }} /> | at $iso8601 }}" />{{ end }} | |||
{{ end }} | {{ with .Lastmod }}<meta property="article:modified_time" content="{{ .Format $i | |||
{{- if not .Lastmod.IsZero }}<meta property="article:modified_time" {{ .Lastmod. | so8601 }}" />{{ end }} | |||
Format $iso8601 | printf "content=%q" | safeHTMLAttr }} />{{ end }} | ||||
{{- else }} | {{- range .Site.Authors }} | |||
{{- if not .Date.IsZero }}<meta property="og:updated_time" {{ .Lastmod.Format $i | {{ with .Social.facebook }}<meta property="article:author" content="https://www. | |||
so8601 | printf "content=%q" | safeHTMLAttr }} /> | facebook.com/{{ . }}" />{{ end }} | |||
{{- end }} | {{ with .Site.Social.facebook }}<meta property="article:publisher" content="http | |||
{{- end }}{{/* .IsPage */}} | s://www.facebook.com/{{ . }}" />{{ end }} | |||
{{- with .Params.tags }}{{ range first 6 . }} | ||||
<meta property="article:tag" content="{{ . }}" /> | ||||
{{- end }}{{ end -}} | ||||
{{- end -}} | ||||
{{- end -}} | ||||
{{- with .Params.audio }}<meta property="og:audio" content="{{ . }}" />{{ end }} | {{- with .Params.audio }}<meta property="og:audio" content="{{ . }}" />{{ end }} | |||
{{- with .Params.locale }}<meta property="og:locale" content="{{ . }}" />{{ end }} | {{- with .Params.locale }}<meta property="og:locale" content="{{ . }}" />{{ end }} | |||
{{- with .Site.Params.title }}<meta property="og:site_name" content="{{ . }}" /> {{ end }} | {{- with .Site.Params.title }}<meta property="og:site_name" content="{{ . }}" /> {{ end }} | |||
{{- with .Params.videos }} | {{- with .Params.videos }}{{- range . }} | |||
{{- range . }} | ||||
<meta property="og:video" content="{{ . | absURL }}" /> | <meta property="og:video" content="{{ . | absURL }}" /> | |||
{{ end }}{{ end }} | {{ end }}{{ end }} | |||
{{- /* If it is part of a series, link to related articles */}} | {{- /* If it is part of a series, link to related articles */}} | |||
{{- $permalink := .Permalink }} | {{- $permalink := .Permalink }} | |||
{{- $siteSeries := .Site.Taxonomies.series }}{{ with .Params.series }} | {{- $siteSeries := .Site.Taxonomies.series }} | |||
{{- range $name := . }} | {{ with .Params.series }}{{- range $name := . }} | |||
{{- $series := index $siteSeries ($name | urlize) }} | {{- $series := index $siteSeries ($name | urlize) }} | |||
{{- range $page := first 6 $series.Pages }} | {{- range $page := first 6 $series.Pages }} | |||
{{- if ne $page.Permalink $permalink }}<meta property="og:see_also" content= "{{ $page.Permalink }}" />{{ end }} | {{- if ne $page.Permalink $permalink }}<meta property="og:see_also" content= "{{ $page.Permalink }}" />{{ end }} | |||
{{- end }} | {{- end }} | |||
{{ end }}{{ end }} | {{ end }}{{ end }} | |||
{{- if .IsPage }} | ||||
{{- range .Site.Authors }}{{ with .Social.facebook }} | ||||
<meta property="article:author" content="https://www.facebook.com/{{ . }}" />{{ | ||||
end }}{{ with .Site.Social.facebook }} | ||||
<meta property="article:publisher" content="https://www.facebook.com/{{ . }}" /> | ||||
{{ end }} | ||||
<meta property="article:section" content="{{ .Section }}" /> | ||||
{{- with .Params.tags }}{{ range first 6 . }} | ||||
<meta property="article:tag" content="{{ . }}" />{{ end }}{{ end }} | ||||
{{- end }}{{ end }} | ||||
{{- /* Facebook Page Admin ID for Domain Insights */}} | {{- /* Facebook Page Admin ID for Domain Insights */}} | |||
{{- with .Site.Social.facebook_admin }}<meta property="fb:admins" content="{{ . }}" />{{ end }} | {{- with .Site.Social.facebook_admin }}<meta property="fb:admins" content="{{ . }}" />{{ end }} | |||
`}, | `}, | |||
{`pagination.html`, `{{ $pag := $.Paginator }} | {`pagination.html`, `{{ $pag := $.Paginator }} | |||
{{ if gt $pag.TotalPages 1 -}} | {{ if gt $pag.TotalPages 1 -}} | |||
<ul class="pagination"> | <ul class="pagination"> | |||
{{ with $pag.First -}} | {{ with $pag.First -}} | |||
<li class="page-item"> | <li class="page-item"> | |||
<a href="{{ .URL }}" class="page-link" aria-label="First"><span aria-hidden= "true">««</span></a> | <a href="{{ .URL }}" class="page-link" aria-label="First"><span aria-hidden= "true">««</span></a> | |||
</li> | </li> | |||
skipping to change at line 299 | skipping to change at line 296 | |||
<li class="page-item"> | <li class="page-item"> | |||
<a href="{{ .URL }}" class="page-link" aria-label="Last"><span aria-hidden=" true">»»</span></a> | <a href="{{ .URL }}" class="page-link" aria-label="Last"><span aria-hidden=" true">»»</span></a> | |||
</li> | </li> | |||
{{- end }} | {{- end }} | |||
</ul> | </ul> | |||
{{ end }} | {{ end }} | |||
`}, | `}, | |||
{`schema.html`, `<meta itemprop="name" content="{{ .Title }}"> | {`schema.html`, `<meta itemprop="name" content="{{ .Title }}"> | |||
<meta itemprop="description" content="{{ with .Description }}{{ . }}{{ else }}{{ if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . }}{{ end }}{{ end }}{{ end }}"> | <meta itemprop="description" content="{{ with .Description }}{{ . }}{{ else }}{{ if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . }}{{ end }}{{ end }}{{ end }}"> | |||
{{- if .IsPage }}{{ $ISO8601 := "2006-01-02T15:04:05-07:00" }}{{ if not .Publish | {{- if .IsPage -}} | |||
Date.IsZero }} | {{- $iso8601 := "2006-01-02T15:04:05-07:00" -}} | |||
<meta itemprop="datePublished" {{ .PublishDate.Format $ISO8601 | printf "content | {{ with .PublishDate }}<meta itemprop="datePublished" content="{{ .Format $iso86 | |||
=%q" | safeHTMLAttr }} />{{ end }} | 01 }}" />{{ end}} | |||
{{ if not .Lastmod.IsZero }}<meta itemprop="dateModified" {{ .Lastmod.Format $IS | {{ with .Lastmod }}<meta itemprop="dateModified" content="{{ .Format $iso8601 }} | |||
O8601 | printf "content=%q" | safeHTMLAttr }} />{{ end }} | " />{{ end}} | |||
<meta itemprop="wordCount" content="{{ .WordCount }}"> | <meta itemprop="wordCount" content="{{ .WordCount }}"> | |||
{{ with $.Params.images }}{{ range first 6 . -}} | ||||
<meta itemprop="image" content="{{ . | absURL }}"> | {{- with $.Params.images -}} | |||
{{ end }}{{ else -}} | {{- range first 6 . -}}<meta itemprop="image" content="{{ . | absURL }}">{{ end | |||
-}} | ||||
{{- else -}} | ||||
{{- $images := $.Resources.ByType "image" -}} | {{- $images := $.Resources.ByType "image" -}} | |||
{{- $featured := $images.GetMatch "*feature*" -}} | {{- $featured := $images.GetMatch "*feature*" -}} | |||
{{- if not $featured }}{{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" } }{{ end -}} | {{- if not $featured }}{{ $featured = $images.GetMatch "{*cover*,*thumbnail*}" } }{{ end -}} | |||
{{- with $featured -}} | {{- with $featured -}} | |||
<meta itemprop="image" content="{{ $featured.Permalink }}"> | <meta itemprop="image" content="{{ $featured.Permalink }}"> | |||
{{ else -}} | {{- else -}} | |||
{{- with $.Site.Params.images -}} | {{- with $.Site.Params.images -}}<meta itemprop="image" content="{{ index . 0 | | |||
<meta itemprop="image" content="{{ index . 0 | absURL }}"/> | absURL }}"/>{{ end -}} | |||
{{ end }}{{ end }}{{ end }} | {{- end -}} | |||
{{- end -}} | ||||
<!-- Output all taxonomies as schema.org keywords --> | <!-- Output all taxonomies as schema.org keywords --> | |||
<meta itemprop="keywords" content="{{ if .IsPage}}{{ range $index, $tag := .Para ms.tags }}{{ $tag }},{{ end }}{{ else }}{{ range $plural, $terms := .Site.Taxono mies }}{{ range $term, $val := $terms }}{{ printf "%s," $term }}{{ end }}{{ end }}{{ end }}" /> | <meta itemprop="keywords" content="{{ if .IsPage}}{{ range $index, $tag := .Para ms.tags }}{{ $tag }},{{ end }}{{ else }}{{ range $plural, $terms := .Site.Taxono mies }}{{ range $term, $val := $terms }}{{ printf "%s," $term }}{{ end }}{{ end }}{{ end }}" /> | |||
{{- end }} | {{- end -}} | |||
`}, | `}, | |||
{`shortcodes/__h_simple_assets.html`, `{{ define "__h_simple_css" }}{{/* These template definitions are global. */}} | {`shortcodes/__h_simple_assets.html`, `{{ define "__h_simple_css" }}{{/* These template definitions are global. */}} | |||
{{- if not (.Page.Scratch.Get "__h_simple_css") -}} | {{- if not (.Page.Scratch.Get "__h_simple_css") -}} | |||
{{/* Only include once */}} | {{/* Only include once */}} | |||
{{- .Page.Scratch.Set "__h_simple_css" true -}} | {{- .Page.Scratch.Set "__h_simple_css" true -}} | |||
<style> | <style> | |||
.__h_video { | .__h_video { | |||
position: relative; | position: relative; | |||
padding-bottom: 56.23%; | padding-bottom: 56.23%; | |||
height: 0; | height: 0; | |||
End of changes. 13 change blocks. | ||||
49 lines changed or deleted | 49 lines changed or added |