MediaWiki:Timeless.js

$( function  {

$(document).ready( function {	//Making the sidebar collapsible//	// Giving the content the necessary IDs	$('#p-Wiki_Navigation .mw-portlet-body').attr('id','wiki-navigation');	$('#p-Useful_Links .mw-portlet-body').attr('id','useful-links');	$('#p-Player_Character .mw-portlet-body').attr('id','player-character');	$('#p-Items .mw-portlet-body').attr('id','items');	$('#p-Love_Interests .mw-portlet-body').attr('id','love-interests');	$('#p-People_of_Interest .mw-portlet-body').attr('id','people-of-interest');       $('#p-Special_NPCs .mw-portlet-body').attr('id','special-npcs');	$('#p-Locations .mw-portlet-body').attr('id','locations');	$('#p-Quests .mw-portlet-body').attr('id','quests');	$('#p-Mechanics .mw-portlet-body').attr('id','mechanics');	$('#p-Toggles .mw-portlet-body').attr('id','toggles');	$('#p-managewiki-sidebar-header .mw-portlet-body').attr('id','administration');

// Contents are collapsed as default $('#wiki-navigation').hide; $('#useful-links').hide; $('#player-character').hide; $('#items').hide; $('#love-interests').hide; $('#people-of-interest').hide; $('#special-npcs').hide; $('#locations').hide; $('#quests').hide; $('#mechanics').hide; $('#toggles').hide; $('#administration').hide; // Making the contents collapsible $('#p-Wiki_Navigation-label').click(function{		$('#wiki-navigation').toggle("fast");	}); $('#p-Useful_Links-label').click(function{		$('#useful-links').toggle("fast");	}); $('#p-Player_Character-label').click(function{		$('#player-character').toggle("fast");	}); $('#p-Items-label').click(function{		$('#items').toggle("fast");	}); $('#p-Love_Interests-label').click(function{		$('#love-interests').toggle("fast");   }); $('#p-People_of_Interest-label').click(function{		$('#people-of-interest').toggle("fast");	}); $('#p-Special_NPCs-label').click(function{		$('#special-npcs').toggle("fast");	}); $('#p-Locations-label').click(function{		$('#locations').toggle("fast");	}); $('#p-Quests-label').click(function{		$('#quests').toggle("fast");	}); $('#p-Mechanics-label').click(function{		$('#mechanics').toggle("fast");	}); $('#p-Toggles-label').click(function{		$('#toggles').toggle("fast");	}); $('#p-managewiki-sidebar-header-label').click(function{		$('#administration').toggle("fast");	}); //Moving the "wiki tools" to the right// $('#site-tools').prependTo('#mw-related-navigation'); $('#mw-related-navigation').wrapInner(' '); //Add "Mass Edit" and "Admin Help" to the administration part in the sidebar $('#p-managewiki-sidebar-header .mw-portlet-body ul').attr('id','administration-ul'); $('#administration-ul').append(' Mass edit pages '); $('#administration-ul').append(' Admin Help '); } );

} ); /* Do not enter code below this line */