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

Content deleted Content added
add
add dual interstate/state route road type
 
(22 intermediate revisions by 4 users not shown)
Line 1:
--Alabama[==[
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))
To inspect a particular route type, change `p` above to include the route type,
e.g., `p.I` and `p["US-Hist"]`.
]==]
 
-- Alabama
local AL = {}
 
local util = require("Module:Road data/util")
AL.I = {shield = "I-%route%.svg",
util.addAll(AL, require("Module:Road data/strings/USA"))
link = {["185"] = "Interstate 185 (Georgia)",
 
local suffix = " ([dab||%dab%, |]Alabama)"
 
AL.I.link = { ["185"] = "Interstate 185 (Georgia)",
["210"] = "Interstate 210 (Alabama)",
default = {hook = "splitlen",
split = 3,
above = "Interstate %route% (Alabama)",
below = "Interstate %route% in Alabama"}},
abbr = "I-%route%",
width = "expand"}
 
for k, v in pairs(AL) do if k:find ("^I") then
AL.Future = {shield = "I-%route% (Future).svg",
v.link = AL.I.link,
end
abbr = "Future " .. AL.I.abbr,
end
width = "expand"}
 
AL.US.link = "U.S. Route %route% in Alabama"
AL["I-Future"] = AL.Future
 
for _,auxType in ipairs({"Alt", "Bus", "Byp", "City", "Conn", "Emerg", "Opt", "Scenic", "Spur", "Temp", "Toll", "Truck"}) do
AL.US = {shield = "US %route%.svg",
local spec = AL[" aux "][auxType]
link = "U.S. Route %route% in Alabama",
for k, v in pairs(AL) do if k:find (auxType) then if k:find ("^US") then
abbr = "US %route%",
v.link = AL.US.base .. " " .. spec.name .. suffix
width = "expand"}
end
end
end
end
 
for k, v in pairs(AL) do if k:find ("^US %d") then
AL["US-Bus"] = {shield = AL.US.shield,
v.link = AL.US.link
link = "U.S. Route %route% Business ([dab||%dab%, |]Alabama)",
end
abbr = AL.US.abbr .. " Bus.",
end
banner = "Business plate.svg",
width = "expand"}
 
AL.SR = {
AL["US-Alt"] = {shield = AL.US.shield,
link base = "U.S.Alabama State Route %route% Alternate ([dab||%dab%, |]Alabama)",
shield = "Alabama %route%.svg",
abbr = AL.US.abbr .. " Alt.",
name = "State Route %route%",
banner = "Alt plate.svg",
link = "Alabama State Route %route% [dab||(%dab%)|]",
width = "expand"}
abbr = "SR %route%",
width = "expand"
}
 
AL.AL = AL.SR
AL["US-Truck"] = {shield = AL.US.shield,
link = "U.S. Route %route% Truck ([dab||%dab%, |]Alabama)",
abbr = AL.US.abbr .. " Truck",
banner = "Truck plate.svg",
width = "expand"}
 
for _,type in ipairs({'SR', 'AL'}) do
AL["US 1926"] = {shield = "US %route% (1926).svg",
for _,auxType in ipairs({"Alt", "Bus", "Byp", "Conn", "Opt", "Scenic", "Spur", "Temp", "Truck"}) do
link = AL.US.link,
local spec = AL[" aux "][auxType]
abbr = AL.US.abbr,
AL[type .. "-" .. auxType] = {
width = "US1926"}
shield = AL.SR.shield,
name = AL.SR.name .. " " .. spec.name,
link = AL.SR.base .. " " .. spec.name .. AL[" dab "],
abbr = AL.SR.abbr .. " " .. spec.abbrsuffix,
banner = spec.bannerprefix .. " plate.svg",
aux = spec.aux,
width = "expand",
}
end
end
 
AL.SPR = {
AL["US 1948"] = {shield = "US %route% (1948).svg",
shield = "",
link = AL.US.link,
name = "State Park Road %route%",
abbr = AL.US.abbr,
link = "State Park Road %route% (Alabama)",
width = "square"}
abbr = "State Park Road %route%"
}
AL["US 1961"] = {shield = "US %route% (1961).svg",
link = AL.US.link,
abbr = AL.US.abbr,
width = "square"}
 
AL.SRD = {
AL.SR = {shield = "Alabama %route%.svg",
link name = "Alabama State Route %route% [dab||(%dab%)|]",
abbr = "SR %route%",
}
width = "expand"}
AL.ALD = AL.SRD
 
AL.AL["SR-Hidden"] = AL.SRSRD
AL["AL-Hidden"] = AL.SRD
--This is for designated state routes along U.S. Highways in Alabama, which are not signed. Meant to streamline existing practices.--
 
AL["SR-Bus 1960"] = {shield = AL.SR.shield,
link shield = "Alabama State Route %route% Business [dab||(%dab%1960)|].svg",
abbr name = AL.SR.abbr .. " Bus."name,
link = AL.SR.link,
banner = "Business plate.svg",
abbr = AL.SR.abbr
width = "expand"}
}
AL["AL 1960"] = AL["SR 1960"]
 
AL.OSR = {
AL["SR-Byp"] = {shield = AL.SR.shield,
link name = "Alabama State RouteRoad %route% Bypass [dab||(%dab%)|]",
abbr = AL."SR.abbr .. " Byp.%route%",
link = "State Road %route% (Alabama pre-1928[dab||, %dab%|])"
banner = "By-pass plate.svg",
}
width = "expand"}
AL.OAL = AL.OSR
AL["Old-SR"] = AL.OSR
AL["Old-AL"] = AL.OSR
--These are for the state road system Alabama used prior to the 1928 renumbering. Currently, no known examples of the shields for these have been found.--
 
-- add new types above this line if you want it to have the state highway browse and maint
AL["SR-Truck"] = {shield = AL.SR.shield,
for k, v in pairs(AL) do if k:find ("^%a") then
link = "Alabama State Route %route% Truck [dab||(%dab%)|]",
v.maint = "[[Alabama Department of Transportation|ALDOT]]"
abbr = AL.SR.abbr .. " Truck",
v.browse = "Alabama Highways"
banner = "Truck plate.svg",
v.browselinks = {
width = "expand"}
[1] = "[[List of Interstate Highways in Alabama|Interstate]]",
[2] = "[[List of U.S. Highways in Alabama|US]]",
[3] = "[[List of state routes in Alabama|State]]"
}
end
end
 
AL.CR.name = "County Route %route%"
AL["AL-Bus"] = AL["SR-Bus"]
AL.CR.maint = ""
 
AL.CRBeach = {shield = "CR--Foley %route%or jct.svg",Baldwin
shield = {
link = {ifexists = true,
ifexists = true,
default = "County Route %route% (%county% County, Alabama)"},
abbr default = "CR %route% Beach Express.svg"},
otherwise = ""
},
link = "%route% Beach Express",
abbr = "%route% Beach Express",
maint = "Beach Express",
bannersuffix = "green"
}
 
AL.IAL = { --Infobox covering both Interstate and state hwy
AL.Beach = {shield = {ifexists = true,
shield = {AL.I.shield, AL.SR.shield},
default = "%route% Beach Express.svg",
shieldmain = {AL.I.shieldmain, AL.SR.shield},
otherwise = ""},
name = AL.I.name .. " and " .. AL.SR.name,
link = "%route% Beach Express",
abbr link = "Interstate %route% Beach Express(Alabama)"} --Foley or Baldwin,
abbr = "I-%route% / AL &route%",
bannersuffix = {"blue", ""}
}
 
AL.SPR = {shield = "",
link = "State Park Road %route% (Alabama)",
abbr = "State Park Road %route%"}
AL.FL = {alias = {module = "USA/FL", type = "SR"}}
AL.GA = {alias = {module = "USA/GA", type = "SR"}}