You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by wa...@apache.org on 2020/10/28 08:00:00 UTC
[incubator-echarts] 01/01: fix(line): only bolder when line width
in normal state is larger than 0.
This is an automated email from the ASF dual-hosted git repository.
wangzx pushed a commit to branch fix-line-bold
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git
commit 08c2ff55038fa7c6ba4e6e001aa6cd78c6194208
Author: plainheart <yh...@all-my-life.cn>
AuthorDate: Wed Oct 28 15:59:12 2020 +0800
fix(line): only bolder when line width in normal state is larger than 0.
---
src/chart/line/LineView.ts | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/chart/line/LineView.ts b/src/chart/line/LineView.ts
index b462eca..4a7b324 100644
--- a/src/chart/line/LineView.ts
+++ b/src/chart/line/LineView.ts
@@ -734,8 +734,7 @@ class LineView extends ChartView {
setStatesStylesFromModel(polyline, seriesModel, 'lineStyle');
- const shouldBolderOnEmphasis = seriesModel.get(['emphasis', 'lineStyle', 'width']) === 'bolder';
- if (shouldBolderOnEmphasis) {
+ if (polyline.style.lineWidth > 0 && seriesModel.get(['emphasis', 'lineStyle', 'width']) === 'bolder') {
const emphasisLineStyle = polyline.getState('emphasis').style;
emphasisLineStyle.lineWidth = polyline.style.lineWidth + 1;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org