fix: wrap nav data in items key for Decap CMS compatibility

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Ludo 2026-04-11 18:10:16 +02:00
parent 219cc91dc2
commit c0426ea746
Signed by: ludo
GPG key ID: F6E479DEFAB84D6E
2 changed files with 20 additions and 19 deletions

View file

@ -1,3 +1,4 @@
items:
- name: Home
url: /
weight: 1

View file

@ -1,7 +1,7 @@
<nav>
<ul><li><a href="/"><strong>{{ .Site.Title }}</strong></a></li></ul>
<ul>
{{- range sort hugo.Data.nav "weight" }}
{{- range sort hugo.Data.nav.items "weight" }}
<li><a href="{{ .url }}"{{ if eq (relURL .url) $.RelPermalink }} aria-current="page"{{ end }}>{{ .name }}</a></li>
{{- end }}
</ul>