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:
parent
219cc91dc2
commit
c0426ea746
2 changed files with 20 additions and 19 deletions
|
|
@ -1,3 +1,4 @@
|
|||
items:
|
||||
- name: Home
|
||||
url: /
|
||||
weight: 1
|
||||
|
|
|
|||
|
|
@ -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>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue