Difference between revisions of "Template:Box"
Jump to navigation
Jump to search
(Added note about specific templates preference) |
(Visual improvements) |
||
Line 56: | Line 56: | ||
|highlight=#4C8ACE |
|highlight=#4C8ACE |
||
}} |
}} |
||
− | </noinclude><includeonly><div style= |
+ | </noinclude><includeonly><div style="background: {{{background|gainsboro}}}; display: flex; border: solid 1px black; min-height: 48px; margin: 5px 0;"> |
− | [[File:{{{icon|Gear.png}}} |
+ | <div style="padding: 8px 5px; background: linear-gradient(to right, {{{highlight|gray}}}, {{{background|gainsboro}}});">[[File:{{{icon|Gear.png}}}|48px]]</div><div style="padding: 2px 5px; flex-grow: 1;"><div style="font-size:1.15em; font-weight: bold; border-bottom: dotted 1px #000000;">{{{caption}}}</div>{{{text}}}</div></div></includeonly> |
Revision as of 13:31, 21 April 2022
Template:Box is a general-purpose template meant to display Wikipedia-style boxes with information such as warnings about the content of a page.
More specific box templates include:
- Template:TipBox, for displaying notices, tips and miscellaneous information;
- Template:WarningBox, for displaying warnings and important notes;
- Template:SafeBox, for displaying validating information (e.g. see Template:Applicable to TDE).
These more specific templates should be preferred when possible to directly using this template.
Usage
To use this template, use {{Box|caption=...|text=...|icon=...|background=...|highlight=...}}
on the target page.
caption
(optional) is the box caption;text
(required) is the box contents;icon
(optional) is the icon displayed by the text (default: File:Gear.png);background
(optional) is the background color (default: gainsboro);highlight
(optional) is the highlight color (default: gray).
Using this template on a page results in a box being placed.
Examples