Skip to content

Commit 1cc02a6

Browse files
Zabriskijeimfing
andauthored
fix: phantom scroll when params.footer.enable is set to false (#658)
* Phantom scroll fix * fix: adjust menu height in CSS and update sidebar max height reference * chore: regenerate css --------- Co-authored-by: Xin <[email protected]>
1 parent 1eb4b9e commit 1cc02a6

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

assets/css/compiled/main.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

assets/css/styles.css

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ body {
2929
--primary-saturation: 100%;
3030
--primary-lightness: 50%;
3131
--navbar-height: 4rem;
32-
--menu-height: 3.75rem;
32+
--menu-height: 3.75rem; /* 60px */
3333
}
3434

3535
.dark {

layouts/partials/sidebar.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
{{ $displayThemeToggle := (site.Params.theme.displayToggle | default true) -}}
4444

4545
{{ if or hugo.IsMultilingual $displayThemeToggle }}
46-
<div class="{{ $switchesClass }} {{ with hugo.IsMultilingual }}hx:justify-end{{ end }} hx:sticky hx:bottom-0 hx:bg-white hx:dark:bg-dark hx:mx-4 hx:py-4 hx:shadow-[0_-12px_16px_#fff] hx:flex hx:items-center hx:gap-2 hx:border-gray-200 hx:dark:border-neutral-800 hx:dark:shadow-[0_-12px_16px_#111] hx:contrast-more:border-neutral-400 hx:contrast-more:shadow-none hx:contrast-more:dark:shadow-none hx:border-t" data-toggle-animation="show">
46+
<div class="{{ $switchesClass }} {{ with hugo.IsMultilingual }}hx:justify-end{{ end }} hx:sticky hx:bottom-0 hx:max-h-(--menu-height) hx:bg-white hx:dark:bg-dark hx:mx-4 hx:py-4 hx:shadow-[0_-12px_16px_#fff] hx:flex hx:items-center hx:gap-2 hx:border-gray-200 hx:dark:border-neutral-800 hx:dark:shadow-[0_-12px_16px_#111] hx:contrast-more:border-neutral-400 hx:contrast-more:shadow-none hx:contrast-more:dark:shadow-none hx:border-t" data-toggle-animation="show">
4747
{{- with hugo.IsMultilingual -}}
4848
{{- partial "language-switch" (dict "context" $context "grow" true) -}}
4949
{{- with $displayThemeToggle }}{{ partial "theme-toggle" (dict "hideLabel" true) }}{{ end -}}

0 commit comments

Comments
 (0)