From 9a208addeaefd39d0a85ec81f4d9d0d7c082f872 Mon Sep 17 00:00:00 2001 From: Greg Korba Date: Thu, 2 Nov 2023 09:10:15 +0100 Subject: [PATCH] Display ToC sections properly (do not trim content) --- assets/css/common/header.css | 5 +++++ layouts/_default/baseof.html | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/assets/css/common/header.css b/assets/css/common/header.css index 9b9e523..bdbc4e3 100644 --- a/assets/css/common/header.css +++ b/assets/css/common/header.css @@ -1,3 +1,8 @@ +/* See: https://github.com/adityatelange/hugo-PaperMod/pull/979#issuecomment-1654974106 */ +html.header-sticky { + scroll-padding-top: calc(var(--header-height) * 2); +} + header.header-sticky { position: sticky; top: 0; diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html index d2de5ee..5a08ce5 100644 --- a/layouts/_default/baseof.html +++ b/layouts/_default/baseof.html @@ -3,7 +3,7 @@ {{- end -}} - + {{- partial "head.html" . }}