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 2023/05/17 01:01:02 UTC

[echarts-doc] branch master updated: fix(legend): clarify the usage of `legend.selector`, resolves apache/echarts#18636.

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

wangzx pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/echarts-doc.git


The following commit(s) were added to refs/heads/master by this push:
     new 2d591a28 fix(legend): clarify the usage of `legend.selector`, resolves apache/echarts#18636.
2d591a28 is described below

commit 2d591a287d9d50f893e03237b921ff0745624faa
Author: plainheart <yh...@all-my-life.cn>
AuthorDate: Wed May 17 08:59:08 2023 +0800

    fix(legend): clarify the usage of `legend.selector`, resolves apache/echarts#18636.
---
 en/option/component/legend.md | 10 +++++++---
 zh/option/component/legend.md |  9 ++++++---
 2 files changed, 13 insertions(+), 6 deletions(-)

diff --git a/en/option/component/legend.md b/en/option/component/legend.md
index 0ba1f916..52f391c3 100644
--- a/en/option/component/legend.md
+++ b/en/option/component/legend.md
@@ -394,19 +394,23 @@ Duration of the page scroll animation.
     version = "4.4.0"
 ) }}
 
-The selector button in the legend component. Currently includes both a full selection and an inverse selection. The selector button doesn't display by default, the user can manually configure it.
+The selector button in the legend component. Currently, there are two types of button:
 
-Usage:
+- `all`: Select All
+- `inverse`: Inverse Selection
+
+The selector button doesn't display by default, you need to enable it manually as follows.
 
 ```ts
 selector: [
     {
-        type: 'all or inverse',
+        type: 'all',
         // can be any title you like
         title: 'All'
     },
     {
         type: 'inverse',
+        // can be any title you like
         title: 'Inv'
     }
 ]
diff --git a/zh/option/component/legend.md b/zh/option/component/legend.md
index d70a4515..53d89667 100644
--- a/zh/option/component/legend.md
+++ b/zh/option/component/legend.md
@@ -490,19 +490,22 @@ data: [{
     version = "4.4.0"
 ) }}
 
-图例组件中的选择器按钮,目前包括全选和反选两种功能。默认不显示,用户可手动开启,也可以手动配置每个按钮的标题。
+图例组件中的选择器按钮,目前包括“全选”和“反选”两种功能。默认不显示,用户可手动开启,也可以手动配置每个按钮的标题。
 
 使用方式如下:
 
 ```ts
 selector: [
     {
-        type: 'all or inverse',
-        // 可以是任意你喜欢的 title
+        // 全选
+        type: 'all',
+        // 可以是任意你喜欢的标题
         title: '全选'
     },
     {
+        // 反选
         type: 'inverse',
+        // 可以是任意你喜欢的标题
         title: '反选'
     }
 ]


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