Template:Parameter: Difference between revisions

From The Mana World
Nelson6e65 (talk | contribs)
m rem: space
Nelson6e65 (talk | contribs)
fix:spaces on empty "Default" param value
Line 2: Line 2:
{{!}}- style="vertical-align:top;"
{{!}}- style="vertical-align:top;"
{{!}} style="text-align:right;" {{!}} <code>{{{Name|{{{1}}}}}}</code>:  
{{!}} style="text-align:right;" {{!}} <code>{{{Name|{{{1}}}}}}</code>:  
{{!}} <span style="color:{{#if:{{{Default|}}}|blue">Optional|red">Required}}</span>. {{{Description|{{{2|''No description available''}}} }}}
{{!}} <span style="color:{{#if:{{{Default|}}}|blue">Optional|red">Required}}</span>. {{{Description|{{{2|''No description available''}}}}}}{{#if:{{{Default|}}}|.
{{#if:{{{Default|}}}|''<span style="color:blue;">Default value</span>: <code>{{{Default|}}}</code>''}}</includeonly>
''<span style="color:blue;">Default value</span>: <code>{{{Default}}}</code>''}}</includeonly>
<noinclude>
<noinclude>{{:Template:{{PAGENAME}}/doc}}<!-- this is to include documentation in this page, without transcluding it in the page where template is used -->
{{:Template:{{PAGENAME}}/doc}}     <!-- this is to include documentation in this page, without transcluding it in the page where template is used -->
[[Category:General Template]]        <!-- this is to categorize the template. It will not be transcluded in the page where template is used -->
[[Category:General Template]]        <!-- this is to categorize the template. It will not be transcluded in the page where template is used -->
</noinclude>
</noinclude>

Revision as of 05:46, 19 October 2015

Template documentation [ Edit ]

Description

Includes a short template parameter documentation.

Use it as content of Template:Parameters container or value(s) for Params argument in Template:Documentation.

Usage

Copy the following code for each parameter and edit as needed, adding a new line after (but not more than one line break between each).

{{Parameter|Name |Description |Default="String default value"}}

Parameters

List of parameters used by this template:

1: Required. Name of parameter. Alias: Name.

Insert the name of parameter, without adding extra spaces or breaklines


2: Optional. Description of parameter. Alias: Description.

Insert a short summary describing the parameter in the first line; and, in the next line, how to fill its value. Default value: “''No description available''”


Default: Optional. Default value.

You can use "Empty" for empty/null default value or enclose value in double quotes (“, ”) for especific text, using nowiki taf if is needed. If not specified, the param will be marked as "Required" . Default value: Empty