Module:snon-common: Difference between revisions
No edit summary |
No edit summary |
||
| Line 22: | Line 22: | ||
if mw.ustring.find(word_l, "^[bcdfgmptsnlrv]") then | if mw.ustring.find(word_l, "^[bcdfgmptsnlrv]") then | ||
ret.len = mw.ustring.gsub(word, "^(.)", "%1h") | ret.len = mw.ustring.gsub(word, "^(.)", "%1h") | ||
elseif mw.ustring.find(word_l, "^-[bcdfgmptsnlrv]") then | elseif mw.ustring.find(word_l, "^-[bcdfgmptsnlrv]") then | ||
ret.len = mw.ustring.gsub(word, "^(..)", "%1h") | ret.len = mw.ustring.gsub(word, "^(..)", "%1h") | ||
| Line 31: | Line 29: | ||
if mw.ustring.find(word_l, "^[b]") then | if mw.ustring.find(word_l, "^[b]") then | ||
ret.ecl = mw.ustring.gsub(word, "^(.)", "m") | ret.ecl = mw.ustring.gsub(word, "^(.)", "m") | ||
elseif mw.ustring.find(word_l, "^[ | elseif mw.ustring.find(word_l, "^[pv]") then | ||
ret.ecl = mw.ustring.gsub(word, "^(.)", "b") | ret.ecl = mw.ustring.gsub(word, "^(.)", "b") | ||
elseif mw.ustring.find(word_l, "^[f]") then | elseif mw.ustring.find(word_l, "^[f]") then | ||
ret.ecl = mw.ustring.gsub(word, "^(.)", "v") | ret.ecl = mw.ustring.gsub(word, "^(.)", "v") | ||
elseif mw.ustring.find(word_l, "^[B]") then | |||
ret.ecl = mw.ustring.gsub(word, "^(.)", "M") | |||
elseif mw.ustring.find(word_l, "^[PV]") then | |||
ret.ecl = mw.ustring.gsub(word, "^(.)", "B") | |||
elseif mw.ustring.find(word_l, "^[F]") then | |||
ret.ecl = mw.ustring.gsub(word, "^(.)", "V") | |||
end | end | ||
end | end | ||