Template
Interface template

Header

From Dogcraft Wiki

(Added tempalte data)
m (Added categories: Interface templates)
 
(4 intermediate revisions by the same user not shown)
Line 1: Line 1:
<h3 style="padding:0.3em 0.4em; {{{margin|margin:10px 0 10px 0;}}} border:1px solid {{{2|{{main-color}}}}}; background:{{{2|{{main-color}}}}}; color:white; font-size:140%; text-align:center;">'''{{{1}}}'''</h3><noinclude>[[Category:Templates]]</noinclude>__NOTOC__
<h3 style="padding:0.3em 0.4em; {{{margin|margin:10px 0 10px 0;}}} border:1px solid {{{2|{{main-color}}}}}; background:{{{2|{{main-color}}}}}; color:white; font-size:140%; text-align:center; display:flex; flex-direction:column; justify-content:center; {{{style|}}}">'''{{{1}}}'''</h3><noinclude>[[Category:Documented templates]]</noinclude>__NOTOC__
<noinclude>
<noinclude>
<templatedata>
<templatedata>
Line 33: Line 33:
"type": "string",
"type": "string",
"default": "margin:10px 0 10px 0;"
"default": "margin:10px 0 10px 0;"
},
"style": {
"label": "Further styles",
"description": "Optional parameter for setting further CSS.",
"example": "width: 200px; margin:0.2em;",
"type": "string"
}
}
},
},
"format": "inline",
"format": "block",
"paramOrder": [
"paramOrder": [
"1",
"1",
"2",
"2",
"margin"
"margin",
]
"style"
],
"description": "Used to generate a box header with a colored background"
}
}
</templatedata>
</templatedata>{{Interface template}}
</noinclude>
</noinclude>

Latest revision as of 10:58, 4 December 2023

{{{1}}}

Used to generate a box header with a colored background

Template parameters

This template prefers block formatting of parameters.

ParameterDescriptionTypeStatus
Header text1 content text

Used to set the header's text

Example
Map of the area
Stringrequired
Background color2 color

Used to set color of the header background.

Default
{{main-color}}
Example
red, #f1f1f1, {{second-color}}
Stringoptional
Marginmargin inline-css

Used to set custom margins.

Default
margin:10px 0 10px 0;
Stringoptional
Further stylesstyle

Optional parameter for setting further CSS.

Example
width: 200px; margin:0.2em;
Stringoptional