Модуль:Category handler/data

Версия от 02:11, 5 апреля 2025; Pok (обсуждение | вклад) (Новая страница: «-- source: https://ru.wikipedia.org/wiki/Модуль:Category handler/data -- license: CC BY-SA 4.0 -- This module assembles data to be passed to Module:Category handler using -- mw.loadData. This includes the configuration data and whether the current -- page matches the title blacklist. local data = require('Module:Category handler/config') local mShared = require('Module:Category handler/shared') local blacklist = require('Module:Category handler/...»)

Для документации этого модуля может быть создана страница Модуль:Category handler/data/doc

-- source: https://ru.wikipedia.org/wiki/Модуль:Category handler/data
-- license: CC BY-SA 4.0 

-- This module assembles data to be passed to [[Module:Category handler]] using
-- mw.loadData. This includes the configuration data and whether the current
-- page matches the title blacklist.

local data = require('Module:Category handler/config')
local mShared = require('Module:Category handler/shared')
local blacklist = require('Module:Category handler/blacklist')
local title = mw.title.getCurrentTitle()

data.currentTitleMatchesBlacklist = mShared.matchesBlacklist(
	title.prefixedText,
	blacklist
)

data.currentTitleNamespaceParameters = mShared.getNamespaceParameters(
	title,
	mShared.getParamMappings()
)

return data