head.html (4021B)
1 <meta http-equiv="content-type" content="text/html; charset=utf-8"> 2 <meta name="viewport" content="width=device-width, initial-scale=1.0"> 3 <meta name="description" content=" 4 {{- if .IsHome -}} {{- $.Site.Params.Subtitle -}} 5 {{- else if .Description -}} 6 {{- .Description | markdownify | plainify -}} 7 {{- else -}} 8 {{- .Summary | markdownify | plainify -}} 9 {{- end -}}" /> 10 <meta name="keywords" content=" 11 {{- with .Params.Keywords -}} 12 {{- delimit . ", " -}} 13 {{- else -}} 14 {{- $.Site.Params.Keywords -}} 15 {{- end -}}" /> 16 {{ if .Params.noindex -}} 17 {{- if or (eq (.Param "noindex") true) (eq (.Param "noindex") "true") -}} 18 <meta name="robots" content="noindex" /> 19 {{- end -}} 20 {{- else -}} 21 <meta name="robots" content="index, follow" /> 22 {{- end }} 23 <link rel="canonical" href="{{ .Permalink }}" /> 24 25 {{ template "_internal/google_analytics.html" . }} 26 27 {{ $css := resources.Get "css/style.css" }} 28 {{ $options := (dict 29 "targetPath" "styles.css" 30 "minify" true 31 "sourceMap" "linked" 32 ) }} 33 {{ $styles := $css | css.Build $options }} 34 35 <link rel="stylesheet" href="{{ $styles.Permalink }}"> 36 37 <!-- Custom CSS to override theme properties (/static/style.css) --> 38 {{ if (fileExists "static/style.css") -}} 39 <link rel="stylesheet" href="{{ "style.css" | absURL }}"> 40 {{- end }} 41 42 <!-- Custom CSS to override theme properties (/static/style.css) --> 43 {{- if (fileExists "static/style.css") -}} 44 <link rel="stylesheet" href="{{ "style.css" | absURL }}"> 45 {{- end -}} 46 47 <!-- Icons --> 48 {{- if isset $.Site.Params "favicon" -}} 49 <link rel="shortcut icon" href="{{ $.Site.Params.favicon | absURL }}"> 50 {{- else -}} 51 <link rel="shortcut icon" href="{{ printf "img/theme-colors/%s.png" (or .Params.color $.Site.Params.ThemeColor | default "orange") | absURL }}"> 52 <link rel="apple-touch-icon" href="{{ printf "img/theme-colors/%s.png" (or .Params.color $.Site.Params.ThemeColor | default "orange") | absURL }}"> 53 {{- end }} 54 <!-- OG data --> 55 <meta property="og:locale" content="{{ $.Site.Language.Lang }}"/> 56 <meta property="og:type" content=" 57 {{- if .IsPage -}} 58 article 59 {{- else -}} 60 website 61 {{- end }}"/> 62 <meta property="og:title" content=" 63 {{- if .IsHome -}} 64 {{- $.Site.Title -}} 65 {{- else -}} 66 {{- .Title -}} 67 {{- end }}"/> 68 <meta property="og:description" content=" 69 {{- if .IsHome -}} 70 {{- $.Site.Params.Subtitle -}} 71 {{- else if .Description -}} 72 {{- .Description | markdownify | plainify -}} 73 {{- else -}} 74 {{- .Summary | markdownify | plainify -}} 75 {{- end }}"/> 76 <meta property="og:url" content="{{ .Permalink }}"/> 77 <meta property="og:site_name" content="{{ .Site.Title }}"/> 78 <meta property="og:image" content= {{- with (.Params.cover | .Resources.GetMatch) -}} 79 "{{ .RelPermalink | absURL }}" 80 {{- else -}} 81 {{- if .Site.Params.favicon -}} 82 "{{ .Site.Params.favicon | absURL }}" 83 {{- else -}} 84 "{{ printf "img/theme-colors/%s.png" .Site.Params.ThemeColor | absURL }}" 85 {{- end -}} 86 {{ end -}}/> 87 <meta property="og:image:width" content="1200"/> 88 <meta property="og:image:height" content="627"/> 89 {{ range .Params.categories -}} 90 <meta property="article:section" content="{{ . }}"/> 91 {{- end }} 92 {{ if isset .Params "date" -}} 93 <meta property="article:published_time" content="{{ time .Date }}"/> 94 {{- end -}} 95 96 <!-- RSS --> 97 {{ with .OutputFormats.Get "RSS" -}} 98 <link href="{{ .RelPermalink }}" 99 rel="alternate" 100 type="application/rss+xml" 101 title="RSS Feed"/> 102 {{- end }} 103 104 <!-- JSON Feed --> 105 {{ with .OutputFormats.Get "json" -}} 106 <link href="{{ .RelPermalink }}" 107 rel="alternate" 108 type="application/json" 109 title="{{ $.Site.Title }}"/> 110 {{- end }} 111 112 {{- partial "ld_schema" . -}} 113 114 <!-- Extended head section--> 115 {{- partial "extended_head.html" . -}} 116