Module:rad-stem/templates: Difference between revisions

ਕੋਈ ਸੋਧ ਸਾਰ ਨਹੀਂ
mNo edit summary
No edit summary
Line 89: Line 89:
end
end


function rad_link_IPA(word)
function rad_link_IPA(word, post, noipa)
if noipa == nil then noipa = false end
local post_space = " "
if post then
if mw.ustring.sub(post, 1, 1) == "-" then
post_space = ""
end
else
post_space = ""
end
if type(word) == "string" then
if type(word) == "string" then
return rad_link(word) .. "<br>" .. rad_IPA(word)
if noipa then
if post then
return rad_link(word) .. post_space .. rad_link(post)
else
return rad_link(word)
end
else
if post then
return rad_link(word) .. post_space .. rad_link(post) .. "<br>" .. rad_IPA(word .. post_space .. post)
else
return rad_link(word) .. "<br>" .. rad_IPA(word)
end
end
elseif type(word) == "table" then
elseif type(word) == "table" then
local links = {}
local links = {}
Line 97: Line 119:
for _, i in ipairs(word) do
for _, i in ipairs(word) do
local new_link = rad_link(i['word'])
local new_link = rad_link(i['word'])
if post then new_link = new_link .. post_space .. rad_link(post) end
if i['note'] then new_link = new_link .. " <small>(" .. i['note'] .. ")</small>" end
if i['note'] then new_link = new_link .. " <small>(" .. i['note'] .. ")</small>" end
table.insert(links, new_link)
table.insert(links, new_link)
table.insert(IPAs, rad_IPA(i['word']))
if not noipa then
if post then
table.insert(IPAs, rad_IPA(i['word'] .. post_space .. post))
else
table.insert(IPAs, rad_IPA(i['word']))
end
end
end
if noipa then
return table.concat(links, ", ")
else
return table.concat(links, ", ") .. "<br>" .. table.concat(IPAs, " ")
end
end
return table.concat(links, ", ") .. "<br>" .. table.concat(IPAs, " ")
else error("Incompatible input type for rad_link_IPA")
else error("Incompatible input type for rad_link_IPA")
end
end
Line 454: Line 487:
local function get_forms(stem, ending, regex1, regex2)
local function get_forms(stem, ending, regex1, regex2)
local temp = {}
local temp = {}
local post = ""
local noipa = false
if type(regex2) == "boolean" then
if regex1 == nil then
post = nil
else
post = regex1
end
noipa = regex2
regex1 = nil
regex2 = nil
else
post = nil
end
ending = ending or ""
ending = ending or ""
regex1 = regex1 or ""
regex1 = regex1 or ""
Line 466: Line 513:
temp = mw.ustring.gsub(stem .. ending, regex1, regex2)
temp = mw.ustring.gsub(stem .. ending, regex1, regex2)
end
end
return rad_link_IPA(temp)
return rad_link_IPA(temp, post, noipa)
end
end
Line 763: Line 810:
th("Compound forms of ''" .. cite .. "'' (active voice) &nbsp;", 1, 14)
th("Compound forms of ''" .. cite .. "'' (active voice) &nbsp;", 1, 14)
_tr()
_tr()
th("finite forms", 4, 3)
th("", 4, 3)
th("singular", 1, 5)
th("singular", 1, 5)
th("plural", 1, 5)
th("plural", 1, 5)
Line 794: Line 841:
th("''" .. rad_link("gjes") .. ", " .. rad_link("gjete") .. ", " .. rad_link("gje") .. ", " .. rad_link("gjen") .. "''")
th("''" .. rad_link("gjes") .. ", " .. rad_link("gjete") .. ", " .. rad_link("gje") .. ", " .. rad_link("gjen") .. "''")
th("''" .. rad_link("sja") .. ", " .. rad_link("lai") .. "''")
th("''" .. rad_link("sja") .. ", " .. rad_link("lai") .. "''")
_tr()
th("continuous",7,1)
th("infinitive",1,2)
td(get_forms(pp.prespart,"vú","vat",true),1,12)
_tr()
th("indicative",2,1)
th("non-past")
td(get_forms(pp.prespart,"vú","vage",true))
td(get_forms(pp.prespart,"vú","vaga",true))
td(get_forms(pp.prespart,"vú","vaș",true),1,2)
td(get_forms(pp.prespart,"vú",_,true))
td(get_forms(pp.prespart,"vú","vaguos",true))
td(get_forms(pp.prespart,"vú","vaguote",true))
td(get_forms(pp.prespart,"vú","vagú",true),1,2)
td(get_forms(pp.prespart,"vú",_,true))
td(get_forms(pp.prespart,"vú","vagún",true))
_tr()
th("past")
td(get_forms(pp.prespart,"vú","hâlei",true))
td(get_forms(pp.prespart,"vú","hâlen",true))
td(get_forms(pp.prespart,"vú","hâleș",true),1,2)
td(get_forms(pp.prespart,"vú","hâle",true))
td(get_forms(pp.prespart,"vú","hâluos",true))
td(get_forms(pp.prespart,"vú","hâluote",true))
td(get_forms(pp.prespart,"vú","hâlú",true),1,3)
td(get_forms(pp.prespart,"vú","hâlún",true))
_tr()
th("subjunctive",2,1)
th("non-past")
td(get_forms(pp.prespart,"vú","vagai",true))
td(get_forms(pp.prespart,"vú","vagá",true))
td(get_forms(pp.prespart,"vú","vagaș",true),1,2)
td(get_forms(pp.prespart,"vú","vaga",true))
td(get_forms(pp.prespart,"vú","vagavuos",true))
td(get_forms(pp.prespart,"vú","vagavuote",true))
td(get_forms(pp.prespart,"vú","vagavú",true),1,3)
td(get_forms(pp.prespart,"vú","vagavún",true))
_tr()
th("past")
td(get_forms(pp.prespart,"vú","hâlai",true))
td(get_forms(pp.prespart,"vú","hâlain",true))
td(get_forms(pp.prespart,"vú","hâlaiș",true),1,2)
td(get_forms(pp.prespart,"vú","hâlai",true))
td(get_forms(pp.prespart,"vú","hâlavuos",true))
td(get_forms(pp.prespart,"vú","hâlavuote",true))
td(get_forms(pp.prespart,"vú","hâlavú",true),1,3)
td(get_forms(pp.prespart,"vú","hâlavún",true))
_tr()
th("optative",2,1)
th("non-past")
td(get_forms(pp.prespart,"vú","vagúe",true))
td(get_forms(pp.prespart,"vú","vagova",true))
td(get_forms(pp.prespart,"vú","vagúș",true),1,2)
td(get_forms(pp.prespart,"vú","vagú",true))
td(get_forms(pp.prespart,"vú","vagovuos",true))
td(get_forms(pp.prespart,"vú","vagovuote",true))
td(get_forms(pp.prespart,"vú","vagovú",true),1,3)
td(get_forms(pp.prespart,"vú","vagovún",true))
_tr()
th("past")
td(get_forms(pp.prespart,"vú","hâlevei",true))
td(get_forms(pp.prespart,"vú","hâleven",true))
td(get_forms(pp.prespart,"vú","hâleveș",true),1,2)
td(get_forms(pp.prespart,"vú","hâleve",true))
td(get_forms(pp.prespart,"vú","hâlevuos",true))
td(get_forms(pp.prespart,"vú","hâlevuote",true))
td(get_forms(pp.prespart,"vú","hâlevú",true),1,3)
td(get_forms(pp.prespart,"vú","hâlevún",true))
_tr()
th("perfective",7,1)
th("infinitive",1,2)
td(get_forms(pp.pspart,"l","-at",true),1,12)
_tr()
th("indicative",2,1)
th("non-past")
td(get_forms(pp.pspart,"l","-age",true))
td(get_forms(pp.pspart,"l","-aga",true))
td(get_forms(pp.pspart,"l","-aș",true),1,2)
td(get_forms(pp.pspart,"l", _,true))
td(get_forms(pp.pspart,"l","-aguos",true))
td(get_forms(pp.pspart,"l","-aguote",true))
td(get_forms(pp.pspart,"l","-agú",true),1,2)
td(get_forms(pp.pspart,"l", _,true))
td(get_forms(pp.pspart,"l","-agún",true))
_tr()
th("past")
td(get_forms(pp.pspart,"l","-âlei",true))
td(get_forms(pp.pspart,"l","-âlen",true))
td(get_forms(pp.pspart,"l","-âleș",true),1,2)
td(get_forms(pp.pspart,"l","-âle",true))
td(get_forms(pp.pspart,"l","-âluos",true))
td(get_forms(pp.pspart,"l","-âluote",true))
td(get_forms(pp.pspart,"l","-âlú",true),1,3)
td(get_forms(pp.pspart,"l","-âlún",true))
_tr()
th("subjunctive",2,1)
th("non-past")
td(get_forms(pp.pspart,"l","-agai",true))
td(get_forms(pp.pspart,"l","-agá",true))
td(get_forms(pp.pspart,"l","-agaș",true),1,2)
td(get_forms(pp.pspart,"l","-aga",true))
td(get_forms(pp.pspart,"l","-agavuos",true))
td(get_forms(pp.pspart,"l","-agavuote",true))
td(get_forms(pp.pspart,"l","-agavú",true),1,3)
td(get_forms(pp.pspart,"l","-agavún",true))
_tr()
th("past")
td(get_forms(pp.pspart,"l","-âlai",true))
td(get_forms(pp.pspart,"l","-âlain",true))
td(get_forms(pp.pspart,"l","-âlaiș",true),1,2)
td(get_forms(pp.pspart,"l","-âlai",true))
td(get_forms(pp.pspart,"l","-âlavuos",true))
td(get_forms(pp.pspart,"l","-âlavuote",true))
td(get_forms(pp.pspart,"l","-âlavú",true),1,3)
td(get_forms(pp.pspart,"l","-âlavún",true))
_tr()
th("optative",2,1)
th("non-past")
td(get_forms(pp.pspart,"l","-agúe",true))
td(get_forms(pp.pspart,"l","-agova",true))
td(get_forms(pp.pspart,"l","-agúș",true),1,2)
td(get_forms(pp.pspart,"l","-agú",true))
td(get_forms(pp.pspart,"l","-agovuos",true))
td(get_forms(pp.pspart,"l","-agovuote",true))
td(get_forms(pp.pspart,"l","-agovú",true),1,3)
td(get_forms(pp.pspart,"l","-agovún",true))
_tr()
th("past")
td(get_forms(pp.pspart,"l","-âlevei",true))
td(get_forms(pp.pspart,"l","-âleven",true))
td(get_forms(pp.pspart,"l","-âleveș",true),1,2)
td(get_forms(pp.pspart,"l","-âleve",true))
td(get_forms(pp.pspart,"l","-âlevuos",true))
td(get_forms(pp.pspart,"l","-âlevuote",true))
td(get_forms(pp.pspart,"l","-âlevú",true),1,3)
td(get_forms(pp.pspart,"l","-âlevún",true))
tr_()
tr_()
add("</table>")
add("</table>")
Line 804: Line 985:
=p.conjugate(mw.getCurrentFrame():newChild{title="whatever",args={"deat","de",["pl"]="di","diș","deti","dev",["t"]="intr",["altnonfin"]="hellu",["altnonfin_note"]="uwu",["altnonfin2"]="hella",["altnonfin2_note"]="owo",["pre"]="fjø", "deruot", "detruvi"}})
=p.conjugate(mw.getCurrentFrame():newChild{title="whatever",args={"deat","de",["pl"]="di","diș","deti","dev",["t"]="intr",["altnonfin"]="hellu",["altnonfin_note"]="uwu",["altnonfin2"]="hella",["altnonfin2_note"]="owo",["pre"]="fjø", "deruot", "detruvi"}})


{| class="mw-collapsible mw-collapsed wikitable inflection table" width=100% style="text-align: center"
! colspan="14" | Compound forms of ''{{{1}}}'' (active voice) &nbsp;
|-
! rowspan="4" colspan="3" | finite forms
! colspan="5" | singular
! colspan="5" | plural
! humble
|-
! rowspan="2" | first
! colspan="2" | second
! rowspan="2" | third
! rowspan="2" | depersonal
! colspan="2" | first
! rowspan="2" | second
! rowspan="2" | third
! rowspan="2" | depersonal
! rowspan="2" | second
|-
! informal
! formal
! inclusive
! exclusive
|-
! ''ú''
! ''re''
! ''lește''
! ''vâs'', ''vara''
! ''gjei, gjen, gjeș …''
! ''dzun'', ''sted''
! ''dzate''
! ''sjáște''
! ''vír'', ''vara''
! ''gjes, gjete, gje, gjen …''
! ''sja'', ''lair''
|-
! rowspan="7" | continuous
! colspan="2" | infinitive
| colspan="12" | {{wl-rad|{{{4}}}vú}} {{wl-rad|vat}}
|-
! rowspan="2" | indicative
! non-past
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vage}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vaga}}
| colspan="2" | {{wl-rad|{{{4}}}vú}} {{wl-rad|vaș}}
| {{wl-rad|{{{4}}}vú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vaguos}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vaguote}}
| colspan="2" | {{wl-rad|{{{4}}}vú}} {{wl-rad|vagú}}
| {{wl-rad|{{{4}}}vú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagún}}
|-
! past
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlei}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlen}}
| colspan="2" | {{wl-rad|{{{4}}}vú}} {{wl-rad|hâleș}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâle}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâluos}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâluote}}
| colspan="3" | {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlún}}
|-
! rowspan="2" | subjunctive
! non-past
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagai}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagá}}
| colspan="2" | {{wl-rad|{{{4}}}vú}} {{wl-rad|vagaș}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vaga}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagavuos}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagavuote}}
| colspan="3" | {{wl-rad|{{{4}}}vú}} {{wl-rad|vagavú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagavún}}
|-
! past
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlai}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlain}}
| colspan="2" | {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlaiș}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlai}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlavuos}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlavuote}}
| colspan="3" | {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlavú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlavún}}
|-
! rowspan="2" | optative
! non-past
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagúe}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagova}}
| colspan="2" | {{wl-rad|{{{4}}}vú}} {{wl-rad|vagúș}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagovuos}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagovuote}}
| colspan="3" | {{wl-rad|{{{4}}}vú}} {{wl-rad|vagovú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|vagovún}}
|-
! past
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlevei}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâleven}}
| colspan="2" | {{wl-rad|{{{4}}}vú}} {{wl-rad|hâleveș}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâleve}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlevuos}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlevuote}}
| colspan="3" | {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlevú}}
| {{wl-rad|{{{4}}}vú}} {{wl-rad|hâlevún}}
|-
|-
! rowspan="7" | perfective
! rowspan="7" | perfective