diff --git a/CHANGELOG.md b/CHANGELOG.md index 54c8c380dd..b43abecf45 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -48,6 +48,11 @@ For the full list of changes, see the [0.9.0] release notes. renamed to `td-footer__center`. For details concerning all foot changes, see [#1818]. +- **Footer, copyright notice**: + - display of year can now be customized via .Site.Params.copyright.year + - title displayed after year must now be given via + .Site.Params.copyright.title + **Other changes**: - The latest release of [Mermaid] resources are fetched at build time ([#1410]). diff --git a/layouts/partials/footer/copyright.html b/layouts/partials/footer/copyright.html index 2142b31969..3a88d78680 100644 --- a/layouts/partials/footer/copyright.html +++ b/layouts/partials/footer/copyright.html @@ -1,3 +1,5 @@ {{ with .Site.Params.copyright -}} - © {{ now.Year }} {{ . }} {{ T "footer_all_rights_reserved" }} + © {{ with .year -}}{{- . -}}{{- else -}}{{- now.Year -}}{{- end }} {{ with .title -}}{{- . -}}{{- end }} {{ T "footer_all_rights_reserved" }} + {{- else }} + {{ with .Site.Copyright }}{{ . | safeHTML }}{{ end }} {{- end -}} diff --git a/userguide/hugo.yaml b/userguide/hugo.yaml index 6b0ad8df3e..ee11f05272 100644 --- a/userguide/hugo.yaml +++ b/userguide/hugo.yaml @@ -50,7 +50,9 @@ markup: style: tango params: - copyright: The Docsy Authors + copyright: + title: The Docsy Authors + year: 2024 privacy_policy: https://policies.google.com/privacy version_menu: Releases archived_version: false