MediaWiki:Common.js: Atšķirības starp versijām

No ''Vēsture''
Jump to navigationJump to search
Nav labojuma kopsavilkuma
Nav labojuma kopsavilkuma
9. rindiņa: 9. rindiņa:
     "sampleText": "Raksts, uz kuru pāradresē"});
     "sampleText": "Raksts, uz kuru pāradresē"});
   }
   }
jQuery( document ).ready( function ( $ ) {
    $( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
        section: 'advanced',
        group: 'format',
        tools: {
            buttonId: {
                label: 'Comment visible only for editors',
                type: 'button',
                icon: '//upload.wikimedia.org/wikipedia/commons/f/f9/Toolbaricon_regular_S_stroke.png',
                action: {
                    type: 'encapsulate',
                    options: {
                        pre: '<!-- ',
                        peri: 'Insert comment here',
                        post: ' -->'
                    }
                }
            }
        }
    } );
} );

Versija, kas saglabāta 2017. gada 2. augusts, plkst. 17.59

/* Any JavaScript here will be loaded for all users on every page load. */

if (mw.toolbar) {
   mw.toolbar.addButton({
     "imageFile": "http://www.vesture.eu/skins/common/images/Button_redirect.png",
     "speedTip": "Redirect",
     "tagOpen": "#REDIRECT [[",
     "tagClose": "]]",
     "sampleText": "Raksts, uz kuru pāradresē"});
  }

jQuery( document ).ready( function ( $ ) {
    $( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
        section: 'advanced',
        group: 'format',
        tools: {
            buttonId: {
                label: 'Comment visible only for editors',
                type: 'button',
                icon: '//upload.wikimedia.org/wikipedia/commons/f/f9/Toolbaricon_regular_S_stroke.png',
                action: {
                    type: 'encapsulate',
                    options: {
                        pre: '<!-- ',
                        peri: 'Insert comment here',
                        post: ' -->'
                    }
                }
            }
        }
    } );
} );