{{/* Ported from theme/header.php — static version: no login/account controls. No Google Fonts: the font-family stack in main.css falls back to system sans-serif, keeping the site free of third-party requests (GDPR). */}}
{{/* The logo uploaded in Gestión → Marca, and the site's name in letters when there is none. The alt text is the name either way, so a reader who does not see the picture reads the same thing. Read through two variables rather than as `site.Data.brand.logo`, because on a site with no data/brand.yaml that expression is a field lookup on nil and fails the build — which is precisely the state every install starts in. */}} {{ $logo := "" }}{{ $stamp := "0" }} {{ with site.Data.brand }}{{ $logo = .logo }}{{ $stamp = .stamp }}{{ end }} {{ with $logo }} {{ else }} {{ .Site.Title }} {{ end }}
{{/* The menu is built from the pages themselves, not from a list in config.yaml. It used to be three names written there, which meant a page published from the members area never appeared on the site at all — and that the German and Portuguese menus had to be kept in step by hand. Built this way, a new page shows up when it is published, with its own translated title in each language. Two levels: a page with `parent: ` in its frontmatter hangs under the page with that basename. The basename is the one translate.py already uses to pair siblings — `acerca` for acerca.es.md, acerca.de.md and acerca.pt-br.md — so a parent set once holds in all three languages. Only Inicio and Comunidad stay in config.yaml, before and after the pages, which is what the weight split below is reading. */}} {{ $current := . }} {{/* A dict per page rather than sorting the pages directly: `weight` is optional, and sorting on a key half of them do not carry puts the rest in an order nobody chose. Defaulted here, once. */}} {{ $pages := slice }} {{ range where .Site.RegularPages "Section" "page" }} {{ $base := "" }} {{ with .File }}{{ $base = .ContentBaseName }}{{ end }} {{ $pages = $pages | append (dict "title" .LinkTitle "url" .RelPermalink "page" . "base" $base "parent" (.Params.parent | default "") "w" (.Params.weight | default 50)) }} {{ end }} {{ $pages = sort $pages "w" }}