Content deleted Content added
S.A. Julio (talk | contribs) →Parameter list: add |
S.A. Julio (talk | contribs) update documentation |
||
Line 1:
{{Module rating|beta<!-- Values: pre-alpha • alpha • beta • release • protected • semiprotected -- If a rating not needed/relevant, delete this template call -->}}
<!-- Add categories where indicated at the bottom of this page and interwikis at Wikidata -->
This is a module for generating match results for a sports series, such as a [[two-legged tie]]. However, the module can support single-leg ties up to an unlimited number of legs. The template supports domestic and international
== Usage ==
Line 10:
<pre>{{#invoke:Sports series|main
|
}}</pre>
===
For two-legged ties in national team or domestic club football, five parameters are expected to be passed for each row. This includes each club's name, the aggregate score and the score of both legs. The parameter {{para|flag|n}} must be passed to disable the country flag parameter.
<pre>{{#invoke:Sports series|main|flag=n
|
}}</pre>
Line 41 ⟶ 28:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}</pre>
Line 49 ⟶ 36:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}
Line 69 ⟶ 56:
}}
===
; Usage
<pre>{{#invoke:Sports series|main|
|{{fb-rt|UKR}}|3–1|{{fb|SVN}}|2–0|1–1
|{{fb-rt|SWE}}|4–3|{{fb|DEN}}|2–1|2–2
|{{fb-rt|BIH}}|1–3|{{fb|IRL}}|1–1|0–2
|{{fb-rt|NOR}}|1–3|{{fb|HUN}}|0–1|1–2
}}</pre>
; Output
{{#invoke:Sports series|main|
|{{fb-rt|UKR}}|3–1|{{fb|SVN}}|2–0|1–1
|{{fb-rt|SWE}}|4–3|{{fb|DEN}}|2–1|2–2
|{{fb-rt|BIH}}|1–3|{{fb|IRL}}|1–1|0–2
|{{fb-rt|NOR}}|1–3|{{fb|HUN}}|0–1|1–2
}}
Line 111 ⟶ 81:
! Description
! Type
|-
|style="text-align:center;vertical-align:top"|{{TOC tab|flag}}
|style="background-color:#fff"|Determines the [[Wikipedia:WikiProject Flag Template|flag icon template]] which will be used in the table. The default
|style="background-color:#fff"|String
Line 141 ⟶ 99:
|[[Atlético Madrid]]|ESP|10–11|[[Borussia Dortmund]]|GER|2–1|2–4|2–1|2–4|2–1
|[[Real Madrid CF|Real Madrid]]|ESP|11–11 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1|3–3|1–1|3–3 {{aet}}
|[[Paris Saint-Germain
}}</pre>
Line 149 ⟶ 107:
|[[Atlético Madrid]]|ESP|10–11|[[Borussia Dortmund]]|GER|2–1|2–4|2–1|2–4|2–1
|[[Real Madrid CF|Real Madrid]]|ESP|11–11 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1|3–3|1–1|3–3 {{aet}}
|[[Paris Saint-Germain
}}
Line 158 ⟶ 116:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{aet}} {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG
|[[Paris Saint-Germain
}}</pre>
Line 166 ⟶ 124:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{aet}} {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG
|[[Paris Saint-Germain
}}
Line 298 ⟶ 256:
|style="text-align:center;vertical-align:top"|{{TOC tab|fill_blanks}}
|style="background-color:#fff"|To enable, set to a positive value (e.g. y, yes, 1). Adds a placeholder flag icon to the space next to a team's name when flag parameters are present in the table, but the parameter for a given team is left blank
|style="background-color:#fff"|String
Line 354 ⟶ 312:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}</pre>
Line 362 ⟶ 320:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}
Line 389 ⟶ 347:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}</pre>
Line 397 ⟶ 355:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}
Line 413 ⟶ 371:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}</pre>
Line 421 ⟶ 379:
|[[Atlético Madrid]]|ESP|4–5|[[Borussia Dortmund]]|GER|2–1|2–4
|[[Real Madrid CF|Real Madrid]]|ESP|4–4 {{pen|4–3}}|[[Manchester City F.C.|Manchester City]]|ENG|3–3|1–1 {{aet}}
|[[Paris Saint-Germain
}}
Line 433 ⟶ 391:
==== Example 10 ====
; Usage
<pre>{{#invoke:Sports series|main|
|{{fb-rt|POL}}|5–1|{{fb|EST}}
|{{fb-rt|WAL}}|4–1|{{fb|FIN}}
|{{fb-rt|WAL}}|0–0 {{aet}} {{pso|4–5}}|{{fb|POL}}
}}</pre>
; Output
{{#invoke:Sports series|main|
|{{fb-rt|POL}}|5–1|{{fb|EST}}
|{{fb-rt|WAL}}|4–1|{{fb|FIN}}
|{{fb-rt|WAL}}|0–0 {{aet}} {{pso|4–5}}|{{fb|POL}}
}}
Line 453 ⟶ 411:
Please note that in order to display a row in the table, at least one cell of said row must have value that is not empty or whitespace. Otherwise, the module will not create a row for that line and all others below it.
=== Team
=== Leg and aggregate scores ===
Line 534 ⟶ 490:
; Usage 3 (for nil)
<pre>{{#invoke:Sports series|main|
|{{fb-rt|LUX}}|5–6|{{fb|DEN}}|3–3|2–2|0–1
|{{fb-rt|ESP
|{{fb-rt|FRA}}|2–5|{{fb|HUN}}|1–3|1–2|nil
|{{fb-rt|SWE}}|2–4|{{fb|URS}}|1–1|1–3|nil
}}</pre>
; Output 3 (for nil)
{{#invoke:Sports series|main|
|{{fb-rt|LUX}}|5–6|{{fb|DEN}}|3–3|2–2|0–1
|{{fb-rt|ESP
|{{fb-rt|FRA}}|2–5|{{fb|HUN}}|1–3|1–2|nil
|{{fb-rt|SWE}}|2–4|{{fb|URS}}|1–1|1–3|nil
}}
=== Simplified anchor links ===
Pages utilizing this module often include a wikilink with an [[WP:ANCHOR|anchor]] to the scores of the legs of a tie, linking to full match summaries
Typically, when using anchored wikilinks, the page title can be omitted if the anchor appears on the same page. However, such links generally do not function properly when transcluded to other articles.
However, for this module, if any parameter contains an anchored wikilink that omits the page title (for example, <code><nowiki>[[#A vs B|2–2]]</nowiki></code>), the module will automatically insert the page title during transclusion to ensure proper linking. For proper functionality, the "sports series" module code must originate from the same page that contains the anchors.
=== Quasi-parameters ===
==== Plus sign (+) for
; Usage
<pre>{{#invoke:Sports series|main
|[[Atlético Madrid]]|ESP+1945|4–5|[[Borussia Dortmund]]|GER+empire|2–1|2–4
}}</pre>
; Output
{{#invoke:Sports series|main
|[[Atlético Madrid]]|ESP+1945|4–5|[[Borussia Dortmund]]|GER+empire|2–1|2–4
}}
==== Three apostrophes (<nowiki>'''</nowiki>) for manual bolding ====
While the template automatically bolds winning teams (unless {{para|bold_winner|n}}), in some situations the module will be unable to determine the winner. Or, some users may find it undesirable to have the module bold the winner automatically. In these cases, manual bolding can be used to indicate the winning team of a tie. This
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.
Line 632 ⟶ 535:
; Usage 1
<pre>{{#invoke:Sports series|main|
|{{fb-rt|LUX}}|5–6|'''{{fb|DEN}}'''|3–3|2–3
|'''{{fb-rt|ESP}}'''|7–1|{{fb|IRL}}|5–1|2–0
|{{fb-rt|FRA}}|2–5|'''{{fb|HUN}}'''|1–3|1–2
|{{fb-rt|SWE}}|2–4|'''{{fb|NOR}}'''|1–1|1–3
}}</pre>
; Output 1
{{#invoke:Sports series|main|
|{{fb-rt|LUX}}|5–6|'''{{fb|DEN}}'''|3–3|2–3
|'''{{fb-rt|ESP}}'''|7–1|{{fb|IRL}}|5–1|2–0
|{{fb-rt|FRA}}|2–5|'''{{fb|HUN}}'''|1–3|1–2
|{{fb-rt|SWE}}|2–4|'''{{fb|NOR}}'''|1–1|1–3
}}
; Usage 2 (third row overrides automatic bolding)
<pre>{{#invoke:Sports series|main|
|{{fb-rt|SWE}}|2–4|{{fb|NOR}}|1–1|1–3
|{{fb-rt|LUX}}|5–5 ([[Away goals rule|a]])|'''{{fb|DEN}}'''|3–3|2–2
|{{fb-rt|ESP}}|7–1|'''{{fb|IRL}}'''|5–1|2–0
}}</pre>
; Output 2 (third row overrides automatic bolding)
{{#invoke:Sports series|main|
|{{fb-rt|SWE}}|2–4|{{fb|NOR}}|1–1|1–3
|{{fb-rt|LUX}}|5–5 ([[Away goals rule|a]])|'''{{fb|DEN}}'''|3–3|2–2
|{{fb-rt|ESP}}|7–1|'''{{fb|IRL}}'''|5–1|2–0
}}
==== 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 color the winner automatically. In these cases, manual coloring can be used to indicate the winning team of a tie. This
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 671 ⟶ 574:
; Usage 1
<pre>{{#invoke:Sports series|main|
|{{fbw-rt|LUX}}|5–6|''{{fbw|DEN}}''|3–3|2–3
|''{{fbw-rt|ESP}}''|7–1|{{fbw|IRL}}|5–1|2–0
|{{fbw-rt|FRA}}|2–5|''{{fbw|HUN}}''|1–3|1–2
|{{fbw-rt|SWE}}|2–4|''{{fbw|NOR}}''|1–1|1–3
}}</pre>
; Output 1
{{#invoke:Sports series|main|
|{{fbw-rt|LUX}}|5–6|''{{fbw|DEN}}''|3–3|2–3
|''{{fbw-rt|ESP}}''|7–1|{{fbw|IRL}}|5–1|2–0
|{{fbw-rt|FRA}}|2–5|''{{fbw|HUN}}''|1–3|1–2
|{{fbw-rt|SWE}}|2–4|''{{fbw|NOR}}''|1–1|1–3
}}
; Usage 2 (third row overrides automatic coloring)
<pre>{{#invoke:Sports series|main|
|{{fbw-rt|SWE}}|2–4|{{fbw|NOR}}|1–1|1–3
|{{fbw-rt|LUX}}|5–5 ([[Away goals rule|a]])|''{{fbw|DEN}}''|3–3|2–2
|{{fbw-rt|ESP}}|7–1|''{{fbw|IRL}}''|5–1|2–0
}}</pre>
; Output 2 (third row overrides automatic coloring)
{{#invoke:Sports series|main|
|{{fbw-rt|SWE}}|2–4|{{fbw|NOR}}|1–1|1–3
|{{fbw-rt|LUX}}|5–5 ([[Away goals rule|a]])|''{{fbw|DEN}}''|3–3|2–2
|{{fbw-rt|ESP}}|7–1|''{{fbw|IRL}}''|5–1|2–0
}}
; Usage 3
<pre>{{#invoke:Sports series|main|
|{{fbw-rt|LUX}}|5–6|''{{fbw|DEN}}''
|''{{fbw-rt|ESP}}''|7–1|{{fbw|IRL}}
|{{fbw-rt|FRA}}|''2–2''|{{fbw|HUN}}
}}</pre>
; Output 3
{{#invoke:Sports series|main|
|{{fbw-rt|LUX}}|5–6|''{{fbw|DEN}}''
|''{{fbw-rt|ESP}}''|7–1|{{fbw|IRL}}
|{{fbw-rt|FRA}}|''2–2''|{{fbw|HUN}}
}}
|