From d7e8f527b452cd728600ba334466ad9153ad4182 Mon Sep 17 00:00:00 2001 From: zhangyi Date: Tue, 5 Nov 2019 08:56:07 +0800 Subject: [PATCH] feat(polar) about ISSUE 11452 --- src/chart/bar/BarView.js | 4 ++-- src/chart/gauge/GaugeSeries.js | 1 - src/coord/polar/polarCreator.js | 2 +- test/polar-rounded.html | 2 +- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/chart/bar/BarView.js b/src/chart/bar/BarView.js index 80a518598..c421918ad 100644 --- a/src/chart/bar/BarView.js +++ b/src/chart/bar/BarView.js @@ -424,8 +424,8 @@ function updateStyle( el.useStyle(zrUtil.defaults( { - fill: color, - opacity: opacity + fill: layout.startAngle === layout.endAngle ? 'transparent' : color, + opacity: layout.startAngle === layout.endAngle ? 0 : opacity }, itemStyleModel.getBarItemStyle() )); diff --git a/src/chart/gauge/GaugeSeries.js b/src/chart/gauge/GaugeSeries.js index 3097bc860..1b8f10429 100644 --- a/src/chart/gauge/GaugeSeries.js +++ b/src/chart/gauge/GaugeSeries.js @@ -19,7 +19,6 @@ import createListSimply from '../helper/createListSimply'; import SeriesModel from '../../model/Series'; -import * as zrUtil from 'zrender/src/core/util'; var GaugeSeries = SeriesModel.extend({ diff --git a/src/coord/polar/polarCreator.js b/src/coord/polar/polarCreator.js index 670776b6b..156f97fba 100644 --- a/src/coord/polar/polarCreator.js +++ b/src/coord/polar/polarCreator.js @@ -50,7 +50,7 @@ function resizePolar(polar, polarModel, api) { var radius = polarModel.get('radius'); if (radius == null) { - radius = [0, "100%"]; + radius = [0, '100%']; } else if (!zrUtil.isArray(radius)) { // r0 = 0 diff --git a/test/polar-rounded.html b/test/polar-rounded.html index d01b49226..cce697b73 100644 --- a/test/polar-rounded.html +++ b/test/polar-rounded.html @@ -186,7 +186,7 @@ under the License. }, series: [{ type: 'bar', - data: [1], + data: [0], coordinateSystem: 'polar', name: 'A', roundCap: true, -- GitLab