Template:Code: Difference between revisions
Jump to navigation
Jump to search
m (Added working backwards compatibility.) |
mNo edit summary |
||
Line 1: | Line 1: | ||
{{DISPLAYTITLE:Template: One-Line Code}} | {{DISPLAYTITLE:Template: One-Line Code}} | ||
<onlyinclude><includeonly>{{#switch:{{{ | <onlyinclude><includeonly><!-- | ||
|#default=<code style="background: {{{ | -->{{#switch:{{{style}}} | ||
| | |#default=<code style="background: {{{bg|rgb(0,0,0,.35)}}}; border-radius: 4px; color: {{{color|currentcolor}}}; padding: 2px 3px; user-select:{{#switch:{{{select}}}|#default=text|1=all|2=none}};">{{{1|}}}</code> | ||
| | |1=<code style="background-color: rgba(0,0,0,.16); border: 1px solid rgba(255,255,255,.1); border-radius: 4px; padding: 1px 3px; user-select:{{#switch:{{{select}}}|#default=text|1=all|2=none}};">{{{1|}}}</code> | ||
| | |2=<code style="background-color: rgb(0,0,0,.16); border-radius: 4px; padding: 2px 3px; user-select:{{#switch:{{{select}}}|#default=text|1=all|2=none}};">{{{1|}}}</code> | ||
|3=<kbd style="color:{{{color|currentcolor}}}; user-select:{{#switch:{{{select}}}|#default=text|1=all|2=none}};">{{{1|}}}</kbd> | |||
}}</includeonly></onlyinclude>{{doc}} | }}</includeonly></onlyinclude>{{doc}} |
Revision as of 13:44, 23 January 2023
The above documentation is transcluded from Template:Code/doc. (Edit | Page history)
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages.
Editors can experiment in this template's sandbox (create | mirror) and testcases (create) pages.