Template:Nb collapsegroup/doc: Difference between revisions
TeslaRaptor (talk | contribs) m (12 revisions) |
TeslaRaptor (talk | contribs) m (2 revisions) |
(No difference)
|
Latest revision as of 19:46, 6 July 2009
Template:Documentationpage Template to be used in Template:Nb main. Creates a collapsible group within a navbox.
Usage
{{nb main |header=title/caption of collapsible group |data= {{nb collapsegroup|rows= rows in collapsible group }} }} Optional: collapsed=yes/no, whether this group is collapsed by default (defaults to yes)
All components of the "nb main" template can be inserted in the "rows" field.
Note that this template cannot be nested inside a block (but blocks can be inside this template).
Examples
Simple collapsible group
{{nb main |name={{subst:PAGENAME}} |title=Example |data= {{nb collapsegroup|header=Example: Collapsible group |rows= {{nb row|Test content within the collapsible group}} {{nb group|Test group|Test content within the collapsible group}} }} }}
results in:
|
Two collapsible groups
{{nb main |name={{subst:PAGENAME}} |title=Example |data= {{nb collapsegroup|header=Example: Collapsible group |rows= {{nb row|Test content within the '''first''' collapsible group}} {{nb group|Test group|Test content within the '''first''' collapsible group}} }} {{nb collapsegroup|header=Example: Collapsible group 2 |rows= {{nb row|Test content within the '''second''' collapsible group}} {{nb group|Test group|Test content within the '''second''' collapsible group}} }} }}
results in:
|
Combined with non-collapsible rows
{{nb main |name={{subst:PAGENAME}} |title=Example |footer=Test footer |data= {{nb row|Test content ''outside'' the collapsible group}} {{nb collapsegroup|header=Example: Collapsible group |rows= {{nb row|Test content '''within''' the collapsible group}} {{nb group|Test group|Test content '''within''' the collapsible group}} }} {{nb row|Test content ''outside'' the collapsible group}} {{nb group|Test group|Test content ''outside'' the collapsible group}} {{nb header|Test header ''outside'' the collapsible group}} {{nb group|Test group|Test content ''outside'' the collapsible group}} }}
results in:
|