From a8e2a8fabe4bb9395f0e858a2a0b64224f38dffb Mon Sep 17 00:00:00 2001 From: Ivan Mikheykin Date: Wed, 29 Aug 2018 17:51:55 +0300 Subject: [PATCH] relax conditions for discrete mode --- src/color_mode_discrete.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/color_mode_discrete.js b/src/color_mode_discrete.js index 6e7aa4e..e64cb31 100644 --- a/src/color_mode_discrete.js +++ b/src/color_mode_discrete.js @@ -15,7 +15,7 @@ export class ColorModeDiscrete { for (let i = 0; i < thresholds.length; i++) { for (let j = 0; j < values.length; j++) { - if (values[j] === thresholds[i].value) { + if (values[j] == thresholds[i].value) { tooltips.push(thresholds[i].tooltip); } } @@ -64,7 +64,7 @@ export class ColorModeDiscrete { getMatchedThreshold(value) { let thresholds = this.panel.color.thresholds; for (let k = 0; k < thresholds.length; k++) { - if (value === thresholds[k].value) { + if (value == thresholds[k].value) { return thresholds[k]; } }