Module:Parameter validation/default config/sandbox: Difference between revisions
Appearance
Content deleted Content added
SilverLocust (talk | contribs) Copying config to sandbox |
SilverLocust (talk | contribs) Use sandbox version of if preview for test |
||
Line 4: | Line 4: | ||
function create_message(msg) |
function create_message(msg) |
||
return require('Module:If preview')._warning({ |
return require('Module:If preview/sandbox')._warning({ |
||
mw.ustring.format("[[templatename]] used with %s.", msg) |
mw.ustring.format("[[templatename]] used with %s.", msg) |
||
}) |
}) |
Latest revision as of 04:50, 1 April 2024
![]() | This is the module sandbox page for Module:Parameter validation/default config (diff). |
function create(cat, msg)
return mw.ustring.format("{{main other|[[Category:Pages using tname_naked with %s parameters]]}}", cat) .. create_message(msg)
end
function create_message(msg)
return require('Module:If preview/sandbox')._warning({
mw.ustring.format("[[templatename]] used with %s.", msg)
})
end
local options = {
["undeclared"] = create("unknown", 'unknown parameter(s): paramname'),
["deprecated"] = create("deprecated", 'deprecated parameter(s): paramname'),
["duplicate"] = create("duplicate", 'duplicate parameter(s): paramandvalue'),
["doc-subpage"] = "doc",
}
local result = {
[0] = options,
[2] = options,
[4] = options,
[6] = options,
[10] = options,
[12] = options,
[14] = options,
}
return result