跳转到内容

Module:Furigana:修订间差异

无编辑摘要
标签手工回退 已被回退
无编辑摘要
标签手工回退
 
第164行: 第164行:
end
end
local template = args.template or 'Photrans'
local template = args.template or 'Ruby'


if mw.isSubsting() then
if mw.isSubsting() then
local prefix = '{{'..template..'|'
local prefix = '{{'..template..'|'
return p.process(args, function (rb, rt)
return p.process(args, function (rb, rt)
return prefix..rb..'_'..rt..'}}'
return prefix..rb..'|'..rt..'}}'
end)
end)
end
end
第181行: 第181行:
local template_string = frame:expandTemplate {
local template_string = frame:expandTemplate {
title = template,
title = template,
args = { rb_placeholder..'_'..rt_placeholder },
args = { rb_placeholder, rt_placeholder },
}
}
if template_string:find(placeholder_pattern) then
if template_string:find(placeholder_pattern) then
第193行: 第193行:
return frame:expandTemplate {
return frame:expandTemplate {
title = template,
title = template,
args = { rb..'_'..rt },
args = { rb, rt },
}
}
end)
end)