local pp =
local mParent = require('Module:Sandbox/McVahl/sometest')
local rdrobin, multirb
local tblkey =
function pp.defaults(args,yesno,color_map) rdrobin = tonumber(args['rdrobin'] or 1) multirb = rdrobin >= 2 local legendtype = args['legend'] or 'BSK' local opt_colors = local colors = mw.text.split(mw.ustring.gsub(tblkey[legendtype], '', ' function pp.addtl_args(k) return k 'legend' or k 'rdrobin' or k function pp.get_argvalues_for_maxround(args,x,del) del = del or return args['pos' .. del .. x] or args['res' .. del .. x] or end function pp.get_rounds_or_maxrounds(rounds,maxrounds,args,team_list) if multirb then return (#team_list - 1) * rdrobin end return mParent.get_rounds_or_maxrounds(rounds,maxrounds)end function pp.header(root,args,labels,maxrounds,navbar,team_list,firstround) local row = root:tag('tr') row:tag('th') :css('white-space', 'nowrap'):cssText('style') :wikitext((not multirb and (args['header'] or labels['teamround']) or ' ') .. navbar) -- if not a single round-robin if (multirb) then for r=1,rdrobin do row:tag('th') :addClass('sportsrbrtable-rnd') :attr('scope', 'col') :attr('colspan', #team_list - 1) :wikitext('Round ' .. r) end row = root:tag('tr') row:tag('th') :css('white-space', 'nowrap'):cssText('style') :wikitext(args['header'] or labels['teamround']) end for r=1,maxrounds do row:tag('th') :addClass('sportsrbrtable-rnd') :attr('scope', 'col') :css('width', (args['ticon'] function pp.rowtext(frame,args,legend_symbols,posrt,opprt) if args['ticon'] then return frame:expandTemplate else return opprt end return legend_symbols[posrt] or posrtend function pp.rowbg(posrc,opprt) return (opprt ~= ) and posrc or end function pp.legendtext(legend_symbols,v) return ' 'end return pp'style' or k
'sched' or k
'ticon'end
nil) and (args['rdwidth'] or '35px') or nil) :wikitext(args['rnd' .. (r + (firstround - 1))] or (r + (firstround - 1))) end return rowend