Template:T/doc: Difference between revisions
More actions
m catdiff |
m Fix Linter errors. |
||
| Line 42: | Line 42: | ||
|3 = 3 | |3 = 3 | ||
|3aliases = lang | |3aliases = lang | ||
|3d = interwiki language code ({{w|List of ISO 639-1 codes|ISO 639}}), if the template is in another Wikipedia<br>can also be specified with <code>lang=</code> | |3d = interwiki language code ({{w|List of ISO 639-1 codes|ISO 639}}), if the template is in another Wikipedia<br />can also be specified with <code>lang=</code> | ||
|3def = | |3def = | ||
|3stat = optional- | |3stat = optional- | ||
| Line 49: | Line 49: | ||
|4d = +/- to precede the template name with the namespace <code>Template:</code> | |4d = +/- to precede the template name with the namespace <code>Template:</code> | ||
* '''<code>+</code>''' (plus sign) to make < | * '''<code>+</code>''' (plus sign) to make <code>Template:</code> a part of the link, | ||
* '''<code>-</code>''' (minus sign) to precede < | * '''<code>-</code>''' (minus sign) to precede <code>Template:</code> as plain text. | ||
The +/- parameter can as well be specified with parameter 2 or 3;<br>(when ''both'' signs are specified, "+" has precedence). | The +/- parameter can as well be specified with parameter 2 or 3;<br />(when ''both'' signs are specified, "+" has precedence). | ||
|4def = | |4def = | ||
|4stat = optional- | |4stat = optional- | ||
| Line 88: | Line 88: | ||
|10 = i18n | |10 = i18n | ||
|10d = another language than < | |10d = another language than <code><nowiki>{{int:lang}}</nowiki></code> for namespace translation (when <code>case=i</code> or <code>case=n</code>) | ||
|10def = {{int:lang}} | |10def = {{int:lang}} | ||
|10stat = optional- | |10stat = optional- | ||
|11 = parm | |11 = parm | ||
|11d = to display templates parameters  (like {{T|Tlx}})<br> | |11d = to display templates parameters  (like {{T|Tlx}})<br /> | ||
Usage e.g. <code>parm=template name</code> or <code>parm=1=template name</code><br> | Usage e.g. <code>parm=template name</code> or <code>parm=1=template name</code><br /> | ||
or  <code><nowiki>parm=&#124;1=&#124;2=&#124;code=y</nowiki></code>" gives | or  <code><nowiki>parm=&#124;1=&#124;2=&#124;code=y</nowiki></code>" gives | ||
"<code><nowiki>|1=|2=|code=y</nowiki></code>". | "<code><nowiki>|1=|2=|code=y</nowiki></code>". | ||
:{{F|Font Awesome 5 solid long-arrow-alt-right.svg|Z|18}} For a better appearing and ''easier to format'' explanatory, use the meta template {{T1|Tle|< | :{{F|Font Awesome 5 solid long-arrow-alt-right.svg|Z|18}} For a better appearing and ''easier to format'' explanatory, use the meta template {{T1|Tle|<code><big>Tle</big></code>|i=6}}. | ||
|11stat = optional- | |11stat = optional- | ||
| Line 119: | Line 119: | ||
|mustbesubst = | |mustbesubst = | ||
|i18n-method = - | |i18n-method = - | ||
|i18n-desc = The template does not generate any localizable text;<br> | |i18n-desc = The template does not generate any localizable text;<br /> | ||
with + or - always the ''namespace'' in English: "{{ns:10}}" is displayed;<br> | with + or - always the ''namespace'' in English: "{{ns:10}}" is displayed;<br /> | ||
only in combination with < | only in combination with <code>case=i</code> or <code>case=n</code> the namespace can be translated using the {{T2|i18n/namespace|LangSwitch}} construct (according to <code>i18n</code>). | ||
}} | }} | ||
{{Commons:Link templates/T-doc-expansion}} <!-- subpage --> | {{Commons:Link templates/T-doc-expansion}} <!-- subpage --> | ||
Revision as of 15:42, 31 October 2022
T links to a Template. T creates a formatted link to a template and surrounds it with {{...}} making the brackets a part of the link.
Usage
{{T |1= }}
Template parameters
| Parameter | Description | Default | Status | |
|---|---|---|---|---|
1 | template name (any namespace is ignored) | T | optional | |
2 | display name (displayed as-it-is) | parameter 1 | optional | |
3lang | interwiki language code (ISO 639), if the template is in another Wikipedia can also be specified with lang= | empty | optional | |
4 | +/- to precede the template name with the namespace Template:
(when both signs are specified, "+" has precedence). | empty | optional | |
incli | i or incl is a one-digit formatting option:
| 2 | optional | |
code | any value, for a surrounding <code> tag (like {{Tl2}}).With code=tt also the surrounding brackets are in teletype style. | empty | optional | |
link | returns plain text instead of a link when set to link=no | empty | optional | |
case | for formatting of the namespace prefix:
| empty | optional | |
i18n | another language than {{int:lang}} for namespace translation (when case=i or case=n) | en | optional | |
parm | to display templates parameters (like {{Tlx}}) Usage e.g.
| empty | optional | |
full | expanded display: Template:{{Example}} (like {{Lts}}) request this expansion with either full=5 or 5=full. | empty | optional | |
Additional information
The template is intended to be used in the following namespaces: all namespaces
The template is intended to be used by the following user groups: all users
Localization
This template is not intended to be localized.
The template does not generate any localizable text;
with + or - always the namespace in English: "Template" is displayed;
only in combination with case=i or case=n the namespace can be translated using the {{LangSwitch}} construct (according to i18n).
{{Commons:Link templates/T-doc-expansion}}
{{Commons:Link templates/Template links}}