Module:UtilsLanguage/Data

local p = {}

local utilsTable = require("Module:UtilsTable")

p = { flagSize = "20px", languages = { {			code = "enBr", name = "English", region = "GB", lect = { abbr = "BR", name = "British", },		},		{			code = "ja", name = "Japanese", region = "JP", },		{			code = "zhS", name = "Chinese", region = "CN", lect = { abbr = "SI", name = "Simplified", },		},		{			code = "zhT", name = "Chinese", region = "THM", lect = { abbr = "TR", name = "Traditional", },		},		{			code = "cs", name = "Czech", region = "CZ", },		{			code = "da", name = "Danish", region = "DK", },		{			code = "nl", name = "Dutch", region = "NL", },		{			code = "fi", name = "Finnish", region = "FI", },		{			code = "frC", name = "French", region = "CA", lect = { abbr = "CA", name = "Canadian" },		},		{			code = "frF", name = "French", region = "FR", lect = { abbr = "EU", name = "European", },		},		{			code = "de", name = "German", region = "DE", },		{			code = "he", name = "Modern Hebrew", region = "IL", },		{			code = "hu", name = "Hungarian", region = "HU", },		{			code = "it", name = "Italian", region = "IT", },		{			code = "ko", name = "Korean", region = "KR", },		{			code = "no", name = "Norwegian", region = "NO", },		{			code = "pl", name = "Polish", region = "PL", },		{			code = "ptB", name = "Portuguese", region = "BR", lect = { abbr = "BR", name = "Brazilian", },		},		{			code = "ptP", name = "Portuguese", region = "PT", lect = { abbr = "EU", name = "European", },		},		{			code = "ru", name = "Russian", region = "RU", },		{			code = "esS", name = "Spanish", region = "ES", lect = { abbr = "EU", name = "European" },		},		{			code = "esL", name = "Spanish", region = "LAT", lect = { abbr = "LA", name = "Latin American", },		},		{			code = "sv", name = "Swedish", region = "SE", },		},	-- Stored separately as we often just want the "foreign" languages wikiLanguage = { code = "enAm", name = "English", region = "NOA", lect = { abbr = "AM", name = "American", },	}, } local allLanguages = utilsTable.concat({p.wikiLanguage}, p.languages) p.languageLookup = utilsTable.keyBy(allLanguages, "code")

return p