Template:NeedsTranslationTooltip: Difference between revisions

From Deadlock Wiki
Jump to navigation Jump to search
Sur (talk | contribs)
m outsourced text to Data:Dictionary
Sur (talk | contribs)
m text key can be passed, defaults to the main tooltip
 
Line 1: Line 1:
<sup class="noprint fact">{{tooltip|[''nt'']|{{#invoke:Dictionary|translate_embed|NeedsTranslationTooltip|deadlocked.wiki/Template:Translate}}}}</sup><noinclude>{{Documentation}}
<includeonly><sup class="noprint fact">{{tooltip|[''nt'']|{{#invoke:Dictionary|translate_embed|{{{1|NeedsTranslationTooltip}}}|deadlocked.wiki/Template:Translate}}}}</sup></includeonly><noinclude>{{Documentation}}
</noinclude>
</noinclude>

Latest revision as of 20:04, 14 October 2024

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}}