Module:Graph: Difference between revisions

Content deleted Content added
looks like a typo, "chartype" appears nowhere else in the module
Tag: Reverted
This needs to use the parent frame
 
(2 intermediate revisions by 2 users not shown)
Line 622:
-- if there are multiple series, connect linewidths to series
if chartTypechartype == "line" then
chartvis.properties.update["strokeWidth"].field = "series"
end
Line 1,418:
return mw.uri.encode(mw.text.decode(mw.text.trim(frame.args[1])), 'PATH')
end
 
function p.chartCompatible(frame)
local not_chart_args = {
"colors",
"xAxisMin",
"xAxisMax",
"yAxisMin",
"yAxisMax",
"xAxisAngle",
"xScaleType",
"yScaleType",
"linewidth",
"linewidths",
"showSymbols",
"symbolsShape",
"symbolsNoFill",
"symbolsStroke",
"showValues",
"innerRadius",
"xGrid",
"yGrid",
"annotations"
}
 
local pframe = frame:getParent()
local b = 0
local t = 0
 
for t=1,18,1 do
if pframe.args[not_chart_args[t]] then
break
else
b = b + 1
end
t = t + 1
end
if b == 18 then
if pframe.args["name"] then
return "[[Category:Graphs to Port]]"
else
return "[[Category:Graphs to be ported needing names]]"
end
end
end
 
return p