hugo-theme-terminal/layouts/partials/head.html

58 lines
3.1 KiB
HTML
Raw Normal View History

2019-01-28 00:11:02 +00:00
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1">
<meta name="description" content="{{ if .IsHome }}{{ .Site.Params.Subtitle }}{{ else }}{{ .Summary | plainify }}{{ end }}"/>
2019-01-29 10:18:14 +00:00
<meta name="keywords" content="{{ $.Site.Params.keywords }}"/>
2019-01-28 00:11:02 +00:00
<meta name="robots" content="noodp"/>
<link rel="canonical" href="{{ .Permalink }}" />
<!-- Theme CSS -->
2019-01-29 09:47:50 +00:00
<link rel="stylesheet" href="{{ "assets/style.css" | absURL }}">
{{ if (ne $.Site.Params.ThemeColor "orange") }}
2019-01-29 10:18:14 +00:00
<link rel="stylesheet" href="{{ (printf "assets/%s.css" $.Site.Params.ThemeColor) | absURL }}">
2019-01-28 00:11:02 +00:00
{{ end }}
<!-- Custom CSS to override theme properties (/static/style.css) -->
2019-01-29 09:47:50 +00:00
<link rel="stylesheet" href="{{ "style.css" | absURL }}">
2019-01-28 00:11:02 +00:00
<!-- Icons -->
2019-01-29 09:47:50 +00:00
<link rel="apple-touch-icon-precomposed" sizes="144x144" href="{{ "img/apple-touch-icon-144-precomposed.png" | absURL }}">
2019-03-13 01:40:07 +00:00
{{ if isset $.Site.Params "favicon" }}
<link rel="shortcut icon" href="{{ $.Site.Params.favicon | absURL }}">
{{ else }}
<link rel="shortcut icon" href="{{ printf "img/favicon/%s.png" $.Site.Params.ThemeColor | absURL }}">
2019-01-28 00:11:02 +00:00
{{ end }}
<!-- Twitter Card -->
<meta name="twitter:card" content="summary" />
<meta name="twitter:title" content="{{ if .IsHome }}{{ $.Site.Title }} — {{ $.Site.Params.Subtitle }}{{ else }}{{ .Title }} :: {{ $.Site.Title }} — {{ $.Site.Params.Subtitle }}{{ end }}" />
<meta name="twitter:description" content="{{ if .IsHome }}{{ $.Site.Params.tagline }}{{ else }}{{ .Summary | plainify }}{{ end }}" />
2019-01-29 10:18:14 +00:00
<meta name="twitter:site" content="{{ $.Site.BaseURL }}" />
2019-01-28 00:11:02 +00:00
<meta name="twitter:creator" content="{{ .Params.Author }}" />
2019-02-09 08:11:56 +00:00
<meta name="twitter:image" content="{{ with .Params.Cover }}{{ . | absURL }}{{ end }}">
2019-01-28 00:11:02 +00:00
<!-- OG data -->
<meta property="og:locale" content="{{ $.Site.Language.Lang }}" />
<meta property="og:type" content="{{ if .IsPage }}article{{ else }}website{{ end }}" />
<meta property="og:title" content="{{ if .IsHome }}{{ $.Site.Title }} — {{ $.Site.Params.Subtitle }}{{ else }}{{ .Title }} :: {{ $.Site.Title }} — {{ $.Site.Params.Subtitle }}{{ end }}">
<meta property="og:description" content="{{ if .IsHome }}{{ $.Site.Params.tagline }}{{ else }}{{ .Summary | plainify }}{{ end }}" />
<meta property="og:url" content="{{ .Permalink }}" />
<meta property="og:site_name" content="{{ .Title }}" />
2019-02-09 08:11:56 +00:00
<meta property="og:image" content="{{ with .Params.Cover }}{{ . | absURL }}{{ end }}">
2019-01-28 00:11:02 +00:00
<meta property="og:image:width" content="2048">
<meta property="og:image:height" content="1024">
{{ range .Params.categories }}<meta property="article:section" content="{{ . }}" />{{ end }}
{{ if isset .Params "date" }}<meta property="article:published_time" content="{{ time .Date }}" />{{ end }}
<!-- RSS -->
{{ if .RSSLink }}
2019-01-29 10:18:14 +00:00
<link href="{{ $.Site.RSSLink }}" rel="alternate" type="application/rss+xml" title="{{ $.Site.Title }}" />
2019-01-28 00:11:02 +00:00
{{ end }}
<!-- JSON Feed -->
{{ if .OutputFormats.Get "json" }}
2019-01-29 10:18:14 +00:00
<link href="{{ if .OutputFormats.Get "json" }}{{ "feed.json" | absURL }}{{ end }}" rel="alternate" type="application/json" title="{{ $.Site.Title }}" />
2019-01-28 00:11:02 +00:00
{{ end }}
<!-- Extended head section-->
{{ partial "extended_head.html" . }}