Skip to content

Commit e05ebc1

Browse files
committed
docs: make sidebar sticky
1 parent 7e69442 commit e05ebc1

3 files changed

Lines changed: 5 additions & 2 deletions

File tree

docs/_includes/reference_sidebar.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<aside class="col-lg-3 pl-4 pt-1 pb-1 bg-gray">
2-
<nav>
2+
<nav class="sticky top-100px">
33
<ul class="f3-light ml-4">
44
{% for item in sidebarItems %}
55
<li class="py-1">

docs/_includes/sidebar.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<aside class="col-lg-3 pl-4 pt-1 pb-1 bg-gray">
2-
<nav>
2+
<nav class="sticky top-100px">
33
<ol class="f3-light ml-4">
44
{% for item in sidebarItems %}
55
<li class="py-1">

docs/custom.css

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ code { font-size: 90% !important }
44
h1, h2, h3, h4, h5 { margin: 1rem 0; width: 100%; }
55
ul li { margin-left: 1rem }
66

7+
.sticky { position: sticky }
8+
.top-100px { top: 100px }
9+
710
/* No preference or prefers light */
811
:root:not([data-prefers-color-scheme=dark]),
912
html[data-prefers-color-scheme=light] {

0 commit comments

Comments
 (0)