Jump to content

Template:Infobox item: Difference between revisions

Seddik (talk | contribs)
No edit summary
Seddik (talk | contribs)
No edit summary
 
(2 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly>{{#if:{{{header|}}}
<includeonly>{{Infobox
|<tr class="infobox-header {{{class|}}}"><th colspan="2">{{{header}}}</th></tr>
| class    = {{#switch:{{{rarity|}}}
|{{#if:{{{data|}}}
  |Common=rarity-common|Uncommon=rarity-uncommon|Rare=rarity-rare
  |<tr class="infobox-row {{{class|}}}">{{#if:{{{label|}}}
  |Very Rare=rarity-veryrare|Legendary=rarity-legendary|Artifact=rarity-artifact
  |<th class="infobox-label">{{{label}}}</th><td class="infobox-data">{{{data}}}</td>
  |#default=
   |<td colspan="2" class="infobox-data">{{{data}}}</td>
}}
  }}</tr>
| title    = {{{name|{{PAGENAME}}}}}
  }}
| image    = {{{image|}}}
}}</includeonly><noinclude>
| imagesize = {{{imagesize|220px}}}
Renders one infobox row. If `header` is set, renders a full-width section header row.
| caption  = {{{caption|}}}
Else if `data` is set, renders a label+data row (or full-width data-only row if no label).
| subtitle = {{{rarity|}}} {{#if:{{{attunement|}}}| ({{{attunement}}})}}
Empty rows (no header, no data) render nothing.
 
</noinclude><noinclude>
| header1 = Item Details
| label2  = Type      | data2 = {{{type|}}}
| label3  = Rarity    | data3 = {{{rarity|}}}
| label4  = Attunement | data4 = {{{attunement|None}}}
 
| header5 = Properties
| data6   = {{{properties|}}}
 
| header7 = Lore
| label8  = Origin | data8 = {{{origin|}}}
| label9 = Owner  | data9 = {{{owner|Unclaimed}}}
| label10 = Party | data10 = {{{party|}}}
 
| below = {{{quote|}}}
}}{{#if:{{{category|}}}|[[Category:{{{category}}}]]}}[[Category:Magic Items]]</includeonly><noinclude>
== Usage ==
== Usage ==
<pre>
<pre>
Line 17: Line 31:
| name =  
| name =  
| image =  
| image =  
| caption =
| type =  
| type =  
| rarity =  
| rarity =  
Line 23: Line 38:
| origin =  
| origin =  
| owner =  
| owner =  
| party =
| quote =
| category =
}}
}}
</pre>
</pre>
'''Rarity''' accepts: Common, Uncommon, Rare, Very Rare, Legendary, Artifact (controls title bar color).
</noinclude>
</noinclude>