Module:qhv-adj: Difference between revisions

Jump to navigation Jump to search
no edit summary
No edit summary
No edit summary
Line 128: Line 128:
end
end


local function make_cases(data)
local function make_cases(data, pop)
local cases = {"nominative", "accusative", "genitive", "dative", "locative", "instrumental", "comitative", "vocative"}
local cases = {"nominative", "accusative", "genitive", "dative", "locative", "instrumental", "comitative", "vocative"}
local genders = {"lunar", "solar", "terrestrial", "aquatic"}
local genders = {"lunar", "solar", "terrestrial", "aquatic"}
local ret = {}
local ret = {}
data.pre, data.post = pre, post
data.pre = pop and false or true
for _, case in ipairs(cases) do
for _, case in ipairs(cases) do
Line 144: Line 144:
end
end
end
end
if case == "vocative" then data.pre, data.post = false, true end
end
end
return table.concat(ret)
return table.concat(ret)
Line 172: Line 171:
! ]=] .. g_tooltip("s", "ol") .. [=[​
! ]=] .. g_tooltip("s", "ol") .. [=[​
! ]=] .. g_tooltip("p", "pa") .. [=[​
! ]=] .. g_tooltip("p", "pa") .. [=[​
|- ]=] .. make_cases(data, true, false) .. [=[
|- ]=] .. make_cases(data) .. [=[
|}<ul style="margin-left:0px;"></ul>
|}<ul style="margin-left:0px;"></ul>
]=]
]=]
Line 193: Line 192:
! ]=] .. g_tooltip("s", "ol") .. [=[&#x200B;
! ]=] .. g_tooltip("s", "ol") .. [=[&#x200B;
! ]=] .. g_tooltip("p", "pa") .. [=[&#x200B;
! ]=] .. g_tooltip("p", "pa") .. [=[&#x200B;
|- style="background-color:#fdfdfd;" ]=] .. make_cases(data, false, true) .. [=[
|- style="background-color:#fdfdfd;" ]=] .. make_cases(data, true) .. [=[
|}
|}
]=]
]=]

Navigation menu