Utente:Delfo/common.js: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
m test |
test2 |
||
Riga 1:
// Check if we're editing a page.
$textarea.wikiEditor( 'addToToolbar', {▼
if ( [ 'edit', 'submit' ].indexOf( mw.config.get( 'wgAction' ) ) !== -1 ) {
// Add a hook handler.
mw.hook( 'wikiEditor.toolbarReady' ).add( function ( $textarea ) {
// Configure a new toolbar entry on the given $textarea jQuery object.
▲ $textarea.wikiEditor( 'addToToolbar', {
/* Your code goes here */
} );
} );
}
|