Відмінності між версіями «Шаблон:Mbox»

Матеріал з Аероскан Сервіс
Перейти до: навігація, пошук
(allow image to continue to work when type is also supplied)
м (fix)
Рядок 14: Рядок 14:
 
<tr>{{#ifeq:{{{image|yes}}}|none
 
<tr>{{#ifeq:{{{image|yes}}}|none
 
  |<!-- no image cell -->
 
  |<!-- no image cell -->
  |<td style="width:52px; padding:2px 0px 2px 0.5em; text-align:center;">{{{image|{{#switch:{{{type|}}}
+
  |<td style="width:52px; padding:2px 0px 2px 0.5em; text-align:center;">
 +
{{#if:{{{image|}}}|[[Image:{{{image}}}|40x40]]|{{#switch:{{{type|}}}
 
  | warning  = [[Image:Stop hand nuvola.svg|40x40px]]
 
  | warning  = [[Image:Stop hand nuvola.svg|40x40px]]
 
  | serious  = [[Image:Stop hand nuvola.svg|40x40px]]
 
  | serious  = [[Image:Stop hand nuvola.svg|40x40px]]
Рядок 26: Рядок 27:
 
  | query    = [[Image:Torchlight help yellow.png|40x40px]]
 
  | query    = [[Image:Torchlight help yellow.png|40x40px]]
 
  | blank    = <!-- empty image cell -->
 
  | blank    = <!-- empty image cell -->
  |#default  = [[Image:Stop hand nuvola.svg|40x40px]]}}}}}</td>}}
+
  |#default  = [[Image:Stop hand nuvola.svg|40x40px]]}}}}</td>}}
 
<td style="color:black;">{{{1|{{{msg|{{{text|''Enter Text''}}}}}}}}}</td>
 
<td style="color:black;">{{{1|{{{msg|{{{text|''Enter Text''}}}}}}}}}</td>
 
{{#if:{{{imageright|}}}|<td>{{{imageright}}}</td>}}
 
{{#if:{{{imageright|}}}|<td>{{{imageright}}}</td>}}

Версія за 01:53, 26 вересня 2007

Usage

This template is used to create other templates with a consistent visual style. Messages will be color coded to demonstrate their type and severity. The types of message are described as:

{{mbox|type=<TYPE>|text=<TEXT>}}

Where <TYPE> can be one of the following:

This message box is using an invalid "type=warning" parameter and needs fixing.
This message box is using an invalid "type=merge" parameter and needs fixing.
This message box is using an invalid "type=growth" parameter and needs fixing.
This message box is using an invalid "type=idea" parameter and needs fixing.
This message box is using an invalid "type=query" parameter and needs fixing.

the default images can be suppressed by specifying "image=none", or "image=<IMAGE>", where <IMAGE> is a replacement image link. Examples of how this template is used are located on Wikibooks:Template messages.