antvis / antvis/G2Plot

Fix: 发现在双轴图中左右Y轴,使用相同tickCount时左右Y轴刻度无法对齐

Open
#2,355 1 comment 0 reactions 1 assignee Claimed by @liuzhenying View on GitHub
Scale
Dominant language
TypeScript
Stars
2.7k
Forks
591
PR merge metrics
No merged PRs in 30d

Description

* **G2Plot Version**: 2.3.7
* **Platform**: Mac
* **Mini Showcase(like screenshots)**:
![image](https://user-images.githubusercontent.com/40811570/109097918-41869380-775b-11eb-8140-3e5ee9cd04f6.png)

* **CodePen Link**: https://codesandbox.io/s/hqpod
主要双轴tickCount配置项
![image](https://user-images.githubusercontent.com/40811570/109098378-28caad80-775c-11eb-83f8-046d6163f976.png)

在使用双轴图的时候,发现左右两边Y轴高度是不一致的,右边Y轴总会比左边Y轴高,这导致左右两轴使用相同tickCount(如上示例tickCount: 5)均分Y轴轴线长度时,左右Y轴刻度值不一致。这就让左右轴线刻度值有错位的感觉,在给两个Y轴加上grid时看起来尤为明显,如下图。
![image](https://user-images.githubusercontent.com/40811570/109098907-22890100-775d-11eb-99f1-de9036cce7f4.png)
我的期望是统一两个Y轴线高度,这样tickCount等分的时候grid显示是在一条线上的,而不是上图错位。
期待你们的答复,salute~

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.