Modul:InfoboxEmlektabla

A modult a Modul:InfoboxEmlektabla/doc lapon tudod dokumentálni

local capiunto = require 'capiunto'

local p = {}

function p.main(frame)
	local args = frame:getParent().args
	local headerStyle
	if args.headerstyle and args.headerstyle ~= '' then
		headerStyle = string.format('background-color:%s;', args.headerstyle)
	else
		headerStyle = 'background-color:grey;'
	end
	local infobox = capiunto.create( {
		top = args.nev,
		topStyle = 'background:#476a4a; color: #fff; font-size: 135%; height: 40px; vertical-align: middle; font-weight: bolder; line-height: 1.2em;' ,
	} )
if args.kep ~= nil and args.kep ~= '' then infobox:addImage( args.kep, args.kepalairas ) end
if args.elhelyezkedese ~= nil and args.elhelyezkedese ~= '' then infobox:addWikitext( args.elhelyezkedese ) end
return infobox

end
 
return p