Hi fellow wiki editors!

To help newly registered users get more familiar with the wiki (and maybe older users too) there is now a {{Welcome to the wiki}} template. Have a look at it and feel free to add it to new users discussion pages (and perhaps your own).

I have tried to keep the template short, but meaningful. /Johan G

Difference between revisions of "Template:Sidebar with collapsible headers"

From FlightGear wiki
Jump to: navigation, search
(Begin editing; still need to add more rows)
 
(5 intermediate revisions by the same user not shown)
Line 1: Line 1:
<table class="vertical-navbox {{#if: {{{wraplinks|}}}|{{#ifeq: {{{wraplinks|}}}|true||nowraplinks}}|nowraplinks}} {{{bodyclass|{{{class|}}}}}}" cellspacing="{{#if:{{{cellspacing|}}}|{{{cellspacing}}}|5}}" style="float: {{#if:{{{float|}}}|{{{float}}}|right}}; clear: {{#ifeq:{{{float|}}}|none|both|{{#if:{{{float|}}}|{{{float}}}|right}}}}; background-color: #f9f9f9; border: 1px solid #aaa; width:{{#if:{{{width|}}}|{{{width}}}|22em}}; {{#switch:{{{float|}}}|left = margin: 0 1em 1em 0;| none | right | #default = margin: 0 0 1em 1em;}} padding: 0.2em; border-spacing: 0.4em 0; text-align: center; line-height: 1.4em; font-size: 88%; {{{bodystyle|{{{style|}}}}}}" cellpadding="{{#if:{{{cellpadding|}}}|{{{cellpadding}}}|0}}">{{#if: {{{outertitle|}}}|<caption class="{{{outertitleclass|}}}" style="padding-bottom: 0.2em; font-size: 125%; line-height: 1.2em; font-weight: bold; {{{outertitlestyle|}}}">{{{outertitle}}}</caption>
+
<includeonly><table class="vertical-navbox {{#if: {{{wraplinks|}}}|{{#ifeq: {{{wraplinks|}}}|true||nowraplinks}}|nowraplinks}} {{{bodyclass|{{{class|}}}}}}" cellspacing="{{#if:{{{cellspacing|}}}|{{{cellspacing}}}|5}}" style="float: {{#if:{{{float|}}}|{{{float}}}|right}}; clear: {{#ifeq:{{{float|}}}|none|both|{{#if:{{{float|}}}|{{{float}}}|right}}}}; background-color: #f9f9f9; border: 1px solid #aaa; width:{{#if:{{{width|}}}|{{{width}}}|22em}}; {{#switch:{{{float|}}}|left = margin: 0 1em 1em 0;| none | right | #default = margin: 0 0 1em 1em;}} padding: 0.2em; border-spacing: 0.4em 0; text-align: center; line-height: 1.4em; font-size: 88%; {{{bodystyle|{{{style|}}}}}}" cellpadding="{{#if:{{{cellpadding|}}}|{{{cellpadding}}}|0}}">{{#if: {{{outertitle|}}}|<caption class="{{{outertitleclass|}}}" style="padding-bottom: 0.2em; font-size: 125%; line-height: 1.2em; font-weight: bold; {{{outertitlestyle|}}}">{{{outertitle}}}</caption>
 
}}{{#if: {{{topimage|}}}|
 
}}{{#if: {{{topimage|}}}|
 
<tr>
 
<tr>
Line 25: Line 25:
 
{{{above}}}</td>
 
{{{above}}}</td>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading1|}}}
+
-->{{#if: {{{content1|}}}
| {{#if: {{{content1|}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading1}}}
+
  | id = 1
            | {{{content1}}}
+
  | content =
            | {{{state|}}}
+
{{{content1}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading1|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading1style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content1style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading1style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content1style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading2|x}}}
+
-->{{#if: {{{content2|}}}
| {{#if: {{{content2|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading2}}}
+
  | id = 2
            | {{{content2}}}
+
  | content =
            | {{{state|}}}
+
{{{content2}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading2|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading2style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content2style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading2style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content2style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading3|x}}}
+
-->{{#if: {{{content3|}}}
| {{#if: {{{content3|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading3}}}
+
  | id = 3
            | {{{content3}}}
+
  | content =
            | {{{state|}}}
+
{{{content3}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading3|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading3style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content3style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading3style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content3style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading4|x}}}
+
-->{{#if: {{{content4|}}}
| {{#if: {{{content4|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading4}}}
+
  | id = 4
            | {{{content4}}}
+
  | content =
            | {{{state|}}}
+
{{{content4}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading4|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading4style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content4style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading4style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content4style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading5|x}}}
+
-->{{#if: {{{content5|}}}
| {{#if: {{{content5|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading5}}}
+
  | id = 5
            | {{{content5}}}
+
  | content =
            | {{{state|}}}
+
{{{content5}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading5|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading5style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content5style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading5style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content5style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading6|x}}}
+
-->{{#if: {{{content6|}}}
| {{#if: {{{content6|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading6}}}
+
  | id = 6
            | {{{content6}}}
+
  | content =
            | {{{state|}}}
+
{{{content6}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading6|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading6style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content6style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading6style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content6style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading7|x}}}
+
-->{{#if: {{{content7|}}}
| {{#if: {{{content7|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading7}}}
+
  | id = 7
            | {{{content7}}}
+
  | content =
            | {{{state|}}}
+
{{{content7}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading7|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading7style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content7style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading7style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content7style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading8|x}}}
+
-->{{#if: {{{content8|}}}
| {{#if: {{{content8|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading8}}}
+
  | id = 8
            | {{{content8}}}
+
  | content =
            | {{{state|}}}
+
{{{content8}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading8|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading8style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content8style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading8style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content8style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading9|x}}}
+
-->{{#if: {{{content9|}}}
| {{#if: {{{content9|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading9}}}
+
  | id = 9
            | {{{content9}}}
+
  | content =
            | {{{state|}}}
+
{{{content9}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading9|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading9style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content9style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading9style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content9style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading10|x}}}
+
-->{{#if: {{{content10|}}}
| {{#if: {{{content10|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading10}}}
+
  | id = 10
            | {{{content10}}}
+
  | content =
            | {{{state|}}}
+
{{{content10}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading10|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading10style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content10style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading10style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content10style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading11|x}}}
+
-->{{#if: {{{content11|}}}
| {{#if: {{{content11|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading11}}}
+
  | id = 11
            | {{{content11}}}
+
  | content =
            | {{{state|}}}
+
{{{content11}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading11|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading11style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content11style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading11style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content1style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
-->{{#if: {{{heading12|x}}}
+
-->{{#if: {{{content12|}}}
| {{#if: {{{content12|x}}}
+
| <tr><td>
  | <tr><td>{{Sidebar with collapsible headers/content
+
  {{Sidebar with collapsible headers/content
            | {{{heading12}}}
+
  | id = 12
            | {{{content12}}}
+
  | content =
            | {{{state|}}}
+
{{{content12}}}
            | headingclass = {{{headingclass|}}}
+
  | heading = {{{heading12|}}}
            | headingstyle = {{{headingstyle|}}}; {{{heading12style|}}}
+
  | state = {{{state|}}}
            | contentclass = {{{contentclass|}}}
+
  | headingclass = {{{headingclass|}}}
            | contentstyle = {{{contentstyle|}}}; {{{content12style|}}}
+
  | headingstyle = {{{headingstyle|}}}; {{{heading12style|}}}
            }}</td></tr>
+
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content12style|}}}
 
   }}
 
   }}
 +
  </td></tr>
 +
}}<!--
 +
-->{{#if: {{{content13|}}}
 +
| <tr><td>
 +
  {{Sidebar with collapsible headers/content
 +
  | id = 13
 +
  | content =
 +
{{{content13}}}
 +
  | heading = {{{heading13|}}}
 +
  | state = {{{state|}}}
 +
  | headingclass = {{{headingclass|}}}
 +
  | headingstyle = {{{headingstyle|}}}; {{{heading13style|}}}
 +
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content13style|}}}
 +
  }}
 +
  </td></tr>
 +
}}<!--
 +
-->{{#if: {{{content14|}}}
 +
| <tr><td>
 +
  {{Sidebar with collapsible headers/content
 +
  | id = 14
 +
  | content =
 +
{{{content14}}}
 +
  | heading = {{{heading14|}}}
 +
  | state = {{{state|}}}
 +
  | headingclass = {{{headingclass|}}}
 +
  | headingstyle = {{{headingstyle|}}}; {{{heading14style|}}}
 +
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content14style|}}}
 +
  }}
 +
  </td></tr>
 +
}}<!--
 +
-->{{#if: {{{content15|}}}
 +
| <tr><td>
 +
  {{Sidebar with collapsible headers/content
 +
  | id = 15
 +
  | content =
 +
{{{content15}}
 +
  | heading = {{{heading15|}}}
 +
  | state = {{{state|}}}
 +
  | headingclass = {{{headingclass|}}}
 +
  | headingstyle = {{{headingstyle|}}}; {{{heading15style|}}}
 +
  | contentclass = {{{contentclass|}}}
 +
  | contentstyle = {{{contentstyle|}}}; {{{content15style|}}}
 +
  }}
 +
  </td></tr>
 
}}<!--
 
}}<!--
 
  Below
 
  Below
Line 187: Line 256:
 
{{{below}}}</td>
 
{{{below}}}</td>
 
</tr>
 
</tr>
}}{{#switch: {{{navbar|{{{tnavbar|<noinclude>off</noinclude>}}}}}}
+
}}<!--
 +
 
 +
-->{{#if: {{{heading1|}}}{{{heading2|}}}{{{heading3|}}}{{{heading4|}}}{{{heading5|}}}{{{heading6|}}}{{{heading7|}}}{{{heading8|}}}{{{heading9|}}}{{{heading10|}}}{{{heading11|}}}{{{heading12|}}}{{{heading13|}}}{{{heading14|}}}{{{heading15|}}}
 +
| <tr><td style="text-align: center; font-size: 85%; color: grey"><i>(click on headings to toggle)</i></td></tr>
 +
}}<!--
 +
 
 +
-->{{#switch: {{{navbar|{{{tnavbar|<noinclude>off</noinclude>}}}}}}
 
|none |off=
 
|none |off=
 
|#default=<tr>
 
|#default=<tr>
 
<td style="text-align: right; font-size: 115%; {{{navbarstyle|{{{tnavbarstyle|}}}}}}">{{navbar|{{{name|{{PAGENAME}}}}}|mini=1|fontstyle={{{navbarfontstyle|{{{tnavbarfontstyle|}}}}}}}}</td>
 
<td style="text-align: right; font-size: 115%; {{{navbarstyle|{{{tnavbarstyle|}}}}}}">{{navbar|{{{name|{{PAGENAME}}}}}|mini=1|fontstyle={{{navbarfontstyle|{{{tnavbarfontstyle|}}}}}}}}</td>
 
</tr>}}
 
</tr>}}
</table><noinclude>{{Informative template |1=
+
</table></includeonly><noinclude>{{Informative template |1=
 
== Goal ==
 
== Goal ==
 
This is a template used by right side navigation box templates used for navigating article series and otherwise related articles. Unlike {{tl|sidebar}}, this template has collapsible headers (which are collapsed by default).
 
This is a template used by right side navigation box templates used for navigating article series and otherwise related articles. Unlike {{tl|sidebar}}, this template has collapsible headers (which are collapsed by default).

Latest revision as of 07:47, 19 December 2015

The following template description is not displayed when the template is inserted in an article.

Goal

This is a template used by right side navigation box templates used for navigating article series and otherwise related articles. Unlike {{sidebar}}, this template has collapsible headers (which are collapsed by default).

For more documentation, see Template:Sidebar.

Related templates

External links