Module:Navbox: திருத்தங்களுக்கு இடையிலான வேறுபாடு

உள்ளடக்கம் நீக்கப்பட்டது உள்ளடக்கம் சேர்க்கப்பட்டது
bodystyle fix
correct fix for empty args
வரிசை 16:
return (mw.ustring.gsub(s, "^%s*(.-)%s*$", "%1"))
end
 
function addTableRow(tbl)
-- If any other rows have already been added, then we add a 2px gutter row.
வரிசை 264:
--
function renderTrackingCategories(builder)
local frame = mw.getCurrentFrame()
if not frame then return end
வரி 351 ⟶ 353:
for k, v in pairs(args) do
iflocal vlistnum == ('' then.. k):match('^list(%d+)$')
if listnum then table.insert(listnums, tonumber(listnum)) end
-- ParserFunctions considers the empty string to be false, so to preserve the previous
-- behavior of {{navbox}}, change any empty arguments to nil, so Lua will consider
-- them false too.
args[k] = nil
else
local listnum = ('' .. k):match('^list(%d+)$')
if listnum then table.insert(listnums, tonumber(listnum)) end
end
end
table.sort(listnums)
வரி 400 ⟶ 395:
end
function p.navbox(frmframe)
-- ParserFunctions considers the empty string to be false, so to preserve the previous
frame = frm
-- behavior of {{navbox}}, change any empty arguments to nil, so Lua will consider
return p._navbox(frame:getParent().args)
-- them false too.
local args = {}
for k, v in pairs(frame:getParent().args) do
if v ~= '' then
args[k] = nilv
elseend
end
return p._navbox(frame:getParent().args)
end
"https://tamilar.wiki/w/Module:Navbox" இலிருந்து மீள்விக்கப்பட்டது