You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Area Chart not displaying correct colors in high contrast mode with theme set #15921
The expected result of setting the highContrast theme under accessibility as that theme would be the correct colors showing up (as they would when I set those colors in chart.options.colors)
Actual behaviour
Setting the colors object does not update the colors. Instead all areas are white. I do have the ability to set them to be a singular other color by setting "color" in plotOptions, but is there a separate recommended approach for setting colors in high contrast mode? I'd like to set distinct colors to maintain the same user experience. The issue here #15040 looks related, but this is more specific to the functionality of the highContrastTheme option.
Yes it only happens in Edge. In chrome the high contrast mode does not change the colors or the chart (unable to apply any color changes at all in chrome under the high contrast theme). Is there any way to disable this functionality so the charts do not change in high contrast mode?
This is an issue with how we apply the high contrast mode theme. We really need to change this.
The theme forces specific colors to be set on each series, from theme.plotOptions, which is unfortunately necessary since it needs to override other colors that may be set specifically on each series. Perhaps we can find a better solution for this.
There is currently no way to turn off the high contrast theme, which there should be. We will of course add this.
Note: You should probably be careful with setting specific colors in High contrast mode, since you don't know what color theme the user has set up and prefers. The user is able to set their own custom theme in High contrast mode. Some users may even use High contrast mode for low contrast, for example users with certain cognitive disabilities. By setting specific colors you could clash with the user's custom theme.
Highcharts by default tries to use the colors defined by the user by referring to system colors instead of hardcoded values. If you run into cases where this is not appropriate it would be great to know, since we would want to change the default theme or behavior to handle the use case.
Activity
raf18seb commentedon Jun 22, 2021
Hi @VasimPatel, sorry for the late reply and thanks for reporting the issue.
Seems like an issue with accessibility in Edge.
Simplified demo: https://jsfiddle.net/BlackLabel/nr7gst92/
FYI @oysteinmoseng
VasimPatel commentedon Jun 23, 2021
Hello,
Yes it only happens in Edge. In chrome the high contrast mode does not change the colors or the chart (unable to apply any color changes at all in chrome under the high contrast theme). Is there any way to disable this functionality so the charts do not change in high contrast mode?
raf18seb commentedon Jun 24, 2021
@VasimPatel,
actually, it's not the Edge issue - it's the only browser the contrast mode is working correctly with.
To change the colors in the Windows High Contrast Mode, you can use this property: https://api.highcharts.com/highcharts/accessibility.highContrastTheme
Sample demo: https://jsfiddle.net/BlackLabel/rptya3h6/
Pending for @oysteinmoseng comment
oysteinmoseng commentedon Jun 24, 2021
This is an issue with how we apply the high contrast mode theme. We really need to change this.
The theme forces specific colors to be set on each series, from
theme.plotOptions, which is unfortunately necessary since it needs to override other colors that may be set specifically on each series. Perhaps we can find a better solution for this.There is currently no way to turn off the high contrast theme, which there should be. We will of course add this.
Note: You should probably be careful with setting specific colors in High contrast mode, since you don't know what color theme the user has set up and prefers. The user is able to set their own custom theme in High contrast mode. Some users may even use High contrast mode for low contrast, for example users with certain cognitive disabilities. By setting specific colors you could clash with the user's custom theme.
Highcharts by default tries to use the colors defined by the user by referring to system colors instead of hardcoded values. If you run into cases where this is not appropriate it would be great to know, since we would want to change the default theme or behavior to handle the use case.
msftedad commentedon Feb 8, 2024
Hi team, Any update on this issue?
oysteinmoseng commentedon Feb 12, 2024
Hi @msftedad, we will prioritize investigating this issue.
A11y: align high contrast theme colors across series types (#15921)