Modulo:Vedi anche/sandbox: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
m +trim |
carico CSS da foglio di stile esterno |
||
Riga 35:
-- @return {string}
local function buildHTML(wikitext, withNoprint)
local tableNode = mw.html.create('table')
tableNode
:addClass('vedi-anche')
:addClass(withNoprint and 'noprint' or nil)
:tag('tr')
:tag('td')
:wikitext('[[File:Magnifying glass icon mgx2.svg|20px|class=noviewer|link=]]')
:done()
:tag('td')
:wikitext(string.format("''Lo stesso argomento in dettaglio: %s''.", wikitext))
:done()
Line 67 ⟶ 58:
-- Funzione per il template {{Vedi anche sezione}}.
function p.sezione(frame)
local styles = 'Modulo:Vedi anche/sandbox/styles'
local arg = frame:getParent().args[1]
local wlink = arg and string.format("'''[[#%s|%s]]'''", arg, arg) or ''
return
name = 'templatestyles',
args = {src = styles}
} .. buildHTML('sezione ' .. wlink)
end
Line 75 ⟶ 70:
function p.main(frame)
local lastArg, conjunction
local styles = 'Modulo:Vedi anche/sandbox/styles'
local args = {}
Line 88 ⟶ 84:
end
return frame:extensionTag{
return buildHTML(mw.text.listToText(args, ', ', conjunction), true)▼
name = 'templatestyles',
args = {src = styles}
end
|