Module:Road data/strings/USA/MT

--[==[
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"]`.
]==]

-- Montana
local MT = {}

local util = require("Module:Road data/util")
local format = mw.ustring.format
util.addAll(MT, require("Module:Road data/strings/USA"))

local suffix = " ([dab||%dab%, |]Montana)"

MT.I.link = {
	["115"] = "Interstate 115",
	["315"] = "Interstate 15 Business (Great Falls, Montana)",
	default = {
		hook = "split",
		split = 100,
		above = "Interstate %route% (Montana)",
		below = "Interstate %route% in Montana"
	}
}

for k, v in pairs(MT) do if k:find ("^I") then 
	v.link = MT.I.link
	end
end

MT.BL.link = MT.I.base .. " Business" .. suffix

for k, v in pairs(MT) do if k:find ("^BL") then 
	v.link = MT.BL.link
	end
end

MT.US.name = "U.S. Highway %route%"
MT.US.link = {
	["10A"] = "U.S. Route 10 Alternate ([dab||%dab%–|]Montana)",
	["310"] = "U.S. Route 310",
	["312"] = "U.S. Route 312",
	default = "U.S. Route %route% in Montana"
}

for k, v in pairs(MT) do if k:find ("^US %d") then 
	v.name = MT.US.name
	v.link = MT.US.link
	end
end

for _,auxType in ipairs({"Alt", "Bus", "Byp", "City", "Conn", "Emerg", "Opt", "Scenic", "Spur", "Temp", "Toll", "Truck"}) do
	local spec = MT[" aux "][auxType]
		for k, v in pairs(MT) do if k:find (auxType) then if k:find ("^US") then
			v.name = MT.US.name .. " " .. spec.name
			v.link = MT.US.base .. " " .. spec.name .. " ([dab||%dab%, |]Montana)"
			end
		end
	end
end

MT.MT = {
	shield = "MT-%route%.svg",
	name = "Montana Highway %route%",
	link = "Montana Highway %route%[dab|| (%dab%)|]",
	abbr = "MT&nbsp;%route%",
	width = "expand"
}

for _,type in ipairs({"MT"}) do
	for _,year in ipairs({"1926", "1948"}) do
		MT["MT " .. year] = {
			shield = format("MT-%%route%% (%s).svg", year),
			name = MT.MT.name,
			link = MT.MT.link,
			abbr = MT.MT.abbr,
			width = "square"
		}
	end
end

MT["MT-Bus"] = {
	shield = MT.MT.shield,
    name = MT.MT.name .. " Business",
    link = "Montana Highway %route% Business[dab|| (%dab%)|]",
    abbr = "MT&nbsp;%route% Bus.",
    banner = "Business plate.svg",
    aux = MT[" aux "].Bus,
    width = "expand"
}

MT.S = {
	shield = "MT-sec-%route%.svg",
    name = "Secondary Highway %route%",
    link = {
    	ifexists = true,
		default = "Montana Secondary Highway %route%",
		otherwise = "List of secondary highways in Montana#Sec0%route%"
    },
    abbr = "S-%route%"
}

MT.Sec = MT.S

MT["S 1945"] = {
	shield = "MT-sec-%route% (1945).svg",
    name = MT.S.name,
    link = MT.S.link,
    abbr = MT.S.abbr
}

MT["Sec 1945"] = MT["S 1945"]

-- add new types above this line if you want it to have the state highway browse and maint
for k, v in pairs(MT) do if k:find ("^%a") then
	v.maint = "[[Montana Department of Transportation|MDT]]"
	v.browse = "[[Montana Highway System]]"
	v.browselinks = {
		[1] = "[[List of Interstate Highways in Montana|Interstate]]",
		[2] = "[[List of U.S. Highways in Montana|US]]",
		[3] = "[[List of state highways in Montana|State]]",
		[4] = "[[List of secondary highways in Montana|Secondary]]"
	}
	end
end

MT.CR.shield = "Connecticut Highway %route%.svg"

MT.NSB.shieldmain = {"US 212.svg", "MUTCD D6-4.svg"}

-- For internal linking on List of secondary highways in Montana

MT.Sec2 = {
	shield = MT.Sec.shield,
	link = "#Secondary Highway %route%",
	abbr = MT.Sec.abbr
}

return MT

Content Disclaimer

Informasi ini disarikan dari Wikipedia dan disajikan kembali untuk tujuan edukasi. Konten tersedia di bawah lisensi CC BY-SA 3.0. Kami tidak bertanggung jawab atas ketidakakuratan data yang bersumber dari kontribusi publik tersebut.

  1. The information displayed on this website is sourced in part or in whole from Wikipedia and has been adapted for the purpose of restating it. We strive to provide accurate and relevant information, however:
  2. There is no guarantee of absolute accuracy. Wikipedia is an open, collaborative project that can be edited by anyone, so information is subject to change.
  3. It is not intended to constitute professional advice. The content displayed is for informational and educational purposes only. For important decisions (e.g., medical, legal, or financial), please consult a professional.
  4. Content copyright. Wikipedia is licensed under the Creative Commons Attribution-ShareAlike License (CC BY-SA). This means that content may be reused with appropriate attribution and shared under a similar license.
  5. Responsible use. Any risk arising from the use of information from this website is entirely the responsibility of the user.