Template:Cardtext/Attack: Difference between revisions

From Bulbapedia, the community-driven Pokémon encyclopedia.
Jump to navigationJump to search
(add switch statement to category link, such that the text is white when the type is darkness)
No edit summary
Line 10: Line 10:
{| width="100%" cellspacing="0" style="background: transparent;"
{| width="100%" cellspacing="0" style="background: transparent;"
| class="roundy" colspan="3" style="padding: 3px; background:#{{#switch: {{{class|}}}|Rocket|Rocketex|Aqua|Magma|Galactic|Plasma|PlasmaEX|Dark|DarkV=888|FFF}};" | {{{effect|}}}
| class="roundy" colspan="3" style="padding: 3px; background:#{{#switch: {{{class|}}}|Rocket|Rocketex|Aqua|Magma|Galactic|Plasma|PlasmaEX|Dark|DarkV=888|FFF}};" | {{{effect|}}}
|}{{#ifeq:{{NAMESPACE}}||
|}{{#ifeq:{{NAMESPACE}}||{{#ifexist:Category:Cards with {{{name}}}||{{#ifeq:{{PAGESINCATEGORY:Cards with {{{name}}}|pages}}|1|[[Category:Temporary test]]}}}}
{{#ifeq:{{{namecategory}}}|-||{{#if:{{{namecategory|{{{name|}}}}}}|[[Category:Cards with {{{namecategory|{{{name|}}}}}}]]}}}}{{#if:{{{damagecategory|{{{damage|}}}}}}|[[Category:Pokémon cards with attack damage {{{damagecategory|{{{damage|}}}}}}]]}}
{{#ifeq:{{{namecategory}}}|-||{{#if:{{{namecategory|{{{name|}}}}}}|[[Category:Cards with {{{namecategory|{{{name|}}}}}}]]}}}}{{#if:{{{damagecategory|{{{damage|}}}}}}|[[Category:Pokémon cards with attack damage {{{damagecategory|{{{damage|}}}}}}]]}}
}}<noinclude>
}}<noinclude>
[[Category:TCG templates]]</noinclude>
[[Category:TCG templates]]</noinclude>