انتقل إلى المحتوى

مودول:Wikidata/i18n

من ويكيپيديا

يمكن إنشاء صفحة توثيق الوحدة في مودول:Wikidata/i18n/شرح

local i18n = {
	["errors"] = {
		["property-not-found"] = "Property not found.",
		["entity-not-found"] = "Wikidata entity not found.",
		["unknown-claim-type"] = "Unknown claim type.",
		["unknown-entity-type"] = "Unknown entity type.",
		["qualifier-not-found"] = "Qualifier not found.",
		["site-not-found"] = "Wikimedia project not found.",
		["unknown-datetime-format"] = "Unknown datetime format.",
		["local-article-not-found"] = "Article is not yet available in this wiki.",
		['not-from-content-page'] = "Do not invoke from content page. Use a template or use a module subpage like /sandbox for testing."
	},
	["datetime"] =
	{
		-- $1 is a placeholder for the actual number
		[0] = "$1 مليار عام",	-- precision: billion years
		[1] = "$100 مليون عام",	-- precision: hundred million years
		[2] = "$10 مليون عام",		-- precision: ten million years
		[3] = "$1 ملاين دالسنين",		-- precision: million years
		[4] = "$100000 عام",		-- precision: hundred thousand years; thousand separators added afterwards
		[5] = "$10000 عام",		-- precision: ten thousand years; thousand separators added afterwards
		[6] = "لألفية $1",		-- precision: millennium
		[7] = "لقرن $1",			-- precision: century
		[8] = "عقد $1",			-- precision: decade
		-- the following use the format of #time parser function
		[9]  = "Y",						-- precision: year
		[10] = "F Y",					-- precision: month
		[11] = "j F Y",					-- precision: day
		["beforenow"] = "$1 قبل لميلاد",		-- how to format negative numbers for precisions 0 to 5
		["afternow"] = "$1 بعد لميلاد",		-- how to format positive numbers for precisions 0 to 5
		["bc"] = '$1 قبل لميلاد',				-- how print negative years
		["ad"] = "$1",					-- how print 1st century AD dates
	},
	["monolingualtext"] = '<span lang="%language">%text</span>',
	["warnDump"] = "[[تصنيف:Called function 'Dump' from module Wikidata]]",
	
	["cite"] = {					-- Cite web parameters
		["url"]          = "url",
		["title"]        = "title",
		["website"]      = "website",
		["access-date"]  = "access-date",
		["archive-url"]  = "archive-url",
		["archive-date"] = "archive-date",
		["author"]       = "author",
		["publisher"]    = "publisher",
		["quote"]        = "quote",
		["language"]     = "language",
		["date"]         = "date",
		["pages"]        = "pages"
		
		}
}


-- Functions for local grammatical cases
local cases = {
	["infoboxlabel"] = function(word) return require("Module:Wikidata/labels").fixInfoboxLabel(word) end,
	["infoboxdata"] = function(word) return require("Module:Wikidata/labels").infoboxdata[word] or word end,
	["smallcaps"] = function(word) return '<span style="font-variant: small-caps;">' .. word .. '</span>' end,
	["annexed"] = function(word, ...) if arg[1] == "kab" then return require("Module:Declension").annexed(word) end return word end
}

return {
	i18n = i18n,
	cases = cases
}