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

Patrick Kollitsch
yesterday d343f0b8575a02a872f4cfbde314da4d0b60b53c
refs
author Patrick Kollitsch <davidsneighbourdev+gh@gmail.com>
Sunday, June 7, 2026 02:34 +0200
committer Patrick Kollitsch <83281+davidsneighbour@users.noreply.github.com>
Sunday, June 7, 2026 05:36 +0200
commitd343f0b8575a02a872f4cfbde314da4d0b60b53c
tree a138fee4cdd886ca7402df89574d0318e271b474 tree | zip | gz
parent 9570264992f1f4923255bd8522a99c5552595d65 view | diff
feat: make section link above article title clickable and configurable

The `article/section-link` hook now renders the section label as a link
instead of plain text. By default it points to the section index page
(`_index.md`).

A new `ananke.section_link` parameter (page front matter or site params)
controls the target:

- unset (default): the section index page
- "first": the first page of the section, honouring its sort order
- "<path>": a specific page, resolved relative to the section

Unresolvable values fall back to the section index. The visible label
remains the section title.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 files modified
33 ■■■■■ changed files
layouts/_partials/hooks/article/section-link.html 33 ●●●●● diff | view | raw | blame | history