Content deleted Content added
No edit summary |
m Reverted edits by Awesome Aasim (talk) to last version by SilverLocust |
||
Line 1:
local p = {}
local cfg = mw.loadData('Module:If preview/configuration')
--[[
Line 14 ⟶ 11:
]]
function p.main(frame)
if cfg.preview then
return frame.args[1] or ''
else
return frame.args[2] or ''
end
end
Line 33 ⟶ 29:
return p.main(frame:getParent())
end
local function warning_text(warning)
Line 51 ⟶ 48:
if not cfg.preview then return '' end
return warning_text(warning)
end
Line 60 ⟶ 57:
This function returns a "preview warning", which is the first argument marked
up with HTML and some supporting text, depending on whether the page is being previewed.
disabled since we'll implement the template version in general
]]
--
-- return
-- return p._warning(frame.args)▼
▲-- end
--[[
Line 71 ⟶ 69:
]]
function p.pwarning(frame)
▲Does both mw.addWarning and preview warning
end
|