Open main menu
Home
Random
Donate
Recent changes
Special pages
Community portal
Preferences
About Stockhub
Disclaimers
Search
User menu
Talk
Contributions
Create account
Log in
Editing
Module:Sports rbr table/doc
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
{{Module rating |beta}} {{Lua|Module:If preview|Module:Yesno|Module:Arguments}} {{Uses TemplateStyles |Module:Sports rbr table/styles.css}} == Usage == '''Position tables''' <syntaxhighlight lang=moin> {{#invoke:Sports rbr table|table | sortable = <!-- y or n or omit --> | team1 = | pos1 = <!-- 1 / 2 / 3 / 4 / ... --> | team2 = | pos2 = <!-- 1 / 2 / 3 / 4 / ... --> <!-- ... --> | color_1 = 1st | text_1 = 1st place | source = }}</syntaxhighlight> '''WDL tables''' <syntaxhighlight lang=moin> {{#invoke:Sports rbr table|table | sortable = <!-- y or n or omit --> | team1 = | res1 = <!-- W / D / L ... --> | team2 = | res2 = <!-- W / D / L ... --> <!-- ... --> | color_W = green2 | color_D = yellow2 | color_L = red2 | source = }}</syntaxhighlight> === Style === The <code>XXX</code> in <code>style=XXX</code> is to be replaced by one of the following available styles: * [[Module:Sports rbr table/matchup|matchup]] β for tables showing matchups and head-to-head results === Parameters === {| class="wikitable" |- ! colspan=2 | General parameters |- ! Parameter !! Description |- | <code>title</code> || A top caption for the table, omit for no title. |- | <code>sortable</code> || Is the table sortable? Set to <code>y</code> for a sortable table, and omit for unsortable. |- | <code>color_X</code> || The background color for position <code>X</code>. Here, <code>X</code> can be a single number (e.g., <code>1</code> for position 1), or a non-numeric value corresponding to a position used in the table (e.g., <code>R</code> for relegated or <code>W</code> for withdrew ...) See the [[#Color|color]] section below for more information on color syntax. |- | <code>color_-3</code> || The background color for position 1, 2, and 3. See the [[#Color|color]] section below for more information on color syntax. |- | <code>color_15-</code> || The background color for position 15, 16, .... See the [[#Color|color]] section below for more information on color syntax. |- | <code>text_Y</code> || Legend text for <code>color_Y</code>. Adding any legend text will trigger the inclusion of a legend at the bottom of the table. |- | <code>source</code> || Source for the information in the table. |- | <code>notes</code> || Any additional notes at add to the foot of the table. |- | <code>update</code><br /><code>start_date</code> || Date of the last round of matches included in the table. If the table is complete, use {{para|update|complete}}. If the matches will occur at a future date, use {{para|update|future}} and {{para|start_date}} for the date of the first round of matches. |- | <code>legendpos</code> || Position for the legend. Supported values include <code>tr</code> (top right), <code>br</code> (bottom right), <code>tl</code> (top left), <code>bl</code> (bottom left), <code>t</code> (top), and <code>b</code> (bottom). |- | <code>legendorder</code> || The order for the entries in the legend (e.g., {{para|legendorder|W/D/L}}). |- | <code>toptext</code> || Text to include at the top of the table. This is useful when {{para|legendpos|tr}} and you wish to have the legend float next to text at the top. |- | <code>header</code> || Text for the team column header. The default is <code>Team β² Round</code>. |- | <code>labelalign</code> || Alignment for the column labels. The default is <code>left</code>. |- | <code>firstround</code> || The number of the first round. The default is <code>1</code>. |- | <code>rnd1</code> || Text to use for the label for round 1. The default is <code>1</code>. |- | <code>splitN</code> || A line can be added between section of the table (if desired) by adding {{para|splitN|yes}} with N the position below which the bar should be shown. |- ! colspan=2 | Compact syntax |- ! Parameter !! Description |- | <code>team1</code> || The wikilinked name of the first team. For additional teams, use <code>team2</code>, <code>team3</code>, ... For a temporary place holder, use {{para|team1|-}} or {{para|team1|&nbsp;}} or {{para|team1|&ensp;}} or {{para|team1|TBA}}. |- | <code>pos1</code> || The forward slash (<code>/</code>) delimited list of round-by-round positions for the first team. For example, {{para|pos1|1/2/3/8/3/2/1}} for seven rounds with the position changing from 1 to 2 to 3 to 8 to 3 to 2 to 1. |- | <code>pos1_rnd3_note</code> || A footnote to append the 3rd position in the <code>pos1</code> positions. |- | <code>res1</code> || The forward slash (<code>/</code>) delimited list of match results for the first team. For example, {{para|res1|W/D/D/W/L}} for five rounds with the round-by-round results of win, draw, draw, win, loss. Note, this parameter cannot be used if {{para|pos1}} is being used. |- | <code>res1_rnd3_note</code> || A footnote to append the 3rd result in the <code>res1</code> match results. |- ! colspan=2 | [[Module:Sports table|Sports table]] syntax |- ! Parameter !! Description |- | <code>team1</code> || this can be abbreviation for the first team. The remainder of the documentation in this section assumes the abbreviation is <code>ABC</code>. For additional teams, use <code>team2</code>, <code>team3</code>, ... |- | <code>name_ABC</code> || The wikilinked name of team <code>ABC</code> |- | <code>pos_ABC</code> || The forward slash (<code>/</code>) delimited list of round-by-round positions for team <code>ABC</code>. For example, {{para|pos_ABC|1/2/3/8/3/2/1}} for seven rounds with the position changing from 1 to 2 to 3 to 8 to 3 to 2 to 1. |- | <code>res_ABC</code> || The forward slash (<code>/</code>) delimited list of match results for team <code>ABC</code>. For example, {{para|res_ABC|W/D/D/W/L}} for five rounds with the round-by-round results of win, draw, draw, win, loss. Note, this parameter cannot be used if {{para|pos_ABC}} is being used. |} === Color === The module has several preset background colors that have acceptable contrast with black foreground text. It is recommended to use one of these colors, which match colors used by [[Module:Sports table]]. {| class="wikitable" style="float:left; margin-right:1em;" ! Name !! Hex value |- | style="background-color:#BBF3BB" | green1 || BBF3BB |- | style="background-color:#CCF9CC" | green2 || CCF9CC |- | style="background-color:#DDFCDD" | green3 || DDFCDD |- | style="background-color:#EEFFEE" | green4 || EEFFEE |- | style="background-color:#BBF3FF" | blue1 || BBF3FF |- | style="background-color:#CCF9FF" | blue2 || CCF9FF |- | style="background-color:#DDFCFF" | blue3 || DDFCFF |- | style="background-color:#EEFFFF" | blue4 || EEFFFF |} {| class="wikitable" style="float:left; margin-right:1em;" ! Name !! Hex value |- | style="background-color:#FFFFBB" | yellow1 || FFFFBB |- | style="background-color:#FFFFCC" | yellow2 || FFFFCC |- | style="background-color:#FFFFDD" | yellow3 || FFFFDD |- | style="background-color:#FFFFEE" | yellow4 || FFFFEE |- | style="background-color:#FFBBBB" | red1 || FFBBBB |- | style="background-color:#FFCCCC" | red2 || FFCCCC |- | style="background-color:#FFDDDD" | red3 || FFDDDD |- | style="background-color:#FFEEEE" | red4 || FFEEEE |} {| class="wikitable" style="float:left; margin-right:1em;" ! Name !! Hex value |- | style="background-color:#BBBBBB" | black1 || BBBBBB |- | style="background-color:#CCCCCC" | black2 || CCCCCC |- | style="background-color:#DDDDDD" | black3 || DDDDDD |- | style="background-color:#EEEEEE" | black4 || EEEEEE |- | style="background-color:#FFD700" | 1st || FFD700 |- | style="background-color:#C0C0C0" | 2nd || C0C0C0 |- | style="background-color:#CC9966" | 3rd || CC9966 |}{{clear left}} In some rare cases, it may be necessary to override the background color for a particular cell. This can be accomplished using {{para|posX_rndY_color}} or {{para|resX_rndY_color}} where <code>X</code> is the row number, and <code>Y</code> is the round number. == Examples == === Example 1: Compact positions syntax === {{#invoke:Sports rbr table|table | title = Example 1 | sortable = y | team1 = A Team | pos1 = 1/2/2/2/2 | team2 = B Team | pos2 = 2/1/4/4/4 | team3 = C Team | pos3 = 3/4/1/6/1 | team4 = D Team | pos4 = 4/3/6/1/3 | team5 = E Team | pos5 = 5/6/3/8/7 | team6 = F Team | pos6 = 6/5/8/3/5 | team7 = G Team | pos7 = 7/8/5/5/8 | team8 = H Team | pos8 = 8/7/7/7/6 | color_1 = 1st | text_1 = First place | color_2 = green1 | text_2 = Promoted | color_3-4 = blue2 | text_3-4 = Championship League | color_7- = red1 | text_7- = Relegated | source = Some source }} <syntaxhighlight lang=moin> {{#invoke:Sports rbr table|table | title = Example 1 | sortable = y | team1 = A Team | pos1 = 1/2/2/2/2 | team2 = B Team | pos2 = 2/1/4/4/4 | team3 = C Team | pos3 = 3/4/1/6/1 | team4 = D Team | pos4 = 4/3/6/1/3 | team5 = E Team | pos5 = 5/6/3/8/7 | team6 = F Team | pos6 = 6/5/8/3/5 | team7 = G Team | pos7 = 7/8/5/5/8 | team8 = H Team | pos8 = 8/7/7/7/6 | color_1 = 1st | text_1 = First place | color_2 = green1 | text_2 = Promoted | color_3-4 = blue2 | text_3-4 = Championship League | color_7- = red1 | text_7- = Relegated | source = Some source }}</syntaxhighlight> === Example 2: Sports table positions syntax === {{#invoke:Sports rbr table|table | title = Example 2 | sortable = y | team1 = AAA | team2 = BBB | team3 = CCC | team4 = DDD | team5 = EEE | team6 = FFF | team7 = GGG | team8 = HHH | name_AAA = A Team | pos_AAA = 1/2/2/2/2 | name_BBB = B Team | pos_BBB = 2/1/4/4/4 | name_CCC = C Team | pos_CCC = 3/4/1/6/1 | name_DDD = D Team | pos_DDD = 4/3/6/1/3 | name_EEE = E Team | pos_EEE = 5/6/3/8/7 | name_FFF = F Team | pos_FFF = 6/5/8/3/5 | name_GGG = G Team | pos_GGG = 7/8/5/5/8 | name_HHH = H Team | pos_HHH = 8/7/7/7/6 | color_1 = 1st | text_1 = First place | color_2 = green1 | text_2 = Promoted | color_3-4 = blue2 | text_3-4 = Championship League | color_7- = red1 | text_7- = Relegated | source = Some source }} <syntaxhighlight lang=moin> {{#invoke:Sports rbr table|table | title = Example 2 | sortable = y | team1 = AAA | team2 = BBB | team3 = CCC | team4 = DDD | team5 = EEE | team6 = FFF | team7 = GGG | team8 = HHH | name_AAA = A Team | pos_AAA = 1/2/2/2/2 | name_BBB = B Team | pos_BBB = 2/1/4/4/4 | name_CCC = C Team | pos_CCC = 3/4/1/6/1 | name_DDD = D Team | pos_DDD = 4/3/6/1/3 | name_EEE = E Team | pos_EEE = 5/6/3/8/7 | name_FFF = F Team | pos_FFF = 6/5/8/3/5 | name_GGG = G Team | pos_GGG = 7/8/5/5/8 | name_HHH = H Team | pos_HHH = 8/7/7/7/6 | color_1 = 1st | text_1 = First place | color_2 = green1 | text_2 = Promoted | color_3-4 = blue2 | text_3-4 = Championship League | color_7- = red1 | text_7- = Relegated | source = Some source }}</syntaxhighlight> === Example 3: Team combined table === {{#invoke:sports rbr table|table |title=Example 3 |header=Round |label1= Ground | res1= H/ A/ A/ H/ A/ H/ A/ H/ H/ A/ A/ H/ H/ A/ H/ A/ A/ H/ H/ A/ A |label2= Result | res2= W/ L/ L/ W/ W/ D/ W/ L/ L/ L/ L/ W/ W/ W/ W/ L/ D/ L/ L/ D/ L |label3= Position | pos3= 4/10/14/ 8/ 6/ 7/ 7/ 8/ 9/10/11/11/ 8/ 7/ 6/ 6/ 6/ 7/ 9/ 9/ 9 | color_W = green2| color_D = yellow2| color_L = red2 | color_1=green1| color_2=green2| color_3-4=green3 | color_5-7=blue1| color_18-=red1 | source = Some source }} <syntaxhighlight lang=moin> {{#invoke:sports rbr table|table |title=Example 3 |header=Round |label1= Ground | res1= H/ A/ A/ H/ A/ H/ A/ H/ H/ A/ A/ H/ H/ A/ H/ A/ A/ H/ H/ A/ A |label2= Result | res2= W/ L/ L/ W/ W/ D/ W/ L/ L/ L/ L/ W/ W/ W/ W/ L/ D/ L/ L/ D/ L |label3= Position | pos3= 4/10/14/ 8/ 6/ 7/ 7/ 8/ 9/10/11/11/ 8/ 7/ 6/ 6/ 6/ 7/ 9/ 9/ 9 | color_W = green2| color_D = yellow2| color_L = red2 | color_1=green1| color_2=green2| color_3-4=green3 | color_5-7=blue1| color_18-=red1 | source = Some source }}</syntaxhighlight> === Example 4: Team combined table with a legend === {{#invoke:sports rbr table|table|legendpos=b |title=Example 4 |header=Round |label1= Ground | res1= H/ A/ A/ H/ A/ H/ A/ H/ H/ A/ A/ H/ H/ A/ H/ A/ A/ H/ H/ A/ A |label2= Result | res2= W/ L/ L/ W/ W/ D/ W/ L/ L/ L/ L/ W/ W/ W/ W/ L/ D/ L/ L/ D/ L |label3= Position | pos3= 4/10/14/ 8/ 6/ 7/ 7/ 8/ 9/10/11/11/ 8/ 7/ 6/ 6/ 6/ 7/ 9/ 9/ 9 <!-- --> | color_W = green2|text_W=Win | color_D = yellow2|text_D=Draw | color_L = red2|text_L=Loss | text_H = Home|text_A = Away | color_1=green1| color_2=green2| color_3-4=green3 | color_5-7=blue1| color_18-=red1 | source = Some source }} <syntaxhighlight lang=moin> {{#invoke:sports rbr table|table|legendpos=b |title=Example 4 |header=Round |label1= Ground | res1= H/ A/ A/ H/ A/ H/ A/ H/ H/ A/ A/ H/ H/ A/ H/ A/ A/ H/ H/ A/ A |label2= Result | res2= W/ L/ L/ W/ W/ D/ W/ L/ L/ L/ L/ W/ W/ W/ W/ L/ D/ L/ L/ D/ L |label3= Position | pos3= 4/10/14/ 8/ 6/ 7/ 7/ 8/ 9/10/11/11/ 8/ 7/ 6/ 6/ 6/ 7/ 9/ 9/ 9 <!-- --> | color_W = green2|text_W=Win | color_D = yellow2|text_D=Draw | color_L = red2|text_L=Loss | text_H = Home|text_A = Away | color_1=green1| color_2=green2| color_3-4=green3 | color_5-7=blue1| color_18-=red1 | source = Some source }}</syntaxhighlight> == See also == * [[Module:Sports table]] * [[Module:Sports results]] == Tracking category == * {{clc|Pages using sports rbr table with dubious updated parameter}} (pages where the updated date does not match the parent page name) * {{clc|Pages using sports rbr table with legendorder}} (pages where the {{para|legendorder}} parameter is used) * {{clc|Pages using sports rbr table with rnd parameters}} (pages where the {{para|rnd1}} parameter is used and may be converted to {{para|firstround}}) * {{clc|Pages using sports rbr table with unsupported parameters}} (pages where unsupported parameters are used, or where the {{para|header}} is potentially missing) * {{clc|Pages using sports rbr table with conflicting parameters}} * {{clc|Pages using sports rbr table with an undescribed result}} * {{clc|Pages using sports rbr table with an unusual source}} * {{clc|Pages using sports rbr table with unequal row lengths}} * {{clc|Pages using sports rbr table with per team and round coloring}} <includeonly>{{Sandbox other|| <!-- Categories below this line; interwikis at Wikidata --> [[Category:Sports modules]] }}</includeonly>
Summary:
Please note that all contributions to Stockhub may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Stockhub:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Templates used on this page:
Template:Clc
(
edit
)
Template:Clear left
(
edit
)
Template:Lua
(
edit
)
Template:Module rating
(
edit
)
Template:Para
(
edit
)
Template:Refbegin
(
edit
)
Template:Refbegin/styles.css
(
edit
)
Template:Refend
(
edit
)
Template:Uses TemplateStyles
(
edit
)
Module:Arguments
(
edit
)
Module:Sports rbr table
(
edit
)
Module:Sports rbr table/styles.css
(
edit
)
Module:Yesno
(
edit
)