Skip to content

Commit

Permalink
Collapse sidebar on small devices if there is only one section
Browse files Browse the repository at this point in the history
  • Loading branch information
mgeier committed Jul 26, 2021
1 parent 5391b5c commit 65e2a3a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/insipid_sphinx_theme/insipid/static/insipid-sidebar.js_t
Original file line number Diff line number Diff line change
Expand Up @@ -266,6 +266,10 @@ $(document).ready(function () {
hideSidebar();
}
})

if ($current.length == 1 && $overlay.css('position') === 'fixed') {
hideSidebar();
}
});

{#
Expand Down

0 comments on commit 65e2a3a

Please sign in to comment.