Editing Module:IconUtils
From Eco - English Wiki
Your changes will be displayed to readers once an authorized user accepts them. (help)
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then publish the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 5: | Line 5: | ||
local itemData = mw.loadData("Module:ItemData") | local itemData = mw.loadData("Module:ItemData") | ||
local Icon = '' | local Icon = '' | ||
local args = Utils.normaliseArgs(param) | local args = Utils.normaliseArgs(param) | ||
Line 19: | Line 16: | ||
Icon = Utils.checkImage(IconName) | Icon = Utils.checkImage(IconName) | ||
if args.style == nil or args.style == '' then IconStyle = | if args.style == nil or args.style == '' then IconStyle = 1 else IconStyle = args.style end | ||
if args.link == nil or args.link == '' then IconLink = ' | if args.link == nil or args.link == '' then IconLink = '' end | ||
if args.link == '1' then IconLink = | if args.link == '1' then IconLink = args.name end | ||
return '[[file:'.. Icon ..'|'.. IconSize ..'px|link=[['.. IconLink ..']]]]' | |||
end | end | ||
return p | return p |