自定义tooltips无法使用
- [ ] I have searched the issues of this repository and believe that this is not a duplicate.
Reproduction link
https://f2.antv.antgroup.com/examples/area/area/#gradient
Steps to reproduce
最新版可复现,官网demo也可复现,随便在一个面积图加 <Tooltip showCrosshairs customText={()=> 测试自定义tip}/> 就报错了,还有什么方式能自定义Tooltip内容?
| Environment | Info |
|---|---|
| f2 | 5.0.25 |
| System | - |
| Browser | - |
我用了源码里的示例,没报错能显示哎
<Tooltip alwaysShow={true} showTooltipMarker={true} defaultItem={data[0]} customText={(record) => { const { origin } = record; return ( <text attrs={{ fill: '#fff', text: 名称:${origin.genre}, }} /> ); }} />
我用了源码里的示例,没报错能显示哎
<Tooltip alwaysShow={true} showTooltipMarker={true} defaultItem={data[0]} customText={(record) => { const { origin } = record; return ( <text attrs={{ fill: '#fff', text:名称:${origin.genre}, }} /> ); }} />
您好,为什么在文档里我找寻不到这个customText https://f2.antv.antgroup.com/tutorial/shape-attrs#%E6%96%87%E6%9C%AC%E5%B1%9E%E6%80%A7
