GoodData.UI API reference
  • All Products
  • All Products
  • GoodData.UI
  • API Reference
  • University
  • Community
  • Documentation
  • Support
  • 11.47.0
  • Code samples
  • GitHub

enableContrastSafeDerivedColors

Home > @gooddata/sdk-ui-charts > IChartConfig > enableContrastSafeDerivedColors

IChartConfig.enableContrastSafeDerivedColors property

Keeps colors derived for comparison (period-over-period) measures at the WCAG 1.4.11 minimum 3:1 contrast ratio against the chart background.

Signature:

enableContrastSafeDerivedColors?: boolean;

Remarks

When the standard derivation would produce a color too close to the background, the closest compliant blend in the same direction is used instead, and when no such blend exists the search continues in the opposite direction. Candidates keep a minimum distance from the master measure color so the two series stay distinguishable. If no candidate meets the ratio (for example on a mid-gray background), the standard color is kept.

  • IChartConfig.enableContrastSafeDerivedColors property
  • Remarks
GoodData resources:
  • Documentation
Follow the community:
  • Community
Copyright © 2007–2026 GoodData Corporation. All Rights Reserved. Code licensed under a dual license - CC BY‑NC 4.0 for trial experience and GoodData.UI EULA for commercial use