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 2024/12/31 04:32:46 UTC
(echarts-doc) branch master updated: add doc for apache/echarts#16315
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 f3ace9a6 add doc for apache/echarts#16315
f3ace9a6 is described below
commit f3ace9a62b603c3e0e8ae96ea9d69ca2214bc5fc
Author: plainheart <yh...@all-my-life.cn>
AuthorDate: Tue Dec 31 12:32:30 2024 +0800
add doc for apache/echarts#16315
---
en/option/component/axis-common.md | 27 +++++++++++++++++++++++++++
en/option/partial/tooltip-common.md | 10 ++++++++++
zh/option/component/axis-common.md | 27 +++++++++++++++++++++++++++
zh/option/partial/tooltip-common.md | 10 ++++++++++
4 files changed, 74 insertions(+)
diff --git a/en/option/component/axis-common.md b/en/option/component/axis-common.md
index 8d68fe17..1da09450 100644
--- a/en/option/component/axis-common.md
+++ b/en/option/component/axis-common.md
@@ -854,6 +854,11 @@ axisPointer settings on the axis.
) }}
{{ /if }}
+{{ use: partial-axis-tooltip(
+ prefix = ${prefix},
+ componentType = ${componentType}
+) }}
+
{{ use: partial-animation(
prefix = ${prefix}
) }}
@@ -1052,3 +1057,25 @@ xAxis: {
}
},
```
+
+
+{{ target: partial-axis-tooltip }}
+
+#${prefix} tooltip(Object)
+
+{{ use: partial-version(version = '5.6.0') }}
+
+The tooltip configuration for ${componentType}, must set [triggerEvent](~${componentType}.triggerEvent) as `true` and enable global [option.tooltip](~tooltip) component.
+
+##${prefix} show(boolean) = false
+
+<ExampleUIControlBoolean default="false" />
+
+Whether to show the tooltip. Defaults to `false`.
+
+{{ use: partial-tooltip-common(
+ prefix = '#' + ${prefix},
+ noValueFormatter = true
+) }}
+
+
diff --git a/en/option/partial/tooltip-common.md b/en/option/partial/tooltip-common.md
index fbcd5ad2..ee7b9214 100644
--- a/en/option/partial/tooltip-common.md
+++ b/en/option/partial/tooltip-common.md
@@ -323,6 +323,14 @@ The first parameter `params` is the data that the formatter needs. Its format is
treeAncestors: {
desc: 'The ancestors of current node in the tree/treemap series (including self)',
type: 'Array'
+ },
+ isTruncated: {
+ desc: 'A function that returns a boolean value to flag if the axis label is truncated',
+ type: 'Function'
+ },
+ tickIndex: {
+ desc: 'Current index of the axis label tick',
+ type: 'number'
}
}
) }}
@@ -347,6 +355,7 @@ formatter: function (params, ticket, callback) {
}
```
+{{ if: !${noValueFormatter} }}
#${prefix} valueFormatter(string)
{{ use: partial-version(
@@ -367,6 +376,7 @@ Example:
// Add $ prefix
valueFormatter: (value) => '$' + value.toFixed(2)
```
+{{ /if }}
#${prefix} backgroundColor(Color) = 'rgba(50,50,50,0.7)'
diff --git a/zh/option/component/axis-common.md b/zh/option/component/axis-common.md
index fb20b459..26b066cc 100644
--- a/zh/option/component/axis-common.md
+++ b/zh/option/component/axis-common.md
@@ -849,6 +849,11 @@ data: [{
) }}
{{ /if }}
+{{ use: partial-axis-tooltip(
+ prefix = ${prefix},
+ componentType = ${componentType}
+) }}
+
{{ use: partial-animation(
prefix = ${prefix}
) }}
@@ -1046,3 +1051,25 @@ xAxis: {
}
},
```
+
+
+{{ target: partial-axis-tooltip }}
+
+#${prefix} tooltip(Object)
+
+{{ use: partial-version(version = '5.6.0') }}
+
+坐标轴 tooltip 设置,注意需设置 [triggerEvent](~${componentType}.triggerEvent) 为 `true` 并启用全局 [option.tooltip](~tooltip) 组件。
+
+##${prefix} show(boolean) = false
+
+<ExampleUIControlBoolean default="false" />
+
+是否显示提示框组件,默认不启用。
+
+{{ use: partial-tooltip-common(
+ prefix = '#' + ${prefix},
+ noValueFormatter = true
+) }}
+
+
diff --git a/zh/option/partial/tooltip-common.md b/zh/option/partial/tooltip-common.md
index c42ee7a0..d4fbb02e 100644
--- a/zh/option/partial/tooltip-common.md
+++ b/zh/option/partial/tooltip-common.md
@@ -331,6 +331,14 @@ formatter: '{b0}: {c0}<br />{b1}: {c1}'
treeAncestors: {
desc: '树图/矩形树图中当前节点的祖先节点(包括自身)',
type: 'Array'
+ },
+ isTruncated: {
+ desc: '坐标轴标签文本是否溢出隐藏,可以使用此函数判断是否需要弹出提示框',
+ type: 'Function'
+ },
+ tickIndex: {
+ desc: '当前坐标轴标签刻度索引',
+ type: 'number'
}
}
) }}
@@ -352,6 +360,7 @@ formatter: function (params, ticket, callback) {
}
```
+{{ if: !${noValueFormatter} }}
#${prefix} valueFormatter(string)
{{ use: partial-version(
@@ -374,6 +383,7 @@ tooltip 中数值显示部分的格式化回调函数。
// 添加 $ 前缀
valueFormatter: (value) => '$' + value.toFixed(2)
```
+{{ /if }}
#${prefix} backgroundColor(Color) = 'rgba(50,50,50,0.7)'
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@echarts.apache.org
For additional commands, e-mail: commits-help@echarts.apache.org