View source for Module:Synced switch
Jump to navigation
Jump to search
You do not have permission to edit this page, for the following reason:
You can view and copy the source of this page.
local p = {}
local hc = require('Module:Paramtest').has_content
p._sortFunc = function(a,b)
return a.id < b.id
end
p.main = function(frame)
local args = frame:getParent().args
local parsed = { {id=0, content=args.default or '', showing = true} }
for k,v in pairs(args) do
local s = tostring(k):match('version(%d+)')
if hc(v) and s then
local obj = {id=tonumber(s), text=args['text'..s], content=v}
if obj.id == 1 then
obj.showing = true
parsed[1].showing = false
end
table.insert(parsed, obj)
000
1:0
Templates used on this page:
- Template:DependencyList (view source)
- Template:Documentation (view source)
- Template:No documentation (view source)
- Template:PageType (view source)
- Module:Array (view source)
- Module:DPLlua (view source)
- Module:DependencyList (view source)
- Module:Documentation (view source)
- Module:Paramtest (view source)
- Module:Synced switch/doc (view source)
- Module:Tooltip (view source)
- Module:Yesno (view source)
Return to Module:Synced switch.