Module:IPA: Difference between revisions

ਕੋਈ ਸੋਧ ਸਾਰ ਨਹੀਂ
No edit summary
No edit summary
Line 60: Line 60:
out = out .. "[[" .. language_pron .. "|" .. i_ipa .. "]]"
out = out .. "[[" .. language_pron .. "|" .. i_ipa .. "]]"
out = mw.ustring.gsub(out, "(%<%/span%>)", "]]%1")
out = mw.ustring.gsub(out, "(%<%/span%>)", "]]%1")
out = mw.ustring.gsub(out, '.(%<span class%=%"' .. class .. '%"%>)', "%1[[" .. language_pron .. "|")
out = mw.ustring.gsub(out, '(.)(%<span class%=%"' .. class .. '%"%>)', "%1%2[[" .. language_pron .. "|")
else
else
out = out .. i_ipa
out = out .. i_ipa
end
end
out = out .. "</span>"
out = out .. "</span>"
out = mw.ustring.gsub(out, '%<span[^%>]+%>%[%[[^%|]+%|%]%]%<%/span%>', "")
out = mw.ustring.gsub(out, '%<span[^%>]+%><%/span%>', "")
end
end
return out
return out
Line 89: Line 91:
return export
return export
--[[
--[[
=p.show(mw.getCurrentFrame():newChild{title="parent", args={"rad", "nom", ["nopre"] = "true"}}:newChild{title="child"})
=p.show(mw.getCurrentFrame():newChild{title="parent", args={"rad", "/ˈvydɛ/ *(''officially'')*", ["nopre"] = "true"}}:newChild{title="child"})
]]--
]]--