Template:Code/doc: Difference between revisions
Jump to navigation
Jump to search
1416006136 (talk | contribs) No edit summary |
mNo edit summary |
||
Line 45: | Line 45: | ||
{{code|<nowiki>{{code|select=1|background=rgb(230,230,230)|color=black|Go to '''[[Main Page|Main Page]]'''}}</nowiki>}} {{code|<nowiki>{{code|background=rgb(40,60,100)|Go to {{hla|4}}}}</nowiki>}} | {{code|<nowiki>{{code|select=1|background=rgb(230,230,230)|color=black|Go to '''[[Main Page|Main Page]]'''}}</nowiki>}} {{code|<nowiki>{{code|background=rgb(40,60,100)|Go to {{hla|4}}}}</nowiki>}} | ||
{{Doc/PreviewBlock|{{code|select=1|background=rgb(230,230,230)|color=black|Go to '''[[Main Page|Main Page]]'''}} {{code|background=rgb(40,60,100)|Go to {{hla|4}}}}}} | {{Doc/PreviewBlock|{{code|select=1|background=rgb(230,230,230)|color=black|Go to '''[[Main Page|Main Page]]'''}} {{code|background=rgb(40,60,100)|Go to {{hla|4}}}}}} | ||
== Deprecated Parameters == | |||
These parameters will be removed in the future, but are currently required for pages that still use them to function correctly. | |||
{| class="standard-table" | |||
! colspan="2" | Styles | |||
|- | |||
| {{param|oneclick}} | |||
| one-click selection | |||
|- | |||
| {{param|desaturated-oneclick}} | |||
| less saturated version with one-click selection | |||
|- | |||
| {{param|outline}} | |||
| less saturated version with outline | |||
|- | |||
| {{param|outline-oneclick}} | |||
| less saturated version with outline and one-click selection | |||
|} | |||
<includeonly>{{sandbox other|| | <includeonly>{{sandbox other|| | ||
[[Category:Markdown]] | [[Category:Markdown]] | ||
}}</includeonly> | }}</includeonly> |
Revision as of 08:30, 22 January 2023

This is a documentation subpage for Template:Code.
Don't forget to purge the contents of the base page upon creating or editing this subpage.
Don't forget to purge the contents of the base page upon creating or editing this subpage.
This template will allow you to format text as a one-line code. The default style is based on Markdown.
Parameters
Styles | |
---|---|
{{{desaturated}}} | less saturated version |
{{{outlined}}} | less saturated version with outline |
{{{clear}}} | no style |
Modifiers | |
---|---|
{{{select}}} | Sets the values for the user-select parameter. Values:
|
{{{color}}} | allows you to change the color of the text if the default style is enabled |
{{{background}}} | allows you to change the background color if the default style is enabled |
Examples
{{code|Go to [[Main Page|Main Page]]}} {{code|Go to {{hla|4}}}}
Go to Main Page Go to
Half-Life: Alyx

{{code|desaturated|Go to [[Main Page|Main Page]]}} {{code|desaturated|Go to {{hla|4}}}}
desaturated desaturated
{{code|outlined|Go to [[Main Page|Main Page]]}} {{code|outlined|Go to {{hla|4}}}}
outlined outlined
{{code|select=1|background=rgb(230,230,230)|color=black|Go to '''[[Main Page|Main Page]]'''}} {{code|background=rgb(40,60,100)|Go to {{hla|4}}}}
Go to Main Page Go to
Half-Life: Alyx

Deprecated Parameters
These parameters will be removed in the future, but are currently required for pages that still use them to function correctly.
Styles | |
---|---|
{{{oneclick}}} | one-click selection |
{{{desaturated-oneclick}}} | less saturated version with one-click selection |
{{{outline}}} | less saturated version with outline |
{{{outline-oneclick}}} | less saturated version with outline and one-click selection |