We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
#4681 提到 Tooltip 默认展示堆叠前的数据,但是如果存在 .transform({ type: 'groupColor', y: 'count' }) ,会导致 Tooltip 展示堆叠后的数据:
import { Chart } from '@antv/g2'; const chart = new Chart({ container: 'container', height: 640, }); chart.coordinate({ type: 'theta', innerRadius: 0.6 }); chart .interval() .transform({ type: 'groupColor', y: 'count' }) .transform({ type: 'stackY' }) .data( [ { name: 'A' }, { name: 'A' }, { name: 'A' }, { name: 'B' }, { name: 'C' }, ] ) .encode('color', 'name') .style('stroke', 'white') .style('inset', 1) .style('radius', 10) .scale('color', { palette: 'spectral', offset: (t) => t * 0.8 + 0.1, }) .animate('enter', { type: 'waveIn' }) .legend(false); chart.render();
No response
The text was updated successfully, but these errors were encountered:
这例子中期望展现的堆叠前的数据是啥?
Sorry, something went wrong.
@pearmini 3,1,1 啊 不是三个A,1个B,1个C嘛
chart .interval() .interaction('tooltip', { shared: true }) // 这样?
No branches or pull requests
问题描述
#4681 提到 Tooltip 默认展示堆叠前的数据,但是如果存在 .transform({ type: 'groupColor', y: 'count' }) ,会导致 Tooltip 展示堆叠后的数据:
重现链接
No response
重现步骤
No response
预期行为
No response
平台
屏幕截图或视频(可选)
No response
补充说明(可选)
No response
The text was updated successfully, but these errors were encountered: