Module:taln-conj: Difference between revisions
mNo edit summary |
mNo edit summary |
||
| Line 58: | Line 58: | ||
return title | return title | ||
end | |||
local translit = { | |||
["ᠠ"] = "a", | |||
["ᠡ"] = "e", | |||
["ᠢ"] = "i", | |||
["ᠣ"] = "o", | |||
["ᠤ"] = "u", | |||
["ᠷ"] = "r", | |||
["ᠸ"] = "v", | |||
["ᠵ"] = "z", | |||
["ᠰ"] = "s", | |||
["ᠲ"] = "t", | |||
["ᠨ"] = "n", | |||
["ᠺ"] = "c", | |||
["ᠴ"] = "č" | |||
} | |||
local function romanize(text) | |||
local result = "" | |||
for _, cp in utf8.codes(text) do | |||
local ch = utf8.char(cp) | |||
result = result .. (translit[ch] or ch) | |||
end | |||
return result | |||
end | end | ||
| Line 91: | Line 119: | ||
local text = | local text = | ||
"'''Conjugation of [[" | |||
.. title | |||
.. "]]''' (''" | |||
.. romanize(title) | |||
.. "'')\n\n" | |||
.. '{| class="wikitable"\n' .. | |||
'|+ Present indicative\n' .. | '|+ Present indicative\n' .. | ||
'|-\n' .. | '|-\n' .. | ||