模块:Message box:修订间差异

跳转到导航 跳转到搜索
删除18字节 、​ 2021年2月9日 (星期二)
本地化
无编辑摘要
(本地化)
 
第156行: 第156行:
end
end
tinsert(boxTypes, '"mbox"')
tinsert(boxTypes, '"mbox"')
error(format('無效的訊息框類型「%s」;有效的類型為%s', tostring(boxType), mw.text.listToText(boxTypes)), 2)
error(format('无效的信息框类型「%s」;有效值为%s', tostring(boxType), mw.text.listToText(boxTypes)), 2)
end
end
return cfg
return cfg
第246行: 第246行:
local sect
local sect
if args.sect == '' then
if args.sect == '' then
sect = '此' .. (cfg.sectionDefault or '頁面')
sect = '此' .. (cfg.sectionDefault or '页面')
elseif type(args.sect) == 'string' then
elseif type(args.sect) == 'string' then
sect = '此' .. args.sect
sect = '此' .. args.sect
第281行: 第281行:
end
end
if talkTitle and talkTitle.exists then
if talkTitle and talkTitle.exists then
local talkText = '相關討論可見於'
local talkText = '相关讨论可见于'
if talkArgIsTalkPage then
if talkArgIsTalkPage then
talkText = format('%s[[%s|%s]]。', talkText, talk, talkTitle.prefixedText)
talkText = format('%s[[%s|%s]]。', talkText, talk, talkTitle.prefixedText)
else
else
talkText = format('%s[[%s#%s|討論頁]]。', talkText, talkTitle.prefixedText, talk)
talkText = format('%s[[%s#%s|讨论页面]]。', talkText, talkTitle.prefixedText, talk)
end
end
self.talk = talkText
self.talk = talkText
第301行: 第301行:
end
end
if date then
if date then
local ok, tempdate = pcall(lang.formatDate, lang, 'Y年n月j日', date) -- 正規化日期
local ok, tempdate = pcall(lang.formatDate, lang, 'Y年n月j日', date)
if ok then
if ok then
date = tempdate
date = tempdate
第487行: 第487行:
end
end
if self.isSubstituted then
if self.isSubstituted then
self:addCat('all', '錯誤使用替換引用的頁面')
self:addCat('all', '错误使用替换应用的页面')
end
end


第510行: 第510行:
:addClass('error')
:addClass('error')
:wikitext(format(
:wikitext(format(
'模板<code>%s[[Template:%s|%s]]%s</code>被錯誤地替代。',
'模板<code>%s[[Template:%s|%s]]%s</code>被错误地替代。',
mw.text.nowiki('{{'), self.name, self.name, mw.text.nowiki('}}')
mw.text.nowiki('{{'), self.name, self.name, mw.text.nowiki('}}')
))
))
第612行: 第612行:
:tag('div')
:tag('div')
:css('text-align', 'center')
:css('text-align', 'center')
:wikitext(format('此訊息框使用無效的「type=%s」參數,需要修復。', self.type or ''))
:wikitext(format('此 Message Box 使用无效的「type=%s」参数,需要修复。', self.type or ''))
end
end


导航菜单