Template:Severity

From FlightGear wiki
Jump to navigation Jump to search
N/A
The following template description is not displayed when the template is inserted in an article.

Goal

This template can be used to highlight the level of urgency/severity/importance/priority/need in a table.

Usage

{{severity|level of severity|alternative text|attributes}}

All parameters are optional.

level of severity
Level of severity as the numbers 0-5 where 5 is the highest level of severity. Leave empty if a level of severity is not yet decided.
alternative text
Alternative text to show instead of the level of severity.
attributes
XHTML attributes. Note that an equal sign = will break the template and {{=}} will have to be used. For example rowspan{{=}}"3".

Examples

Usage Result
{{severity|5|Fix yesterday!}} Fix yesterday!
{{severity|5}} 5
{{severity|4}} 4
{{severity|3}} 3
{{severity|2}} 2
{{severity|1}} 1
{{severity}} N/A
{{severity|2=-}} -
{{severity|3=rowspan{{=}}"2"}} N/A
-

Using attributes

{| class="wikitable"
! Items !! Importance
| These are... |
| {{severity|5||rowspan{{=}}"2"}}
|-
| ...both important
|-
| But not this one |
| {{severity|1}}
|}
Items Importance
These are... 5
...both important
But not this one 1

Known issues

For now the second and third parameter cannot be used if the first is empty, unless they are used as numbered parameters. See examples below:

Usage Result
{{severity||-}} {{severity}}: Invalid level of severity parameter
{{severity|||rowspan{{=}}"2"}} {{severity}}: Invalid level of severity parameter
{{severity|2=-}} -
{{severity|3=rowspan{{=}}"2"}} N/A
-

Related templates