You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by sh...@apache.org on 2020/07/30 15:55:55 UTC

[incubator-echarts] branch next updated (701747c -> 25a19ba)

This is an automated email from the ASF dual-hosted git repository.

shenyi pushed a change to branch next
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git.


    from 701747c  Merge pull request #13052 from plainheart/chore-fix
     new e95bc1f  fix(toolbox): fix null pointer access when using custom feature
     new 25a19ba  fix(bar): fix clipped object can't switch from hidden to shown

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 src/chart/bar/BarView.ts              | 12 ++++--------
 src/component/toolbox/ToolboxModel.ts |  8 +++++---
 test/bar-race.html                    |  1 -
 3 files changed, 9 insertions(+), 12 deletions(-)


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[incubator-echarts] 01/02: fix(toolbox): fix null pointer access when using custom feature

Posted by sh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

shenyi pushed a commit to branch next
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git

commit e95bc1f14fed2738bb11ff021c6352ab3b829a91
Author: pissang <bm...@gmail.com>
AuthorDate: Thu Jul 30 23:54:46 2020 +0800

    fix(toolbox): fix null pointer access when using custom feature
---
 src/component/toolbox/ToolboxModel.ts | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/src/component/toolbox/ToolboxModel.ts b/src/component/toolbox/ToolboxModel.ts
index 10712e5..1d6a1da 100644
--- a/src/component/toolbox/ToolboxModel.ts
+++ b/src/component/toolbox/ToolboxModel.ts
@@ -90,10 +90,12 @@ class ToolboxModel extends ComponentModel<ToolboxOption> {
 
         zrUtil.each(this.option.feature, function (featureOpt, featureName) {
             const Feature = featureManager.getFeature(featureName);
-            if (Feature.getDefaultOption) {
-                Feature.defaultOption = Feature.getDefaultOption(ecModel);
+            if (Feature) {
+                if (Feature.getDefaultOption) {
+                    Feature.defaultOption = Feature.getDefaultOption(ecModel);
+                }
+                zrUtil.merge(featureOpt, Feature.defaultOption);
             }
-            Feature && zrUtil.merge(featureOpt, Feature.defaultOption);
         });
     }
 


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org


[incubator-echarts] 02/02: fix(bar): fix clipped object can't switch from hidden to shown

Posted by sh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

shenyi pushed a commit to branch next
in repository https://gitbox.apache.org/repos/asf/incubator-echarts.git

commit 25a19ba2188db2d73cfd5450d0faf2fa2a2b7514
Author: pissang <bm...@gmail.com>
AuthorDate: Thu Jul 30 23:55:31 2020 +0800

    fix(bar): fix clipped object can't switch from hidden to shown
---
 src/chart/bar/BarView.ts | 12 ++++--------
 test/bar-race.html       |  1 -
 2 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/src/chart/bar/BarView.ts b/src/chart/bar/BarView.ts
index cd5a02b..18a818e 100644
--- a/src/chart/bar/BarView.ts
+++ b/src/chart/bar/BarView.ts
@@ -121,7 +121,7 @@ class BarView extends ChartView {
 
     private _model: BarSeriesModel;
 
-    constructor () {
+    constructor() {
         super();
         this._isFirstFrame = true;
     }
@@ -286,10 +286,9 @@ class BarView extends ChartView {
                 }
 
                 data.setItemGraphicEl(dataIndex, el);
+
                 group.add(el);
-                if (isClipped) {
-                    el.hide();
-                }
+                el.ignore = isClipped;
             })
             .update(function (newIndex, oldIndex) {
                 const itemModel = data.getItemModel(newIndex);
@@ -365,10 +364,7 @@ class BarView extends ChartView {
                 }
 
                 data.setItemGraphicEl(newIndex, el);
-                // Add back
-                if (isClipped) {
-                    el.hide();
-                }
+                el.ignore = isClipped;
                 group.add(el);
             })
             .remove(function (dataIndex) {
diff --git a/test/bar-race.html b/test/bar-race.html
index e9e3841..429175f 100644
--- a/test/bar-race.html
+++ b/test/bar-race.html
@@ -375,7 +375,6 @@ under the License.
                             }
                             option.series[0].data = data;
 
-                            debugger
                             option.graphic.elements[0].style.text = i + 1960 + '';
 
                             chart.setOption(option);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org