I am trying to capture click event on a nvd3 stacked area chart. I am able to capture tooltip show tooltip hide events. I want to capture click event and get the clicked point info. Please help. PLUNKER_LINK
my chart option is :
chart: {
type: 'stackedAreaChart',
height: 450,
x: function (d) { return d[0]; },
y: function (d) { return d[1]; },
showValues: true,
valueFormat: function (d) { return d3.format(',.4f')(d); },
dispatch: {
tooltipShow: function (e) { console.log('! tooltip SHOW !') },
tooltipHide: function (e) { console.log('! tooltip HIDE !') },
beforeUpdate: function (e) { console.log('! before UPDATE !') },
elementClick: function (e) { alert('clicked');}
}
}
};