Template:Translated tag: Difference between revisions
More actions
m template for translated tag (work in progress) |
switch {{autotranslate}} to a module call |
||
| (142 intermediate revisions by 69 users not shown) | |||
| Line 1: | Line 1: | ||
< | {{#ifeq:{{NAMESPACE}}|{{ns:4}}||<!-- ignore commons namespace for demonstration pages --> | ||
{{#switch:{{FULLPAGENAME}} | |||
|{{{ns|{{{ns1|{{ns:10}}}}}}}}:{{ucfirst:{{{page|{{{page1}}}}}}}}{{{sub|/{{SUBPAGENAME}}}}} | |||
< | |{{{ns2|{{ns:10}}}}}:{{ucfirst:{{{page2}}}}}{{{sub|/{{SUBPAGENAME}}}}} | ||
|{{{ns3|{{ns:10}}}}}:{{ucfirst:{{{page3}}}}}{{{sub|/{{SUBPAGENAME}}}}} | |||
|{{{ns4|{{ns:10}}}}}:{{ucfirst:{{{page4}}}}}{{{sub|/{{SUBPAGENAME}}}}} = <!-- for any exceptions --> | |||
|#default = | |||
{{#switch:localisation|{{{1}}}|{{{2}}}=<!-- it may be used directly so the message doesn't apply -->|#default = | |||
{{#invoke:Autotranslate|autotranslate | |||
|base=Template:Translated tag/i18n | |||
{{ #switch: {{ | |lang={{{lang|}}} | ||
| | |template={{{template|{{#ifexist:{{BASEPAGENAME}}|{{BASEPAGENAME}}|{{#titleparts:{{PAGENAME}}|1}}}}}}} | ||
| | }} | ||
| | }}<!-- | ||
auto-categorizer | |||
-->{{#ifeq:{{FULLPAGENAME}}|{{ns:10}}:{{BASEPAGENAME}}/{{SUBPAGENAME}} | |||
}} | | {{DEFAULTSORT:{{PAGENAME}}}}<!-- | ||
-->{{{localcat|[[Category:{{#ifexist:Template:Translated tag/local category-{{SUBPAGENAME}} | |||
| {{translated tag/local category-{{SUBPAGENAME}}|{{{1}}}}} | |||
| Commons templates-{{SUBPAGENAME}} }}]]}}}<!-- | |||
-->[[Category:Translated {{#switch:{{lc:{{{1}}}}} | |||
| cleanup = media cleanup templates | |||
| license = license tags | |||
| marker = marker templates | |||
| problem = problem tags | |||
| restriction = restriction tags | |||
| header = header templates | |||
| infobox = infobox templates | |||
| navigational = navigational templates | |||
| protection = protection templates | |||
| source = source templates | |||
| documentation = documentation templates | |||
| user = user templates | |||
| localisation = templates for localisation | |||
| templates needing categories | |||
}}]] | |||
| {{#ifeq:{{NAMESPACE}}|{{ns:6}}|[[Category:Images using translated tags]]}}<!-- check for misuse --> | |||
}}<!-- | |||
end auto-categorizer | |||
-->}} | |||
}}<noinclude>{{documentation}}</noinclude> | |||
Latest revision as of 13:16, 8 August 2024
This template is used on translated template messages, to avoid getting these on image pages and to lead to use the master template (NOT the translated one).
Usage
{{Translated tag |1= }}
Template parameters
| Parameter | Description | Default | Status | |
|---|---|---|---|---|
1 | Type | All categorization of translated tags is done through this template. It will add a local category based on the template's language and a general maintenance category based on the type of template it is. For the latter, you must supply the "type" as the first parameter. See Template:Translated tag/local category-en for possible values (or view template code). All templates lacking this will end up in Category:Translated templates needing categories (however they will still be in a proper language-based category). If none of the available options match the template in question just leave it as {{translated tag}}.
Add one of the following as the first parameter:
| empty | required |
|
<templatedata>JSON</templatedata> ./. {{TemplateBox}}
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 Newly created template documentation and imports Wikipedia's help about TemplateData • Commons-specific information This template is used on translated template messages, to avoid getting these on image pages and to lead to use the master template (NOT the translated one).
| ||||||||||
Additional information
The template is intended to be used in the following namespaces: the Template namespace
The template is intended to be used by the following user groups: all users
Placement: At the bottom of the page
Localization
العربية ∙ беларуская (тарашкевіца) ∙ বাংলা ∙ čeština ∙ Deutsch ∙ English ∙ español ∙ euskara ∙ فارسی ∙ français ∙ galego ∙ עברית ∙ हिन्दी ∙ Bahasa Indonesia ∙ italiano ∙ 日本語 ∙ 한국어 ∙ македонски ∙ മലയാളം ∙ Bahasa Melayu ∙ Nederlands ∙ polski ∙ português ∙ русский ∙ sicilianu ∙ slovenščina ∙ српски / srpski ∙ svenska ∙ ไทย ∙ Türkçe ∙ українська ∙ Tiếng Việt ∙ 中文
This template makes use of {{Autotranslate}} and the translate extension.