fix(crosshair): restore pointer values on stacked measure axes - #4683
Merged
Merged
Conversation
kkxxkk2019
approved these changes
Sep 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
💡 问题的背景&解决方案
#4561 放宽了 crosshair 区间匹配的端点顺序,用于修复马赛克图的矩形高亮。普通堆叠柱图、面积图的数值轴也使用内部
STACK_END / STACK_START字段,因此会误入区间匹配:仅按数值扫描全部系列数据,取到其他类目的第一个匹配区间,既改变标签,也把辅助线移到该区间中点。例如悬停
Mascara / EU,鼠标对应 Y=22000 时:11659 ~ 24473(来自Nail polish / USA)2200018066(错误区间中点)22000本次使用现有
series.getStack()和series.direction识别堆叠数值轴,跳过区间查找,保留鼠标对应的坐标轴值、位置和标签格式化流程。马赛克、堆叠直方图维度轴继续使用区间匹配、矩形定位和升序标签。堆叠数值轴交互不再读取、扫描系列数据;新增测试同时验证这一点,避免在鼠标移动热路径引入数据量相关开销。
🤔 这个分支是...
🔗 相关的 PR 链接
#4561
🐞 Bugserver 用例 id
65115a4575f95aebb64ca5d9📝 Changelog
☑️ 自测
rush test --only tag:package:VChart 全量 82 套测试、455 项用例通过,vutils-extension的 1 项测试通过。vutils-extension类型声明后,VChart 全量tsc --noEmit通过。git diff --check通过。🚀 Summary
copilot:summary
🔍 Walkthrough
copilot:walkthrough