summaryrefslogtreecommitdiff
path: root/themes/archie/layouts/partials/header.html
diff options
context:
space:
mode:
authorRoger Gonzalez <roger@rogs.me>2020-11-02 18:37:23 -0300
committerRoger Gonzalez <roger@rogs.me>2020-11-02 18:37:23 -0300
commitdea4a61cbf42ff422f1409d4342fa59017950526 (patch)
tree991f6d09a6c30dab04e5a1806ba59501471c6779 /themes/archie/layouts/partials/header.html
parente09d9dc4ffc26c6082ef003251efa77d133795f8 (diff)
Changed theme to Archie, moving blog to rogs.me
Diffstat (limited to 'themes/archie/layouts/partials/header.html')
-rw-r--r--themes/archie/layouts/partials/header.html66
1 files changed, 66 insertions, 0 deletions
diff --git a/themes/archie/layouts/partials/header.html b/themes/archie/layouts/partials/header.html
new file mode 100644
index 0000000..7234f29
--- /dev/null
+++ b/themes/archie/layouts/partials/header.html
@@ -0,0 +1,66 @@
+<head>
+ <meta charset="utf-8" />
+ <meta http-equiv="X-UA-Compatible" content="IE=edge">
+ {{- $title := ( .Title ) -}}
+ {{- $siteTitle := ( .Site.Title ) -}}
+ {{- if .IsHome -}}
+ <title>{{ $siteTitle }} | Home </title>
+ {{- else -}}
+ <title>{{ $title }} - {{ $siteTitle }}</title>
+ {{- end -}}
+
+ {{- if isset .Site.Params "favicon" -}}
+ <link rel="icon" type="image/png" href={{ .Site.Params.favicon }} />
+ {{- end -}}
+
+ <meta name="viewport" content="width=device-width, initial-scale=1">
+
+ <meta property="og:description" content="{{ .Params.description }}" />
+ <meta name="twitter:description" content="{{ .Params.description }}" />
+ <meta name="description" content="{{ $.Param "description" }}" />
+ <meta name="description" content="{{ $.Params.description }}" />
+
+ <meta property="og:title" content="{{ $title }} | {{ $siteTitle }}" />
+ <meta name="twitter:title" content="{{ $title }} | {{ $siteTitle }}" />
+
+ <meta property="og:image" content="{{ .Site.Params.og_image }}"/>
+ <meta itemprop="name" content="{{ $title }} | {{ $siteTitle }}" />
+ <meta name="application-name" content="{{ $title }} | {{ $siteTitle }}" />
+ <meta property="og:site_name" content="{{ .Site.Params.sitename }}" />
+ {{ with .OutputFormats.Get "rss" -}}
+ {{ printf `<link rel="%s" type="%s" href="%s" title="%s" />` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
+ {{ end -}}
+
+ {{- template "_internal/opengraph.html" . -}}
+ {{- template "_internal/twitter_cards.html" . -}}
+ {{ if and (isset .Site.Params "social") (.Site.Params.useCDN | default false) -}}
+ <script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
+ {{- else if (isset .Site.Params "social") -}}
+ <script src="{{ .Site.BaseURL }}js/feather.min.js"></script>
+ {{ end }}
+ {{ if .Site.Params.useCDN | default false -}}
+ <link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:ital,wght@1,500&display=swap" rel="stylesheet">
+ <link href="https://fonts.googleapis.com/css2?family=Fira+Sans&display=swap" rel="stylesheet">
+ <link href="https://fonts.googleapis.com/css?family=Roboto+Mono" rel="stylesheet">
+ {{- else -}}
+ <link href="{{ .Site.BaseURL }}css/fonts.css" rel="stylesheet">
+ {{ end }}
+ <link rel="stylesheet" type="text/css" media="screen" href="{{ .Site.BaseURL }}css/main.css" />
+ {{- if or (eq .Site.Params.mode "auto") (eq .Site.Params.mode "dark") -}}
+ <link rel="stylesheet" type="text/css" href="{{ .Site.BaseURL }}css/dark.css" {{ if eq .Site.Params.mode "auto" }}media="(prefers-color-scheme: dark)"{{ end }} />
+ {{ end }}
+ <!-- Custom CSS style get applied last -->
+ {{- if isset .Site.Params "customcss" }}
+ {{ range .Site.Params.customCSS }}
+ <link rel="stylesheet" type="text/css" ref="{{ . | relURL }}">
+ {{ end }}
+ {{- end -}}
+ {{- range .Site.Params.customJS }}
+ {{- if or (hasPrefix . "http://") (hasPrefix . "https://") }}
+ <script src="{{ . }}"></script>
+ {{- else }}
+ <script src="{{ $.Site.BaseURL }}{{ . }}"></script>
+ {{- end }}
+ {{- end }}
+ <script src="https://kit.fontawesome.com/0460fae059.js" crossorigin="anonymous"></script>
+</head>