4,090
edits
No edit summary |
No edit summary |
||
Line 48: | Line 48: | ||
// Attach a click event listener to close the fixed column | // Attach a click event listener to close the fixed column | ||
$(document).on('click', function (event) { | |||
// Check if the click is outside of the #show-article-wrapper and not on a card | |||
if (!showArticleWrapper.is(event.target) && showArticleWrapper.has(event.target).length === 0 && !$(event.target).hasClass('card')) { | |||
// Remove the fade-out class when hiding the fixed column | |||
$('#list').removeClass('fade-out'); | |||
showArticleWrapper.css('display', 'none'); | |||
} | |||
}); | |||
// Hover effect for scrolling | // Hover effect for scrolling |