Initial Commit
This commit is contained in:
@@ -0,0 +1,19 @@
|
||||
//
|
||||
// modal.js
|
||||
// Theme module
|
||||
//
|
||||
|
||||
const modals = document.querySelectorAll('.modal');
|
||||
|
||||
function overflowHide() {
|
||||
document.documentElement.style.overflowX = 'visible';
|
||||
}
|
||||
|
||||
function overflowShow() {
|
||||
document.documentElement.style.overflowX = '';
|
||||
}
|
||||
|
||||
modals.forEach((modal) => {
|
||||
modal.addEventListener('show.bs.modal', overflowHide);
|
||||
modal.addEventListener('hidden.bs.modal', overflowShow);
|
||||
});
|
||||
Reference in New Issue
Block a user