Module:Infobox military conflict: Difference between revisions
m
1 revision imported
Squareblob (talk | contribs) m (1 revision imported) |
Squareblob (talk | contribs) m (1 revision imported) |
||
(One intermediate revision by one other user not shown) | |||
Line 2:
local infoboxStyle = mw.loadData('Module:WPMILHIST Infobox style')
local templatestyles = 'Module:Infobox military conflict/styles.css'
local IMC = {}
Line 94 ⟶ 95:
:done()
:tag('td')
:tag('
:addClass('location')
:wikitext(self.args.place or '{{{place}}}') -- hack so that people who don't know Lua know that this parameter is required
Line 142 ⟶ 143:
-- this should be the same as using {{stack|clear=right|...}}
builder = builder:tag('div')
:addClass('mw-stack
:tag('div')
:css('overflow', 'hidden')
Line 152 ⟶ 150:
builder = builder:tag('table')
:addClass('infobox vevent')
:cssText(infoboxStyle.
:css('width', self.args.width or
builder:tag('tr')
Line 213 ⟶ 211:
:attr('colspan', self.combatants)
:css('border-top', infoboxStyle.internal_border)
self.args.map_type,
▲ :node(require('Module:Location map').main(self.frame, {
▲ .. (require('Module:Location map').data(self.frame, {self.args.map_type, 'name'})))
▲ }))
end
builder = builder:done()
Line 268 ⟶ 265:
function p.main(frame)
return frame:extensionTag{ name = 'templatestyles', args = { src = templatestyles} } .. tostring(IMC.new(frame):render())
end
|