Modul:Vorlage:Dokumentation: Unterschied zwischen den Versionen
Zur Navigation springen
Zur Suche springen
Modul:Vorlage:Dokumentation (bearbeiten)
Version vom 10. September 2018, 22:10 Uhr
, 10. September 20182018-09-10
K (6 Versionen importiert: Lua) |
(2018-09-10) |
||
Zeile 1: | Zeile 1: | ||
--[=[ 2018- | --[=[ 2018-09-10 | ||
{{Dokumentation}} | {{Dokumentation}} | ||
]=] | ]=] | ||
Zeile 69: | Zeile 69: | ||
local function furnish( area ) | local function furnish( area, frame ) | ||
local i = area:find( "==", 1, true ) | local i = area:find( "==", 1, true ) | ||
local r | local r | ||
Zeile 96: | Zeile 96: | ||
r = "__NOTOC__\n" .. area | r = "__NOTOC__\n" .. area | ||
elseif n == 2 then | elseif n == 2 then | ||
local toc = mw.html.create( "div" ) | local src = "TOC nonum/styles.css" | ||
local toc = mw.html.create( "div" ) | |||
:newline() | |||
:addClass( "nonumtoc" ) | |||
:wikitext( "__TOC__" ) | |||
toc = tostring( toc ) | :newline() | ||
local styles = frame:extensionTag( "templatestyles", | |||
nil, | |||
{ src = src } ) | |||
toc = styles .. tostring( toc ) | |||
if init == 1 then | if init == 1 then | ||
r = toc .. area | r = toc .. area | ||
Zeile 128: | Zeile 132: | ||
if not findeSchalter( r ) then | if not findeSchalter( r ) then | ||
if not findeTemplateDataTOC( r ) then | if not findeTemplateDataTOC( r ) then | ||
r = furnish( r ) | r = furnish( r, frame ) | ||
end | end | ||
end | end |