From 440075dfe0969c700c9aa28194d4320c8b841443 Mon Sep 17 00:00:00 2001 From: Antoine Roy-Gobeil Date: Thu, 21 Jan 2021 15:38:55 -0500 Subject: [PATCH] In indicator, do not ignore threshold with value 0 --- src/traces/indicator/plot.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/traces/indicator/plot.js b/src/traces/indicator/plot.js index 60febc38d79..6f5abc99afb 100644 --- a/src/traces/indicator/plot.js +++ b/src/traces/indicator/plot.js @@ -324,7 +324,7 @@ function drawBulletGauge(gd, plotGroup, cd, opts) { } fgBullet.exit().remove(); - var data = cd.filter(function() {return trace.gauge.threshold.value;}); + var data = cd.filter(function() {return trace.gauge.threshold.value || trace.gauge.threshold.value === 0;}); var threshold = bullet.selectAll('g.threshold-bullet').data(data); threshold.enter().append('g').classed('threshold-bullet', true).append('line'); threshold.select('line') @@ -497,7 +497,7 @@ function drawAngularGauge(gd, plotGroup, cd, opts) { // Draw threshold arcs = []; var v = trace.gauge.threshold.value; - if(v) { + if(v || v === 0) { arcs.push({ range: [v, v], color: trace.gauge.threshold.color,