Adjust sticky sidebar's maximum height

This commit is contained in:
Leilukin 2025-04-03 00:56:35 +08:00 committed by Helen Chong
parent 0b26f47aba
commit b1336eea16
2 changed files with 38 additions and 38 deletions

View File

@ -10,48 +10,48 @@
</aside> </aside>
{%- css %} {%- css %}
.toc__wrapper { .toc__wrapper {
max-height: var(--ht-sticky-sidebar); max-height: var(--ht-sticky-sidebar);
overflow-x: auto; overflow-x: auto;
background-color: var(--clr-content-bg); background-color: var(--clr-content-bg);
padding: 1rem 1.3rem; padding: 1rem 1.3rem;
} }
.toc__heading { .toc__heading {
font-size: 1.3rem; font-size: 1.3rem;
font-weight: 700; font-weight: 700;
color: var(--clr-sub-heading); color: var(--clr-sub-heading);
} }
.toc__wrapper[open] > .toc__heading { .toc__wrapper[open] > .toc__heading {
margin-bottom: 0.5em; margin-bottom: 0.5em;
} }
.toc ol, .toc ol ol { .toc ol, .toc ol ol {
display: grid; display: grid;
gap: 0.3em; gap: 0.3em;
} }
.toc ol { .toc ol {
border-top: 0.1em solid var(--clr-title-border); border-top: 0.1em solid var(--clr-title-border);
padding-left: 1.3em; padding-left: 1.3em;
padding-top: 1em; padding-top: 1em;
} }
.toc ol ol { .toc ol ol {
border-top: none; border-top: none;
list-style-type: disc; list-style-type: disc;
padding-left: 1em; padding-left: 1em;
padding-top: 0.3em; padding-top: 0.3em;
} }
.toc ol a { .toc ol a {
font-size: 1.1rem; font-size: 1.1rem;
padding-left: 0.3em; padding-left: 0.3em;
} }
.toc ol ol a { .toc ol ol a {
padding: 0; padding: 0;
font-size: 1rem; font-size: 1rem;
} }
{% endcss %} {% endcss %}

View File

@ -50,7 +50,7 @@
--sz-content-list-gap: 0.7em; --sz-content-list-gap: 0.7em;
--sz-def-indent: 1.5em; --sz-def-indent: 1.5em;
--ht-sticky-sidebar: 89vh; --ht-sticky-sidebar: 86vh;
} }
/* ------------------- */ /* ------------------- */