local exports = {}
local langdata = require('Module:Data/Langs')
local posdata = require('Module:Data/POS')
exports.head = function(frame)
local headword = frame.args[1]
local lang = frame.args["lang"]
local pos = frame.args["pos"]
local translit = frame.args["translit"]
local sc = frame.args["sc"]
local ipa = frame.args["ipa"]
assert(lang)
assert(pos)
assert(ipa)
ipa = frame:expandTemplate{ title = "IPA", args = {"/" .. ipa .. "/" }}
if (not translit) or translit == "" then
translit = ""
else
translit = " (" .. translit .. ")"
end
if sc and sc ~= "" then
headword = frame:expandTemplate{ title = 'Scr', args = { sc, headword}}
end
return headword .. translit .. " " .. ipa .. " ''" .. pos .. ".''\n"
.. "[[Category:" .. lang .. " " .. pos .. "]]\n"
.. "[[Category:" .. lang .. " Lemmas]]"
end
return exports