Modulo:Citazione: differenze tra le versioni
Contenuto cancellato Contenuto aggiunto
correggo resa grafica degli archivi; aggiungo decodifica della data archivio + categorie per parametri deprecati; gestisco codici lingua con virgola |
fix spazio tra icona ed eventuale codice lingua; rimuovo categoria di errore obsoleta; prevedo formato "html" come da discussione |
||
Riga 870:
===============================================================================]]
local function get_format(format, url)
if format:lower() == 'html' then
return ''
if not cfg.external_link_type[
if not cfg.external_link_type[
return ''
end
Riga 883:
-- Se il formato esterno è tra quelli previsti imita lo stile dei template {{PDF}} o {{doc}}
local f = cfg.external_link_type[
if f then
return mw.ustring.format(' (<span style="font-weight: bolder; font-size:80%%"><abbr title="%s">%s</abbr></span>)', f.text, f.label)
else
table.insert( z.message_tail, { set_error('unknown_format',
return mw.ustring.format(' (%s)',
end
end
Riga 1 392:
else
local frame_lingue = {return_error='true'}
lingua = mw.text.trim(lingua)
if lingua ~= '' then
frame_lingue[#frame_lingue+1] = lingua
end
end
if #frame_lingue > 1 or (#frame_lingue==1 and frame_lingue[1]:lower()~="it") then
Riga 1 600 ⟶ 1 593:
local text = Language_code .. tostring(fragment_citation)
--aggiungo l'icona per cita video
if config.CitationClass == "video" then text = cfg.messages['icon_video'] .. ' ' .. text end
if config.CitationClass == "audio" then text = cfg.messages['icon_audio'] .. ' ' .. text end
-- Now enclose the whole thing in a <span/> element
|