MediaWiki:Common.js/portal.js

/* Any JavaScript here will be loaded for all users on every page load. */ /* Sliders using jquery * By: User:Tierrie, with modifications by User:Thailog and User:KettleMeetPot */ $(document).ready(function { if ( wgPageName == "Howlslittlefjord_Wiki") {    mw.loader.using( ['jquery.ui.tabs'], function { var $tabs = $("#portal_slider").tabs({ fx: [{opacity:'toggle', duration:200},{height:'toggle', duration:'normal'}, ] } ); $("[class^=portal_sliderlink]").click(function { // bind click event to link       var currentCl = $(this).prop('class');        var workaround = $(this).children("a").prop('href');        $(this).children("a").children("img").addClass("selectedImg");        $(".selectedImg").animate( {height: "90%", width: "90%" }, { duration: 50, queue: true} );        $(".selectedImg").animate( {height: "100%", width: "100%" }, { duration: 150, queue: true, complete: function{ $(".selectedImg").removeClass("selectedImg"); if ( currentCl != "portal_sliderlink_15" ) { $tabs.tabs('select', currentCl.replace("portal_sliderlink_", "")); }         else { window.location.replace(workaround); }       } } );        return false;      }); });   } });