Template:DisplayBox: Difference between revisions
Jump to navigation
Jump to search
Documentation
(oops) |
(replaced template:Switch with parser function #switch) |
||
(12 intermediate revisions by 2 users not shown) | |||
Line 1: | Line 1: | ||
< | <includeonly> | ||
<div style="margin: 0; margin-right: {{{marginR|30px}}}; margin-left: {{{marginL|30px}}}; margin-top: {{{marginT|0}}}; margin-bottom: {{{marginB|0}}}; border:{{{bdwidth|1}}}px solid {{{bdcolor|#3399ff}}}; padding: {{{padding|0.4em 1em 0.4em 1em}}}; background-color:{{#switch:{{{bgcolor|{{#ifeq:{{NAMESPACE}}|Template|g|grey}}}}}| | |||
grey=#dddddd| | |||
char=#bbbbbb| | |||
none=#ffffff| | |||
g=#ddffdd| | |||
r=#ffdddd| | |||
y=#eeeeb8| | |||
b=#ddddff| | |||
m=#e8d4ee| | |||
o=#ffeebb| | |||
w=#ffffff| | |||
gs0=#ffffff| | |||
gs1=#eeeeee| | |||
gs2=#dddddd| | |||
gs3=#cccccc| | |||
gs4=#bbbbbb| | |||
gs5=#aaaaaa| | |||
#default={{{bgcolor}}}}};">{{#if:{{{title|}}}|<center><big><b>{{{title}}}</b></big></center>}} | |||
{{{text|{{{1|'''''Error:''' Text is missing!''}}}}}} | |||
</div></includeonly><noinclude>{{Doc| | |||
Centered box with fixed margins for displaying material | |||
'''Syntax:''' | |||
:{{tl|DisplayBox|<displayed text>}} | |||
'''Optional parameters:''' | |||
<pre> | |||
|marginL=<margin-left, default=30px> | |marginL=<margin-left, default=30px> | ||
|marginR=<margin-right, default=30px> | |marginR=<margin-right, default=30px> | ||
|marginB=<margin-bottom, default=0> | |||
|marginT=<margin-top, default=0> | |||
|bdwidth=<borderwidth in pixels, default=1> | |bdwidth=<borderwidth in pixels, default=1> | ||
|bdcolor=<bordercolor, default=#3399ff> | |bdcolor=<bordercolor, default=#3399ff> | ||
|padding=<padding, default=1em | |padding=<padding, default=0.4em 1em 0.4em 1em (top, right, bottom, left)> | ||
|bgcolor=<backgroundcolor, default=# | |bgcolor=<backgroundcolor, default=#d8d8d8;> other options include: | ||
grey=#dddddd | |||
char=#bbbbbb (charcoal) | |||
g =#ddffdd (green) | |||
r =#ffdddd (red) | |||
y =#ffffbb (yellow) | |||
b =#ddddff (blue) | |||
m =#ddccff (magenta) | |||
o =#ffeebb (orange) | |||
none=#ffffff (white) | |||
w =#ffffff (white) | |||
|title=<optional; a centered title displayed in bold> | |||
|text=<text to display, defaults to parameter 1 when no optional parameters are used> | |||
</pre> | |||
}} | |||
| | |||
{{prot-temp}} | {{prot-temp}} | ||
[[Category: | [[Category:Message box templates]] | ||
</noinclude> | </noinclude> |
Latest revision as of 16:45, 16 June 2017
Centered box with fixed margins for displaying material
Syntax:
- {{DisplayBox|<displayed text>}}
Optional parameters:
|marginL=<margin-left, default=30px> |marginR=<margin-right, default=30px> |marginB=<margin-bottom, default=0> |marginT=<margin-top, default=0> |bdwidth=<borderwidth in pixels, default=1> |bdcolor=<bordercolor, default=#3399ff> |padding=<padding, default=0.4em 1em 0.4em 1em (top, right, bottom, left)> |bgcolor=<backgroundcolor, default=#d8d8d8;> other options include: grey=#dddddd char=#bbbbbb (charcoal) g =#ddffdd (green) r =#ffdddd (red) y =#ffffbb (yellow) b =#ddddff (blue) m =#ddccff (magenta) o =#ffeebb (orange) none=#ffffff (white) w =#ffffff (white) |title=<optional; a centered title displayed in bold> |text=<text to display, defaults to parameter 1 when no optional parameters are used>
This high-risk template has been protected from editing to prevent vandalism. Please use the talk page to ask an administrator about making an edit to change this template. |