Open main menu
Home
Random
Nearby
Log in
Settings
About Kancolle Wiki
Disclaimers
Kancolle Wiki
Search
Changes
← Older edit
Newer edit →
Module:EquipmentLink
(view source)
Revision as of 03:34, 24 March 2017
20 bytes added
,
7 years ago
m
no edit summary
Line 23:
Line 23:
or F:format_link(link or name, text or name)
or F:format_link(link or name, text or name)
−
local formatted_icon =
""
+
local formatted_icon
−
if
icon
then
+
= icon
−
-- [[Category:Todo]] again, would be nice to share
this
object with EquipmentCardKai
+
-- [[Category:Todo]] again, would be nice to share
Equipment
object with EquipmentCardKai
−
local equipment = Equipment(name)
+
and
F:format_image{ F:format_equipment_icon(
Equipment(name)
:icon()) }
−
formatted_icon =
F:format_image{ F:format_equipment_icon(
equipment
:icon()) }
+
or ""
−
end
−
return F:class_span("advanced-tooltip", nil, formatted_icon .. formatted_link ..
F:class_div("tooltip-contents", nil, card)
)
+
local tooltip_content = F:class_div("tooltip-contents", nil, card)
+
+
return F:class_span("advanced-tooltip", nil, formatted_icon .. formatted_link ..
tooltip_content
)
end
end
Line 44:
Line 45:
{ "Prototype 51cm Twin Gun Mount", icon = "x" },
{ "Prototype 51cm Twin Gun Mount", icon = "x" },
{ },
{ },
+
{ icon = "x" },
})
})
-- p.run_format_tests()
-- p.run_format_tests()
がか
cssedit, gkautomate
7,064
edits