antvis / G2

📊 The concise and progressive visualization grammar.
https://g2.antv.antgroup.com
MIT License
12.13k stars 1.59k forks source link

开启缩略轴(slider)后,数据标签(label)不响应缩略轴变化 #6212

Closed jp-liu closed 3 months ago

jp-liu commented 6 months ago

问题描述

开启缩略轴(slider)后,直接拉动缩略轴进行筛选范围,图表上的 label 不回响应进行变更,会导致图表上的 label 显示错误,必现,第一次图表渲染完毕后才会出现,多操作几次就恢复正常了

重现链接

https://codesandbox.io/p/sandbox/confident-euclid-8fz4vj?layout=%257B%2522sidebarPanel%2522%253A%2522EXPLORER%2522%252C%2522rootPanelGroup%2522%253A%257B%2522direction%2522%253A%2522horizontal%2522%252C%2522contentType%2522%253A%2522UNKNOWN%2522%252C%2522type%2522%253A%2522PANEL_GROUP%2522%252C%2522id%2522%253A%2522ROOT_LAYOUT%2522%252C%2522panels%2522%253A%255B%257B%2522type%2522%253A%2522PANEL_GROUP%2522%252C%2522contentType%2522%253A%2522UNKNOWN%2522%252C%2522direction%2522%253A%2522vertical%2522%252C%2522id%2522%253A%2522clvlqhfe100063b6mfpoabnzo%2522%252C%2522sizes%2522%253A%255B100%252C0%255D%252C%2522panels%2522%253A%255B%257B%2522type%2522%253A%2522PANEL_GROUP%2522%252C%2522contentType%2522%253A%2522EDITOR%2522%252C%2522direction%2522%253A%2522horizontal%2522%252C%2522id%2522%253A%2522EDITOR%2522%252C%2522panels%2522%253A%255B%257B%2522type%2522%253A%2522PANEL%2522%252C%2522contentType%2522%253A%2522EDITOR%2522%252C%2522id%2522%253A%2522clvlqhfe100023b6mgj7ss6ti%2522%257D%255D%257D%252C%257B%2522type%2522%253A%2522PANEL_GROUP%2522%252C%2522contentType%2522%253A%2522SHELLS%2522%252C%2522direction%2522%253A%2522horizontal%2522%252C%2522id%2522%253A%2522SHELLS%2522%252C%2522panels%2522%253A%255B%257B%2522type%2522%253A%2522PANEL%2522%252C%2522contentType%2522%253A%2522SHELLS%2522%252C%2522id%2522%253A%2522clvlqhfe100033b6mpvj12ndd%2522%257D%255D%252C%2522sizes%2522%253A%255B100%255D%257D%255D%257D%252C%257B%2522type%2522%253A%2522PANEL_GROUP%2522%252C%2522contentType%2522%253A%2522DEVTOOLS%2522%252C%2522direction%2522%253A%2522vertical%2522%252C%2522id%2522%253A%2522DEVTOOLS%2522%252C%2522panels%2522%253A%255B%257B%2522type%2522%253A%2522PANEL%2522%252C%2522contentType%2522%253A%2522DEVTOOLS%2522%252C%2522id%2522%253A%2522clvlqhfe100053b6mkf9az7so%2522%257D%255D%252C%2522sizes%2522%253A%255B100%255D%257D%255D%252C%2522sizes%2522%253A%255B50%252C50%255D%257D%252C%2522tabbedPanels%2522%253A%257B%2522clvlqhfe100023b6mgj7ss6ti%2522%253A%257B%2522tabs%2522%253A%255B%257B%2522id%2522%253A%2522clvlqhfe000013b6miv1gia9n%2522%252C%2522mode%2522%253A%2522permanent%2522%252C%2522type%2522%253A%2522FILE%2522%252C%2522filepath%2522%253A%2522%252Findex.ts%2522%257D%255D%252C%2522id%2522%253A%2522clvlqhfe100023b6mgj7ss6ti%2522%252C%2522activeTabId%2522%253A%2522clvlqhfe000013b6miv1gia9n%2522%257D%252C%2522clvlqhfe100053b6mkf9az7so%2522%253A%257B%2522tabs%2522%253A%255B%257B%2522id%2522%253A%2522clvlqhfe100043b6mcl73wmwn%2522%252C%2522mode%2522%253A%2522permanent%2522%252C%2522type%2522%253A%2522UNASSIGNED_PORT%2522%252C%2522port%2522%253A0%252C%2522path%2522%253A%2522%252F%2522%257D%255D%252C%2522id%2522%253A%2522clvlqhfe100053b6mkf9az7so%2522%252C%2522activeTabId%2522%253A%2522clvlqhfe100043b6mcl73wmwn%2522%257D%252C%2522clvlqhfe100033b6mpvj12ndd%2522%253A%257B%2522tabs%2522%253A%255B%255D%252C%2522id%2522%253A%2522clvlqhfe100033b6mpvj12ndd%2522%257D%257D%252C%2522showDevtools%2522%253Atrue%252C%2522showShells%2522%253Afalse%252C%2522showSidebar%2522%253Atrue%252C%2522sidebarPanelSize%2522%253A15%257D

重现步骤

1.进入页面 2.拉动 slider 上下两端的按扭筛选范围

预期行为

图表根据筛选范围进行重绘 --- 已经重绘, 数据标签也根据筛选范围重绘 --- 没有更新,显示错位等,

平台

屏幕截图或视频(可选)

https://github.com/antvis/G2/assets/79979500/e9279c21-e106-4515-a52c-84d26c5ca5ca

补充说明(可选)

No response

qtj4js commented 4 months ago

同样遇到问题,想问下这个怎么处理,或者是否有避免的方法