forked from rDrama/rDrama
same as last commit
parent
6022699118
commit
30ec96be0d
|
@ -598,11 +598,10 @@ if (screen_width <= 768) {
|
||||||
}, 100);
|
}, 100);
|
||||||
});
|
});
|
||||||
|
|
||||||
window.addEventListener('hashchange', (e) => {
|
window.addEventListener('hashchange', () => {
|
||||||
if (e.oldURL.includes('#m-')) {
|
if (!location.hash.startsWith("#m-")) {
|
||||||
const modal_id = e.oldURL.split('#m-')[1]
|
const curr_modal = bootstrap.Modal.getInstance(document.getElementsByClassName('show')[0])
|
||||||
const modal = document.getElementById(modal_id)
|
if (curr_modal) curr_modal.hide()
|
||||||
bootstrap.Modal.getInstance(modal).hide()
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue