32 lines
908 B
HTML
32 lines
908 B
HTML
{{ define "main" }}
|
|
<header class="post-header">
|
|
<h1 id="title">{{ .Title }}</h1>
|
|
<!--
|
|
If it's a static page, then the post information are useless and
|
|
therefore not displayed. The test checks if the page IS NOT a static
|
|
page.
|
|
-->
|
|
{{- if ne .Layout "static" }}
|
|
{{- partial "post-info.html" . -}}
|
|
{{ end }}
|
|
</header>
|
|
<!--
|
|
If in the front matter, the layout key is set to verse, then the class is
|
|
added.
|
|
-->
|
|
<article {{ if eq .Layout "verse" }} class="content, {{ .Layout }}"
|
|
{{ else }} class="content" {{ end -}}>
|
|
<!--
|
|
Displays the image associated to the post, if set in the front matter.
|
|
-->
|
|
{{ if .Params.postimage -}}
|
|
<figure class="post-image">
|
|
<img src="/images/{{ .Params.postimage }}"
|
|
alt="{{ .Params.postimagedescription }}">
|
|
</figure>
|
|
{{ end }}
|
|
{{ .Content -}}
|
|
</article>
|
|
{{ end -}}
|
|
|