diff options
| author | schneefux <schneefux+commit@schneefux.xyz> | 2016-05-21 21:41:35 +0200 |
|---|---|---|
| committer | schneefux <schneefux+commit@schneefux.xyz> | 2016-05-21 21:41:35 +0200 |
| commit | 555e95319513c7c8289ffe9d188ca1899e5cf70d (patch) | |
| tree | 261d25f66986f42ae7f8ac6455011191cd14c423 /layouts | |
| download | blog-555e95319513c7c8289ffe9d188ca1899e5cf70d.tar.gz blog-555e95319513c7c8289ffe9d188ca1899e5cf70d.zip | |
migrate to hugo
Diffstat (limited to 'layouts')
| -rw-r--r-- | layouts/_default/list.html | 13 | ||||
| -rw-r--r-- | layouts/_default/single.html | 13 | ||||
| -rw-r--r-- | layouts/index.html | 12 | ||||
| -rw-r--r-- | layouts/partials/footer.html | 10 | ||||
| -rw-r--r-- | layouts/partials/header.html | 19 |
5 files changed, 67 insertions, 0 deletions
diff --git a/layouts/_default/list.html b/layouts/_default/list.html new file mode 100644 index 0000000..00e2181 --- /dev/null +++ b/layouts/_default/list.html @@ -0,0 +1,13 @@ +{{ partial "header.html" . }} + + <main role="main"> + <h1 class="list-title">{{ .Title }}</h1> +{{ range .Data.Pages }} + <article itemscope itemtype="http://schema.org/Blog"> + <h2 class="entry-title" itemprop="headline"><a href="{{ .RelPermalink }}">{{ .Title }}{{ if .Draft }} #Draft{{ end }}</a></h2> + <span class="entry-meta"><time itemprop="datePublished" datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 02, 2006" }}</time></span> + </article> +{{ end }} + </main> + +{{ partial "footer.html" . }}
\ No newline at end of file diff --git a/layouts/_default/single.html b/layouts/_default/single.html new file mode 100644 index 0000000..6aadea7 --- /dev/null +++ b/layouts/_default/single.html @@ -0,0 +1,13 @@ +{{ partial "header.html" . }} + + <main role="main"> + <article itemscope itemtype="http://schema.org/BlogPosting"> + <h1 class="entry-title" itemprop="headline">{{ .Title }}</h1> + <span class="entry-meta"><time itemprop="datePublished" datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 02, 2006" }}</time></span> + <section itemprop="entry-text"> + {{ .Content }} + </section> + </article> + </main> + +{{ partial "footer.html" . }}
\ No newline at end of file diff --git a/layouts/index.html b/layouts/index.html new file mode 100644 index 0000000..673ab35 --- /dev/null +++ b/layouts/index.html @@ -0,0 +1,12 @@ +{{ partial "header.html" . }} + + <main role="main"> +{{ range (where .Data.Pages ".Params.hidefromhome" "!=" "true") }} + <article itemscope itemtype="http://schema.org/Blog"> + <h2 class="entry-title" itemprop="headline"><a href="{{ .RelPermalink }}">{{ .Title }}</a></h2> + <span class="entry-meta"><time itemprop="datePublished" datetime="{{ .Date.Format "2006-01-02" }}">{{ .Date.Format "January 02, 2006" }}</time></span> + </article> +{{ end }} + </main> + +{{ partial "footer.html" . }} diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 0000000..87a4c15 --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1,10 @@ + <footer role="contentinfo"> + <div class="hr"></div> + <div class="footer-link"> + {{ with .Site.Params.email }}<a href="mailto:{{ . }}" target="_blank">Email</a>{{ end }} + {{ with .Site.Params.github }}<a href="{{ . }}" target="_blank">GitHub</a>{{ end }} + </div> + </footer> +</div> +</body> +</html> diff --git a/layouts/partials/header.html b/layouts/partials/header.html new file mode 100644 index 0000000..f8a935b --- /dev/null +++ b/layouts/partials/header.html @@ -0,0 +1,19 @@ +<!DOCTYPE html> +<html lang="{{ with .Site.LanguageCode }}{{ . }}{{ else }}en-US{{ end }}"> +<head> +<meta charset="utf-8"> +{{ .Hugo.Generator }} +<meta name="viewport" content="width=device-width, initial-scale=1"> +<link rel="stylesheet" href="/css/min.css"> +<link rel="alternate" href="/index.xml" type="application/rss+xml" title="{{ .Site.Title }}"> +<title>{{ $isHomePage := eq .Title .Site.Title }}{{ .Title }}{{ if eq $isHomePage false }} - {{ .Site.Title }}{{ end }}</title> +</head> +<body> + +<div class="container"> + <header role="banner"> + <div class="header-logo"> + <a href="/"><img src="{{ .Site.Params.logo }}" alt="{{ .Site.Title }}"></a> + </div> + {{ if eq $isHomePage true }}<h1 class="site-title">{{ .Site.Title }}</h1>{{ end }} + </header> |
