Modul:Uses TemplateStyles: Unterschied zwischen den Versionen

Zur Navigation springen Zur Suche springen
Undo revision 4678331 by ExE Boss (talk): this is a global module; change the local config if you want to modify categories (I don’t think it’s necessary)
StadtbahnBI>Tacsipacsi
 
StadtbahnBI>Tacsipacsi
(Undo revision 4678331 by ExE Boss (talk): this is a global module; change the local config if you want to modify categories (I don’t think it’s necessary))
Zeile 5: Zeile 5:
local mMessageBox = require('Module:Message box')
local mMessageBox = require('Module:Message box')
local TNT = require('Module:TNT')
local TNT = require('Module:TNT')
local lang = mw.getCurrentFrame():preprocess('{{int:lang}}')


local p = {}
local p = {}


local function format(msg, ...)
local function format(msg, ...)
return TNT.formatInLanguage(lang, 'I18n/Uses TemplateStyles', msg, ...)
return TNT.format('I18n/Uses TemplateStyles', msg, ...)
end
end


Zeile 29: Zeile 28:
end
end


function p._main(args)
function p._main(args, cfg)
local tStyles = mTableTools.compressSparseArray(args)
local tStyles = mTableTools.compressSparseArray(args)
local box = p.renderBox(tStyles)
local box = p.renderBox(tStyles)
Zeile 98: Zeile 97:
local tsProt = tsTitleObj.protectionLevels["edit"] and tsTitleObj.protectionLevels["edit"][1] or nil
local tsProt = tsTitleObj.protectionLevels["edit"] and tsTitleObj.protectionLevels["edit"][1] or nil
if cfg['protection_conflict_category'] and tsProt ~= currentProt and not addedLevelCat then
if cfg['protection_conflict_category'] and tsProt ~= currentProt and not addedLevelCat then
addedLevelCat = true
cats[#cats + 1] = cfg['protection_conflict_category']
cats[#cats + 1] = cfg['protection_conflict_category']
end
end
Anonymer Benutzer

Navigationsmenü