quartz-research-note/quartz/components/styles/toc.scss

56 lines
900 B
SCSS
Raw Normal View History

2023-06-17 19:07:40 +00:00
button#toc {
background-color: transparent;
border: none;
text-align: left;
cursor: pointer;
padding: 0;
color: var(--dark);
display: flex;
align-items: center;
2023-06-10 06:06:02 +00:00
2023-06-17 19:07:40 +00:00
& h3 {
font-size: 1rem;
display: inline-block;
margin: 0;
}
2023-06-10 06:06:02 +00:00
2023-06-17 19:07:40 +00:00
& .fold {
margin-left: 0.5rem;
transition: transform 0.3s ease;
opacity: 0.8;
}
2023-06-17 02:41:59 +00:00
2023-06-17 19:07:40 +00:00
&.collapsed .fold {
transform: rotateZ(-90deg)
2023-06-10 06:06:02 +00:00
}
2023-06-17 19:07:40 +00:00
}
#toc-content {
list-style: none;
overflow: hidden;
max-height: none;
transition: max-height 0.3s ease;
2023-06-18 17:47:07 +00:00
font-size: 0.9rem;
2023-06-17 19:07:40 +00:00
2023-06-10 06:06:02 +00:00
& ul {
list-style: none;
2023-06-17 02:41:59 +00:00
margin: 0.5rem 0;
2023-06-10 06:06:02 +00:00
padding: 0;
2023-06-17 02:41:59 +00:00
& > li > a {
color: var(--dark);
opacity: 0.35;
2023-06-18 17:47:07 +00:00
transition: 0.5s ease opacity, 0.3s ease color;
2023-06-17 02:41:59 +00:00
&.in-view {
opacity: 0.75;
}
}
2023-06-10 06:06:02 +00:00
}
2023-06-17 02:41:59 +00:00
@for $i from 0 through 6 {
2023-06-10 06:06:02 +00:00
& .depth-#{$i} {
padding-left: calc(1rem * #{$i});
}
}
}
2023-06-17 19:07:40 +00:00