Skip to content
New issue

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

[4.0] 更新未支持坐标系切换场景,导致绘图不符合预期 #1935

Closed
simaQ opened this issue Jan 17, 2020 · 0 comments
Closed
Assignees

Comments

@simaQ
Copy link
Contributor

simaQ commented Jan 17, 2020

image

  • 复现代码:
import { Chart } from '@antv/g2';

const data = [
  { year: '1991', value: 3 },
  { year: '1992', value: 4 },
  { year: '1993', value: 3.5 },
  { year: '1994', value: 5 },
  { year: '1995', value: 4.9 },
  { year: '1996', value: 6 },
  { year: '1997', value: 7 },
  { year: '1998', value: 9 },
  { year: '1999', value: 13 },
];
const chart = new Chart({
  container: 'container',
  autoFit: true,
  height: 500,
});

chart.data(data);
chart.scale('value', {
  min: 0,
  nice: true,
});
chart.scale('year', {
  range: [0, 1],
});

chart.tooltip({
  showCrosshairs: true, // 展示 Tooltip 辅助线
  shared: true,
});

chart.line().position('year*value');
chart
  .point()
  .position('year*value')
  .size(4)
  .shape('circle')
  .style({
    stroke: '#fff',
    lineWidth: 1,
  });

chart.render();

chart.coordinate('polar');
chart.render(true);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants