Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
this.tooltipContainerSelector = '.scatter-plot .metadata-group';
break;
case ChartType.Sparkline:
this.chart = sparkline();
this.chartSelector = '.sparkline';
this.chartClickSelector = ''; // No click selector.
this.tooltipContainerSelector = ''; // No tooltip selector.
break;
case ChartType.StackedArea:
this.chart = stackedArea();
this.chartSelector = '.stacked-area';
this.chartClickSelector = ''; // No click selector.
this.tooltipContainerSelector = '.stacked-area .metadata-group .vertical-marker-container';
break;
case ChartType.StackedBar:
this.chart = stackedBar();
this.chartSelector = '.stacked-bar';
this.chartClickSelector = '.stacked-bar .bar';
this.tooltipContainerSelector = '.stacked-bar .metadata-group';
break;
case ChartType.Step:
this.chart = step();
this.chartSelector = '.step-chart';
this.chartClickSelector = '.step-chart .step';
this.tooltipContainerSelector = '.step-chart .metadata-group';
break;
}
}
this.tooltipContainerSelector = '.scatter-plot .metadata-group';
break;
case ChartType.Sparkline:
this.chart = sparkline();
this.chartSelector = '.sparkline';
this.chartClickSelector = ''; // No click selector.
this.tooltipContainerSelector = ''; // No tooltip selector.
break;
case ChartType.StackedArea:
this.chart = stackedArea();
this.chartSelector = '.stacked-area';
this.chartClickSelector = ''; // No click selector.
this.tooltipContainerSelector = '.stacked-area .metadata-group .vertical-marker-container';
break;
case ChartType.StackedBar:
this.chart = stackedBar();
this.chartSelector = '.stacked-bar';
this.chartClickSelector = '.stacked-bar .bar';
this.tooltipContainerSelector = '.stacked-bar .metadata-group';
break;
case ChartType.Step:
this.chart = step();
this.chartSelector = '.step-chart';
this.chartClickSelector = '.step-chart .step';
this.tooltipContainerSelector = '.step-chart .metadata-group';
break;
}
};
ChartComponent.prototype.isDictionary = function (obj) {
private drawChart() {
this.stackedBar = stackedBar();
this.chartTooltip = tooltip();
let stackedBarContainer = d3Selection.select(this.el).select('.stacked-bar-chart-container'),
containerWidth = stackedBarContainer.node() ? stackedBarContainer.node().getBoundingClientRect().width : false;
if (containerWidth) {
this.stackedBar.width(containerWidth);
for (let option in this.chartConfig['properties']) {
if (this.stackedBar.hasOwnProperty(option) && option !== 'colorSchema') {
this.stackedBar[option](this.chartConfig['properties'][option]);
}
}
let showTooltip = false;
if (this.chartConfig.hasOwnProperty('showTooltip') && this.chartConfig['showTooltip'] === true) {
StackedBarChartComponent.prototype.drawChart = function () {
var _this = this;
this.stackedBar = stackedBar();
this.chartTooltip = tooltip();
var stackedBarContainer = d3Selection.select(this.el).select('.stacked-bar-chart-container'), containerWidth = stackedBarContainer.node() ? stackedBarContainer.node().getBoundingClientRect().width : false;
if (containerWidth) {
this.stackedBar.width(containerWidth);
for (var option in this.chartConfig['properties']) {
if (this.stackedBar.hasOwnProperty(option) && option !== 'colorSchema') {
this.stackedBar[option](this.chartConfig['properties'][option]);
}
}
var showTooltip = false;
if (this.chartConfig.hasOwnProperty('showTooltip') && this.chartConfig['showTooltip'] === true) {
showTooltip = true;
var that_1 = this;
this.stackedBar.on('customMouseOver', function () {
that_1.chartTooltip.show();
});