MediaWiki:Common.js: Difference between revisions

Jump to navigation Jump to search
no edit summary
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) {
$(document).on('click', function (event) {
            // Check if the click is outside of the #show-article-wrapper
    // 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) {
    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
        // Remove the fade-out class when hiding the fixed column
                $('#list').removeClass('fade-out');
        $('#list').removeClass('fade-out');
                showArticleWrapper.css('display', 'none');
        showArticleWrapper.css('display', 'none');
            }
    }
        });
});


         // Hover effect for scrolling
         // Hover effect for scrolling

Navigation menu