Difference between revisions of "Template:Infobox/row"

From Twinsuniverse
Jump to: navigation, search
m
Line 10: Line 10:
 
</tr>
 
</tr>
 
}}</includeonly><noinclude>
 
}}</includeonly><noinclude>
This template is used by [[Template:Infobox]] to add a row to the table.
+
This template is used by [[Template:Infobox]] to add a row to the table. A row can be a full-row header, a half-row label with data, or a (multi-line) data-only row.
  
 
{{stub}}
 
{{stub}}
  
 
==Parameters==
 
==Parameters==
* '''header''':
+
* '''header''': Specifying this parameter makes this row a header, and further ignores any '''data''' or '''label''' (case sensitive, defaults to non-header row)
* '''label''':
+
* '''label''': Specifying this parameter if the row isn't a header, adds a half-row label in front of the '''data''' (case sensitive, defaults to data-only row)
* '''data''':
+
* '''data''': Specify this parameter to make the row display data, if it isn't a header row (case sensitive, defaults to nothing displayed)
* '''class''':
+
* '''class''': The class of the header tablecell if the row is a header, or the data tablecell otherwise (case sensitive, defaults to "subtitle" for header, or no specific class for data)
 +
 
 +
 
 +
'''''Note:''' When neither '''data''' nor '''header''' are specified, the row will fully collapse and ignore any other specified values.''
 +
 
 +
'''''Note:''' The '''data''' may contain multiple lines of text, but if the '''label''' is also specified, the label will render stretched across the height of the data. So only specify a label if the data contains just a single line.''
  
 
==Syntax==
 
==Syntax==
 +
When specifying a header row, use this syntax:
 +
<nowiki>{{Infobox/row
 +
|header=some header text
 +
|class=subtitle
 +
}}</nowiki>
 +
 +
Otherwise, when specifying a row that contains data:
 +
<nowiki>{{Infobox/row
 +
|label=some optional label text
 +
|data=text
 +
|class=
 +
}}</nowiki>
  
 
==Examples==
 
==Examples==

Revision as of 18:59, 20 December 2012

This template is used by Template:Infobox to add a row to the table. A row can be a full-row header, a half-row label with data, or a (multi-line) data-only row.


  This article is a stub [list all]. You can help the Twinsuniverse by expanding it.

Parameters

  • header: Specifying this parameter makes this row a header, and further ignores any data or label (case sensitive, defaults to non-header row)
  • label: Specifying this parameter if the row isn't a header, adds a half-row label in front of the data (case sensitive, defaults to data-only row)
  • data: Specify this parameter to make the row display data, if it isn't a header row (case sensitive, defaults to nothing displayed)
  • class: The class of the header tablecell if the row is a header, or the data tablecell otherwise (case sensitive, defaults to "subtitle" for header, or no specific class for data)


Note: When neither data nor header are specified, the row will fully collapse and ignore any other specified values.

Note: The data may contain multiple lines of text, but if the label is also specified, the label will render stretched across the height of the data. So only specify a label if the data contains just a single line.

Syntax

When specifying a header row, use this syntax:

{{Infobox/row
 |header=some header text
 |class=subtitle
}}

Otherwise, when specifying a row that contains data:

{{Infobox/row
 |label=some optional label text
 |data=text
 |class=
}}

Examples