Content deleted Content added
refactor |
simpler |
||
(2 intermediate revisions by the same user not shown) | |||
Line 53:
end
end
cells[1]:wikitext('<code>' ..
if lect.aliases then
local aliases = {}
Line 125:
local key = lect.key or lect.parent and lect.parent.key
if key then
local asciiKey = mw.ustring.gsub(mw.ustring.toNFD(key), '[^ -~]', '')
table.insert(keys, asciiKey)
end
table.insert(byKey[
code = lect.code,
name = lect.name or lect.extName,
Line 137 ⟶ 138:
end
table.sort(keys)
for _,
local row = t:tag('tr')
local
local keyCell = row:tag('td'):wikitext('[[' .. keyLects.name .. ']]')
local lang
if #keyLects > 1 then
keyCell:attr('rowspan', #keyLects)
table.sort(keyLects, function (a, b) return a.name < b.name end)
local keyName = mw.ustring.gsub(
for _, lect in ipairs(keyLects) do
if lect.name == keyName then
|