Open main menu

Template:Local template category

Curly Brackets.svg This category is for translated or localised templates. The main category is located at Category:Commons templates.
[{{fullurl:Template:Local template category/description/{{{1}}}|action=edit}} Please translate this!]
Tango Globe of Letters.svg
Documentation icon Documentationviewedithistorypurge

This documentation is transcluded from Template:Local template category/doc.

This goes at the top of all template categories which contain translated templates.

Usage

{{Local template category |1= |2= }}

Template parameters

ParameterDescriptionDefaultStatus
1
language codeThe code of the language of the translated templates{{SUBPAGENAME}}required
2
main categoryThe name of the main category where the non-translated templates areCommons templatesrequired
Template data
<templatedata>JSON</templatedata> ./. {{TemplateBox}}
TemplateData

TemplateData is a way to store information about template parameters (the description of those and of the whole template) for both humans and machines. It is used by VisualEditor and possibly other tools like Upload Wizard.


Existing template documentation
At Wikimedia Commons, it is recommended to use {{TemplateBox}} with either useTemplateData=1 or useTemplateData=only on the /doc subpage and transcluding it with {{Documentation}} into the template. <nowiki>-tags can be wrapped around the arguments, if required, to avoid templates being expanded.

Newly created template documentation and imports
Another option, especially for imported templates, or for users with JSON experience, is placing raw <templatedata>-tags into the Wikitext of the template, as described in various Wikipediae.

Discussion
There is an ongoing discussion about that matter. Feel invited to comment if you are experienced in either way, your time permits and if you like to share your opinion or to make a suggestion.


Wikipedia's help about TemplateDataCommons-specific information

This goes at the top of all template categories which contain translated templates.

Template parameters

ParameterDescriptionTypeStatus
language code1

The code of the language of the translated templates

Default
{{SUBPAGENAME}}
Stringrequired
main category2

The name of the main category where the non-translated templates are

Default
Commons templates
Stringrequired

Additional information

The template is intended to be used in the following namespaces: the Category namespace

The template is intended to be used by the following user groups: all users

Placement: At the top of the page

See also

Localization

This template is not intended to be localized.

This template should not be translated. The text inside it is located at Template:Local template category/description and that should be translated. The template will switch out the default text (as seen above) automatically with the translation on that language's category pages. All translations of {{local template category/description}} should be created as subpages of that page.