Jump to content

User:Mattflaschen-WMF/common.js: Difference between revisions

From Wikipedia, the free encyclopedia
Content deleted Content added
hope this isn't a heisenbug
m add back quotes
Line 8: Line 8:
mw.loader.load('//meta.wikimedia.org/enwiki/w/index.php?title=User:Krinkle/RTRC.js&action=raw&ctype=text/javascript');
mw.loader.load('//meta.wikimedia.org/enwiki/w/index.php?title=User:Krinkle/RTRC.js&action=raw&ctype=text/javascript');


$( function () {
mw.loader.using( 'mediawiki.util' ).done( function () {
var $body = $( 'body' ), enabled = false;
mw.loader.using( 'mediawiki.util' ).done( function () {
var $body = $( 'body' ), enabled = false;
if ( $body.is( '.mw-special-Recentchanges, .mw-special-Recentchangeslinked, .mw-special-Watchlist' ) ) {
if ( mw.user.options.get( 'rcenhancedfilters' ) ) {
if ( $body.is( '.mw-special-Recentchanges, .mw-special-Recentchangeslinked, .mw-special-Watchlist' ) ) {
if ( $body.is( '.mw-special-Recentchanges, .mw-special-Recentchangeslinked' ) ) {
if ( mw.user.options.get( 'rcenhancedfilters' ) ) {
enabled = true;
if ( $body.is( '.mw-special-Recentchanges, .mw-special-Recentchangeslinked' ) ) {
} else if ( $body.is ('.mw-special-Watchlist' ) ) {
enabled = true;
enabled = ( mw.util.getParamValue( 'rcfilters' ) === '1' );
} else if ( $body.is ('.mw-special-Watchlist' ) ) {
enabled = ( mw.util.getParamValue( 'rcfilters' ) === 1 );
}
}
}
$body.addClass( enabled ? 'mw-rcfilters-enabled' : 'mw-rcfilters-disabled' );
}
mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistBase.css&action=raw&ctype=text/css', 'text/css' );
var skin = mw.config.get( 'skin' );
if ( skin === 'vector' ) {
mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistGreenIndicators.css&action=raw&ctype=text/css', 'text/css' );
} else if ( skin === 'monobook' || skin === 'modern' ) {
mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistGreenIndicatorsMono.css&action=raw&ctype=text/css', 'text/css' );
}
}
$body.addClass( enabled ? 'mw-rcfilters-enabled' : 'mw-rcfilters-disabled' );
mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistChangesBold.css&action=raw&ctype=text/css', 'text/css' );
} );
}

mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistBase.css&action=raw&ctype=text/css', 'text/css' );

var skin = mw.config.get( 'skin' );
if ( skin === 'vector' ) {
mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistGreenIndicators.css&action=raw&ctype=text/css', 'text/css' );
} else if ( skin === 'monobook' || skin === 'modern' ) {
mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistGreenIndicatorsMono.css&action=raw&ctype=text/css', 'text/css' );
}

mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistChangesBold.css&action=raw&ctype=text/css', 'text/css' );
} );
} );

Revision as of 02:16, 12 September 2017

mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Albert221/common.css&action=raw&ctype=text/css', 'text/css' );
mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=MediaWiki:Gadget-ReferenceTooltips.js&action=raw&ctype=text/javascript' );

// [[File:User:He7d3r/Tools/DebugModeToggle.js]] (workaround for [[bugzilla:33355]])
mw.loader.load( '//meta.wikimedia.org/enwiki/w/index.php?title=User:He7d3r/Tools/DebugModeToggle.js&action=raw&ctype=text/javascript' );

// [[File:Krinkle_RTRC.js]]
mw.loader.load('//meta.wikimedia.org/enwiki/w/index.php?title=User:Krinkle/RTRC.js&action=raw&ctype=text/javascript');

mw.loader.using( 'mediawiki.util' ).done( function () {
	var $body = $( 'body' ), enabled = false;
	
	if ( $body.is( '.mw-special-Recentchanges, .mw-special-Recentchangeslinked, .mw-special-Watchlist' ) ) {
		if ( mw.user.options.get( 'rcenhancedfilters' ) ) {
			if ( $body.is( '.mw-special-Recentchanges, .mw-special-Recentchangeslinked' ) ) {
				enabled = true;
			} else if ( $body.is ('.mw-special-Watchlist' ) ) {
				enabled = ( mw.util.getParamValue( 'rcfilters' ) === '1' );
			}
		}
	
		$body.addClass( enabled ? 'mw-rcfilters-enabled' : 'mw-rcfilters-disabled' );
	}

	mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistBase.css&action=raw&ctype=text/css', 'text/css' );

	var skin = mw.config.get( 'skin' );
	if ( skin === 'vector' ) {
		mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistGreenIndicators.css&action=raw&ctype=text/css', 'text/css' );
	} else if ( skin === 'monobook' || skin === 'modern' ) {
		mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistGreenIndicatorsMono.css&action=raw&ctype=text/css', 'text/css' );
	}

	mw.loader.load( 'https://en.wikipedia.org/enwiki/w/index.php?title=User:Mattflaschen-WMF/MediaWiki:Gadget-WatchlistChangesBold.css&action=raw&ctype=text/css', 'text/css' );
} );