Difference between revisions of "Template:Card infobox/doc"

From Artifact: The Dota Card Game Wiki
Jump to: navigation, search
Line 1: Line 1:
  +
{{doc/start}}
{{Card infobox
 
  +
This template draws data from a card page's associated data page that is populated through [[Template:Card data]]. It accepts an optional override parameter of <code>id</code> should the database load the incorrect card based on name alone.
| name = Test
 
  +
| image = File:Sven card art.jpg
 
  +
It creates a instance of Card infobox aligned on the right side of the page. It also generates the first line of text on the page describing what the card is. Furthermore, this templates sets a custom <code>og:description</code> attribute on the page so that search engines like Google don't parse the Card infobox as the search description.
| cost = 0
 
  +
| rarity = Unknown
 
  +
The majority of the wikitext powering these functions are loaded through a template call to Template:Card infobox/inner by the Cargo query.
| attack = 5
 
  +
| armor = 10
 
  +
{{doc/end}}
| health = 11
 
| text = Manly
 
| gold_cost = 20
 
| mana_cost = 20
 
| ability = It's great
 
|abilitycd=1
 
}}
 
To add a illustrator to a card infobox, it must have an associated entry at [[Artists and Actors]].
 
<pre>
 
{{
 
| name = String
 
| image = File
 
| icon = File
 
| ability_image = File
 
| type = String
 
| color = String
 
| mana_cost = Integer
 
| gold_cost = Integer
 
| rarity = String
 
| color = String
 
| attack = Integer
 
| armor = Integer
 
| health = Integer
 
| illustrator = String
 
| text = String
 
| ability = String
 
| hero_dependent = String
 
| expansion = String
 
}}
 
</pre>
 

Revision as of 15:52, 14 December 2018

Template-info.png Documentation

This template draws data from a card page's associated data page that is populated through Template:Card data. It accepts an optional override parameter of id should the database load the incorrect card based on name alone.

It creates a instance of Card infobox aligned on the right side of the page. It also generates the first line of text on the page describing what the card is. Furthermore, this templates sets a custom og:description attribute on the page so that search engines like Google don't parse the Card infobox as the search description.

The majority of the wikitext powering these functions are loaded through a template call to Template:Card infobox/inner by the Cargo query.