Modulo:TeamBracket: differenze tra le versioni

Contenuto cancellato Contenuto aggiunto
m fix
m cleanup
Riga 46:
s1 = mw.ustring.gsub(s1 or '', '^[\'%s]*([%d%.]*).-$', '%1')
s2 = mw.ustring.gsub(s2 or '', '^[\'%s]*([%d%.]*).-$', '%1')
 
if s1 ~= '' and s2 ~= '' then
s1 = tonumber(s1)
Riga 85:
if k:find('^[R3][Dr][d1-9]b?%-[a-z][a-z]*00*') then
k = mw.ustring.gsub(k, '^([R3][Dr][d1-9]b?%-[a-z][a-z]*)00*', '%1')
if (teams < 10) then
tcats = tcats .. '[[Categoria:Errori nella compilazione di TeamBracket|P]]'
end
Riga 319:
return nil
else
local cell = addBlank(index,
{['border-width'] = '0',
['border-style'] = 'solid',
Riga 337:
-- seed value for the paired team
local otherteam = team % 2 == 0 and team-1 or team+1
local pairSeedArg = otherbye and ''
or getTeamArg(round, 'seed', otherteam)
-- show seed if seed is defined for either or both
Riga 357:
teamArg = '&nbsp;'
end
 
if not showSeed and (not hideSeeds) then
tcs = tcs + 1
Riga 379:
local fw = nil
local agg = legs[round] > 1 and s == legs[round] and true or false
local score1 = (agg and getScoreArg(round, team, 'agg') or nil) or
getScoreArg(round, team, s) or ((legs[round] == 1) and getScoreArg(round, team)) or nil
local score2 = (agg and getScoreArg(round, otherteam, 'agg') or nil) or
getScoreArg(round, otherteam, s) or ((legs[round] == 1) and getScoreArg(round, otherteam)) or nil
local showscore = true
if agg and aggregate ~= '' and score1 == nil and hassum then
score1 = (aggregate == 'score') and sumscore
or ((aggregate == 'legs' or aggregate == 'sets') and wins)
or nil
Riga 407:
othersumscore = sumScores(othersumscore, score2)
if winner == 1 then
if boldwinner ~= '' or (agg and (aggregate == 'score' or aggregate == 'legs' or aggregate == 'sets')) then
if agg and (aggregate == 'legs' or aggregate == 'sets') and (wins <= (legs[round] - 1)/2) then
else
Riga 532:
group = group + 1
end
blank = addBlank(offset,
{['border-width'] = '0',
['border-style'] = 'solid',
Riga 538:
height, 1)
else
blank = addBlank(offset,
{['border-width'] = '0',
['border-style'] = 'solid',
Riga 603:
addBlank(i, {
['border-color'] = 'black',
['border-style'] = 'solid',
['border-width'] = '0 ' .. w .. ' 0 0'})
else
Riga 615:
addBlank(i+1, {
['border-color'] = 'black',
['border-style'] = 'solid',
['border-width'] = '0 ' .. w .. ' 0 0'})
else
Riga 701:
end
end
 
for r = 1, maxround do
local roundFromLast = rounds - r + 1
Riga 821:
parseSeedmap(args['RD1-omit'])
parseLegs(args.sets or args.legs)
 
if autoSeeds then
-- set default seeds for round 1
Riga 844:
tbl:css('white-space', 'nowrap')
end
 
if align == 'right' then
tbl:css('float', 'right')