From 4cccafb96b2a1b04df7785da808a5f6f30c548df Mon Sep 17 00:00:00 2001 From: Ovilia Date: Thu, 19 Jun 2025 19:46:09 +0800 Subject: [PATCH] fix(dataZoom): fix the case when first value is NaN, relates to #16978 --- src/component/dataZoom/SliderZoomView.ts | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/component/dataZoom/SliderZoomView.ts b/src/component/dataZoom/SliderZoomView.ts index b460ffee72..332feaccf9 100644 --- a/src/component/dataZoom/SliderZoomView.ts +++ b/src/component/dataZoom/SliderZoomView.ts @@ -430,8 +430,10 @@ class SliderZoomView extends DataZoomView { linePoints.push([thisCoord, 0]); } - areaPoints.push([thisCoord, otherCoord]); - linePoints.push([thisCoord, otherCoord]); + if (!isEmpty) { + areaPoints.push([thisCoord, otherCoord]); + linePoints.push([thisCoord, otherCoord]); + } lastIsEmpty = isEmpty; });