We are using Charts module along with Financial/Stock charts.
When showing multiple line charts or mutliple series charts in financial chart, is there a way to hide a particular series on click of the relevant legend item.
Please let us know your inputs!
What I can suggest you in order to achieve your requirement is to handle IgxFinancialChartComponent’s seriesAdded event and assign series' legendItemTemplate where you can customize the legend item content and add a checkbox to toggle series visibility.Please take a look at this sample.stackblitz.com/.../github-8zw4gw-u29ims
Thanks for the response and providing a sample. It works but I found an issue with it after zoom in and zoom out.
The checkbox toggle is not working once we uncheck one series and then zoom in and out and check that again.
Steps to reproduce the issue:
I have reproduced the same in the stackblitz sample provided by you.
Please let us know the fix for this problem... otherwise the given solution will be not useful...
I have added series.styleUpdated() after the series visibility is changed in the checkbox's onchange event.Can you please try one more time?
Thanks for the quick fix! It worked fine now!