reset nav scrollTop if not on pattern page
This commit is contained in:
parent
36bf525ad7
commit
4c207a345f
|
@ -35,6 +35,10 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
window.addEventListener('DOMContentLoaded', function () {
|
window.addEventListener('DOMContentLoaded', function () {
|
||||||
|
if (window.location.href.indexOf('patterns/') !== -1) {
|
||||||
document.getElementById('patterns-nav').scrollTop = parseInt(localStorage.getItem('scrollPoint'))
|
document.getElementById('patterns-nav').scrollTop = parseInt(localStorage.getItem('scrollPoint'))
|
||||||
|
} else {
|
||||||
|
document.getElementById('patterns-nav').scrollTop = 0
|
||||||
|
}
|
||||||
})
|
})
|
||||||
}());
|
}());
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -35,6 +35,10 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
window.addEventListener('DOMContentLoaded', function () {
|
window.addEventListener('DOMContentLoaded', function () {
|
||||||
|
if (window.location.href.indexOf('patterns/') !== -1) {
|
||||||
document.getElementById('patterns-nav').scrollTop = parseInt(localStorage.getItem('scrollPoint'))
|
document.getElementById('patterns-nav').scrollTop = parseInt(localStorage.getItem('scrollPoint'))
|
||||||
|
} else {
|
||||||
|
document.getElementById('patterns-nav').scrollTop = 0
|
||||||
|
}
|
||||||
})
|
})
|
||||||
}());
|
}());
|
||||||
|
|
Loading…
Reference in New Issue
Block a user