Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

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

g2@4.2.4 can't show legend #4019

Closed
1 task done
chi-gao opened this issue Jul 1, 2022 · 1 comment
Closed
1 task done

g2@4.2.4 can't show legend #4019

chi-gao opened this issue Jul 1, 2022 · 1 comment

Comments

@chi-gao
Copy link

chi-gao commented Jul 1, 2022

  • I have searched the issues of this repository and believe that this is not a duplicate.

Reproduction link

Edit on CodeSandbox

Steps to reproduce

as the code shows, I set the legend visible, but it doesn't show.
I had set the line size, line color and line shape attribute.
and I had tried followings:

  • chart.legend(true)
  • chart.legend({ position: 'bottom'})
  • add bottom padding
Environment Info
g2 4.2.4
System -
Browser -
@chi-gao
Copy link
Author

chi-gao commented Jul 12, 2022

尝试g2降级到3.x,上述写法 图例是完美展示的。
目前可以确定确实是升级4.x带来的问题,所以不清楚是 4.x底层默认不支持 双轴图的图例展示, 还是 4.x升级时这部分逻辑漏掉了。
如果设计不支持,建议升级文档能够说明下,毕竟也算是 break change 了。

补充一个3.x的demo:https://codesandbox.io/s/young-mountain-x1u73c

@antvis antvis locked and limited conversation to collaborators May 10, 2023
@hustcc hustcc converted this issue into discussion #4993 May 10, 2023

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant