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

[v5] Tooltip 与 Slider一起使用会造成Tooltip失效 #4959

Closed
wuchuanxun opened this issue May 8, 2023 · 1 comment · Fixed by #4962
Closed

[v5] Tooltip 与 Slider一起使用会造成Tooltip失效 #4959

wuchuanxun opened this issue May 8, 2023 · 1 comment · Fixed by #4962
Assignees
Labels

Comments

@wuchuanxun
Copy link

示例地址: https://g2.antv.antgroup.com/examples/interaction/interaction/#tooltip-render

修改代码,增加x轴slider 配置

chart
  .interval()
  .data({
    type: 'fetch',
    value:
      'https://gw.alipayobjects.com/os/bmw-prod/fb9db6b7-23a5-4c23-bbef-c54a55fee580.csv',
  })
  .transform([{ type: 'sortX', by: 'y', reverse: true, slice: 5 }])
  .encode('x', 'letter')
  .encode('y', 'frequency')
  .slider({
    x: {},
  });

初始情况下tooltip是正常的,但是只需要更改slider范围后,tooltip就保持最后的提示不变了。

修复思路,可能slider变化之后需要移除tooltip交互重新添加tooltip

@pearmini
Copy link
Member

pearmini commented May 8, 2023

嗯嗯,这个问题和自定义 tooltip 内容有关,会在这周修复。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants