Template:Message box: Difference between revisions

let's not do the whole pre thing, honey
actually, icon is better off on the text
Line 1: Line 1:
<div style="{{msgbox/style|{{{type|normal}}} | bgcol = {{{bgcol|#FFFFCC}}} | linecol = {{{linecol|#616161}}} }} {{{css|}}}">
<div style="{{msgbox/style|{{{type|normal}}} | bgcol = {{{bgcol|#FFFFCC}}} | linecol = {{{linecol|#616161}}} }} {{{css|}}}">
{{#if: {{{icon|}}} | {{CommentSprite| {{{icon}}} }} }}{{#if: {{{title|}}} | '''{{{title|}}}''' }}{{#if: {{{discuss|}}} | <sup>[[{{TALKPAGENAME}}|Discuss]]</sup> }}
{{#if: {{{title|}}} | '''{{{title|}}}''' }}{{#if: {{{discuss|}}} | <sup>[[{{TALKPAGENAME}}|Discuss]]</sup> }}
{{#if: {{{text|}}} |<br />{{{text}}} }}
{{#if: {{{icon|}}} | {{CommentSprite| {{{icon}}}&nbsp;}} }}{{#if: {{{text|}}} |<br />{{{text}}} }}
</div><noinclude>
</div><noinclude>
== Usage ==
== Usage ==
Line 20: Line 20:
| type = mini
| type = mini
| icon = 8
| icon = 8
| title = This is a mini message box with an information icon using [[Template:CommentSprite]]
| text = This is a mini message box with an information icon using [[Template:CommentSprite]]
}}
}}
</pre>
</pre>


Will result in:
Will result in:
{{msgbox| type = mini | icon = 8 | title = This is a mini message box with an information icon using [[Template:CommentSprite]]}}
{{msgbox| type = mini | icon = 8 | text = This is a mini message box with an information icon using [[Template:CommentSprite]]}}


=== Advanced usage ===
=== Advanced usage ===