Content deleted Content added
all done |
swap to divs |
||
Line 106:
end
local root = mw.html.create('
root:addClass('progression-rainbow')
for _, class in ipairs(classes) do
if class.count ~= 0 then
local percentage = class_percent(class.count, total)
root:newline() -- sprinkled through to make the HTML easier to read
root:tag('
:css('background', frame:expandTemplate{
title = 'class/colour', args = { class.class }
Line 136 ⟶ 129:
local remaining = percent_remaining(sum_classes, total)
if remaining then
root:tag('
:addClass('remaining')
:css('width', remaining)
|