fix: better big screen navigation scroll

This commit is contained in:
Matthieu Bessat 2020-09-04 00:00:37 +02:00
parent db60d95d9c
commit b46dff280d
2 changed files with 4 additions and 1 deletions

View file

@ -194,7 +194,9 @@ function enableTag(node) {
closeMenu()
document.getElementsByClassName('content')[0].scrollIntoView(true)
} else {
document.getElementsByClassName('up-footer')[0].scrollIntoView(true)
if (window.scrollY() > 300) {
document.getElementsByClassName('content')[0].scrollIntoView(true)
}
}
}

View file

@ -76,6 +76,7 @@
.content {
padding-top: 1.5em;
display: flex;
padding-bottom: 1em;
}