mirror of
https://github.com/Ocelot-Social-Community/Ocelot-Social.git
synced 2025-12-13 07:46:06 +00:00
the first 50px are excluded from the scrolling hide mechanism
This commit is contained in:
parent
4ae4edf000
commit
e6f2d14fee
@ -300,10 +300,12 @@ export default {
|
||||
methods: {
|
||||
handleScroll() {
|
||||
const currentScrollPos = window.pageYOffset
|
||||
if (this.prevScrollpos > currentScrollPos) {
|
||||
this.hideNavbar = false
|
||||
} else {
|
||||
this.hideNavbar = true
|
||||
if (this.prevScrollpos > 50) {
|
||||
if (this.prevScrollpos > currentScrollPos) {
|
||||
this.hideNavbar = false
|
||||
} else {
|
||||
this.hideNavbar = true
|
||||
}
|
||||
}
|
||||
this.prevScrollpos = currentScrollPos
|
||||
},
|
||||
|
||||
@ -213,11 +213,13 @@ export default {
|
||||
},
|
||||
handleScroll() {
|
||||
const currentScrollPos = window.pageYOffset
|
||||
if (this.prevScrollpos > currentScrollPos) {
|
||||
this.hideByScroll = false
|
||||
} else {
|
||||
if (!this.showFilter) {
|
||||
this.hideByScroll = true
|
||||
if (this.prevScrollpos > 50) {
|
||||
if (this.prevScrollpos > currentScrollPos) {
|
||||
this.hideByScroll = false
|
||||
} else {
|
||||
if (!this.showFilter) {
|
||||
this.hideByScroll = true
|
||||
}
|
||||
}
|
||||
}
|
||||
this.prevScrollpos = currentScrollPos
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user