Content deleted Content added
No edit summary |
No edit summary |
||
(2 intermediate revisions by the same user not shown) | |||
Line 58:
local function infobox_ship_begin (args_t, infobox_ship_t, frame)
infobox_ship_t['bodystyle'] = data.styles_t.mainbox;
if args_t.infobox_caption then
▲ local name = mw.title.getCurrentTitle().text;
if 'yes' == args_t.infobox_caption then -- format article title as infobox caption
infobox_ship_t.title = ship_name_format ({name=name, adj='off', showerrs=args_t.showerrs, sclass=args_t.sclass});
Line 71 ⟶ 72:
infobox_ship_t.title = ''; -- to allow for possible displaytitle concatenation
end
-- end▼
if args_t.display_title then
Line 87 ⟶ 80:
end
else -- |display_title= empty or omitted, use article title
infobox_ship_t.title = infobox_ship_t.title .. frame:preprocess ('{{DISPLAYTITLE:' .. ship_name_format ({name=name, sclass=args_t.sclass}) .. '}}');
end
end
--[[--------------------------< I N F O B O X _ S H I P _ I M A G E >------------------------------------------
Line 102 ⟶ 95:
local function infobox_ship_image (frame)
local args_t = get_args (frame);
if not args_t.image then
return; -- if no image specified, abandon
local infobox_ship_t = {
child = args_t.child or 'yes'; -- default to child
|