fix: custom scrollbar does not reload after page switch
This commit is contained in:
parent
960e85f92d
commit
176b38a4cb
|
@ -327,6 +327,7 @@ const setup = () => {
|
||||||
window.swup.hooks.on('link:click', () => {
|
window.swup.hooks.on('link:click', () => {
|
||||||
document.documentElement.style.setProperty('--content-delay', '0ms')
|
document.documentElement.style.setProperty('--content-delay', '0ms')
|
||||||
})
|
})
|
||||||
|
window.swup.hooks.on('content:replace', initCustomScrollbar)
|
||||||
}
|
}
|
||||||
if (window.swup.hooks) {
|
if (window.swup.hooks) {
|
||||||
setup()
|
setup()
|
||||||
|
|
Loading…
Reference in New Issue