Skip to content

Commit 8957862

Browse files
committed
feat: add curtain to toc popup
1 parent 47d033b commit 8957862

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

_sass/layout/post.scss

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,6 +379,7 @@ header {
379379
#toc-popup {
380380
$slide-in: slide-in 0.3s ease-out;
381381
$slide-out: slide-out 0.3s ease-out;
382+
$curtain-height: 2rem;
382383

383384
border-color: var(--toc-popup-border-color);
384385
border-width: 1px;
@@ -469,10 +470,19 @@ header {
469470
backdrop-filter: blur(5px);
470471
}
471472

473+
&::after {
474+
display: flex;
475+
content: '';
476+
position: relative;
477+
background: linear-gradient(transparent, var(--main-bg) 70%);
478+
height: $curtain-height;
479+
}
480+
472481
#toc-popup-content {
473482
overflow: auto;
474483
max-height: calc(100vh - 4 * $topbar-height);
475484
font-family: $font-family-heading;
485+
margin-bottom: -$curtain-height;
476486
}
477487
}
478488

0 commit comments

Comments
 (0)