User:Soxra/monobook.js

function includePage(name) { document.write('<\/script>'); }

importScriptPage("AjaxBatchDelete/code.js", "dev"); includePage('User:Soxra/Plugins.js');

$(document).ready(function {	/* Shrinking talk bubble sprites */	if (document.readyState != "complete") {		setTimeout(arguments.callee,100);		return;	}	/* Collapsible sidebar */	$("#column-one #p-logo").nextAll(".portlet").each(function { var $this = $(this); var id = $this.attr("id"); var expanded = $.cookie("sidebar-" + id + "-expanded"); if (expanded == undefined || expanded == null) { expanded = "true"; if (id == "p-search" || id == "p-wikicities-nav") expanded = "false"; }		if (expanded == "true") { $this.find(".pBody").show; $this.data("expanded", true); } else { $this.find(".pBody").hide; $this.data("expanded", false); }		$this.find("h5").click(function {			if ($this.find(".pBody").is(":animated"))				return false;			if ($this.data("expanded") == true) {				$this.find(".pBody").slideUp(500);				$.cookie("sidebar-" + id + "-expanded", "false");				$this.data("expanded", false);			} else {				$this.find(".pBody").slideDown(500);				$.cookie("sidebar-" + id + "-expanded", "true");				$this.data("expanded", true);			}			return false;		}); });	/* Fix for URL parsers which do not catch the last ")" of a URL */ $(".noarticletext:first").each(function {		var headerText = $("#firstHeading").text;		var countL = 0;		var countR = 0;		var leftBracket = headerText.match(/\(/g); var rightBracket = headerText.match(/\)/g);		if (leftBracket)			countL = leftBracket.length;		if (rightBracket)			countR = rightBracket.length;		if (countL == countR + 1) {			var didYouMean = " Did you mean " + headerText + ")? ";			$("#mw-content-text").prepend($(" ", {				html: didYouMean,			}));		}	}); /* Tabby */ $("body.ns-8.action-edit textarea, body.ns-8.action-submit textarea").tabby; $("body.ns-2.action-edit textarea, body.ns-2.action-submit textarea").tabby; /* Recent Changes modifications */ $(".page-Special_RecentChanges").each(function {		$("table.mw-enhanced-rc.mw-collapsible").removeClass("mw-collapsible");		$(".mw-collapsible-toggle").live("mouseover",function { $(this).unbind.die; });		/* Sliding enhanced page */		$("table.mw-enhanced-rc.mw-made-collapsible .mw-rc-openarrow a, table.mw-enhanced-rc.mw-made-collapsible .mw-rc-closearrow a").live("click",function { var $collTable = $(this).closest("table.mw-enhanced-rc.mw-made-collapsible"); var $openarrow = $collTable.find(".mw-rc-openarrow"); var $closearrow = $collTable.find(".mw-rc-closearrow"); $openarrow.css("visibility","visible").removeClass("mw-changeslist-hidden mw-changeslist-expanded"); $closearrow.css("visibility","visible").removeClass("mw-changeslist-hidden mw-changeslist-expanded"); if ($collTable.find("tr:last").is(":hidden")) { $openarrow.hide; $closearrow.show; $collTable.find("tr:not(:first)").show; } else { $openarrow.show; $closearrow.hide; $collTable.find("tr:not(:first)").hide; }			return false; });	});	/* Highlight desired section */ var supportElem = jQuery(" ")[0]; supportElem.style.cssText = "background-color:rgba(1,1,1,.5)"; if (supportElem.style.backgroundColor.indexOf("rgba") > -1) { $("#" + window.location.hash.substring(1).replace(/'/, "")).closest("h6, h5, h4, h3, h2, h1").css("background-color", "#d58e04").delay(1000).animate({ "background-color": "transparent" }, 1000); }	/* Selected sidebar item */ $("#column-one li a").each(function {		var href = $(this).attr("href");		if (href == document.URL.replace("http://fma.wikia.com", "")) {			$(this).addClass("selected");		}	}); });