Template

Difference between revisions of "Ambox/doc"

From Joomla! Documentation

< Template:Ambox
(New page: {{tlp|ambox}} is the base tempate used by several ''"alert message boxes"'' which can be placed at the top of an article. It generates a two column table with an optional "message icon". ...)
 
m (combined image and type tables)
Line 9: Line 9:
 
: the message text to display
 
: the message text to display
 
Optional:
 
Optional:
;style (empty)
 
: value of the HTML style attribute applied to the table element
 
 
;type (notice)
 
;type (notice)
 
: controls the class attribute used
 
: controls the class attribute used
Line 17: Line 15:
 
;imageright (none)
 
;imageright (none)
 
: an supplemental image from the Image: namespace, shown in a third column
 
: an supplemental image from the Image: namespace, shown in a third column
 +
;style (empty)
 +
: CSS properties for the HTML <tt>style</tt> attribute applied to the &lt;table&gt; element. Please try to avoid using colors and fancy font settings in inline styles as this may conflict with a skin's color schema and user settings -- think accessibility!
  
=== type ===
+
=== type and image ===
{| class="wikitable"
+
:'''Internal note:''' Please update the list of image names if files become available.
!Value    !!CSS class
+
{| class="wikitable parameters"
|-
+
!Value    !! CSS class !! Image name
|serious  ||ambox-serious
 
|-
 
|content  ||ambox-content
 
|-
 
|style    ||ambox-style
 
|-
 
|merge    ||ambox-merge
 
 
|-
 
|-
|notice  ||ambox-notice
+
|serious  ||ambox-serious ||[[Image:Stop_hand_nuvola.svg.png|50|Stop icon]]
|-
 
|growth  ||ambox-growth
 
|-
 
|#default ||ambox-notice
 
|}
 
 
 
=== image ===
 
: Please update this list to the image names used.
 
{| class="wikitable"
 
!Value !!Image name
 
 
|-
 
|-
|serious ||[[Image:Stop_hand_nuvola.svg.png]]
+
|content ||ambox-content ||[[Image:Info_content.png|50]]<br/>(paper sheet?)
 
|-
 
|-
|content  ||(jdn-icon)
+
|style    ||ambox-style  ||[[Image:Info_style.png|50]]<br/>(a [[wikipedia:Feather|calamus/quill]]?)
 
|-
 
|-
|style   ||(style--icon)
+
|merge   ||ambox-merge  ||[[Image:Info_merge.png|50]]<br/>(arrows, bandage, symbolic diff output?)
 
|-
 
|-
|merge    ||(merge-icon)
+
|notice  ||ambox-notice  ||[[Image:Info_non-talk.png|50]]
 
|-
 
|-
|notice   ||[[Image:Info_non-talk.png]]
+
|growth   ||ambox-growth  ||[[Image:Info_growth.png|50]]
 
|-
 
|-
|blank    ||empty cell
+
|blank    ||ambox || empty cell
 
|-
 
|-
|#default ||empty cell
+
|#default ||ambox-notice ||empty cell
 
|}
 
|}
  
Line 64: Line 47:
 
  td.ambox-image
 
  td.ambox-image
 
  td.ambox-imageright
 
  td.ambox-imageright
<includeonly></includeonly>
+
<includeonly>[[Category:Templates that need an overhaul]]</includeonly>

Revision as of 08:39, 30 March 2008

{{ambox}} is the base tempate used by several "alert message boxes" which can be placed at the top of an article. It generates a two column table with an optional "message icon". The message text must be provided by the calling template in the {{{text}}} parameter.

ambox should never be used directly, but only via "proxy templates" such as {{inuse}}, {{underconstruction}} or {{docstatus}}. Those templates provide default parameters to have a consistant look and feel for alert message boxes including a standard message text.

Parameters[edit]

Mandatory:

text
the message text to display

Optional:

type (notice)
controls the class attribute used
image (none)
an image from the Image: namespace as a notification icon
imageright (none)
an supplemental image from the Image: namespace, shown in a third column
style (empty)
CSS properties for the HTML style attribute applied to the <table> element. Please try to avoid using colors and fancy font settings in inline styles as this may conflict with a skin's color schema and user settings -- think accessibility!

type and image[edit]

Internal note: Please update the list of image names if files become available.
Value CSS class Image name
serious ambox-serious Stop icon
content ambox-content 50
(paper sheet?)
style ambox-style 50
(a calamus/quill?)
merge ambox-merge 50
(arrows, bandage, symbolic diff output?)
notice ambox-notice 50
growth ambox-growth 50
blank ambox empty cell
#default ambox-notice empty cell

imageright[edit]

An optional, arbitragy image from the File namespace. If this value is not empty, a third right column in added to the alert box.

Stylesheet[edit]

table.metadata plainlinks ambox type
td.ambox-image
td.ambox-imageright