This repository has been archived on 2023-12-07. You can view files and clone it, but cannot push or open issues or pull requests.
geeklabor_legacy/themes/geeklab/layouts/partials/head.html

31 lines
1.4 KiB
HTML
Raw Permalink Normal View History

<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
2019-02-07 21:36:45 +00:00
{{- $defaultTitle := ( printf "%s - %s" .Site.Title .Site.Params.longTitle ) }}
{{- $title := .Title | default $defaultTitle }}
{{- $description := .Page.Description }}
{{- $keywords := .Page.Keywords }}
{{- $author := index $.Site.Data.authors (.Page.Params.Author | default .Site.Params.author) }}
{{- if .IsHome }}
2019-02-07 21:36:45 +00:00
{{ $title = $defaultTitle }}
{{ $description = .Site.Params.description }}
{{ $keywords = .Site.Params.keywords }}
{{- end }}
2019-02-07 21:36:45 +00:00
{{- with $description }}
<meta name="description" content="{{ . }}">
{{- end }}
2019-02-07 21:36:45 +00:00
{{- with $keywords }}
2018-12-23 15:14:52 +00:00
<meta name="keywords" content="{{ delimit . "," }}">
{{- end }}
2019-02-07 21:36:45 +00:00
{{- with $author }}
<meta name="author" content="{{ $author.name }}">
{{- end }}
2019-02-07 21:36:45 +00:00
<title>{{ $title }}</title>
<link rel="shortcut icon" href="/favicon.ico">
<link rel="icon" type="image/png" href="/favicon.png" sizes="32x32">
<link rel="icon" type="image/png" href="/favicon.png" sizes="96x96">
<link rel="apple-touch-icon" sizes="180x180" href="/apple-touch-icon.png">
{{- range .AlternativeOutputFormats -}}
{{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
{{- end }}
</head>