mirror of https://github.com/theNewDynamic/gohugo-theme-ananke.git

Patrick Kollitsch
12 hours ago 8263c013685ba4e5628315ff8c3125ebf286fd7e
refs
author Patrick Kollitsch <davidsneighbourdev+gh@gmail.com>
Thursday, November 19, 2026 09:40 +0100
committer Patrick Kollitsch <davidsneighbourdev+gh@gmail.com>
Thursday, November 19, 2026 12:51 +0100
commit8263c013685ba4e5628315ff8c3125ebf286fd7e
tree bccd99e1159251196ddad46d950776d2007b8987 tree | zip | gz
parent 0eb3f08f5bdc38ec9002d90feb8eb54db7aef4de view | diff
refactor(layouts): render header parts through hooks

Render every part of the site header (logo, languages, menu, social
links, title, and description) through header/<name> hooks. The theme
ships default hook partials that produce the same markup as before.

Each component also fires header/<name>-before and header/<name>-after
hooks, so sites can add markup (for example a search form or a second
menu) between components without overriding the templates.
3 files modified
13 files added
392 ■■■■■ changed files
layouts/_partials/func/header/GetMenuCurrent.html 15 ●●●●● diff | view | raw | blame | history
layouts/_partials/func/header/GetNavigationClasses.html 31 ●●●●● diff | view | raw | blame | history
layouts/_partials/header/component.html 30 ●●●●● diff | view | raw | blame | history
layouts/_partials/header/content.html 12 ●●●●● diff | view | raw | blame | history
layouts/_partials/header/menu-toggle-icon.html 2 ●●●●● diff | view | raw | blame | history
layouts/_partials/header/submenu-icon.html 2 ●●●●● diff | view | raw | blame | history
layouts/_partials/header/submenu.html 27 ●●●●● diff | view | raw | blame | history
layouts/_partials/hooks/header/description.html 23 ●●●●● diff | view | raw | blame | history
layouts/_partials/hooks/header/languages.html 5 ●●●●● diff | view | raw | blame | history
layouts/_partials/hooks/header/logo.html 12 ●●●●● diff | view | raw | blame | history
layouts/_partials/hooks/header/menu.html 49 ●●●●● diff | view | raw | blame | history
layouts/_partials/hooks/header/social.html 5 ●●●●● diff | view | raw | blame | history
layouts/_partials/hooks/header/title.html 15 ●●●●● diff | view | raw | blame | history
layouts/_partials/page-header.html 7 ●●●●● diff | view | raw | blame | history
layouts/_partials/site-header.html 19 ●●●●● diff | view | raw | blame | history
layouts/_partials/site-navigation.html 138 ●●●●● diff | view | raw | blame | history