Pergi ke kandungan

Modul:category tree/poscatboiler/data/word of the day

Daripada Wikikamus

Submodul data ini mentakrifkan sebahagian daripada struktur kategori Wikikamus.

Untuk pengenalan kepada sistem poscatboiler dan penerangan tentang cara menambah atau mengubah suai kategori, lihat Modul:category tree/poscatboiler/data/doc.


local raw_categories = {}
local raw_handlers = {}



-----------------------------------------------------------------------------
--                                                                         --
--                              RAW CATEGORIES                             --
--                                                                         --
-----------------------------------------------------------------------------


raw_categories["Former foreign words of the day by language"] = {
	description = "Categories with former foreign words of day in various languages.",
	additional = "{{{umbrella_msg}}}",
	parents = {
		"Category:Foreign word of the day archive",
	},
	breadcrumb = "Former by language",
	hidden = true,
}



-----------------------------------------------------------------------------
--                                                                         --
--                                RAW HANDLERS                             --
--                                                                         --
-----------------------------------------------------------------------------


table.insert(raw_handlers, function(data)
	local langname = data.category:match("^Former foreign words of the day in (.*)$")
	if langname then
		local lang = require("Module:languages").getByCanonicalName(langname, true)
		return {
			lang = lang:getCode(),
			description = "Former foreign words of the day in " .. lang:makeCategoryLink() .. ".",
			parents = {
				{name = "Former foreign words of the day by language", sort = langname},
			},
			breadcrumb = langname,
			hidden = true,
		}
	end
end)


return {RAW_CATEGORIES = raw_categories, RAW_HANDLERS = raw_handlers}