17 lines
691 B
JavaScript
17 lines
691 B
JavaScript
// Function to handle loginBtn click
|
|
document.getElementById('loginBtn').addEventListener('click', function() {
|
|
var popupLogin = document.getElementById('popupLogin');
|
|
popupLogin.style.display = 'flex';
|
|
document.body.style.overflow = 'hidden'; // Disable scroll
|
|
});
|
|
|
|
// Function to handle popupMainInsideWrapperBoxTopBtn click
|
|
document.addEventListener('click', function(event) {
|
|
var clickedElement = event.target;
|
|
if (clickedElement.classList.contains('popupMainInsideWrapperBoxTopBtn')) {
|
|
var popupLogin = document.getElementById('popupLogin');
|
|
popupLogin.style.display = 'none';
|
|
document.body.style.overflow = ''; // Re-enable scroll
|
|
}
|
|
});
|