Skip to content

Display of shared tooltip incorrect when using reversedStacks #17948

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

Closed
robinroestenburg opened this issue Nov 7, 2022 · 1 comment · Fixed by #18038
Closed

Display of shared tooltip incorrect when using reversedStacks #17948

robinroestenburg opened this issue Nov 7, 2022 · 1 comment · Fixed by #18038

Comments

@robinroestenburg
Copy link

Expected behaviour

When using a shared tooltip in a stacked bar chart that is using the reversedStacks option on the yAxis, I expect the tooltip to be displayed at the end of the bar (if there is room). This expected behavior would be similar to how the shared tooltip is displayed when not using the reversedStacks option.

Actual behaviour

The shared tooltip is displayed in the middle of the bar, making it difficult to view the data:

Screenshot 2022-11-07 at 20 29 14

For comparison, the behaviour when not using the reversedStacks option:

Screenshot 2022-11-07 at 20 28 38

Using the { legend: { reversed: true } } as a workaround works, but I can't use that because our series are ordered by size/number of results. Something like: '1', '2', '3', 'Other'.

Live demo with steps to reproduce

https://jsfiddle.net/5y6mcjp9/

Product version

Reproducible on Highcharts, master.

Affected browser(s)

I don't think the browser is of influence, but I was able to reproduce it on:

  • Microsoft Edge: 107.0.1418.28 (Official build) (arm64)
  • Safari: 15.6.1 (17613.3.9.1.16)
@pawellysy
Copy link
Contributor

hi @robinroestenburg, thanks for reporting a bug!
you can use the tooltip.positioner as a workaround, to set the position of the tooltip manually: https://jsfiddle.net/BlackLabel/7f6bac8x/3/

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.

4 participants