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

horizontal bar chart - total dataLabel overflow on stackType 100% #3579

Open
delphi-sucks opened this issue Jan 2, 2023 · 1 comment
Open
Labels
bug Something isn't working

Comments

@delphi-sucks
Copy link

Description

When creating a horizontal 100% stacked bar chart with a total-dataLabel, the dataLabel gets cut off.

Steps to Reproduce

  1. create a horizontal 100% stacked bar chart (chart.stacked = true, chart.stackType = "100%", plotOptions.bar.horizontal = true)
  2. enabled total-datalabels (plotOptions.bar.dataLabels.total.enabled = true)
    => total dataLabel gets cut off

Expected Behavior

The chart adds a right padding dependent on the max dataLabel width.

Actual Behavior

The total-dataLabel gets positioned right of the bar and gets cut off, because it overflows.

Screenshots

chrome_CTOZi7kLSm

Reproduction Link

https://codepen.io/moddesteni/pen/vYaKJQq

Workaround

Defining a manual offset via grid.padding.right works as a workaround, but depending on the data it can still get cut off, if a big number is needed to be shown.

@delphi-sucks delphi-sucks added the bug Something isn't working label Jan 2, 2023
@Wijlini
Copy link

Wijlini commented Jul 1, 2023

Same here, we need fix for that

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants