-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcomponent.toc.css
More file actions
63 lines (55 loc) · 1.22 KB
/
Copy pathcomponent.toc.css
File metadata and controls
63 lines (55 loc) · 1.22 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
.toc {
/* we hide the TOC if there is less than 2 item */
&:not(:has(li:nth-of-type(2))) {
display: none;
}
p {
margin-bottom: var(--xs2);
}
ul {
font-size: var(--text-sm);
ul {
margin-inline-start: var(--toc-indentation);
}
}
& > ul > li:first-child > a:first-child {
padding-top: 0;
}
a {
display: flex;
align-items: center;
padding-top: calc(var(--toc-spacing) / 2);
padding-bottom: calc(var(--toc-spacing) / 2);
text-decoration: none;
color: var(--toc-color);
transition: color var(--transition);
&:hover {
color: var(--toc-color-hover);
}
span {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
&.is-active {
color: var(--toc-color-hover);
svg {
transform: translateX(calc(var(--xs1) * -1));
opacity: var(--o-5);
}
}
}
}
.toc-icon {
a {
margin-inline-start: calc(var(--toc-icon-size) * -1);
}
svg {
width: var(--toc-icon-size);
height: var(--toc-icon-size);
flex-shrink: 0;
opacity: var(--o-0);
transform: translateX(calc(var(--toc-icon-size) * -1));
transition: opacity var(--transition), transform var(--transition);
}
}