User:Cafeinlove/global.js

/** This scripts affect only for User:Cafeinlove **/

/* AjaxBatchDelete */ importArticle({   type: "script",    article: [        "w:dev:AjaxBatchDelete/code.js"    ] });

/* PurgeButton */ (function($,mw){	'use strict';	var nsNr = mw.config.get( 'wgNamespaceNumber' ),	theText = typeof window.PurgeButtonText === 'string' ? window.PurgeButtonText : '새로고침'; //default text, ala SMW	if (nsNr < 0 || window.PurgeButtonsLoaded || document.getElementById( 'control_purge')){		return;	}	window.PurgeButtonsLoaded = true; // prevent duplicate running (but not dupe buttons from outside this code)	$( addPurgeButton );	function purgePage {		var page = encodeURIComponent( mw.config.get( 'wgPageName' ) );		$.get( '/index.php?title=' + page + '&action=purge', function  { location.reload( true ); });	}	function addOasisPurgeButton {		var selector;		switch (nsNr) {		case 500:		case 502:			selector = $( '#WikiaUserPagesHeader' );			break;		case 2:		case 3:			selector = $( '.UserProfileActionButton' );			if ( selector.length ) break;		default:			selector = $( '#WikiaPageHeader' );	}	selector.find('.wikia-menu-button').first.find('ul')	.append(''+ theText + '');	}

function addPurgeButton { switch( mw.config.get( 'skin' ) ) { case 'oasis': case 'wikia': addOasisPurgeButton; break; }

$('#purge').click(purgePage); }   }(jQuery, mediaWiki));

/* AddFollowingButton */ $(function{	if( skin === 'monobook' ) {		addPortletLink( 'p-tb', wgServer + wgScriptPath + '/index.php?title=Special:Following', '주시중인 문서');	} else {		$( 'ul.tools' ).append( ' 주시중인 문서' );	} });