mirror of
https://github.com/phil-opp/blog_os.git
synced 2025-12-16 22:37:49 +00:00
Add partial layouts for header and footer
This commit is contained in:
12
layouts/partials/footer.html
Normal file
12
layouts/partials/footer.html
Normal file
@@ -0,0 +1,12 @@
|
||||
</main>
|
||||
|
||||
<footer class="footer">
|
||||
<small>
|
||||
© <time datetime="{{ .Site.LastChange.Format "2006" }}">
|
||||
{{ .Site.LastChange.Format "2006" }}
|
||||
</time>. All rights reserved. <a href="TODO">Contact</a>
|
||||
</small>
|
||||
</footer>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
25
layouts/partials/head.html
Normal file
25
layouts/partials/head.html
Normal file
@@ -0,0 +1,25 @@
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
|
||||
<!-- Enable responsiveness on mobile devices-->
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
|
||||
<meta http-equiv="X-Frame-Options" content="sameorigin">
|
||||
{{ with .Site.Params.author }}<meta name="author" content="{{ . }}">{{ end }}
|
||||
{{ with .Site.Params.description }}<meta name="description" content="{{ . }}">{{ end }}
|
||||
|
||||
<title>
|
||||
{{ .Title }}{{ if not .IsHome }} · {{ .Site.Title }}{{end}}
|
||||
</title>
|
||||
|
||||
|
||||
<link rel="canonical" href="{{ .Permalink }}">
|
||||
{{ if .RSSlink }}
|
||||
<link href="{{ .RSSlink }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />
|
||||
<link href="{{ .RSSlink }}" rel="feed" type="application/rss+xml" title="{{ .Site.Title }}" />
|
||||
{{ end }}
|
||||
|
||||
<!-- CSS -->
|
||||
<link rel="stylesheet" href="/css/poole.css">
|
||||
<link rel="stylesheet" href="{{ .Site.BaseURL }}css/main.css">
|
||||
</head>
|
||||
15
layouts/partials/header.html
Normal file
15
layouts/partials/header.html
Normal file
@@ -0,0 +1,15 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
|
||||
{{ partial "head.html" . }}
|
||||
<body>
|
||||
<div class="container content">
|
||||
|
||||
<header class="masthead">
|
||||
<h3 class="masthead-title">
|
||||
<a href="/" title="Home">{{ .Site.Title }}</a>
|
||||
<small>{{ replace .Site.Params.subtitle " " " " | safeHTML }}</small>
|
||||
</h3>
|
||||
</header>
|
||||
|
||||
<main>
|
||||
Reference in New Issue
Block a user