Template:Tlg/doc

From HandWiki Stage
Revision as of 22:47, 9 July 2021 by WikiHarold (talk | contribs) (Created page with "{{Documentation subpage}} <!-- PLEASE ADD CATEGORIES WHERE INDICATED AT THE BOTTOM OF THIS PAGE --> {{#ifeq:{{FULLPAGENAME}}|Template:Template link expanded|{{used in system}}...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Template:Tsh

This template, often abbreviated as Template:Tlf, is used to provide stylized formatting to template displays without actually using the template itself.

Parameters

With the exception of alttext, the named parameters are toggles that are either omitted (default in most cases) or activated (by being assigned a value such as "on", "yes", "true", "include", etc.). They may be included in any order (see Examples below). Certain templates have the parameter "on" by default; see the main table for all alternate options.

Parameter Action Use with
Template:T
Default active
brace Include braces as part of the template link Template:Tlg Template:Tl/Template:Tl
braceinside Include innermost braces as part of the template link Template:Tlg
bold Renders the template link/name in bold Template:Tlg Template:Tl, Template:Tl
code Display output using HTML <code>...</code> tags (monospaced font) Template:Tlg Template:Tl, Template:Tl, etc.
italic Display any parameters accompanying the template link/name in italics Template:Tlg Template:Tl
kbd Display output using HTML <kbd>...</kbd> tags (monospaced font) Template:Tlg
nolink Don't render the template name as a link Template:Tlg Template:Tl, Template:T, Template:T
nowrap Prevent the insertion of line breaks (word wrap) in the output Template:Tlg
nowrapname Prevent word wrapping in the output of template name/link (parameters will wrap if needed) Template:Tlg
plaincode Uses <code style="border:none; background:transparent;">...</code> Template:Tlg Template:Tl
subst Include a subst: prefix before the template link/name Template:Tlg Template:Tl, Template:Tl, etc
|alttext=[text] Use [text] as the label for the template link Template:Tlg Template:Tl

Unnamed (Positional)

This template can take any number of unnamed parameters as parameters accompanying the template link (or name); see Examples below.

Examples

Note
On the source sister projects, en.wikipedia and Meta, X0, X1, X2, …, X9 are sandbox templates for experimentation on involved templates that need be in template space. An auto-cleansing software facility exists that might be used to duplicate the facility on other Sister projects.
Code Output Remarks
Template:Tlx Template:Tlg Banner template does not exist. Be aware with linking to non-existing templates, although desired.
Template:Tlx Template:Tlg ok template does exist
Template:Tlx Template:Tlg Unlimited parameters as one <nowiki>...</nowiki> string
Template:Tlx Template:Tlg
Template:Tlx Template:Tlg template names are case-sensitive
Template:Tlx Template:Tlg first letter is case-insensitive though
Template:Tlx Template:Tlg Using Template:Tl before and after {{{1}}} parameter.
Template:Tlx Template:Tlg
Template:Tlx Template:Tlg <code> style
Template:Tlx Template:Tlg plaincode style
Template:Tlx Template:Tlg <kbd> style
Template:Tlx Template:Tlg bold link/name
Template:Tlx Template:Tlg parameter/s in italics
Template:Tlx Template:Tlg
Template:Tlx Template:Tlg
Template:Tlx Template:Tlg all braces in link
Template:Tlx Template:Tlg inside braces in link
Template:Tlx Template:Tlg
Template:Tlx Template:Tlg No reason you can't combine multiple parameter settings
Template:Tlx Template:Tlg
Template:Tlx Template:Tlg
Template:Tlx Template:Tlg Can combine named and anonymous parameters …
Template:Tlx Template:Tlg … in any order …
Template:Tlx Template:Tlg … even intermixed …
Template:Tlx Template:Tlg … with many different configurations.
Template:Tlx Template:Tlg
Template:Tlx tlg with no arguments, the current page name is substituted
Template:Tlx Template:Tlg = won't work
Template:Tlx Template:Tlg
&#61; is okay
Template:Tlx Template:Tlg
{{=}} is okay (see template equal sign)
Template:Tlx Template:Tlg
sticky nowiki is okay
Template:Tlx Template:Tlg empty parameters work too, even at the end
Template:Tlx Template:Tlg
right to left okay
Wrapping of long names (default)
Code Output
Template:Tlx Template:Tlg
Wrapping of long names (nowrap=on)
Code Output
Template:Tlx Template:Tlg
Wrapping of long names (nowrapname=on)
Code Output
Template:Tlx Template:Tlg

See also

Template:Tlg