Modul:Sidebar: Unterschied zwischen den Versionen
add some tracking with Category:Pages using sidebar with the child parameter
K (vereinfacht) |
(add some tracking with Category:Pages using sidebar with the child parameter) |
||
| Zeile 2: | Zeile 2: | ||
-- This module implements {{Sidebar}} | -- This module implements {{Sidebar}} | ||
-- | -- | ||
require(' | require('Module:No globals') | ||
local p = {} | local p = {} | ||
local getArgs = require(' | local getArgs = require('Module:Arguments').getArgs | ||
local navbar = require(' | local navbar = require('Module:Navbar')._navbar | ||
local function trimAndAddAutomaticNewline(s) | local function trimAndAddAutomaticNewline(s) | ||
| Zeile 97: | Zeile 97: | ||
root | root | ||
:wikitext(args.title) | :wikitext(args.title) | ||
:wikitext('</th></tr>') -- @todo replace this with unclosed again once mw.html gets it | |||
else | else | ||
root | root | ||
| Zeile 162: | Zeile 163: | ||
root | root | ||
:tag('tr') | :tag('tr') | ||
:tag(' | :tag('th') | ||
:addClass(args.headingclass) | :addClass(args.headingclass) | ||
:css('padding', '0.1em') | :css('padding', '0.1em') | ||
:cssText(args.basestyle) | :cssText(args.basestyle) | ||
:cssText(args.headingstyle) | :cssText(args.headingstyle) | ||
| Zeile 218: | Zeile 218: | ||
end | end | ||
return tostring(root) | return tostring(root) .. (child and '[[Category:Pages using sidebar with the child parameter]]' or '') | ||
end | end | ||