Module:VerticalGrid
Documentation for this module may be created at Module:VerticalGrid/doc
local p = {}
function p.rowNumbers(frame)
local args = frame:getParent().args
local res = ""
local function addRow(s)
res = res .. frame:expandTemplate{
title = "VerticalGridCell",
args = {s, class = "vgc-row-number"}
}
end
if type(args.heading) == "string" then
addRow(args.heading)
end
for i = 1, tonumber(args[1]) or 0 do
addRow(i)
end
return res
end
return p