Restructure all pages under article tag
This commit is contained in:
@@ -1,40 +1,3 @@
|
||||
{{ define "main" }}
|
||||
{{ if not (or .Title .Description .PublishDate .Content) }}
|
||||
<section>
|
||||
<h1 class="display-5 fw-bold text-center">Nothing Here</h1>
|
||||
</section>
|
||||
{{ else }}
|
||||
<article>
|
||||
{{ if or .Title .Description .PublishDate }}
|
||||
<header>
|
||||
<div class="justify-content-center row">
|
||||
<div class="col col-auto text-center">
|
||||
{{ if .Title }}
|
||||
<h1 class="display-5 fw-bold">
|
||||
{{ if .Params.link }}
|
||||
<a href="{{ .Params.link }}">{{ .Title | markdownify }}</a>
|
||||
{{ else }}
|
||||
{{ .Title | markdownify }}
|
||||
{{ end }}
|
||||
</h1>
|
||||
{{ end }}
|
||||
{{ if .Description }}
|
||||
<p class="lead">{{ .Description | markdownify }}</p>
|
||||
{{ end }}
|
||||
{{ if .PublishDate }}
|
||||
<p class="text-muted"><time datetime="{{ .PublishDate.Format `2006-01-02` }}">{{ .PublishDate.Format "January 2, 2006" }}</time></p>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
{{ end }}
|
||||
{{ if .Content }}
|
||||
<div class="justify-content-center row">
|
||||
<div class="col col-auto" id="content">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
</article>
|
||||
{{ end }}
|
||||
{{ partial "paige_content.html" . }}
|
||||
{{ end }}
|
||||
|
Reference in New Issue
Block a user