Module:rad-stem/templates: Difference between revisions

m
ਕੋਈ ਸੋਧ ਸਾਰ ਨਹੀਂ
No edit summary
mNo edit summary
Line 452: Line 452:
end
end
local function get_forms(stem, ending)
local function get_forms(stem, ending, regex1, regex2)
local temp = {}
local temp = {}
ending = ending or ""
ending = ending or ""
regex1 = regex1 or ""
regex2 = regex2 or ""
regex3 = regex3 or ""
regex4 = regex4 or ""
if type(stem) == "table" then
if type(stem) == "table" then
for i, form in ipairs(stem) do
for i, form in ipairs(stem) do
temp[i] = {['word'] = form['word'] .. ending, ['note'] = form['note']}
temp[i] = {['word'] = mw.ustring.gsub(form['word'] .. ending, regex1, regex2), ['note'] = form['note']}
end
end
elseif type(stem) == "string" then
elseif type(stem) == "string" then
temp = stem .. ending
temp = mw.ustring.gsub(stem .. ending, regex1, regex2)
end
end
return rad_link_IPA(temp)
return rad_link_IPA(temp)
Line 483: Line 487:
th("", 1, 11)
th("", 1, 11)
else
else
td(get_forms(pp.nonfin,"a"), 1, 11)
td(get_forms(pp.inf,"a","uta$","ûta"), 1, 11)
end
end
_tr()
_tr()
th("supine", 1, 3)
th("supine", 1, 3)
td(get_forms(pp.nonfin,"úr"), 1, 11)
td(get_forms(pp.inf,"úr", "utúr$","ûtúr"), 1, 11)
_tr()
_tr()
th("participle", 4, 1)
th("participle", 4, 1)
Line 542: Line 546:
th("imperative", 1, 2)
th("imperative", 1, 2)
th()
th()
if pp.imp then
if pp.imp and pp.a ~= pp.imp then
td(get_forms(pp.imp))
elseif pp.vstem then
td(get_forms(pp.a, "", "va$", "ja"))
else
td(get_forms(pp.a), 2, 1)
td(get_forms(pp.a), 2, 1)
else
td(get_forms(pp.imp))
end
end
td(get_forms(pp['2s'],"úș"))
td(get_forms(pp['2s'],"úș"))
Line 551: Line 557:
td(get_forms(pp.pl or pp['2s'],"uoș"))
td(get_forms(pp.pl or pp['2s'],"uoș"))
th()
th()
td(get_forms(pp.o,""))
td(get_forms(pp['2s'],"ovú", "([au])ovú$", "%1òvú"))
th("", 1, 2)
th("", 1, 2)
td(get_forms(pp.pl or pp['2s'],"úr"))
td(get_forms(pp.pl or pp['2s'],"úr"))
Line 558: Line 564:
th("non-past")
th("non-past")
td(get_forms(pp['1s']))
td(get_forms(pp['1s']))
if pp.imp ~= pp.a then td(get_forms(pp.a)) end
if (pp.imp and pp.a ~= pp.imp) or pp.vstem then td(get_forms(pp.a)) end
if pp['3s'] == (pp.depers or pp['2s']) then
if pp['3s'] == (pp.depers or pp['2s']) then
td(get_forms(pp['3s']), 1, 3)
td(get_forms(pp['3s']), 1, 3)
Line 566: Line 572:
end
end
local temp_height = 1
local temp_height = 1
if get_forms(pp.pl or pp['2s'],"ú") == get_forms(pp.upst) then temp_height = 2 end
if get_forms(pp.pl or pp['2s'],"ú") == get_forms(pp.pst,"ú","[uú]ú$","ủ") then temp_height = 2 end
td(get_forms(pp.pl or pp['2s'],"uos"), temp_height)
td(get_forms(pp.pl or pp['2s'],"uos"), temp_height)
td(get_forms(pp.pl or pp['2s'],"uote"), temp_height)
td(get_forms(pp.pl or pp['2s'],"uote"), temp_height)
Line 572: Line 578:
td(get_forms(pp.pl or pp['2s'],"ún"), temp_height)
td(get_forms(pp.pl or pp['2s'],"ún"), temp_height)
_tr()
_tr()
th("past")
if pp.epst then
if pp.epst then
td(get_forms(pp.epst,"e"))
td(get_forms(pp.epst,"e"))
Line 583: Line 590:
td(get_forms(pp.pst,"e"))
td(get_forms(pp.pst,"e"))
end
end
if get_forms(pp.pl or pp['2s'],"ú") ~= get_forms(pp.pst,"ú","[uú]ú$","ủ") then
td(get_forms(pp.pst,"uos","[uú]uos$","ủos"))
td(get_forms(pp.pst,"uote","[uú]uote$","ủote"))
td(get_forms(pp.pst,"ú","[uú]ú$","ủ"),1,3)
td(get_forms(pp.pst,"ún","[uú]ún$","ủn"))
end
_tr()
th("subjunctive",2,1)
th("non-past")
local aidentical = false
if pp.vstem then
if get_forms(pp['2s'],"ai","avai$","áe") == get_forms(pp.pst,"ai") then
td(get_forms(pp['2s'],"ai","avai$","áe"),2)
aidentical = true
else
td(get_forms(pp['2s'],"ai","avai$","áe"))
end
td(get_forms(pp['2s'],"á","avá$","áva"))
else
if get_forms(pp['2s'],"ai") == get_forms(pp.pst,"ai") then
td(get_forms(pp['2s'],"ai"),2)
aidentical = true
else
td(get_forms(pp['2s'],"ai"))
end
td(get_forms(pp['2s'],"á"))
end
td(get_forms(pp.a,"ș"),1,2)
td(get_forms(pp.a))
temp_height = 1
if pp.a == pp.apst then temp_height = 2 end
td(get_forms(pp.a,"vuos"), temp_height)
td(get_forms(pp.a,"vuote"), temp_height)
td(get_forms(pp.a,"vú"), temp_height, 3)
td(get_forms(pp.a,"vún"), temp_height)
_tr()
th("past")
if not aidentical then td(get_forms(pp.pst,"ai")) end
td(get_forms(pp.pst,"ain"))
td(get_forms(pp.pst,"aiș"),1,2)
td(get_forms(pp.pst,"ai"))
if pp.a ~= pp.apst then
td(get_forms(pp.apst,"vuos"))
td(get_forms(pp.apst,"vuote"))
td(get_forms(pp.apst,"vú"),1,3)
td(get_forms(pp.apst,"vún"))
end
_tr()
th("optative",2,1)
th("non-past")
td(get_forms(pp['2s'],"úe"))
td(get_forms(pp['2s'],"ova", "([au])ova$", "%1òva"))
td(get_forms(pp['2s'],"úș"),1,2)
td(get_forms(pp['2s'],"ú"))
td(get_forms(pp['2s'],"ovuos", "([au])ovuos$", "%1òvuos"))
td(get_forms(pp['2s'],"ovuote", "([au])ovuote$", "%1òvuote"))
td(get_forms(pp['2s'],"ovú", "([au])ovú$", "%1òvú"),1,3)
td(get_forms(pp['2s'],"ovún", "([au])ovún$", "%1òvún"))
_tr()
th("past")
if pp.epst then
td(get_forms(pp.epst,"vei"))
td(get_forms(pp.epst,"ven"))
td(get_forms(pp.epst,"veș"),1,2)
td(get_forms(pp.epst,"ve"))
td(get_forms(pp.epst,"vuos"))
td(get_forms(pp.epst,"vuote"))
td(get_forms(pp.epst,"vú"),1,3)
td(get_forms(pp.epst,"vún"))
else
td(get_forms(pp.pst,"evei"))
td(get_forms(pp.pst,"even"))
td(get_forms(pp.pst,"eveș"),1,2)
td(get_forms(pp.pst,"eve"))
td(get_forms(pp.pst,"evuos"))
td(get_forms(pp.pst,"evuote"))
td(get_forms(pp.pst,"evú"),1,3)
td(get_forms(pp.pst,"evún"))
end
_tr()
th("habitual",6,1)
th("indicative",2,1)
th("non-past")
td(get_forms(pp.r,"iè"))
td(get_forms(pp.r,"in"))
td(get_forms(pp.r,"iș"),1,2)
td(get_forms(pp.r,"i"))
temp_height = 1
if get_forms(pp.pl or pp['2s'],"ú") == get_forms(pp.pst,"ú","[uú]ú$","ủ") then temp_height = 2 end
td(get_forms(pp.pl or pp['2s'],"úris"), temp_height)
td(get_forms(pp.pl or pp['2s'],"úrite"), temp_height)
td(get_forms(pp.pl or pp['2s'],"úri"), temp_height, 3)
td(get_forms(pp.pl or pp['2s'],"úrin"), temp_height)
_tr()
th("past")
if pp.epst then
td(get_forms(pp.epst,"riè"))
td(get_forms(pp.epst,"rin"))
td(get_forms(pp.epst,"riș"),1,2)
td(get_forms(pp.epst,"ri"))
else
td(get_forms(pp.pst,"eriè"))
td(get_forms(pp.pst,"erin"))
td(get_forms(pp.pst,"eriș"),1,2)
td(get_forms(pp.pst,"eri"))
end
if get_forms(pp.pl or pp['2s'],"ú") ~= get_forms(pp.pst,"ú","[uú]ú$","ủ") then
td(get_forms(pp.pst,"úris","[uú]úris$","ủris"))
td(get_forms(pp.pst,"úrite","[uú]úrite$","ủrite"))
td(get_forms(pp.pst,"úri","[uú]úri$","ủri"),1,3)
td(get_forms(pp.pst,"úrin","[uú]úrin$","ủrin"))
end
_tr()
th("subjunctive",2,1)
th("non-past")
td(get_forms(pp.a,"riè"))
td(get_forms(pp.a,"rin"))
td(get_forms(pp.a,"riș"),1,2)
td(get_forms(pp.a,"ri"))
temp_height = 1
if pp.a == pp.apst then temp_height = 2 end
td(get_forms(pp.a,"vúris"), temp_height)
td(get_forms(pp.a,"vúrite"), temp_height)
td(get_forms(pp.a,"vúri"), temp_height, 3)
td(get_forms(pp.a,"vúrin"), temp_height)
_tr()
th("past")
td(get_forms(pp.pst,"airiè"))
td(get_forms(pp.pst,"airin"))
td(get_forms(pp.pst,"airiș"),1,2)
td(get_forms(pp.pst,"airi"))
if pp.a ~= pp.apst then
td(get_forms(pp.apst,"vúris"))
td(get_forms(pp.apst,"vúrite"))
td(get_forms(pp.apst,"vúri"),1,3)
td(get_forms(pp.apst,"vúri"))
end
--[[
--[[
=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"}})
=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ø"}})
<!--
 
-->{{#ifeq: {{{pl|{{{2}}}}}}uo|{{{upst2|{{{3}}}uo}}}||<td>{{wl-rad-IPA|{{{upst2|{{{3}}}uo}}}s}}</td>}}<!--
-->{{#ifeq: {{{pl|{{{2}}}}}}uo|{{{upst2|{{{3}}}uo}}}||<td>{{wl-rad-IPA|{{{upst2|{{{3}}}uo}}}te}}</td>}}<!--
-->{{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}||<td colspan="3">{{wl-rad-IPA|{{{upst1|{{{3}}}ú}}}}}</td>}}<!--
-->{{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}||<td>{{wl-rad-IPA|{{{upst1|{{{3}}}ú}}}n}}</td>}}
|-
! rowspan="2" | subjunctive
! non-past
| {{#ifeq: {{{ai|{{{2}}}ai}}}|{{{aipst|{{{3}}}ai}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{ai|{{{2}}}ai}}}}}
| {{wl-rad-IPA|{{{aa|{{{2}}}á}}}}}
| colspan="2" | {{wl-rad-IPA|{{{a|{{{2}}}a}}}ș}}
| {{wl-rad-IPA|{{{a|{{{2}}}a}}}}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{a|{{{2}}}a}}}vuos}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{a|{{{2}}}a}}}vuote}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2"|}} colspan="3" | {{wl-rad-IPA|{{{a|{{{2}}}a}}}vú}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{a|{{{2}}}a}}}vún}}
|-
! past<!--
-->{{#ifeq: {{{ai|{{{2}}}ai}}}|{{{aipst|{{{3}}}ai}}}||<td>{{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}}}</td>}}
| {{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}n}}
| colspan="2" | {{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}ș}}
| {{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td>{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vuos}}</td>}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td>{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vuote}}</td>}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td colspan="3">{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vú}}</td>}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td>{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vún}}</td>}}
|-
! rowspan="2" | optative
! non-past
| {{wl-rad-IPA|{{{2}}}úe}}
| {{wl-rad-IPA|{{{o|{{{2}}}o}}}va}}
| colspan="2" | {{wl-rad-IPA|{{{2}}}úș}}
| {{wl-rad-IPA|{{{2}}}ú}}
| {{wl-rad-IPA|{{{o|{{{2}}}o}}}vuos}}
| {{wl-rad-IPA|{{{o|{{{2}}}o}}}vuote}}
| colspan="3" | {{wl-rad-IPA|{{{o|{{{2}}}o}}}vú}}
| {{wl-rad-IPA|{{{o|{{{2}}}o}}}vún}}
|-
! past
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}vei}}
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}ven}}
| colspan="2" | {{wl-rad-IPA|{{{epst|{{{3}}}e}}}veș}}
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}ve}}
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}vuos}}
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}vuote}}
| colspan="3" | {{wl-rad-IPA|{{{epst|{{{3}}}e}}}vú}}
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}vún}}
|-
! rowspan="6" | habitual
! rowspan="2" | indicative
! non-past
| {{wl-rad-IPA|{{{r|{{{depers|{{{2}}}}}}r}}}iè}}
| {{wl-rad-IPA|{{{r|{{{depers|{{{2}}}}}}r}}}in}}
| colspan="2" | {{wl-rad-IPA|{{{r|{{{depers|{{{2}}}}}}r}}}iș}}
| {{wl-rad-IPA|{{{r|{{{depers|{{{2}}}}}}r}}}i}}
| {{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{pl|{{{2}}}}}}úris}}
| {{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{pl|{{{2}}}}}}úrite}}
| {{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}|rowspan="2"|}} colspan="3" | {{wl-rad-IPA|{{{pl|{{{2}}}}}}úri}}
| {{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{pl|{{{2}}}}}}úrin}}
|-
! past
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}riè}}
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}rin}}
| colspan="2" | {{wl-rad-IPA|{{{epst|{{{3}}}e}}}riș}}
| {{wl-rad-IPA|{{{epst|{{{3}}}e}}}ri}}<!--
-->{{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}||<td>{{wl-rad-IPA|{{{upst1|{{{3}}}ú}}}ris}}}}<!--
-->{{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}||<td>{{wl-rad-IPA|{{{upst1|{{{3}}}ú}}}rite}}}}<!--
-->{{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}||<td colspan="3">{{wl-rad-IPA|{{{upst1|{{{3}}}ú}}}ri}}}}<!--
-->{{#ifeq: {{{pl|{{{2}}}}}}ú|{{{upst1|{{{3}}}ú}}}||<td>{{wl-rad-IPA|{{{upst1|{{{3}}}ú}}}rin}}}}
|-
! rowspan="2" | subjunctive
! non-past
| {{wl-rad-IPA|{{{a|{{{2}}}a}}}riè}}
| {{wl-rad-IPA|{{{a|{{{2}}}a}}}rin}}
| colspan="2" | {{wl-rad-IPA|{{{a|{{{2}}}a}}}riș}}
| {{wl-rad-IPA|{{{a|{{{2}}}a}}}ri}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{a|{{{2}}}a}}}vúris}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{a|{{{2}}}a}}}vúrite}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2"|}} colspan="3" | {{wl-rad-IPA|{{{a|{{{2}}}a}}}vúri}}
| {{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}|rowspan="2" {{!}}|}} {{wl-rad-IPA|{{{a|{{{2}}}a}}}vúrin}}
|-
! past
| {{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}riè}}
| {{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}rin}}
| colspan="2" | {{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}riș}}
| {{wl-rad-IPA|{{{aipst|{{{3}}}ai}}}ri}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td>{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vúris}}}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td>{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vúrite}}}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td colspan="3">{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vúri}}}}<!--
-->{{#ifeq: {{{a|{{{2}}}a}}}|{{{apst|{{{3}}}a}}}||<td>{{wl-rad-IPA|{{{apst|{{{3}}}a}}}vúrin}}}}
|-
|-
! rowspan="2" | optative
! rowspan="2" | optative