Difference between revisions of "Template:GroupTableColHeader"

From QWiki
(Extreme lab)
 
m
Line 1: Line 1:
 
<includeonly>|-
 
<includeonly>|-
!style="width: 16px;"|<nowiki>#</nowiki> <!-- show place number in header cell -->
+
!class="wikitable" style="width: 16px;"|<nowiki>#</nowiki> <!-- show place number in header cell -->
 
!colspan="{{#expr:4-{{#if:{{{go|}}}|1|0}}-{{#if:{{{win_g|}}}{{{lose_g|}}}|1|0}}-{{#if:{{{diff|}}}|1|0}}}}" style="text-align:left;" class="grouptableslot"| Team <!-- show the player name with the correct colspan -->
 
!colspan="{{#expr:4-{{#if:{{{go|}}}|1|0}}-{{#if:{{{win_g|}}}{{{lose_g|}}}|1|0}}-{{#if:{{{diff|}}}|1|0}}}}" style="text-align:left;" class="grouptableslot"| Team <!-- show the player name with the correct colspan -->
 
{{#if: {{{go|}}} <!-- if go= is present, add a cell and show the arrow -->
 
{{#if: {{{go|}}} <!-- if go= is present, add a cell and show the arrow -->

Revision as of 11:30, 21 October 2020

Documentation (view - edit)

Adds a column header row to a group table. This template is used inbetween the templates {{GroupTableStart}} and {{GroupTableSlot}}, which have to end with with {{GroupTableEnd}}).

Example #1

{{GroupTableStart|GroupTableStart|width=100%}}
{{GroupTableColHeader|Nation|games=1|maps=1|diff=1}}
{{GroupTableEnd}}

Gives us:

GroupTableStart
# Team 0-0 1

Example #1

{{GroupTableStart|GroupTableStart|width=100%}}
{{GroupTableColHeader|Nation|games=1|maps=1|diff=}}
{{GroupTableEnd}}

Gives us:

GroupTableStart
# Team 0-0

Parameters

The following parameters can be used for this template

first unnamed argument
The first unnamed argument of the parameter list is used as the name of player column. Examples could be Player, Team or Nation.
|games=
(Optional) If not empty, it will display "Games" header
|maps=
(Optional) If not empty, it will display "Maps" header
|diff=
(Optional) If not empty, it will display "Diff" header