antvis/G2

The issue has been closed
在 "@antv/g2": "~4.2.10" 版本使用 Chart 时,请问如何取消 legend 的默认点击行为,即不想点击图例后,对应的折线消失,图例只用作显示 #6084
SnowBeforeSpring posted onGitHub
问题描述
import { Chart } from '@antv/g2'
const res = new Chart({ container: antVLineContainer.current as HTMLElement, autoFit: true, })
chart.legend({ position: 'top', marker: { symbol: 'hyphen' }, // 这里看类型定义里面没有禁止点击事件的方法 or 属性 })
重现链接
No response
重现步骤
No response
预期行为
No response
平台
- 操作系统: [macOS, Windows, Linux, React Native ...]
- 网页浏览器: [Google Chrome, Safari, Firefox]
屏幕截图或视频(可选)
No response
补充说明(可选)
No response