饼图 Tooltip 展示信息 #2410
visiky
started this conversation in
Show and tell
饼图 Tooltip 展示信息
#2410
Replies: 2 comments
解决方案(基于 v2.3.13):
期望展示1:tooltip: {
showTitle: true,
formatter: (datum) => ({ title: datum.type, name: '销售占比', value: datum.value })
},期望展示2:tooltip: {
showTitle: true,
title: '销售占比'
},期望展示3:
|
0 replies
解决方案( v2.3.14):期望展示3tooltip: {
fields: ['type', 'value']
}, |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
现状:饼图目前 tooltip 默认展示具体的维度值 + 指标数值.
问题:某些业务场景下,图表场外信息没有给出具体的指标名称,需要在 tooltip 上去看到具体对应的是什么指标,如下期望1。
结论:移步查看 Tooltip(悬浮提示信息)组件 的设计规范,可以观察到规范就是;每一条 tooltip 数据项,主要由「维度值+指标数值」构成
1. 饼图 Tooltip 默认展示态不变
2. 我们不会提供「期望1」的 Tooltip,但提供 formatter 的方式让您可以自定义
3. 关于「期望2」,您可以通过自定义 Tooltip title 的方式来展示指标名称
All reactions