MediaWiki:Gadget-RollbackNascosti.js: differenze tra le versioni
m (Stile) |
m (una versione importata) |
(Nessuna differenza)
|
Versione attuale delle 22:40, 30 ago 2020
/**
* Per gli amministratori, mostra un link "Rollback nascosti" nelle pagine dei contributi
*/
$( function() {
if ( ( mw.config.get( 'wgCanonicalSpecialPageName' ) === 'Contributions' ) &&
( window.location.href.indexOf( 'bot=1' ) === -1 ) &&
( $.inArray( 'sysop', mw.config.get( 'wgUserGroups' ) ) !== -1 )
) {
var sep = window.location.href.indexOf( 'index.php' ) !== -1 ? '&' : '?',
$link = $( '<a title="Rollback nascosti">Rollback nascosti</a>' )
.attr( 'href', window.location.href + sep + 'bot=1' );
$( '#contentSub' ).append( ' · ', $link );
}
} );