MediaWiki:Common.js

/* Any JavaScript here will be loaded for all users on every page load. */

/* Bad Tabber Fix All of this so it won't do history.pushState function checkExist(selector, cb) { var i = 0; var handler = setInterval(function {       i += 1;        if (i > 4) clearInterval(handler);        if (document.querySelector(selector)) {            cb.call;            clearInterval(handler);        }    }, 1000); } checkExist('.tabbernav', function {	$('.character__details + div .tabbernav a').each( function { $(this).click( function(e) {			e.stopPropagation;

// https://github.com/HydraWiki/Tabber/blob/a499360d0d8081eed24bb8dfcbe3bc1e212e7301/js/tabber.js#L25 function showContent( title, tabber ) { var tabContent = $(tabber).closest('.tabber').children('.tabbertab'); var nav = $(tabber).children('.tabbernav');

var content = tabContent.filter( '[title="' + title + '"]' ); if ( content.length !== 1 ) { return false; } tabContent.hide; content.show; nav.find( '.tabberactive' ).removeClass( 'tabberactive' ); nav.find( 'a[title="' + title + '"]' ).parent.addClass( 'tabberactive' ); return true; }

var tabber = $(this).closest('.tabber'); var title = $(this).attr('title'); showContent(title, tabber); });	}); });