Module:Road data/strings/USA/MO: Difference between revisions

Content deleted Content added
setting the Interstates to bypass redirects
Add green banner for Branson wayfinding routes
 
(48 intermediate revisions by 4 users not shown)
Line 1:
--[==[
To inspect the content of this data module, use [[Special:ExpandTemplates]]
and enter the following input text:
{{#invoke:Road data/dump|dump|module=Module:<name-of-this-module>}}
 
To inspect the content of this data module when editing, enter the following
into the Debug console:
local util = require("Module:Road data/util")
print(util.arrayToString(p))
]==]
 
--Missouri
local MO = {}require("Module:Road data/strings/USA")
 
local util = require("Module:Road data/util")
MO.I = {shield = "I-%route%.svg",
local format = mw.ustring.format
link = {["57"] = "Interstate 57",
["66"] = "Interstate 66 (Kansas–Kentucky)",
["72"] = "Interstate 72",
["155"] = "Interstate 155 (Missouri–Tennessee)",
["170"] = "Interstate 170",
["244"] = "Interstate 270 (Illinois–Missouri)",
["255"] = "Interstate 255",
["270"] = "Interstate 270 (Illinois–Missouri)",
["435"] = "Interstate 435",
["635"] = "Interstate 635 (Kansas–Missouri)",
["670"] = "Interstate 670 (Kansas–Missouri)",
default = {hook = "split",
split = 100,
above = "Interstate %route% (Missouri)",
below = "Interstate %route% in Missouri"}},
abbr = "I-%route%",
width = "expand"}
 
local suffix = " ([dab||%dab%, |]Missouri)"
MO["I-Future"] = {shield = "I-%route%.svg",
link = "Interstate %route% (Missouri)",
abbr = "Future I-%route%",
width = "expand"}
 
MO.I.link = {
MO.Future = MO["I-Future"]
["72"] = "Interstate 72",
["155"] = "Interstate 155 (Missouri–Tennessee)",
["170"] = "Interstate 170",
["244"] = "Interstate 270 (Missouri–Illinois)",
["255"] = "Interstate 255",
["270"] = "Interstate 270 (Missouri–Illinois)",
["435"] = "Interstate 435",
["635"] = "Interstate 635 (Kansas–Missouri)",
["670"] = "Interstate 670 (Kansas–Missouri)",
default = {
hook = "split",
split = 100,
above = "Interstate %route% (Missouri)",
below = "Interstate %route% in Missouri"
}
}
 
for k, v in pairs(MO) do if k:find ("^I") then
MO.BL = {shield = "Business Loop %route%.svg",
v.link = MO.I.link
link = "Interstate %route% Business ([dab||%dab%, |]Missouri)",
end
abbr = "Business Loop I-%route%",
end
width = "expand"}
MO.BL.link = "Interstate %route% Business" .. suffix
 
for k, v in pairs(MO) do if k:find ("^B%a") then
v.link = MO.BL.link
end
end
MO["I-Bus"] = MO.BL
 
MO.US = {shield.link = "USU.S. Route %route%.svg in Missouri",
link = "U.S. Route %route% in Missouri",
abbr = "US&nbsp;%route%",
width = "expand"}
 
for k, v in pairs(MO) do if k:find ("^US %d") then
MO["US-Alt"] = {shield = MO.US.shield,
v.name = MO.US.name
link = "U.S. Route %route% Alternate ([dab||%dab%, |]Missouri)",
v.link = MO.US.link
abbr = "US&nbsp;%route% Alt.",
end
banner = "Alternate plate.svg",
end
width = "expand"}
 
MO["US-Bus 1978"] = {shield = MO.US.shield,
shield = {
link = "U.S. Route %route% Business ([dab||%dab%, |]Missouri)",
hook = "splitlen",
abbr = "US&nbsp;%route% Bus.",
split = 3,
banner = "Business plate.svg",
above = "US %route% square.svg",
width = "expand"}
below = "US %route%.svg"
},
base = MO.US.base,
name = MO.US.name,
link = MO.US.link,
abbr = MO.US.abbr,
width = "square",
}
 
for _,auxType in ipairs({"Alt", "Bus", "Byp", "City", "Conn", "Emerg", "Opt", "Scenic", "Spur", "Temp", "Toll", "Truck"}) do
MO["US-Byp"] = {shield = MO.US.shield,
local spec = MO[" aux "][auxType]
link = "U.S. Route %route% Bypass ([dab||%dab%, |]Missouri)",
for k, v in pairs(MO) do if k:find (auxType) then if k:find ("^US") then
abbr = "US&nbsp;%route% Byp.",
v.link = MO.US.base .. " " .. spec.name .. " ([dab||%dab%, |]Missouri)"
banner = "By-pass plate.svg",
end
width = "expand"}
end
end
end
 
for _,year in ipairs({'1926', '1948', '1961'}) do
MO["US-City"] = {shield = MO.US.shield,
for _,auxType in ipairs({"Alt", "Bus", "Byp", "City", "Conn", "Opt", "Scenic", "Spur", "Temp", "Truck"}) do
link = "U.S. Route %route% City ([dab||%dab%, |]Missouri)",
local type = "US " .. year
abbr = "US&nbsp;%route% City",
local spec = MO[" aux "][auxType]
banner = "City plate.svg",
MO[type .. "-" .. auxType] = {
width = "expand"}
shield = MO[type].shield,
shieldmain = MO[type].shieldmain,
name = MO[type].name .. " " .. spec.name,
link = MO[type].base .. " " .. spec.name .. suffix,
abbr = MO[type].abbr .. " " .. spec.abbrsuffix,
banner = spec.bannerprefix .. " plate " .. year .. ".svg",
aux = spec.aux,
width = MO[type].width
}
end
end
MO["US 1926-City"].shield = "US %route% City 1926.svg"
MO["US 1926-City"].shieldmain = "US %route% City 1926.svg"
MO["US 1926-City"].banner = ""
 
MO["US-Spur"] = {shield = MO.US.shield,
link = "U.S. Route %route% Spur ([dab||%dab%, |]Missouri)",
abbr = "US&nbsp;%route% Spur",
banner = "Spur plate.svg",
width = "expand"}
 
MO["US-TruckBus-Alt"] = {
shield = MO.US.shield,
name = MO["US-Bus"].name .. " Alternate",
link = "U.S. Route %route% Truck ([dab||%dab%, |]Missouri)",
link = "U.S. Route %route% Business Alternate ([dab||%dab%, |]Missouri)",
abbr = "US&nbsp;%route% Truck",
abbr = MO["US-Bus"].abbr .. " Alt.",
banner = "Truck plate.svg",
banner = "Alternate business plate.svg",
width = "expand"}
aux = MO[" aux "].Alt,
width = "expand"
}
 
MO["US-AOTSHist"] = {shield.link = MO.US.shield,link
link = "U.S. Route %route% in Missouri",
abbr = "US&nbsp;%route%",
banner = "Avenue of the Saints banner.png",
width = "expand"}
 
MO.Route = {
MO["US 1926"] = {shield = "US %route% Missouri 1926.svg",
base = "Missouri Route %route%",
link = MO.US.link,
shield = "MO-%route%.svg",
abbr = MO.US.abbr,
name = "Route %route%",
width = "US1926"}
link = "Missouri Route %route% [dab||(%dab%)|]",
 
MO["US 1961-Bus"] = {shield abbr = "US Route&nbsp;%route% (1961).svg",
width = "expand"
link = MO["US-Bus"].link,
}
abbr = MO["US-Bus"].abbr,
banner = "Business plate.svg"}
 
MO["US 1961-Spur"] = {shield = "US %route% (1961).svg",
link = MO["US-Spur"].link,
abbr = MO["US-Spur"].abbr,
banner = "Spur plate.svg"}
 
MO.Route = {shield = "MO-%route%.svg",
link = "Missouri Route %route%[dab|| (%dab%)|]",
abbr = "Route&nbsp;%route%",
width = "expand"}
 
MO.MO = MO.Route
 
for _,type in ipairs({"Route", "MO"}) do
MO["Route 1948"] = {shield = "MO-%route%-cutout.svg",
for _,year in ipairs({"1922", "1926", "1948", "1960"}) do
link = MO.Route.link,
MO[type .. " " .. year] = {
abbr = MO.Route.abbr}
shield = format("MO-%%route%% (%s).svg", year),
name = MO.Route.name,
link = MO.Route.link,
abbr = MO.Route.abbr,
width = "square",
}
end
end
 
MO["MORoute 19481960"].shield = MO[".Route.shield 1948"] --until squares are made
MO["MO 1960"] = MO["Route 1960"]
 
MO["Route-Bus"] = {shield = MO.Route.shield,
link = "Missouri Route %route% Business [dab||(%dab%)|]",
abbr = "Route&nbsp;%route% Bus.",
banner = "Business plate.svg",
width = "expand"}
 
MO["MO-Bus"] = MO["Route-Bus"]
 
for _,type in ipairs({"Route", "MO"}) do
for _,auxType in ipairs({"Alt", "Bus", "Spur", "Temp",}) do
local spec = MO[" aux "][auxType]
MO[type .. "-" .. auxType] = {
shield = MO[type].shield,
name = MO[type].name .. " " .. spec.name,
link = MO[type].base .. " " .. spec.name .. MO[" dab "],
abbr = MO[type].abbr .. " " .. spec.abbrsuffix,
banner = spec.bannerprefix .. " plate.svg",
aux = spec.aux,
width = "expand"
}
end
end
MO.Bus = MO["Route-Bus"]
 
MO["Route-Spur"] = {shield = MO.Route.shield,
link = "Missouri Route %route% Spur [dab||(%dab%)|]",
abbr = "Route&nbsp;%route% Spur",
banner = "Spur plate.svg",
width = "expand"}
 
MO["MO-Spur"] = MO["Route-Spur"]
 
MO.Spur = MO["Route-Spur"]
 
MO.Supp = {
shield = "MO-supp-%route%.svg",
name = MO.Route.name,
link = {ifexists = true,
link = {
default = "Missouri Route %route% (%county% County)"},
ifexists = true,
abbr = "Route&nbsp;%route%",
default = "Missouri Route %route% (%county% County)"
width = "MOSupp"}
},
 
abbr = MO.Route.abbr,
MO.AOTS = {shield = "MO-27.svg",
width = "MOSupp"
link = "Avenue of the Saints",
}
abbr = "Route 27",
banner = "Avenue of the Saints banner.png",
width = "square"}
 
MO.CKCAOTS = {shield = "MO-110.svg",
shield = {
link = "Chicago–Kansas City Expressway",
arg = "route",
abbr = "Route&nbsp;110 (CKC)",
banner ["27"] = "CKC plateMO-27.svg",
["61"] = "US 61.svg"
width = "wide"}
},
link = {
arg = "route",
["27"] = "Avenue of the Saints",
["61"] = "U.S. Route 61 in Missouri"
},
abbr = {
arg = "route",
["27"] = "Route 27",
["61"] = "US 61"
},
banner = "Avenue of the Saints banner.svg",
width = "square"
}
MO["US-AOTS"] = MO.AOTS
 
MO.CKC = {
MO.GRR = {shield = "GreatRiverRoad.svg",
shield = "MO-110.svg",
link = "Great River Road",
name = "Chicago–Kansas City Expressway",
abbr = "Great River Road"}
link = "Chicago–Kansas City Expressway",
abbr = "Route&nbsp;110 (CKC)",
banner = "Chicago-Kansas City Expressway plate.svg",
width = "wide"
}
 
-- add new types above this line if you want it to have the state highway browse and maint
MO.LCT = {shield = "Lewis and Clark Trail.png",
for k, v in pairs(MO) do if k:find ("^%a") then
link = "Lewis and Clark Trail",
v.maint = "[[Missouri Department of Transportation|MoDOT]]"
abbr = "Lewis and Clark Trail"}
v.browse = "[[Missouri State Highway System]]"
v.browselinks = {
[1] = "[[List of Interstate Highways in Missouri|Interstate]]",
[2] = "[[List of U.S. Routes in Missouri|US]]",
[3] = "[[List of state highways in Missouri|State]]",
[4] = "[[Missouri supplemental route|Supplemental]]"
}
end
end
 
MO.Branson = {
MO["US-Hist"] = {shield = {["66"] = "US 66 (MO historic).svg",
shield = "Branson %route% Route.svg",
default = ""},
link name = "U.S. Route %route% in MissouriRoute",
link = "",
abbr = "Historic US&nbsp;%route%[dab|| (%dab%)|]",
abbr = "%route% Route",
width = 16}
maint = "",
bannersuffix = "green"
}
 
MO.BransonCR.link = {shield = "",
ifexists = true,
link = "",
default = "County Road %route% (%county% County, Missouri)",
abbr = "%route% Route"}
otherwise = ""
}
MO.CR.maint = ""
 
MO.SRCR = {
MO.CR = {shield = "CR %route% jct.svg",
shield = MO.Route.shield,
link = "",
shieldmain = {MO.Route.shield, MO.CR.shieldmain},
abbr = "CR&nbsp;%route%"}
name = MO.Route.name,
link = MO.Route.link,
abbr = MO.Route.abbr,
maint = ""
}
 
MO.AR = {alias = {module = "USA/AR", type = "AR"}}
Line 179 ⟶ 244:
MO["TN-Sec"] = {alias = {module = "USA/TN", type = "Sec"}}
 
MO.list = {
shield = "",
link = {
hook = "padroute",
paddedLength = 4,
default = "#MO%paddedRoute%"
},
abbr = MO.Route.abbr
}
 
return MO