Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
chartBrush.on('update', (added, removed) => {
var selection = pq.selections(chartBrush)[0];
//console.log(selection);
if (selection.method === 'resetMadeSelections') {
//console.log
chartBrush.end();
that.backendApi.clearSelections();
} else
if (selection.method === 'selectHyperCubeValues') {
that.selectValues(selection.params[1], selection.params[2], false);
} else
if (selection.method === 'rangeSelectHyperCubeValues') {
if (chartBrush.isActive) {
that.backendApi.selectRange(selection.params[1], true);
} else {
}