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

[Bug]: VerticalBarChart Appears Blank When All Y-Axis Data Ponts are Zeros #33881

Open
2 tasks done
Yogitha-Lakshmi-525 opened this issue Feb 21, 2025 · 0 comments
Open
2 tasks done

Comments

@Yogitha-Lakshmi-525
Copy link

Charting Control

VerticalBarChart

Package version

5.23.51

React version

17.0.2

Environment

- Fluent UI React version: @fluentui/react-charting 5.23.51
- React version: 17.0.2
- Browser: Chrome, Edge 
- Operating System: Windows 11

Current Behavior

VerticalBarChart appears blank when all Y-axis data points are zero; it only renders when at least one value is non zeros.

Expected Behavior

VerticalBarChart should display even when all Y-axis values are zero.

Reproduction

https://codepen.io/yogitha-525/pen/NPWGpro?editors=1111

Steps to reproduce

1.Render the VerticalBarChart component with a dataset where all Y-axis values are 0.
2.Observe that the chart appears blank (an empty

is displayed instead of bars).
3.Modify the dataset by changing at least one Y-axis value to 0.01 or higher.
4.Observe that the chart now renders correctly with bars visible.

Expected Behavior:
The chart should display even when all Y-axis values are 0, instead of rendering an empty

.

Are you reporting an Accessibility issue?

None

Suggested severity

Urgent - No workaround and Products/sites are affected

Products/sites affected

No response

Are you willing to submit a PR to fix?

yes

Validations

  • Check that there isn't already an issue that reports the same bug to avoid creating a duplicate.
  • The provided reproduction is a minimal reproducible example of the bug.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants