Adding sticky navigation option

This commit is contained in:
Eric Hough 2014-01-05 17:17:41 -05:00
parent d45046d77d
commit bcf2276d5b
4 changed files with 8 additions and 2 deletions

View File

@ -106,7 +106,9 @@ html_theme = 'sphinx_rtd_theme'
# Theme options are theme-specific and customize the look and feel of a theme
# further. For a list of options available for each theme, see the
# documentation.
#html_theme_options = {}
html_theme_options = {
'sticky_navigation' : False # Set to True to "stick" the navigation during scrolling
}
# Add any paths that contain custom themes here, relative to this directory.
html_theme_path = ["../.."]

View File

@ -286,3 +286,6 @@ footer
.wy-nav-content-wrap
margin-left: 0
.stickynav
position: fixed
top: 0

View File

@ -94,7 +94,7 @@
<div class="wy-grid-for-nav">
{# SIDE NAV, TOGGLES ON MOBILE #}
<nav data-toggle="wy-nav-shift" class="wy-nav-side">
<nav data-toggle="wy-nav-shift" class="wy-nav-side{% if theme_sticky_navigation %} stickynav{% endif %}">
<div class="wy-side-nav-search">
<a href="{{ pathto(master_doc) }}" class="icon icon-home"> {{ project }}</a>
{% include "searchbox.html" %}

View File

@ -5,3 +5,4 @@ stylesheet = css/theme.css
[options]
typekit_id = hiw1hhg
analytics_id =
sticky_navigation = False