Difference between revisions 21306665 and 21306666 on frwiktionary

local export = {}
local m_languages = require('Module:languages')

-- The main entry point.
-- This is the only function that can be invoked from a template.
function export.show(frame)
	if mw.title.getCurrentTitle().nsText == "Template" then
		return "(This template should be used on pages in the Category: namespace.)"
(contracted; show full)	local namespace = ""
	
	if info.label == "citations" or info.label == "citations of undefined terms" then
		namespace = "Citations"
	elseif info.code then
		local lang = require("Module:languages").getByCode(info.code)
		
		if lang 
and (then
			if lang:getType() == "reconstructed" orthen
				namespace = "Reconstruction"
			elseif lang:getType() == "appendix-constructed") then
					namespace = "Appendix"
			end
		end
	end
	
	local recent = mw.getCurrentFrame():callParserFunction{
		name = "#tag",
		args = {
			"DynamicPageList",
			"category=" .. mw.title.getCurrentTitle().text .. "\n" ..
(contracted; show full)			return mw.getCurrentFrame():expandTemplate{title = TOC_template.text, args = {}}
		end
	end
	
	return nil
end

return export