diff --git a/src/chart/pie/labelLayout.ts b/src/chart/pie/labelLayout.ts index 0c90908914..4ed96f3ac3 100644 --- a/src/chart/pie/labelLayout.ts +++ b/src/chart/pie/labelLayout.ts @@ -394,8 +394,11 @@ export default function pieLabelLayout( if (Math.abs(sectorShape.endAngle - sectorShape.startAngle) < minShowLabelRadian) { each(label.states, setNotShow); - each(labelLine.states, setNotShow); - label.ignore = labelLine.ignore = true; + label.ignore = true; + if (labelLine) { + each(labelLine.states, setNotShow); + labelLine.ignore = true; + } return; } diff --git a/test/pie-label.html b/test/pie-label.html index 23cb8d39a7..4738d0e17e 100644 --- a/test/pie-label.html +++ b/test/pie-label.html @@ -52,6 +52,7 @@
+
+ +