1
0
mirror of https://github.com/cotes2020/jekyll-theme-chirpy.git synced 2025-12-18 05:41:31 +00:00

feat: support vertical scrolling for toc in desktop mode (#2064)

This commit is contained in:
Cotes Chung
2024-11-28 02:58:25 +08:00
parent 11647697bb
commit 5265b03974
5 changed files with 61 additions and 13 deletions

View File

@@ -6,7 +6,6 @@
top: 2rem;
transition: top 0.2s ease-in-out;
margin-top: 3rem;
margin-bottom: 4rem;
&:only-child {
position: -webkit-sticky;
@@ -14,11 +13,12 @@
}
> section {
padding-left: 1rem;
border-left: 1px solid var(--main-border-color);
@extend %panel-border;
&:not(:last-child) {
margin-bottom: 4rem;
padding-left: 1rem;
&:not(:first-child) {
margin-top: 4rem;
}
}
@@ -48,6 +48,10 @@
}
}
> :last-child {
margin-bottom: 4rem;
}
@include bp.lt(bp.get(xl)) {
display: none;
}