Module:Sports series/doc: Difference between revisions

Content deleted Content added
update documentation
Line 37:
=== International club football ===
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 45:
 
; Output
{{#invoke:Sports series|main|bold_winner=y
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 54:
=== Domestic club football ===
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|flag=n
|[[Valencia CF|Valencia]]|3–3 {{pso|3–2}}|[[Deportivo Alavés|Alavés]]|2–1|1–2 {{aet}}
|[[Atlético Madrid]]|2–5|[[Sevilla FC|Sevilla]]|1–2|1–3
Line 62:
 
; Output
{{#invoke:Sports series|main|flag=n|bold_winner=y
|[[Valencia CF|Valencia]]|3–3 {{pso|3–2}}|[[Deportivo Alavés|Alavés]]|2–1|1–2 {{aet}}
|[[Atlético Madrid]]|2–5|[[Sevilla FC|Sevilla]]|1–2|1–3
Line 71:
=== Men's national team football ===
; Usage
<pre>{{#invoke:Sports series|main|type=NT|bold_winner=y
|UKR|3–1|SVN|2–0|1–1
|SWE|4–3|DEN|2–1|2–2
Line 79:
 
; Output
{{#invoke:Sports series|main|type=NT|bold_winner=y
|UKR|3–1|SVN|2–0|1–1
|SWE|4–3|DEN|2–1|2–2
Line 88:
=== Women's national team football ===
; Usage
<pre>{{#invoke:Sports series|main|type=WNT|bold_winner=y
|SRB|2–3|ISL|1–1|1–2
|HUN|2–10|BEL|1–5|1–5
Line 96:
 
; Output
{{#invoke:Sports series|main|type=WNT|bold_winner=y
|SRB|2–3|ISL|1–1|1–2
|HUN|2–10|BEL|1–5|1–5
Line 137:
==== Example 1 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|legs=5
|[[Arsenal F.C.|Arsenal]]|ENG|6–8|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1|2–2|0–1|2–2
|[[Atlético Madrid]]|ESP|10–11|[[Borussia Dortmund]]|GER|2–1|2–4|2–1|2–4|2–1
Line 145:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|legs=5
|[[Arsenal F.C.|Arsenal]]|ENG|6–8|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1|2–2|0–1|2–2
|[[Atlético Madrid]]|ESP|10–11|[[Borussia Dortmund]]|GER|2–1|2–4|2–1|2–4|2–1
Line 154:
==== Example 2 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|legs=n
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER
Line 162:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|legs=n
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER
Line 174:
 
|style="text-align:center;vertical-align:top"|{{TOC tab|bold_winner}}
|style="background-color:#fff"|Automatically enabled by default. To enabledisable, set to a positivenegative value (e.g. yn, yesno, 10). AutomaticallyThe module automatically bolds the winning team of the tie. First priority is given to the winning team of scores listed inside brackets (which is commonly used to denote the results of a [[Penalty shoot-out (association football)|penalty shoot-out]]). Otherwise, the regular score will be used. If the aggregate scores are level for two-legged ties and no results of penalty shoot-outs are given, the [[away goals rule]] will be applied to determine the winning team (unless {{para|away_goals}} is used to turn off this feature). In all other cases, if no winner can be determined based on the input, neither team in a given tie will be bolded.
|style="background-color:#fff"|String
 
Line 198:
==== Example 3 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|collapsed=y
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 204:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|collapsed=y
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 218:
==== Example 4 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|caption=This is a caption
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 224:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|caption=This is a caption
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 238:
==== Example 5 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|title=This is a title
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 244:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|title=This is a title
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 332:
==== Example 6 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|leg1=Game 1|leg2=Second Leg
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 340:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|leg1=Game 1|leg2=Second Leg
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 356:
==== Example 7 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|flag=n|legs=7|leg_prefix=Game|aggregate=Series
|[[Golden State Warriors]]|3–4|[[Cleveland Cavaliers]]|104–89|110–77|90–120|108–97|97–112|101–115|89–93
}}</pre>
 
; Output
{{#invoke:Sports series|main|bold_winner=y|flag=n|legs=7|leg_prefix=Game|aggregate=Series
|[[Golden State Warriors]]|3–4|[[Cleveland Cavaliers]]|104–89|110–77|90–120|108–97|97–112|101–115|89–93
}}
Line 367:
==== Example 8 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|leg_prefix=y
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 375:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|leg_prefix=y
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 391:
==== Example 9 ====
; Usage
<pre>{{#invoke:Sports series|main|bold_winner=y|leg_suffix=match
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 399:
 
; Output
{{#invoke:Sports series|main|bold_winner=y|leg_suffix=match
|[[Arsenal F.C.|Arsenal]]|ENG|2–3|[[FC Bayern Munich|Bayern Munich]]|GER|2–2|0–1
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
Line 415:
==== Example 10 ====
; Usage
<pre>{{#invoke:Sports series|main|type=NT|legs=n|h_a=y|bold_winner=y|heading1=Semi-finals|heading3=Final
|POL|5–1|EST
|WAL|4–1|FIN
Line 422:
 
; Output
{{#invoke:Sports series|main|type=NT|legs=n|h_a=y|bold_winner=y|heading1=Semi-finals|heading3=Final
|POL|5–1|EST
|WAL|4–1|FIN
Line 444:
 
; Usage
<pre>{{#invoke:Sports series|main|type=NT|legs=3|bold_winner=y|leg3=Play-off
|LUX|5–6|DEN|3–3|2–2|0–1
|ESP+1945|7–1|IRL|5–1|2–0|null
Line 452:
 
; Output
{{#invoke:Sports series|main|type=NT|legs=3|bold_winner=y|leg3=Play-off
|LUX|5–6|DEN|3–3|2–2|0–1
|ESP+1945|7–1|IRL|5–1|2–0|null
Line 465:
 
; Usage
<pre>{{#invoke:Sports series|main|type=NT|flag=fbu+17|bold_winner=y
|LUX|5–6|DEN|3–3|2–2
|ESP|7–1|IRL|5–1|2–0
Line 473:
 
; Output
{{#invoke:Sports series|main|type=NT|flag=fbu+17|bold_winner=y
|LUX|5–6|DEN|3–3|2–2
|ESP|7–1|IRL|5–1|2–0
Line 484:
 
; Usage 1
<pre>{{#invoke:Sports series|main|type=NT|bold_winner=y
|MLT+1943|5–6|GRE+old|3–3|2–2
}}</pre>
 
; Output 1
{{#invoke:Sports series|main|type=NT|bold_winner=y
|MLT+1943|5–6|GRE+old|3–3|2–2
}}
 
; Usage 2
<pre>{{#invoke:Sports series|main|bold_winner=y
|[[Atlético Madrid]]|ESP+1945|4–5|[[Borussia Dortmund]]|GER+empire|2–1|2–4
}}</pre>
 
; Output 2
{{#invoke:Sports series|main|bold_winner=y
|[[Atlético Madrid]]|ESP+1945|4–5|[[Borussia Dortmund]]|GER+empire|2–1|2–4
}}
Line 507:
 
; Usage 1
<pre>{{#invoke:Sports series|main|type=NT|bold_winner=y
|FRA|2–5|HUN|1–3|1–2
|SWE||*Winner QF1||
Line 513:
 
; Output 1
{{#invoke:Sports series|main|type=NT|bold_winner=y
|FRA|2–5|HUN|1–3|1–2
|SWE||*Winner QF1||
}}
; Usage 2
<pre>{{#invoke:Sports series|main|type=NT|bold_winner=y|fill_blanks=y
|FRA|2–5|HUN|1–3|1–2
|SWE||*Winner QF1||
Line 524:
 
; Output 2
{{#invoke:Sports series|main|type=NT|bold_winner=y|fill_blanks=y
|FRA|2–5|HUN|1–3|1–2
|SWE||*Winner QF1||
Line 530:
 
==== Three apostrophes (<nowiki>'''</nowiki>) for manual bolding ====
While the template allowsautomatically for automatic bolding ofbolds winning teams via(unless {{para|bold_winner|yn}}), in some situations (such as matches tied on away goals) the module will be unable to determine the winner. Or, some users may find it undesirable to usehave {{para|bold_winner}}the tomodule determinebold the winner automatically. In these cases, manual bolding can be used to indicate the winning team of a tie. This is simple to do for {{para|type|club}}, by placing the three apostrophes before and after the name of the team. Additionally, the module supports using three apostrophes around both sides of the national team name/code for {{para|type|NT}}. If {{para|bold_winner}} is setnot disabled, the team that is manually bolded will override the winning team as determined by the module. If {{para|color_winner}} is also set, the cell of the team that is manually bolded will also be colored.
 
This may be used in conjunction with the [[#Two apostrophes ('') for manual coloring|below method]] by using five apostrophes on either side of a team to bold and color the cell.
 
(Note: The usage of three apostrophes was slightly modified for the purposes of this module to bold the cell. Therefore, it is not possible to selectively bold parts of the team parameters, while leaving other parts of said parameter unbolded.)
 
; Usage 1
<pre>{{#invoke:Sports series|main|type=NT|bold_winner=n
|LUX|5–6|'''DEN'''|3–3|2–3
|'''ESP'''|7–1|IRL|5–1|2–0
Line 543 ⟶ 545:
 
; Output 1
{{#invoke:Sports series|main|type=NT|bold_winner=n
|LUX|5–6|'''DEN'''|3–3|2–3
|'''ESP'''|7–1|IRL|5–1|2–0
Line 550 ⟶ 552:
}}
 
; Usage 2 (third row overrides {{para|bold_winner}}automatic bolding)
<pre>{{#invoke:Sports series|main|type=NT|bold_winner=y
|SWE|2–4|NOR|1–1|1–3
|LUX|5–5 ([[Away goals rule|a]])|'''DEN'''|3–3|2–2
Line 557 ⟶ 559:
}}</pre>
 
; Output 2 (third row overrides {{para|bold_winner}automatic bolding})
{{#invoke:Sports series|main|type=NT|bold_winner=y
|SWE|2–4|NOR|1–1|1–3
|LUX|5–5 ([[Away goals rule|a]])|'''DEN'''|3–3|2–2
Line 565 ⟶ 567:
 
==== Two apostrophes (<nowiki>''</nowiki>) for manual coloring ====
While the template allows for automatic coloring of the cells of winning teams via {{para|color_winner|y}}, in some situations (such as matches tied on away goals) the module will be unable to determine the winner. Or, some users may find it undesirable to use {{para|color_winner}} to determinecolor the winner automatically. In these cases, manual coloring can be used to indicate the winning team of a tie. This is simple to do for {{para|type|club}}, by placing the two apostrophes before and after the name of the team. Additionally, the module supports using two apostrophes around both sides of the national team name/code for {{para|type|NT}}. If {{para|color_winner}} is set, the cell of team that is manually colored will override the winning team as determined by the module. If {{para|bold_winner}} is alsonot setdisabled, the cell of the team that is manually colored will also be bolded.
 
This may be used in conjunction with the [[#Three apostrophes (''') for manual bolding|above method]] by using five apostrophes on either side of a team to color and bold the cell.
Line 571 ⟶ 573:
Two apostrophes surrounding an aggregate score (or the score of a single-leg tie) can also be used to manually indicate a draw/tie.
 
(Note: While two apostrophes surrounding both sides of text are usually used to add italics in wikitext, the usage was modified here to allow for a simple way to color the cell. Therefore, it is not possible to italicize team names or aggregate scores using this formatting.)
 
; Usage 1
<pre>{{#invoke:Sports series|main|type=WNT|bold_winner=n
|LUX|5–6|''DEN''|3–3|2–3
|''ESP''|7–1|IRL|5–1|2–0
Line 582 ⟶ 584:
 
; Output 1
{{#invoke:Sports series|main|type=WNT|bold_winner=n
|LUX|5–6|''DEN''|3–3|2–3
|''ESP''|7–1|IRL|5–1|2–0
Line 589 ⟶ 591:
}}
 
; Usage 2 (third row overrides {{para|color_winner}}automatic coloring)
<pre>{{#invoke:Sports series|main|type=WNT|color_winner=y|bold_winner=n
|SWE|2–4|NOR|1–1|1–3
|LUX|5–5 ([[Away goals rule|a]])|''DEN''|3–3|2–2
Line 596 ⟶ 598:
}}</pre>
 
; Output 2 (third row overrides {{para|color_winner}}automatic coloring)
{{#invoke:Sports series|main|type=WNT|color_winner=y|bold_winner=n
|SWE|2–4|NOR|1–1|1–3
|LUX|5–5 ([[Away goals rule|a]])|''DEN''|3–3|2–2
Line 604 ⟶ 606:
 
; Usage 3
<pre>{{#invoke:Sports series|main|type=WNT|legs=0|bold_winner=n
|LUX|5–6|''DEN''
|''ESP''|7–1|IRL
Line 611 ⟶ 613:
 
; Output 3
{{#invoke:Sports series|main|type=WNT|legs=0|bold_winner=n
|LUX|5–6|''DEN''
|''ESP''|7–1|IRL