Files
gurixandClaude Opus 4.5 803bd79dc8 feat: add bilingual blog post about digital media literacy for children
Add new blog post "Ein alter Laptop, Linux und Pi-hole: Digitale
Medienkompetenz für Kinder" in German and English, covering setting up
a child's first computer with Ubuntu and Pi-hole, open source philosophy,
and the balance between protection and freedom.

Also adds i18n support for localized month names in date formatting
across blog templates.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-19 16:43:58 +01:00

48 lines
1.5 KiB
HTML

{{ define "main" }}
<div class="container">
<div class="row">
<div class="col-lg-8 offset-lg-2">
<article class="mt-5 mb-5">
<h1 class="display-4 mb-4">{{ .Title }}</h1>
<div class="content">
{{ .Content }}
</div>
</article>
{{/* Recent blog posts section */}}
{{ $blogPages := where .Site.RegularPages "Section" "blog" }}
{{ $blogPages = where $blogPages ".Lang" .Language.Lang }}
{{ $recentPosts := first 3 $blogPages }}
{{ if $recentPosts }}
<section class="mt-5 mb-5">
<h2 class="h3 mb-4">
{{ if eq .Language.Lang "de" }}
Neueste Beiträge
{{ else }}
Recent Posts
{{ end }}
</h2>
<ul class="list-unstyled">
{{ range $recentPosts }}
<li class="mb-3">
<a href="{{ .RelPermalink }}" class="text-decoration-none">
<strong>{{ .Title }}</strong>
</a>
<br>
<time datetime="{{ .Date.Format "2006-01-02" }}" class="text-muted small">
{{ if eq $.Language.Lang "de" }}
{{ .Date.Day }}. {{ i18n (printf "month_%d" .Date.Month) }} {{ .Date.Year }}
{{ else }}
{{ i18n (printf "month_%d" .Date.Month) }} {{ .Date.Day }}, {{ .Date.Year }}
{{ end }}
</time>
</li>
{{ end }}
</ul>
</section>
{{ end }}
</div>
</div>
</div>
{{ end }}