You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@echarts.apache.org by ov...@apache.org on 2022/07/12 09:07:45 UTC

[echarts-doc] 01/01: doc: update instruction for custom group being null apache/echarts#17349

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

ovilia pushed a commit to branch fix-custom-merge
in repository https://gitbox.apache.org/repos/asf/echarts-doc.git

commit 687b006aa34a046bbdfbfd30365d519cd00c27a9
Author: Ovilia <zw...@gmail.com>
AuthorDate: Tue Jul 12 17:07:26 2022 +0800

    doc: update instruction for custom group being null apache/echarts#17349
---
 en/option/partial/zr-graphic.md | 5 ++++-
 zh/option/partial/zr-graphic.md | 5 ++++-
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/en/option/partial/zr-graphic.md b/en/option/partial/zr-graphic.md
index d54b71b3..5b993e5c 100644
--- a/en/option/partial/zr-graphic.md
+++ b/en/option/partial/zr-graphic.md
@@ -5,6 +5,10 @@
 
 `group` is the only type that can contain children, so that a group of elements can be positioned and transformed together.
 
+{{ if: ${usageType} === 'customSeries' }}
+Note that if any of its child is `null`, it means the child no longer exists. So if a group contains an element that is set to be `null` in a future `setOption` call, it should remove the previous element at the same index. If a child should not change, it should be `{}` in the new option.
+{{ /if }}
+
 {{ use: partial-graphic-cpt-common-props(
     type = 'group',
     prefix = ${prefix},
@@ -2046,4 +2050,3 @@ Although the points will be interpolated, the consequent animation will be like
 ```
 
 See this example [example](${galleryEditorPath}custom-spiral-race&edit=1&reset=1).
-
diff --git a/zh/option/partial/zr-graphic.md b/zh/option/partial/zr-graphic.md
index a0fce1a0..5d0cf927 100644
--- a/zh/option/partial/zr-graphic.md
+++ b/zh/option/partial/zr-graphic.md
@@ -5,6 +5,10 @@
 
 group 是唯一的可以有子节点的容器。group 可以用来整体定位一组图形元素。
 
+{{ if: ${usageType} === 'customSeries' }}
+注意,如果其任意子节点是 `null`,这表示该子节点不再存在。所以,如果再次调用 `setOption` 时,一个子节点被设为 `null`,这意味着它之前对应序号的元素会被删除。如果希望一个子节点保持不变,应在新的配置项中使用 `{}` 表示。
+{{ /if }}
+
 {{ use: partial-graphic-cpt-common-props(
     type = 'group',
     prefix = ${prefix},
@@ -2017,4 +2021,3 @@ type TransformProp =
 ```
 
 也参见这个 [例子](${galleryEditorPath}custom-spiral-race&edit=1&reset=1)。
-


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