Template:ClassTabs: Difference between revisions

From the Portal Wiki
Jump to navigation Jump to search
(Created page with "<includeonly>{{Tabs | title = {{{title}}} | name = {{{name}}} | collapsed = {{{collapsed|}}} | orientation = {{{orientation|vertical}}} | {{#if:{{{selected|}}}|selected|null...")
 
(Test dis)
Line 5: Line 5:
  | orientation = {{{orientation|vertical}}}
  | orientation = {{{orientation|vertical}}}
  | {{#if:{{{selected|}}}|selected|null}} = {{#switch:{{lc:{{{selected|}}}}}
  | {{#if:{{{selected|}}}|selected|null}} = {{#switch:{{lc:{{{selected|}}}}}
   | scout   = 1
   | hats   = 1
   | soldier = 2
   | misc = 2
   | pyro     = 3
   | skins     = 3
   | demoman = 4
   | gestures = 4
  | heavy    = 5
  | engineer = 6
  | medic    = 7
  | sniper  = 8
  | spy      = 9
  | all
  | all-class
  | random  = 10
   | #default = 1
   | #default = 1
   }}
   }}
  | {{#if:{{{edittabs|}}}|edittabs|null}}                = {{{edittabs|}}}
  | {{#if:{{{edittabs|}}}|edittabs|null}}                = {{{edittabs|}}}
  | {{#if:{{{edit1|{{{editscout|}}}}}}|edit1|null}}      = {{{edit1|{{{editscout|}}}}}}
  | {{#if:{{{edit1|{{{edithats|}}}}}}|edit1|null}}      = {{{edit1|{{{edithats|}}}}}}
  | {{#if:{{{edit2|{{{editsoldier|}}}}}}|edit2|null}}    = {{{edit2|{{{editsoldier|}}}}}}
  | {{#if:{{{edit2|{{{editmisc|}}}}}}|edit2|null}}    = {{{edit2|{{{editmisc|}}}}}}
  | {{#if:{{{edit3|{{{editpyro|}}}}}}|edit3|null}}        = {{{edit3|{{{editpyro|}}}}}}
  | {{#if:{{{edit3|{{{editskins|}}}}}}|edit3|null}}        = {{{edit3|{{{editskins|}}}}}}
  | {{#if:{{{edit4|{{{editdemoman|}}}}}}|edit4|null}}    = {{{edit4|{{{editdemoman|}}}}}}
  | {{#if:{{{edit4|{{{editgestures|}}}}}}|edit4|null}}    = {{{edit4|{{{editgestures|}}}}}}
| {{#if:{{{edit5|{{{editheavy|}}}}}}|edit5|null}}      = {{{edit5|{{{editheavy|}}}}}}
| {{#if:{{{edit6|{{{editengineer|}}}}}}|edit6|null}}    = {{{edit6|{{{editengineer|}}}}}}
| {{#if:{{{edit7|{{{editmedic|}}}}}}|edit7|null}}      = {{{edit7|{{{editmedic|}}}}}}
| {{#if:{{{edit8|{{{editsniper|}}}}}}|edit8|null}}      = {{{edit8|{{{editsniper|}}}}}}
| {{#if:{{{edit9|{{{editspy|}}}}}}|edit9|null}}        = {{{edit9|{{{editspy|}}}}}}
| {{#if:{{{edit10|{{{editallclass|}}}}}}|edit10|null}}  = {{{edit10|{{{editallclass|}}}}}}
  | {{#if:{{{notitle|}}}|notitle|null}} = {{{notitle|}}}
  | {{#if:{{{notitle|}}}|notitle|null}} = {{{notitle|}}}
  | {{#if:{{{noheader|}}}|noheader|null}} = {{{noheader|}}}
  | {{#if:{{{noheader|}}}|noheader|null}} = {{{noheader|}}}
  | {{#if:{{{instant|}}}|instant|null}} = {{{instant|}}}
  | {{#if:{{{instant|}}}|instant|null}} = {{{instant|}}}
  | {{#if:{{{width|}}}|width|null}} = {{{width|}}}
  | {{#if:{{{width|}}}|width|null}} = {{{width|}}}
  | icon1 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Scout}}
  | icon1 = {{|size={{{size|{{{icon-size|24px}}}}}}|Hats}}
  | icon2 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Soldier}}
  | icon2 = {{|size={{{size|{{{icon-size|24px}}}}}}|Misc}}
  | icon3 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Pyro}}
  | icon3 = {{|size={{{size|{{{icon-size|24px}}}}}}|Skins}}
  | icon4 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Demoman}}
  | icon4 = {{|size={{{size|{{{icon-size|24px}}}}}}|Gestures}}
| icon5 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Heavy}}
}}
| icon6 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Engineer}}
| icon7 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Medic}}
| icon8 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Sniper}}
| icon9 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Spy}}
| {{#if:{{{all-class|}}}|icon10|null}} = [[File:TF2 crosshair orange.png|24px|link=Classes{{if lang}}]] {{#if:{{{icononly|}}}||{{ucfirst:{{MediaWiki:Searchall{{if lang}}}}}}}}


  | content1 = {{{scout}}}
  | content1 = {{{hats}}}
  | content2 = {{{soldier}}}
  | content2 = {{{misc}}}
  | content3 = {{{pyro}}}
  | content3 = {{{skins}}}
  | content4 = {{{demoman}}}
  | content4 = {{{gestures}}}
| content5 = {{{heavy}}}
| content6 = {{{engineer}}}
| content7 = {{{medic}}}
| content8 = {{{sniper}}}
| content9 = {{{spy}}}
| {{#if:{{{all-class|}}}|content10|null}} = {{{all-class|}}}
  }}</includeonly><noinclude>
  }}</includeonly><noinclude>
{{doc begin}}
{{doc begin}}
Line 77: Line 52:
| title    = Classes
| title    = Classes
| name = ClassTabs
| name = ClassTabs
| selected = heavy
| selected = hats
| size    = 24px
| size    = 24px


| scout   = Scout
| hats   = hats
| soldier = Soldier
| gestures = gestures
| pyro     = Pyro
| skins     = skins
| demoman = Demoman
| misc = misc
| heavy    = Heavy
| engineer = Engineer
| medic    = Medic
| sniper  = Sniper
| spy      = Spy
}}
}}
</pre>
</pre>
Line 95: Line 65:
| title    = Classes
| title    = Classes
| name = ClassTabs
| name = ClassTabs
| selected = heavy
| selected = hats
| size    = 24px
| size    = 24px


| scout   = Scout
| hats   = hats
| soldier = Soldier
| gestures = gestures
| pyro     = Pyro
| skins     = skins
| demoman = Demoman
| misc = misc
| heavy    = Heavy
| engineer = Engineer
| medic    = Medic
| sniper  = Sniper
| spy      = Spy
}}
}}



Revision as of 18:58, 22 May 2011

The template above may be partially or fully invisible or glitched due to the respected strings aren't entered.
This is normal.

Documentation for ClassTabs

Wrapper for {{Tabs}} with class-specific tabs.

Parameters

  • title – box title
  • notitle – Hide title from top bar
  • noheader – Hide top bar completely
  • name – name of the template
  • orientationvertical or horizontal
  • selected – tab to automatically display
  • size – size of class icons
  • width – control the width of the box
  • icononly – only display the class icons (no text labels)
  • instant – set to 'yes' to disable animations
  • <class name> – content (scout, soldier, pyro, etc, all-class for the all-class tab).

Example

{{ClassTabs
| title    = Classes
| name = ClassTabs
| selected = hats
| size     = 24px

| hats    = hats
| gestures  = gestures
| skins     = skins 
| misc  = misc
}}
[hide]Classes
  • {{|size=24px|Hats}}
  • {{|size=24px|Misc}}
  • {{|size=24px|Skins}}
  • {{|size=24px|Gestures}}
{{{content1}}}
{{{content2}}}
{{{content3}}}
{{{content4}}}
show;hide
| content1 = hats
| content2 = misc
| content3 = skins
| content4 = gestures
}}

See also