File tree Expand file tree Collapse file tree 2 files changed +32
-5
lines changed Expand file tree Collapse file tree 2 files changed +32
-5
lines changed Original file line number Diff line number Diff line change @@ -529,6 +529,7 @@ atomic-search-layout atomic-layout-section[section="search"] {
529
529
max-height : 100vh ;
530
530
overflow : hidden;
531
531
scrollbar-gutter : stable;
532
+ scrollbar-width : none;
532
533
}
533
534
534
535
.sidebar .scrollbar-container : hover {
@@ -698,7 +699,7 @@ atomic-search-layout atomic-layout-section[section="search"] {
698
699
699
700
.sidebar .sidebar-navigation ul li .partial {
700
701
margin-top : 0 ;
701
- top : calc ( 50 % - 3. 5px ) ;
702
+ top : 5px ;
702
703
left : -13px ;
703
704
}
704
705
@@ -707,10 +708,7 @@ atomic-search-layout atomic-layout-section[section="search"] {
707
708
position : relative;
708
709
}
709
710
710
- .sidebar
711
- .sidebar-navigation
712
- .parent-collapsible-content
713
- li : not (: only-child )::before {
711
+ .sidebar .sidebar-navigation .parent-collapsible-content : first-child ::before {
714
712
content : "" ;
715
713
position : absolute;
716
714
border-left : black 1px solid;
@@ -719,6 +717,16 @@ atomic-search-layout atomic-layout-section[section="search"] {
719
717
height : calc (100% - 9px - 10px );
720
718
}
721
719
720
+ .sidebar
721
+ .sidebar-navigation
722
+ .parent-collapsible-content
723
+ li : not (: only-child )
724
+ a
725
+ + : not (: has (# TableOfContents ))
726
+ li ::before {
727
+ border : none;
728
+ }
729
+
722
730
/* First Sidebar Nav Horizontal Lines */
723
731
.sidebar
724
732
.sidebar-navigation
@@ -748,6 +756,22 @@ atomic-search-layout atomic-layout-section[section="search"] {
748
756
align-items : flex-start;
749
757
}
750
758
759
+ /* Table of Contents */
760
+ # TableOfContents {
761
+ /* Close all TOC on sidebar */
762
+ display : none;
763
+ }
764
+
765
+ .collapsible-content li ul li : has (.current ) > nav {
766
+ /* Open TOC for current page */
767
+ display : block !important ;
768
+ }
769
+
770
+ # TableOfContents li {
771
+ position : relative;
772
+ list-style : square;
773
+ }
774
+
751
775
/* content */
752
776
main {
753
777
flex : 1 ;
Original file line number Diff line number Diff line change 20
20
< span class ="box-link partial "> </ span >
21
21
{{ end }}
22
22
< a href ="{{ .Permalink }} " style ="{{if eq $currentUrl .Permalink}}font-weight: bold;{{end}} "> {{ .Title }} </ a >
23
+ {{- with .TableOfContents -}}
24
+ {{- . -}}
25
+ {{- end -}}
23
26
{{ end }}
24
27
</ li >
25
28
{{ end }}
You can’t perform that action at this time.
0 commit comments