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

Матеріал з Аероскан Сервіс
Перейти до: навігація, пошук
м (fix)
м
Рядок 1: Рядок 1:
<includeonly>
+
<includeonly><table class="metadata plainlinks" style="{{{style|width:90%; margin:0px auto; border-collapse:collapse; background:#f8fcff; border: 1px solid #aaa;}}} border-left: 10px solid {{#switch:{{{type|}}}
{| class="metadata plainlinks" style="{{{style|width:90%; margin:0px auto; background:#f8fcff; border:1px solid #aaa;}}} border-left:10px solid {{#switch:{{{type|}}}
+
 
   | warning  = #b22222
 
   | warning  = #b22222
 
   | serious  = #b22222
 
   | serious  = #b22222
Рядок 11: Рядок 10:
 
   | idea    = yellow
 
   | idea    = yellow
 
   | query    = #ffb734
 
   | query    = #ffb734
   |#default = #1e90ff
+
   | #default = #1e90ff
}};"
+
}};">
|-
+
<tr>{{#ifeq:{{{image}}}|none
{{#ifeq:{{{image|yes}}}|none
+
  | <!--no image cell-->
|<!-- no image cell -->
+
  | <td style="width: 52px; padding: 2px 0px 2px 0.5em; text-align: center;"> {{#switch:{{{type|}}}
|{{!}} style="width:52px; padding:2px 0px 2px 0.5em; text-align:center;" {{!}} {{#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]]
+
    | content  = [[Image:Book important.svg|40x40px]]
| content  = [[Image:Book important.svg|40x40px]]
+
    | style    = [[Image:Applications-office.svg|40x40px]]
| style    = [[Image:Applications-office.svg|40x40px]]
+
    | merge    = [[Image:Merge-split-transwiki default.svg|40x40px]]
| merge    = [[Image:Merge-split-transwiki default.svg|40x40px]]
+
    | move    = [[Image:Merge-split-transwiki default.svg|40x40px]]
| move    = [[Image:Merge-split-transwiki default.svg|40x40px]]
+
    | notice  = [[Image:Book notice.svg|40x40px]]
| notice  = [[Image:Book notice.svg|40x40px]]
+
    | growth  = [[Image:Nuvola apps bookcase.svg|40x40px]]
| growth  = [[Image:Nuvola apps bookcase.svg|40x40px]]
+
    | idea    = [[Image:Ktip.svg|40x40px]]
| idea    = [[Image:Ktip.svg|40x40px]]
+
    | query    = [[Image:Torchlight help yellow.png|40x40px]]
| query    = [[Image:Torchlight help yellow.png|40x40px]]
+
    | blank    = <!-- empty image cell -->
| blank    = <!-- empty image cell -->
+
    | #default = {{{image|[[Image:Stop hand nuvola.svg|40x40px]]}}}
|#default = {{{image|[[Image:Stop hand nuvola.svg|40x40px]]}}}}}}}
+
  }}</td>
| style="color:black;" | {{{1|{{{msg|{{{text|''Enter Text''}}}}}}}}}
+
}}<td style="color: #000000;">
{{#if:{{{imageright|}}}|{{!}}{{{imageright}}}}}
+
{{{1|{{{msg|{{{text|''Enter Text''}}}}}}}}}
|}
+
</td style="padding: 0.25em 0.5em;">
</includeonly><noinclude>
+
{{#if:{{{imageright|}}}|
 +
  <td class="ambox-imageright"> {{{imageright}}} </td>
 +
}}
 +
</tr>
 +
</table></includeonly><noinclude>
 
== Usage ==
 
== Usage ==
  

Версія за 01:35, 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=blank", or "image=<IMAGE>", where <IMAGE> is a replacement image link. Examples of how this template is used are located on Wikibooks:Template messages.