ZoomIn

源码
import { Chart } from '@antv/g2';

const chart = new Chart({
  container: 'container',
  autoFit: true,
  insetLeft: 30,
});

chart.options({
  type: 'point',
  data: {
    type: 'fetch',
    value: 'https://gw.alipayobjects.com/os/antvdemo/assets/data/bubble.json',
  },
  encode: {
    x: 'GDP',
    y: 'LifeExpectancy',
    color: 'continent',
    size: 'Population',
    shape: 'point',
  },
  scale: { size: { range: [4, 65] }, y: { domain: [65, 90] } },
  style: { fillOpacity: 0.3, lineWidth: 1 },
  legend: { size: false },
  animate: { enter: { type: 'zoomIn', duration: 1000 } },
});

chart.render();
全站搜索
文档与示例输入关键词开始搜索

输入关键词,查找文档、API 与示例

选择打开Esc关闭