Template:Set2: Difference between revisions
Appearance
| [unchecked revision] | [unchecked revision] |
Content deleted Content added
Caleb Cooper (talk | contribs) m 1 revision imported |
Caleb Cooper (talk | contribs) No edit summary |
||
| Line 1: | Line 1: | ||
| ⚫ | <div class="mw-collapsible {{#if:{{{open|}}}||mw-collapsed}} {{#if:{{{color|}}}|{{{color}}}}} force-toggle-float-left" data-collapsetext="-" data-expandtext="+" style="overflow:hidden; display: inline;"><span style="color: red; display: inline;">'''{{#if:{{{2|}}}|{{#ifeq:{{#len:{{{2}}}}}|0|{{{1}}}|{{{alt-text|{{{2|{{{1}}}}}}}}}}}|{{{alt-text|{{{2|{{{1}}}}}}}}}}}'''</span><div class="mw-collapsible-content shell" style="align: left;">{{#if:{{{2|}}}|{{#ifeq:{{#len:{{{2}}}}}|0|{{{2}}}|{{{example|{{{3|<pre>Need an Example</pre>}}}}}}}}}}</div></div>{{#if:{{{inline|}}}||<br><br style="clear:both;">}}<noinclude> |
||
{{#switch: {{#lst:Cli:{{{1}}}|warning}}| Very Dangerous = <div style="float:left" title="IMPORTANT:This set command can cause Data Unavailable or Data Loss if used incorrectly, CSE only!">[[File:Skull_sm_40.png]]</div>| Not Dangerous = <div style="float:left" title="Careful Now!">[[File:One_Pixel.png]]</div>| #default = <div style="float:left" title="IMPORTANT:No set command should ever be run without Senior Engineer verification!">[[File:Warn_sm_20.png]]</div>}} |
|||
{{#ifeq: {{#sub:{{{1}}}|0|3}} | {{#sub:{{{2}}}|0|3}} |
|||
<templatedata> |
|||
| |
|||
{ |
|||
<div class="mw-collapsible mw-collapsed force-toggle-float-left" data-collapsetext="-" data-expandtext="+" style="display: inline;">[[Cli:{{{1}}}|<span style="color: red; display: inline;" title="{{#lst:Cli:{{{1}}}|description}} {{#if:{{#lst:Cli:{{{1}}}|version}}|{{#ifeq:{{#lst:Cli:{{{1}}}|version}}|07.0x.0y||(ver. {{#lst:Cli:{{{1}}}|version}} )}}|}}">{{#if: {{{2|}}} |'''{{{2}}}'''|'''{{{1}}}'''}}</span>]]<div class="mw-collapsible-content shell noprint" style="align: left;">{{#if: {{{3|}}}|{{{3}}}|{{#lst:Cli:{{{1}}}|{{{sect|example}}}}} }}</div></div> |
|||
"params": { |
|||
| |
|||
"1": { |
|||
| ⚫ | <div class="mw-collapsible mw-collapsed force-toggle-float-left" data-collapsetext="-" data-expandtext="+" style="display: inline;"> |
||
"label": "Command Name", |
|||
"description": "Command Name, will like match page name describing this command", |
|||
"example": "volume show", |
|||
"type": "string", |
|||
"required": true |
|||
}, |
|||
"2": { |
|||
"label": "Alternative Command Description", |
|||
"description": "Either Alternate Description of Command or an Example", |
|||
"example": "volume show where status = offline", |
|||
"type": "string" |
|||
}, |
|||
"3": { |
|||
"label": "Sample output", |
|||
"description": "An example output of runing this command", |
|||
"example": "<pre>volume show where status = offline</pre>", |
|||
"type": "string" |
|||
}, |
|||
"color": { |
|||
"label": "Pre Color", |
|||
"description": "Color of Pre-formatted Example", |
|||
"example": "black-green, blue-white, black-white, net, esx", |
|||
"type": "string" |
|||
}, |
|||
"Section": { |
|||
"label": "Name of page section", |
|||
"description": "Name of page section where pre-formatted example is found", |
|||
"example": "example, example2", |
|||
"type": "string" |
|||
}, |
|||
"open": { |
|||
"label": "Open", |
|||
"description": "Shows pre-formatted example as open by default", |
|||
"example": "1", |
|||
"type": "boolean" |
|||
}, |
|||
"inline": { |
|||
"label": "Inline", |
|||
"description": "Removes all new lines / carraige returns", |
|||
"example": "1", |
|||
"type": "boolean" |
|||
}, |
|||
"example": { |
|||
"label": "Sample output", |
|||
"description": "An example output of runing this command", |
|||
"example": "<pre>volume show where status = offline</pre>", |
|||
"type": "string" |
|||
}, |
|||
"alt-text": { |
|||
"label": "Alternative Command Description", |
|||
"description": "Either Alternate Description of Command or an Example", |
|||
"example": "volume show where status = offline", |
|||
"type": "string" |
|||
} |
|||
}, |
|||
"description": "Show a Command with a collapsed div containing an example", |
|||
"format": "inline" |
|||
} |
|||
</templatedata>[[Category:AutoDumpContentFromCommons]]</noinclude> |
|||
Revision as of 18:42, 30 March 2020
Show a Command with a collapsed div containing an example
| Parameter | Description | Type | Status | |
|---|---|---|---|---|
| Command Name | 1 | Command Name, will like match page name describing this command
| String | required |
| Alternative Command Description | 2 | Either Alternate Description of Command or an Example
| String | optional |
| Sample output | 3 | An example output of runing this command
| String | optional |
| Pre Color | color | Color of Pre-formatted Example
| String | optional |
| Name of page section | Section | Name of page section where pre-formatted example is found
| String | optional |
| Open | open | Shows pre-formatted example as open by default
| Boolean | optional |
| Inline | inline | Removes all new lines / carraige returns
| Boolean | optional |
| Sample output | example | An example output of runing this command
| String | optional |
| Alternative Command Description | alt-text | Either Alternate Description of Command or an Example
| String | optional |