Vintage Story Wiki:How to translate the wiki/en: Difference between revisions

From Vintage Story Wiki
Updating to match new version of source page
(Updating to match new version of source page)
(Updating to match new version of source page)
Line 14: Line 14:
*: {{ll|Template:Page language link|2=Template:Page language link}}
*: {{ll|Template:Page language link|2=Template:Page language link}}
*: {{ll|Template:Localized link|2=Template:Localized link}}
*: {{ll|Template:Localized link|2=Template:Localized link}}
*: {{ll|Template:Translatable template|2=Template:Translatable template}}
* If you are marking a '''template''' for translation, make sure the "Enable translation-aware transclusion" checkbox is selected!
=== How to mark for translation ===
=== How to mark for translation ===
''PLEASE read the [https://www.mediawiki.org/wiki/Help:Extension:Translate/Page_translation_example official MediaWiki documentation] for this feature!''
''PLEASE read the [https://www.mediawiki.org/wiki/Help:Extension:Translate/Page_translation_example official MediaWiki documentation] for this feature!''
Line 33: Line 33:


[[File:Update-translation.PNG|thumb|500px|right]]
[[File:Update-translation.PNG|thumb|500px|right]]
[[File:Update-translation-version.PNG|thumb|500px|right]]


# Go to the page you want to translate and switch to the language you want to translate to
# Go to the page you want to translate and switch to the language you want to translate to
# If the page does not offer the option for that language yet, no translation has been started
# If the page does not offer the option for that language yet, no translation has been started
# If there was a translation attempt previously, the page will show the current progress of translation at the top, adding information if the translation is up to date or not
# If there was a translation attempt previously, the page will show the current progress of translation at the top, adding information if the translation is up to date or not
# Click on "translated version" to continue working on the translation.
# Instead you might also find "This page contains changes which are not marked for translation." - in which case the original version of the page was updated since it's last translation. Click on "marked for translation" and check the changes between last (translated) version and the current one. Take care to not invalidate previous translations unless they now include misleading or wrong translations - keep in mind that you would not just invalidate your own translation language, but all others as well!
# Once done checking, scroll to the bottom and hit "mark this version for translation".
# Back on the content page, click on "translated version" to continue working on the translation.


=== How to actually translate ===
=== How to actually translate ===
Line 60: Line 63:
== How to translate templates ==
== How to translate templates ==


[[File:Template-translate.PNG|thumb|500px|right|Veerserif's note: now outdated due to the new tnt template.]]
[[File:Template-translate.PNG|thumb|500px|right|Veerserif's note: now outdated due to the new {{tl|tnt}} template and software update.]]


Templates should only be tagged and mark for translation when they are ''complete''. Make sure the <code><nowiki><languages /></nowiki></code> tag is '''outside''' of the part of the template marked for transclusion, i.e. the <code><nowiki><onlyinclude> ... </onlyinclude></nowiki></code> or <code><nowiki><includeonly> ... </includeonly></nowiki></code> part.
Templates should only be tagged and mark for translation when they are ''complete''. Make sure the <code><nowiki><languages /></nowiki></code> tag is '''outside''' of the part of the template marked for transclusion, i.e. the <code><nowiki><onlyinclude> ... </onlyinclude></nowiki></code> or <code><nowiki><includeonly> ... </includeonly></nowiki></code> part.


When you use a translated or translatable (i.e. tagged and marked for translation) template on any page, you '''must''' use the [[Template:Translatable template|Translatable template]] template instead! For example, if you wanted to use the <code><nowiki>{{Metals navbox}}</nowiki></code> template on a page, instead write it as <code><nowiki>{{Translatable template|Metals navbox}}</nowiki></code>. You can also use <code><nowiki>{{tnt|Metals navbox}}</nowiki></code> as a shorter version.
When you mark a template for translation, '''make sure''' that the "Enable translation-aware transclusion" checkbox is enabled. On older templates, you must make a content change that would prompt you to re-mark it for translation in order to update its translations to be transclusion aware. Once you have done so, MediaWiki will automatically fetch the correctly translated version of the template for use on a translated page - there's no longer a need to use {{tl|tnt}} to call them.


When translating a page that uses translatable templates, do not include them within the <code><nowiki><translate></nowiki></code> tags. (I'm repeating this because it's important.)
When translating a page that uses translatable templates, do not include them within the <code><nowiki><translate></nowiki></code> tags. (I'm repeating this because it's important.)
43,178

edits