Template:NeedsTranslationTooltip: Difference between revisions

From Deadlock Wiki
Jump to navigation Jump to search
Sur (talk | contribs)
m no longer states that it was presented in english, as now it can display the key instead
Sur (talk | contribs)
m outsourced text to Data:Dictionary
Line 1: Line 1:
<sup class="noprint fact">{{tooltip|[''nt'']|This Needs Translation to the current language. To help translate it, visit deadlocked.wiki/Template:Translate for documentation.}}</sup><noinclude>{{Documentation}}
<sup class="noprint fact">{{tooltip|[''nt'']|{{#invoke:Dictionary|translate_embed|NeedsTranslationTooltip|deadlocked.wiki/Template:Translate}}}}</sup><noinclude>{{Documentation}}
</noinclude>
</noinclude>

Revision as of 22:30, 12 October 2024

[nt]

Template documentation [view] [edit] [history] [purge]

Added directly after content that needs localization, including both larger content such as Abrams#Introduction, and shorter strings such as "Patch notes" in a Hero's Update history article, which are otherwise written in a template.

See Template:Translate for documentation and further information to help translate marked text.

Optional first parameter is translation-key to localize and display. Defaults to 'NeedsTranslationTooltip' which displays "This needs translation to English. To help translate it, visit %s.".

In most circumstances, use no parameter. Patch notes{{NeedsTranslationTooltip}}

Outputs

Patch notes[nt]


One special circumstance for needing to use another key is in an ability article. Notes for the ability come from /<ability name>/Notes, so if 'Notes' is not yet translated, the page can't exist, and it instead transcludes the english notes. In this case, the 'NotesNeedsTranslation' key is passed, which displays "Notes page cannot be created until 'Notes' is translated.".

This is accomplished with

{{NeedsTranslationTooltip|NotesNeedsTranslation}}