Module:InfoboxHero: Difference between revisionsGive feedback
Jump to navigation
Jump to search
add tooltips (the fancy template style) |
change tooltip type (the boring html title style) |
||
| Line 616: | Line 616: | ||
local tr = tbl:tag('tr') | local tr = tbl:tag('tr') | ||
local label = dict_module.translate(row.label_dict) | local label = dict_module.translate(row.label_dict) | ||
local label_cell = tr:tag('td') | |||
if row.tooltip then | if row.tooltip then | ||
label_cell:attr('title', row.tooltip) | |||
end | end | ||
if row.link then | if row.link then | ||
label_cell:wikitext(string.format('[[%s|<span>%s</span>]]:', | |||
page_link(ctx, row.link), label)) | page_link(ctx, row.link), label)) | ||
else | else | ||
label_cell:wikitext(label .. ':') | |||
end | end | ||
tr:tag('td'):wikitext(ctx.args[row.param]) | tr:tag('td'):wikitext(ctx.args[row.param]) | ||