跳转到内容

模組:List symbol

被永久保护的模块
维基百科,自由的百科全书

这是本页的一个历史版本,由Wj654cj86留言 | 贡献2015年8月4日 (二) 08:15 (修正筆誤)编辑。这可能和当前版本存在着巨大的差异。

local p = {}
function p.arrange(frame)
	local args = frame.args
	if args[1] == nil then
 		args = frame:getParent().args
	end

	local symbol = args.symbol or '.'
	local ss = ''
	if args[1] ~= nil then
		ss = ss .. '<span style="white-space:nowrap">' .. args[1]
	end
	local i = 2
	while args[i] ~= nil do
		ss = ss .. '&#32;' .. symbol .. '&#32;</span><span style="white-space:nowrap">' .. args[i]
		i = i + 1
	end
	ss = ss .. '</span>'
	ss = string.gsub(ss,'\n','')
	return ss
end

return p