Module:InfoboxHero: Difference between revisionsGive feedback
change tooltip type (the boring html title style) |
move back to fancy tooltips, also add classes to label spans |
||
| Line 560: | Line 560: | ||
end | end | ||
if row.link then | if row.link then | ||
label_cell:wikitext(string.format('[[%s|<span>%s</span>]]:', | label_cell:wikitext(string.format('[[%s|<span class="infobox-h-stat-label">%s</span>]]:', | ||
page_link(ctx, row.link), label_of(row))) | page_link(ctx, row.link), label_of(row))) | ||
else | else | ||
| 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) | ||
if row.tooltip then | if row.tooltip then | ||
label = ctx.frame:expandTemplate{ title = 'Tooltip', args = { label, row.tooltip } } | |||
end | end | ||
if row.link then | if row.link then | ||
tr:tag('td'):wikitext(string.format('[[%s|<span class="infobox-h-stat-label">%s</span>]]:', | |||
page_link(ctx, row.link), label)) | page_link(ctx, row.link), label)) | ||
else | else | ||
tr:tag('td'):wikitext(label .. ':') | |||
end | end | ||
tr:tag('td'):wikitext(ctx.args[row.param]) | tr:tag('td'):wikitext(ctx.args[row.param]) | ||