Template:Highlight: Difference between revisions

From Leo's Notes
This page was last edited on 10 January 2021, at 04:07.
mNo edit summary
m Changed deprecated enclose=div to inline
Line 5: Line 5:
|style="{{#if:{{{style|}}}| {{{style}}} |}}"
|style="{{#if:{{{style|}}}| {{{style}}} |}}"
|highlight="{{{highlight|{{{3|}}}}}}"
|highlight="{{{highlight|{{{3|}}}}}}"
|enclose="div"
|inline
|{{#if: {{{line|}}}|line=line}}
|{{#if: {{{line|}}}|line=line}}
}}<noinclude>
}}<noinclude>

Revision as of 04:07, 10 January 2021

No code provided.

Syntax highlights a chunk of code or text

Template parameters[Edit template data]

This template prefers block formatting of parameters.

ParameterDescriptionTypeStatus
codecode 1

code to highlight

Auto value
Stringrequired
langlang 2

language of the code to highlight

Default
terminal
Example
terminal
Auto value
terminal
Stringsuggested
lineline

line to highlight

Numberoptional
stylestyle

custom CSS style

Auto value
Stringoptional
highlighthighlight 3

no description

Auto value
Unknownoptional