Module:Documentation:修订间差异
删除的内容 添加的内容
吸收用户版本改进:escapeBrackets / EXPECTUNUSED / isPreviewing / small / env.printTitle / endBox顺序 |
修复3项: renderStartBoxLinks链接 / makeToolbar nil过滤 / EXPECTUNUSED分隔符 |
||
第79行:
end
for i = 1, lim do
if v then
ret[#ret + 1] = v
end
end
if #ret == 0 then return nil end
return format(
'<span class="%s">(%s)</span>',
第350行 ⟶ 第354行:
omargs.image = message('sandbox-notice-image')
local text = '__EXPECTUNUSEDTEMPLATE__\\n'
local pagetype, pagetypee, sandboxCat
if subjectSpace == 10 then
第458行 ⟶ 第462行:
function p.renderStartBoxLinks(data)
-- 纯 wikilink 拼接,由 MediaWiki 内核自动渲染方括号外观
local docTitle = data.docTitle
local purgeLink = makeWikilink("Special:Purge/" .. data.title.prefixedText, data.purgeLinkDisplay)
if docTitle.exists then
local viewLink = makeWikilink(docTitle.prefixedText, data.viewLinkDisplay)
local editLink = makeWikilink("Special:EditPage/" .. docTitle.prefixedText, data.editLinkDisplay)
local historyLink = makeWikilink("Special:PageHistory/" .. docTitle.prefixedText, data.historyLinkDisplay)
return viewLink .. editLink .. historyLink .. purgeLink
else
local createLink = makeUrlLink(docTitle:canonicalUrl{action = 'edit', preload = data.preload}, data.createLinkDisplay)
end
end
| |||