Difference between revisions of "Template:Imbox"

From Drawn to Life Wiki
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
<div style="width: 97%; background: white; border: 1px solid #ccc; border-radius: 2px; box-shadow: rgba(0, 0, 0, 0.1) 0 0px 4px; padding: 7px; margin: 10px; display: flex; flex-flow: row nowrap;">   
+
<div class="Imbox" style="width: 97%; background: white; border: 1px solid #ccc; border-radius: 2px; box-shadow: rgba(0, 0, 0, 0.1) 0 0px 4px; padding: 7px; margin: 10px; display: flex; flex-flow: row nowrap;">   
<div style="margin-right: 15px;">{{#if:{{{Icon|}}}|{{#switch: {{{Icon}}}|Alert=[[File:Ambox warning.svg|60px]]|Info=[[File:Information icon.svg|60px]]}}|[[File:Information icon.svg|60px]]}}</div> <div style="padding-top: 5px;">'''<span>{{{Title|A title has not been supplied.}}}'''</span><br><span>''{{{Content|Content has not been supplied.}}}''</span></div>
+
<div style="margin-right: 15px;">{{#if:{{{Icon|}}}|{{#switch: {{{Icon}}}|Alert=[[File:Ambox warning.svg|60px]]|Info=[[File:Information icon.svg|60px]]|Lock=[[File:Tool_lock.png|60px]]|Unlock=[[File:Tool_unlock.png|60px]]|Pencil=[[File:Tool_pencil.png|60px]]|Pencil2=[[File:Tool_pencil_white.png|60px]]}}|[[File:Information icon.svg|60px]]}}</div> <div style="padding-top: 5px;">'''<span>{{{Title|A title has not been supplied.}}}'''</span><br><span>''{{{Content|Content has not been supplied.}}}''</span></div>
 
</div>
 
</div>
 
<noinclude>
 
<noinclude>
Line 8: Line 8:
 
<code><nowiki>
 
<code><nowiki>
 
{{Imbox
 
{{Imbox
 
+
   |Icon    = [Alert/Info/Lock/Unlock/Pencil/Pencil2]
   |Icon    = [Alert/Info]
 
 
 
 
   |Title  = The message title text.
 
   |Title  = The message title text.
 
 
 
   |Content = The message body text.
 
   |Content = The message body text.
 
 
 
}}
 
}}
 
</nowiki></code>
 
</nowiki></code>
Line 26: Line 22:
 
{{Imbox
 
{{Imbox
 
   |Icon    = Alert
 
   |Icon    = Alert
 +
  |Title  = The message title text.
 +
  |Content = The message body text.
 +
}}
 +
{{Imbox
 +
  |Icon    = Lock
 +
  |Title  = The message title text.
 +
  |Content = The message body text.
 +
}}
 +
{{Imbox
 +
  |Icon    = Unlock
 +
  |Title  = The message title text.
 +
  |Content = The message body text.
 +
}}
 +
{{Imbox
 +
  |Icon    = Pencil
 +
  |Title  = The message title text.
 +
  |Content = The message body text.
 +
}}
 +
{{Imbox
 +
  |Icon    = Pencil2
 
   |Title  = The message title text.
 
   |Title  = The message title text.
 
   |Content = The message body text.
 
   |Content = The message body text.
Line 31: Line 47:
  
 
(Depending on the icon chosen.)
 
(Depending on the icon chosen.)
</noinclude>
+
[[Category:Templates]]</noinclude>

Latest revision as of 15:36, 17 June 2022

Information icon.svg
A title has not been supplied.
Content has not been supplied.

This is the Image Box template and is used to construct simple informational boxes for content pages.

Usage: {{Imbox |Icon = [Alert/Info/Lock/Unlock/Pencil/Pencil2] |Title = The message title text. |Content = The message body text. }}

Would produce:

Information icon.svg
The message title text.
The message body text.
Ambox warning.svg
The message title text.
The message body text.
Tool lock.png
The message title text.
The message body text.
Tool unlock.png
The message title text.
The message body text.
Tool pencil.png
The message title text.
The message body text.
Tool pencil white.png
The message title text.
The message body text.


(Depending on the icon chosen.)