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

Styled mode line chart series className not applied to shared tooltip #17815

Closed
fhoeben opened this issue Oct 3, 2022 · 2 comments · Fixed by #17865
Closed

Styled mode line chart series className not applied to shared tooltip #17815

fhoeben opened this issue Oct 3, 2022 · 2 comments · Fixed by #17865

Comments

@fhoeben
Copy link

fhoeben commented Oct 3, 2022

Expected behaviour

Given I have a line chart, in styled mode, with a shared tooltip
When I apply a className to my series
Then I expect that className to be applied to the tooltip element for that series
Screenshot 2022-10-03 at 12 25 51

Actual behaviour

The className specified is not added to the values for the series in the tooltip

Live demo with steps to reproduce

https://codepen.io/fhoeben/pen/WNJyeNQ

Screenshot 2022-10-03 at 12 20 34

The line colours have been configured, these are applied to the labels but not to the tooltip. The tooltip elements do not have the weight or bmi class specified to their series
Screenshot 2022-10-03 at 12 23 17

Product version

Highcharts JS v10.2.1 (2022-08-29)

Affected browser(s)

all

@karolkolodziej
Copy link
Contributor

Hi @fhoeben!

I agree the class name and new colors should be reflected in the tooltip while using the styledMode.

As a workaround, you can use other CSS selectors to change those colors- demo.

Similar to: #17346

@TorsteinHonsi
Copy link
Collaborator

@fhoeben The safest workaround (and how coloring is intended to work), is to use the colorIndex option to handle your color-to-series mapping.

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.

5 participants