This data submodule defines part of Wiktionary's category structure.

For an introduction to the poscatboiler system and a description of how to add or modify categories, see Module:category tree/poscatboiler/data/documentation.


local labels = {}
local raw_categories = {}


labels["วลี"] = {
	description = "กลุ่มคำ{{{langname}}}ที่เรียบเรียงอย่างประณีตเพื่อแสดงความคิด ไม่จำเป็นต้องเป็นวลีในความหมายทางไวยากรณ์",
	umbrella_parents = "หมวดหมู่ย่อยของคำหลักแบ่งตามภาษา",
	parents = {"คำหลัก"},
}
labels["phrases"] = labels["วลี"]

labels["adverb-adjective phrases"] = {
	description = "{{{langname}}} phrases in which an adverb modifies the adjective that heads the phrase.",
	umbrella_parents = {name = "วลี", is_label = true, sort = " "},
	parents = {"วลี"},
}

-- วลีสัมผัส มีสองแบบ
labels["วลีสัมผัสพยัญชนะ"] = {
	description = "{{{langname}}} phrases composed of two or more words that alliterate.",
	umbrella_parents = {name = "วลี", is_label = true, sort = " "},
	parents = {"วลี"},
}
labels["alliterative phrases"] = labels["วลีสัมผัสพยัญชนะ"]

-- วลีสัมผัส มีสองแบบ
labels["วลีสัมผัสสระ"] = {
	description = "{{{langname}}} phrases composed of two or more words that rhyme.",
	umbrella_parents = {name = "วลี", is_label = true, sort = " "},
	parents = {"วลี"},
}
labels["rhyming phrases"] = labels["วลีสัมผัสสระ"]

labels["ประโยค"] = {
	description = "{{{langname}}} [[sentence]]s.",
	umbrella_parents = "มูลฐาน",
	parents = {{name = "{{{langcat}}}", raw = true}},
}
labels["sentences"] = labels["ประโยค"]

labels["หนังสือวลี"] = {
	description = "{{{langname}}} non-idiomatic phrases that are used in common situations, and may be useful to language learners or travellers.",
	parents = {
		"วลี",
		{name = "หนังสือวลีแบ่งตามภาษา", raw = true, sort = "{{{langname}}}"}
	},
	umbrella = false, -- Umbrella has a nonstandard name so we treat it as a raw category
}
labels["phrasebook"] = labels["หนังสือวลี"]

raw_categories["หนังสือวลีแบ่งตามภาษา"] = {
	description = "Categories with phrasebooks in various specific languages.",
	additional = "Phrasebook categories contain non-idiomatic phrases that are used in common situations, and may be useful to language learners or travellers.\n\n" ..
	"See [[Wiktionary:Phrasebook]] for more information.\n\n{{{umbrella_msg}}}",
	parents = "มูลฐาน",
}

for _, category in ipairs({
	{name = "Basic", topics = {}},
	{name = "Communication", topics = {"Communication"}},
	{name = "Emergencies", topics = {"Emergency medicine"}},
	{name = "Ethnicity", topics = {"Ethnicity"}},
	{name = "Family", topics = {"Family"}},
	{name = "Farewells", topics = {"Farewells"}},
	{name = "Festivities", topics = {}},
	{name = "Food and drink", topics = {"Food and drink"}},
	{name = "Greetings", topics = {"Greetings"}},
	{name = "Health", topics = {"Health"}},
	{name = "Love", topics = {"Love"}},
	{name = "Money", topics = {"Money"}},
	{name = "Needs", topics = {}},
	{name = "Religion", topics = {"Religion"}},
	{name = "Sex", topics = {"Sex"}},
	{name = "Time", topics = {"Time"}},
	{name = "Travel", topics = {"Travel"}},
	{name = "Weather", topics = {"Weather"}},
}) do
	local parents = {
		{name = "หนังสือวลี", sort = category.name},
		{name = "หนังสือวลีแบ่งตามภาษา/" .. category.name, raw = true, sort = "{{{langname}}}"},
	}
	for _, topic in ipairs(category.topics) do
		table.insert(parents, {module = "topic cat", args = {code = "{{{langcode}}}", label = topic}, sort = " "})
	end
	labels["หนังสือวลี/" .. category.name] = {
		description = "{{{langname}}} common non-idiomatic phrases in the category '" .. category.name .. "'.",
		breadcrumb = category.name,
		parents = parents,
		umbrella = false,
	}
	raw_categories["หนังสือวลีแบ่งตามภาษา/" .. category.name] = {
		description = "Categories with common non-idiomatic phrases in the category '" .. category.name .. "', in various specific languages.",
		additional = "{{{umbrella_msg}}}",
		parents = {{name = "หนังสือวลีแบ่งตามภาษา", sort = " "}},
		breadcrumb = category.name,
	}
end


return {LABELS = labels, RAW_CATEGORIES = raw_categories}