Module:Cite Q/sandbox: Difference between revisions

Content deleted Content added
we need plain=true after all
nowiki around title
Line 200:
 
]]
 
local function wrap_nowiki(str)
return mw.text.nowiki(str or '')
end
 
function citeq.cite_q (frame)
Line 268 ⟶ 272:
if slink then
citeq_args.url = nil
citeq_args.title = '[[' .. slink .. '|' .. wrap_nowiki(citeq_args.title) .. ']]'
else
citeq_args.title = wrap_nowiki(citeq_args.title)
end
else
Line 276 ⟶ 282:
citeq_args.title = '[[' .. slink .. ']]'
else
citeq_args.title = '[[' .. slink .. '|' .. wrap_nowiki(slink:gsub("%s%(.+%)$", ""):gsub(",.+$", "")) .. ']]'
end
else
citeq_args.title = wrap_nowiki(label)
end
end