local export = {};
local full_link = require("Module:links").full_link;
local lang_code = require("Module:languages").getByCode;
local sc_code = require("Module:scripts").getByCode;
function export.main (frame)
local args = require("Module:parameters").process(frame:getParent().args, {
= {required = true, default = "und"},
= {},
----
= {list = true, required = true},
= {list = true, allow_holes = true},
= {list = true, allow_holes = true},
= {list = true, allow_holes = true},
= {list = true, allow_holes = true},
= {list = true, allow_holes = true},
= {list = true, allow_holes = true},
= {list = true, allow_holes = true},
= {list = true, allow_holes = true},
});
local lang = lang_code(args);
local sc; if (args.sc) then sc = sc_code(args.sc); end
local links = {};
for i, v in ipairs(args) do
links = full_link({
lang = lang,
sc = sc,
----
term = v,
alt = args.alt,
id = args.id,
genders = args.g,
tr = args.tr,
ts = args.ts,
gloss = args.t,
pos = args.pos,
lit = args.lit,
}, "term");
end
local s = links;
if (#links > 1) then
for i = 2, #links - 1 do
s = s .. ', ' .. links;
end
s = s .. ' and ' .. links;
end
return frame:expandTemplate { title = "non-gloss definition", args = {
'See ' .. s .. '.'
} };
end
return export;