Template:Infobox Card: Difference between revisions

Jump to navigation Jump to search
simply code with variables for expansion, expansioncode, expansionlogo and plotdeck
(Reduce overall height of infobox)
(simply code with variables for expansion, expansioncode, expansionlogo and plotdeck)
Line 3: Line 3:
}}{{
}}{{
   #vardefine: archetype | {{ValidateArchetype|{{{archetype|}}}}}
   #vardefine: archetype | {{ValidateArchetype|{{{archetype|}}}}}
}}{{
  #vardefine: expansion | {{ValidateExpansion|{{{expansion|}}}}}
}}{{
  #vardefine: expansioncode | {{ValidateExpansionCode|{{{expansion|}}}}}
}}{{
  #vardefine: expansionlogo | {{ValidateExpansionLogo|{{{expansion|}}}}}
}}{{
  #vardefine: plotdeck | {{ValidatePlotDeck|{{{expansion|}}}}}
}}{{
}}{{
   #vardefine: heroclass | {{ValidateHeroClass|{{{heroclass|}}}}}
   #vardefine: heroclass | {{ValidateHeroClass|{{{heroclass|}}}}}
Line 119: Line 127:
       }}
       }}
     |Plot Card=
     |Plot Card=
       {{#if:{{{expansion|}}}|
       {{#if:{{#var: plotdeck}}|
        {{#if:{{ValidatePlotDeck|{{{expansion|}}}}}|
        {{!}}align=center style="border:0px transparent" {{!}}[[Plot_Card#Plot_Cards|Plot Deck:]]
          {{!}}align=center style="border:0px transparent" {{!}}[[Plot_Card#Plot_Cards|Plot Deck:]]
        {{!}}align=center style="border:0px transparent"{{!}}[[:Category:{{#var: plotdeck}}|{{#var: plotdeck}}]]
          {{!}}align=center style="border:0px transparent"{{!}}[[:Category:{{ValidatePlotDeck|{{{expansion|}}}}}|{{ValidatePlotDeck|{{{expansion|}}}}}]]
        |}}
       |}}
       |}}
     |#default=
     |#default=
Line 311: Line 317:
   {{!}}colspan=2 align=center style="border:0px transparent" {{!}}'''Expansion'''
   {{!}}colspan=2 align=center style="border:0px transparent" {{!}}'''Expansion'''
   {{!}}-
   {{!}}-
   {{#if:{{{expansion|}}}|
   {{#if:{{#var: expansion}}|
    {{#if:{{ValidateExpansion|{{{expansion|}}}}}|
    {{!}} colspan=2 align=center style="border:0px transparent"{{!}}{{#if:{{#var: expansionlogo}}|{{#var: expansionlogo}}<br>|}}{{#var: expansioncode}} [[{{#var: expansion}}]]
      {{!}} colspan=2 align=center style="border:0px transparent"{{!}}{{#if:{{ValidateExpansionLogo|{{{expansion|}}}}}|{{ValidateExpansionLogo|{{{expansion|}}}}}<br>|}}{{ValidateExpansionCode|{{{expansion|}}}}} [[{{ValidateExpansion|{{{expansion|}}}}}]]
    |
      {{!}} colspan=2 align=center style="border:0px transparent"{{!}}[[Template:ValidateExpansion|Invalid expansion. Read the template documentation for valid expansions]] [[Category:PagesWhichFailValidation]]
    }}
   |
   |
     {{!}} colspan=2 align=center style="border:0px transparent"{{!}}Unknown
     {{!}} colspan=2 align=center style="border:0px transparent"{{!}}[[Template:ValidateExpansion|Invalid expansion. Read the template documentation for valid expansions]] [[Category:PagesWhichFailValidation]]
   }}
   }}
   {{!}}}</div>
   {{!}}}</div>
Line 394: Line 396:
     }}
     }}
   |}}
   |}}
   {{#if:{{ValidateExpansion|{{{expansion|}}}}}|
   {{#if:{{#var: expansion}}|
     [[Category:{{ValidateExpansion|{{{expansion|}}}}}]]
     [[Category:{{#var: expansion}}]]
     {{#switch:{{#var: cardtype}}
     {{#switch:{{#var: cardtype}}
       |Plot Card= [[Category:{{ValidatePlotDeck|{{{expansion|}}}}}]]
       |Plot Card= [[Category:{{#var: plotdeck}}]]
       |#default=
       |#default=
     }}
     }}

Navigation menu