2020-09-22 15:35:44 +02:00
|
|
|
{{ define "stylesheet" }}{{ $scss := resources.Get "/_default/single.scss" }}{{ $style := $scss | resources.ToCSS }}
|
2020-09-26 17:57:12 +02:00
|
|
|
<link rel="stylesheet" href="{{ $style.Permalink }}" type="text/css" media="screen" rel="preload" />
|
2020-09-14 16:24:02 +02:00
|
|
|
{{ end }}
|
|
|
|
|
|
|
|
{{ define "main" }}
|
|
|
|
<main>
|
|
|
|
<div class="container">
|
|
|
|
<section class="section-article">
|
|
|
|
<article>
|
|
|
|
<p class="meta">
|
2020-09-21 14:00:45 +02:00
|
|
|
{{ if eq .Params.type "project" }}<span title="{{ .Date.Format "2 Jan 2006" }}">latest update: {{ .Date.Format "2. January 2006" }}</span>{{ end }}
|
|
|
|
{{ if ne .Params.type "project" }}<span title="{{ .Date.Format "2 Jan 2006, 15:04 MST" }}">{{ .Date.Format "2. January 2006" }}</span>{{ end }}
|
|
|
|
<span>{{ with .Params.author }}by {{ end }}{{ .Params.author }}</span>
|
2020-09-14 16:24:02 +02:00
|
|
|
</p>
|
|
|
|
<h1 class="title">{{ .Title }}</h1>
|
|
|
|
{{ with .Params.featured_image }}
|
2020-10-05 09:57:10 +02:00
|
|
|
<img src="{{ . | relURL }}" loading="lazy" alt="">
|
2020-09-14 16:24:02 +02:00
|
|
|
{{ end }}
|
|
|
|
{{ .Content }}
|
|
|
|
<aside class="meta">
|
2020-09-17 21:51:17 +02:00
|
|
|
{{ with .Params.topics }}
|
2020-09-14 16:24:02 +02:00
|
|
|
<ul class="topics">
|
|
|
|
{{ range . }}
|
2020-10-05 09:57:10 +02:00
|
|
|
<li>
|
|
|
|
<a href="{{ "topics" | relURL}}/{{ . | urlize }}">{{ . }}</a>
|
|
|
|
</li>
|
2020-09-14 16:24:02 +02:00
|
|
|
{{ end }}
|
|
|
|
</ul>
|
|
|
|
{{ end }}
|
|
|
|
{{ with .Params.tags }}
|
2020-10-05 09:57:10 +02:00
|
|
|
<h3>tags</h3>
|
2020-09-14 16:24:02 +02:00
|
|
|
<ul class="tags">
|
|
|
|
{{ range . }}
|
2020-10-05 09:57:10 +02:00
|
|
|
<li>
|
|
|
|
<a href="{{ "tags" | relURL }}/{{ . | urlize }}">{{ . }}</a>
|
|
|
|
</li>
|
2020-09-14 16:24:02 +02:00
|
|
|
{{ end }}
|
|
|
|
</ul>
|
|
|
|
{{ end }}
|
|
|
|
</aside>
|
|
|
|
</article>
|
|
|
|
</section>
|
|
|
|
<section class="section-articles">
|
2020-09-22 14:10:53 +02:00
|
|
|
<article class="next-article">
|
2020-10-05 09:57:10 +02:00
|
|
|
{{ with .NextInSection }}
|
|
|
|
<a href="{{ .Permalink }}">
|
|
|
|
{{ if eq .Params.type "project" }}← next project{{ end }}
|
|
|
|
{{ if ne .Params.type "project" }}← next article{{ end }}
|
|
|
|
</a>
|
|
|
|
{{ end }}
|
2020-09-22 14:10:53 +02:00
|
|
|
</article>
|
|
|
|
<article class="previous-article">
|
2020-10-05 09:57:10 +02:00
|
|
|
{{ with .PrevInSection }}<span></span>
|
|
|
|
<a href="{{ .Permalink }}">
|
|
|
|
{{ if eq .Params.type "project" }}previous project →{{ end }}
|
|
|
|
{{ if ne .Params.type "project" }}previous article →{{ end }}
|
|
|
|
</a>
|
|
|
|
{{ end }}
|
2020-09-22 14:10:53 +02:00
|
|
|
</article>
|
2020-09-14 16:24:02 +02:00
|
|
|
</section>
|
|
|
|
</div>
|
|
|
|
</main>
|
|
|
|
{{ end }}
|