This commit is contained in:
kek7198 2021-12-06 22:02:23 -06:00
parent 063093634a
commit 0c999d6712

View file

@ -8,19 +8,17 @@ document.getElementsByTagName('body')[0].onscroll = () => {
// var navbar = document.getElementById("navbar");
if (bottomBar != null) {
if (currentScrollPos <= 60) {
if (currentScrollPos <= 60 || currentScrollPos >= document.body.offsetHeight) {
bottomBar.style.transform = "translateY(60px)";
console.log('test 2')
}
else if (prevScrollpos < currentScrollPos && (window.innerHeight + currentScrollPos) >= (document.body.offsetHeight)) {
bottomBar.style.transform = "translateY(60px)";
console.log(document.body.offsetHeight)
console.log((window.innerHeight + currentScrollPos))
}
else if (prevScrollpos > currentScrollPos && (window.innerHeight + currentScrollPos) < (document.body.offsetHeight)) {
else if (prevScrollpos > currentScrollPos && currentScrollPos < document.body.offsetHeight) {
bottomBar.style.transform = "translateY(0px)"
console.log('test 1')
}
else {
bottomBar.style.transform = "translateY(60px)";
}
}
// if (topBar != null && dropdown != null) {