Modul:Citation/CS1: Perbedaan antara revisi
Konten dihapus Konten ditambahkan
Tidak ada ringkasan suntingan |
Tidak ada ringkasan suntingan |
||
Baris 1.836:
name = table.concat (language_list, ', ') -- and concatenate with '<comma><space>' separators
end
if 'indonesian' == name:lower() or 'indonesia' == name:lower() or 'bahasa indonesia' == name:lower() then
return ''; -- if one language and that language is Indonesian return an enpty string (no annotation)
end
Baris 2.962 ⟶ 2.958:
end
--[[Look in the list of iso639-1 language codes to see if the value provided in the language parameter matches one of them. If a match is found,
use that value; if not, then use the value that was provided with the language parameter.
Categories are assigned in a manner similar to the {{xx icon}} templates - categorizes only mainspace citations and only when the language code is not 'en' (English).
]]
if is_set (Language) then
-- Poner en minúsculas el primer caracter del idioma si está en mayúsculas
Language = Language:gsub("^%u", string.lower)
if Language == 'indonesia' or Language == 'indonesian' or Language == 'id' or Language:match('^id%-.*') then
Language=""; -- No mostrar el idioma español
else
local name = mw.language.fetchLanguageName( Language:lower(), "id" ); -- experiment: this seems to return correct ISO 639-1 language names
if is_set (name) then
Language=" " .. wrap( 'language', name );
else
Language=" " .. wrap( 'language', Language ); -- no match, use parameter's value
end
end
else
Language="";
end
|