Module:History
From Vintage Story Wiki
Documentation for this module may be created at Module:History/doc
local p = {}
function p.create(f)
local args = require( 'Module:ProcessArgs' ).merge( true )
local header = {
'{|class="wikitable"',
'!colspan="3"|History',
'|-'
}
if args.header then
return table.concat(header, '\n')
end
local footer = '|}'
if args.footer then
return footer
end
local parentVer = args[1] or ''
local childVer = args[2]
local child = '[[' .. childVer .. ']]'
local parent
local body
if parentVer then
parent = '[[' .. parentVer .. ']]'
body = {
'|' .. parent .. '||' .. child .. '||' .. args[3]
}
else
body = '|' .. child .. notes
end
return body
end
return p