Content deleted Content added
clean |
move css |
||
Line 80:
local function renderMainHeading(builder, colspan, headingText, borderTop)
builder:tag('tr')
:addClass('vgr-main-heading')
:tag('th')
:attr('colspan', colspan)
:attr('scope', colspan == 1 and 'col' or 'colgroup')
:css('border-top', borderTop)
:wikitext(headingText)
Line 91 ⟶ 92:
renderMainHeading(builder, #activeSystems + 1, mainHeading)
builder:tag('tr')
:addClass('vgr-systems')
:tag('th')
:attr('rowspan', '2')
:
:wikitext(data.i18n.publication)
:done()
:tag('th')
:attr('colspan', #activeSystems)
:attr('scope', #activeSystems == 1 and 'col' or 'colgroup')
:wikitext(data.i18n.score)
:done()
builder = builder:tag('tr')
for _, v in ipairs(activeSystems) do
builder:tag('th')
:wikitext(data.systems[v].name) :done()
end
end
Line 113 ⟶ 115:
renderMainHeading(builder, 2, mainHeading)
builder:tag('tr')
:addClass('vgr-hrow')
:tag('th')
:wikitext(nameHeading)
:done()
:tag('th')
:wikitext(data.i18n.score)
:done()
end
local function renderRatingsBySystem(builder, code, name, activeSystems, args, na)
builder = builder:tag('tr'):addClass('vgr-ratings')
builder:tag('td')
:wikitext(name)
Line 137 ⟶ 136:
if args[combinedCode] then
cell
:wikitext(args[combinedCode])
:done()
elseif na then
cell
:addClass('table-na')
:wikitext(data.i18n.na)
Line 154 ⟶ 148:
local function renderRating(builder, name, rating)
builder:tag('tr'):addClass('vgr-rating')
:tag('td')
:wikitext(name)
:done()
:tag('td')
:wikitext(rating)
:done()
Line 169 ⟶ 160:
activeSystems, customAggregatorKeys, customReviewerKeys, args)
builder = builder:tag('table')
:
▲ :css('width', '100%')
▲ :css('margin', '0em')
if args.state then builder:addClass('mw-collapsible-content') end
Line 239 ⟶ 226:
local function renderAwards(builder, args, awardKeys, borderTop)
builder = builder:tag('table')
:
▲ :css('margin', '0')
:css('border-top', borderTop)
:attr('cellpadding', 3)▼
:attr('cellspacing', 0)▼
if args.state then builder:addClass('mw-collapsible-content') end
Line 251 ⟶ 235:
:tag('th')
:wikitext(data.i18n.publication)
:done()
:tag('th')
:wikitext(data.i18n.award)
:done()
for _, v in ipairs(awardKeys) do
builder:tag('tr')
:tag('td')
:wikitext(args[v .. 'Pub'])
:done()
:tag('td')
:wikitext(args[v])
:done()
end
builder:done()
Line 402 ⟶ 387:
local providedReviewers, providedAggregators = getProvidedReviewersAndAggregators(args, #activeSystems ~= 0)
local wikidata = checkForWikidata(frame, args, activeSystems, providedAggregators)
if #customAggregatorKeys ~= 0 or #customReviewerKeys ~= 0 or
#providedAggregators ~= 0 or #providedReviewers ~= 0 or #awardKeys ~= 0 then return frame:extensionTag{
name='templatestyles', args = { src = data.i18n.templatestyles }
|