Изменения

пригодится
Строка 47: Строка 47:  
local link = require('Module:Yesno')(args._link, false)
 
local link = require('Module:Yesno')(args._link, false)
 
local endl = args._endl or ''
 
local endl = args._endl or ''
 +
local prefix = args._prefix or ''
 +
local postfix = args._postfix or ''
 
local nwt = mw.html.create(tag):tag(tag) --"no-wiki tag", внутри него шаблон не вызывается
 
local nwt = mw.html.create(tag):tag(tag) --"no-wiki tag", внутри него шаблон не вызывается
local content = '{{' --для накопления содержимого тэга
+
local content = nowiki(prefix) .. '{{' --для накопления содержимого тэга
 
local tname = args._template or args[1]
 
local tname = args._template or args[1]
   Строка 70: Строка 72:  
end
 
end
 
end
 
end
content = content .. '}}'
+
content = content .. '}}' .. nowiki(postfix)
 
nwt:wikitext(content):done()
 
nwt:wikitext(content):done()
   −
return tostring(nwt) .. ' ' .. sep .. ' ' .. tostring(expand(frame, tname, targs))
+
return tostring(nwt) .. ' ' .. sep .. ' ' .. prefix .. tostring(expand(frame, tname, targs)) .. postfix
 
end
 
end
    
return p
 
return p
Анонимный участник