From: Dan Allen Date: Wed, 14 Aug 2019 00:15:07 +0000 (-0600) Subject: format source X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=68f17dc170edb45ec6c685fab176cf03d1b5e3ff;p=working%2Feg-antora.git format source --- diff --git a/src/js/01-nav.js b/src/js/01-nav.js index 3001c0d..3d1a8a7 100644 --- a/src/js/01-nav.js +++ b/src/js/01-nav.js @@ -86,7 +86,7 @@ var rect = panel.getBoundingClientRect() var effectiveHeight = rect.height var navStyle = window.getComputedStyle(nav) - if (navStyle.position === 'sticky') effectiveHeight -= (rect.top - parseFloat(navStyle.top)) + if (navStyle.position === 'sticky') effectiveHeight -= rect.top - parseFloat(navStyle.top) panel.scrollTop = Math.max(0, (el.getBoundingClientRect().height - effectiveHeight) * 0.5 + el.offsetTop) }