diff options
author | Phil Hughes <me@iamphill.com> | 2017-08-29 15:34:12 +0300 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-08-29 15:34:12 +0300 |
commit | ab3c8302afdbbcd608e2768f9db5e53ec4358512 (patch) | |
tree | 11362d4c118ee4d81ff0957d10cdc3c689ee3767 /app/assets/javascripts/lib | |
parent | c274da069d0de558613feb5bc35edc1312f5241d (diff) |
Fixes the diff changes buttons from toggling when scrolling
Closes #36698
Diffstat (limited to 'app/assets/javascripts/lib')
-rw-r--r-- | app/assets/javascripts/lib/utils/sticky.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/assets/javascripts/lib/utils/sticky.js b/app/assets/javascripts/lib/utils/sticky.js index ff2b66046b4..283c0ec0410 100644 --- a/app/assets/javascripts/lib/utils/sticky.js +++ b/app/assets/javascripts/lib/utils/sticky.js @@ -1,5 +1,5 @@ export const isSticky = (el, scrollY, stickyTop) => { - const top = el.offsetTop - scrollY; + const top = Math.floor(el.offsetTop - scrollY); if (top <= stickyTop) { el.classList.add('is-stuck'); |