Wikipedia:Tools/Navigation popups/Translation

From Wikipedia, the free encyclopedia
Jump to: navigation, search
Example of popup

The user interface of the navigation popups script can be translated to most languages by copying and translating a file of text strings. Alternatively, the complete script can be translated.

Instructions for translating the string file plus a list of existing translations are given here. If you have translated the string file, the script or the instruction page to some language, please add it to the list below.


Instructions for translation of string file[edit]

  • Translate the strings on the righthand side of each assignment. An assignment looks like this:
'string1': 'string2',
You should leave 'string1' unchanged and translate 'string2'. Any apostrophes in 'string2' should be backslash-escaped, for example 'L\'article'. Be sure to leave the comma at the end of the line unchanged.
  • Strings with one or more %s get arguments from the script, e.g. article name or user name. These %s-es are included in string2 in the same order as in string1. If you want a different order, you can instead refer to the arguments as $1, $2, $3, etc.
  • From your skin .js file, e.g. monobook.js, load your translation .js file as well as popups.js using code similar to this:
mw.loader.load( 'https://en.wikipedia.org/w/load.php?modules=ext.gadget.Navigation_popups&only=scripts' );
  • Kindly include your translation in the list below. To keep the translation updated, you must watch the file that you copied, and change your file according to changes in the original, e.g. new strings or changes in syntax.

List of existing translations[edit]

Translation of string file for any version since 23-Feb-2006[edit]

Please list translations like this:

* Language: [[:interwikicode:User:username/filename.js]]

Translation of complete script, locked to specific versions[edit]

Please list translations like this:

* Language: script version: [[:interwikicode:namespace:filename.js]]

Translation of instruction pages[edit]

Please list translations like this:

* Language: [[:interwikicode:Wikipedia:pagename]]