Typecraft v2.5
Jump to: navigation, search

Difference between revisions of "Template:Infobox"

(undo: adding parameters to a highly used meta-template should probably be discussed, the second image was only added after much debate)
(wrap in mainspace detection)
 
(19 intermediate revisions by 7 users not shown)
Line 1: Line 1:
{{#ifeq:{{{child|}}}|yes||<table class="infobox {{{bodyclass|}}}" cellspacing="5" style="width:22em; text-align:left; font-size:88%; line-height:1.5em; {{{bodystyle|}}}"><!--
+
{{#ifeq:{{{child|}}}|yes||<table class="infobox {{{bodyclass|}}}" cellspacing="5" style="width:22em; {{{bodystyle|}}}"><!--
 
  Caption
 
  Caption
-->{{#if:{{{title|}}}|<caption class="{{{titleclass|}}}" style="font-size:125%; font-weight:bold; {{{titlestyle|}}}">{{{title}}}</caption>}}<!--
+
-->{{#if:{{{title|}}}|<caption class="{{{titleclass|}}}" style="{{{titlestyle|}}}">{{{title}}}</caption>}}<!--
 
  Header
 
  Header
-->{{#if:{{{above|}}}|{{Infobox/row
+
-->{{#if:{{{above|}}}|<tr><th colspan=2 class="{{{aboveclass|}}}" style="text-align:center; font-size:125%; font-weight:bold; {{{abovestyle|}}}">{{{above}}}</th></tr>}}
|header={{{above}}} |headerstyle=text-align:center; font-size:125%; font-weight:bold; {{{abovestyle|}}}
+
}}{{#ifeq:{{{child|}}}|yes|{{#if:{{{title|}}}|'''{{{title}}}'''}}}}<!--
|class={{{aboveclass|}}} |rowclass={{{aboverowclass|}}}
+
}} }} }}{{#ifeq:{{{child|}}}|yes|{{#if:{{{title|}}}|'''{{{title}}}'''}}}}<!--
+
 
  Subheader1
 
  Subheader1
-->{{#if:{{{subheader|}}}|{{Infobox/row
+
-->{{#if:{{{subheader|{{{subheader1|}}}}}}|{{Infobox/row
  |data={{{subheader}}}     |datastyle={{{subheaderstyle|}}}
+
  |data={{{subheader|{{{subheader1|}}}}}}
  |class={{{subheaderclass|}}}   |rowclass={{{subheaderrowclass1|}}}
+
|datastyle={{{subheaderstyle|}}}
 +
  |class={{{subheaderclass|}}}
 +
|rowclass={{{subheaderrowclass|{{{subheaderrowclass1|}}}}}}
 
}} }}<!--
 
}} }}<!--
 
  Subheader2
 
  Subheader2
 
-->{{#if:{{{subheader2|}}}|{{Infobox/row
 
-->{{#if:{{{subheader2|}}}|{{Infobox/row
  |data={{{subheader2}}}     |datastyle={{{subheaderstyle|}}}
+
  |data={{{subheader2}}}
  |class={{{subheaderclass|}}}   |rowclass={{{subheaderrowclass2|}}}
+
|datastyle={{{subheaderstyle|}}}
 +
  |class={{{subheaderclass|}}}
 +
|rowclass={{{subheaderrowclass2|}}}
 
}} }}<!--
 
}} }}<!--
 
  Image1
 
  Image1
 
-->{{#if:{{{image|{{{image1|}}}}}}|{{Infobox/row
 
-->{{#if:{{{image|{{{image1|}}}}}}|{{Infobox/row
  |data={{{image|{{{image1}}} }}}{{#if:{{{caption|{{{caption1|}}}}}}|<br /><span style="{{{captionstyle|}}}">{{{caption|{{{caption1}}}}}}</span>}}     |datastyle={{{imagestyle|}}}
+
  |data={{{image|{{{image1}}} }}}{{#if:{{{caption|{{{caption1|}}}}}}|<br /><span style="{{{captionstyle|}}}">{{{caption|{{{caption1}}}}}}</span>}}
  |class={{{imageclass|}}}   |rowclass={{{imagerowclass1|}}}
+
|datastyle={{{imagestyle|}}}
 +
  |class={{{imageclass|}}}
 +
|rowclass={{{imagerowclass1|}}}
 
}} }}<!--
 
}} }}<!--
 
  Image2
 
  Image2
 
-->{{#if:{{{image2|}}}|{{Infobox/row
 
-->{{#if:{{{image2|}}}|{{Infobox/row
  |data={{{image2}}}{{#if:{{{caption2|}}}|<br /><span style="{{{captionstyle|}}}">{{{caption2}}}</span>}}     |datastyle={{{imagestyle|}}}
+
  |data={{{image2}}}{{#if:{{{caption2|}}}|<br /><span style="{{{captionstyle|}}}">{{{caption2}}}</span>}}
  |class={{{imageclass|}}}   |rowclass={{{imagerowclass2|}}}
+
|datastyle={{{imagestyle|}}}
 +
  |class={{{imageclass|}}}
 +
|rowclass={{{imagerowclass2|}}}
 
}} }}<!--
 
}} }}<!--
 
-->{{Infobox/row
 
-->{{Infobox/row
Line 428: Line 434:
 
  |class={{{class80|}}}  |rowclass={{{rowclass80|}}}
 
  |class={{{class80|}}}  |rowclass={{{rowclass80|}}}
 
}}<!-- Below
 
}}<!-- Below
-->{{#if:{{{below|}}}|<tr><td colspan="2" class="{{{belowclass|}}}" style="text-align:center; {{{belowstyle|}}}">{{{below}}}</td></tr>}}<!--
+
-->{{#if:{{{below|}}}|<tr><td colspan=2 class="{{{belowclass|}}}" style="text-align:center; {{{belowstyle|}}}">{{{below}}}</td></tr>}}<!--
 
  Navbar
 
  Navbar
-->{{#if:{{{name|}}}|<tr><td colspan="2" style="text-align:right">{{navbar|{{{name}}}|mini=1}}</td></tr>}}
+
-->{{#if:{{{name|}}}|<tr><td colspan=2 style="text-align:right">{{navbar|{{{name}}}|mini=1}}</td></tr>}}
{{#ifeq:{{{child|}}}|yes||</table>}}<noinclude>
+
{{#ifeq:{{{child|}}}|yes||</table>}}{{#switch:{{lc:{{{italic title|¬}}}}}
{{documentation}}
+
|¬|no      = <!-- no italic title -->
</noinclude>
+
||force|yes = {{italic title|force={{#ifeq:{{lc:{{{italic title|}}}}}|force|true}}}}
 +
}}<includeonly>{{ns0|{{#if:{{{data1|}}}{{{data2|}}}{{{data3|}}}{{{data4|}}}{{{data5|}}}{{{data6|}}}{{{data7|}}}{{{data8|}}}{{{data9|}}}{{{data10|}}}{{{data11|}}}{{{data12|}}}{{{data13|}}}{{{data14|}}}{{{data15|}}}{{{data16|}}}{{{data17|}}}{{{data18|}}}{{{data19|}}}{{{data20|}}}{{{data21|}}}{{{data22|}}}{{{data23|}}}{{{data24|}}}{{{data25|}}}{{{data26|}}}{{{data27|}}}{{{data28|}}}{{{data29|}}}{{{data30|}}}{{{data31|}}}{{{data32|}}}{{{data33|}}}{{{data34|}}}{{{data35|}}}{{{data36|}}}{{{data37|}}}{{{data38|}}}{{{data39|}}}{{{data40|}}}{{{data41|}}}{{{data42|}}}{{{data43|}}}{{{data44|}}}{{{data45|}}}{{{data46|}}}{{{data47|}}}{{{data48|}}}{{{data49|}}}{{{data50|}}}{{{data51|}}}{{{data52|}}}{{{data53|}}}{{{data54|}}}{{{data55|}}}{{{data56|}}}{{{data57|}}}{{{data58|}}}{{{data59|}}}{{{data60|}}}{{{data61|}}}{{{data62|}}}{{{data63|}}}{{{data64|}}}{{{data65|}}}{{{data66|}}}{{{data67|}}}{{{data68|}}}{{{data69|}}}{{{data70|}}}{{{data71|}}}{{{data72|}}}{{{data73|}}}{{{data74|}}}{{{data75|}}}{{{data76|}}}{{{data77|}}}{{{data78|}}}{{{data79|}}}{{{data80|}}}||[[category:infobox templates with no data rows]]}}}}</includeonly><noinclude>{{documentation}}</noinclude>

Latest revision as of 18:57, 2 July 2011

[edit] [purge] 50px Template documentation

(edit)