Content deleted Content added
BrandonXLF (talk | contribs) No edit summary Tag: Reverted |
BrandonXLF (talk | contribs) No edit summary Tag: Reverted |
||
Line 1:
-- Sandbox, do not delete
require('strict')
local p = {}▼
local getArgs = require('Module:Arguments').getArgs
Line 8 ⟶ 6:
local parser = parserModule.parser
▲local function route(route, routeType, routeLoc, currProvince)
local out = ''
local parserArgs = {
route
type = routeType,
province = routeLoc
Line 43 ⟶ 35:
end
return "'''" .. out .. "'''"
end
function p.route(frame)▼
return route(▼
frame.args[1],▼
frame.args.type,▼
frame.args.province,▼
frame.args.current_province or frame.args.province▼
)▼
end▼
▲local function nav(prefix, label, currProvince, args)
local index = 1
local out = ''
Line 68 ⟶ 51:
end
out = out ..
index = index + 1
until not args[prefix .. index]
return label .. ' ' .. (index - 1 > 1 and 'routes' or 'route') .. '
▲end
▲local p = {}
▲function p.route(frame)
▲ frame.args[1],
▲ frame.args.type,
▲ frame.args.province,
▲ frame.args.current_province or frame.args.province
▲ )
end
function p.nav(frame)
return
frame.args[1],
frame.args.label,
frame.args.current_province,
getArgs(frame, { parentOnly = true })
)
end
|