Skip to content

Instantly share code, notes, and snippets.

@dbergey
Forked from anonymous/gist:2172307
Created March 23, 2012 16:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dbergey/2172335 to your computer and use it in GitHub Desktop.
Save dbergey/2172335 to your computer and use it in GitHub Desktop.
if (type == 'blah')
var conditionalArea = {
stuff: "nonsense"
};
else {
var conditionalArea = {
fillColor: {
linearGradient: [0, 0, 0, 300],
stops: [
[0, Highcharts.getOptions().colors[0]],
[1, 'rgba(2,0,0,0)']
]
},
lineWidth: 1,
marker: {
enabled: false,
states: {
hover: {
enabled: true,
radius: 5
}
}
},
shadow: false,
states: {
hover: {
lineWidth: 1
}
}
}
}
{
plotOptions: {
area: conditionalArea,
other: stuff
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment