Create basic front matter

This commit is contained in:
2023-10-08 20:10:42 +02:00
parent 67f5f175e7
commit ffc70d00d3
5 changed files with 80 additions and 5 deletions

View File

@@ -5,9 +5,11 @@
<div id="wrapper">
{{- partial "page/header.html" . -}}
<div class="main">
{{ block "left" . }}
<div class="left-menu">
{{- partial "page/left_menu" . -}}
</div>
{{ end }}
<div id="content">
{{- block "main" . -}}{{- end -}}
</div>

View File

@@ -0,0 +1,33 @@
{{ define "main" }}
<a name="top">
<h1>{{ .Title }}</h1>
</a>
<div class="news-blog">
{{ range (.Paginate (first 10 ( where .Site.RegularPages "Section" "==" "news")) 5 ).Pages }}
<div class="blog-entry">
<div class="header">
{{ .Date.Format "02.01.2006" }}
<a href="{{ .Permalink }}">{{ .Title }}</a>
</div>
<div class="details">
<div class="teaser-image">
{{ $page := . }}
{{ if .Params.Image }}
<img src="{{ (.Resources.GetMatch (.Params.Image)).RelPermalink }}">
{{ end }}
</div>
<div class="intro">
{{ with .Summary }}
{{ . }}
{{ end }}
</div>
</div>
</div>
{{ end }}
{{ template "_internal/pagination.html" . }}
</div>
{{ .Content }}
{{ partial "totop" }}
{{ end }}
{{ define "left" }}<!-- No left side menu -->{{ end }}

View File

@@ -1,5 +0,0 @@
{{ define "main" }}
<div id="home-jumbotron" class="jumbotron text-center">
<h1 class="title">{{ .Site.Title }}</h1>
</div>
{{ end }}