Module:Framexml search
Jump to navigation
Jump to search
Documentation for this module may be created at Module:Framexml search/doc
-- https://wowpedia.fandom.com/wiki/Template:Framexml_search
local m = {}
local URL = "https://github.com/search?q=repo:Gethe/wow-ui-source"
local ICON = "GitHub_Octocat.png"
function m.main(f)
if f.args.t == "icon" then
return string.format("[[File:%s|16px|link=%s+%s&type=code]]", ICON, URL, f.args[1])
elseif f.args.t == "verbose" then
local search = #f.args[1]>0 and f.args[1] or f.args.pagename
return string.format(" [[File:%s|16px|link=]] Search FrameXML for [%s+%s&type=code %s]", ICON, URL, search, search)
else
local text = #f.args[2]>0 and f.args[2] or f.args[1]
return string.format("[%s+%s&type=code %s]", URL, f.args[1], text)
end
end
return m