From 30f5c683eb757a2ee18cc3d7d25cc8a2e5885cf9 Mon Sep 17 00:00:00 2001 From: Eric Hough Date: Tue, 7 Jan 2014 17:39:48 -0500 Subject: [PATCH] Turning off sticky navigation if navbar is taller than window Conflicts: sass/_theme_layout.sass sphinx_rtd_theme/layout.html --- sass/_theme_layout.sass | 2 +- sphinx_rtd_theme/layout.html | 11 ++++++- sphinx_rtd_theme/static/css/theme.css | 2 +- sphinx_rtd_theme/static/js/theme.js | 47 +++++++++++++++++++++++++++ 4 files changed, 59 insertions(+), 3 deletions(-) diff --git a/sass/_theme_layout.sass b/sass/_theme_layout.sass index 9b4543e4..1ea473d4 100644 --- a/sass/_theme_layout.sass +++ b/sass/_theme_layout.sass @@ -286,6 +286,6 @@ footer .wy-nav-content-wrap margin-left: 0 -.stickynav +nav.stickynav position: fixed top: 0 diff --git a/sphinx_rtd_theme/layout.html b/sphinx_rtd_theme/layout.html index 7a3a354a..ae3c0466 100644 --- a/sphinx_rtd_theme/layout.html +++ b/sphinx_rtd_theme/layout.html @@ -53,6 +53,15 @@ {% endif %} + {# STICKY NAVIGATION #} + {% if theme_sticky_navigation %} + + {% endif %} + {% for cssfile in css_files %} {% endfor %} @@ -94,7 +103,7 @@
{# SIDE NAV, TOGGLES ON MOBILE #} -