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

Series tooltip 在有元素超出绘制区域的时候,存在偏移 #5789

Closed
pearmini opened this issue Nov 13, 2023 · 0 comments · Fixed by #5802
Closed

Series tooltip 在有元素超出绘制区域的时候,存在偏移 #5789

pearmini opened this issue Nov 13, 2023 · 0 comments · Fixed by #5802

Comments

@pearmini
Copy link
Member

问题描述

Series tooltip 在有元素超出绘制区域的时候,存在偏移

重现链接

No response

重现步骤

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

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

chart
  .line()
  .data({
    type: 'fetch',
    value:
      'https://gw.alipayobjects.com/os/bmw-prod/551d80c6-a6be-4f3c-a82a-abd739e12977.csv',
  })
  .encode('x', 'date')
  .encode('y', 'close')

chart
  .text()
  .style('x', 0)
  .style('y', 0)
  .style('text', 'hello world')
  .style('textAlign', 'end');

chart.render();

预期行为

实际结果如下:

期望没有红框的距离。

平台

  • 操作系统: [macOS, Windows, Linux, React Native ...]
  • 网页浏览器: [Google Chrome, Safari, Firefox]

屏幕截图或视频(可选)

No response

补充说明(可选)

版本:5.1.7

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

Successfully merging a pull request may close this issue.

1 participant