Module:RoundN/sandbox: Difference between revisions

Content deleted Content added
test
Requested edit from talk page
Line 348:
'article_include',
'color',
'color_repechage',
'3rdplace',
'omit_blanks',
Line 533 ⟶ 534:
col.top = m.num
p.span = p.tCols > c and bump * 2 or p.branch_upwards or math.max((bump - 1) / 2, 2)
col.color_repechage = p['color_repechage'] and ((c == p.tCols) or ((c == p.tCols-1) and skipMatch[math.pow(2, p.tCols) - 1]))
col.show3rd = p['3rdplace'] and c == p.tCols and rowNum.third
local colorFinal, bumpMid = p.color and c == p.tCols, p.span > 0 and mw.clone(bumpBase):attr{rowspan = p.span} or nil
Line 651 ⟶ 653:
else
if m.showBox[m.phase] then
if col.color_repechage then
col.color_repechage = 2
end
if p.bold then
if m.bold.win(m.phase) and (colorFinal or col.color_repechage) then
color_index = 1 + (col.show3rd or 0) + (col.color_repechage or 0)
elseif m.bold.box[#m.nonEmpty] then
color_index = 2 + (col.show3rd or 0) + (col.color_repechage or 0)
else
color_index = 2 + (col.show3rd or 0)4
end
p.teamBoxCSS = (colorFinal or col.color_repechage) and
{border = p.teamBoxNormal.border, background = p.bgColor[color_index]}
or p.teamBoxNormal
else
p.teamBoxCSS = (colorFinal or col.color_repechage) and
{border = p.teamBoxNormal.border, background = p.bgColor[m.phase + (col.show3rd or 0) + (col.color_repechage or 0)]}
or p.teamBoxNormal
end