diff --git a/assets/styles/layouts/main.scss b/assets/styles/layouts/main.scss index 96cef8d..eb30ce8 100644 --- a/assets/styles/layouts/main.scss +++ b/assets/styles/layouts/main.scss @@ -8,6 +8,10 @@ html { scroll-behavior: smooth !important; } +body { + position: relative; +} + /* Fixes anchor overlapping with header. See: https://stackoverflow.com/questions/4086107/fixed-page-header-overlaps-in-page-anchors diff --git a/layouts/partials/helpers/get-section-url.html b/layouts/partials/helpers/get-section-url.html new file mode 100644 index 0000000..2a902f4 --- /dev/null +++ b/layouts/partials/helpers/get-section-url.html @@ -0,0 +1,5 @@ +{{- if page.IsHome -}} + #{{ partial "helpers/get-section-id.html" . }} +{{- else -}} + {{ site.BaseURL | relLangURL }}#{{ partial "helpers/get-section-id.html" . }} +{{- end -}} \ No newline at end of file diff --git a/layouts/partials/navigators/navbar.html b/layouts/partials/navigators/navbar.html index 57f3a8e..d10a78e 100644 --- a/layouts/partials/navigators/navbar.html +++ b/layouts/partials/navigators/navbar.html @@ -77,9 +77,9 @@