Difference between revisions of "Template:ClassTabs"

From Team Fortress Wiki
Jump to: navigation, search
(Let's try dis)
 
m
 
(28 intermediate revisions by 8 users not shown)
Line 1: Line 1:
{{VerticalTabs
+
<includeonly>{{Tabs
 
  | title = {{{title}}}
 
  | title = {{{title}}}
  | {{#if:{{{selected|}}}|selected|null}} = {{{selected|}}}
+
| name = {{{name|ClassTabs}}}
 +
| collapsed = {{{collapsed|}}}
 +
| orientation = {{{orientation|vertical}}}
 +
  | {{#if:{{{selected|}}}|selected|null}} = {{#switch:{{lc:{{{selected|}}}}}
 +
  | scout    = 1
 +
  | soldier  = 2
 +
  | pyro    = 3
 +
  | demoman  = 4
 +
  | heavy    = 5
 +
  | engineer = 6
 +
  | medic    = 7
 +
  | sniper  = 8
 +
  | spy      = 9
 +
  | all
 +
  | all-class
 +
  | random  = 10
 +
  | #default = 1
 +
  }}
 +
| {{#if:{{{style|}}}|style|null}}                        = {{{style|}}}
 +
| {{#if:{{{edittabs|}}}|edittabs|null}}                = {{{edittabs|}}}
 +
| {{#if:{{{edit1|{{{editscout|}}}}}}|edit1|null}}      = {{{edit1|{{{editscout|}}}}}}
 +
| {{#if:{{{edit2|{{{editsoldier|}}}}}}|edit2|null}}    = {{{edit2|{{{editsoldier|}}}}}}
 +
| {{#if:{{{edit3|{{{editpyro|}}}}}}|edit3|null}}        = {{{edit3|{{{editpyro|}}}}}}
 +
| {{#if:{{{edit4|{{{editdemoman|}}}}}}|edit4|null}}    = {{{edit4|{{{editdemoman|}}}}}}
 +
| {{#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:{{{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 = {{Icon class|class=Scout|icon-size={{{icon-size|24px}}}}} [[Scout]]
+
  | icon1 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Scout}}
  | icon2 = {{Icon class|class=Soldier|icon-size={{{icon-size|24px}}}}} [[Soldier]]
+
  | icon2 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Soldier}}
  | icon3 = {{Icon class|class=Pyro|icon-size={{{icon-size|24px}}}}} [[Pyro]]
+
  | icon3 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Pyro}}
  | icon4 = {{Icon class|class=Demoman|icon-size={{{icon-size|24px}}}}} [[Demoman]]
+
  | icon4 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Demoman}}
  | icon5 = {{Icon class|class=Heavy|icon-size={{{icon-size|24px}}}}} [[Heavy]]
+
  | icon5 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Heavy}}
  | icon6 = {{Icon class|class=Engineer|icon-size={{{icon-size|24px}}}}} [[Engineer]]
+
  | icon6 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Engineer}}
  | icon7 = {{Icon class|class=Medic|icon-size={{{icon-size|24px}}}}} [[Medic]]
+
  | icon7 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Medic}}
  | icon8 = {{Icon class|class=Sniper|icon-size={{{icon-size|24px}}}}} [[Sniper]]
+
  | icon8 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Sniper}}
  | icon9 = {{Icon class|class=Spy|icon-size={{{icon-size|24px}}}}} [[Spy]]
+
  | icon9 = {{{{#if:{{{icononly|}}}|Icon class|Class link}}|size={{{size|{{{icon-size|24px}}}}}}|Spy}}
  | {{#if:{{{all-class|}}}|icon10|null}} = {{Icon class|class=Random|icon-size={{{icon-size|24px}}}}} All classes
+
  | {{#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 = {{{scout}}}
 
  | content2 = {{{soldier}}}
 
  | content2 = {{{soldier}}}
Line 24: Line 56:
 
  | content9 = {{{spy}}}
 
  | content9 = {{{spy}}}
 
  | {{#if:{{{all-class|}}}|content10|null}} = {{{all-class|}}}
 
  | {{#if:{{{all-class|}}}|content10|null}} = {{{all-class|}}}
 +
}}</includeonly><noinclude>
 +
{{doc begin}}
 +
Wrapper for {{tl|Tabs}} with class-specific tabs.
 +
 +
=== Parameters ===
 +
* {{code|title}} &ndash; box title
 +
* {{code|notitle}} &ndash; Hide <code>title</code> from top bar
 +
* {{code|noheader}} &ndash; Hide top bar completely
 +
* {{code|name}} &ndash; name of the template
 +
* {{code|orientation}} &ndash; <code>vertical</code> or <code>horizontal</code>
 +
* {{code|selected}} &ndash; tab to automatically display
 +
* {{code|size}} &ndash; size of class icons
 +
* {{code|width}} &ndash; control the width of the box
 +
* {{code|icononly}} &ndash; only display the class icons (no text labels)
 +
* {{code|instant}} &ndash; set to 'yes' to disable animations
 +
* {{code|<class name>}} &ndash; content ({{code|scout}}, {{code|soldier}}, {{code|pyro}}, etc, {{code|all-class}} for the all-class tab).
 +
 +
=== Example ===
 +
<pre>
 +
{{ClassTabs
 +
| title    = Classes
 +
| name = ClassTabs
 +
| selected = heavy
 +
| size    = 24px
 +
 +
| scout    = Scout
 +
| soldier  = Soldier
 +
| pyro    = Pyro
 +
| demoman  = Demoman
 +
| heavy    = Heavy
 +
| engineer = Engineer
 +
| medic    = Medic
 +
| sniper  = Sniper
 +
| spy      = Spy
 
}}
 
}}
 +
</pre>
 +
 +
{{ClassTabs
 +
| title    = Classes
 +
| name = ClassTabs
 +
| selected = heavy
 +
| size    = 24px
 +
 +
| scout    = Scout
 +
| soldier  = Soldier
 +
| pyro    = Pyro
 +
| demoman  = Demoman
 +
| heavy    = Heavy
 +
| engineer = Engineer
 +
| medic    = Medic
 +
| sniper  = Sniper
 +
| spy      = Spy
 +
}}
 +
 +
== See also ==
 +
* {{tl|Tabs}}
 +
 +
[[Category:Navbox templates]]
 +
</noinclude>

Latest revision as of 03:42, 6 November 2013

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 = heavy
| size     = 24px

| scout    = Scout
| soldier  = Soldier
| pyro     = Pyro
| demoman  = Demoman
| heavy    = Heavy
| engineer = Engineer
| medic    = Medic
| sniper   = Sniper
| spy      = Spy
}}
[hide]Classes
Scout
Soldier
Pyro
Demoman
Heavy
Engineer
Medic
Sniper
Spy
show;hide

See also