From 88d563eb2e531dab5b37e7d53361b98dedb83f51 Mon Sep 17 00:00:00 2001 From: Julien Pivotto Date: Sat, 22 Aug 2020 21:03:19 +0200 Subject: [PATCH] Fix react UI bug with series going on and off (#7804) * Fix react UI bug with series going on and off Signed-off-by: Julien Pivotto --- web/ui/react-app/src/vendor/flot/jquery.flot.stack.js | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/web/ui/react-app/src/vendor/flot/jquery.flot.stack.js b/web/ui/react-app/src/vendor/flot/jquery.flot.stack.js index 0bf160aa60..1c172d58f3 100644 --- a/web/ui/react-app/src/vendor/flot/jquery.flot.stack.js +++ b/web/ui/react-app/src/vendor/flot/jquery.flot.stack.js @@ -108,13 +108,11 @@ charts or filled areas). l = newpoints.length; if (i < points.length && points[i] == null) { - // copy gaps - for (m = 0; m < ps; ++m) newpoints.push(points[i + m]); + // take the points from the previous series + for (m = 0; m < ps; ++m) newpoints.push(otherpoints[i + m]); + if (withbottom) newpoints[l + 2] = otherpoints[i + accumulateOffset]; i += ps; } else if (i >= points.length) { - // take the remaining points from the previous series - for (m = 0; m < ps; ++m) newpoints.push(otherpoints[j + m]); - if (withbottom) newpoints[l + 2] = otherpoints[j + accumulateOffset]; j += otherps; } else if (j >= otherpoints.length) { // take the remaining points from the current series