Initial commit

This commit is contained in:
Leon Mika 2025-06-25 13:23:29 +02:00
parent 891b767c61
commit 56295d02ba
2 changed files with 25 additions and 0 deletions

View file

@ -0,0 +1,21 @@
{{- $pgr := where .Site.RegularPages "Section" "ne" "" -}}
{{- $pgr = where $pgr "Section" "not in" (slice "replies") -}}
{{- if (.Get "categories") -}}
{{- range (split (.Get "categories") ",") -}}
{{- $pgr = (where $pgr "Params.categories" "intersect" (slice .)) -}}
{{- end -}}
{{- end -}}
{{- if (eq (.Get "order") "link-title" ) -}}
{{- $pgr = $pgr.ByLinkTitle -}}
{{- end -}}
<ul class="postlist">
{{ range $pgr }}
{{- if (ne .LinkTitle "") -}}
<li><a href="{{ .RelPermalink }}">{{ .LinkTitle }}</a></li>
{{- else if (ne .Summary "") -}}
<li><a href="{{ .RelPermalink }}">{{ .Summary | safeHTML | truncate 70 }}</a></li>
{{- else -}}
<li><a href="{{ .RelPermalink }}">{{ .Content | safeHTML | truncate 70 }}</a></li>
{{ end }}
{{ end }}
</ul>

4
static/postlist.css Normal file
View file

@ -0,0 +1,4 @@
ul.postlist {
list-style: none;
padding-inline-start: 0;
}