diff options
| author | Mike Bayer <mike_mp@zzzcomputing.com> | 2014-05-27 16:53:49 -0400 |
|---|---|---|
| committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2014-05-27 16:53:49 -0400 |
| commit | bb671fafcaf029b298aceb9faba8901c648208f0 (patch) | |
| tree | 32aa3e2599708b53fc68365f6ebd7e6117c0db12 /doc/build/static | |
| parent | a0366c9a56156bb01506d6ed977d945c371d0d06 (diff) | |
| download | sqlalchemy-bb671fafcaf029b298aceb9faba8901c648208f0.tar.gz | |
OK this one seems to be the most solid
Diffstat (limited to 'doc/build/static')
| -rw-r--r-- | doc/build/static/docs.css | 6 | ||||
| -rw-r--r-- | doc/build/static/init.js | 12 |
2 files changed, 11 insertions, 7 deletions
diff --git a/doc/build/static/docs.css b/doc/build/static/docs.css index a740fc426..f6e7cc6f2 100644 --- a/doc/build/static/docs.css +++ b/doc/build/static/docs.css @@ -1,5 +1,9 @@ /* global */ +.body-background { + background-color: #FDFBFC; +} + body { background-color: #FDFBFC; margin:0 38px; @@ -197,7 +201,6 @@ a.headerlink:hover { #docs-top-navigation-container { - background-color:#FFF; } #docs-top-navigation-container.automated { @@ -205,7 +208,6 @@ a.headerlink:hover { top:0; z-index:100; width:100%; - background-color:#FFF; } /* http://css-tricks.com/hash-tag-links-padding/ */ diff --git a/doc/build/static/init.js b/doc/build/static/init.js index 0d3e678ba..0732890c9 100644 --- a/doc/build/static/init.js +++ b/doc/build/static/init.js @@ -12,11 +12,8 @@ var automatedBreakpoint = -1; function initFloatyThings() { automatedBreakpoint = $("#docs-container").position().top; - containerHeight = $("#docs-top-navigation-container").height(); - - // TODO: calculate the '9' here - autoOffset = containerHeight + 9; + parentOffset = $("#docs-container").parent().position().top - $("#docs-container").position().top; $("#docs-top-navigation-container").addClass("preautomated"); $("#docs-sidebar").addClass("preautomated"); $("#docs-container").addClass("preautomated"); @@ -32,7 +29,12 @@ function initFloatyThings() { setNavSize(); $("#docs-top-navigation-container").addClass("automated"); $("#docs-sidebar").addClass("automated"); - $("#docs-body").css("margin-top", autoOffset); + + // note this height is dependent on docs-top-navigation-container + // being position:fixed or absolute, otherwise it might get + // a little squashed + containerHeight = $("#docs-top-navigation-container").height(); + $("#docs-body").css("margin-top", containerHeight - parentOffset + 1); } else { $("#docs-sidebar.automated").scrollTop(0); |
