Remove unwanted legend details from widgets
Hi all,
Another tip from Kobbi Gal below (Thank Kobbi!).
For cases when we want to not display legend details for specific series. We can add a few lines to the widget script to do so.
As an example, we have the following Area Chart and we want to remove the Total Cost series:
Adding the following to the widget script:
|
Where the '1' inside
args.options.series[ 1 ].showInLegend = false ;
|
refers to the index of the series array.
The result, Total Cost series is gone from the legend:
-
Hi Oxana,
Can we change the Legend shape from square to circle? Irrespective of series' marker shape, legend is always coming in square.
I tried following `http://jsfiddle.net/sureshuvv/ucw81eb2/2/`. It was able to hide the actual legend, but not populating the linked one.
Looking forward to your reply on this.
Thank you,
Suresh Ungarala
Please sign in to leave a comment.
Comments
1 comment