Użytkownik:Frisk/hydra.js: Różnice pomiędzy wersjami
Przejdź do nawigacji
Przejdź do wyszukiwania
test |
d added padding |
||
| Linia 13: | Linia 13: | ||
$( '<a>' ).addClass( 'rc-editlink' ).attr( { | $( '<a>' ).addClass( 'rc-editlink' ).attr( { | ||
href: mw.util.getUrl( title, { action: 'edit' } ), | href: mw.util.getUrl( title, { action: 'edit' } ), | ||
title: 'Edit this page' | title: 'Edit this page', | ||
style: 'padding-left: 3px;padding-right: 3px;' | |||
} ).text( '✎' ).insertAfter( this ); | } ).text( '✎' ).insertAfter( this ); | ||
} | } | ||
Wersja z 02:03, 6 sty 2018
( function() {
'use strict';
var $changeList = $( '.mw-changeslist' );
if ( !$changeList.length ) {
return;
}
mw.loader.using( 'mediawiki.util' ).then( function() {
$changeList.find( '.mw-title' ).each( function() {
var title = $( this ).find( '.mw-changeslist-title' ).attr( 'title' );
if ( title ) {
$( '<a>' ).addClass( 'rc-editlink' ).attr( {
href: mw.util.getUrl( title, { action: 'edit' } ),
title: 'Edit this page',
style: 'padding-left: 3px;padding-right: 3px;'
} ).text( '✎' ).insertAfter( this );
}
} );
} );
}() );