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

Legend title is visible when there is no data in chart #17167

Closed
rrimmana opened this issue Apr 7, 2022 · 1 comment · Fixed by #17436
Closed

Legend title is visible when there is no data in chart #17167

rrimmana opened this issue Apr 7, 2022 · 1 comment · Fixed by #17436

Comments

@rrimmana
Copy link

rrimmana commented Apr 7, 2022

Expected behaviour

Legend title should not be show when chart has no data
Behavior should be similar to Legend items/ series names.

Actual behaviour

Legend title is shown even when no data is present in chart

Live demo with steps to reproduce

http://jsfiddle.net/L7cnkg98/

Product version

Latest version

Affected browser(s)

chrome,FF, edge

@pawellysy
Copy link
Contributor

Hello @rrimmana, thanks for reporting this bug.

Simplified demo: http://jsfiddle.net/BlackLabel/tpc7ugx2/2/

Workaround

http://jsfiddle.net/BlackLabel/tpc7ugx2/3/

internal note

The legend group has no visibility attribute. Probably, instead of hiding the legend.box we could replace it with legend.group.

box[display ? 'show' : 'hide']();

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

Successfully merging a pull request may close this issue.

3 participants