Controls – Template
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Fix parameters) |
Lou Montana (talk | contribs) m (Add error auto-category) |
||
Line 1: | Line 1: | ||
<includeonly>{{#if:{{{1|}}}|<span class="keyboard">{{{1}}}</span>{{#if:{{{2|}}}| + <span class="keyboard">{{{2}}}</span>{{#if:{{{3|}}}| + <span class="keyboard">{{{3}}}</span>{{#if:{{{4|}}}| + <span class="keyboard">{{{4}}}</span>|}}|}}|}}|-no keys defined-}}</includeonly><noinclude>{{Doc/Template | <includeonly>{{#if:{{{1|}}}|<span class="keyboard">{{{1}}}</span>{{#if:{{{2|}}}| + <span class="keyboard">{{{2}}}</span>{{#if:{{{3|}}}| + <span class="keyboard">{{{3}}}</span>{{#if:{{{4|}}}| + <span class="keyboard">{{{4}}}</span>|}}|}}|}}|-no keys defined-{{TemplateCase||[[Category:KeyboardShortcut template usage error]]}}}}</includeonly><noinclude>{{Doc/Template | ||
|descr= Shows a key-styled keyboard shortcut. | |descr= Shows a key-styled keyboard shortcut. It also adds the page to the [[:Category:KeyboardShortcut template usage error|KeyboardShortcut template usage error]] category on usage error. | ||
|param1= key1 | |param1= key1 | ||
|descr1= first key | |descr1= first key |
Revision as of 13:43, 16 November 2021
Shows a key-styled keyboard shortcut. It also adds the page to the KeyboardShortcut template usage error category on usage error.
This template is used on these pages.
Usage
{{Controls|key1|key2|key3|key4}}
- key1: first key
- key2: (Optional) second key
- key3: (Optional) third key
- key4: (Optional) fourth key
Code | Result |
---|---|
{{KeyboardShortcut}} | -no keys defined- |
{{KeyboardShortcut|Ctrl}} | Ctrl |
{{KeyboardShortcut|Ctrl|Shift|T}} | Ctrl + Shift + T |
{{KeyboardShortcut|Ctrl|Alt|Shift|T}} | Ctrl + Alt + Shift + T |
{{KeyboardShortcut|Ctrl|Alt|Shift|T|U}} | Ctrl + Alt + Shift + T |