"ഘടകം:Location map" എന്ന താളിന്റെ പതിപ്പുകൾ തമ്മിലുള്ള വ്യത്യാസം

Content deleted Content added
merge namespace translations
Document what "temporarily" means in the lat/long section
വരി 1:
require('ഘടകംModule:No globals')
 
local p = {}
 
local getArgs = require('ഘടകംModule:Arguments').getArgs
 
local function round(n, decimals)
വരി 14:
error('The name of the location map definition to use must be specified', 2)
end
local moduletitle = mw.title.new('ഘടകംModule:Location map/data/' .. map)
if not moduletitle then
error(string.format('%q is not a valid name for a location map definition', map), 2)
elseif moduletitle.exists then
local mapData = mw.loadData('ഘടകംModule:Location map/data/' .. map)
return function(name, params)
if name == nil then
return 'ഘടകംModule:Location map/data/' .. map
elseif mapData[name] == nil then
return ''
വരി 30:
end
end
elseif mw.title.new('ഫലകംTemplate:Location map ' .. map).exists then
local cache = {}
if type(frame) ~= 'table' or type(frame.expandTemplate) ~= 'function' then
വരി 40:
else
if name == nil then
return 'ഫലകംTemplate:Location map ' .. map
elseif cache[name] == nil then
cache[name] = frame:expandTemplate{title = 'Location map ' .. map, args = { name }}
വരി 48:
end
else
error('Unable to find the specified location map definition. Neither "ഘടകംModule:Location map/data/' .. map .. '" nor "ഫലകംTemplate:Location map ' .. map .. '" exists', 2)
end
end
വരി 337:
function p.mark(frame, args, map)
if not args then
args = getArgs(frame, {wrappers = 'ഫലകംTemplate:Location map~'})
end
if not map then
വരി 346:
latitude = decdeg(args.lat_deg, args.lat_min, args.lat_sec, args.lat_dir, args.lat, 'latitude')
if args.coordinates then
-- Temporarily removed to facilitate infobox conversion. See [[Wikipedia:Coordinates in infoboxes]]
 
-- if longitude or latitude then
-- error('Coordinates from [[ഘടകംModule:Coordinates]] and individual coordinates cannot both be provided')
-- end
longitude = coord2text('longitude', args.coordinates)
വരി 431:
function p.main(frame, args, map)
if not args then
args = getArgs(frame, {wrappers = 'ഫലകംTemplate:Location map', valueFunc = p.valueFunc})
end
if args.useWikidata == nil then
"https://ml.wikipedia.org/wiki/ഘടകം:Location_map" എന്ന താളിൽനിന്ന് ശേഖരിച്ചത്