Content added Content deleted
m (Universal Omega moved page User:TheDemon08/common.js to User:TheDemon08/cosmos.js without leaving a redirect) |
(Cleanup for performance; remove not-needed waitForPageTools functiion) |
||
Line 1: | Line 1: | ||
mw.loader.load( '/w/index.php?title=MediaWiki:LastEdited.js&action=raw&ctype=text/javascript' ); |
mw.loader.load( '/w/index.php?title=MediaWiki:LastEdited.js&action=raw&ctype=text/javascript' ); |
||
⚫ | |||
if ( $( '#mw-content .hgroup' ).length > 0 === true ) { |
|||
$(document).ready(function() { |
|||
⚫ | |||
$('input#wpLeaveRedirect').removeAttr('checked'); |
|||
} |
} |
||
if($('#mw-content a[href*="/wiki/Special:UpdateProfile"]').length > 0 === true){ |
if ( $( '#mw-content a[href*="/wiki/Special:UpdateProfile"]' ).length > 0 === true ) { |
||
⚫ | |||
var waitForPageTools = function(selector, callback) { |
|||
⚫ | |||
if ($(selector).length) { |
|||
}, function () { |
|||
⚫ | |||
} else { |
|||
⚫ | |||
setTimeout(function() { |
|||
waitForPageTools(selector, callback); |
|||
}, 100); |
|||
} |
|||
}; |
|||
waitForPageTools('#cosmos-actionsList-list', function() { |
|||
⚫ | |||
⚫ | |||
}, function () { |
|||
⚫ | |||
⚫ | |||
}); |
|||
} |
} |
Revision as of 01:20, 8 June 2021
mw.loader.load( '/w/index.php?title=MediaWiki:LastEdited.js&action=raw&ctype=text/javascript' );
if ( $( '#mw-content .hgroup' ).length > 0 === true ) {
mw.loader.load( '/w/index.php?title=MediaWiki:TagRightsManagement.js&action=raw&ctype=text/javascript' );
}
if ( $( '#mw-content a[href*="/wiki/Special:UpdateProfile"]' ).length > 0 === true ) {
$( '#profile-top, #mw-content #cosmos-articleHeader-actions' ).hover( function () {
$( '#mw-content #cosmos-articleHeader-actions' ).css( 'visibility', 'visible' );
}, function () {
$( '#mw-content #cosmos-articleHeader-actions' ).css( 'visibility', 'hidden' );
});
}