Initial working draft.

This commit is contained in:
2026-06-16 16:45:32 +02:00
parent b7697d1125
commit b784459d87
116 changed files with 10760 additions and 0 deletions
+11
View File
@@ -0,0 +1,11 @@
{{ if not (isset .Site.Params "cookieConsentDisabled") }}
<div id="cookie-banner" style="display:none" role="dialog"
aria-label="Cookie consent" aria-live="polite">
<p>Diese Website möchte ein Cookie speichern.
<a href="{{ .Site.Params.privacyPolicyURL }}">Mehr darüber.</a></p>
<div>
<button id="cookie-accept">Akzeptieren</button>
<button id="cookie-decline">Ablehnen</button>
</div>
</div>
{{ end }}
+14
View File
@@ -0,0 +1,14 @@
<footer class="footer bg-light">
<div class="container py-4">
<div class="row">
<div class="col-md-6">
<p>&copy; {{ now.Year }} {{ .Site.Title }}</p>
</div>
<div class="col-md-6 text-md-end">
<p>
<a href="{{ relURL "impressum" }}">Impressum</a>
</p>
</div>
</div>
</div>
</footer>
+47
View File
@@ -0,0 +1,47 @@
<nav class="navbar navbar-expand-lg navbar-light bg-light sticky-top">
<div class="container"> <!-- Changed from container-fluid to container -->
<a class="navbar-brand fw-bold" href="{{ .Site.BaseURL }}">
<img src="/img/favicon.svg" alt="{{ .Site.Title }}" title="{{ .Site.Title }}">
</a>
<button class="navbar-toggler" type="button" data-bs-toggle="collapse"
data-bs-target="#navbarNav" aria-controls="navbarNav" aria-expanded="false"
aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav ms-auto">
{{ range .Site.Menus.main }}
{{ if .HasChildren }}
<!-- Dropdown menu for items with children -->
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="navbar{{ .Name | urlize }}"
role="button" data-bs-toggle="dropdown" aria-expanded="false">
{{ .Name }}
</a>
<ul class="dropdown-menu" aria-labelledby="navbar{{ .Name | urlize }}">
{{ range .Children }}
<li>
<a class="dropdown-item {{ if eq .URL ($.RelPermalink) }}active{{ end }}"
href="{{ .URL | relURL }}">
{{ .Name }}
</a>
</li>
{{ end }}
</ul>
</li>
{{ else }}
<!-- Regular menu item -->
<li class="nav-item">
<a class="nav-link {{ if eq .URL ($.RelPermalink) }}active{{ end }}"
href="{{ .URL | relURL }}">
{{ .Name }}
</a>
</li>
{{ end }}
{{ end }}
</ul>
</div>
</div>
</nav>
+28
View File
@@ -0,0 +1,28 @@
{{ printf "<!-- %s -->" hugo.Environment | safeHTML }}
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="description" content="{{ .Page.Params.description }}">
<meta name="author" content="{{ .Site.Params.author }}">
<link rel="me" href="https://neph.social/@nierenverein">
<link rel="icon" type="image/png" href="/img/favicon.png">
<title>{{ if .IsHome }}{{ .Site.Title }}{{ else }}{{ .Title }} - {{ .Site.Title }}{{ end }}</title>
<!-- Compile SCSS to CSS -->
{{ with resources.Get "scss/main.scss" }}
{{ $opts := dict
"enableSourceMap" (not hugo.IsProduction)
"outputStyle" (cond hugo.IsProduction "compressed" "expanded")
"targetPath" "css/main.css"
"transpiler" "dartsass"
}}
{{ with . | toCSS $opts }}
{{ if hugo.IsProduction }}
{{ with . | fingerprint "sha512" }}
<link rel="stylesheet" href="{{ .RelPermalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous">
{{ end }}
{{ else }}
<link rel="stylesheet" href="{{ .RelPermalink }}">
{{ end }}
{{ end }}
{{ end }}
+44
View File
@@ -0,0 +1,44 @@
{{- $js := resources.Get "js/cookie-consent.js" | minify -}}
<script src="{{ $js.RelPermalink }}" defer></script>
<!-- Bootstrap Bundle JS (includes Popper.js) -->
{{ $bs := resources.Get "js/bootstrap.bundle.min.js" | fingerprint "sha512" }}
{{ if $bs }}
<script src="{{ $bs.RelPermalink }}" integrity="{{ $bs.Data.Integrity }}" crossorigin="anonymous"></script>
{{ end }}
<!-- Custom scripts -->
{{ $custom := resources.Get "js/main.js" }}
{{ if $custom }}
{{ $custom = $custom | fingerprint "sha512" }}
<script src="{{ $custom.RelPermalink }}" integrity="{{ $custom.Data.Integrity }}" crossorigin="anonymous"></script>
{{ end }}
{{ if eq hugo.Environment "production" }}
<!-- Matomo -->
<script>
// Path 1: user just clicked Accept (event fires this session)
window.addEventListener('cookieAccepted', loadMatomo);
// Path 2: user already consented in a previous visit
if (localStorage.getItem('cookie_consent') === 'accepted') {
loadMatomo();
}
function loadMatomo() {
var _paq = window._paq = window._paq || [];
/* tracker methods like "setCustomDimension" should be called before "trackPageView" */
_paq.push(['trackPageView']);
_paq.push(['enableLinkTracking']);
(function() {
var u="https://matomo.bovender.de/";
_paq.push(['setTrackerUrl', u+'matomo.php']);
_paq.push(['setSiteId', '9']);
var d=document, g=d.createElement('script'), s=d.getElementsByTagName('script')[0];
g.async=true; g.src=u+'matomo.js'; s.parentNode.insertBefore(g,s);
})();
}
</script>
<!-- End Matomo Code -->
{{ end }}