Module:Infobox Test: Difference between revisions
From Bibliotheca Anonoma
Antonizoon (talk | contribs) No edit summary |
Antonizoon (talk | contribs) No edit summary |
||
Line 6: | Line 6: | ||
top = tostring(mw.title.getCurrentTitle()), | top = tostring(mw.title.getCurrentTitle()), | ||
topStyle = 'background:#cfc;', | topStyle = 'background:#cfc;', | ||
bottom = frame.args[ | bottom = frame.args["description"]; -- description | ||
} ) | } ) | ||
:addImage( | :addImage( | ||
string.format('[[File:%s|200px]]', frame.args[ | string.format('[[File:%s|200px]]', frame.args["img_url"]), -- featured image | ||
frame.args[ | frame.args["caption"] -- caption | ||
) | ) | ||
:addRow('URL', frame.args[ | :addRow('URL', frame.args["url"]) | ||
:addRow('Project Status', frame.args[ | :addRow('Project Status', frame.args["project_status"]) | ||
:addRow('Archiving Status', frame.args[ | :addRow('Archiving Status', frame.args["archiving_status"]) | ||
:addRow('Project Source', frame.args[ | :addRow('Project Source', frame.args["project_source"]) | ||
end | end | ||
return p | return p |
Revision as of 19:46, 8 January 2017
Documentation for this module may be created at Module:Infobox Test/doc
local p = {}
function p.run(frame)
local capiunto = require 'capiunto'
return capiunto.create( {
top = tostring(mw.title.getCurrentTitle()),
topStyle = 'background:#cfc;',
bottom = frame.args["description"]; -- description
} )
:addImage(
string.format('[[File:%s|200px]]', frame.args["img_url"]), -- featured image
frame.args["caption"] -- caption
)
:addRow('URL', frame.args["url"])
:addRow('Project Status', frame.args["project_status"])
:addRow('Archiving Status', frame.args["archiving_status"])
:addRow('Project Source', frame.args["project_source"])
end
return p